跳转到主要内容
POST
Connect a platform with its credentials

请求规范

  • 方法与路径: POST /apis/v1/social/messaging/connect/{platform}/credentials
  • 可用状态: enabled
  • 请求 URL 模板: https://api.aisa.one/apis/v1/social/messaging/connect/{platform}/credentials
  • platform: path; 必填
完整 OpenAPI 定义 有效请求声明(包括认证和引用的 schema):

费用与请求规则

此操作不另收费。

授权

Authorization
string
header
必填

Bearer authentication header of the form Bearer <token>, where <token> is your auth token.

路径参数

platform
string
必填

请求体

application/json

The members each platform needs: whatsapp: accessToken, wabaId, phoneNumberId. They are passed to the platform's integration once; AIsa neither stores nor returns them.

accessToken
string

WhatsApp: a permanent system user access token with the whatsapp_business_management and whatsapp_business_messaging permissions.

Minimum string length: 1
phoneNumberId
string

WhatsApp: the phone number id of the number to connect.

Minimum string length: 1
pin
string

WhatsApp: the six-digit two-step verification PIN of the number, when it has one.

Minimum string length: 1
profileId
string

Your social profile (prf_...); the default profile when omitted.

Pattern: ^prf_[0-9A-Za-z]+$
wabaId
string

WhatsApp: the WhatsApp Business Account id.

Minimum string length: 1

响应

Success

connectedAt
string<date-time>
必填
displayName
string | null
必填
id
string
必填
Pattern: ^msc_[0-9A-Za-z]+$
platform
enum<string>
必填
可用选项:
whatsapp,
google,
microsoft
profileId
string
必填

The social profile (prf_...) the connection was made under.

status
enum<string>
必填
可用选项:
active,
needs_reconnect,
disconnected
syncedAt
string<date-time> | null
必填
username
string | null
必填