Skip to main content
POST
Create a connect link

Authorizations

x-api-key
string
header
required

Your workspace API key. Create one in Settings → API Keys; the plaintext value is shown once and never again.

Keys are scoped. A key needs conversations:send to send, conversations:read to read threads and messages, templates:read to list templates, channels:read to list channels, and channels:manage to create connect sessions. A key missing the scope for an endpoint gets 403.

The CRM endpoints use the same resource:action form: leads:read, leads:create, leads:update, leads:delete, customers:read, customers:create, customers:update, customers:delete, customers:manage.

Several resources have no scope of their own and borrow one:

Grant only what the integration needs — a key that only sends notifications should hold conversations:send and nothing else.

X-Tenant-Id
string
header
required

Your workspace UUID. Required on every request in addition to x-api-key.

It does not select the workspace — data access is always scoped to the workspace that owns the API key, and a mismatched value cannot read anyone else's data.

Body

application/json
platform
enum<string>
required

Which channel the popup connects. facebook is Messenger. whatsapp_qr links a number as a WhatsApp Web linked device, by QR scan or pairing code.

Available options:
whatsapp,
whatsapp_qr,
facebook,
instagram,
tiktok
channelName
string

whatsapp_qr only: the channel's display name. Defaults to the linked number, e.g. +201001234567.

Maximum string length: 100
origin
string<uri>

Origin of the window that opens the popup, e.g. https://app.example.com. The result is sent with postMessage to window.opener at exactly this origin.

redirectUri
string<uri>

Where the popup goes when there is no opener window to notify. Receives ?sessionId=…&status=…&channelId=…&state=….

state
string

Your own reference, echoed back in every result. Never interpreted.

Maximum string length: 512
locale
enum<string>
default:en

Language of the hosted page.

Available options:
en,
ar

Response

The session, with the link to open.

connectUrl
string<uri>
required

Open this in a popup. The token is in the fragment, so it never reaches a server log.

Example:

"https://crm.linkiasoft.com/connect#token=cst_..."

id
string<uuid>
platform
enum<string>
Available options:
whatsapp,
whatsapp_qr,
facebook,
instagram,
tiktok
status
enum<string>

expired means the 30-minute link ran out before the person finished.

Available options:
pending,
connected,
cancelled,
expired
channelId
string<uuid> | null

Set once status is connected. Use it as channelId elsewhere in this API.

channelName
string | null
state
string | null

The state you sent, unchanged.

createdAt
string<date-time>
expiresAt
string<date-time>

When the link stops working.

completedAt
string<date-time> | null