Skip to main content
Threads

修改线程

修改指定线程的 metadata。

POST
/threads/{thread_id}
cURL
curl --request POST \
  --url 'https://dashscope.aliyuncs.com/api/v1/threads/{thread_id}' \
  --header 'Authorization: Bearer <YOUR_API_KEY>' \
  --header 'Content-Type: application/json' \
  --data '
{
  "metadata": {
    "modified": "true",
    "user": "abc123"
  }
}
'
{
  "id": "thread_c7ebb0ca-2e4f-43e5-b223-6e1f8c6fccc7",
  "object": "thread",
  "created_at": 1711507920700,
  "metadata": {
    "modified": "true",
    "user": "abc123"
  },
  "request_id": "a9ad63fa-b884-94be-9ec6-5000882de3c4"
}

Authorizations

string
header
required

DashScope API Key,在控制台 API Key 页面(https://bailian.console.aliyun.com/settings/apikey)获取。请求头格式:Authorization: Bearer $DASHSCOPE_API_KEY。

Path Parameters

string
required

待修改的 thread ID。

Body

application/json
object

与该 Thread 关联的 key/value 信息。

Response

200-application/json
Managed Agent API
Flow Agent API
RAG API
Connector API
框架集成
  • 框架
Assistant API(下线中)