華為云計算 云知識 本接口用于查詢指定工作流實例詳細ShowWorkflowInstance
本接口用于查詢指定工作流實例詳細ShowWorkflowInstance

 

接口說明

本接口用于查詢指定工作流實例詳細。

URL
GET  https://dwr.cn-south-1.myhuaweicloud.com/v3/{project_id}/workflows/{graph_name}/workflowexecution/{execution_name} 
請求參數(shù)
名稱 類型 IN 必選 描述
X-Auth-Token
 
string header

用戶Token。通過調(diào)用 IAM 服務(wù)獲取用戶Token接口獲取(響應(yīng)消息頭中X-Subject-Token的值)。 條件:匿名請求不需要帶,其他請求必選。

project_id
 
string path

項目ID。

execution_name
 
string path

工作流實例名稱。

graph_name
 
string path

工作流名稱。

返回參數(shù)
返回碼: 200
 
名稱 類型 必選 描述
Content-Length
 
string

響應(yīng)消息體的字節(jié)長度。

Connection
 
string

指明與服務(wù)器的連接是長連接還是短連接。有效值:keep-alive | close。

Date
 
string

DWR系統(tǒng)響應(yīng)的時間。

x-request-id
 
string

由DWR創(chuàng)建來唯一確定本次請求的值,可以通過該值來定位問題。

名稱 類型 必選 描述
workflow_id
 
string

流程定義ID

最小長度:1

最大長度:64

workflow_urn
 
string

函數(shù)工作流 URN, 格式為: urn:fss:<region_id>:<project_id>:workflow:<package>:<workflow_name>:<version> 注意: package當(dāng)前只支持default version當(dāng)前只支持latest

execution_id
 
string

流程執(zhí)行實例ID

最小長度:1

最大長度:64

status
 
string

流程實例執(zhí)行狀態(tài)

最小長度:1

最大長度:32

枚舉值:

success

fail

running

timeout

cancel

headers
 
headers object

函數(shù)執(zhí)行時需要的Header。

input
 
input object

函數(shù)執(zhí)行時的入?yún)?/p>

output
 
output object

函數(shù)執(zhí)行結(jié)果

begin_time
 
string

流程實例創(chuàng)建時間,格式:yyyy-MM-ddTHH:mm:ssZ,UTC時間

最小長度:0

最大長度:64

end_time
 
string

流程實例結(jié)束時間,格式:yyyy-MM-ddTHH:mm:ssZ,UTC時間

最小長度:0

最大長度:64

last_update_time
 
string

流程實例上次更新時間,格式:yyyy-MM-ddTHH:mm:ssZ,UTC時間

最小長度:0

最大長度:64

created_by
 
string

流程實例創(chuàng)建者

最小長度:1

最大長度:32

node_execution_details
 
Array of NodeExecution objects

節(jié)點執(zhí)行信息

200 node_execution_details
名稱 類型 必選 描述
status
 
string

流程節(jié)點執(zhí)行狀態(tài)

最小長度:1

最大長度:32

枚舉值:

success

fail

running

timeout

cancel

input
 
input object

函數(shù)執(zhí)行時的入?yún)?/p>

output
 
output object

函數(shù)執(zhí)行結(jié)果

begin_time
 
long

節(jié)點啟動時間,UTC毫秒時間戳格式

最小值:0

最大值:99999999999999999

end_time
 
long

節(jié)點結(jié)束時間,UTC毫秒時間戳格式

最小值:0

最大值:99999999999999999

error_message
 
string

節(jié)點錯誤信息,僅在節(jié)點出錯時非空

request_id
 
string

流程節(jié)點請求ID

返回碼: 400
 
名稱 類型 必選 描述
error_msg
 
string

錯誤詳細描述

error_code
 
integer

簡單錯誤碼

request_id
 
string

請求唯一標識ID

返回碼: 500
 
名稱 類型 必選 描述
error_msg
 
string

錯誤詳細描述

error_code
 
integer

簡單錯誤碼

request_id
 
string

請求唯一標識ID

請求示例
示例 1
 
"/v3/{project_id}/workflowexecution/{execution_name}?graph_name={graph_name}"
 
"GET /v3/{project_id}/workflowexecution/{execution_name}?graph_name={graph_name}HTTP/1.1\nHost: dwr.cn-north-4.myhuaweicloud.com\nX-Auth-Token: H4IPJX0TQTHTHEBQQCEC:sc2PM13Wlfcoc/YZLK0MwsI2Zpo=\nContent-Type: application/json\nContent-Length: 0\nDate: Thu, 27 Aug 2020 12:38:10 GMT"
返回示例
返回碼:200
 
示例 1
 
HTTP/1.1 200 OK Date: Thu, 27 Aug 2020 12:38:10 GMT Content-Length: 100 Content-Type: application/json X-Request-ID: 6a63a18b8bab40ffb71ebd9cb80d0085 { "execution_info": { "input": "[{\"x\":123,\"y\":321},{\"x\":586}]", "isTest": true, "graph_urn": "urn:fgs:<region_id>:<project_id>:graph:<graph_name>", "execution_urn": "urn:fgs:<region_id>:<project_id>:execution:<graph_name>:<execution_name>:<domain_id>", "execution_name": "<execution_name>", "started_at": "2017-11-13T07:14:04.849Z", "state_map": { "next1": { "state_name": "next1", "status": "NOTRUNNING", "type": "NOOP" }, "end1": { "state_name": "end1", "status": "NOTRUNNING", "type": "END" }, "hello": { "state_name": "hello", "status": "RUNNING", "started_at": "2017-11-13T07:14:04.893Z", "type": "DELAY", "input": "[{\"x\":123,\"y\":321},{\"x\":586}]" } }, "start_state": "hello", "execution_state": "RUNNING", "execution_type": "APICALL" } }
SDK
點擊  數(shù)據(jù)工坊  (DWR) SDK, 下載SDK或查看SDK文檔。SDK的安裝、認證方式等在SDK文檔中對應(yīng)語言類型的【使用】目錄下。
錯誤碼
請參考 錯誤碼說明。