Metadata-Version: 2.4
Name: aurarouter-claude
Version: 0.5.1
Summary: Anthropic Claude provider for AuraRouter — exposes Claude models as an MCP provider server.
Author: AuraCore Dynamics Inc.
License-Expression: Apache-2.0
Keywords: aurarouter,claude,anthropic,mcp,llm
Classifier: Development Status :: 4 - Beta
Classifier: Programming Language :: Python :: 3
Classifier: Programming Language :: Python :: 3.12
Classifier: Programming Language :: Python :: 3.13
Requires-Python: >=3.12
Description-Content-Type: text/markdown
License-File: LICENSE
Requires-Dist: anthropic>=0.40
Requires-Dist: mcp[cli]
Dynamic: license-file

# aurarouter-claude

Anthropic Claude provider for [AuraRouter](https://github.com/auracore-dynamics/aurarouter) -- exposes Claude models as an MCP provider server.

## Installation

```bash
pip install aurarouter-claude
```

## Usage

### As an MCP server (standalone)

```bash
python -m aurarouter_claude
```

### With AuraRouter

Once installed, AuraRouter automatically discovers this package via the `aurarouter.providers` entry point. Configure it in `auraconfig.yaml`:

```yaml
provider_catalog:
  manual:
    - name: claude
      endpoint: http://localhost:9100
```

### Provider Metadata Discovery

The package exposes `get_provider_metadata()` returning typed `ProviderMetadata` when `aurarouter` is installed, or a plain dictionary fallback when introspected independently:

```python
from aurarouter_claude import get_provider_metadata

metadata = get_provider_metadata()
```

## Configuration

Set your Anthropic API key via environment variable:

```bash
export ANTHROPIC_API_KEY=sk-ant-...
```

## Available Models

| Model | Context Window | Input Cost | Output Cost |
|-------|---------------|------------|-------------|
| Claude Opus 4 | 200k | $15.00/1M | $75.00/1M |
| Claude Sonnet 4 | 200k | $3.00/1M | $15.00/1M |
| Claude Haiku 4.5 | 200k | $0.80/1M | $4.00/1M |

## AuraRouter v2.1 Telemetry & Resilience

- **Cross-MCP RateLimit Envelopes**: Parses and forwards Anthropic split request and token rate-limit headers (`anthropic-ratelimit-requests-*`, `anthropic-ratelimit-tokens-*`) to the central GCRA tracker.
- **Fault Isolation**: Maps Anthropic HTTP 529 overloads and transient API errors to `ProviderTransientError`, triggering AuraRouter's circuit breakers without false-positive rate limit penalties.
- **Header Sanitization**: Redacts sensitive authorization tokens from MCP trace telemetry.
- **Canary Suite**: Includes `@pytest.mark.live_vendor` canaries with strict token caps (`max_tokens=16`) to verify live Anthropic platform readiness.

## License

Apache-2.0
