导出工作流为JSON格式,包含工作流基本信息、工作流内所有节点信息、工作流的DAG依赖关系
调试
您可以在OpenAPI Explorer中直接运行该接口,免去您计算签名的困扰。运行成功后,OpenAPI Explorer可以自动生成SDK代码示例。
授权信息
当前API暂无授权信息透出。
请求参数
| 名称 | 类型 | 必填 | 描述 | 示例值 |
|---|---|---|---|---|
| ClusterId | string | 是 | A short description of struct | xxljob-b6ec1xxxx |
| AppName | string | 是 | 应用名称。 | test-app |
| WorkflowId | array | 否 | 工作流 ID。 | |
| long | 否 | 工作流 ID | 20 |
返回参数
示例
正常返回示例
JSON格式
[
{
"kind": "SchedulerXWorkflows",
"type": "JSON",
"version": 2,
"workflowInfo": {
"name": "myWorkflow",
"description": "",
"appName": "xuerentest",
"appType": 1,
"maxConcurrency": 1,
"currentExecuteStatus": 0,
"timeConfig": {
"timeType": 1,
"timeExpression": "0 0 12 * * ?",
"dataOffset": 0
}
},
"nodes": [
{
"name": "Java1",
"startTime": -1,
"coordinate": {
"x": -222,
"y": 40,
"width": 220,
"height": 76
},
"appName": "xuerentest",
"description": "",
"jobType": "xxljob",
"executeMode": "standalone",
"contentType": 1,
"content": {
"jobHandler": "helloworld"
},
"xattrs": {
"executorBlockStrategy": 1
},
"dependentStrategy": 1,
"routeStrategy": 1,
"parameters": "",
"maxConcurrency": 1,
"maxAttempt": 0,
"attemptInterval": 30,
"priority": 5,
"weight": 1,
"timeConfig": {
"timeType": 1,
"calendar": "",
"dataOffset": 0
},
"monitorConfigInfo": {
"timeoutEnable": true,
"failEnable": true,
"failLimitTimes": 1,
"failRate": 100,
"missWorkerEnable": true,
"timeout": 300,
"timeoutKillEnable": false,
"daysOfDeadline": 0,
"sendChannel": "",
"alarmType": "CustomContacts",
"successNotice": false,
"endEarlyEnable": false,
"endEarly": 30
},
"contactInfoList": []
},
{
"name": "shell1",
"startTime": -1,
"coordinate": {
"x": 102,
"y": -51,
"width": 220,
"height": 76
},
"appName": "xuerentest",
"description": "",
"jobType": "script_shell",
"executeMode": "standalone",
"contentType": 2,
"content": "echo \"hello world\"",
"xattrs": {
"executorBlockStrategy": 1
},
"dependentStrategy": 1,
"routeStrategy": 1,
"parameters": "",
"maxConcurrency": 1,
"maxAttempt": 0,
"attemptInterval": 30,
"priority": 5,
"weight": 1,
"timeConfig": {
"timeType": 1,
"calendar": "",
"dataOffset": 0
},
"monitorConfigInfo": {
"timeoutEnable": true,
"failEnable": true,
"failLimitTimes": 1,
"failRate": 100,
"missWorkerEnable": true,
"timeout": 300,
"timeoutKillEnable": false,
"daysOfDeadline": 0,
"sendChannel": "",
"alarmType": "CustomContacts",
"successNotice": false,
"endEarlyEnable": false,
"endEarly": 30
},
"contactInfoList": []
},
{
"name": "Java2",
"startTime": -1,
"coordinate": {
"x": 390,
"y": 55,
"width": 220,
"height": 76
},
"appName": "xuerentest",
"description": "",
"jobType": "xxljob",
"executeMode": "standalone",
"contentType": 1,
"content": {
"jobHandler": "helloworld2"
},
"xattrs": {
"executorBlockStrategy": 1,
"localParams": []
},
"dependentStrategy": 1,
"routeStrategy": 1,
"parameters": "",
"maxConcurrency": 1,
"maxAttempt": 0,
"attemptInterval": 30,
"priority": 5,
"weight": 1,
"timeConfig": {
"timeType": 1,
"calendar": "",
"dataOffset": 0
},
"monitorConfigInfo": {
"timeoutEnable": true,
"failEnable": true,
"failLimitTimes": 1,
"failRate": 100,
"missWorkerEnable": true,
"timeout": 300,
"timeoutKillEnable": false,
"daysOfDeadline": 0,
"sendChannel": "",
"alarmType": "CustomContacts",
"successNotice": false,
"endEarlyEnable": false,
"endEarly": 30
},
"contactInfoList": []
},
{
"name": "shell2",
"startTime": -1,
"coordinate": {
"x": 89,
"y": 161,
"width": 220,
"height": 76
},
"appName": "xuerentest",
"description": "",
"jobType": "script_shell",
"executeMode": "standalone",
"contentType": 2,
"content": "echo \"hello world2\"",
"xattrs": {
"executorBlockStrategy": 1
},
"dependentStrategy": 1,
"routeStrategy": 1,
"parameters": "",
"maxConcurrency": 1,
"maxAttempt": 0,
"attemptInterval": 30,
"priority": 5,
"weight": 1,
"timeConfig": {
"timeType": 1,
"calendar": "",
"dataOffset": 0
},
"monitorConfigInfo": {
"timeoutEnable": true,
"failEnable": true,
"failLimitTimes": 1,
"failRate": 100,
"missWorkerEnable": true,
"timeout": 300,
"timeoutKillEnable": false,
"daysOfDeadline": 0,
"sendChannel": "",
"alarmType": "CustomContacts",
"successNotice": false,
"endEarlyEnable": false,
"endEarly": 30
},
"contactInfoList": []
}
],
"edges": [
{
"from": "Java1",
"to": "shell1"
},
{
"from": "Java1",
"to": "shell2"
},
{
"from": "Schedulerx-Root",
"to": "Java1"
},
{
"from": "shell1",
"to": "Java2"
},
{
"from": "shell2",
"to": "Java2"
}
]
}
]错误码
| HTTP status code | 错误码 | 错误信息 | 描述 |
|---|---|---|---|
| 400 | InvalidParameter | Parameter error: %s. | 参数错误: %s |
| 401 | IllegalRequest | IllegalRequest: %s. | 非法请求:%s |
| 403 | NoPermission | No permission to perform this operation: %s. | 没有权限去执行该操作:%s |
| 404 | NotFound | Not found: %s. | 资源不存在:%s |
| 500 | InternalError | InternalError: %s. | 系统内部错误:%s |
访问错误中心查看更多错误码。
变更历史
| 变更时间 | 变更内容概要 | 操作 |
|---|---|---|
| 2025-12-25 | 新增 OpenAPI | 查看变更详情 |
