Read visitor task events incrementally

after_seq echoes the requested cursor, not a server next cursor. total counts projections returned in this response. For the next read, use the largest seq actually received. An empty page does not mean task completion. No limit/offset parameters exist here.

GET https://api.moi.matrixorigin.cn/v5/public/webapp/conversations/{conversation_id}/tasks/{task_id}/events

Before you call this API

Set BASE_URL to the product API prefix https://api.moi.matrixorigin.cn/v5; use the corresponding product API URL for a dedicated deployment.

Prepare links and visitor identity in the same environment. Do not supply a product PAT or workspace request headers.

Request

curl --request GET \
  "$BASE_URL/public/webapp/conversations/$CONVERSATION_ID/tasks/$TASK_ID/events?webapp=$AGENT_ID&t=$WEBAPP_TOKEN&s=$WEBAPP_SESSION&after_seq=0"

Parameter

Location

Type

Required

Description

webapp

Queries

string

Yes

Agent ID associated with the link.

t

Queries

string

Yes

Currently valid publication token. For short-code links, resolve first, then use the short code as t.

s

Queries

string

Yes

Visitor session credential for the same publication.

conversation_id

Path

string

Yes

Active Web App conversation created by this visitor.

task_id

Path

string

Yes

Task ID under that conversation.

after_seq

Queries

integer

No

Read only larger seq values. Missing, invalid, or negative values use 0.

Successful response

{
  "code": 0,
  "data": {
    "items": [],
    "total": 0,
    "after_seq": 0
  }
}

Success returns HTTP 200 and numeric code=0. Read data’s object descriptions alongside the example. The conversation creation example is only a field excerpt.

Error responses

Public errors and identity handling distinguishes unavailable/disabled links, invalid sessions, parameters, and system failures.

Last updated on