v1

latestOpenAPI 3.1.02026-07-22106199311.5 KB
Connections

Create a new project connection

Creates a new connection within the specified project. Where a connection requires sensitive information such as a password or authorisation code, that must be created in the relevant secret vault prior to creating a connection. The name of that secret (and, where relevant, key within the secret) is then passed as part of the connection configuration.

For an example of how to use this endpoint as part of automating the provisioning and management of projects, see https://docs.maia.ai/docs/api-reference/provisioning-a-project

post/v1/projects/{projectId}/connections

Path parameters

projectIdstring required

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

Request body

authProviderstring

The authentication provider

authType'GENERIC_SECRET' | 'CLOUD_PROVIDER_SECRET' | 'OAUTH_USER_TOKENS' | 'OAUTH_AUTHORIZATION_CODE' | 'OAUTH_CLIENT_CRED' | 'COMPOSITE_TOKEN' | 'OAUTH_1_0_X_ADS' required

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

namestring required

The name of the connection

platformConnectionType'COMPONENT_BASIC' | 'CLOUD_PLATFORM_CREDENTIALS' 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.

Example request

{
  "authProvider": "salesforce",
  "authType": "GENERIC_SECRET",
  "connectionDetails": {
    "connectionProperties": {
      "credentialSecretName": "aws-platform-credentials"
    }
  },
  "name": "my-secret",
  "platformConnectionType": "COMPONENT_BASIC"
}

Response

Connection created successfully

authProviderstring

The authentication provider

authType'GENERIC_SECRET' | 'CLOUD_PROVIDER_SECRET' | 'OAUTH_USER_TOKENS' | 'OAUTH_AUTHORIZATION_CODE' | 'OAUTH_CLIENT_CRED' | 'COMPOSITE_TOKEN' | 'OAUTH_1_0_X_ADS'

The authentication type

createdBystring

The user who created the connection

createdDatestring date-time

The date and time when the connection was created

namestring

The name of the connection

platformConnectionType'COMPONENT_BASIC' | 'CLOUD_PLATFORM_CREDENTIALS'

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.
projectIdstring uuid

The project ID this connection belongs to

Example response

{
  "authProvider": "salesforce",
  "authType": "GENERIC_SECRET",
  "connectionDetails": {
    "connectionProperties": {
      "credentialSecretName": "aws-platform-credentials"
    }
  },
  "name": "my-secret",
  "platformConnectionType": "COMPONENT_BASIC"
}