Metadata-Version: 2.4
Name: currencycore
Version: 0.1.0
Summary: Official CurrencyCore API client - currency conversion, FX rates, PPP, and analytics.
Home-page: 
Author: OpenAPI Generator community
Author-email: CurrencyCore <dev@currency-core.com>
License-Expression: MIT
Project-URL: Homepage, https://currency-core.com
Project-URL: Repository, https://github.com/CurrencyCore/currencycore-python
Keywords: currencycore,currency,exchange-rates,forex,ppp,fx,api,sdk
Classifier: Programming Language :: Python :: 3
Classifier: Operating System :: OS Independent
Classifier: Intended Audience :: Developers
Classifier: Topic :: Software Development :: Libraries :: Python Modules
Requires-Python: >=3.9
Description-Content-Type: text/markdown
License-File: LICENSE
Requires-Dist: urllib3<3.0.0,>=2.1.0
Requires-Dist: python-dateutil>=2.8.2
Requires-Dist: pydantic>=2.11
Requires-Dist: typing-extensions>=4.7.1
Provides-Extra: dev
Requires-Dist: pytest>=7.2.1; extra == "dev"
Dynamic: author
Dynamic: license-file

# CurrencyCore SDK for Python

Official client for the [CurrencyCore](https://currency-core.com) API — currency
conversion, FX rates, PPP, and analytics.

Generated from the CurrencyCore OpenAPI 3.1 spec with
[OpenAPI Generator](https://openapi-generator.tech) (`python`, urllib3), plus a
thin `create_client` helper for API-key and version handling.

## Install

```bash
pip install currencycore
```

## Quickstart

```python
from currencycore.client import create_client

api = create_client(api_key="cc_live_...")  # or set CURRENCYCORE_API_KEY
res = api.convert(var_from="USD", to="EUR", amount=100)
print(res.results[0])
```

`var_from` carries the `var_` prefix because `from` is a reserved word in Python.

Public reference endpoints need no key:

```python
api = create_client()
print(api.currencies())
```

## API key

`create_client` resolves the key as `api_key` → `CURRENCYCORE_API_KEY`.

## API version

Base URL is `https://api.currency-core.com/{version}` (default `v1`):

```python
create_client(version="v1")
create_client(base_url="https://api.currency-core.com/v1")
```

## Low-level client

```python
import currencycore

config = currencycore.Configuration(
    host="https://api.currency-core.com/v1", access_token="cc_live_..."
)
api = currencycore.CurrencyCoreApi(currencycore.ApiClient(config))
```

## Regenerate

The committed `openapi.json` is the source of truth:

```bash
bash scripts/generate.sh
```

Hand-written files (`currencycore/client.py`, this README) are protected by
`.openapi-generator-ignore`.

## License

MIT
