Zhihu Answer List API (V1)
API health status
Healthy Available Limited Mostly unavailable No data
Loading health status...
Get Zhihu answer List data, including answer content, author profiles, and interaction metrics, for question analysis and answer research.
Parameters
| Name | In | Type | Required | Default | Description |
|---|---|---|---|---|---|
token | query | string | Yes | - | TOKEN |
questionId | query | string | Yes | - | Question ID |
cursor | query | string | No | `` | Pagination cursor from previous result. |
offset | query | integer | No | 0 | Start offset, begins with 0. |
order | query | string | No | _updated | Sorting criteria for answers. Available Values: - _default: Default sorting.- _updated: Sorted by updated time. |
sessionId | query | string | No | `` | Session ID from previous result. |
Code Samples
bash
curl -X GET "https://api.justoneapi.com/api/zhihu/get-answer-list/v1?token=YOUR_API_KEY&questionId=VALUE"text
I want to use the "Answer List (V1)" API from Just One API.
API Endpoint: https://api.justoneapi.com/api/zhihu/get-answer-list/v1
HTTP Method: GET
Authentication: Append "?token=YOUR_API_KEY" to the URL.
OpenAPI Definition: https://docs.justoneapi.com/openapi/zhihu/answer-list-v1-en.json
Parameters:
- token (query): TOKEN (Required)
- questionId (query): Question ID (Required)
- cursor (query): Pagination cursor from previous result.
- offset (query): Start offset, begins with 0.
- order (query): Sorting criteria for answers.
Available Values:
- `_default`: Default sorting.
- `_updated`: Sorted by updated time.
- sessionId (query): Session ID from previous result.
Return format: JSON
Response Handling & Error Codes:
1. Business results should be determined by the "code" field in the response body (code 0 means success).
2. Timeout Recommendation: Set request timeout to at least 60 seconds.
3. Business Code Reference:
- 0: Success
- 100: Invalid or Inactive Token
- 301: Collection Failed. Please Retry.
- 302: Rate Limit Exceeded
- 303: Daily Quota Exceeded
- 400: Invalid Parameters
- 500: Internal Server Error
- 600: Permission Denied
- 601: Insufficient Balance
Please help me write a script in my preferred programming language to call this API and handle the response.python
import requests
url = "https://api.justoneapi.com/api/zhihu/get-answer-list/v1?token=YOUR_API_KEY&questionId=VALUE"
response = requests.get(url)
print(response.json())js
const response = await fetch("https://api.justoneapi.com/api/zhihu/get-answer-list/v1?token=YOUR_API_KEY&questionId=VALUE", {
method: "GET"
});
const data = await response.json();
console.log(data);java
import java.net.URI;
import java.net.http.HttpClient;
import java.net.http.HttpRequest;
import java.net.http.HttpResponse;
public class Main {
public static void main(String[] args) throws Exception {
HttpClient client = HttpClient.newHttpClient();
HttpRequest request = HttpRequest.newBuilder()
.uri(URI.create("https://api.justoneapi.com/api/zhihu/get-answer-list/v1?token=YOUR_API_KEY&questionId=VALUE"))
.method("GET", HttpRequest.BodyPublishers.noBody())
.build();
HttpResponse<String> response = client.send(request, HttpResponse.BodyHandlers.ofString());
System.out.println(response.body());
}
}go
package main
import (
"fmt"
"io"
"net/http"
)
func main() {
client := &http.Client{}
url := "https://api.justoneapi.com/api/zhihu/get-answer-list/v1?token=YOUR_API_KEY&questionId=VALUE"
req, _ := http.NewRequest("GET", url, nil)
resp, _ := client.Do(req)
defer resp.Body.Close()
body, _ := io.ReadAll(resp.Body)
fmt.Println(string(body))
}php
<?php
$ch = curl_init();
curl_setopt($ch, CURLOPT_URL, "https://api.justoneapi.com/api/zhihu/get-answer-list/v1?token=YOUR_API_KEY&questionId=VALUE");
curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
curl_setopt($ch, CURLOPT_CUSTOMREQUEST, "GET");
$response = curl_exec($ch);
curl_close($ch);
echo $response;Responses
json
{
"code": 0,
"data": {
"data": [
{
"type": "question_feed_card",
"target_type": "answer",
"target": {
"admin_closed_comment": false,
"allow_segment_interaction": 1,
"annotation_action": null,
"answer_type": "normal",
"attached_info": "ogETCAQQAxiXytHkle2V8Bsg+emDEpICLgoJNzcwMjQxNDAxEhMyMDA4NzAxNTQzODQzNjUyODg3GAQiCklNQUdFX1RFWFQ=",
"author": {
"avatar_url": "https://pica.zhimg.com/v2-2cbd425e6d8f176296de7dd480b74b56_l.jpg?source=1def8aca",
"avatar_url_template": "https://picx.zhimg.com/v2-2cbd425e6d8f176296de7dd480b74b56.jpg?source=1def8aca",
"badge": [],
"badge_v2": {
"detail_badges": [],
"icon": "",
"merged_badges": [],
"night_icon": "",
"title": ""
},
"exposed_medal": {
"avatar_url": "",
"description": "",
"medal_id": "0",
"medal_name": ""
},
"follower_count": 52,
"gender": 1,
"headline": "",
"id": "42f8a05a565b1c254c006546d5b8a2b0",
"is_advertiser": false,
"is_followed": false,
"is_following": false,
"is_org": false,
"is_privacy": false,
"name": "余十三",
"type": "people",
"url": "https://www.zhihu.com/api/v4/people/42f8a05a565b1c254c006546d5b8a2b0",
"url_token": "not-online-70-29",
"user_type": "people"
},
"business_type": "normal",
"can_comment": {
"reason": "",
"status": true
},
"collapse_reason": "",
"collapsed_by": "nobody",
"comment_count": 0,
"comment_permission": "all",
"content": "<p data-pid=\"yHt11Jy7\">自己做的壁纸</p><figure data-size=\"normal\"><noscript><img src=\"https://picx.zhimg.c...",
"content_mark": {},
"content_need_truncated": false,
"created_time": 1771691767,
"decorative_labels": [],
"editable_content": "",
"excerpt": "自己做的壁纸 [图片] 效果 [图片]",
"extras": "",
"favlists_count": 0,
"force_login_when_click_read_more": false,
"has_publishing_draft": false,
"id": "2008701543843652887",
"is_collapsed": false,
"is_contain_ai_content": false,
"is_copyable": true,
"is_jump_native": false,
"is_mine": false,
"is_navigator": false,
"is_normal": true,
"is_sticky": false,
"is_visible": true,
"matrix_tips": "0 赞同",
"navigator_vote": false,
"question": {
"created": 1448289701,
"id": "37811449",
"question_type": "normal",
"relationship": null,
"title": "有哪些优雅的 Windows 10 壁纸?",
"type": "question",
"updated_time": 1521972248,
"url": "https://www.zhihu.com/api/v4/questions/37811449"
},
"reaction": {
"relation": {
"faved": false,
"liked": false
},
"statistics": {
"down_vote_count": 0,
"favorites": 0,
"like_count": 0
}
},
"reaction_instruction": {},
"relationship": {
"is_author": false,
"is_authorized": false,
"is_favorited": false,
"is_nothelp": false,
"is_thanked": false,
"upvoted_followees": [],
"voting": 0
},
"relevant_info": {
"is_relevant": false,
"relevant_text": "",
"relevant_type": ""
},
"reshipment_settings": "allowed",
"reward_info": {
"can_open_reward": false,
"is_rewardable": false,
"reward_member_count": 0,
"reward_total_money": 0,
"tagline": ""
},
"settings": {
"table_of_contents": {
"enabled": false
}
},
"sticky_info": "",
"suggest_edit": {
"reason": "",
"status": false,
"tip": "",
"title": "",
"unnormal_details": {
"description": "",
"note": "",
"reason": "",
"reason_id": 0,
"status": ""
},
"url": ""
},
"thanks_count": 0,
"thumbnail_info": {
"count": 2,
"thumbnails": [
{
"height": 1080,
"token": "v2-0466d67e78ee71f7be3e0f89f3f181c9",
"type": "image",
"url": "https://picx.zhimg.com/80/v2-0466d67e78ee71f7be3e0f89f3f181c9_720w.jpg?source=1def8aca",
"width": 1920
}
],
"type": "thumbnail_info"
},
"type": "answer",
"updated_time": 1771691767,
"url": "https://www.zhihu.com/api/v4/answers/2008701543843652887",
"visible_only_to_author": false,
"vote_next_step": "vote",
"voteup_count": 0
},
"skip_count": false,
"position": 0,
"cursor": "abe7fc41e6e496d998ecbcf3ff1f3b85",
"is_jump_native": false
}
],
"finished_reading_filtered_count": 0,
"ad_info": {
"ad": {
"ad_verb": "",
"brand": {
"id": 0,
"logo": "https://pic3.zhimg.com/v2-6bcab51aab5519d3e668f35b0a210fc3_xl.jpg?source=d6434cab",
"name": "ima"
},
"category": 1,
"click_tracks": [
"https://sugar.zhihu.com/plutus_adreaper?ri=e0f2764e-dbf1-4920-b312-7b65d498274e&rui=e0f2764e-dbf1-49..."
],
"close_track": "https://sugar.zhihu.com/plutus_adreaper?nt=0&ft=2&ar=0.003579080570489168&qetl=0&t=7&pdi=17447741095...",
"close_tracks": [
"https://sugar.zhihu.com/plutus_adreaper?nt=0&ft=2&ar=0.003579080570489168&qetl=0&t=7&pdi=17447741095..."
],
"conversion_tracks": [
"https://sugar.zhihu.com/plutus_adreaper?ft=2&pf=4&bn=0&ar=0.003579080570489168&ed=CjEEfx4wM30oF2VTA2..."
],
"creatives": [
{
"app_promotion_url": "",
"brand": {
"id": 0,
"logo": "https://pic3.zhimg.com/v2-6bcab51aab5519d3e668f35b0a210fc3_xl.jpg?source=d6434cab",
"name": "ima"
},
"cta": {
"value": "查看详情"
},
"description": "文档处理太麻烦?智能辅助腾讯ima来帮你",
"footer": {
"value": ""
},
"image": "",
"landing_url": "https://ima.qq.com/download/?webFrom=10000435&channel=10000435&cb=https%3A%2F%2Fsugar.zhihu.com%2Fpl...",
"title": "微信文件秒存腾讯ima知识库,以后工作文件再也不怕丢了",
"video_watch_num": 116069
}
],
"debug_tracks": [
"https://sugar.zhihu.com/plutus_adreaper?ar=0.003579080570489168&bn=0&s=c93e736f-b26c-4f83-bb7a-e89dc..."
],
"display_advertising_tag": true,
"download_silent": false,
"experiment_info": "{}",
"id": 3665260,
"impression_tracks": [
"https://sugar.zhihu.com/plutus_adreaper?nt=0&pty=50&idi=100010062&t=2&bn=0&s=c93e736f-b26c-4f83-bb7a..."
],
"is_new_webview": true,
"is_speeding": false,
"name": "",
"native_prefetch": true,
"party_id": -2,
"revert_close_track": "https://sugar.zhihu.com/plutus_adreaper?qpt=0&di=tower&qetl=0&pf=4&idi=100010062&ed=CjEEch4wM30oF2VT...",
"template": "web_word",
"view_track": "https://sugar.zhihu.com/plutus_adreaper?qetl=0&ar=0.003579080570489168&ed=CjEEeR4wM30oF2VTA2J8BUZ2W3...",
"view_tracks": [
"https://sugar.zhihu.com/plutus_adreaper?qetl=0&ar=0.003579080570489168&ed=CjEEeR4wM30oF2VTA2J8BUZ2W3..."
],
"za_ad_info": "COza3wEQ7AEiATFdpV3TTmDZgd0B",
"za_ad_info_json": "{\"ad_id\":3665260,\"ad_zone_id\":236,\"category\":\"1\",\"timestamp\":1773064800,\"creative_id\":3621081}"
},
"adjson": "{\"ads\":[{\"id\":3665260,\"ad_zone_id\":236,\"template\":\"web_word\",\"impression_tracks\":[\"https://sugar.zhi...",
"position": 3
},
"session": {
"id": "1773064804697666854"
},
"paging": {
"page": 1,
"is_end": false,
"next": "https://www.zhihu.com/api/v4/questions/37811449/feeds?cursor=abe7fc41e6e496d9c018e7f8ff1f3b85&includ...",
"need_force_login": false
}
}
}💡 Note: For list data, the example shows only 1-2 items for simplicity. The actual count depends on the API response.
