Query skill tags¶
Query the aggregation tags of the current workspace and system default skills. The numbers of identical tags in the two directories are merged.
GET https://api.moi.matrixorigin.cn/v5/workspaces/{workspace_id}/skills/tags
Before you call¶
Prepare a personal access token and target workspace ID that has access to the target workspace.
The example below uses:
$AI_STUDIO_API_KEY: The actual personal access token, passed through theX-API-KeyHeader.$WORKSPACE_ID: The workspace ID to be queried is passed through theX-Workspace-IDHeader.
Request example¶
curl "https://api.moi.matrixorigin.cn/v5/workspaces/$WORKSPACE_ID/skills/tags" \
-H "X-API-Key: $AI_STUDIO_API_KEY" \
-H "X-Workspace-ID: $WORKSPACE_ID"
Path parameters¶
Parameters |
Type |
Is it required |
Description |
|---|---|---|---|
|
string |
Yes |
The current workspace ID. |
Successful response¶
Returns 200 on success. Tags are first sorted by quantity in descending order, and if the quantity is the same, they are sorted by tag name.
{
"code": 0,
"data": {
"items": [
{
"tag": "文本处理",
"count": 3
},
{
"tag": "摘要",
"count": 1
}
]
}
}
The response fields are as follows.
Field |
Type |
Description |
|---|---|---|
|
integer |
|
|
array |
Aggregated tag list. |
|
string |
Tag name. |
|
integer |
The total number of times this tag is used in the current workspace and system default skills. |
[] after a type denotes an array. [] in a field path denotes each item in an array.
Error response¶
{
"code": 2,
"message": "<错误信息>"
}
Common HTTP errors¶
HTTP status code |
error code |
Common causes |
Recommended actions |
|---|---|---|---|
|
|
Invalid workspace ID. |
Check path parameters. |
|
|
Lack of valid identity credentials. |
Check API Key. |
|
|
The current identity does not have permission to read workspace skills. |
Check workspace authorization. |
|
|
Skill services or authorized dependencies are temporarily unavailable. |
Try again later. |
Follow-up operations¶
Tags are used for filtering. After selecting the tag, return to Query skill list to filter by tag.