---
title: "Create Connection"
method: POST
path: "/poweredby/connection/create"
tags: ["Connection"]
---

# Create Connection

`POST /poweredby/connection/create`

Create Connection requests the Connection Create Flow from the Connect AI Embed product. Create Connection validates the JWT and returns a string containing the URL to redirect the user to. If you include the parameter `dataSource`, the URL redirects the user to an **Add Connection** page for the data source. If you omit `dataSource`, the URL redirects the user to a general **Add Connection** page where the user can select a connection to add from the connections list.

## Request body

- CreateConnectionRequest
  - `dataSource` string, nullable — (Optional) The type of data source (For example: Snowflake, ActOn, or Salesforce). You can obtain data source names from List Connections. If you omit this parameter, the user can select from a list of available data sources.
  - `redirectURL` string, required — The URL to redirect the customer once the customer has created the connection through the Connect AI UI. This URL maps to the **Return to** button on the **Add Connection** page in the Connect AI UI.
  - `name` string, nullable — (Optional) If provided, the connection name. By default, this is a suggested default that the end user can change on the **Add Connection** form. Set `editableName` to `false` to lock the field to this value. If `name` is provided without a `dataSource`, it is ignored.
  - `externalId` string, nullable — (Optional) Your identifier for this connection in your own system. Must be unique within the sub-account; if a connection with the same `externalId` already exists under the account, the request returns a conflict error.
  - `editableName` boolean — (Optional) The default value is `true`. When `true`, any `name` you supply is shown as a suggested default value, and the end user can change it. When `false`, the **Connection Name** field is rendered read-only, and the server enforces the supplied `name` on submit. Has no effect when `name` is omitted.

## Response `200`

A string containing the CData-hosted connection URL to redirect the user to.

- RedirectURLResponse
  - `redirectURL` string, required — A string containing the CData-hosted connection URL to redirect the user to.

---

[API](https://skmtc.net/cdata/apis/cdata-connect-ai-rest-api-embedded.md) · [All operations](https://skmtc.net/cdata/apis/cdata-connect-ai-rest-api-embedded/llms.txt) · [OpenAPI document](https://skmtc-service-staging.skmtc.workers.dev/v1/apis/cdata/cdata-connect-ai-rest-api-embedded/versions/c13133ad66c0/schema)
