NodeTransition
A NodeTransition represents a decision point within a Flow. In this decision point the evaluation of a condition determines the subsequent path the candidate will follow.
Endpoints
GET /node-transitions
- Retrieve all node transitions (of all flows and nodes)GET /node-transitions/{id}
- Retrieve a single node transition by IDPOST /node-transitions
- Create a new node transitionPATCH /node-transitions/{id}
- Update a node transition by IDDELETE /node-transitions/{id}
- Delete a node transition by ID
Attributes
condition
String
condition to evaluate
index
Integer
order in which to evaluate the transitons
HTTP methods
condition
X
X
X
index
X
X
X
Example bodies
Post
{
"data": {
"type": "nodeTransitions",
"attributes": {
"condition": null,
"index": 0
},
"relationships": {
"node": {
"data": {
"type": "nodes",
"id": "parent-node-id"
}
},
"exitNode": {
"data": {
"type": "nodes",
"id": "exit-node-id"
}
}
}
}
}
Patch
In this example we alter the exitNode, effectively rerouting the transition.
{
"data": {
"type": "nodeTransitions",
"relationships": {
"exitNode": {
"data": {
"type": "nodes",
"id": "new-exit-node-id"
}
}
}
}
}
OpenAPI
NodeTransition found
GET /public/v2/node-transitions/{id} HTTP/1.1
Host: {defaulthost}
Authorization: YOUR_API_KEY
Accept: */*
NodeTransition found
{
"data": {
"id": "0278d0b1-68dd-49d7-b586-d2aaf05a8711",
"type": "nodeTransitions",
"attributes": {
"createdAt": "2024-08-20T10:45:11+00:00",
"updatedAt": "2024-08-20T10:45:11+00:00",
"condition": "session.first_name === should_be_name",
"index": 927
},
"relationships": {
"node": {
"links": {
"related": "/public/v2/nodes/c1d759b1-3b35-440f-ad5e-d37ed9d574db"
}
},
"exitNode": {
"links": {
"related": "/public/v2/nodes/1cc36bd2-9f2d-4241-a732-ff6cf5722bec"
}
}
}
},
"meta": {}
}
NodeTransition updated
PATCH /public/v2/node-transitions/{id} HTTP/1.1
Host: {defaulthost}
Authorization: YOUR_API_KEY
Content-Type: application/vnd.api+json
Accept: */*
Content-Length: 80
{
"data": {
"id": "text",
"type": "text",
"attributes": {
"condition": "text",
"index": 1
}
}
}
NodeTransition updated
{
"data": {
"id": "69e6892b-5579-4bbd-b602-04ce6765ae5c",
"type": "nodeTransitions",
"attributes": {
"createdAt": "2024-08-20T10:45:11+00:00",
"updatedAt": "2024-08-20T10:45:11+00:00",
"condition": null,
"index": 173
},
"relationships": {
"node": {
"links": {
"related": "/public/v2/nodes/83e65002-3ef8-4f21-a38f-9549458e436b"
}
},
"exitNode": {
"links": {
"related": "/public/v2/nodes/af441df3-8a8f-4e1d-995d-c921c9109aaf"
}
}
}
},
"meta": {}
}
Last updated