Skip to content

Python SDK Configuration

This page covers all configuration options for the SideSeat Python SDK.

SideSeat(
# Connection
endpoint: str | None = None,
project_id: str | None = None,
api_key: str | None = None,
# Framework
framework: str | None = None,
auto_instrument: bool = True,
# Service identity
service_name: str | None = None,
service_version: str | None = None,
# Telemetry signals
enable_traces: bool = True,
enable_metrics: bool = True,
enable_logs: bool = False,
# Content capture
capture_content: bool = True,
encode_binary: bool = True,
# Control
disabled: bool = False,
debug: bool = False,
)

SideSeat server URL.

# Default
client = SideSeat() # Uses http://127.0.0.1:5388
# Custom endpoint
client = SideSeat(endpoint="http://sideseat.example.com:5388")

Project identifier for organizing traces.

client = SideSeat(project_id="my-project")

Authentication key for the SideSeat server.

client = SideSeat(api_key="pk-your-api-key")

Explicitly select a framework to instrument.

from sideseat import SideSeat, Frameworks
client = SideSeat(framework=Frameworks.LangGraph)

Available frameworks:

  • Frameworks.Strands
  • Frameworks.LangGraph
  • Frameworks.LangChain
  • Frameworks.CrewAI
  • Frameworks.AutoGen
  • Frameworks.OpenAIAgents
  • Frameworks.GoogleADK
  • Frameworks.PydanticAI

If not specified, the SDK auto-detects in this order:

  1. Strands (strands-agents)
  2. LangChain / LangGraph (langchain-core)
  3. CrewAI (crewai)
  4. AutoGen (autogen-agentchat)
  5. OpenAI Agents (agents)
  6. Google ADK (google-adk)
  7. PydanticAI (pydantic-ai)

Enable automatic framework instrumentation.

# Auto-instrument (default)
client = SideSeat(auto_instrument=True)
# Skip instrumentation
client = SideSeat(auto_instrument=False)

Override the auto-detected service name.

# Auto-detect (default)
client = SideSeat()
# Explicit name
client = SideSeat(service_name="my-agent")

Set the service version for resource attributes.

client = SideSeat(
service_name="my-agent",
service_version="1.2.3"
)

Enable trace span export.

client = SideSeat(enable_traces=True) # Default

Enable metrics export.

client = SideSeat(enable_metrics=True) # Default

Enable log export.

client = SideSeat(enable_logs=False) # Default

Capture LLM prompts and responses.

# Capture content (default)
client = SideSeat(capture_content=True)
# Disable for privacy
client = SideSeat(capture_content=False)

Base64 encode binary data in spans.

# Encode binary (default)
client = SideSeat(encode_binary=True)
# Leave as-is (may cause export errors)
client = SideSeat(encode_binary=False)

Disable all telemetry.

# Disabled mode
client = SideSeat(disabled=True)

Useful for testing or CI environments.

Enable verbose logging.

client = SideSeat(debug=True)

The SDK respects these environment variables:

VariableDefaultDescription
SIDESEAT_ENDPOINThttp://127.0.0.1:5388Server URL
SIDESEAT_PROJECTdefaultProject identifier
SIDESEAT_API_KEYAuthentication key
SIDESEAT_DISABLEDfalseDisable all telemetry
SIDESEAT_DEBUGfalseEnable verbose logging

Standard OpenTelemetry variables are also supported:

VariableDescription
OTEL_SERVICE_NAMEOverride service name
OTEL_EXPORTER_OTLP_ENDPOINTDefault OTLP endpoint
OTEL_EXPORTER_OTLP_HEADERSDefault headers (comma-separated)
OTEL_EXPORTER_OTLP_TIMEOUTRequest timeout

Settings are resolved in this order (highest to lowest):

  1. Constructor parameters
  2. SIDESEAT_* environment variables
  3. OTEL_* environment variables
  4. Defaults
from sideseat import SideSeat, Frameworks
# Full configuration
client = SideSeat(
# Connection
endpoint="http://localhost:5388",
project_id="my-project",
api_key="pk-xxx",
# Framework
framework=Frameworks.LangGraph,
auto_instrument=True,
# Service identity
service_name="my-agent",
service_version="1.0.0",
# Telemetry signals
enable_traces=True,
enable_metrics=True,
enable_logs=False,
# Content capture
capture_content=True,
encode_binary=True,
# Control
disabled=False,
debug=False,
)
# Add debug exporters
client.telemetry.setup_file_exporter("traces.jsonl")
# Your agent code here...
# Explicit shutdown (or let atexit handle it)
client.shutdown()