Apps
These are the applications you create on our platform to send OTPs securely and efficiently.
Properties
- Name
id
- Type
- string
- Description
Unique identifier for the group.
- Name
name
- Type
- string
- Description
The name for the app.
- Name
message_template
- Type
- string
- Description
The message template for the app.
- Name
sender_id
- Type
- array
- Description
The sender id for the app.
- Name
code_size
- Type
- array
- Description
The code size for the app.
- Name
account_id
- Type
- array
- Description
The code account id for the app.
- Name
created_at
- Type
- timestamp
- Description
Timestamp of when the app was created.
- Name
updated_at
- Type
- timestamp
- Description
Timestamp of when the app was updated.
Retrieve Apps
This endpoint allows you to list your apps in Ourvoice.
Request
curl --request GET \
"https://api.getourvoice.com/v1/apps" \
--header "Authorization: Bearer {YOUR_AUTH_KEY}" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
Response (200)
{
"data": [
{
"id": "483ec9f8-b582-48d8-8305-ef27f403f6f2",
"account_id": "7bbbbcb-05b9-4e5d-8b41-c23034e0f8b",
"name": "GOLDEN",
"message_template": "Votre code de vérification [app_name] est [code].",
"sender_id": "9b38a5f6-bb4f-46a4-9ea4-2a207ae01f1e",
"code_size": 5,
"deleted_at": null,
"created_at": "2024-04-30T15:57:03.000000Z",
"updated_at": "2024-04-30T15:57:03.000000Z"
},
{
"id": "7e7e7fe0-a93b-49ce-b240-9e004c141666",
"account_id": "7bbbbcab-059-4e5d-8b41-c23034e0f8b",
"name": "Eldon's App",
"message_template": "Votre code Eldon's App est :",
"sender_id": "9b38a5f6-bb4f-46a4-9ea4-2a207ae01f1e",
"code_size": 5,
"deleted_at": null,
"created_at": "2024-04-30T15:06:50.000000Z",
"updated_at": "2024-04-30T15:06:50.000000Z"
},
],
"links": {
"first": "http://192.168.1.23:8000/api/v1/apps?page=1",
"last": "http://192.168.1.23:8000/api/v1/apps?page=1",
"prev": null,
"next": null
},
"meta": {
"current_page": 1,
"from": 1,
"last_page": 1,
"links": [
{
"url": null,
"label": "« Précédent",
"active": false
},
{
"url": "http://192.168.1.23:8000/api/v1/apps?page=1",
"label": "1",
"active": true
},
{
"url": null,
"label": "Suivant »",
"active": false
}
],
"path": "http://192.168.1.23:8000/api/v1/apps",
"per_page": 10,
"to": 2,
"total": 2
}
}
Retrieve App
This endpoint allows you to retrieve a app in Ourvoice.
Required attributes
- Name
id
- Type
- string
- Description
The id (uuid) for the app.
Request
curl --request GET \
"https://api.getourvoice.com/v1/483ec9f8-b582-48d8-835-ef27f403f6f2" \
--header "Authorization: Bearer {YOUR_AUTH_KEY}" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
Response (200)
{
"data": {
"id": "483ec9f8-b582-48d8-835-ef27f403f6f2",
"account_id": "7bbbbcab-05b9-4e5d-8b41-c23034e0f8b",
"name": "GOLDEN",
"message_template": "Votre code de vérification [app_name] est [code].",
"sender_id": "9b38a5f6-bb4f-46a4-9ea4-2a207ae01f1e",
"code_size": 5,
"deleted_at": null,
"created_at": "2024-04-30T15:57:03.000000Z",
"updated_at": "2024-04-30T15:57:03.000000Z"
}
}
Create a App
This endpoint allows you to create a new app in Ourvoice .
Required attributes
- Name
name
- Type
- string
- Description
The name for the app.
- Name
sender_id
- Type
- string
- Description
The id(uuid) for the sender.
Optional attributes
- Name
message_template
- Type
- string
- Description
The message template for the app.
- Name
code_size
- Type
- int
- Description
The otp code size for the app.
Request
curl --request POST \
"https://api.getourvoice.com/v1/groups" \
--header "Authorization: Bearer {YOUR_AUTH_KEY}" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
"name" : "App Name",
"sender_id" : "9b38a5f6-bb4f-46a4-9ea4-2a207ae01f1e"
}"
Response (201)
{
"data": {
"name": "App Name",
"sender_id": "9b38a5f6-bb4f-46a4-9ea4-2a207ae01f1e",
"message_template": "Votre code pour App Name est: {{code}}",
"code_size": 6,
"account_id": "7bbbbcab-05b9-4e5d-8b41-c23034e0f8b",
"id": "0a576ef0-fc2c-4986-a94c-b2360a3e67a",
"updated_at": "2024-05-03T09:17:44.000000Z",
"created_at": "2024-05-03T09:17:44.000000Z"
}
}
Update a app
This endpoint allows you to perform an update on a apps. Examples of updates are changing the name , sender_id , code_size and message_template. It also takes a PATCH as a method.
Required attributes
- Name
id
- Type
- string
- Description
The ID (uuid) of the app.
Optional attributes
- Name
name
- Type
- string
- Description
The name for the app.
- Name
sender_id
- Type
- string
- Description
The id(uuid) for the sender.
- Name
message_template
- Type
- string
- Description
The message template for the app.
- Name
code_size
- Type
- int
- Description
The otp code size for the app.
Request
curl --request PUT \
"api.getourvoice.com/v1/apps/0a576ef0-fc2c-4986-a94c-b2360a3e67a" \
--header "Authorization: Bearer {YOUR_AUTH_KEY}" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
"name" : "New App Name",
}"
Response (200)
{
"data": {
"id": "0a576ef0-fc2c-4986-a94c-b2360a3e67a",
"account_id": "7bbbbcab-05b9-4e5d-8b41-c23034e0f8b",
"name": "New App Name",
"message_template": "Votre code pour App Name est: {{code}}",
"sender_id": "9b38a5f6-bb4f-46a4-9ea4-2a207ae01f1e",
"code_size": 6,
"deleted_at": null,
"created_at": "2024-05-03T09:17:44.000000Z",
"updated_at": "2024-05-03T09:31:24.000000Z"
}
}
Delete a app
This endpoint allows you to delete app.
Required attributes
- Name
id
- Type
- string
- Description
The ID (uuid) of the app.
Request
curl --request DELETE \
"api.getourvoice.com/v1/apps/2b9ac653-bcb5-4bad-a8c5-4f9714bfaebe" \
--header "Authorization: Bearer {YOUR_AUTH_KEY}" \
--header "Content-Type: application/json" \
--header "Accept: application/json"