Skip to main content

Fetch rates from openexchangerates with aiohttp.

Project description

aioopenexchangerates

CI Status Documentation Status Test coverage percentage

Poetry Ruff pre-commit

PyPI Version Supported Python versions License


Documentation: https://aioopenexchangerates.readthedocs.io

Source Code: https://github.com/MartinHjelmare/aioopenexchangerates


Fetch rates from openexchangerates with aiohttp.

Installation

Install this via pip (or your favourite package manager):

pip install aioopenexchangerates

Usage

import asyncio

from aioopenexchangerates import Client, OpenExchangeRatesError


async def main() -> None:
    """Run main."""
    async with Client("your_api_key") as client:
        try:
            result = await client.get_latest()
        except OpenExchangeRatesError as err:
            print(err)
        else:
            print(result)


if __name__ == "__main__":
    asyncio.run(main())

Credits

This package was created with Copier and the browniebroke/pypackage-template project template.

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

aioopenexchangerates-0.6.18.tar.gz (8.6 kB view details)

Uploaded Source

Built Distribution

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

aioopenexchangerates-0.6.18-py3-none-any.whl (9.4 kB view details)

Uploaded Python 3

File details

Details for the file aioopenexchangerates-0.6.18.tar.gz.

File metadata

  • Download URL: aioopenexchangerates-0.6.18.tar.gz
  • Upload date:
  • Size: 8.6 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/5.1.1 CPython/3.12.7

File hashes

Hashes for aioopenexchangerates-0.6.18.tar.gz
Algorithm Hash digest
SHA256 b0e544f6badb500331f39cb8abf5f3519e612ad4633ef3bb581353420cd5a198
MD5 33cfe088f0a33bf6ebbe602bc8770e75
BLAKE2b-256 78781687bcc76c7a1d4b72a24841f8e610e757f673b44ec2f532b8e87b554eac

See more details on using hashes here.

Provenance

The following attestation bundles were made for aioopenexchangerates-0.6.18.tar.gz:

Publisher: ci.yml on MartinHjelmare/aioopenexchangerates

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file aioopenexchangerates-0.6.18-py3-none-any.whl.

File metadata

File hashes

Hashes for aioopenexchangerates-0.6.18-py3-none-any.whl
Algorithm Hash digest
SHA256 2d14451fe6776697ad337d8fcc4ee50dc094946261a98b49c43b1b9e25a18327
MD5 f0ee0452577577834f828c1d1ca79aec
BLAKE2b-256 33cf86fad5ad404fe133d0b367763b3513b11fb87c72a9b88f79d255a09fafd9

See more details on using hashes here.

Provenance

The following attestation bundles were made for aioopenexchangerates-0.6.18-py3-none-any.whl:

Publisher: ci.yml on MartinHjelmare/aioopenexchangerates

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

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