Dagster & Airbyte OSS
Using this integration, you can trigger Airbyte syncs and orchestrate your Airbyte connections from within Dagster, making it easy to chain an Airbyte sync with upstream or downstream steps in your workflow.
note
For new projects, we recommend using the new Airbyte Workspace Component which provides a more streamlined configuration experience.
Installation
- uv
- pip
uv add dagster-airbyte
pip install dagster-airbyte
Example
from dagster_airbyte import AirbyteWorkspace, build_airbyte_assets_definitions
import dagster as dg
# Connect to your OSS Airbyte instance
airbyte_workspace = AirbyteWorkspace(
rest_api_base_url="http://localhost:8000/api/public/v1",
configuration_api_base_url="http://localhost:8000/api/v1",
workspace_id=dg.EnvVar("AIRBYTE_WORKSPACE_ID"),
# If using basic auth, include username and password:
username="airbyte",
password=dg.EnvVar("AIRBYTE_PASSWORD"),
)
# Load all assets from your Airbyte workspace
airbyte_assets = build_airbyte_assets_definitions(workspace=airbyte_workspace)
defs = dg.Definitions(
assets=airbyte_assets,
resources={"airbyte": airbyte_workspace},
)
Configuration
The AirbyteWorkspace resource requires both a REST API URL and Configuration API URL:
- REST API URL:
http(s)://<your-airbyte-host>/api/public/v1 - Configuration API URL:
http(s)://<your-airbyte-host>/api/v1
Authentication Methods
Basic Authentication
from dagster_airbyte import AirbyteWorkspace
import dagster as dg
airbyte_workspace = AirbyteWorkspace(
rest_api_base_url="http://localhost:8000/api/public/v1",
configuration_api_base_url="http://localhost:8000/api/v1",
workspace_id=dg.EnvVar("AIRBYTE_WORKSPACE_ID"),
username=dg.EnvVar("AIRBYTE_USERNAME"),
password=dg.EnvVar("AIRBYTE_PASSWORD"),
)