ZukVnc (1.2)

Download OpenAPI specification:Download

ZukRec的RESTFul接口文档

task

进行中任务相关接口

创建新任务

Request Body schema: application/json
url
required
string

页面链接,任务对应的页面url

callback
string

回调地址

region
string

任务运行的区域,当前仅支持us-east-1和cn-north-1

Responses

202

服务器已收到创建请求

401

用户未登录

post /tasks
https://rec.zukdoor.cloud/api/v1/tasks

Request samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "url": "string",
  • "callback": "string",
  • "region": "string"
}

Response samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "display": 0,
  • "userId": "string",
  • "url": "string",
  • "callback": "string",
  • "createdTime": 0
}

修改任务参数

path Parameters
display
required
string
Request Body schema: application/json
audioOffsetMillisecond
number

音频偏移时间

autoOffset
boolean

是否自动调整音频偏移

rp
number

调整屏幕分辨率

Responses

200

操作成功

401

用户未登录

403

用户无权限

404

任务不存在

patch /tasks/{display}
https://rec.zukdoor.cloud/api/v1/tasks/{display}

Request samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "audioOffsetMillisecond": 0,
  • "autoOffset": true,
  • "rp": 0
}

停止任务

path Parameters
display
required
string

Responses

204

成功停止

401

用户未登录

403

用户无权限

404

任务不存在

delete /tasks/{display}
https://rec.zukdoor.cloud/api/v1/tasks/{display}

开始录制

path Parameters
display
required
string
Request Body schema: application/json
recordName
required
string

录像名称,同一任务中的录像名称不能重复

format
string

录像格式,默认为mkv

onlyAudio
boolean

是否只录制音频,默认为否

Responses

202

收到开始录制请求

401

用户未登录

403

用户无权限

404

任务不存在

409

该任务正在录制中或录像名重复

post /tasks/{display}/records
https://rec.zukdoor.cloud/api/v1/tasks/{display}/records

Request samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "recordName": "string",
  • "format": "string",
  • "onlyAudio": true
}

停止录制

path Parameters
display
required
string

Responses

204

成功停止

401

用户未登录

403

用户无权限

404

任务不存在

delete /tasks/{display}/records
https://rec.zukdoor.cloud/api/v1/tasks/{display}/records

开始推流

path Parameters
display
required
string
Request Body schema: application/json
rtmpUrl
required
string

推流地址

Responses

202

收到开始推流请求

401

用户未登录

403

用户无权限

404

任务不存在

409

推流地址重复

post /tasks/{display}/rtmps
https://rec.zukdoor.cloud/api/v1/tasks/{display}/rtmps

Request samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "rtmpUrl": "string"
}

Response samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "rtmpId": 0
}

停止推流

path Parameters
display
required
string
rtmpId
required
integer

Responses

204

停止推流成功

401

用户未登录

403

用户无权限

404

任务不存在

delete /tasks/{display}/rtmps/{rtmpId}
https://rec.zukdoor.cloud/api/v1/tasks/{display}/rtmps/{rtmpId}

模拟鼠标点击

path Parameters
display
required
string
Request Body schema: application/json
x
required
number

横坐标

y
required
number

纵坐标

Responses

201

模拟点击成功

401

用户未登录

403

用户无权限

404

任务不存在

post /tasks/{display}/clicks
https://rec.zukdoor.cloud/api/v1/tasks/{display}/clicks

Request samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "x": 0,
  • "y": 0
}

stopped-task

已停止任务相关接口

生成录像地址

path Parameters
display
required
string
recordName
required
string
Request Body schema: application/json
expireTime
required
number

有效期时间,单位为秒

Responses

201

录像url

401

用户未登录

403

用户无权限

404

任务不存在

post /stopped-tasks/{display}/records/{recordName}/urls
https://rec.zukdoor.cloud/api/v1/stopped-tasks/{display}/records/{recordName}/urls

Request samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "expireTime": 0
}

Response samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "url": "string"
}