OpenAPI 参考
Workflows
See, start, cancel, and decide runs of a Workflow node. A run acts as the key's owner, capped by the key.
Path Parameters
nodeId*string
Length
1 <= lengthQuery Parameters
limit?integer
How many runs to return. Default 20, at most 50.
Range
1 <= value <= 50cursor?string
nextCursor from the previous page.
Length
1 <= lengthrunId?string
Answer for this one run instead of a page, with what the caller may do to it.
Length
1 <= lengthResponse Body
application/json
curl -X GET "https://example.com/api/v1/workflows/string/runs"{ "runs": [ { "id": "string", "spaceId": "string", "workflowNodeId": "string", "status": "queued", "trigger": "manual", "startedBy": "string", "startedVia": null, "cancelledBy": null, "cursorNodeId": "string", "previousNodeId": "string", "outputs": { "property1": { "kind": "string", "capturedAt": "string", "sequence": 0, "record": { "recordId": "string", "baseId": "string", "headCommitId": "string", "fields": { "property1": null, "property2": null } }, "data": { "property1": null, "property2": null } }, "property2": { "kind": "string", "capturedAt": "string", "sequence": 0, "record": { "recordId": "string", "baseId": "string", "headCommitId": "string", "fields": { "property1": null, "property2": null } }, "data": { "property1": null, "property2": null } } }, "recordId": "string", "payload": { "property1": null, "property2": null }, "pause": { "kind": "wait", "nodeId": "string", "resumeAt": "string" }, "error": "string", "freshness": "snapshot-steps-plus-explicit-reread", "startedAt": "string", "updatedAt": "string" } ], "canRun": true, "decidableRunIds": [ "string" ], "nextCursor": "string", "queuedCount": 0, "actorNames": { "property1": "string", "property2": "string" }}Path Parameters
nodeId*string
Length
1 <= lengthRequest Body
application/json
TypeScript Definitions
Use the request body type in TypeScript.
Response Body
application/json
curl -X POST "https://example.com/api/v1/workflows/string/runs" \ -H "Content-Type: application/json" \ -d '{}'{ "id": "string", "spaceId": "string", "workflowNodeId": "string", "status": "queued", "trigger": "manual", "startedBy": "string", "startedVia": null, "cancelledBy": null, "cursorNodeId": "string", "previousNodeId": "string", "outputs": { "property1": { "kind": "string", "capturedAt": "string", "sequence": 0, "record": { "recordId": "string", "baseId": "string", "headCommitId": "string", "fields": { "property1": null, "property2": null } }, "data": { "property1": null, "property2": null } }, "property2": { "kind": "string", "capturedAt": "string", "sequence": 0, "record": { "recordId": "string", "baseId": "string", "headCommitId": "string", "fields": { "property1": null, "property2": null } }, "data": { "property1": null, "property2": null } } }, "recordId": "string", "payload": { "property1": null, "property2": null }, "pause": { "kind": "wait", "nodeId": "string", "resumeAt": "string" }, "error": "string", "freshness": "snapshot-steps-plus-explicit-reread", "startedAt": "string", "updatedAt": "string"}curl -X GET "https://example.com/api/v1/workflow-runs/string"{ "id": "string", "spaceId": "string", "workflowNodeId": "string", "status": "queued", "trigger": "manual", "startedBy": "string", "startedVia": null, "cancelledBy": null, "cursorNodeId": "string", "previousNodeId": "string", "outputs": { "property1": { "kind": "string", "capturedAt": "string", "sequence": 0, "record": { "recordId": "string", "baseId": "string", "headCommitId": "string", "fields": { "property1": null, "property2": null } }, "data": { "property1": null, "property2": null } }, "property2": { "kind": "string", "capturedAt": "string", "sequence": 0, "record": { "recordId": "string", "baseId": "string", "headCommitId": "string", "fields": { "property1": null, "property2": null } }, "data": { "property1": null, "property2": null } } }, "recordId": "string", "payload": { "property1": null, "property2": null }, "pause": { "kind": "wait", "nodeId": "string", "resumeAt": "string" }, "error": "string", "freshness": "snapshot-steps-plus-explicit-reread", "startedAt": "string", "updatedAt": "string"}Path Parameters
runId*string
Length
1 <= lengthRequest Body
application/json
TypeScript Definitions
Use the request body type in TypeScript.
Response Body
application/json
curl -X POST "https://example.com/api/v1/workflow-runs/string/decide" \ -H "Content-Type: application/json" \ -d '{ "decision": "approved" }'{ "id": "string", "spaceId": "string", "workflowNodeId": "string", "status": "queued", "trigger": "manual", "startedBy": "string", "startedVia": null, "cancelledBy": null, "cursorNodeId": "string", "previousNodeId": "string", "outputs": { "property1": { "kind": "string", "capturedAt": "string", "sequence": 0, "record": { "recordId": "string", "baseId": "string", "headCommitId": "string", "fields": { "property1": null, "property2": null } }, "data": { "property1": null, "property2": null } }, "property2": { "kind": "string", "capturedAt": "string", "sequence": 0, "record": { "recordId": "string", "baseId": "string", "headCommitId": "string", "fields": { "property1": null, "property2": null } }, "data": { "property1": null, "property2": null } } }, "recordId": "string", "payload": { "property1": null, "property2": null }, "pause": { "kind": "wait", "nodeId": "string", "resumeAt": "string" }, "error": "string", "freshness": "snapshot-steps-plus-explicit-reread", "startedAt": "string", "updatedAt": "string"}curl -X POST "https://example.com/api/v1/workflow-runs/string/cancel"{ "id": "string", "spaceId": "string", "workflowNodeId": "string", "status": "queued", "trigger": "manual", "startedBy": "string", "startedVia": null, "cancelledBy": null, "cursorNodeId": "string", "previousNodeId": "string", "outputs": { "property1": { "kind": "string", "capturedAt": "string", "sequence": 0, "record": { "recordId": "string", "baseId": "string", "headCommitId": "string", "fields": { "property1": null, "property2": null } }, "data": { "property1": null, "property2": null } }, "property2": { "kind": "string", "capturedAt": "string", "sequence": 0, "record": { "recordId": "string", "baseId": "string", "headCommitId": "string", "fields": { "property1": null, "property2": null } }, "data": { "property1": null, "property2": null } } }, "recordId": "string", "payload": { "property1": null, "property2": null }, "pause": { "kind": "wait", "nodeId": "string", "resumeAt": "string" }, "error": "string", "freshness": "snapshot-steps-plus-explicit-reread", "startedAt": "string", "updatedAt": "string"}