Flows
Flows are where you communicate with the community in an event-driven way in Our Voice - they are a set of groups that you address at the same time. On this page, we'll dive into the different flows endpoints you can use to manage flows programmatically. We'll look at how to query, create, retrieve, update and delete flows.
The flow template contains all the information about the flows that grouped the SMS and Voice.
Properties
- Name
name
- Type
- string
- Description
The name of the flow.
- Name
type
- Type
- string
- Description
The type of the flow.
- Name
status
- Type
- string
- Description
The status of the flow.
- Name
metadata
- Type
- string
- Description
The metadata of the flow.
GET/v1/flows
List of flows
This endpoint allows you to list the flow in Our voice.
Request
GET
/v1/flowscurl --request POST \
--post "https://api.getourvoice.com/v1/flows" \
--header "Authorization: Bearer {YOUR_AUTH_KEY}" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"name\": \"nemo\",
\"type\": \"et\",
\"status\": \"modi\",
\"metadata\": \"maxime\"
}"
Response (200)
{
"data": {
"id": "74716765-f20f-42f8-b5c2-5ccfd8878b19",
"name": "inventore",
"description": "Doloribus autem corporis.",
"flow_executions_count": 0,
"type": "voice",
"status": "draft",
"metadata": "{\"matadata_1\":\"est\", \"matadata_2\":\"a\"}",
"created_at": "2023-03-16T07:13:21.000000Z",
"updated_at": "2023-03-16T07:13:21.000000Z"
}
}
GET/v1/flows
List of filtered flows
This endpoint allows you to list the flow by a certain filter in Our voice.
Request
GET
/v1/flowscurl --request POST \
--post "https://api.getourvoice.com/v1/flows?page=1&limit=10&filter[to]=&filter[from]=&filter[direction]=outgoing&filter[status]=completed&filter[duration]=" \
--header "Authorization: Bearer {YOUR_AUTH_KEY}" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"name\": \"nemo\",
\"type\": \"et\",
\"status\": \"modi\",
\"metadata\": \"maxime\"
}"
Response (200)
{
"data": {
"id": "74716765-f20f-42f8-b5c2-5ccfd8878b19",
"name": "inventore",
"description": "Doloribus autem corporis.",
"flow_executions_count": 0,
"type": "voice",
"status": "draft",
"metadata": "{\"matadata_1\":\"est\", \"matadata_2\":\"a\"}",
"created_at": "2023-03-16T07:13:21.000000Z",
"updated_at": "2023-03-16T07:13:21.000000Z"
}
}
GET/v1/flows/{id}
Retrieve a flow
This endpoint allows you to retrieve a flow in Our voice.
Required attributes
- Name
id
- Type
- string
- Description
The ID (uuid) of the flow.
Request
GET
/v1/flows/{id}curl --request GET \
"https://api.getourvoice.com/v1/flows/f1d9818b-1b58-4193-889a-42e44269d74a" \
--header "Authorization: Bearer {YOUR_AUTH_KEY}" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
Response (200)
{
"data": {
"id": "f1d9818b-1b58-4193-889a-42e44269d74a",
"name": "NaniscaAgodjie",
"description": "Et unde.",
"flow_executions_count": 0,
"type": "voice",
"status": " Zpublished",
"metadata": "{\"matadata_1\":\"voluptas\", \"matadata_2\":\"aspernatur\"}",
"created_at": "2023-03-16T07:13:21.000000Z",
"updated_at": "2023-03-16T07:13:21.000000Z"
}
}