Sand AISand AI MAGI-2MAGI-2 kini tersedia di SandBase: video 1080p dengan audio nativeCoba sekarang

Toutiao Post Comments

Dokumentasi API
https://api.sandbase.ai/v1/api/toutiao/app/comments

Returns user comments and interaction metrics for a specific Toutiao post. Results can be paginated through comment batches using an offset index.

Harga
$0.001USD / panggilan
Metode
POST
Respons
JSON
Parameter
2 wajib · 0 opsional

Playground

Input
Post ID, can be obtained from the link
Offset, used for pagination, default is 0, then add 20 each time
OutputContoh
Responsoutputs · 11.4 KB · 356 baris
[
  {
    "data": {
      "at_user_guide_info": null,
      "ban_audio_comment": true,
      "ban_comment": false,
      "ban_comment_reason": "写评论",
      "ban_comment_toast": "",
      "ban_face": false,
      "ban_gif_suggest": 0,
      "ban_pic_comment": 0,
      "bottom_tips": null,
      "comment_activity": null,
      "comment_classify_detail": null,
      "comment_share_enabled": false,
      "data": [
        {
          "ad": null,
          "cell_type": 1,
          "comment": {
            "aid": 13,
            "auth_verified_info": "",
            "author_act_badge": null,
            "author_badge": [],
            "author_badge_night": [],
            "band_name": "",
            "band_url": "",
            "bury_count": 9,
            "comment_badge": null,
            "comment_badge_night": null,
            "comment_tag_url": "",
            "content_rich_span": "{\"links\":[]}",
            "couplet_sticker": null,
            "create_time": 1735386148,
            "digg_bury_style": 2,
            "digg_count": 557,
            "digg_prompt": {
              "enable": true,
              "reply_box_placeholder": "发评不易,快回复鼓励下TA吧"
            },
            "dislike_style": 0,
            "extra": null,
            "extra_tips": "",
            "forward_count": 0,
            "has_author_digg": 0,
            "has_author_replied": 0,
            "has_multi_media": false,
            "id": 7453426669643630000,
            "id_str": "7453426669643629364",
            "interact_style": 0,
            "is_blocked": 0,
            "is_blocking": 0,
            "is_first_comment": 0,
            "is_followed": 0,
            "is_following": 0,
            "is_loyal_fan": 0,
            "is_pgc_author": 0,
            "is_repost": false,
            "large_image_list": [],
            "log_pb_string": "{\"has_author_replied\":0,\"with_hot_fans\":0}",
            "media_info": {
              "avatar_url": "",
              "name": ""
            },
            "membership_status": 0,
            "multi_media": null,
            "new_reply_list": [],
            "pendants": null,
            "platform": "feifei",
            "publish_loc_info": "安徽",
            "reaction_info": null,
            "remark_name": "",
            "reply_count": 71,
            "reply_list": [],
            "resource_url": "",
            "score": 0,
            "show_tags": 0,
            "source": null,
            "star_comment_info": {
              "has_recommend": false,
              "is_open": false,
              "is_star_comment": false
            },
            "support_react_list": null,
            "tags": null,
            "text": "这是全球首发,不会在有喷子了吧",
            "thumb_image_list": [],
            "user_auth_info": "",
            "user_bury": 0,
            "user_decoration": "",
            "user_digg": 0,
            "user_id": 2123875039058317,
            "user_name": "行云流水",
            "user_profile_image_url": "https://p3-sign.toutiaoimg.com/user-avatar/d5d554f2b46866499828b5ae7c2641f1~300x300.image?_iz=112761&from=tt_user.tab_comments_comment&lk3s=a67912db&x-expires=1791936000&x-signature=M9Gq5vTOntxfimeWHEbUEkgMqWI%3D",
            "user_relation": 0,
            "user_super_digg": 0,
            "user_verified": false,
            "verified_reason": "",
            "vote_info": null,
            "xg_badge_type": 0
          },
          "comment_resource_banner": null,
          "embedded_data": null,
          "forum_card": null,
          "id": 7453426669643630000,
          "pk_forum": null
        },
        {
          "ad": null,
          "cell_type": 1,
          "comment": {
            "aid": 13,
            "auth_verified_info": "",
            "author_act_badge": null,
            "author_badge": [],
            "author_badge_night": [],
            "band_name": "",
            "band_url": "",
            "bury_count": 6,
            "comment_badge": null,
            "comment_badge_night": null,
            "comment_tag_url": "",
            "content_rich_span": "{\"links\":[]}",
            "couplet_sticker": null,
            "create_time": 1735442128,
            "digg_bury_style": 2,
            "digg_count": 418,
            "digg_prompt": {
              "enable": true,
              "reply_box_placeholder": "有共鸣?一起讨论下吧"
            },
            "dislike_style": 0,
            "extra": null,
            "extra_tips": "",
            "forward_count": 0,
            "has_author_digg": 0,
            "has_author_replied": 0,
            "has_multi_media": false,
            "id": 7453667090147313000,
            "id_str": "7453667090147312447",
            "interact_style": 0,
            "is_blocked": 0,
            "is_blocking": 0,
            "is_first_comment": 0,
            "is_followed": 0,
            "is_following": 0,
            "is_loyal_fan": 0,
            "is_pgc_author": 0,
            "is_repost": false,
            "large_image_list": [],
            "log_pb_string": "{\"has_author_replied\":0,\"with_hot_fans\":0}",
            "media_info": {
              "avatar_url": "",
              "name": ""
            },
            "membership_status": 0,
            "multi_media": null,
            "new_reply_list": [],
            "pendants": null,
            "platform": "feifei",
            "publish_loc_info": "山西",
            "reaction_info": null,
            "remark_name": "",
            "reply_count": 22,
            "reply_list": [],
            "resource_url": "",
            "score": 0,
            "show_tags": 0,
            "source": null,
            "star_comment_info": {
              "has_recommend": false,
              "is_open": false,
              "is_star_comment": false
            },
            "support_react_list": null,
            "tags": null,
            "text": "我虽然是一位特别普通的打工仔,一个月工资4000。信用卡欠账一堆。父母都是70岁的农民。我也有很多委屈。可,对于国防,我不会有任何一句抱怨。因为没有一个强大的国防,你连这些都可能失去。",
            "thumb_image_list": [],
            "user_auth_info": "",
            "user_bury": 0,
            "user_decoration": "",
            "user_digg": 0,
            "user_id": 6931721159,
            "user_name": "糟老头子j",
            "user_profile_image_url": "https://p3-sign.toutiaoimg.com/user-avatar/fa45cc75efa17b2622d464050df7d382~300x300.image?_iz=112761&from=tt_user.tab_comments_comment&lk3s=a67912db&x-expires=1791936000&x-signature=HTuidRquj2NGzZyY8M%2FbPoiCIX8%3D",
            "user_relation": 0,
            "user_super_digg": 0,
            "user_verified": false,
            "verified_reason": "",
            "vote_info": null,
            "xg_badge_type": 0
          },
          "comment_resource_banner": null,
          "embedded_data": null,
          "forum_card": null,
          "id": 7453667090147313000,
          "pk_forum": null
        },
        {
          "ad": null,
          "cell_type": 1,
          "comment": {
            "aid": 13,
            "auth_verified_info": "",
            "author_act_badge": null,
            "author_badge": [],
            "author_badge_night": [],
            "band_name": "",
            "band_url": "",
            "bury_count": 0,
            "comment_badge": null,
            "comment_badge_night": null,
            "comment_tag_url": "",
            "content_rich_span": "{\"links\":[]}",
            "couplet_sticker": null,
            "create_time": 1735390776,
            "digg_bury_style": 2,
            "digg_count": 345,
            "digg_prompt": {
              "enable": true,
              "reply_box_placeholder": "有共鸣?一起讨论下吧"
            },
            "dislike_style": 0,
            "extra": null,
            "extra_tips": "",
            "forward_count": 0,
            "has_author_digg": 0,
            "has_author_replied": 0,
            "has_multi_media": false,
            "id": 7453446542591411000,
            "id_str": "7453446542591410980",
            "interact_style": 0,
            "is_blocked": 0,
            "is_blocking": 0,
            "is_first_comment": 0,
            "is_followed": 0,
            "is_following": 0,
            "is_loyal_fan": 0,
            "is_pgc_author": 0,
            "is_repost": false,
            "large_image_list": [],
            "log_pb_string": "{\"has_author_replied\":0,\"with_hot_fans\":0}",
            "media_info": {
              "avatar_url": "",
              "name": ""
            },
            "membership_status": 0,
            "multi_media": null,
            "new_reply_list": [],
            "pendants": null,
            "platform": "feifei",
            "publish_loc_info": "安徽",
            "reaction_info": null,
            "remark_name": "",
            "reply_count": 1,
            "reply_list": [],
            "resource_url": "",
            "score": 0,
            "show_tags": 0,
            "source": null,
            "star_comment_info": {
              "has_recommend": false,
              "is_open": false,
              "is_star_comment": false
            },
            "support_react_list": null,
            "tags": null,
            "text": "向最敬爱的中国军事科学家技术专家致以最崇高的敬礼!你们是最可爱的人!!![赞][赞][赞][赞][赞][赞][玫瑰][玫瑰][玫瑰][玫瑰][玫瑰][玫瑰]",
            "thumb_image_list": [],
            "user_auth_info": "",
            "user_bury": 0,
            "user_decoration": "",
            "user_digg": 0,
            "user_id": 14593625568,
            "user_name": "冬去兮春来",
            "user_profile_image_url": "https://p11-sign.toutiaoimg.com/mosaic-legacy/3e81000d94cec5d46aba~300x300.image?_iz=112761&from=tt_user.tab_comments_comment&lk3s=a67912db&x-expires=1791936000&x-signature=dSuMyE1aLZt27JZbY759Y259BDc%3D",
            "user_relation": 0,
            "user_super_digg": 0,
            "user_verified": false,
            "verified_reason": "",
            "vote_info": null,
            "xg_badge_type": 0
          },
          "comment_resource_banner": null,
          "embedded_data": null,
          "forum_card": null,
          "id": 7453446542591411000,
          "pk_forum": null
        },
        "… 17 more items in the full response"
      ],
      "detail_no_comment": 0,
      "enter_comment_info": {
        "err_no": 0,
        "toast_text": ""
      },
      "err_no": 0,
      "exempt": false,
      "extensions": null,
      "fold_comment_count": 0,

Contoh

Pilih contoh untuk memuat input dan hasilnya ke playground.

README API

Toutiao Post Comments API

Returns a page of comments for a Toutiao post, plus paging data and post-level comment settings. It needs the post's group_id and an offset value.

Use cases

  • Collect the first pages of comments on a Toutiao post to review reader feedback.
  • Track how many bury_count votes each comment on a post receives.
  • Page through all comments of a post by repeating the call until has_more is false.
  • Check whether commenting is turned off on a post using ban_comment.

Request

curl -X POST "https://api.sandbase.ai/v1/api/toutiao/app/comments" \
  -H "Authorization: Bearer $SANDBASE_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{"group_id": "7453372680222523931", "offset": "0"}'

The result is returned in outputs[0].data.

Parameters

NameTypeRequiredDescription
group_idstringYesPost ID, can be obtained from the link
offsetstringYesOffset, used for pagination, default is 0, then add 20 each time

Example response

Real response for the request above, trimmed: lists keep their first item and long strings are cut.

{
  "at_user_guide_info": null,
  "ban_ai_polish": true,
  "ban_audio_comment": true,
  "ban_comment": false,
  "ban_comment_reason": "写评论",
  "ban_comment_toast": "",
  "ban_face": false,
  "ban_gif_suggest": 0,
  "ban_pic_comment": 0,
  "bottom_tips": null,
  "comment_activity": null,
  "comment_classify_detail": null
}

Response fields

FieldMeaning
data[]List of comment cells. Each item holds one comment and its id.
data[].idID of the comment cell. It is a long number.
data[].comment.bury_countNumber of bury votes on the comment.
data[].comment.aidApp ID value attached to the comment. The response does not explain its meaning.
data[].cell_typeType code of the list item. Items in this response all have the value 1.
has_moretrue when more comments are available after this page.
offsetOffset value for the next page. The sample response returns 20 after a request with 0.
next_comment_since_tsUnix-style timestamp number returned for the next comment batch.
ban_comment / ban_pic_comment / ban_audio_commentFlags that show whether commenting, picture comments or audio comments are blocked on this post.
group.group_idID of the post the comments belong to.

Notes

  • Take group_id from the Toutiao post link.
  • Start with offset set to 0, then add 20 for each next page, as the parameter description states.
  • Stop paging when has_more is false.
  • To get details about the post itself, call Toutiao Article Details (App).

Pricing

$0.001 per successful call. Failed calls are not charged. It is included in the daily free quota of each organization.

Jelajahi lebih lanjut

API Terkait

Semua APIs
APIHargaRespons
Toutiao$0.001 per panggilanJSON
Toutiao$0.001 per panggilanJSON
Toutiao$0.001 per panggilanJSON
Toutiao$0.001 per panggilanJSON
Toutiao$0.001 per panggilanJSON
Toutiao$0.071429 per panggilanJSON

Pertanyaan

FAQ

Bagaimana cara menggunakan API Toutiao Post Comments?

Kirim permintaan POST ke https://api.sandbase.ai/v1/api/toutiao/app/comments dengan kunci API SandBase Anda di header Authorization (Bearer) dan parameter sebagai body JSON. Anda juga dapat mencobanya di Playground di halaman ini tanpa menulis kode.

Berapa biaya API Toutiao Post Comments?

$0.001 per panggilan, ditagihkan dari saldo SandBase Anda. Anda hanya dikenai biaya untuk panggilan yang Anda lakukan; tidak ada langganan.

Parameter apa yang diterima API Toutiao Post Comments?

Wajib: group_id (string) dan offset (string). Tabel Parameters dan Playground di halaman ini mencantumkan setiap field.

Apa yang dikembalikan API Toutiao Post Comments?

Respons JSON yang dikembalikan dalam permintaan HTTP yang sama (sinkron). README di halaman ini menyertakan contoh respons.

Apakah saya memerlukan akun developer atau kunci API Toutiao?

Tidak. Toutiao Post Comments berjalan melalui SandBase, jadi satu kunci API SandBase mencakup endpoint ini dan setiap API serta model lain di katalog. Anda tidak perlu mendaftar akses API Toutiao secara terpisah.