Skip to content

directus-labs/airbyte

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

1 Commit
 
 
 
 

Repository files navigation

Directus Airbyte Connector

Declarative Airbyte source for Directus. Sync CMS content, files, users, activity, and collection metadata from your Directus instance into any Airbyte destination (BigQuery, Snowflake, Postgres, S3, and more).

Built with the Airbyte Connector Builder — no custom Python connector required. The manifest lives in Airbyte.yaml.

Streams

Stream API Description
collection_items GET /items/{collection} Records from one collection (posts, products, pages, etc.)
files GET /files File library assets
users GET /users User accounts (PII — enable only if needed)
activity GET /activity Audit log
collections_meta GET /collections Collection schema metadata

Connection test uses the files stream.

Prerequisites

  • A Directus project (Cloud or self-hosted)
  • A static API token with read access to the data you plan to sync (Settings → Access Tokens)
  • An Airbyte workspace (Cloud or self-hosted) with Connector Builder access

Quick start

  1. Clone this repository (or copy Airbyte.yaml).

  2. In Airbyte, open Connector Builder → create or import a custom source.

  3. Paste the contents of Airbyte.yaml into the manifest editor (or import from your fork).

  4. Configure the source:

    Field Required Example
    API Key Yes Your static token
    Base URL Yes https://your-project.directus.app
    Collection Name Yes posts
  5. Test connection, then create a connection to your destination.

  6. Enable only the streams you need (files, collection_items, etc.).

Multiple collections

Use one Airbyte source per collection (same URL and token, different Collection Name).

Files-only sync

You still need Collection Name in the form (any slug your token can read). Disable the collection_items stream on the connection.

Optional configuration

These map to Directus query parameters on every enabled stream.

Field Example Purpose
Start Date 2026-06-01 Records on or after this date (YYYY-MM-DD or full ISO)
Fields id,title,status,date_updated Limit returned columns
Filter {"status":{"_eq":"published"}} Directus JSON filter
Sort -date_updated Sort order (- = descending)
Search hero Text search

Start Date applies per stream:

  • filesuploaded_on
  • collection_itemsdate_updated
  • activitytimestamp

Not applied to users or collections_meta. Date-only values (e.g. 2026-06-01) are normalized to UTC midnight before the API call.

Repository layout

File Purpose
Airbyte.yaml Connector manifest — import this into Airbyte
docs.md End-user setup guide (for your docs site or internal use)
test.md Example values and QA test scenarios
publish.md Connector & contribution descriptions for publishing

Permissions

Your token’s role needs read access for each stream you enable:

Stream Access
collection_items Read on the target collection
files Read files
users Read users
activity Read activity (often requires elevated permissions)
collections_meta Read collections

A 403 on a stream usually means adjusting the role or disabling that stream.

Troubleshooting

Issue Check
Connection test fails Base URL has no trailing slash; token is valid; token can read files
collection_items 404 Collection slug is exact (case-sensitive)
Start Date seems ignored Confirm the record’s uploaded_on / date_updated / timestamp in the API response
Old files still appear Files filter uses uploaded_on, not UI labels; verify with GET /files?filter[uploaded_on][_gte]=...

Learn more

Contributing

Issues and pull requests are welcome. When changing the manifest, re-test in Connector Builder (files connection test and any streams you modified). Update docs.md and test.md if configuration behavior changes.

License

License TBD — add a LICENSE file when you publish the repository.

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors