调用ListFlows接口,查询工作流列表

调试

您可以在OpenAPI Explorer中直接运行该接口,免去您计算签名的困扰。运行成功后,OpenAPI Explorer可以自动生成SDK代码示例。

请求参数

名称 类型 是否必选 示例值 描述
Action String ListFlows

系统规定参数。取值:ListFlows

RegionId String cn-hangzhou

地域ID。

ProjectId String FP-3535FE0BE522****

项目ID。

JobId String FJ-F32FB31D8295****

作业ID。

Name String my_flow

工作流名称。

Id String F-A32FB31D8295****

工作流ID。

ClusterId String C-F32FB31D8295****

集群ID。

Status String STOP_SCHEDULE

状态:

  • STOP_SCHEDULE(停止调度)
  • UNDER_SCHEDULE(调度中)
Periodic Boolean true

是否调度。

PageNumber Integer 1

页码。

PageSize Integer 20

每页查询数量。

返回数据

名称 类型 示例值 描述
PageNumber Integer 1

页码。

PageSize Integer 20

每页数量。

RequestId String 7DDFF4C7-3AE3-485F-BFA1-BAE0AA3689DD

请求ID。

Total Integer 10

总数。

Flow Array of Flow

工作流列表。

Flow
Type String DDI

DDI

Status String STOP_SCHEDULE

执行结果。

AlertUserGroupBizId String ADG-0a00d00abb7743ff9f812f1a997f3d87

报警用户组信息。

Periodic Boolean true

是否周期执行:

  • true:周期执行。
  • false:非周期行执行。
ProjectId String FP-3535FE0BE522****

项目ID。

HostName String emr-worker-1

主机名。

GmtModified Long 1538017814000

修改时间。

Description String 这是一个创建工作流描述

工作流描述。

StartSchedule Long 1538017814000

开始调度时间。

CreateCluster Boolean false

是否创建集群:

  • true:ClusterId为集群模板id(CT-XXXXXX)。
  • false:ClusterId为集群id(C-XXXXXX)。
EndSchedule Long 1538018814000

结束调度时间。

Graph String {"nodes":[{"id":"48d474ea","index":0,"spmAnchorId":"0.0.0.i0.766645eb2cmNtQ","attribute":{"type":"START"},"shape":"startControlNode","type":"node","y":250,"size":"80*34","x":500},{"id":"7ba480b3","index":1,"spmAnchorId":"5176.8250060.0.i19.771e28d0IPNQGE","attribute":{"jobType":"SHELL","jobId":"FJ-7BE1062897B19D25","type":"JOB"},"config":{"hostName":""},"label":"fail_job","shape":"shellJobNode","type":"node","y":398.5,"size":"170*34","x":470.5},{"id":"33202d60","index":2,"spmAnchorId":"5176.8250060.0.i23.771e28d0IPNQGE","attribute":{"type":"END"},"shape":"endControlNode","type":"node","y":562.5,"size":"80*34","x":430.5}],"edges":[{"id":"28167ea0","index":3,"source":"48d474ea","sourceAnchor":0,"target":"7ba480b3","targetAnchor":0},{"id":"e8d5ff52","index":4,"source":"7ba480b3","sourceAnchor":1,"target":"33202d60","targetAnchor":0}]}

图形信息。

GmtCreate Long 1538017814000

创建时间。

AlertDingDingGroupBizId String AUG-c917bbfaf6494bbfacdee69c8284967c

报警钉钉群信息。

CronExpr String 0 0 0-23/1 * * ?

调度Cron表达式。

CategoryId String FC-F2495319DA05****

工作流目录ID。

Name String my_flow

工作流名称。

Id String F-A32FB31D8295****

工作流ID。

ClusterId String C-F32FB31D8295****

集群ID。

AlertConf String

保留参数。

示例

请求示例

http(s)://[Endpoint]/?Action=ListFlows
&RegionId=cn-hangzhou
&ProjectId=FP-3535FE0BE522****
&JobId=FJ-F32FB31D8295****
&Name=my_flow
&Id=F-A32FB31D8295****
&ClusterId=C-F32FB31D8295****
&Status=STOP_SCHEDULE
&Periodic=true
&PageNumber=1
&PageSize=20
&公共请求参数

正常返回示例

XML格式

HTTP/1.1 200 OK
Content-Type:application/xml

