Query Catalog details¶
Query the details of a Catalog by ID.
POST https://moi.matrixorigin.cn/newmoi/catalog/info
Preparation before calling¶
First query the catalog list to obtain the target catalog ID. Prepare the personal access token, target workspace ID, and Catalog ID that have 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: Target workspace ID, passed throughX-Workspace-IDHeader.$CATALOG_ID: Catalog ID to be queried.
Request example¶
curl -X POST "https://moi.matrixorigin.cn/newmoi/catalog/info" \
-H "X-API-Key: $AI_STUDIO_API_KEY" \
-H "X-Workspace-ID: $WORKSPACE_ID" \
-H 'Content-Type: application/json' \
-d '{
"id": '"$CATALOG_ID"'
}'
Request body¶
Parameter |
Type |
Required |
Description |
|---|---|---|---|
|
integer |
Yes |
Catalog ID. |
Successful response¶
Returns 200 and Catalog details on success.
{
"code": "OK",
"msg": "OK",
"data": {
"catalog": {
"id": 1,
"name": "sales",
"display_name": "sales",
"description": "销售数据",
"display_description": "销售数据"
}
}
}
The response fields are as follows.
Field |
Type |
Description |
|---|---|---|
|
string |
|
|
string |
|
|
integer |
Catalog ID. |
|
string |
Catalog original name. |
|
string |
Catalog description. |
|
string |
Catalog display name; returned if there is a value. |
|
string |
Catalog Display description; return if there is a value. |
Error response¶
{
"code": "ErrObjectNotFound",
"msg": "Catalog 不存在",
"data": null
}
Common HTTP errors¶
HTTP status code |
error code |
Common causes |
Recommended actions |
|---|---|---|---|
|
|
The request body cannot be parsed or |
Positive integer IDs returned using a list. |
|
|
The current identity does not have Catalog read permission. |
Requesting permission to |
|
|
Catalog does not exist or cannot be read. |
Verify Catalog ID and workspace. |
|
|
The server failed to read the details. |
Try again later. |
Follow-up operations¶
When modifications are needed Update Catalog. When returning the list Query file products.