Update skills¶
Partially update the skills in the current workspace. Fields not provided retain their original values. Instead of just updating the tag, updates create a new skill version and make it the current version.
PATCH $CLOUDSIGMA_API_BASE/workspaces/{workspace_id}/skills/{skill_id}
Before you call¶
Configure the CloudSigma regional endpoint and authentication before calling. The endpoint, credentials, workspace, and resource IDs must belong to the same region. First Query skill details to confirm the skill to be updated. Prepare the personal access token, target workspace ID, and skill ID that can access the target workspace.
Request body¶
curl -X PATCH "$CLOUDSIGMA_API_BASE/workspaces/$WORKSPACE_ID/skills/$SKILL_ID" \
-H "X-API-Key: $CLOUDSIGMA_API_KEY" \
-H "X-Workspace-ID: $WORKSPACE_ID" \
-H 'Content-Type: application/json' \
-d '{
"description": "更新后的说明",
"change_summary": "补充输出约定"
}'
Parameter |
Type |
Required |
Description |
|---|---|---|---|
|
string |
Yes |
Current workspace ID. |
|
string |
Yes |
The skill ID to update. |
|
string |
No |
The workspace to which the skill belongs. It can only be the current workspace or |
|
string |
No |
Basic definition of skills. The status can be |
|
string |
No |
Basic definition of skills. The status can be |
|
string |
No |
Basic definition of skills. The status can be |
|
string |
No |
Basic definition of skills. The status can be |
|
string |
No |
Basic definition of skills. The status can be |
|
string |
No |
Classify and display information. Providing |
|
string |
No |
Classify and display information. Providing |
|
array of string |
No |
Classify and display information. Providing |
|
string |
No |
Classify and display information. Providing |
|
string |
No |
Classify and display information. Providing |
|
object |
No |
Route summary, directives and dependency requirements. |
|
object |
No |
Route summary, directives and dependency requirements. |
|
object |
No |
Route summary, directives and dependency requirements. |
|
object |
No |
Input Schema and output conventions. |
|
object |
No |
Input Schema and output conventions. |
|
object |
No |
Market metadata, tags, annotations and extended metadata. |
|
object |
No |
Market metadata, tags, annotations and extended metadata. |
|
object |
No |
Market metadata, tags, annotations and extended metadata. |
|
object |
No |
Market metadata, tags, annotations and extended metadata. |
|
string |
No |
Change notes for the new version. |
The fields in the request body are optional. Fields not provided retain their original values.
The updated skill must still retain the instruction body or route summary and satisfy the validation rules for skill dependency references.
Successful response¶
{
"code": 0,
"data": {
"id": "skill_01",
"workspace_id": "ws_01",
"name": "摘要技能",
"description": "更新后的说明",
"status": "active",
"source_type": "custom",
"instruction": {
"body": "总结用户提供的内容。"
},
"version": 3,
"updated_at": "2026-01-03T10:00:00Z",
"routing_summary": {},
"requirements": {},
"created_at": "2026-01-02T15:04:05Z"
}
}
Field |
Type |
Description |
|---|---|---|
|
integer |
|
|
object |
The result of this request. |
|
object |
Extended comments. Can be omitted if empty or not set. |
|
string |
classification. Can be omitted if empty or not set. |
|
string |
Creation time. Use RFC 3339 format. |
|
string |
Creator ID. Can be omitted if empty or not set. |
|
string |
Description. Can be omitted if empty or not set. |
|
string |
Icon reference. Can be omitted if empty or not set. |
|
string |
Skill ID. |
|
object |
An empty object is returned when the skill command has no subfields. |
|
string |
Instruction text. Can be omitted if empty or not set. |
|
object |
JSON Schema of directive variables. Can be omitted if empty or not set. |
|
object |
Extension tag. Can be omitted if empty or not set. |
|
object |
Market metadata. Can be omitted if empty or not set. |
|
object |
Extended metadata. Can be omitted if empty or not set. |
|
string |
Name. |
|
object |
Output convention. Can be omitted if empty or not set. |
|
object |
JSON Schema of skill input parameters. Can be omitted if empty or not set. |
|
string |
use stage. Can be omitted if empty or not set. |
|
string |
Pipeline reference. Can be omitted if empty or not set. |
|
object |
Returns an empty object when skill dependency requires no subfields. |
|
string |
Description. Can be omitted if empty or not set. |
|
array |
Document input requirements. Can be omitted if empty or not set. |
|
string |
Description. Can be omitted if empty or not set. |
|
array |
Accepted file media types. Can be omitted if empty or not set. |
|
string |
Name. Can be omitted if empty or not set. |
|
boolean |
Is it required? Can be omitted if empty or not set. |
|
array |
knowledge base role requirements. Can be omitted if empty or not set. |
|
string |
Description. Can be omitted if empty or not set. |
|
boolean |
Is it required? Can be omitted if empty or not set. |
|
string |
knowledge base role. Can be omitted if empty or not set. |
|
array |
Model capability requirements. Can be omitted if empty or not set. |
|
array |
Dependent skill identifier. Can be omitted if empty or not set. |
|
array |
Dependent tool identifier. Can be omitted if empty or not set. |
|
array |
Tool resource references. Can be omitted if empty or not set. |
|
string |
Description of binding capabilities. Can be omitted if empty or not set. |
|
boolean |
Whether it can be bound. Can be omitted if empty or not set. |
|
string |
Binding source. Can be omitted if empty or not set. |
|
string |
classification. Can be omitted if empty or not set. |
|
object |
Resource allocation. Can be omitted if empty or not set. |
|
string |
Description. Can be omitted if empty or not set. |
|
string |
Display name. Can be omitted if empty or not set. |
|
string |
Reference item ID. Can be omitted if empty or not set. |
|
string |
Tool type. Can be omitted if empty or not set. |
|
boolean |
Is it manageable. Can be omitted if empty or not set. |
|
string |
Name. Can be omitted if empty or not set. |
|
string |
use stage. Can be omitted if empty or not set. |
|
string |
The ID of the referenced object. Can be omitted if empty or not set. |
|
string |
Runtime tool visibility. Can be omitted if empty or not set. |
|
string |
status. Can be omitted if empty or not set. |
|
array |
Supported runtimes. Can be omitted if empty or not set. |
|
string |
The identity of the workspace to which it belongs. Can be omitted if empty or not set. |
|
object |
Returns an empty object when the skill routing summary has no subfields. |
|
array |
Routing example. Can be omitted if empty or not set. |
|
string |
Route summary text. Can be omitted if empty or not set. |
|
string |
Source information. Can be omitted if empty or not set. |
|
string |
Source type. |
|
string |
status. |
|
array |
label. Can be omitted if empty or not set. |
|
string |
Last updated time. Use RFC 3339 format. |
|
string |
Last updated by identifier. Can be omitted if empty or not set. |
|
integer |
Version number. |
|
string |
The identity of the workspace to which it belongs. |
Error response¶
{
"code": 2,
"message": "<错误信息>"
}
Common HTTP errors
HTTP status code |
error code |
Description |
|---|---|---|
|
|
Common causes: The request field, dependency reference, or updated skill definition is invalid. Recommended Action: Check the field value, directive or route summary, and dependent resources. |
|
|
Common Cause: Valid identity credentials are missing. Recommended Action: Check the API Key. |
|
|
Common reasons: The current identity does not have the permission to update skills. Recommended Action: Check the workspace authorization. |
|
|
Common reasons: Specify system skills as read-only. Recommended Action: Do not modify system skills. Create or update your skills in the current workspace. |
|
|
Common reasons: The skill does not exist in the specified workspace. Recommended Action: Check the skill ID and |
|
|
Common reasons: The skill version has been modified by another request before submission. Recommended action: Re-query the current skills and confirm the changes before submitting. |
|
|
Common reasons: Skill services or authorization dependencies are temporarily unavailable. Recommended Action: Try again later. |