List all agents
import requests
url = "https://api.diga.io/v1/agent/"
headers = {"Authorization": "Bearer <token>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};
fetch('https://api.diga.io/v1/agent/', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));curl --request GET \
--url https://api.diga.io/v1/agent/ \
--header 'Authorization: Bearer <token>'package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://api.diga.io/v1/agent/"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("Authorization", "Bearer <token>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}{
"data": [
{
"agent_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"modified_at": "2023-11-07T05:31:56Z",
"created_at": "2023-11-07T05:31:56Z",
"version_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"version_number": 123,
"version_created_at": "2023-11-07T05:31:56Z",
"voice": {
"id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"name": "<string>",
"provider_voice_id": "<string>",
"is_favourite": true,
"preview_urls": {},
"gender": "<string>"
},
"version_name": "<string>",
"is_draft": false,
"is_published": false,
"name": "<string>",
"description": "<string>",
"prompt": "<string>",
"greeting": "<string>",
"time_before_start": 123,
"volume": 50,
"max_reminder_count": 3,
"reminder_frequency_ms": 7500,
"reminder_messages": [],
"knowledge_base_ids": [],
"knowledge_item_ids": [],
"conversational_path_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"integrations": [],
"call_tools": [],
"dynamic_variables": {},
"flows": [],
"source_template_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"voicemail_detection": false,
"voicemail_action": "leave_message",
"voicemail_message": "<string>",
"phone_menu_detection": false,
"phone_menu_action": "navigate",
"phone_menu_navigation_mode": "goal",
"phone_menu_goal": "<string>",
"phone_menu_key_sequence": "<string>",
"validation_issues": [
{
"message_code": "<string>",
"message": "<string>",
"params": {}
}
]
}
],
"has_more": true,
"first_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"last_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"current_page": 123,
"total_pages": 123
}{
"status": "error",
"error_code": "NOT_VALID_FIELD",
"message": "Invalid field value in query parameters"
}{
"status": "error",
"error_code": "INTERNAL_SERVER_ERROR",
"message": "Missing required permissions to view agents"
}{
"status": "error",
"error_code": "INVALID_PAGINATION_PARAMETERS",
"message": "Cannot use both 'before' and 'after' pagination parameters together"
}{
"status": "error",
"error_code": "INTERNAL_SERVER_ERROR",
"message": "Error: Internal Server Error"
}Agents
List all agents
Retrieve a paginated list of agents for the company. By default, retrieves only draft versions. Supports cursor-based and page-based pagination.
GET
/
v1
/
agent
/
List all agents
import requests
url = "https://api.diga.io/v1/agent/"
headers = {"Authorization": "Bearer <token>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};
fetch('https://api.diga.io/v1/agent/', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));curl --request GET \
--url https://api.diga.io/v1/agent/ \
--header 'Authorization: Bearer <token>'package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://api.diga.io/v1/agent/"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("Authorization", "Bearer <token>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}{
"data": [
{
"agent_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"modified_at": "2023-11-07T05:31:56Z",
"created_at": "2023-11-07T05:31:56Z",
"version_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"version_number": 123,
"version_created_at": "2023-11-07T05:31:56Z",
"voice": {
"id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"name": "<string>",
"provider_voice_id": "<string>",
"is_favourite": true,
"preview_urls": {},
"gender": "<string>"
},
"version_name": "<string>",
"is_draft": false,
"is_published": false,
"name": "<string>",
"description": "<string>",
"prompt": "<string>",
"greeting": "<string>",
"time_before_start": 123,
"volume": 50,
"max_reminder_count": 3,
"reminder_frequency_ms": 7500,
"reminder_messages": [],
"knowledge_base_ids": [],
"knowledge_item_ids": [],
"conversational_path_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"integrations": [],
"call_tools": [],
"dynamic_variables": {},
"flows": [],
"source_template_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"voicemail_detection": false,
"voicemail_action": "leave_message",
"voicemail_message": "<string>",
"phone_menu_detection": false,
"phone_menu_action": "navigate",
"phone_menu_navigation_mode": "goal",
"phone_menu_goal": "<string>",
"phone_menu_key_sequence": "<string>",
"validation_issues": [
{
"message_code": "<string>",
"message": "<string>",
"params": {}
}
]
}
],
"has_more": true,
"first_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"last_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"current_page": 123,
"total_pages": 123
}{
"status": "error",
"error_code": "NOT_VALID_FIELD",
"message": "Invalid field value in query parameters"
}{
"status": "error",
"error_code": "INTERNAL_SERVER_ERROR",
"message": "Missing required permissions to view agents"
}{
"status": "error",
"error_code": "INVALID_PAGINATION_PARAMETERS",
"message": "Cannot use both 'before' and 'after' pagination parameters together"
}{
"status": "error",
"error_code": "INTERNAL_SERVER_ERROR",
"message": "Error: Internal Server Error"
}Autorizaciones
Bearer authentication header of the form Bearer <token>, where <token> is your auth token.
Parámetros de consulta
Rango requerido:
x >= 1Rango requerido:
1 <= x <= 100Opciones disponibles:
asc, desc Enum for Agent Modes.
Opciones disponibles:
free, path ⌘I

