Query file products¶
Query file product information by file ID.
GET $CLOUDSIGMA_API_BASE/catalog/file-artifacts/{file_id}
Before you call this API¶
Configure the regional API endpoint and authentication, and select the target workspace.
First query the file list to obtain the target file ID.
Set the operation-specific values used in the request:
$FILE_ID: The file ID of the product to be queried.
Request¶
curl "$CLOUDSIGMA_API_BASE/catalog/file-artifacts/$FILE_ID" \
-H "X-API-Key: $CLOUDSIGMA_API_KEY" \
-H "X-Workspace-ID: $WORKSPACE_ID"
Path parameters
Parameters |
Type |
Description |
|---|---|---|
|
string |
File ID. |
Successful response¶
Returns 200 and file product information when successful; returns 404 when the file does not exist.
{
"code": "OK",
"msg": "OK",
"data": {
"file_id": "file-123",
"file_exists": true,
"has_artifact": false,
"derivations": [],
"assets_by_id": {}
}
}
The response fields are as follows.
Field |
Type |
Description |
|---|---|---|
|
string |
|
|
string |
|
|
string |
The queried file ID. |
|
boolean |
Whether the file exists. |
|
boolean |
Whether the file has related products. |
|
string |
Source file ID; may be omitted if not available. |
|
string |
Parsed product file ID; can be omitted if not available. |
|
object |
Root data asset; may be omitted if not available. |
|
object |
Data asset in processing; may be omitted if not available. |
|
object |
The parsed data asset; may be omitted if not available. |
|
array |
Data asset derivation relationship. |
|
object |
Mapping metadata between original file and parsed product; may be omitted if not available. |
|
object |
Related assets indexed by asset ID. |
Error response¶
{
"code": "ErrNotFound",
"msg": "对象不存在",
"data": null
}
Common HTTP errors¶
HTTP status code |
error code |
Common causes |
Recommended actions |
|---|---|---|---|
|
|
|
Pass in a valid file ID. |
|
|
The current identity does not have read permission on the root volume to which it belongs. |
Use credentials with read access, or contact your administrator for authorization. |
|
|
File does not exist. |
Check file ID. |
|
|
The service cannot read the file product. |
Record the request time and error message and try again; if it continues to fail, contact support. |
Follow-up operations¶
Save the identification of the target item and then Query Catalog details.