connector = client.connectors.create(
provider="slack",
name="acme-engineering",
database="acme_corp",
collection="company_docs",
provider_account_scope="T12345ACME",
credentials={"access_token": "xoxp-..."},
)
connector_id = connector.connector_id
const connector = await client.connectors.create({
provider: "slack",
name: "acme-engineering",
database: "acme_corp",
collection: "company_docs",
providerAccountScope: "T12345ACME",
credentials: { access_token: "xoxp-..." },
});
const connectorId = connector.connectorId;
curl -X POST 'https://api.hydradb.com/connectors' \
-H "Authorization: Bearer $HYDRADB_API_KEY" \
-H "API-Version: 2" \
-H "Content-Type: application/json" \
-d '{
"provider": "slack",
"name": "acme-engineering",
"database": "acme_corp",
"collection": "company_docs",
"provider_account_scope": "T12345ACME",
"credentials": {
"access_token": "xoxp-..."
}
}'
{
"connector_id": "{connector_id}",
"provider": "slack",
"name": "acme-engineering",
"database": "acme_corp",
"collection": "company_docs",
"provider_account_scope": "T12345ACME",
"lifecycle": "pending_setup",
"sync_status": "idle",
"enforce_acl": false,
"sync_interval_seconds": 3600,
"next_sync_at": "2026-06-01T12:05:00Z",
"first_sync_at": "2026-06-01T12:05:00Z",
"message": "Connector created. Configure resources to start syncing; the first scheduled sync runs in about 5 minutes."
}
Connectors
Create Connector
Store credentials for one provider account so its data can be synced.
POST
/
connectors
connector = client.connectors.create(
provider="slack",
name="acme-engineering",
database="acme_corp",
collection="company_docs",
provider_account_scope="T12345ACME",
credentials={"access_token": "xoxp-..."},
)
connector_id = connector.connector_id
const connector = await client.connectors.create({
provider: "slack",
name: "acme-engineering",
database: "acme_corp",
collection: "company_docs",
providerAccountScope: "T12345ACME",
credentials: { access_token: "xoxp-..." },
});
const connectorId = connector.connectorId;
curl -X POST 'https://api.hydradb.com/connectors' \
-H "Authorization: Bearer $HYDRADB_API_KEY" \
-H "API-Version: 2" \
-H "Content-Type: application/json" \
-d '{
"provider": "slack",
"name": "acme-engineering",
"database": "acme_corp",
"collection": "company_docs",
"provider_account_scope": "T12345ACME",
"credentials": {
"access_token": "xoxp-..."
}
}'
{
"connector_id": "{connector_id}",
"provider": "slack",
"name": "acme-engineering",
"database": "acme_corp",
"collection": "company_docs",
"provider_account_scope": "T12345ACME",
"lifecycle": "pending_setup",
"sync_status": "idle",
"enforce_acl": false,
"sync_interval_seconds": 3600,
"next_sync_at": "2026-06-01T12:05:00Z",
"first_sync_at": "2026-06-01T12:05:00Z",
"message": "Connector created. Configure resources to start syncing; the first scheduled sync runs in about 5 minutes."
}
Creates a connector for one provider account. Nothing syncs yet: next, call Discover Resources to see what the credentials can reach, then Configure Connector to choose resources and start the first sync.
connector = client.connectors.create(
provider="slack",
name="acme-engineering",
database="acme_corp",
collection="company_docs",
provider_account_scope="T12345ACME",
credentials={"access_token": "xoxp-..."},
)
connector_id = connector.connector_id
const connector = await client.connectors.create({
provider: "slack",
name: "acme-engineering",
database: "acme_corp",
collection: "company_docs",
providerAccountScope: "T12345ACME",
credentials: { access_token: "xoxp-..." },
});
const connectorId = connector.connectorId;
curl -X POST 'https://api.hydradb.com/connectors' \
-H "Authorization: Bearer $HYDRADB_API_KEY" \
-H "API-Version: 2" \
-H "Content-Type: application/json" \
-d '{
"provider": "slack",
"name": "acme-engineering",
"database": "acme_corp",
"collection": "company_docs",
"provider_account_scope": "T12345ACME",
"credentials": {
"access_token": "xoxp-..."
}
}'
{
"connector_id": "{connector_id}",
"provider": "slack",
"name": "acme-engineering",
"database": "acme_corp",
"collection": "company_docs",
"provider_account_scope": "T12345ACME",
"lifecycle": "pending_setup",
"sync_status": "idle",
"enforce_acl": false,
"sync_interval_seconds": 3600,
"next_sync_at": "2026-06-01T12:05:00Z",
"first_sync_at": "2026-06-01T12:05:00Z",
"message": "Connector created. Configure resources to start syncing; the first scheduled sync runs in about 5 minutes."
}
provider is any provider from List Connector Providers. The shape of credentials depends on the provider: read it from credential_schema by calling that endpoint with ?id={provider}.
Optional settings you can also pass here, and change later with Update Connector:
custom_instructions: guidance for how this connector’s synced sources are interpreted and indexed. See Custom ingestion instructions.sync_interval_seconds: how often scheduled syncs run. Omit it for the provider default (one hour for most providers).enforce_acl: whether content reads from this connector always enforce ACL for the authenticated caller. It defaults tofalsewhen omitted. Only workspace owners and writers in a signed-in dashboard session can set it, here, with Update Connector, or in the dashboard. API-key-authenticated requests must omit this field.truerequires the provider to reportacl_supported: true. See ACL on synced content for how caller identity and requestaclbehave.
Errors
400:providerordatabaseis missing, the provider is unknown, or a setting such assync_interval_secondsis out of range.402: your plan’s connector limit is reached.403: the provider is not available to your organization, or the request tries to setenforce_aclwithout a signed-in dashboard session for a workspace owner or writer. The ACL authorization error message isonly workspace owners and writers can change ACL enforcement.422:credentialsdoes not match the provider’scredential_schema.
Related resources
- Next: Discover Resources: see what the credentials can reach
- Next: Configure Connector: choose resources and start syncing
- List Connector Providers: the credential schema for a provider
- Connectors: Overview
Authorizations
Body
application/json
Connector configuration
Response
Created
Was this page helpful?
