SDK
The Airbyte Agents Python SDK (airbyte_agent_sdk) is the Python front door to Airbyte Agents. With one install you get typed connectors, automatic credential handling, direct execution, and patterns for exposing connectors as tools to AI agent frameworks.
This section walks through the three operations most apps need: authenticate, add a connector, and execute operations. Deeper class and method signatures live in the SDK reference.
Choose your interface
You can use Airbyte Agents programmatically two ways:
- SDK: a typed Python library. Best for Python apps, notebooks, scripts, and AI agents.
- API: an HTTP API. Best for non-Python backends and languages the SDK doesn't cover.
Most Airbyte Agents operations are available through both interfaces. Where the SDK can't do something directly, use the API. Pages in the SDK section flag this explicitly.
Log in and sign up
Log in or sign up at app.airbyte.ai.
Install
Add the SDK to a uv-managed project:
uv add airbyte-agent-sdk
To install into an existing virtual environment instead, run uv pip install airbyte-agent-sdk.
The install name uses dashes. The Python import name uses underscores: from airbyte_agent_sdk import Workspace, connect.
End-to-end example
The example below authenticates with Airbyte, adds a GitHub connector, and executes an operation against it. The pages in this section explain each step in detail.
import asyncio
from airbyte_agent_sdk import Workspace, connect
async def main():
# Authenticate. The SDK reads AIRBYTE_CLIENT_ID and AIRBYTE_CLIENT_SECRET
# from the environment.
async with Workspace() as ws:
# Add a connector.
await ws.create_connector(
definition_id="<github_definition_id>",
name="My GitHub Connector",
credentials={
"option_title": "PAT Credentials",
"personal_access_token": "<github_pat>",
},
replication_config={"repositories": ["airbytehq/airbyte"]},
)
# Execute an operation against the connector. `connect()` resolves the
# connector by its slug within the current workspace — no ID needed
# when the workspace has one connector of this type.
github = connect("github")
try:
# Parameter names are connector- and entity-specific. Call
# `github.list_entities()` to see what each entity accepts.
result = await github.execute("issues", "list", params={"per_page": 10})
for row in result.data:
print(row)
finally:
await github.close()
asyncio.run(main())
Learn more
Authenticate
The SDK authenticates with Airbyte Agents using an Airbyte clientid and clientsecret. Once the SDK has these, it handles the rest: fetching tokens, refreshing them before they expire, and attaching them to every request. You never manage tokens yourself.
Add a connector
<!--
Execute operations
Once you've added a connector to your workspace, you can run operations against it from Python. The SDK offers direct execution and patterns for exposing a connector as a tool to an AI agent framework.
Manage workspaces
A workspace is a container inside your Airbyte Agents organization that holds a set of connectors and credentials. A token scoped to one workspace can't reach another.