<ListFlowsResponse>
    <PageNumber>1</PageNumber>
    <PageSize>20</PageSize>
    <RequestId>7DDFF4C7-3AE3-485F-BFA1-BAE0AA3689DD</RequestId>
    <Total>10</Total>
    <Flow>
        <Type>DDI</Type>
        <Status>STOP_SCHEDULE</Status>
        <AlertUserGroupBizId>ADG-0a00d00abb7743ff9f812f1a997f3d87</AlertUserGroupBizId>
        <Periodic>true</Periodic>
        <ProjectId>FP-3535FE0BE522****</ProjectId>
        <HostName>emr-worker-1</HostName>
        <GmtModified>1538017814000</GmtModified>
        <Description>这是一个创建工作流描述</Description>
        <StartSchedule>1538017814000</StartSchedule>
        <CreateCluster>false</CreateCluster>
        <EndSchedule>1538018814000</EndSchedule>
        <Graph>{"nodes":[{"id":"48d474ea","index":0,"spmAnchorId":"0.0.0.i0.766645eb2cmNtQ","attribute":{"type":"START"},"shape":"startControlNode","type":"node","y":250,"size":"80*34","x":500},{"id":"7ba480b3","index":1,"spmAnchorId":"5176.8250060.0.i19.771e28d0IPNQGE","attribute":{"jobType":"SHELL","jobId":"FJ-7BE1062897B19D25","type":"JOB"},"config":{"hostName":""},"label":"fail_job","shape":"shellJobNode","type":"node","y":398.5,"size":"170*34","x":470.5},{"id":"33202d60","index":2,"spmAnchorId":"5176.8250060.0.i23.771e28d0IPNQGE","attribute":{"type":"END"},"shape":"endControlNode","type":"node","y":562.5,"size":"80*34","x":430.5}],"edges":[{"id":"28167ea0","index":3,"source":"48d474ea","sourceAnchor":0,"target":"7ba480b3","targetAnchor":0},{"id":"e8d5ff52","index":4,"source":"7ba480b3","sourceAnchor":1,"target":"33202d60","targetAnchor":0}]}</Graph>
        <GmtCreate>1538017814000</GmtCreate>
        <AlertDingDingGroupBizId>AUG-c917bbfaf6494bbfacdee69c8284967c</AlertDingDingGroupBizId>
        <CronExpr>0 0 0-23/1 * * ?</CronExpr>
        <CategoryId>FC-F2495319DA05****</CategoryId>
        <Name>my_flow</Name>
        <Id>F-A32FB31D8295****</Id>
        <ClusterId>C-F32FB31D8295****</ClusterId>
        <AlertConf>无</AlertConf>
    </Flow>
</ListFlowsResponse>

JSON格式

HTTP/1.1 200 OK
Content-Type:application/json

{
  "PageNumber" : 1,
  "PageSize" : 20,
  "RequestId" : "7DDFF4C7-3AE3-485F-BFA1-BAE0AA3689DD",
  "Total" : 10,
  "Flow" : [ {
    "Type" : "DDI",
    "Status" : "STOP_SCHEDULE",
    "AlertUserGroupBizId" : "ADG-0a00d00abb7743ff9f812f1a997f3d87",
    "Periodic" : true,
    "ProjectId" : "FP-3535FE0BE522****",
    "HostName" : "emr-worker-1",
    "GmtModified" : 1538017814000,
    "Description" : "这是一个创建工作流描述",
    "StartSchedule" : 1538017814000,
    "CreateCluster" : false,
    "EndSchedule" : 1538018814000,
    "Graph" : "{\"nodes\":[{\"id\":\"48d474ea\",\"index\":0,\"spmAnchorId\":\"0.0.0.i0.766645eb2cmNtQ\",\"attribute\":{\"type\":\"START\"},\"shape\":\"startControlNode\",\"type\":\"node\",\"y\":250,\"size\":\"80*34\",\"x\":500},{\"id\":\"7ba480b3\",\"index\":1,\"spmAnchorId\":\"5176.8250060.0.i19.771e28d0IPNQGE\",\"attribute\":{\"jobType\":\"SHELL\",\"jobId\":\"FJ-7BE1062897B19D25\",\"type\":\"JOB\"},\"config\":{\"hostName\":\"\"},\"label\":\"fail_job\",\"shape\":\"shellJobNode\",\"type\":\"node\",\"y\":398.5,\"size\":\"170*34\",\"x\":470.5},{\"id\":\"33202d60\",\"index\":2,\"spmAnchorId\":\"5176.8250060.0.i23.771e28d0IPNQGE\",\"attribute\":{\"type\":\"END\"},\"shape\":\"endControlNode\",\"type\":\"node\",\"y\":562.5,\"size\":\"80*34\",\"x\":430.5}],\"edges\":[{\"id\":\"28167ea0\",\"index\":3,\"source\":\"48d474ea\",\"sourceAnchor\":0,\"target\":\"7ba480b3\",\"targetAnchor\":0},{\"id\":\"e8d5ff52\",\"index\":4,\"source\":\"7ba480b3\",\"sourceAnchor\":1,\"target\":\"33202d60\",\"targetAnchor\":0}]}",
    "GmtCreate" : 1538017814000,
    "AlertDingDingGroupBizId" : "AUG-c917bbfaf6494bbfacdee69c8284967c",
    "CronExpr" : "0 0 0-23/1 * * ?",
    "CategoryId" : "FC-F2495319DA05****",
    "Name" : "my_flow",
    "Id" : "F-A32FB31D8295****",
    "ClusterId" : "C-F32FB31D8295****",
    "AlertConf" : "无"
  } ]
}

错误码

访问错误中心查看更多错误码。

访问错误中心查看更多错误码。