Metadata-Version: 2.4
Name: fxmacrodata-platform-core
Version: 0.1.0
Summary: Public-contract data adapters for FXMacroData platform integrations
License-Expression: MIT
Requires-Python: >=3.10
Description-Content-Type: text/markdown
License-File: LICENSE
Requires-Dist: fxmacrodata-public-client==0.1.1
Dynamic: license-file

# FXMacroData platform core

Read documented FXMacroData operations into lossless records for data platforms.
The package adds a stable tabular projection while preserving complete response
envelopes, source links, original values, release timestamps and revisions.

```python
from fxmacrodata_platform_core import read, schemas

batch = read("release_calendar", {"currency": "usd"})
records = batch.records()
table_rows = batch.rows()
original_response = batch.payload
```

USD catalogue, recent macro history and calendar provide a no-key evaluation
workflow subject to the public service's limits and delay. For subscribed access,
provision a secret environment variable and pass only its name:

```python
batch = read("indicator_history", {"currency": "eur", "indicator": "policy_rate"},
             api_key_env="FXMACRODATA_API_KEY")
```

Omitting `api_key_env` explicitly uses anonymous access. Credentials are sent in
headers, never operation arguments. Errors omit provider response text and URLs.
The package sends requests only through the public client to documented service
origins.

`schemas()` returns every packaged operation's input schema. Offset-paginated
REST operations download complete available histories within `max_pages` and
reject partial initial offsets. Calendar snapshot/version operations follow cursors
within the same archive checkpoint, retaining every original page. Other MCP tools
and finite SSE captures preserve their bounded public response. Use
`complete_history=False` for an individual history page or explicit continuation.

`record_json` and `response_json` preserve parsed public JSON except credential
redaction. JSON number tokens use the public Python client's numeric parser;
their original lexical precision is not guaranteed. Source numbers supplied as
strings retain their precision. `value` is an approximate floating-point
convenience; `value_text` represents the parsed source value. Empty responses produce one envelope
row with `record_json` set to JSON `null`. No publication time or future date is
inferred. A stable content hash identifies repeated records, without a fetch clock.

[FXMacroData documentation](https://fxmacrodata.com/documentation/reference?utm_source=github&utm_medium=referral&utm_campaign=platform-core&utm_content=readme)
