# 影像数据
# 创建影像数据集
# 请求 URL:
http://host:port/heycloud/api/io/idataset/create
# 请求方式:
- POST
# 请求 Header:
字段 | 类型 | 是否必选 | 说明 |
---|---|---|---|
x-heycloud-admin-session | String | 是 | 通过 session 提供管理权限 |
x-heycloud-account-id | String | 是 | 帐号的唯一标识符 |
# 请求参数:
参数名称 | 可选值 | 类型 | 是否必须 | 默认值 | 说明 |
---|---|---|---|---|---|
title | - | String | 是 | - | 数据集的标题 |
bands | - | Number | 是 | - | 波段数量 |
sr | web-mercator | wgs-84 | cgcs-2000 | gcj-02 | bd-09 | String | 是 | - | 坐标系 |
# 请求示例:
POST http://host:port/heycloud/api/io/idataset/create
{
title: "2020 年 GlobeLand30 全球地表覆盖",
bands: 1,
sr: "web-mercator",
}
# 正确响应示例:
{
"result": {
"id": "<uuid>", // 数据集 ID
"title": "xxxxxx"
}
}
# 错误响应示例:
{
"error": "Error",
"message": "错误信息"
}
# 向影像数据集导入影像
# 请求 URL:
http://host:port/heycloud/api/io/idataset/:idatasetId/import
# 请求方式:
- POST
# 请求 Header:
字段 | 类型 | 是否必选 | 说明 |
---|---|---|---|
x-heycloud-admin-session | String | 是 | 通过 session 提供管理权限 |
x-heycloud-account-id | String | 是 | 帐号的唯一标识符 |
# 请求参数:
参数名称 | 类型 | 是否必须 | 默认值 | 说明 |
---|---|---|---|---|
idatasetId | String | 是 | - | 影像集的 ID |
fileId | String | 是 | - | 影像文件的 ID |
tileSize | Number | 否 | 256 | 瓦片尺寸 |
resampleMethod | String | 否 | NEAREST | 重采样方法(用于计算的数据应使用 NEAREST,用于显示的数据应使用 CUBIC) |
# 请求示例:
POST http://host:port/heycloud/api/io/idataset/xxxxx/import
{
fileId: "xxxxxxx",
tileSize: 256,
resampleMethod: "CUBIC"
}
# 正确响应示例:
{
"result": {
"id": "<uuid>", // 数据集 ID
"title": "xxxxxx"
}
}
# 错误响应示例:
{
"error": "Error",
"message": "错误信息"
}
# 获取影像数据信息
# 请求 URL:
http://host:port/heycloud/api/io/idataset/:idatasetId/:imageId
# 请求方式:
- GET
# 请求 Header:
字段 | 类型 | 是否必选 | 说明 |
---|---|---|---|
x-heycloud-admin-session | String | 是 | 通过 session 提供管理权限 |
x-heycloud-account-id | String | 是 | 帐号的唯一标识符 |
# 请求参数:
参数名称 | 类型 | 是否必须 | 默认值 | 说明 |
---|---|---|---|---|
idatasetId | String | 是 | - | 影像集的 ID |
imageId | String | 是 | - | 影像的 ID |
# 请求示例:
GET http://host:port/heycloud/api/io/idataset/:idatasetId/:imageId
# 正确响应示例:
文件正在导入
{
"result": {
"importing": {
"vdatasetId": "f94cbe0f-0e6c-4e61-8e59-9a8b3b2126c2",
"type": "feature_layer",
"fileId": "5abf5e02491cadd06d537d5448d32d39",
"startAt": "2021-03-10T03:22:29.553Z",
"importedCount": "155" // 以导入数据条数
}
}
}
文件导入成功
{
"result": {
"id": "xxxxx",
"title": "xxxxx",
"sr": "wgs-84",
"count": "525",
"createdAt": "2021-03-10T03:22:37.782Z"
}
}
# 错误响应示例:
{
"error": "Error",
"message": "错误信息"
}
# 取消导入某个影像
# 请求 URL:
http://host:port/heycloud/api/io/idataset/:idatasetId/importing/:imageId/cancel
# 请求方式:
- POST
# 请求 Header:
字段 | 类型 | 是否必选 | 说明 |
---|---|---|---|
x-heycloud-admin-session | String | 是 | 通过 session 提供管理权限 |
x-heycloud-account-id | String | 是 | 帐号的唯一标识符 |
# 请求参数:
参数名称 | 类型 | 是否必须 | 默认值 | 说明 |
---|---|---|---|---|
idatasetId | String | 是 | - | 影像集的 ID |
imageId | String | 是 | - | 影像的 ID |
# 请求示例:
POST http://host:port/heycloud/api/io/idataset/:idatasetId/importing/:imageId/cancel
# 正确响应示例:
{
"result": {...}
}
# 错误响应示例:
{
"error": "Error",
"message": "错误信息"
}
# 删除影像
# 请求 URL:
http://host:port/heycloud/api/io/idataset/:idatasetId/:imageId
# 请求方式:
- DELETE
# 请求 Header:
字段 | 类型 | 是否必选 | 说明 |
---|---|---|---|
x-heycloud-admin-session | String | 是 | 通过 session 提供管理权限 |
x-heycloud-account-id | String | 是 | 帐号的唯一标识符 |
# 请求参数:
参数名称 | 类型 | 是否必须 | 默认值 | 说明 |
---|---|---|---|---|
idatasetId | String | 是 | - | 影像集的 ID |
imageId | String | 是 | - | 影像的 ID |
# 请求示例:
DELETE http://host:port/heycloud/api/io/idataset/:idatasetId/:imageId
# 正确响应示例:
{
"result": {
"id": "68ee1874-0a86-47dd-befa-8b2328d3f64b",
"deletedAt": "2021-02-04T09:46:34.465Z"
}
}
# 错误响应示例:
{
"error": "Error",
"message": "错误信息"
}
# 将无主数据分配给某个帐号
# 请求 URL:
http://host:port/heycloud/api/io/idataset/:idatasetId/assign
# 请求方式:
- POST
# 请求 Header:
字段 | 类型 | 是否必选 | 说明 |
---|---|---|---|
x-heycloud-admin-session | String | 是 | 通过 session 提供管理权限 |
# 请求参数:
参数名称 | 类型 | 是否必须 | 默认值 | 说明 |
---|---|---|---|---|
idatasetId | String | 是 | - | 影像集的 ID |
accountId | String | 是 | - | 账号 |
# 请求示例:
POST http://host:port/heycloud/api/io/idataset/xxxxx/assign
{
accountId: 'xxxxx';
}
# 正确响应示例:
{
"result": {
"id": "68ee1874-0a86-47dd-befa-8b2328d3f64b",
"assingnedAt": "2021-02-04T09:46:34.465Z"
}
}
# 错误响应示例:
{
"error": "Error",
"message": "错误信息"
}
# 删除影像集
http://host:port/heycloud/api/io/idataset/:idatasetId
# 请求方式:
- DELETE
# 请求 Header:
字段 | 类型 | 是否必选 | 说明 |
---|---|---|---|
x-heycloud-admin-session | String | 是 | 通过 session 提供管理权限 |
x-heycloud-account-id | String | 是 | 帐号的唯一标识符 |
# 请求参数:
参数名称 | 类型 | 是否必须 | 默认值 | 说明 |
---|---|---|---|---|
idatasetId | String | 是 | - | 影像集的 ID |
# 请求示例:
DELETE http://host:port/heycloud/api/io/idataset/xxxxx
# 正确响应示例:
{
"result": {
"id": "68ee1874-0a86-47dd-befa-8b2328d3f64b",
"deletedAt": "2021-02-04T09:46:34.465Z"
}
}
# 错误响应示例:
{
"error": "Error",
"message": "错误信息"
}