Skip to main content

ChatGPT (Codex) OAuth transport for Axio using Responses API

Project description

axio-transport-codex

PyPI Python License: MIT

ChatGPT OAuth transport for axio using the OpenAI Responses API.

Authenticates via the same OAuth flow used by ChatGPT — no API key required; your ChatGPT subscription covers usage. Implements the OpenAI Responses API (not the legacy completions endpoint).

Features

  • No API key — authenticates with your ChatGPT account via OAuth
  • Responses API — uses OpenAI's newer stateful Responses endpoint
  • Full streaming — incremental text and tool-call events via SSE
  • Tool calling — works with all axio tool handlers
  • aiohttp-based — non-blocking I/O throughout

Installation

pip install axio-transport-codex

Usage

from axio.agent import Agent
from axio.context import MemoryContextStore
from axio_transport_codex import CodexTransport

transport = CodexTransport(
    api_key="your-chatgpt-oauth-token",
)

agent = Agent(system="You are a helpful assistant.", tools=[], transport=transport)

async def main() -> None:
    ctx = MemoryContextStore()
    async for event in agent.run_stream("Summarise the Rust ownership model", ctx):
        from axio.events import TextDelta
        if isinstance(event, TextDelta):
            print(event.delta, end="", flush=True)
    print()

Plugin registration

[project.entry-points."axio.transport"]
codex = "axio_transport_codex:CodexTransport"

Part of the axio ecosystem

axio · axio-transport-openai · axio-tui

License

MIT

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

axio_transport_codex-0.5.0.tar.gz (88.7 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

axio_transport_codex-0.5.0-py3-none-any.whl (13.6 kB view details)

Uploaded Python 3

File details

Details for the file axio_transport_codex-0.5.0.tar.gz.

File metadata

  • Download URL: axio_transport_codex-0.5.0.tar.gz
  • Upload date:
  • Size: 88.7 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.12

File hashes

Hashes for axio_transport_codex-0.5.0.tar.gz
Algorithm Hash digest
SHA256 d698011975bca383dde5e8c803f45794f61f7b222ee905de72dc35e8490b45bf
MD5 96be6ee151998778fcb90bb53e7118d1
BLAKE2b-256 ce558ac560cedc850f0953bc3b64f4c23db0f118c200991eff42017e4704e6d3

See more details on using hashes here.

Provenance

The following attestation bundles were made for axio_transport_codex-0.5.0.tar.gz:

Publisher: publish.yml on axio-agent/monorepo

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file axio_transport_codex-0.5.0-py3-none-any.whl.

File metadata

File hashes

Hashes for axio_transport_codex-0.5.0-py3-none-any.whl
Algorithm Hash digest
SHA256 487efa69ee5e5130d2673c65b58d7212138b2763d48818cb549accd7e4ea23e8
MD5 ade0c9ab394614bd353161c1c4a70075
BLAKE2b-256 b41ca17cc0199afd00d1938503ad6694a988968b4d6526e5add525c2613d5afa

See more details on using hashes here.

Provenance

The following attestation bundles were made for axio_transport_codex-0.5.0-py3-none-any.whl:

Publisher: publish.yml on axio-agent/monorepo

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page