Weibo Social Ranking
https://api.sandbase.ai/v1/api/weibo/web-v2/social-rankingReturns Weibo social ranking data covering current affairs, social hotspots, and livelihood topics. Call this endpoint to track top-trending public interest discussions.
- 料金
- $0.001USD / 回
- メソッド
- POST
- レスポンス
- JSON
- パラメータ
- 必須 0 件 · 任意 0 件
プレイグラウンド
[
{
"data": {
"band_list": [
{
"emoticon": "",
"flag": 2,
"icon": "https://simg.s.weibo.com/moter/flags/2_0.png",
"icon_desc": "热",
"icon_desc_color": "#ff9406",
"icon_height": 24,
"icon_url": "https://simg.s.weibo.com/moter/flags/2_0.png",
"icon_width": 24,
"is_hot": 1,
"loc_page": 3,
"m_category": "民生新闻",
"note": "许家印被曝奢靡日常",
"num": 3157580,
"rank": 0,
"realpos": 1,
"small_icon_desc": "热",
"small_icon_desc_color": "#ff9406",
"subject_querys": {},
"topic_flag": 0,
"word": "许家印被曝奢靡日常",
"word_scheme": "许家印被曝奢靡日常"
},
{
"emoticon": "",
"flag": 2,
"icon": "https://simg.s.weibo.com/moter/flags/2_0.png",
"icon_desc": "热",
"icon_desc_color": "#ff9406",
"icon_height": 24,
"icon_url": "https://simg.s.weibo.com/moter/flags/2_0.png",
"icon_width": 24,
"is_hot": 1,
"loc_page": 4,
"m_category": "辟谣/通报,作品衍生",
"note": "警方通报时代峰峻楼下聚集事件",
"num": 2466208,
"rank": 1,
"realpos": 2,
"small_icon_desc": "热",
"small_icon_desc_color": "#ff9406",
"subject_querys": {
"警方通报时代峰峻楼下聚集事件": {
"subject_trend": "tf家族五代下班被anti",
"subject_type": "event"
}
},
"topic_flag": 1,
"word": "警方通报时代峰峻楼下聚集事件",
"word_scheme": "#警方通报时代峰峻楼下聚集事件#"
},
{
"emoticon": "",
"flag": 1,
"icon": "https://simg.s.weibo.com/moter/flags/1_0.png",
"icon_desc": "新",
"icon_desc_color": "#ff3852",
"icon_height": 24,
"icon_url": "https://simg.s.weibo.com/moter/flags/1_0.png",
"icon_width": 24,
"is_new": 1,
"loc_page": 4,
"m_category": "民生新闻",
"note": "青岛涉事女游客多次致歉求饶",
"num": 1701148,
"rank": 2,
"realpos": 3,
"small_icon_desc": "新",
"small_icon_desc_color": "#ff3852",
"subject_querys": {
"青岛男子辱骂女游客": {
"subject_trend": "青岛男子辱骂女游客",
"subject_type": "event"
}
},
"topic_flag": 1,
"word": "青岛涉事女游客多次致歉求饶",
"word_scheme": "#青岛涉事女游客多次致歉求饶#"
},
"… 47 more items in the full response"
]
}
}
]例
例を選択すると、その入力と結果がプレイグラウンドに読み込まれます。
API README
Weibo Social Ranking API
Returns the current Weibo social ranking list, which covers current affairs, social hotspots and livelihood topics. The API takes no input. Each entry has a topic title, a heat number, a category and a rank.
Use cases
- Show the top Weibo public affairs topics on a news dashboard.
- Log
hot_numfor each topic over time to see which stories grow fastest. - Filter entries by
categoryto collect livelihood news or official clarification notices. - Collect the
word_schemehashtags to use as keywords in a post search.
Request
curl -X POST "https://api.sandbase.ai/v1/api/weibo/web-v2/social-ranking" \
-H "Authorization: Bearer $SANDBASE_API_KEY" \
-H "Content-Type: application/json" \
-d '{}'
The result is returned in outputs[0].data.
Example response
Real response for the request above, trimmed: lists keep their first item and long strings are cut.
{
"band_list": [
{
"category": "民生新闻",
"emoticon": "",
"flag": 2,
"hot_num": 2173490,
"icon": "https://simg.s.weibo.com/moter/flags/2_0.png",
"icon_desc": "热",
"icon_desc_color": "#ff9406",
"icon_height": 24,
"icon_url": "https://simg.s.weibo.com/moter/flags/2_0.png",
"icon_width": 24,
"is_hot": 1,
"loc_page": 4
}
]
}
Response fields
| Field | Meaning |
|---|---|
band_list[] | One ranked topic in the social ranking list. |
band_list[].word / note | The topic title. Both fields hold the same text in the sample. |
band_list[].word_scheme | The topic written as a Weibo hashtag, such as #警方通报九寨沟景区游客冲突事件#. Some entries have no # marks. |
band_list[].hot_num / num | The heat value of the topic. Higher numbers rank higher. |
band_list[].rank / realpos | The position in the list. rank starts at 0 and realpos starts at 1. |
band_list[].category / m_category | The topic category, for example 民生新闻 (livelihood news) or 辟谣/通报 (rumor refutation or official notice). |
band_list[].icon_desc | The short label shown on the topic, such as 热, 新 or 沸. The flags is_hot, is_new and is_fei match these labels. |
band_list[].flag | Numeric code for the label type. The sample shows 1 with 新, 2 with 热 and 16 with 沸. |
band_list[].subject_querys | Related event names keyed by query text. Each value has subject_trend (a trend title) and subject_type. |
band_list[].icon_url | URL of the label image for the topic. |
Notes
- Send an empty JSON object
{}. The API has no request parameters and no pagination. - To read the posts behind a topic, pass its
wordto Weibo Topic Search or Weibo Real-Time Search. - For other rankings, see Weibo Life Ranking.
Pricing
$0.001 per successful call. Failed calls are not charged. It is included in the daily free quota of each organization.
開発を始める
最初のリクエストを送信
統一認証と使用状況の追跡を備えたプラットフォームAPIエンドポイントです。
curl -X POST "https://api.sandbase.ai/v1/api/weibo/web-v2/social-ranking" \
-H "Authorization: Bearer $SANDBASE_API_KEY" \
-H "Content-Type: application/json" \
-d '{}'2. 認証
SandBaseのAPIキーをサーバー環境に設定してください。リクエストはBearer認証を使用します。
export SANDBASE_API_KEY="YOUR_API_KEY"キーはサーバー側で管理してください。ブラウザコードに公開しないでください。
3. パラメータ
このAPIのパラメータスキーマは公開されていません。
4. レスポンス
このAPIの保存済みサンプルレスポンスです。表示時にライブリクエストは行われません。
[
{
"data": {
"band_list": [
{
"emoticon": "",
"flag": 2,
"icon": "https://simg.s.weibo.com/moter/flags/2_0.png",
"icon_desc": "热",
"icon_desc_color": "#ff9406",
"icon_height": 24,
"icon_url": "https://simg.s.weibo.com/moter/flags/2_0.png",
"icon_width": 24,
"is_hot": 1,
"loc_page": 3,
"m_category": "民生新闻",
"note": "许家印被曝奢靡日常",
"num": 3157580,
"rank": 0,
"realpos": 1,
"small_icon_desc": "热",
"small_icon_desc_color": "#ff9406",
"subject_querys": {},
"topic_flag": 0,
"word": "许家印被曝奢靡日常",
"word_scheme": "许家印被曝奢靡日常"
},
{
"emoticon": "",
"flag": 2,
"icon": "https://simg.s.weibo.com/moter/flags/2_0.png",
"icon_desc": "热",
"icon_desc_color": "#ff9406",
"icon_height": 24,
"icon_url": "https://simg.s.weibo.com/moter/flags/2_0.png",
"icon_width": 24,
"is_hot": 1,
"loc_page": 4,
"m_category": "辟谣/通报,作品衍生",
"note": "警方通报时代峰峻楼下聚集事件",
"num": 2466208,
"rank": 1,
"realpos": 2,
"small_icon_desc": "热",
"small_icon_desc_color": "#ff9406",
"subject_querys": {
"警方通报时代峰峻楼下聚集事件": {
"subject_trend": "tf家族五代下班被anti",
"subject_type": "event"
}
},
"topic_flag": 1,
"word": "警方通报时代峰峻楼下聚集事件",
"word_scheme": "#警方通报时代峰峻楼下聚集事件#"
},
{
"emoticon": "",
"flag": 1,
"icon": "https://simg.s.weibo.com/moter/flags/1_0.png",
"icon_desc": "新",
"icon_desc_color": "#ff3852",
"icon_height": 24,
"icon_url": "https://simg.s.weibo.com/moter/flags/1_0.png",
"icon_width": 24,
"is_new": 1,
"loc_page": 4,
"m_category": "民生新闻",
"note": "青岛涉事女游客多次致歉求饶",
"num": 1701148,
"rank": 2,
"realpos": 3,
"small_icon_desc": "新",
"small_icon_desc_color": "#ff3852",
"subject_querys": {
"青岛男子辱骂女游客": {
"subject_trend": "青岛男子辱骂女游客",
"subject_type": "event"
}
},
"topic_flag": 1,
"word": "青岛涉事女游客多次致歉求饶",
"word_scheme": "#青岛涉事女游客多次致歉求饶#"
},
"… 47 more items in the full response"
]
}
}
]さらに探索
関連 APIs
| API | 価格 | レスポンス |
|---|---|---|
Weibo Social Rankingこの API Weibo | $0.001 / 回 | JSON |
Weibo | $0.001 / 回 | JSON |
Weibo | $0.001 / 回 | JSON |
Weibo | $0.001 / 回 | JSON |
Weibo | $0.001 / 回 | JSON |
Weibo | $0.001 / 回 | JSON |
質問
FAQ
Weibo Social Ranking API はどのように使いますか?
Authorization ヘッダー(Bearer)に SandBase API key を指定し、パラメータを JSON ボディで送信して https://api.sandbase.ai/v1/api/weibo/web-v2/social-ranking に POST リクエストを送ります。このページの Playground で、コードを書かずに試すこともできます。
Weibo Social Ranking API の料金はいくらですか?
1回あたり $0.001、SandBase 残高から課金されます。課金対象はご利用分のみで、サブスクリプションはありません。
Weibo Social Ranking API はどのパラメータを受け付けますか?
Weibo Social Ranking は入力パラメータを取りません。空の JSON ボディを送信してください。
Weibo Social Ranking API は何を返しますか?
同じ HTTP リクエスト内で返される JSON レスポンスです(同期)。 このページの README にサンプルレスポンスがあります。
Weibo の開発者アカウントまたは API key は必要ですか?
いいえ。Weibo Social Ranking は SandBase 経由で動作するため、SandBase の API key 1つでこのエンドポイントと、カタログ内の他のすべての API とモデルを利用できます。Weibo の API アクセスを別途申請する必要はありません。
