connections

Create a warehouse connection.

Registers a connection's non-secret metadata. For service_* auth methods the connection is created in an unconfigured state — credential material is attached separately by the credential broker and is never accepted or echoed here. For oauth_passthrough, per-user grants are collected later via the OAuth consent flow. Admin or above.

post/v1/connections

Request

  • Base URL: http://localhost:8080
  • URL: http://localhost:8080/v1/connections
  • Auth: one of:
    • API key in cookie dvt_session
    • HTTP bearer

Request body

namestring required

Connection slug — unique within the org; used as the sourceId alias in specs.

type'snowflake' | 'bigquery' | 'databricks_sql' | 'redshift' | 'postgres' | 'mysql' | 'sqlite' | 'parquet_s3' | 'csv' | 'google_sheets' required
authMethod'service_secret' | 'service_keypair' | 'oauth_passthrough' | 'cloud_iam' | 'spcs_token' required

spcs_token (secretless: the engine reads an SPCS-injected OAuth token from a file) is accepted only when the server runs as a Snowflake Native App (DVT_MODE=snowflake); rejected with 400 on any other deployment.

kind'pushdown' | 'writeback'

Connection kind (ADR-0031 D2). Defaults to pushdown when omitted. writeback opts into the write path — provision a dedicated write-role credential scoped to dvt_writeback only. Immutable after creation.

configobject

Non-secret connection parameters (account, warehouse, database, schema, project, region). Never credentials.

Response

Connection created.

Changes

No recorded changes to this operation across all 1 revision of this API.