Retrieve a workflow's step graph
Every step in the workflow, including its TRIGGER entry node, and every directed transition between them. version is the workflow's version at the time of the read — a different number on a later read means somebody edited the graph in between.
A step's config is returned exactly as stored, camelCase keys and all, rather than projected into the snake_case used everywhere else on this API. That is deliberate: the same document is authored by the visual editor, and renaming its keys on the way out would mean any key this API did not know about was silently dropped on the way back in.
The response of GET /api/v1/workflows/{id}/graph is accepted verbatim by PUT on the same path: read a graph, change a step, send it back. Step and transition ids are yours to choose on a write, which is what makes that round trip a no-op rather than a rebuild.
Requires the workflows:read scope — View your automation workflows and their runs.
API key authentication. Use a sk_* (FULL) or pk_* (SENDING_ONLY) key as the bearer token. Public keys (pk_*) are restricted to the email-send endpoints and the self-serve list subscribe/unsubscribe pair; every other endpoint — event tracking included — answers 403 for them. In scope terms (used by /api/v1/* operations): FULL keys hold every scope; SENDING_ONLY keys hold only emails:send.
In: header
Path Parameters
Workflow id.
Response Body
application/json
application/problem+json
application/problem+json
application/problem+json
application/problem+json
application/problem+json
application/problem+json
curl -X GET "https://example.com/api/v1/workflows/497f6eca-6276-4993-bfeb-53cbbbba6f08/graph"{
"workflow_id": "03e70e31-d7a4-4401-a629-6a4b6096cdfe",
"version": 0,
"steps": [
{
"id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",
"name": "string",
"position": {
"x": 0,
"y": 0,
"property1": "string",
"property2": "string"
},
"template_id": "c6d67e98-83ea-49f0-8812-e4abae2b68bc",
"type": "TRIGGER",
"config": {
"property1": "string",
"property2": "string"
}
}
],
"transitions": [
{
"id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",
"from_step_id": "e4c3aeab-3fd1-4e4e-9277-1338b28978a8",
"to_step_id": "b9ed3588-525d-4e92-bfb0-711a014dbce6",
"condition": "string",
"priority": 0
}
]
}{
"type": "http://example.com",
"title": "string",
"status": 0,
"detail": "string",
"instance": "string",
"code": "string",
"request_id": "string",
"errors": [
{
"pointer": "string",
"code": "string",
"message": "string"
}
]
}{
"type": "http://example.com",
"title": "string",
"status": 0,
"detail": "string",
"instance": "string",
"code": "string",
"request_id": "string",
"errors": [
{
"pointer": "string",
"code": "string",
"message": "string"
}
]
}{
"type": "http://example.com",
"title": "string",
"status": 0,
"detail": "string",
"instance": "string",
"code": "string",
"request_id": "string",
"errors": [
{
"pointer": "string",
"code": "string",
"message": "string"
}
]
}{
"type": "http://example.com",
"title": "string",
"status": 0,
"detail": "string",
"instance": "string",
"code": "string",
"request_id": "string",
"errors": [
{
"pointer": "string",
"code": "string",
"message": "string"
}
]
}{
"type": "http://example.com",
"title": "string",
"status": 0,
"detail": "string",
"instance": "string",
"code": "string",
"request_id": "string",
"errors": [
{
"pointer": "string",
"code": "string",
"message": "string"
}
]
}{
"type": "http://example.com",
"title": "string",
"status": 0,
"detail": "string",
"instance": "string",
"code": "string",
"request_id": "string",
"errors": [
{
"pointer": "string",
"code": "string",
"message": "string"
}
]
}