Resolve a public Web app link¶
Short-code responses include agent_id; webapp/t form returns agent_name only. Resolution checks publication availability, not whether the agent can currently run, a session was issued, or business calls succeed.
POST https://api.moi.matrixorigin.cn/v5/public/webapp/resolve
Before you call this API¶
Set BASE_URL to the product API prefix https://api.moi.matrixorigin.cn/v5. For private deployments, use the corresponding product API URL.
Prepare links and visitor identity in the same environment. Do not supply a product PAT or Workspace request header.
Request¶
curl --request POST \
"$BASE_URL/public/webapp/resolve" \
--header "Content-Type: application/json" \
--data @- <<JSON
{"k": "${WEBAPP_SHORT_CODE}"}
JSON
Parameter |
Location |
Type |
Required |
Description |
|---|---|---|---|---|
|
Body |
string |
Condition |
22-character short code; mutually exclusive with webapp/t. |
|
Body |
string |
Condition |
Agent ID from a legacy link; provide together with t. |
|
Body |
string |
Condition |
Publication token from a legacy link; provide together with webapp. |
Successful response¶
{
"code": 0,
"data": {
"agent_name": "示例智能体",
"agent_id": "agent-example"
}
}
Success returns HTTP 200 with numeric code=0. Read data’s Object descriptions with the example; the conversation-creation example shows a field excerpt only.
Error responses¶
Public errors and identity handling distinguishes unavailable links, disablement, invalid sessions, parameters, and system failures.