All Products
Search
Document Center

Cloud Monitor:GetThreadData

Last Updated:Jan 20, 2026

Retrieves session data.

Operation description

Retrieves session data.

Try it now

Try this API in OpenAPI Explorer, no manual signing needed. Successful calls auto-generate SDK code matching your parameters. Download it with built-in credential security for local usage.

Test

RAM authorization

The table below describes the authorization required to call this API. You can define it in a Resource Access Management (RAM) policy. The table's columns are detailed below:

  • Action: The actions can be used in the Action element of RAM permission policy statements to grant permissions to perform the operation.

  • API: The API that you can call to perform the action.

  • Access level: The predefined level of access granted for each API. Valid values: create, list, get, update, and delete.

  • Resource type: The type of the resource that supports authorization to perform the action. It indicates if the action supports resource-level permission. The specified resource must be compatible with the action. Otherwise, the policy will be ineffective.

    • For APIs with resource-level permissions, required resource types are marked with an asterisk (*). Specify the corresponding Alibaba Cloud Resource Name (ARN) in the Resource element of the policy.

    • For APIs without resource-level permissions, it is shown as All Resources. Use an asterisk (*) in the Resource element of the policy.

  • Condition key: The condition keys defined by the service. The key allows for granular control, applying to either actions alone or actions associated with specific resources. In addition to service-specific condition keys, Alibaba Cloud provides a set of common condition keys applicable across all RAM-supported services.

  • Dependent action: The dependent actions required to run the action. To complete the action, the RAM user or the RAM role must have the permissions to perform all dependent actions.

Action

Access level

Resource type

Condition key

Dependent action

cms:GetThreadData

get

*DigitalEmployee

acs:cms:{#regionId}:{#accountId}:digitalemployee/{#name}/thread/{#threadId}

None None

Request syntax

GET /digitalEmployee/{name}/thread/{threadId}/data HTTP/1.1

Path Parameters

Parameter

Type

Required

Description

Example

name

string

Yes

The name of the digital employee.

test

threadId

string

Yes

The session ID.

thread_id01

Request parameters

Parameter

Type

Required

Description

Example

nextToken

string

No

The pagination token.

xxxxxxxxxx

maxResults

integer

No

The maximum number of session data entries to return. The maximum value is 100.

1

Response elements

Element

Type

Description

Example

object

The response schema.

maxResults

integer

The maximum number of results.

1

data

array<object>

The message data.

array<object>

An entry of message data.

traceId

string

The ID of the current message request. This is the first trace ID in the root data.

3b5287b717636040171772050d0095

requestId

string

The ID of the current message request. This is the first request ID in the root data.

8FDE2569-626B-5176-9844-28877A*****

messages

array<object>

A list of messages in the session.

array<object>

The structure of a message.

version

string

The version of the message data.

v0.1.0

parentCallId

string

The execution ID of the parent level.

3b5287b7176360

callId

string

The execution ID.

3b5287b7176360

role

string

The role that sent the message.

user

seq

integer

The sequence number of the message.

0

timestamp

string

The timestamp in nanoseconds.

1768702985000000000

type

string

The type of the message.

task_finished

detail

string

The details of the message.

context of model exceed

contents

array<object>

The message content.

object

The structure of the content.

{ "append": false, "lastChunk": false, "type": "text", "value": "result output chunk" }

tools

array<object>

A list of tools that were used.

object

The structure of a tool.

{ "arguments": { "confidence": "high", "intent": "analyser", "is_new_turn": true, "language": "en", "title": "Root Cause of Alert" }, "id": "IntentRecognition", "name": "IntentRecognition", "status": "start", "toolCallId": "019bc1cb-adad" }

agents

array<object>

A list of invoked agents.

object

Details of the agent that was called.

{ "callId": "019bc1cb-adad", "id": "analyser", "inputs": [ { "append": false, "lastChunk": false, "type": "text", "value": "Analyze this trace: TraceID=xxx" } ], "name": "analyser", "status": "start" }

events

array<object>

A list of events.

object

The details of the event.

{ "payload": { "error": { "code": "TASK_FAILED", "message": "Invalid task parameter", "suggestion": "" }, "statistics": { "duration": 300000 }, "success": false }, "type": "task_finished" }

artifacts

array<object>

Information about the generated artifacts.

object

The structure of an artifact.

{ "artifactId": "019bc1cb-9600-703axxx", "name": "sql output", "description": "sql generation task result", "extensions": ["sql_generation_tool", "sql_diagnosis"], "metadata": { "model": "qwen3-coder-plus" }, "parts": [ { "text": "select * from table", "kind": "text" } ] }

nextToken

string

The pagination token.

xxxxxxxxx

requestId

string

The ID of the request.

8FDE2569-626B-5176-9844-28877A*****

threadId

string

The session ID.

thread_id01

digitalEmployeeName

string

The name of the digital employee.

test

Examples

Success response

JSON format

{
  "maxResults": 1,
  "data": [
    {
      "traceId": "3b5287b717636040171772050d0095",
      "requestId": "8FDE2569-626B-5176-9844-28877A*****",
      "messages": [
        {
          "version": "v0.1.0",
          "parentCallId": "3b5287b7176360",
          "callId": "3b5287b7176360",
          "role": "user",
          "seq": 0,
          "timestamp": "1768702985000000000",
          "type": "task_finished",
          "detail": "context of model exceed",
          "contents": [
            {
              "append": false,
              "lastChunk": false,
              "type": "text",
              "value": "result output chunk"
            }
          ],
          "tools": [
            {
              "arguments": {
                "confidence": "high",
                "intent": "analyser",
                "is_new_turn": true,
                "language": "en",
                "title": "Root Cause of Alert"
              },
              "id": "IntentRecognition",
              "name": "IntentRecognition",
              "status": "start",
              "toolCallId": "019bc1cb-adad"
            }
          ],
          "agents": [
            {
              "callId": "019bc1cb-adad",
              "id": "analyser",
              "inputs": [
                {
                  "append": false,
                  "lastChunk": false,
                  "type": "text",
                  "value": "Analyze this trace: TraceID=xxx"
                }
              ],
              "name": "analyser",
              "status": "start"
            }
          ],
          "events": [
            {
              "payload": {
                "error": {
                  "code": "TASK_FAILED",
                  "message": "Invalid task parameter",
                  "suggestion": ""
                },
                "statistics": {
                  "duration": 300000
                },
                "success": false
              },
              "type": "task_finished"
            }
          ],
          "artifacts": [
            {
              "artifactId": "019bc1cb-9600-703axxx",
              "name": "sql output",
              "description": "sql generation task result",
              "extensions": [
                "sql_generation_tool",
                "sql_diagnosis"
              ],
              "metadata": {
                "model": "qwen3-coder-plus"
              },
              "parts": [
                {
                  "text": "select * from table",
                  "kind": "text"
                }
              ]
            }
          ]
        }
      ]
    }
  ],
  "nextToken": "xxxxxxxxx",
  "requestId": "8FDE2569-626B-5176-9844-28877A*****",
  "threadId": "thread_id01",
  "digitalEmployeeName": "test"
}

Error codes

See Error Codes for a complete list.

Release notes

See Release Notes for a complete list.