Flows
Get Flow
GET /api/flows/<flow_id>/
GET /api/flows/?name__iexact=<flow name>&group__iexact=<group name>
URL params
Name | Type | Description | Example |
---|---|---|---|
| uuid | the flow's id | "9b399774-3a0a-40c1-8a1c-4a124170b6f3" |
Query params
Request a Flow (one or more) in list, which applies to these filters.
Name | Type | Description |
---|---|---|
| string | The flow's name |
| string | The flow'd group |
Successful status: 200 OK
Return the Flow (one or a list).
Example:
{
"name": "my_flow",
"input_fields": ["inputField1", "inputField2"],
"output_fields": ["outputField1", "outputField2"],
"canvas_id": "8101c262-be18-40c7-a85a-78b47dcdf80d"
}
Failed status: 404 NOT_FOUND
Get Flow Status
GET /api/apps/<flow_id>/status/
URL params
Name | Type | Description | Example |
---|---|---|---|
| uuid | the flow's id | "9b399774-3a0a-40c1-8a1c-4a124170b6f3" |
Successful status: 200 OK
Name | Type | Description |
---|---|---|
| string | The flow status |
Example:
{
"status": "started/stopped/not-deployed"
}
Failed status: 404 NOT_FOUND
Create Flow
POST /api/flows/
Name | Type | Default | Description |
---|---|---|---|
| string | - | The flow's name |
| array[string] | [ ] | The flow's input fields |
| array[string] | [ ] | The flow's output fields |
Example:
{
"name": "my_flow",
"input_fields": ["inputField1", "inputField2"],
"output_fields": ["outputField1", "outputField2"]
}
Successful status: 201 CREATED
The created App.
Example:
{
"name": "my_flow",
"input_fields": ["inputField1", "inputField2"],
"output_fields": ["outputField1", "outputField2"],
"canvas_id": "8101c262-be18-40c7-a85a-78b47dcdf80d"
}
Failed status: 400 BAD_REQUEST
when the flow name contains invalid characters (acceptable flow name characters are only alphanumeric [a-Z0-9] and the underscore character '_')
Example:
JSON{ "name": [ "Invalid flow name. Flow name must contain only alphanumeric characters and the underscore character." ] }
Update Flow
PUT /api/flows/<flow_id>/
URL params
Name | Type | Description | Example |
---|---|---|---|
| uuid | the flow's id | "9b399774-3a0a-40c1-8a1c-4a124170b6f3" |
Request payload
Some Flow variables for editing.
Name | Type | Description |
---|---|---|
| array[string] | The flow's input fields |
| array[string] | The flow's output fields |
Example:
{
"input_fields": ["inputField1", "inputField2"],
"output_fields": ["outputField1", "outputField2"]
}
Successful status: 200 OK
The updated Flow object.
Example:
{
"name": "my_flow",
"input_fields": ["inputField1", "inputField2"],
"output_fields": ["outputField1", "outputField2"],
"canvas_id": "8101c262-be18-40c7-a85a-78b47dcdf80d"
}
Delete Flow
DELETE /api/flows/<flow_id>/
URL params
Name | Type | Description | Example |
---|---|---|---|
| uuid | the flow's id | "9b399774-3a0a-40c1-8a1c-4a124170b6f3" |
Successful status: 204 NO_CONTENT
Failed status: 404 NOT_FOUND
Failed status: 409 CONFLICT
if Flow is in use by other app/flow
Example:
JSON{ "detail": "Cannot delete the Flow, because it is used by these apps/flows: some_app,some_flow" }