Get conversation
curl --request GET \
--url https://api.aisa.one/apis/v1/social/inbox/conversations/{conversationId} \
--header 'Authorization: Bearer <token>'import requests
url = "https://api.aisa.one/apis/v1/social/inbox/conversations/{conversationId}"
headers = {"Authorization": "Bearer <token>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};
fetch('https://api.aisa.one/apis/v1/social/inbox/conversations/{conversationId}', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.aisa.one/apis/v1/social/inbox/conversations/{conversationId}",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://api.aisa.one/apis/v1/social/inbox/conversations/{conversationId}"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("Authorization", "Bearer <token>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://api.aisa.one/apis/v1/social/inbox/conversations/{conversationId}")
.header("Authorization", "Bearer <token>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.aisa.one/apis/v1/social/inbox/conversations/{conversationId}")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["Authorization"] = 'Bearer <token>'
response = http.request(request)
puts response.read_body{
"data": {
"accountId": "<string>",
"accountUsername": "<string>",
"adAttribution": {
"adAccountId": "<string>",
"adAccountName": "<string>",
"adId": "<string>",
"adSetId": "<string>",
"adSetName": "<string>",
"campaignId": "<string>",
"campaignName": "<string>",
"isExternal": true,
"name": "<string>",
"platformPostId": "<string>",
"synced": true
},
"businessScopedUserId": "<string>",
"id": "<string>",
"instagramProfile": {
"fetchedAt": "2023-11-07T05:31:56Z",
"followerCount": 123,
"isFollower": true,
"isFollowing": true,
"isVerified": true
},
"lastMessage": "<string>",
"lastMessageAt": "2023-11-07T05:31:56Z",
"metadata": {
"ctwa_body": "<string>",
"ctwa_captured_at": "2023-11-07T05:31:56Z",
"ctwa_clid": "<string>",
"ctwa_headline": "<string>",
"ctwa_image_url": "<string>",
"ctwa_media_type": "<string>",
"ctwa_source_id": "<string>",
"ctwa_source_type": "<string>",
"ctwa_source_url": "<string>",
"ctwa_thumbnail_url": "<string>",
"ctwa_video_url": "<string>",
"meta_ad_captured_at": "2023-11-07T05:31:56Z",
"meta_ad_flow_id": "<string>",
"meta_ad_id": "<string>",
"meta_ad_photo_url": "<string>",
"meta_ad_post_id": "<string>",
"meta_ad_product_id": "<string>",
"meta_ad_ref": "<string>",
"meta_ad_source": "<string>",
"meta_ad_title": "<string>",
"meta_ad_type": "<string>",
"meta_ad_video_url": "<string>"
},
"pageId": "<string>",
"participantId": "<string>",
"participantName": "<string>",
"participantVerifiedType": "blue",
"participants": [
{
"id": "<string>",
"name": "<string>"
}
],
"platform": "<string>",
"status": "active",
"updatedTime": "2023-11-07T05:31:56Z",
"whatsappUsername": "<string>"
}
}{
"error": {
"code": "<string>",
"details": {},
"message": "<string>",
"param": "<string>",
"retryHint": "never",
"retryable": true,
"type": "<string>"
}
}收件箱
Get conversation
Inbox. Read only; needs social:read. Ids are yours: accounts acc_…, profiles prf_…, posts pst_…; every other object id is checked against your accounts before the call.
Retrieve details and metadata for a specific conversation. Requires accountId query parameter.
GET
https://api.aisa.one
/
apis
/
v1
/
social
/
inbox
/
conversations
/
{conversationId}
Get conversation
curl --request GET \
--url https://api.aisa.one/apis/v1/social/inbox/conversations/{conversationId} \
--header 'Authorization: Bearer <token>'import requests
url = "https://api.aisa.one/apis/v1/social/inbox/conversations/{conversationId}"
headers = {"Authorization": "Bearer <token>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};
fetch('https://api.aisa.one/apis/v1/social/inbox/conversations/{conversationId}', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.aisa.one/apis/v1/social/inbox/conversations/{conversationId}",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://api.aisa.one/apis/v1/social/inbox/conversations/{conversationId}"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("Authorization", "Bearer <token>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://api.aisa.one/apis/v1/social/inbox/conversations/{conversationId}")
.header("Authorization", "Bearer <token>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.aisa.one/apis/v1/social/inbox/conversations/{conversationId}")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["Authorization"] = 'Bearer <token>'
response = http.request(request)
puts response.read_body{
"data": {
"accountId": "<string>",
"accountUsername": "<string>",
"adAttribution": {
"adAccountId": "<string>",
"adAccountName": "<string>",
"adId": "<string>",
"adSetId": "<string>",
"adSetName": "<string>",
"campaignId": "<string>",
"campaignName": "<string>",
"isExternal": true,
"name": "<string>",
"platformPostId": "<string>",
"synced": true
},
"businessScopedUserId": "<string>",
"id": "<string>",
"instagramProfile": {
"fetchedAt": "2023-11-07T05:31:56Z",
"followerCount": 123,
"isFollower": true,
"isFollowing": true,
"isVerified": true
},
"lastMessage": "<string>",
"lastMessageAt": "2023-11-07T05:31:56Z",
"metadata": {
"ctwa_body": "<string>",
"ctwa_captured_at": "2023-11-07T05:31:56Z",
"ctwa_clid": "<string>",
"ctwa_headline": "<string>",
"ctwa_image_url": "<string>",
"ctwa_media_type": "<string>",
"ctwa_source_id": "<string>",
"ctwa_source_type": "<string>",
"ctwa_source_url": "<string>",
"ctwa_thumbnail_url": "<string>",
"ctwa_video_url": "<string>",
"meta_ad_captured_at": "2023-11-07T05:31:56Z",
"meta_ad_flow_id": "<string>",
"meta_ad_id": "<string>",
"meta_ad_photo_url": "<string>",
"meta_ad_post_id": "<string>",
"meta_ad_product_id": "<string>",
"meta_ad_ref": "<string>",
"meta_ad_source": "<string>",
"meta_ad_title": "<string>",
"meta_ad_type": "<string>",
"meta_ad_video_url": "<string>"
},
"pageId": "<string>",
"participantId": "<string>",
"participantName": "<string>",
"participantVerifiedType": "blue",
"participants": [
{
"id": "<string>",
"name": "<string>"
}
],
"platform": "<string>",
"status": "active",
"updatedTime": "2023-11-07T05:31:56Z",
"whatsappUsername": "<string>"
}
}{
"error": {
"code": "<string>",
"details": {},
"message": "<string>",
"param": "<string>",
"retryHint": "never",
"retryable": true,
"type": "<string>"
}
}请求规范
- 方法与路径: GET /apis/v1/social/inbox/conversations/{conversationId}
- 可用状态: enabled
- 请求 URL 模板:
https://api.aisa.one/apis/v1/social/inbox/conversations/{conversationId} - conversationId: path; 必填
- accountId: query; 必填
{
"operationId": "get_aisa_social_apis_v1_social_inbox_conversation_d09eb3",
"method": "GET",
"path": "/apis/v1/social/inbox/conversations/{conversationId}",
"servers": [
{
"url": "https://api.aisa.one"
}
],
"parameters": [
{
"description": "Opaque conversation identifier, accepted verbatim from the list endpoint or from the conversationId on inbox webhooks. Format not to be assumed.",
"in": "path",
"name": "conversationId",
"required": true,
"schema": {
"type": "string"
}
},
{
"description": "One of your social accounts (acc_...).",
"in": "query",
"name": "accountId",
"required": true,
"schema": {
"pattern": "^acc_[0-9A-Za-z]{22}$",
"type": "string"
}
}
],
"security": [
{
"bearerAuth": []
}
],
"x-aisa-status": "enabled",
"components": {
"securitySchemes": {
"bearerAuth": {
"scheme": "bearer",
"type": "http"
}
}
}
}