Metadata-Version: 2.4
Name: treeship-sdk
Version: 0.1.0
Summary: Cryptographic attestations for AI agents
Project-URL: Homepage, https://treeship.dev
Project-URL: Documentation, https://docs.treeship.dev
Project-URL: Repository, https://github.com/treeship-dev/treeship
Author-email: Treeship <hello@treeship.dev>
License: MIT
Keywords: agents,ai,attestation,cryptography,treeship,verification
Classifier: Development Status :: 4 - Beta
Classifier: Intended Audience :: Developers
Classifier: License :: OSI Approved :: MIT License
Classifier: Programming Language :: Python :: 3
Classifier: Programming Language :: Python :: 3.9
Classifier: Programming Language :: Python :: 3.10
Classifier: Programming Language :: Python :: 3.11
Classifier: Programming Language :: Python :: 3.12
Classifier: Topic :: Software Development :: Libraries :: Python Modules
Requires-Python: >=3.9
Requires-Dist: httpx>=0.27.0
Description-Content-Type: text/markdown

# treeship-sdk

Cryptographic attestations for AI agents.

## Installation

```bash
pip install treeship-sdk
```

## Quick Start

```python
from treeship import Treeship

# Initialize (uses TREESHIP_API_KEY and TREESHIP_AGENT env vars)
ts = Treeship()

# Create an attestation
result = ts.attest(
    action="Approved loan application #12345",
    inputs_hash=ts.hash({"customer_id": "cust_123", "amount": 50000})
)

print(f"Attestation: {result.attestation_id}")
print(f"Verify at: {result.url}")
```

## Environment Variables

| Variable | Description |
|----------|-------------|
| `TREESHIP_API_KEY` | Your API key (required for attest) |
| `TREESHIP_AGENT` | Default agent slug |
| `TREESHIP_API_URL` | API URL (default: https://api.treeship.dev) |

## Async Support

```python
from treeship import AsyncTreeship

async with AsyncTreeship() as ts:
    result = await ts.attest(
        action="Processed request",
        inputs_hash=ts.hash(request_data)
    )
```

## Verification

```python
# Verify an attestation
result = ts.verify("attestation-id-here")
print(f"Valid: {result['valid']}")
```

## Documentation

- [Full Documentation](https://docs.treeship.dev)
- [API Reference](https://docs.treeship.dev/api-reference)

## License

MIT
