Skip to main content

Python module implementing the Hydrus API

Project description

Hydrus API

Python module implementing the Hydrus API.

Requirements

  • Python 3
  • requests library (pip install requests)

Installation

$ pip install hydrus-api

If you want to use the package in your own (installable) Python project, specify it in your setup.py using: install_requires=['hydrus-api'].

Description

It is highly recommended that you do not solely rely on the docstrings in this module to use the API, instead read the official documentation (latest here).

When instantiating Client the acccess_key is optional, allowing you to initially manually request permissions using request_new_permissions(). Alternatively there is utils.request_api_key() to make this easier. You can instantiate a new Client with the returned access key after that.

If the API version the module is developed against and the API version at the specified endpoint differ, you will be warned but not prevented from using any functionality -- this might have unintended consequences, be careful.

If something with the API goes wrong, a subclass of APIError (MissingParameter, InsufficientAccess, ServerError) or APIError itself will be raised with the requests.Response object that caused the error. APIError will only be raised directly, if the returned status code is unrecognized.

The module provides Permission, URLType, ImportStatus, TagAction, TagStatus and PageType enums for your convenience. Values in the response data, represented by the enums, are automatically converted -- this makes them more easily readable, the enum values can still be handled like regular integers. Some utility functions are available in hydrus.utils.

Check out examples/ for some example applications.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

hydrus-api-1.11.4.tar.gz (30.2 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

hydrus_api-1.11.4-py3-none-any.whl (32.0 kB view details)

Uploaded Python 3

File details

Details for the file hydrus-api-1.11.4.tar.gz.

File metadata

  • Download URL: hydrus-api-1.11.4.tar.gz
  • Upload date:
  • Size: 30.2 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: poetry/0.12.17 CPython/3.7.4 Linux/4.19.73-1-lts

File hashes

Hashes for hydrus-api-1.11.4.tar.gz
Algorithm Hash digest
SHA256 1ff7bb0f3d1fb185a6bae56ce9bf224418d3409e3f061a1c0951c0abd4c74d33
MD5 28d75eebb0edbf21e861f55de5acd0c1
BLAKE2b-256 2f5cc23a0574d55062501ac3dd032142940c409a407af7e02d51c872f5f38304

See more details on using hashes here.

File details

Details for the file hydrus_api-1.11.4-py3-none-any.whl.

File metadata

  • Download URL: hydrus_api-1.11.4-py3-none-any.whl
  • Upload date:
  • Size: 32.0 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: poetry/0.12.17 CPython/3.7.4 Linux/4.19.73-1-lts

File hashes

Hashes for hydrus_api-1.11.4-py3-none-any.whl
Algorithm Hash digest
SHA256 cfb4d57eb645062c0a215fb21d66998c7d474a3fbfe9e5fb4cc976a4302b7d9b
MD5 057237d8fd49541deb0df20f2f8b67c4
BLAKE2b-256 1d7bbce0d6dbc27da8bfe3bfccd28f3c83874f7cd5387b5690616c4d0302d2d5

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page