cryptodatapi


Namecryptodatapi JSON
Version 1.0.7 PyPI version JSON
download
home_pagehttps://horisystems.com/crypto-api/
SummaryPython SDK for integrating with Crypto API.
upload_time2023-10-27 22:46:44
maintainer
docs_urlNone
authorHori Systems Limited
requires_python>=2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*
licenseMIT
keywords crypto cryptocurrency bitcoin btc ethereum sol bnb
VCS
bugtrack_url
requirements No requirements were recorded.
Travis-CI No Travis.
coveralls test coverage No coveralls.
            cryptodatapi
============

.. image:: https://badge.fury.io/py/cryptodatapi.svg
    :target: https://badge.fury.io/py/cryptodatapi
    :alt: Crypto API Python Package Version

Python library for integrating with `Crypto API`_ functionality.

.. _Crypto API: https://horisystems.com/crypto-api/


Requirements
-------------

Python 2.7 and later.


Setup
------

You can install this package by using the pip tool and installing:

.. code-block:: bash

	$ pip install cryptodatapi

Or:

.. code-block:: bash

	$ easy_install cryptodatapi


Usage Example
-------------

.. code-block:: python

    import cryptodatapi
    from dotenv import load_dotenv
    import os

    ## Loads environment variables from .env
    load_dotenv('.env')

    username = os.getenv('_USERNAME')
    password = os.getenv('_PASSWORD')

    ## Authentication
    cryptodatapi.login(username, password)

    ## Retrieve All Cryptocurrency Prices
    cryptoPrices = cryptodatapi.get_crypto_price()
    print(cryptoPrices)

    ## Retrieve Cryptocurrency Price by ID
    cryptoPriceByID = cryptodatapi.get_crypto_price(id='<insert unique id>')
    print(cryptoPriceByID)

    ## Retrieve Bitcoin Price
    cryptoPrice = cryptodatapi.get_crypto_price(sym='BTC')
    print(cryptoPrice)

    ## Retrieve All Cryptocurrency Top Gainers
    cryptoGainers = cryptodatapi.get_gainers()
    print(cryptoGainers)

    ## Retrieve Cryptocurrency Top Gainers by ID
    cryptoGainersByID = cryptodatapi.get_gainers(id='<insert unique id>')
    print(cryptoGainersByID)

    ## Retrieve All Cryptocurrency Top Losers
    cryptoLosers = cryptodatapi.get_losers()
    print(cryptoLosers)

    ## Retrieve Cryptocurrency Top Losers by ID
    cryptoLosersByID = cryptodatapi.get_losers(id='<insert unique id>')
    print(cryptoLosersByID)

    ## Retrieve All Cryptocurrency 2021 Historical Prices
    cryptoHistorical2021 = cryptodatapi.get_hist_price_2021()
    print(cryptoHistorical2021)

    ## Retrieve Cryptocurrency 2021 Historical Prices by ID
    cryptoHistorical2021ByID = cryptodatapi.get_hist_price_2021(id='<insert unique id>')
    print(cryptoHistorical2021ByID)

    ## Retrieve All Cryptocurrency 2022 Historical Prices
    cryptoHistorical2022 = cryptodatapi.get_hist_price_2022()
    print(cryptoHistorical2022)

    ## Retrieve Cryptocurrency 2022 Historical Prices by ID
    cryptoHistorical2022ByID = cryptodatapi.get_hist_price_2022(id='<insert unique id>')
    print(cryptoHistorical2022ByID)

    ## Retrieve All Cryptocurrency 2023 Historical Prices
    cryptoHistorical2023 = cryptodatapi.get_hist_price_2023()
    print(cryptoHistorical2023)

    ## Retrieve Cryptocurrency 2023 Historical Prices by ID
    cryptoHistorical2023ByID = cryptodatapi.get_hist_price_2023(id='<insert unique id>')
    print(cryptoHistorical2023ByID)

    ## Retrieve All Cryptocurrency Derivatives Exchanges
    cryptoDerivatives = cryptodatapi.get_derivatives()
    print(cryptoDerivatives)

    ## Retrieve Cryptocurrency Derivatives Exchanges by ID
    cryptoDerivativesByID = cryptodatapi.get_derivatives(id='<insert unique id>')
    print(cryptoDerivativesByID)

    ## Retrieve All Cryptocurrency Decentralized Exchanges
    cryptoDecentralized = cryptodatapi.get_dex()
    print(cryptoDecentralized)

    ## Retrieve Cryptocurrency Decentralized Exchanges by ID
    cryptoDecentralizedByID = cryptodatapi.get_dex(id='<insert unique id>')
    print(cryptoDecentralizedByID)

    ## Retrieve All Cryptocurrency Lending Exchanges
    cryptoLending = cryptodatapi.get_lending()
    print(cryptoLending)

    ## Retrieve Cryptocurrency Lending Exchanges by ID
    cryptoLendingByID = cryptodatapi.get_lending(id='<insert unique id>')
    print(cryptoLendingByID)

    ## Retrieve All Cryptocurrency Spot Exchanges
    cryptoSpot = cryptodatapi.get_spot()
    print(cryptoSpot)

    ## Retrieve Cryptocurrency Spot Exchanges by ID
    cryptoSpotByID = cryptodatapi.get_spot(id='<insert unique id>')
    print(cryptoSpotByID)

    ## Retrieve All Cryptocurrency News
    cryptoNews = cryptodatapi.get_news()
    print(cryptoNews)

    ## Retrieve Cryptocurrency News by ID
    cryptoNewsByID = cryptodatapi.get_news(id='<insert unique id>')
    print(cryptoNewsByID)


