Skip to main content

Get Agent

Returns the full configuration of an agent by ID. Returns the latest version by default; use the version parameter to specify a historical version.

Prerequisites

Endpoint and authentication configured. For details, see Overview and authentication.

Endpoint

GET /agents/{agent_id}

Query parameters

version int (可选)Version number to retrieve; returns the latest version if not specified

Request example

# Default: latest version
curl "$AGENTSTUDIO_URL/agents/agent_xxx" \
  -H "Authorization: Bearer $DASHSCOPE_API_KEY"

# Specific version
curl "$AGENTSTUDIO_URL/agents/agent_xxx?version=3" \
  -H "Authorization: Bearer $DASHSCOPE_API_KEY"

Response fields

id stringAgent ID, format: agent_<ULID>type stringAlways agentversion intCurrent version number, auto-incremented on each update; locked when a session is createdname / description / system stringAgent name, description, and system promptmodel / tools / mcp_servers / skills / multiagent / metadata object / arrayModel, toolkits, MCP references, skills, multi-agent collaboration, and business metadata; structure same as at creationarchived_at string | nullArchive timestamp; null if not archivedcreated_at / updated_at stringCreation / last update time, ISO 8601workspace_id stringWorkspace IDrequest_id stringUnique identifier for this request

Response example

{
  "id": "agent_xxx",
  "type": "agent",
  "version": 1,
  "name": "data-analyst",
  "description": "Data analysis assistant",
  "model": {"id": "qwen3.7-max"},
  "system": "You are a data analysis expert who uses pandas to process CSV files.",
  "tools": [],
  "mcp_servers": [],
  "skills": [],
  "multiagent": {
    "type": "coordinator",
    "agents": [
      {"type": "self"},
      {"type": "agent", "id": "agent_researcher", "version": 3}
    ]
  },
  "metadata": {"team": "data"},
  "created_at": "2026-05-28T16:23:11.456+08:00",
  "updated_at": "2026-05-28T16:23:11.456+08:00",
  "archived_at": null,
  "workspace_id": "ws_xxx",
  "request_id": "req_xxx"
}