Skip to main content

Cryptonator Python API

A simple wrapper for the Cryptonator exchange rate API.

Install

You can either install Cryptonator by using pip, or simply copy the cryptonator.py file in you project root directory.

$ pip install cryptonator  # add --user if you want

Usage

import cryptonator

"""Get an exchange rate between two currencies."""
cryptonator.get_exchange_rate('usd', 'eur')
# 0.95147479

"""A Cryptonator API object can speed-up things if you need multiple calls."""
api = cryptonator.Cryptonator()

"""Get an exchange rate between a single curreny and many targets."""
api.get_exchange_rates('usd', ['eur', 'btc', 'xrp'])
# {'btc': 0.00136076, 'eur': 0.95147479, 'xrp': 144.71780029}

Testing

Tests can be found in test_cryptonator.py. You can launch them with:

$ python test_cryptonator.py

Release files for cryptonator 0.0.4

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Built distribution (wheel)

Table of built distributions (wheels) for cryptonator 0.0.4
File Interpreter ABI Platform
cryptonator-0.0.4-py2.py3-none-any.whl Python 2, Python 3 none any Details

Release files / cryptonator-0.0.4-py2.py3-none-any.whl

Download URL cryptonator-0.0.4-py2.py3-none-any.whl
Size 3.7 kB
Tags Python 2 Python 3
SHA-256 checksum
How to use checksums
12d360b0a48c1363ab177cc0c5f003aeeb916f39effffe709f0f1c767f5ece03
BLAKE2b-256 checksum
How to use checksums
c1b48888f66a888a5d1f25971ff2eac984ec0ef6c7adde7074b88a85b137e8b4
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/3.2.0 pkginfo/1.6.1 requests/2.24.0 setuptools/50.3.2 requests-toolbelt/0.9.1 tqdm/4.51.0 CPython/3.9.0

Release history Release notifications | RSS feed

This release

0.0.4 This release

1 release file

0.0.3

2 release files

0.0.2

2 release files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page