Skip to main content
  1. Sign up — Create an account at platform.respan.ai
  2. Create an API key — Generate one on the API keys page
  3. Add credits or a provider key — Add credits on the Credits page or connect your own provider key on the Integrations page
Add the Docs MCP to your AI coding tool to get help building with Respan. No API key needed.
{
  "mcpServers": {
    "respan-docs": {
      "url": "https://respan.ai/docs/mcp"
    }
  }
}

What is Superagent?

Superagent is a safety guardrails platform that provides guard, redact, scan, and test operations for LLM applications. The Respan exporter wraps these calls to capture them as tool spans.

Setup

1

Install packages

pip install safety-agent respan-exporter-superagent
2

Set environment variables

export RESPAN_API_KEY="YOUR_RESPAN_API_KEY"
3

Use the Respan client

from respan_exporter_superagent import create_client

# Create a Respan-instrumented Superagent client
client = create_client(api_key="your-api-key")

# Operations are automatically traced
result = await client.guard(
    respan_params={"customer_identifier": "user-123"},
    input="Check this content for safety",
)
print(result)
4

View your trace

Open the Traces page to see your safety operations.

Configuration

ParameterTypeDefaultDescription
api_keystrRESPAN_API_KEY env varRespan API key.
base_urlstr | NoneNoneAPI base URL.
See the Superagent Exporter SDK reference for the full API.

Attributes

Pass Respan-specific params to each operation:
result = await client.guard(
    respan_params={
        "customer_identifier": "user-123",
        "metadata": {"source": "api", "version": "2.0"},
    },
    input="Check this content",
)
AttributeDescription
customer_identifierUser/customer identifier.
metadataCustom key-value pairs.
disable_logSet True to skip logging this call.