Setting up an Crypto API Account
--------------------------------

Sign up for a self-service `user account`_.

.. _user account: https://horisystems.com/crypto-api/


Using the Crypto API
--------------------

You can read the `API documentation`_ to understand what's possible with the Crypto API. If you need further assistance, don't hesitate to `contact us`_.

.. _API documentation: https://docs.cryptodatapi.com/
.. _contact us: https://horisystems.com/contact/

License
--------

This project is licensed under the `MIT License`_.  

.. _MIT License: https://horisystems.com/


Copyright
----------

Copyright |copy| 2020 - 2023 `Hori Systems Limited`_. All Rights Reserved.

.. |copy| unicode:: 0xA9 .. copyright sign
.. _Hori Systems Limited: https://horisystems.com/

            

Raw data

            {
    "_id": null,
    "home_page": "https://horisystems.com/crypto-api/",
    "name": "cryptodatapi",
    "maintainer": "",
    "docs_url": null,
    "requires_python": ">=2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*",
    "maintainer_email": "",
    "keywords": "crypto,cryptocurrency,bitcoin,btc,ethereum,sol,bnb",
    "author": "Hori Systems Limited",
    "author_email": "support@horisystems.com",
    "download_url": "https://files.pythonhosted.org/packages/10/78/38c97a8b697010e9ddde642712cbab93b622f7e42a3a7b6310a9d101082a/cryptodatapi-1.0.7.tar.gz",
    "platform": null,
    "description": "cryptodatapi\n============\n\n.. image:: https://badge.fury.io/py/cryptodatapi.svg\n    :target: https://badge.fury.io/py/cryptodatapi\n    :alt: Crypto API Python Package Version\n\nPython library for integrating with `Crypto API`_ functionality.\n\n.. _Crypto API: https://horisystems.com/crypto-api/\n\n\nRequirements\n-------------\n\nPython 2.7 and later.\n\n\nSetup\n------\n\nYou can install this package by using the pip tool and installing:\n\n.. code-block:: bash\n\n\t$ pip install cryptodatapi\n\nOr:\n\n.. code-block:: bash\n\n\t$ easy_install cryptodatapi\n\n\nUsage Example\n-------------\n\n.. code-block:: python\n\n    import cryptodatapi\n    from dotenv import load_dotenv\n    import os\n\n    ## Loads environment variables from .env\n    load_dotenv('.env')\n\n    username = os.getenv('_USERNAME')\n    password = os.getenv('_PASSWORD')\n\n    ## Authentication\n    cryptodatapi.login(username, password)\n\n    ## Retrieve All Cryptocurrency Prices\n    cryptoPrices = cryptodatapi.get_crypto_price()\n    print(cryptoPrices)\n\n    ## Retrieve Cryptocurrency Price by ID\n    cryptoPriceByID = cryptodatapi.get_crypto_price(id='<insert unique id>')\n    print(cryptoPriceByID)\n\n    ## Retrieve Bitcoin Price\n    cryptoPrice = cryptodatapi.get_crypto_price(sym='BTC')\n    print(cryptoPrice)\n\n    ## Retrieve All Cryptocurrency Top Gainers\n    cryptoGainers = cryptodatapi.get_gainers()\n    print(cryptoGainers)\n\n    ## Retrieve Cryptocurrency Top Gainers by ID\n    cryptoGainersByID = cryptodatapi.get_gainers(id='<insert unique id>')\n    print(cryptoGainersByID)\n\n    ## Retrieve All Cryptocurrency Top Losers\n    cryptoLosers = cryptodatapi.get_losers()\n    print(cryptoLosers)\n\n    ## Retrieve Cryptocurrency Top Losers by ID\n    cryptoLosersByID = cryptodatapi.get_losers(id='<insert unique id>')\n    print(cryptoLosersByID)\n\n    ## Retrieve All Cryptocurrency 2021 Historical Prices\n    cryptoHistorical2021 = cryptodatapi.get_hist_price_2021()\n    print(cryptoHistorical2021)\n\n    ## Retrieve Cryptocurrency 2021 Historical Prices by ID\n    cryptoHistorical2021ByID = cryptodatapi.get_hist_price_2021(id='<insert unique id>')\n    print(cryptoHistorical2021ByID)\n\n    ## Retrieve All Cryptocurrency 2022 Historical Prices\n    cryptoHistorical2022 = cryptodatapi.get_hist_price_2022()\n    print(cryptoHistorical2022)\n\n    ## Retrieve Cryptocurrency 2022 Historical Prices by ID\n    cryptoHistorical2022ByID = cryptodatapi.get_hist_price_2022(id='<insert unique id>')\n    print(cryptoHistorical2022ByID)\n\n    ## Retrieve All Cryptocurrency 2023 Historical Prices\n    cryptoHistorical2023 = cryptodatapi.get_hist_price_2023()\n    print(cryptoHistorical2023)\n\n    ## Retrieve Cryptocurrency 2023 Historical Prices by ID\n    cryptoHistorical2023ByID = cryptodatapi.get_hist_price_2023(id='<insert unique id>')\n    print(cryptoHistorical2023ByID)\n\n    ## Retrieve All Cryptocurrency Derivatives Exchanges\n    cryptoDerivatives = cryptodatapi.get_derivatives()\n    print(cryptoDerivatives)\n\n    ## Retrieve Cryptocurrency Derivatives Exchanges by ID\n    cryptoDerivativesByID = cryptodatapi.get_derivatives(id='<insert unique id>')\n    print(cryptoDerivativesByID)\n\n    ## Retrieve All Cryptocurrency Decentralized Exchanges\n    cryptoDecentralized = cryptodatapi.get_dex()\n    print(cryptoDecentralized)\n\n    ## Retrieve Cryptocurrency Decentralized Exchanges by ID\n    cryptoDecentralizedByID = cryptodatapi.get_dex(id='<insert unique id>')\n    print(cryptoDecentralizedByID)\n\n    ## Retrieve All Cryptocurrency Lending Exchanges\n    cryptoLending = cryptodatapi.get_lending()\n    print(cryptoLending)\n\n    ## Retrieve Cryptocurrency Lending Exchanges by ID\n    cryptoLendingByID = cryptodatapi.get_lending(id='<insert unique id>')\n    print(cryptoLendingByID)\n\n    ## Retrieve All Cryptocurrency Spot Exchanges\n    cryptoSpot = cryptodatapi.get_spot()\n    print(cryptoSpot)\n\n    ## Retrieve Cryptocurrency Spot Exchanges by ID\n    cryptoSpotByID = cryptodatapi.get_spot(id='<insert unique id>')\n    print(cryptoSpotByID)\n\n    ## Retrieve All Cryptocurrency News\n    cryptoNews = cryptodatapi.get_news()\n    print(cryptoNews)\n\n    ## Retrieve Cryptocurrency News by ID\n    cryptoNewsByID = cryptodatapi.get_news(id='<insert unique id>')\n    print(cryptoNewsByID)\n\n\nSetting up an Crypto API Account\n--------------------------------\n\nSign up for a self-service `user account`_.\n\n.. _user account: https://horisystems.com/crypto-api/\n\n\nUsing the Crypto API\n--------------------\n\nYou can read the `API documentation`_ to understand what's possible with the Crypto API. If you need further assistance, don't hesitate to `contact us`_.\n\n.. _API documentation: https://docs.cryptodatapi.com/\n.. _contact us: https://horisystems.com/contact/\n\nLicense\n--------\n\nThis project is licensed under the `MIT License`_.  \n\n.. _MIT License: https://horisystems.com/\n\n\nCopyright\n----------\n\nCopyright |copy| 2020 - 2023 `Hori Systems Limited`_. All Rights Reserved.\n\n.. |copy| unicode:: 0xA9 .. copyright sign\n.. _Hori Systems Limited: https://horisystems.com/\n",
    "bugtrack_url": null,
    "license": "MIT",
    "summary": "Python SDK for integrating with Crypto API.",
    "version": "1.0.7",
    "project_urls": {
        "Bug Tracker": "https://github.com/horisystems/cryptodatapi-py-sdk/issues",
        "Changes": "https://github.com/horisystems/cryptodatapi-py-sdk/blob/main/CHANGELOG.md",
        "Documentation": "https://docs.cryptodatapi.com/",
        "Homepage": "https://horisystems.com/crypto-api/",
        "Source Code": "https://github.com/horisystems/cryptodatapi-py-sdk"
    },
    "split_keywords": [
        "crypto",
        "cryptocurrency",
        "bitcoin",
        "btc",
        "ethereum",
        "sol",
        "bnb"
    ],
    "urls": [
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "3295a72c3b099039f2484499d5c26c1a509d59c5d475d0eb17b818893800e94d",
                "md5": "d4b49221a4be747a03acb8be07a421f9",
                "sha256": "4d157ae53616ab9168f682bad061c809094b1870c1e30664374eb4aa23d44dfa"
            },
            "downloads": -1,
            "filename": "cryptodatapi-1.0.7-py3-none-any.whl",
            "has_sig": false,
            "md5_digest": "d4b49221a4be747a03acb8be07a421f9",
            "packagetype": "bdist_wheel",
            "python_version": "py3",
            "requires_python": ">=2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*",
            "size": 9318,
            "upload_time": "2023-10-27T22:46:42",
            "upload_time_iso_8601": "2023-10-27T22:46:42.735761Z",
            "url": "https://files.pythonhosted.org/packages/32/95/a72c3b099039f2484499d5c26c1a509d59c5d475d0eb17b818893800e94d/cryptodatapi-1.0.7-py3-none-any.whl",
            "yanked": false,
            "yanked_reason": null
        },
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "107838c97a8b697010e9ddde642712cbab93b622f7e42a3a7b6310a9d101082a",
                "md5": "96e28f350ccb5dafc9446d7b776093ac",
                "sha256": "6711daa7b2ad34aa0a866fca85057f68acd429f667bac16817809ce62b9615ea"
            },
            "downloads": -1,
            "filename": "cryptodatapi-1.0.7.tar.gz",
            "has_sig": false,
            "md5_digest": "96e28f350ccb5dafc9446d7b776093ac",
            "packagetype": "sdist",
            "python_version": "source",
            "requires_python": ">=2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*",
            "size": 7617,
            "upload_time": "2023-10-27T22:46:44",
            "upload_time_iso_8601": "2023-10-27T22:46:44.326336Z",
            "url": "https://files.pythonhosted.org/packages/10/78/38c97a8b697010e9ddde642712cbab93b622f7e42a3a7b6310a9d101082a/cryptodatapi-1.0.7.tar.gz",
            "yanked": false,
            "yanked_reason": null
        }
    ],
    "upload_time": "2023-10-27 22:46:44",
    "github": true,
    "gitlab": false,
    "bitbucket": false,
    "codeberg": false,
    "github_user": "horisystems",
    "github_project": "cryptodatapi-py-sdk",
    "github_not_found": true,
    "lcname": "cryptodatapi"
}
        
Elapsed time: 0.12844s