Appearance
Query Metadata Page API
API Information
- Request Path:
/metadata/query/page - Request Method:
POST - Content-Type:
application/json
Request Headers
| Parameter | Type | Required | Description |
|---|---|---|---|
| Authorization | String | Yes | User authentication token |
| Content-Type | String | Yes | Must be set to application/json |
Request Body Structure
MetaDataReq Object
| Field | Type | Required | Description | Constraints |
|---|---|---|---|---|
| page | Integer | Yes | Page number | Must be positive integer |
| size | Integer | Yes | Page size | Must be positive integer |
| name | String | No | Metadata name filter | Optional name filter |
| userId | String | No | User ID filter | Optional user filter |
| tagIds | List<Long> | No | Tag IDs filter | Optional tag filter |
| dataTypes | List<Integer> | No | Data types filter | Optional data type filter |
| enables | List<Integer> | No | Enable status filter | Optional enable status filter |
| publishStatuses | List<Integer> | No | Publish status filter | Optional publish status filter |
| datasetId | Long | No | Dataset ID filter | Optional dataset filter |
Request Body Example
json
{
"page": 1,
"size": 10,
"name": "Satellite",
"datasetId": 12345,
"tagIds": [1, 2],
"dataTypes": [1, 2],
"enables": [1],
"publishStatuses": [1]
}Response Body Structure
CommonResponse Object
| Field | Type | Description |
|---|---|---|
| code | Integer | Response status code |
| message | String | Response message |
| data | MetaDataResp | Metadata list response |
MetaDataResp Object
| Field | Type | Description |
|---|---|---|
| total | Long | Total number of records |
| pages | Integer | Total number of pages |
| metaDataVoList | List<MetaDataVo> | List of metadata records |
MetaDataVo Object
| Field | Type | Description |
|---|---|---|
| id | Long | Metadata ID |
| code | String | Metadata code |
| name | String | Metadata name |
| dataFileId | Long | Data file ID |
| thumbnailUrl | String | Thumbnail URL |
| creator | String | Creator name |
| creatorAvatarUrl | String | Creator avatar URL |
| createTime | Long | Creation timestamp |
| modifyTime | Long | Modification timestamp |
| captureTime | String | Image capture time |
| bands | String | Band combination |
| cloudCover | String | Cloud coverage percentage |
| sensorType | String | Sensor type |
| dataFileType | String | Data file type |
| dataType | Integer | Data type |
| fileSize | Double | File size in GB |
| enable | Integer | Enable status (0-disabled, 1-enabled) |
| dirPath | String | Directory path |
| resolution | String | Resolution |
| satelliteName | String | Satellite name |
| datasetId | Long | Dataset ID |
| datasetName | String | Dataset name |
| publishStatus | Integer | Publish status |
| releaseData | List<ReleaseData> | Release data information |
| detailReleaseData | List<ReleaseData> | Detailed release data information |
| tagInfos | List<MetaDataTagInfoVo> | Tag information |
ReleaseData Object (Nested in MetaDataVo)
| Field | Type | Description |
|---|---|---|
| protoc | Integer | Protocol type |
| publishStatus | Integer | Publish status |
| taskId | String | Task ID |
| errorMessage | String | Error message |
Response Examples
Success Response
json
{
"code": 200,
"message": "success",
"data": {
"total": 50,
"pages": 5,
"metaDataVoList": [
{
"id": 1,
"name": "Satellite Image 001",
"dataFileId": 12345,
"dataType": 1,
"fileSize": 1.024,
"createTime": 1704105600000,
"modifyTime": 1704105600000,
"captureTime": "2024-01-01T10:00:00Z",
"resolution": "10m",
"publishStatus": 1,
"releaseData": [
{
"protoc": 1,
"publishStatus": 1,
"taskId": "task-001",
"errorMessage": null
}
],
"tagInfos": [
{
"tagId": 1,
"tagName": "Satellite"
}
]
}
]
}
}Failure Response
json
{
"code": 400,
"message": "Invalid request parameters",
"data": null
}Error Code Description
| Error Code | Description |
|---|---|
| 200 | Success |
| 400 | Request parameter error |
| 401 | Unauthorized |
| 500 | Server internal error |
Usage Instructions
- This API is used to query metadata list with pagination
- User authentication is required
- Supports filtering by metadata name and dataset ID
- Returns paginated results with total count
Notes
- User authentication token must be included in request headers
- Request body must be valid JSON format
- Pagination parameters are required
- Demo users can only see their own metadata