# SDKs

> Python SDK (generated, typed, sync+async) — TypeScript next


## Python

```bash
pip install deepsieve
```

Fully typed, sync + async, generated from the /v1 contract:

```python
from deepsieve import SDK

with SDK(bearer_auth="ds_live_...") as sdk:
    me = sdk.v1_meta.v1_meta_get_me().result

    # Free test run — exercises the real poll loop
    run = sdk.v1_research.v1_research_create_run(query="...", dry_run=True).result

    # Discover the schema, then read cited data
    catalog = sdk.v1_data.v1_data_data_catalog().result
    page = sdk.v1_data.v1_data_read_entity_data(
        entity_key=catalog.entities[0].key, receipts=True
    ).result
```

Every call returns `.result` (typed models) plus `.headers` (RateLimit-*,
X-Request-Id). Errors raise typed exceptions carrying the same
`{code, retriable, request_id}` envelope the REST API returns.

The SDK is generated from [`/openapi.json`](/openapi.json)'s `/v1` subset and
regenerated whenever the contract changes, and CI fails a PR that leaves the
two out of step. That keeps the SDK matching the CONTRACT; where the contract
and the running API disagree, the API is the truth and the gap is our bug.

## TypeScript

Next up, generated from the same source. Until then the REST API is
deliberately easy to consume raw — every list is `{data, has_more,
next_cursor}`, every error is typed — and your coding assistant can build a
thin client from the [Quickstart](/developers) prompt block in one shot.
