渠道管理/授权
查询授权状态
接口说明:轮询平台授权 Session 状态
GET
/
api
/
v2
/
channels
/
accounts
/
auth
/
{platform}
/
status
/
{sessionId}
查询授权状态
curl --request GET \
--url https://aitoearn.cn/api/v2/channels/accounts/auth/{platform}/status/{sessionId} \
--header 'X-Api-Key: <api-key>'{
"code": 0,
"message": "请求成功",
"data": {
"sessionId": "string",
"status": "pending",
"requiresSelection": true,
"errorCode": 1,
"expiresAt": "2026-07-02T12:00:00.000Z",
"accountId": "string",
"accountIds": [
"string"
],
"accounts": [
{
"accountId": "string",
"platform": "douyin",
"platformUid": "string",
"displayName": "string",
"account": "string",
"avatarUrl": "string"
}
],
"selectableAccounts": [
{
"platform": "douyin",
"platformUid": "string",
"displayName": "string",
"account": "string",
"avatarUrl": "string",
"parentPlatformUid": "string"
}
]
}
}授权
AiToEarn Open Platform API Key。
响应
200 - application/json
请求已被服务处理。业务是否成功以响应体 code === 0 为准。
业务状态码。0 表示成功,非 0 表示业务错误。
响应消息。
Hide child attributes
Hide child attributes
授权 Session ID
授权 Session 状态
可用选项:
pending, completed, failed 是否需要选择二级账号
授权失败错误码
授权 Session 过期时间
首个本地账号 ID
本地账号 ID 列表
已连接账号列表
Hide child attributes
Hide child attributes
本地账号 ID
平台类型
可用选项:
douyin, xhs, wxSph, KWAI, youtube, wxGzh, bilibili, twitter, tiktok, facebook, instagram, threads, pinterest, linkedin, google_business 平台账号 UID
平台账号展示名
平台账号补充唯一标识
平台账号头像 URL
可选择的平台账号列表
Hide child attributes
Hide child attributes
平台类型
可用选项:
douyin, xhs, wxSph, KWAI, youtube, wxGzh, bilibili, twitter, tiktok, facebook, instagram, threads, pinterest, linkedin, google_business 平台账号 UID
平台账号展示名
平台账号补充唯一标识
平台账号头像 URL
父级平台账号 UID
请求 ID。
错误响应时间戳,Unix 毫秒。
⌘I
查询授权状态
curl --request GET \
--url https://aitoearn.cn/api/v2/channels/accounts/auth/{platform}/status/{sessionId} \
--header 'X-Api-Key: <api-key>'{
"code": 0,
"message": "请求成功",
"data": {
"sessionId": "string",
"status": "pending",
"requiresSelection": true,
"errorCode": 1,
"expiresAt": "2026-07-02T12:00:00.000Z",
"accountId": "string",
"accountIds": [
"string"
],
"accounts": [
{
"accountId": "string",
"platform": "douyin",
"platformUid": "string",
"displayName": "string",
"account": "string",
"avatarUrl": "string"
}
],
"selectableAccounts": [
{
"platform": "douyin",
"platformUid": "string",
"displayName": "string",
"account": "string",
"avatarUrl": "string",
"parentPlatformUid": "string"
}
]
}
}
