Use the GetWikiPage operation to read the full body content of a currently published page by its page path.
Prerequisites
-
An AgentStorage instance has been created and its status is
normal, and you have obtained the instance endpoint and instance name. -
An API Key has been created.
-
Wiki operations require a complete three-segment Agent Scope (
appId/tenantId/agentId). Each segment must be non-empty and cannot be*, with a maximum length of 128 bytes, and must not contain/. Do not pass inrunId. -
The page path must come from the return value of
SearchWikiPagesorListWikiPages, starting with/wiki/and ending with.md.
Request parameters
|
Field |
Type |
Required |
Description |
|
|
string |
Yes |
The name of the memory store. |
|
|
object |
Yes |
The complete three-segment Agent Scope, with the same rules as |
|
|
string |
Yes |
The page path returned by |
Request example
When using API Key authentication, pass the instance name and API Key through the x-ots-instancename and x-ots-apikey request headers.
curl -X POST https://<endpoint>/GetWikiPage \
-H "x-ots-instancename: <instance-name>" \
-H "x-ots-apikey: <your-api-key>" \
-H "Content-Type: application/json" \
-d '{
"memoryStoreName": "agent_memory",
"scope": {
"appId": "app-001",
"tenantId": "user-001",
"agentId": "assistant"
},
"path": "/wiki/payment-callback.md"
}'
Response
The fields of the Wiki page object are as follows.
|
Field |
Description |
|
|
The page path. |
|
|
The page title. |
|
|
The page type, for example |
|
|
The page summary or description. |
|
|
The Markdown body content. Only returned by |
|
|
The list of source paths used to generate the page, for example |
|
|
The Wiki page paths that this page links to. |
|
|
The Wiki page paths that link to the current page. A maximum of 256 entries are returned. |
|
|
The total number of links pointing to the current page. |
|
|
Whether |
|
|
The search score. Only returned by |
{
"path": "/wiki/payment-callback.md",
"title": "支付回调",
"type": "guide",
"description": "支付回调的幂等与验签要求",
"content": "# 支付回调\n\n支付回调必须校验幂等键。",
"sources": [
"raw/product/payment.md"
],
"outgoingLinks": [
"/wiki/payment-overview.md"
],
"incomingLinkCount": 1
}