Skip to main content
The OpenAI Agents SDK reads OPENAI_API_KEY from the environment by default. Authsome supplies it either through the proxy (recommended) or through export.
authsome login openai
authsome run -- python my_agent.py
The Agents SDK initializes with OPENAI_API_KEY=authsome-proxy-managed. Outbound requests to api.openai.com are intercepted and authenticated at the proxy layer. The agent’s process never sees the real key.

Alternative: export into the environment

eval "$(authsome export openai --format env)"
python my_agent.py

Multi-account workflows

authsome login openai --connection personal
authsome login openai --connection team
eval "$(authsome export openai --connection team --format env)"

Tools that hit other providers

The Agents SDK supports tools that call external APIs. Each tool typically reads its own credential. Authsome covers both bundled (OpenAI, GitHub, etc.) and custom (see Custom providers). For an MCP-style tool that calls api.github.com, just log in once: authsome login github. The proxy will inject the GitHub token automatically when the tool makes its request.

What’s next

OpenAI integration

Set up the underlying OpenAI key.

Run agents with the proxy

The injection model in detail.