Skip to main content
POST
/
v1
/
projects
/
{projectId}
/
connections
curl --request POST \
  --url https://eu1.api.matillion.com/dpc/v1/projects/{projectId}/connections \
  --header 'Authorization: Bearer <token>' \
  --header 'Content-Type: application/json' \
  --data '
{
  "name": "my-aws-connection",
  "platformConnectionType": "CLOUD_PLATFORM_CREDENTIALS",
  "authProvider": "aws",
  "authType": "CLOUD_PROVIDER_SECRET",
  "connectionDetails": {
    "description": "AWS credentials for the analytics environment",
    "secretsLocation": {
      "type": "AWS_SECRET_MANAGER",
      "region": "us-east-1"
    },
    "connectionProperties": {
      "credentialSecretName": "aws-platform-credentials"
    }
  }
}
'
{
  "id": "550e8400-e29b-41d4-a716-446655440010",
  "name": "my-aws-connection",
  "platformConnectionType": "CLOUD_PLATFORM_CREDENTIALS",
  "authProvider": "aws",
  "authType": "CLOUD_PROVIDER_SECRET",
  "createdBy": "550e8400-e29b-41d4-a716-446655440001",
  "createdDate": "2024-01-15T10:30:00.123Z",
  "projectId": "550e8400-e29b-41d4-a716-446655440002",
  "connectionDetails": {
    "description": "AWS credentials for the analytics environment",
    "secretsLocation": {
      "type": "AWS_SECRET_MANAGER",
      "region": "us-east-1"
    },
    "connectionProperties": {
      "credentialSecretName": "aws-platform-credentials"
    }
  }
}

Authorizations

Authorization
string
header
required

a valid bearer token

Path Parameters

projectId
string
required

The unique identifier of the project where the connection will be created

Pattern: ^[0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12}$

Body

application/json

The parameters platformConnectionType, authProvider and authType are inter-dependent. The valid combinations are:

platformConnectionTypeauthProviderauthTypeUse this for
COMPONENT_BASICNONEGENERIC_SECRETCreating simple secret definitions
COMPONENT_BASIC(connector name e.g. salesforce)OAUTH_CLIENT_CRED, OAUTH_USER_TOKENS, OAUTH_AUTHORIZATION_CODEOAuth secrets stored for the named provider
COMPONENT_BASICnetsuiteCOMPOSITE_TOKENCreating NetSuite composite-token secrets
COMPONENT_BASICx-adsOAUTH_1_0_X_ADSCreating X Ads OAuth 1.0 secrets
CLOUD_PLATFORM_CREDENTIALSawsCLOUD_PROVIDER_SECRETCreating AWS cloud credentials
CLOUD_PLATFORM_CREDENTIALSgcpCLOUD_PROVIDER_SECRETCreating GCP cloud credentials
CLOUD_PLATFORM_CREDENTIALSazureCLOUD_PROVIDER_SECRETCreating AZURE cloud credentials

The connection creation request containing all necessary details

authType
enum<string>
required

The kind of secret being referenced. See the combinations table in the operation description for valid values per connection type.

Available options:
GENERIC_SECRET,
CLOUD_PROVIDER_SECRET,
OAUTH_USER_TOKENS,
OAUTH_AUTHORIZATION_CODE,
OAUTH_CLIENT_CRED,
COMPOSITE_TOKEN,
OAUTH_1_0_X_ADS
Example:

"GENERIC_SECRET"

name
string
required

The name of the connection

Minimum string length: 1
Example:

"my-secret"

platformConnectionType
enum<string>
required

The different types of connection that can be created:

  • COMPONENT_BASIC — connect a component to a data source, API, or SaaS application using a secret stored in your secrets manager.
  • CLOUD_PLATFORM_CREDENTIALS — give a project access to a cloud provider (AWS, Azure, GCP) using cloud credentials stored in your secrets manager.
Available options:
COMPONENT_BASIC,
CLOUD_PLATFORM_CREDENTIALS
Example:

"COMPONENT_BASIC"

authProvider
string

The authentication provider

Example:

"salesforce"

connectionDetails
object

Provides the definition of the values of the connection which will vary by connection type. Includes:

  • Location of any sensitive values (secret location and name)
  • Any non-sensitive values (url, username)

Response

Connection created successfully

authProvider
string

The authentication provider

Example:

"salesforce"

authType
enum<string>

The authentication type

Available options:
GENERIC_SECRET,
CLOUD_PROVIDER_SECRET,
OAUTH_USER_TOKENS,
OAUTH_AUTHORIZATION_CODE,
OAUTH_CLIENT_CRED,
COMPOSITE_TOKEN,
OAUTH_1_0_X_ADS
Example:

"GENERIC_SECRET"

connectionDetails
object

Provides the definition of the values of the connection which will vary by connection type. Includes:

  • Location of any sensitive values (secret location and name)
  • Any non-sensitive values (url, username)
createdBy
string

The user who created the connection

createdDate
string<date-time>

The date and time when the connection was created

name
string

The name of the connection

Example:

"my-secret"

platformConnectionType
enum<string>

The different types of connection that can be created:

  • COMPONENT_BASIC — connect a component to a data source, API, or SaaS application using a secret stored in your secrets manager.
  • CLOUD_PLATFORM_CREDENTIALS — give a project access to a cloud provider (AWS, Azure, GCP) using cloud credentials stored in your secrets manager.
Available options:
COMPONENT_BASIC,
CLOUD_PLATFORM_CREDENTIALS
Example:

"COMPONENT_BASIC"

projectId
string<uuid>

The project ID this connection belongs to