翻篇收录说明
翻篇网页快照

Conversation History - Overview - Z.AI DEVELOPER DOCUMENT

https://docs.z.ai/api-reference/agents/agent-conversation

最近抓取:2026-12-03 17:58:12(北京时间)

最近内容变化:2026-12-03 17:58:12(北京时间)

这是最近一次有效抓取的文本快照,不含网页脚本、图片和动态交互内容。实际网页可能已更新。

访问原网页

页面简介

This endpoint is used to query the agent conversation history.Only support slides_glm_agent

正文摘录

cURLcURLcurl --request POST \ --url https://api.z.ai/api/v1/agents/conversation \ --header 'Authorization: Bearer <token>' \ --header 'Content-Type: application/json' \ --data ' { "agent_id": "<string>", "conversation_id": "<string>", "custom_variables": { "include_pdf": true, "pages": [ { "position": 123, "width": 123, "height": 123 } ] } } '200default{ "conversation_id": "<string>", "agent_id": "<string>", "choices": [ { "message": [ { "role": "<string>", "content": [ { "type": "<string>", "tag_cn": "<string>", "tag_en": "<string>", "file_url": "<string>", "image_url": "<string>" } ] } ] } ], "error": { "code": "<string>", "message": "<string>" } }POST/v1/agents/conversationTry itcURLcURLcurl --request POST \ --url https://api.z.ai/api/v1/agents/conversation \ --header 'Authorization: Bearer <token>' \ --header 'Content-Type: application/json' \ --data ' { "agent_id": "<string>", "conversation_id": "<string>", "custom_variables": { "include_pdf": true, "pages": [ { "position": 123, "width": 123, "height": 123 } ] } } '200default{ "conversation_id": "<string>", "agent_id": "<string>", "choices": [ { "message": [ { "role": "<string>", "content": [ { "type": "<string>", "tag_cn": "<string>", "tag_en": "<string>", "file_url": "<string>", "image_url": "<string>" } ] } ] } ], "error": { "code": "<string>", "message": "<string>" } }AuthorizationsAuthorizationstringheaderrequiredUse the following format for authentication: Bearer HeadersAccept-Languageenum<string>default:en-US,enConfig desired response language for HTTP requests.Available options: en-US,en Example:"en-US,en"Bodyapplication/jsonagent_idstringAgent IDconversation_idstringConversation IDcustom_variablesobjectCustom variablesHide child attributescustom_variables.include_pdfbooleanIs export the pdf filecustom_variables.pagesobject[]Slides PagesHide child attributescustom_variables.pages.positionnumberSlide Page Positioncustom_variables.pages.widthnumberSlide Width, unit: ptcustom_variables.pages.heightnumberSlide Height, unit: ptResponse200application/jsonProcessing successfulconversation_idstringConversation IDagent_idstringAgent IDchoicesobject[]Agent output.Hide child attributeschoices.messageobject[]Hide child attributeschoices.message.rolestringRole: fixed as assistant.choices.message.contentobject[]Content metadataHide child attributeschoices.message.content.typestringResponse Content type: file_url、image_urlchoices.message.content.tag_cnstringCN Tag.choices.message.content.tag_enstringEN Tag.choices.message.content.file_urlstringOutput file_url content when type is file_urlchoices.message.content.image_urlstringOutput image_url content when type is image_urlerrorobjectHide child attributeserror.codestringError code.error.messagestringError message.Was this page helpful?YesNo