CreateStarOpsChat - Send a message in a DevOps AI thread
Calling this API consumes AI credits. For billing rules, refer to AI Assistant management.
Applicable editions | Central edition, Region edition |
Service endpoint and authorization
Obtain a service endpoint and replace {domain} in the API request syntax.
Obtain an organization ID: Required only for the Central edition. Go to the organization management console and get the organization ID on the Basic Information page.
Product | Resource | Required permission |
DevOps AI Assistant | Q&A | Read and write |
Request syntax
Central edition
POST https://{domain}/oapi/v1/aiAssistant/organizations/{organizationId}/chatRegion edition
POST https://{domain}/oapi/v1/aiAssistant/chatRequest headers
Parameter | Type | Required | Description | Example |
x-yunxiao-token | string | Yes | The personal access token. | pt-0fh3****0fbG_35af****0484 |
Request parameters
Parameter | Type | In | Required | Description | Example |
organizationId | string | path |
| [Description pending] | |
Accept | string | header | Yes | [Description pending] | |
| - | object | body | No | [Description pending] | |
message | string | body | Yes | The user message text. Maximum: 65536 UTF-8 bytes. | |
threadId | string | body | Yes | [Description pending] |
Request examples
Central edition
curl -X 'POST' \
'https://{domain}/oapi/v1/aiAssistant/organizations/{organizationId}/chat' \
-H 'Content-Type: application/json' \
-H 'x-yunxiao-token: pt-0fh3****0fbG_35af****0484' \
--data '
{
"message": "",
"threadId": ""
}'Region edition
curl -X 'POST' \
'https://{domain}/oapi/v1/aiAssistant/chat' \
-H 'Content-Type: application/json' \
-H 'x-yunxiao-token: pt-0fh3****0fbG_35af****0484' \
--data '
{
"message": "",
"threadId": ""
}'Response parameters
Parameter | Type | Description | Example |
- | string |
Response sample
Error codes
For error codes, see the Error Code Center.