Metadata-Version: 2.4
Name: attestic
Version: 0.1.0
Summary: Thin client for the Attestic AI gateway: pre-configured OpenAI/Anthropic clients + offline signed-receipt verification.
Author: VelarIQ Inc.
License: MIT
Project-URL: Homepage, https://attestic.ai
Project-URL: Documentation, https://attestic.ai/developers
Keywords: attestic,ai,gateway,provenance,openai,anthropic,llm
Requires-Python: >=3.9
Description-Content-Type: text/markdown
Requires-Dist: cryptography>=41
Provides-Extra: openai
Requires-Dist: openai>=1.30; extra == "openai"
Provides-Extra: anthropic
Requires-Dist: anthropic>=0.40; extra == "anthropic"
Provides-Extra: all
Requires-Dist: openai>=1.30; extra == "all"
Requires-Dist: anthropic>=0.40; extra == "all"

# attestic (Python)

Thin client for the [Attestic](https://attestic.ai) AI gateway.

Attestic is drop-in **OpenAI- and Anthropic-compatible**, so you can also just point
the OpenAI or Anthropic SDK at `https://api.attestic.ai`. This package adds two
conveniences: a pre-configured client, and **offline verification of the signed
provenance receipt** every call produces.

```bash
pip install attestic[all]      # or attestic[openai] / attestic[anthropic]
```

```python
from attestic import Attestic

at = Attestic(api_key="atk_...")   # mint a key at attestic.ai/api-keys

# OpenAI-style
r = at.openai.chat.completions.create(
    model="gpt-5.5",
    messages=[{"role": "user", "content": "Explain provenance in one sentence."}],
)
print(r.choices[0].message.content)

# Anthropic / Claude-style (same key, same gateway)
m = at.anthropic.messages.create(
    model="claude-fable-5", max_tokens=256,
    messages=[{"role": "user", "content": "hi"}],
)

# Verify a call's receipt OFFLINE — no trust in Attestic required
receipt_id = "..."                 # from the x-attestic-receipt-id response header
assert at.verify(receipt_id)       # checks Ed25519 signature + Merkle inclusion
```

Models route by id across OpenAI, Anthropic, Google, and NVIDIA open-weight —
`gpt-5.5`, `claude-fable-5`, `gemini-3.1-pro-preview`, `meta/llama-3.3-70b-instruct`, …

## Without this SDK
Nothing special required:

```python
from openai import OpenAI
client = OpenAI(base_url="https://api.attestic.ai/v1", api_key="atk_...")
```
```python
from anthropic import Anthropic
client = Anthropic(base_url="https://api.attestic.ai", api_key="atk_...")
```
