Object Comments
GET/{version}/{post_id}/commentsVia 360: GET https://partner.quantri360.com/v1/facebook/{version}/{post_id}/comments
Coming soon. This API already runs in production through 360 and pricing is being finalised — you can read the docs and prepare your integration now.
Description
Bình luận của một bài viết (hoặc ảnh / video), hoặc trả lời của một bình luận khi {post_id} là id bình luận. Nguồn để rà, trả lời, ẩn bình luận của khách và tìm bình luận hỏi giá.
filter=streamđếm cả trả lời: cùng một bài,summary.total_count= 15 trong khicomments.summaryở /published_posts = 8.- Bình luận bị ẩn vẫn trả về (
is_hidden = true); bình luận đã xóa thì không. - Dữ liệu cá nhân người bình luận — chỉ dùng cho CSKH của chính Trang.
Request
Endpoint
GET https://partner.quantri360.com/v1/facebook/{version}/{post_id}/comments
Authentication & shop
| Name | In | Type | Sample | Description |
|---|---|---|---|---|
| Authorization | header | header | Bearer q360_live_ab12cd34_… | Khóa API của brand (tạo ở mục API key). Bắt buộc với mọi request. Brand suy từ key — không truyền mã brand. |
| platform_shop_id | query | string | act_123456789 hoặc 1234567890 | Tài sản Facebook brand đã nối với 360: tài khoản quảng cáo (act_<id> hoặc <id>), Page id hoặc Pixel id — lấy ở GET /v1/platforms. Có thể bỏ khi đường dẫn đã chứa act_<id> / page id của brand. |
Request parameters
| Name | In | Type | Required | Sample | Description |
|---|---|---|---|---|---|
| version | path | string | Yes | v25.0 | |
| post_id | path | string | Yes | 109900000000001_1199000000000005 | Id bài (<page_id>_<post_id>), ảnh, video, hoặc id bình luận (<post_id>_<comment_id>) để lấy các trả lời. |
| fields | query | string | No | id,message,created_time,from,like_count,comment_count,is_hidden,can_hide,parent{id} | Trường cần lấy. from (tên + id người bình luận) chỉ trả khi token Trang đủ quyền. |
| filter | query | string | No | stream | toplevel (mặc định) = chỉ bình luận cấp 1 · stream = tất cả, gồm trả lời (có parent). |
| order | query | string | No | reverse_chronological | chronological (cũ trước) · reverse_chronological (mới trước) · ranked. |
| summary | query | bool | No | true | Thêm summary.total_count. |
| limit | query | int | No | 25 | Số bình luận mỗi trang (tối đa 100). |
| after | query | string | No | paging.cursors.after của trang trước. |
Pagination
Lặp khi có paging.next: thêm after = paging.cursors.after.
Request examples
curl -s "https://partner.quantri360.com/v1/facebook/v25.0/109900000000001_1199000000000005/comments?fields=id%2Cmessage%2Ccreated_time%2Cfrom%2Clike_count%2Ccomment_count%2Cis_hidden%2Cparent%7Bid%7D&filter=stream&order=reverse_chronological&summary=true&limit=25" \ -H "Authorization: Bearer $KEY"
Python
import requests
KEY = "q360_live_..." # khóa API của brand
r = requests.get(
"https://partner.quantri360.com/v1/facebook/v25.0/109900000000001_1199000000000005/comments",
params={
"fields": "id,message,created_time,from,like_count,comment_count,is_hidden,parent{id}",
"filter": "stream",
"order": "reverse_chronological",
"summary": True,
"limit": 25
},
headers={"Authorization": f"Bearer {KEY}"},
timeout=60,
)
print(r.status_code)
print(r.json())Node.js
const KEY = 'q360_live_...'; // khóa API của brand
const url = new URL('https://partner.quantri360.com/v1/facebook/v25.0/109900000000001_1199000000000005/comments');
for (const [k, v] of Object.entries({"fields":"id,message,created_time,from,like_count,comment_count,is_hidden,parent{id}","filter":"stream","order":"reverse_chronological","summary":true,"limit":25})) url.searchParams.set(k, typeof v === 'object' ? JSON.stringify(v) : String(v));
const r = await fetch(url, {
method: 'GET',
headers: { Authorization: `Bearer ${KEY}` },
});
console.log(r.status, await r.json());PHP
<?php
$key = 'q360_live_...'; // khóa API của brand
$url = 'https://partner.quantri360.com/v1/facebook/v25.0/109900000000001_1199000000000005/comments' . '?' . http_build_query(['fields' => 'id,message,created_time,from,like_count,comment_count,is_hidden,parent{id}', 'filter' => 'stream', 'order' => 'reverse_chronological', 'summary' => 'true', 'limit' => 25]);
$ch = curl_init($url);
curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
curl_setopt($ch, CURLOPT_HTTPHEADER, ['Authorization: Bearer ' . $key]);
$res = curl_exec($ch);
$status = curl_getinfo($ch, CURLINFO_HTTP_CODE);
curl_close($ch);
echo $status, "\n", $res;Response
Response fields (as returned by Facebook)
| Name | Type | Sample | Description |
|---|---|---|---|
| data | object[] | Bình luận. | |
| id | string | 1199000000000005_3699000000000001 | Id bình luận `<post_id>_<comment_id>`. |
| message | string | Nội dung. | |
| created_time | string | 2026-08-25T10:18:30+0000 | ISO 8601, UTC. |
| from | object | `{name, id}` người bình luận (id theo phạm vi app) hoặc Trang khi Trang trả lời. | |
| like_count | int | 0 | |
| comment_count | int | 1 | Số trả lời. |
| is_hidden | bool | false | Đã ẩn. |
| can_hide | bool | true | `false` với bình luận của chính Trang. |
| parent | object | `{id}` bình luận cha — chỉ có với trả lời khi `filter=stream`. | |
| paging | object | `{cursors, next}`. | |
| summary | object | `{order, total_count, can_comment}` — khi `summary=true`. |
Response sample
{
"data": [
{
"id": "1199000000000005_1199000000000006",
"message": "Cửa hàng mẫu xin chào, cảm ơn chị đã quan tâm…",
"created_time": "2026-08-25T10:21:34+0000",
"from": {
"name": "Cửa hàng mẫu Fashion",
"id": "109900000000001"
},
"like_count": 0,
"comment_count": 0,
"is_hidden": false,
"can_hide": false,
"parent": {
"id": "1199000000000005_3699000000000001"
}
},
{
"id": "1199000000000005_3699000000000001",
"message": "Shop cho xin giá mẫu này ạ",
"created_time": "2026-08-25T10:18:30+0000",
"from": {
"name": "Nguyễn Văn A",
"id": "1234567890123456"
},
"like_count": 0,
"comment_count": 1,
"is_hidden": false,
"can_hide": true
}
],
"paging": {
"cursors": {
"before": "WTI5dGJXVnVk…",
"after": "WTI5dGJXVnVk…"
},
"next": ""
},
"summary": {
"order": "reverse_chronological",
"total_count": 15,
"can_comment": true
}
}
Get started
- Sign up for Partner
- Enable a data type of the Trang & Messenger group on the platform page
- Create an API key (tick the Facebook channel)
- Call it as in the examples above