curl --request PUT \
--url http://localhost:3001/api/admin/journeys/ \
--header 'Content-Type: application/json' \
--data '{
"id": "<string>",
"workspaceId": "<string>",
"name": "<string>",
"canRunMultiple": true,
"updatedAt": 123,
"definition": {
"entryNode": {
"type": "EntryNode",
"segment": "<string>",
"child": "<string>",
"reEnter": true
},
"exitNode": {
"type": "ExitNode"
},
"nodes": [
{
"id": "<string>",
"type": "DelayNode",
"variant": {
"type": "Second",
"seconds": 123
},
"child": "<string>"
}
]
},
"status": "NotStarted",
"draft": {
"nodes": [
{
"id": "<string>",
"data": {
"type": "JourneyUiNodeDefinitionProps",
"nodeTypeProps": {
"type": "EntryUiNode",
"variant": {
"segment": "<string>",
"child": "<string>",
"reEnter": true,
"type": "EntryNode"
}
}
}
}
],
"edges": [
{
"source": "<string>",
"target": "<string>",
"data": {
"type": "JourneyUiDefinitionEdgeProps",
"disableMarker": true
}
}
]
}
}'
{
"id": "<string>",
"workspaceId": "<string>",
"name": "<string>",
"canRunMultiple": true,
"updatedAt": 123,
"draft": {
"nodes": [
{
"id": "<string>",
"data": {
"type": "JourneyUiNodeDefinitionProps",
"nodeTypeProps": {
"type": "EntryUiNode",
"variant": {
"segment": "<string>",
"child": "<string>",
"reEnter": true,
"type": "EntryNode"
}
}
}
}
],
"edges": [
{
"source": "<string>",
"target": "<string>",
"data": {
"type": "JourneyUiDefinitionEdgeProps",
"disableMarker": true
}
}
]
},
"status": "NotStarted",
"definition": {
"entryNode": {
"type": "EntryNode",
"segment": "<string>",
"child": "<string>",
"reEnter": true
},
"exitNode": {
"type": "ExitNode"
},
"nodes": [
{
"id": "<string>",
"type": "DelayNode",
"variant": {
"type": "Second",
"seconds": 123
},
"child": "<string>"
}
]
},
"createdAt": 123
}
Create or update a journey.
curl --request PUT \
--url http://localhost:3001/api/admin/journeys/ \
--header 'Content-Type: application/json' \
--data '{
"id": "<string>",
"workspaceId": "<string>",
"name": "<string>",
"canRunMultiple": true,
"updatedAt": 123,
"definition": {
"entryNode": {
"type": "EntryNode",
"segment": "<string>",
"child": "<string>",
"reEnter": true
},
"exitNode": {
"type": "ExitNode"
},
"nodes": [
{
"id": "<string>",
"type": "DelayNode",
"variant": {
"type": "Second",
"seconds": 123
},
"child": "<string>"
}
]
},
"status": "NotStarted",
"draft": {
"nodes": [
{
"id": "<string>",
"data": {
"type": "JourneyUiNodeDefinitionProps",
"nodeTypeProps": {
"type": "EntryUiNode",
"variant": {
"segment": "<string>",
"child": "<string>",
"reEnter": true,
"type": "EntryNode"
}
}
}
}
],
"edges": [
{
"source": "<string>",
"target": "<string>",
"data": {
"type": "JourneyUiDefinitionEdgeProps",
"disableMarker": true
}
}
]
}
}'
{
"id": "<string>",
"workspaceId": "<string>",
"name": "<string>",
"canRunMultiple": true,
"updatedAt": 123,
"draft": {
"nodes": [
{
"id": "<string>",
"data": {
"type": "JourneyUiNodeDefinitionProps",
"nodeTypeProps": {
"type": "EntryUiNode",
"variant": {
"segment": "<string>",
"child": "<string>",
"reEnter": true,
"type": "EntryNode"
}
}
}
}
],
"edges": [
{
"source": "<string>",
"target": "<string>",
"data": {
"type": "JourneyUiDefinitionEdgeProps",
"disableMarker": true
}
}
]
},
"status": "NotStarted",
"definition": {
"entryNode": {
"type": "EntryNode",
"segment": "<string>",
"child": "<string>",
"reEnter": true
},
"exitNode": {
"type": "ExitNode"
},
"nodes": [
{
"id": "<string>",
"type": "DelayNode",
"variant": {
"type": "Second",
"seconds": 123
},
"child": "<string>"
}
]
},
"createdAt": 123
}
Default Response
The response is of type object
.