Metadata-Version: 2.4
Name: contextwall-sdk
Version: 0.1.1
Summary: ContextWall SDK - drop-in wrapper for Anthropic and OpenAI with context firewall enforcement
Author-email: Context Firewall <sumesh.punakkal@gmail.com>
License: Apache-2.0
Keywords: ai,anthropic,context-firewall,governance,openai,security
Requires-Python: >=3.11
Requires-Dist: httpx>=0.27
Requires-Dist: pydantic>=2.0
Provides-Extra: all
Requires-Dist: anthropic>=0.25; extra == 'all'
Requires-Dist: openai>=1.0; extra == 'all'
Provides-Extra: anthropic
Requires-Dist: anthropic>=0.25; extra == 'anthropic'
Provides-Extra: dev
Requires-Dist: anthropic>=0.25; extra == 'dev'
Requires-Dist: httpx>=0.27; extra == 'dev'
Requires-Dist: openai>=1.0; extra == 'dev'
Requires-Dist: pytest-asyncio>=0.24; extra == 'dev'
Requires-Dist: pytest>=8.0; extra == 'dev'
Provides-Extra: openai
Requires-Dist: openai>=1.0; extra == 'openai'
Description-Content-Type: text/markdown

# contextwall-sdk

Drop-in wrapper for Anthropic and OpenAI that routes calls through a local [ContextWall](https://contextwall.io) daemon, enforcing your context firewall policy with no other code changes.

## Install

```bash
pip install 'contextwall-sdk[anthropic]'
pip install 'contextwall-sdk[openai]'
pip install 'contextwall-sdk[all]'
```

## Usage

```python
from contextwall_sdk import SafeAnthropic

client = SafeAnthropic(api_key="sk-ant-...", ctxfw_url="http://localhost:8080")
# use exactly like the standard Anthropic client
```

```python
from contextwall_sdk import SafeOpenAI

client = SafeOpenAI(api_key="sk-...", ctxfw_url="http://localhost:8080")
```

Blocked requests raise `contextwall_sdk.ContextWallBlockedError` with the policy violation detail.

## Daemon setup

The SDK requires a running ContextWall daemon. See the [quickstart](https://contextwall.io/quickstart) or the [GitHub repo](https://github.com/bytewise-ca/context-wall).
