channels

Connect a surface — link-flow platforms return a pending connect ceremony [write]

Changed on

telegram/imessage/whatsapp/x/lark/gchat mint a connect ceremony (hosted page or deep link + code) the end user claims in-platform. Slack/Discord with destination.webhook return a LINK ceremony; other Slack/Discord flows create a channel synchronously. Pass app for BYO; callback_url (link flows) redirects the hosted connect page to you after the claim.

post/channels/connections

Request

  • Base URL
    https://api.agentsky.dev/v1
  • URL
    https://api.agentsky.dev/v1/channels/connections
  • Auth
    HTTP bearer

Request body

platform'telegram' | 'slack' | 'discord' | 'whatsapp' | 'imessage' | 'email' | 'teams' | 'x' | 'lark' | 'buzz' | 'gchat' | 'line' | 'loopback' required
labelstring
metadataobject

Echoed on channel.connected and the callback redirect

appstring

BYO ChannelApp id — the connect ceremony runs on your bot/number

invite_userstring

Slack only: user id to invite into the created channel

callback_urlstring

Link-flow platforms only: the hosted connect page redirects here after the claim with connection_id, status, and metadata query params

Response

Created

idstring
platformstring
channel_idstring nullable
thread_idstring

Present after administrative adoption; the existing app-scoped reply address

labelstring
status'PENDING' | 'CONNECTED' | 'DISCONNECTED'
created_atstring date-time

Changes