semvec/pypi-packages huggingface dataset:
local-forex 0.1.9
A package for maintaining and interacting with a local forex database.
Requires Python: >=3.10

# local-forex
A free python package to help get started in building and interacting with a local database of currency exchange rates.

## Dictionary based currency exchange rate package
* Rates provided by Bank of Canada. Includes function for fetching and saving latest rates using BoC API
* Offline JSON historical database reduces reliance on external API availability (records to 2017-01-03, TODO: extend historical records)
* ~24 modern currencies supported
## Installation
```shell
pip install local-forex
cd local-forex
pip install -r requirements.txt
```

## Example conversion
```python
import local_forex

fx = local_forex.ForexRates()

# Example conversion rate query for USD/EUR on December 02, 2020
from datetime import datetime
rate = local_forex.get_conversion_rate(base="USD", quote="EUR", date=datetime(2020,12,02))

```
## Backfilling rates
* backfill.py is included for convenience. Run Mon-Fri after 16:30EST to update database daily (e.g. Launchd on MacOS).
```python
online_rates = fx.fetch_boc_rates()
fx.update_from_boc_rates(online_rates)
fx.save_rates_to_file()
```
gpycat 0.1.3
Python Gfycat API
Requires Python: >=3.8,<3.11

# gpycat
![PyPI - Python Version](https://img.shields.io/pypi/pyversions/gpycat?style=for-the-badge)
![GitHub](https://img.shields.io/github/license/kvdomingo/pygfycat?style=for-the-badge)
![GitHub release (latest SemVer including pre-releases)](https://img.shields.io/github/v/release/kvdomingo/pygfycat?include_prereleases&style=for-the-badge)

![](./coverage.svg)

This is a WIP unofficial Python wrapper for the Gfycat web API.

## Installation
```shell
# Using pip
pip install gpycat

# OR

# Using poetry
poetry add gpycat
```

## Usage

```python
from gpycat import gpycat

# Import your client ID/secret from environment variables

gpycat.auth(client_id=CLIENT_ID, client_secret=CLIENT_SECRET)
item = gpycat.get_gfycat("zestycreepyasiaticlesserfreshwaterclam")
```

Output:
```shell
> GfyItem(title="...", description="...", avgColor="...", content_urls={...}, ...)
```