创建任务
POST
/task/api/v1.0/projects/{project_uuid}/flight-tasks请求参数
Path 参数
project_uuid
string
必需
Header 参数
X-Organization-Key
string
组织密钥
示例值:
{{organization_key}}
Body 参数application/json
name
string
计划名称
sn
string
起飞机场SN
landing_dock_sn
string
可选
降落机场SN,非蛙跳任务可不填
time_zone
string
必需
时区,TZ database中的时区名称
wayline_uuid
string
航线文件uuid
rth_altitude
number
必需
返航高度,单位m,目前只接受整数
rth_mode
enum<integer>
可选
返航模式(0:智能高度 1:设定高度)
枚举值:
01
默认值:
1
wayline_precision_type
enum<integer>
可选
任务精度(0: GPS 1:RTK)
枚举值:
01
默认值:
1
out_of_control_action_in_flight
enum<integer>
必需
丢失信号后无人机动作(1:返航 2:继续执行)
枚举值:
12
resumable_status
enum<string>
必需
自动断点续飞(auto:自动断点续飞 manual:手动断点续飞)
枚举值:
automanual
tags
array[string]
设备直传标签
>= 0 items<= 10 items
media_direct_transfer
boolean
可选
设备直传开关,为空则上传司空2
默认值:
false
task_type
enum<integer>
必需
当前只支持立即任务(类型1)
枚举值:
1
示例
{
"name": "斗战影红给热",
"sn": "DOCKSN1",
"landing_dock_sn": "DOCKSN2",
"time_zone": "Asia/Chongqing",
"wayline_uuid": "3f6fa0d6-765d-4b7d-92c5-1a2213b8c0f0",
"rth_altitude": 24,
"out_of_control_action_in_flight": 2,
"resumable_status": "auto",
"task_type": 1
}
示例代码
返回响应
成功(200)
成功(200)
HTTP 状态码: 200
内容格式: JSONapplication/json
数据结构
body
object
必需
code
integer
必需
data
object
必需
message
string
必需
headers
object
必需
size
integer
必需
status
integer
必需
示例
{
"body": {
"code": 0,
"data": {
"task": {
"begin_at": 1718705485,
"uuid": "1280bab3-3b0d-4517-a53c-3257e48319e5",
"wayline_validity_check_codes": null
}
},
"message": "success"
},
"headers": {},
"size": 152,
"status": 200
}
最后修改时间: 3 个月前