cURL
Authorizations
string
header
required
DashScope API Key,在控制台 API Key 页面(https://rag.console.aliyun.com/settings/apikey)获取。
在当前业务空间下创建新的类目
curl -X POST "https://{workspaceId}.cn-beijing.maas.aliyuncs.com/api/v1/connector/dash/addCategory" \
-H "Authorization: Bearer $DASHSCOPE_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"categoryName": "产品文档",
"categoryType": "UNSTRUCTURED"
}'{
"code": "Success",
"message": "",
"messageUnmodified": false,
"requestId": "xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx",
"data": {
"categoryId": "cate_xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx_xxxxxx",
"categoryName": "_tmp_example"
},
"status": 200
}DashScope API Key,在控制台 API Key 页面(https://rag.console.aliyun.com/settings/apikey)获取。
curl -X POST "https://{workspaceId}.cn-beijing.maas.aliyuncs.com/api/v1/connector/dash/addCategory" \
-H "Authorization: Bearer $DASHSCOPE_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"categoryName": "产品文档",
"categoryType": "UNSTRUCTURED"
}'{
"code": "Success",
"message": "",
"messageUnmodified": false,
"requestId": "xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx",
"data": {
"categoryId": "cate_xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx_xxxxxx",
"categoryName": "_tmp_example"
},
"status": 200
}