### Configure Snapshot Repository and Dependencies Source: https://docs.dixa.io/docs/dixamessenger/android/installation.md Enables access to unstable snapshot versions of the SDK for testing purposes. Includes the repository URL configuration and the dependency format for snapshot versions. ```groovy allprojects { repositories { maven { url = uri("https://central.sonatype.com/repository/maven-snapshots/") mavenContent { snapshotsOnly() } } } } dependencies { implementation 'com.dixa:messenger-sdk:-SNAPSHOT' } ``` -------------------------------- ### Customize Dixa Messenger Widget Initialization (TypeScript) Source: https://docs.dixa.io/docs/dixamessenger/web/overview.md This TypeScript example demonstrates how to customize the Dixa Messenger Web Widget's initialization by passing various options to the `init` method. Options include token, position, close button visibility, and language. Refer to the InitPayload documentation for a complete list of available options. ```typescript _dixa_.invoke('init', { messengerToken: '', position: 'bottomLeft', showWidgetCloseButton: true, language: 'en', //other options... }); ``` -------------------------------- ### Get Webhook Subscription Event Logs (cURL Example) Source: https://docs.dixa.io/openapi/dixa-api/v1/tag/Webhooks Example cURL command to fetch event logs for a specific webhook subscription and event type. You need to provide your API key, the webhookSubscriptionId, and the event name. ```curl curl -i -X GET \ 'https://docs.dixa.io/_mock/openapi/dixa-api/v1/v1/webhooks/{webhookSubscriptionId}/delivery-status/logs/{event}' \ -H 'Authorization: YOUR_API_KEY_HERE' ``` -------------------------------- ### Configure Dixa MCP Server in Claude Desktop Source: https://docs.dixa.io/docs/dixamcp/dixa-mcp.md This JSON configuration adds the Dixa MCP server to Claude Desktop's settings. It specifies the command to run and arguments, including the server URL and an authorization header. Replace 'YOUR_API_KEY_HERE' with your actual Dixa API key. ```json { "mcpServers": { "dixa": { "command": "npx", "args": [ "mcp-remote", "https://dixa-mcp-public.fastmcp.app/mcp", "--header", "Authorization: Bearer YOUR_API_KEY_HERE" ] } } } ``` -------------------------------- ### Import Conversation Response Example Source: https://docs.dixa.io/_bundle/openapi/dixa-api/%40v1/v1.json?download= This example demonstrates a successful response from the conversation import endpoint, including the conversation ID and any partial errors encountered during the import process. ```json { "data": { "id": 100, "partialErrors": [ { "message": "The conversation could not be assigned" }, { "message": "Invalid attachment url in message. externalId: 42" } ] } } ``` -------------------------------- ### Retrieve Custom Attributes Definition Source: https://docs.dixa.io/_bundle/openapi/dixa-api/%40v1/v1.json?download= Example JSON response for a GET request to /v1/custom-attributes. It returns a list of custom attribute definitions including their identifiers, labels, and input configurations. ```json { "data": [ { "id": "c43fc767-f89b-443a-9c98-90f53f940bd7", "entityType": "Conversation", "identifier": "parcel_id", "label": "Parcel ID", "inputDefinition": { "placeholder": "1234", "_type": "Text" }, "description": "Id of the parcel", "createdAt": "2023-01-01T08:23:54.246Z[GMT]", "updatedAt": "2023-01-11T12:25:23.837Z[GMT]", "isRequired": false, "isArchived": false, "isDeactivated": false } ] } ``` -------------------------------- ### Not Found Response Example Source: https://docs.dixa.io/_bundle/openapi/dixa-api/%40v1/v1.json?download= This JSON example shows a standard response for a not found error (HTTP 404) from the Dixa API, indicating that a requested resource could not be located. ```json { "message": "The requested resource could not be found" } ``` -------------------------------- ### Example Initial Dixa API Request Response Source: https://docs.dixa.io/docs/gdpr-data-anonymisation.md This is an example of the JSON response received after making an initial request to the Dixa API. It includes a unique ID for the request, which is necessary for subsequent status checks. The `_type`, `initiatedAt`, `targetEntityId`, and `requestedBy` fields provide context about the request. ```json { "data": { "id": "87bac308-e49f-4134-84cc-96b868f1e1e4", "_type": "Conversation", "initiatedAt": "2022-02-01T00:41:26.381Z[GMT]", "targetEntityId": "7392", "requestedBy": "b165fdaa-51d6-44b0-bfcd-5f431d623fa7" } } ``` -------------------------------- ### Retrieve End User Data Structure Source: https://docs.dixa.io/_bundle/openapi/dixa-api/%40v1/v1.json?download= Example JSON response structure for an end user object, containing fields such as display name, email, and external identifiers. This format is typically returned by GET requests to the end users endpoint. ```json { "id": "9e688c58-a548-3b8e-af69-c9e1005ad0bf", "createdAt": "2020-12-16T09:41:43Z", "displayName": "Enduser 2", "email": "enduser.2@example.org", "additionalEmails": [], "additionalPhoneNumbers": [], "middleNames": [], "avatarUrl": "https://files.dixa.io/public/image_2_id", "externalId": "#12345678" } ``` -------------------------------- ### Create Webhook Subscription (JSON Example) Source: https://docs.dixa.io/openapi/dixa-api/v1/tag/Webhooks Example JSON payload for creating a new webhook subscription. It includes details like name, subscribed events, URL, headers, and enablement status. The secretKey is generated by Dixa. ```json { "data": { "id": "cb452b81-6748-40ab-af85-6559b371bc5d", "name": "Dashboard Integration", "subscribedEvents": [ ... ], "url": "https://example.webhook/dashboard_integration", "headers": { ... }, "secretKey": "4g4h988p468g785965b780684bde5546c52gge658d76b4q33fb69c526ea4bdbc", "enabled": true, "createdAt": "2023-08-01T09:30:15Z", "createdBy": "e979cc3b-17b2-4850-b049-13c758763d1c", "updatedAt": "2023-08-02T15:09:30Z", "updatedBy": "64b777c3-eb82-49fb-bb3e-294afb5d840c", "filters": { ... } } } ``` -------------------------------- ### Define Business Hours and Knowledge Base API Responses Source: https://docs.dixa.io/_bundle/openapi/dixa-api/%40v1/v1.json?download= JSON schema examples representing successful responses for business hours schedules, status checks, and knowledge collection retrieval. These examples illustrate the expected data structure returned by the API endpoints. ```json { "data": { "schedules": [ { "name": "Schedule 1", "id": "b462107a-0a67-19f6-bfc0-207012e0190f" }, { "name": "Schedule 2", "id": "f462107a-0a57-66f6-dac0-207012e01255" } ] } } ``` ```json { "data": { "isOpen": true, "timestamp": "2025-01-08T08:31:25Z" } } ``` -------------------------------- ### Bad Request Response Example Source: https://docs.dixa.io/_bundle/openapi/dixa-api/%40v1/v1.json?download= This JSON example illustrates a typical response for a bad request (HTTP 400) from the Dixa API. It indicates an invalid value in the request. ```json { "message": "Invalid value in request" } ``` -------------------------------- ### GET /v1/tags Source: https://docs.dixa.io/_bundle/openapi/dixa-api/%40v1/v1.json?download= Retrieves a list of all available tags within the system. ```APIDOC ## GET /v1/tags ### Description List all tags available in the system. ### Method GET ### Endpoint /v1/tags ### Response #### Success Response (200) - **tags** (array) - List of tag objects. #### Response Example { "data": [] } ``` -------------------------------- ### GET /v1/queues Source: https://docs.dixa.io/openapi/dixa-api/v1/queues Lists all queues within an organization. ```APIDOC ## GET /v1/queues ### Description List all queues in an organization. ### Method GET ### Endpoint /v1/queues ### Parameters #### Path Parameters None #### Query Parameters None ### Request Example None ### Response #### Success Response (200) - **queues** (array) - A list of queue objects. - **id** (string) - The unique identifier for the queue. - **name** (string) - The name of the queue. - **description** (string) - A description of the queue. #### Response Example { "queues": [ { "id": "q123", "name": "Support Queue", "description": "Handles general support inquiries." }, { "id": "q456", "name": "Sales Queue", "description": "Handles sales-related inquiries." } ] } ``` -------------------------------- ### Get Webhook Subscription Last Delivery Statuses (cURL Example) Source: https://docs.dixa.io/openapi/dixa-api/v1/tag/Webhooks Example cURL command to retrieve the latest delivery statuses for a specific webhook subscription. Requires your API key and the webhookSubscriptionId. ```curl curl -i -X GET \ 'https://docs.dixa.io/_mock/openapi/dixa-api/v1/v1/webhooks/{webhookSubscriptionId}/delivery-status' \ -H 'Authorization: YOUR_API_KEY_HERE' ``` -------------------------------- ### Get Messages in a Conversation Source: https://docs.dixa.io/docs/gdpr-data-anonymisation.md Retrieves all messages within a specific conversation. This can be used to find message IDs for anonymisation. ```APIDOC ## GET /v1/conversations/{conversationId}/messages ### Description Retrieves all messages belonging to a specific conversation. ### Method GET ### Endpoint `/v1/conversations/{conversationId}/messages` ### Parameters #### Path Parameters - **conversationId** (integer) - Required - The unique identifier of the conversation whose messages are to be retrieved. ### Request Example ```bash curl -X GET \ -H "Authorization: Bearer " \ "https://dev.dixa.io/v1/conversations/123/messages" ``` ### Response #### Success Response (200) - **id** (string) - The unique identifier of the message. - **content** (string) - The content of the message. #### Response Example ```json [ { "id": "a1b2c3d4-e5f6-7890-1234-567890abcdef", "content": "This is a sample message." } ] ``` ``` -------------------------------- ### Retrieve Agent Presence Status Source: https://docs.dixa.io/_bundle/openapi/dixa-api/%40v1/v1.json?download= Example response for the GET /v1/agents/presence endpoint, which returns an array of user presence objects including status, connection state, and active channels. ```json [ { "userId": "d31a73fc-d67b-49ec-9534-1f36a0c4c906", "presenceStatus": "Working", "connectionStatus": "Online", "activeChannels": ["Email", "FacebookMessenger"] } ] ``` -------------------------------- ### WhatsApp Message Example Source: https://docs.dixa.io/_bundle/openapi/dixa-api/%40v1/v1.json?download= This snippet illustrates the format for sending WhatsApp messages via the Dixa API. It includes message details, sender information, and WhatsApp-specific attributes. ```json { "id": "99b95893-0514-4606-a5d8-1880172b3a63", "authorId": "41646d42-edc0-493e-ac7b-814d9ff40a2e", "externalId": "13252", "createdAt": "2021-12-01T12:54:36.581Z[GMT]", "attributes": { "content": { "value": "WhatsApp message", "_type": "Text" }, "direction": "Inbound", "attachments": [], "_type": "WhatsAppAttributes" } } ``` -------------------------------- ### Initialize Dixa Messenger SDK Source: https://docs.dixa.io/docs/dixamessenger/android/usage.md Initializes the Dixa Messenger SDK with a provided API key. This setup should be performed in the `onCreate()` method of your Application subclass. It requires the DixaMessenger library and a valid API key obtained from the Dixa Dashboard. ```kotlin class ApplicationSubclass : Application() { override fun onCreate() { super.onCreate() // Create configuration val config = DixaMessenger.Configuration.Builder() .setApiKey("") .build() // Initialize DixaMessenger with the configuration DixaMessenger.init(config, this) } } ``` -------------------------------- ### POST /api/queues Source: https://docs.dixa.io/_bundle/openapi/dixa-api/%40v1/v1.json?download= Creates a new queue with specified configuration details. This endpoint is used to set up new queues for handling customer interactions. ```APIDOC ## POST /api/queues ### Description Creates a new queue with specified configuration details. This endpoint is used to set up new queues for handling customer interactions. ### Method POST ### Endpoint /api/queues ### Parameters #### Request Body - **name** (string) - Required - The name of the queue. - **callFunctionality** (boolean) - Optional - Whether call functionality is enabled for this queue. - **isDefault** (boolean) - Optional - Whether this is the default queue. - **queueThresholds** (object) - Optional - Thresholds for the queue. - **WaitingConversations** (integer) - Optional - Maximum number of waiting conversations. - **offerTimeout** (integer) - Optional - Timeout for offering conversations. - **offerAlgorithm** (string) - Optional - Algorithm used for offering conversations (e.g., "AllAtOnce"). - **wrapupTimeout** (integer) - Optional - Timeout for wrap-up after a conversation. - **priority** (integer) - Optional - Priority of the queue. - **offerAbandonedConversations** (boolean) - Optional - Whether to offer abandoned conversations. - **doNotOfferTimeouts** (object) - Optional - Timeouts for not offering conversations. - **WidgetChat** (integer) - Optional - Timeout for WidgetChat. - **isDoNotOfferEnabled** (boolean) - Optional - Whether 'do not offer' is enabled. - **preferredAgentTimeouts** (object) - Optional - Timeouts for preferred agents. - **WhatsApp** (integer) - Optional - Timeout for WhatsApp. - **Voicemail** (integer) - Optional - Timeout for Voicemail. - **WidgetChat** (integer) - Optional - Timeout for WidgetChat. - **FacebookMessenger** (integer) - Optional - Timeout for Facebook Messenger. - **Email** (integer) - Optional - Timeout for Email. - **ContactForm** (integer) - Optional - Timeout for ContactForm. - **Callback** (integer) - Optional - Timeout for Callback. - **PstnPhone** (integer) - Optional - Timeout for PstnPhone. - **isPreferredAgentEnabled** (boolean) - Optional - Whether preferred agent is enabled. - **preferredAgentOfflineTimeout** (integer) - Optional - Timeout for preferred agent offline. - **personalAgentOfflineTimeout** (integer) - Optional - Timeout for personal agent offline. - **isRestricted** (boolean) - Optional - Whether the queue is restricted. ### Request Example ```json { "request": { "name": "MyCorp main queue", "callFunctionality": false, "isDefault": true, "queueThresholds": { "WaitingConversations": 10 }, "offerTimeout": 10, "offerAlgorithm": "AllAtOnce", "wrapupTimeout": 10, "priority": 1, "offerAbandonedConversations": false, "doNotOfferTimeouts": { "WidgetChat": 1 }, "isDoNotOfferEnabled": true, "preferredAgentTimeouts": { "WhatsApp": 300, "Voicemail": 300, "WidgetChat": 300, "FacebookMessenger": 300, "Email": 43200, "ContactForm": 43200, "Callback": 300, "PstnPhone": 300 }, "isPreferredAgentEnabled": false, "preferredAgentOfflineTimeout": 500, "personalAgentOfflineTimeout": 500, "isRestricted": false } } ``` ### Response #### Success Response (201) - **id** (string) - The unique identifier of the created queue. - **name** (string) - The name of the queue. - **isDefault** (boolean) - Whether this is the default queue. - **organizationId** (string) - The ID of the organization the queue belongs to. - **queueThresholds** (object) - Thresholds for the queue. - **SlaPercentage** (integer) - The SLA percentage threshold. - **slaCalculationMethod** (string) - The method used for SLA calculation. - **offerTimeout** (integer) - Timeout for offering conversations. - **offeringAlgorithm** (string) - The algorithm used for offering conversations. - **memberListType** (string) - The type of member list. - **usages** (object) - Usage details for the queue. - **queueId** (string) - The ID of the queue. - **usages** (object) - Specific usage details. - **Email** (array) - List of email addresses associated with the queue. - **wrapupTimeout** (integer) - Timeout for wrap-up after a conversation. - **priority** (integer) - Priority of the queue. - **offerAbandonedConversations** (boolean) - Whether abandoned conversations are offered. - **doNotOfferTimeouts** (object) - Timeouts for not offering conversations. - **WidgetChat** (integer) - Timeout for WidgetChat. - **isDoNotOfferEnabled** (boolean) - Whether 'do not offer' is enabled. - **isPreferredAgentEnabled** (boolean) - Whether preferred agent is enabled. - **preferredAgentOfflineTimeout** (integer) - Timeout for preferred agent offline. - **personalAgentOfflineTimeout** (integer) - Timeout for personal agent offline. - **isRestricted** (boolean) - Whether the queue is restricted. #### Response Example ```json { "id": "921a6e00-0845-417e-9c67-f7cb872d45f0", "name": "MyCorp email queue", "isDefault": true, "organizationId": "927d4b48-966b-45a3-8d7c-c6ad64f877b0", "queueThresholds": { "SlaPercentage": 10 }, "slaCalculationMethod": "AbandonedIgnored", "offerTimeout": 10, "offeringAlgorithm": "OneAtATimeRandom", "memberListType": "SkillBased", "usages": { "queueId": "921a6e00-0845-417e-9c67-f7cb872d45f0", "usages": { "Email": [ "info@mycorp.dixa.io" ] } }, "wrapupTimeout": 10, "priority": 1, "offerAbandonedConversations": false, "doNotOfferTimeouts": { "WidgetChat": 1 }, "isDoNotOfferEnabled": true, "isPreferredAgentEnabled": false, "preferredAgentOfflineTimeout": 500, "personalAgentOfflineTimeout": 500, "isRestricted": false } ``` #### Error Response (400) - **message** (string) - Description of the bad request. #### Error Response Example (400) ```json { "message": "Invalid value in request" } ``` #### Error Response (500) - **message** (string) - Description of the internal server error. #### Error Response Example (500) ```json { "message": "There was an internal server error while processing the request" } ``` ``` -------------------------------- ### Configure Maven Central Repository Source: https://docs.dixa.io/docs/dixamessenger/android/installation.md Ensures the project can resolve the Dixa Messenger SDK by declaring Maven Central in the root build.gradle file. This is required for successful dependency fetching. ```groovy allprojects { repositories { mavenCentral() } } ``` -------------------------------- ### Create Agents in Bulk Source: https://docs.dixa.io/openapi/dixa-api/v1/agents Creates multiple agents or administrators in the organization simultaneously. ```APIDOC ## POST /v1/agents/bulk ### Description Create agents in bulk. ### Method POST ### Endpoint /v1/agents/bulk ### Parameters #### Request Body - **agents** (array) - Required - An array of agent objects to create. - **first_name** (string) - Required - The first name of the agent. - **last_name** (string) - Required - The last name of the agent. - **email** (string) - Required - The email address of the agent. - **phone_number** (string) - Optional - The phone number of the agent. ### Request Example ```json { "agents": [ { "first_name": "Bob", "last_name": "Johnson", "email": "bob.johnson@example.com" }, { "first_name": "Charlie", "last_name": "Brown", "email": "charlie.brown@example.com", "phone_number": "+1555123456" } ] } ``` ### Response #### Success Response (201) - **message** (string) - A confirmation message indicating the bulk creation was successful. - **created_agents** (array) - List of IDs for the newly created agents. #### Response Example ```json { "message": "Agents created successfully.", "created_agents": ["agent987", "agent654"] } ``` ``` -------------------------------- ### Get End User Response Example (JSON) Source: https://docs.dixa.io/openapi/dixa-api/v1/End-Users This JSON object represents a successful response when retrieving an end user's details. It includes unique identifiers, timestamps, contact information, and custom attributes. ```json { "data": { "id": "434ce9f5-14c8-4be1-a0a8-f755010deb9b", "createdAt": "2020-12-16T09:41:43Z", "displayName": "Alice Brown", "email": "alice@brown.com", "phoneNumber": "+551155256325", "additionalEmails": [ … ], "additionalPhoneNumbers": [ … ], "firstName": "Alice", "lastName": "Brown", "middleNames": [ … ], "avatarUrl": "https://files.dixa.io/public/image_id", "externalId": "#12345678", "customAttributes": [ … ] } } ``` -------------------------------- ### Import Generic Messaging Conversation Source: https://docs.dixa.io/_bundle/openapi/dixa-api/%40v1/v1.json?download= Demonstrates how to import a conversation for the genericapimessaging channel. This requires setting the genericChannelName and providing a list of inbound and outbound messages. ```json { "genericChannelName": "genericapimessaging", "requesterId": "9c2a2cce-699f-4a72-89d9-fda5bc8dec8b", "requesterConnectionStatus": "Connected", "direction": "Inbound", "messages": [ { "content": { "value": "Hi, I need help with my order", "_type": "Text" }, "attachments": [], "createdAt": "2021-12-01T13:00:00.003Z", "_type": "InboundImport" }, { "content": { "value": "Sure — what seems to be the problem?", "_type": "Text" }, "agentId": "cd4ceb58-bb3a-443c-9cd8-4f088feafe5b", "attachments": [], "createdAt": "2021-12-01T14:00:00.004Z", "_type": "OutboundImport" } ], "createdAt": "2021-12-01T11:00:00.001Z", "assignment": { "agentId": "cd4ceb58-bb3a-443c-9cd8-4f088feafe5b", "assignedAt": "2021-12-01T12:00:00.002Z" }, "_type": "GenericConversationImport" } ``` -------------------------------- ### Create End User Source: https://docs.dixa.io/openapi/dixa-api/v1.md Creates a new end user. ```APIDOC ## POST /v1/endusers ### Description Create an end user. ### Method POST ### Endpoint /v1/endusers ### Parameters #### Request Body - **(object)** - Required - The end user object to create. ### Request Example ```json { "example": "request body" } ``` ### Response #### Success Response (200) - **(object)** - The created end user object. #### Response Example ```json { "example": "response body" } ``` ``` -------------------------------- ### Enable Core Library Desugaring Source: https://docs.dixa.io/docs/dixamessenger/android/installation.md Configures the Android build to support Java 8+ features on API levels 23-25. This is necessary for the SDK to function correctly on older Android devices. ```groovy android { compileOptions { coreLibraryDesugaringEnabled true sourceCompatibility JavaVersion.VERSION_11 targetCompatibility JavaVersion.VERSION_11 } } dependencies { coreLibraryDesugaring "com.android.tools:desugar_jdk_libs:2.0.4" } ``` -------------------------------- ### POST /tags Source: https://docs.dixa.io/_bundle/openapi/dixa-api/%40v1/v1.json?download= Creates a new tag within the system. ```APIDOC ## POST /tags ### Description Creates a new tag to be used for organizing conversations or other entities. ### Method POST ### Endpoint /tags ### Request Body - **name** (string) - Required - The name of the tag - **color** (string) - Optional - The color representation for the tag ### Request Example { "name": "Urgent", "color": "#FF0000" } ### Response #### Success Response (200) - **data** (object) - The created Tag object #### Response Example { "data": { "id": "tag_123", "name": "Urgent", "color": "#FF0000" } } ``` -------------------------------- ### Configure Dixa Messenger SDK Dependency Source: https://docs.dixa.io/docs/dixamessenger/android/installation.md Adds the Dixa Messenger SDK library to the application's build.gradle file. This is the primary step to enable the messenger functionality in an Android project. ```groovy dependencies { implementation 'com.dixa:messenger-sdk:2.0.0' } ``` -------------------------------- ### Dixa MCP Server Authentication Header Source: https://docs.dixa.io/docs/dixamcp/dixa-mcp.md This shows the format for the Authorization header required to authenticate with the Dixa MCP server. It uses a Bearer token, where 'YOUR_API_KEY_HERE' should be substituted with your actual Dixa API key. ```text Authorization: Bearer YOUR_API_KEY_HERE ``` -------------------------------- ### Get User ID by Email or Phone Source: https://docs.dixa.io/docs/gdpr-data-anonymisation.md Retrieves the internal Dixa user ID based on the user's email address or phone number. This is useful for obtaining identifiers needed for anonymisation requests. ```APIDOC ## GET /v1/endusers ### Description Retrieves a list of end users. This endpoint can be used to find a user's ID by providing their email address or phone number. ### Method GET ### Endpoint `/v1/endusers` ### Parameters #### Query Parameters - **email** (string) - Optional - The email address of the end user to search for. - **phone** (string) - Optional - The phone number of the end user to search for. ### Request Example ```bash curl -X GET \ -H "Authorization: Bearer " \ "https://dev.dixa.io/v1/endusers?email=test@example.com" ``` ### Response #### Success Response (200) - **id** (string) - The unique identifier of the end user. - **email** (string) - The email address of the end user. - **phone** (string) - The phone number of the end user. #### Response Example ```json [ { "id": "7161f740-e8bf-44ab-8d3f-8ab00241c9c6", "email": "test@example.com", "phone": "+1234567890" } ] ``` ``` -------------------------------- ### Create End User Source: https://docs.dixa.io/openapi/dixa-api/v1/end-users Creates a single end user. ```APIDOC ## POST /v1/endusers ### Description Create an end user. ### Method POST ### Endpoint /v1/endusers ### Parameters #### Request Body - **email** (string) - Required - The email address of the end user. - **phone_number** (string) - Optional - The phone number of the end user. - **first_name** (string) - Optional - The first name of the end user. - **last_name** (string) - Optional - The last name of the end user. ### Request Example ```json { "email": "new.user@example.com", "first_name": "New", "last_name": "User" } ``` ### Response #### Success Response (200) - **userId** (string) - The unique identifier for the newly created end user. - **email** (string) - The email address of the end user. - **phone_number** (string) - The phone number of the end user. - **first_name** (string) - The first name of the end user. - **last_name** (string) - The last name of the end user. - **created_at** (string) - Timestamp when the end user was created. #### Response Example ```json { "userId": "user_789", "email": "new.user@example.com", "phone_number": null, "first_name": "New", "last_name": "User", "created_at": "2023-10-27T11:00:00Z" } ``` ``` -------------------------------- ### POST /v1/agents/bulk Source: https://docs.dixa.io/openapi/dixa-api/v1/agents/postagentsbulk Create multiple agents in a single request. ```APIDOC ## POST /v1/agents/bulk ### Description Create agents in bulk within the Dixa platform. ### Method POST ### Endpoint /v1/agents/bulk ### Parameters #### Request Body - **data** (array) - Required - List of agent objects to create - **data.displayName** (string) - Required - The agent's display name - **data.email** (string) - Required - The agent's primary email address - **data.phoneNumber** (string) - Optional - The agent's primary phone number - **data.additionalEmails** (array) - Optional - Additional email addresses - **data.additionalPhoneNumbers** (array) - Optional - Additional phone numbers - **data.firstName** (string) - Optional - The agent's first name - **data.lastName** (string) - Optional - The agent's last name - **data.middleNames** (array) - Optional - The agent's middle names - **data.avatarUrl** (string) - Optional - The url for the agent's avatar ### Request Example { "data": [ { "displayName": "John Doe", "email": "john@example.com" } ] } ### Response #### Success Response (201) - **data** (array) - List of created agent objects #### Error Response (400/500) - **message** (string) - Error description #### Response Example { "data": [] } ``` -------------------------------- ### Get Anonymization Status Request Example (JSON) Source: https://docs.dixa.io/openapi/dixa-api/v1/tag/Anonymization This JSON structure represents the response when retrieving the status of an anonymization request. It includes the request ID, the type of entity anonymized, timestamps for initiation and processing, and the target entity ID. ```json { "data": { "id": "062f0b37-4de0-40f2-95a4-641435cb2869", "entityType": "UserAnonymizationType", "_type": "User", "initiatedAt": "2021-12-01T12:46:36.581Z[GMT]", "targetEntityId": "da9db703-4a7a-4f44-8a6a-c03b179b8ae2", "requestedBy": "bac5a02c-15b3-44da-ae1e-ab7b9db4aa89" } } ``` -------------------------------- ### POST /v1/webhooks Source: https://docs.dixa.io/openapi/dixa-api/v1/webhooks Creates a new Webhook Subscription. ```APIDOC ## POST /v1/webhooks ### Description Create a Webhook Subscription. ### Method POST ### Endpoint /v1/webhooks ### Parameters #### Request Body - **url** (string) - Required - The URL to send webhook events to. - **events** (array of strings) - Required - A list of events to subscribe to. ### Request Example ```json { "url": "https://example.com/new-webhook", "events": ["customer.created", "customer.updated"] } ``` ### Response #### Success Response (200) - **subscriptionDetails** (object) - Details of the newly created webhook subscription. #### Response Example ```json { "subscriptionDetails": { "id": "sub_789ghi", "url": "https://example.com/new-webhook", "events": ["customer.created", "customer.updated"], "createdAt": "2023-10-27T12:00:00Z" } } ``` ``` -------------------------------- ### Example Dixa API Request Status Response Source: https://docs.dixa.io/docs/gdpr-data-anonymisation.md This JSON object represents the response when checking the status of a Dixa API request. It includes the `id` of the request, timestamps for initiation (`initiatedAt`) and processing (`processedAt`), and other relevant details. If the request has not yet been processed, `processedAt` will be `null`. ```json { "data": { "id": "efbb03a0-be79-4ce0-b1ef-9f799e48143e", "_type": "Conversation", "initiatedAt": "2022-02-28T09:01:11.561Z", "targetEntityId": "690", "requestedBy": "c16ad1ec-39c1-4317-813f-a6198e05037d", "processedAt": "2022-02-28T09:01:11.758Z" } } ``` -------------------------------- ### Initiate Bulk Tagging for Conversation (POST) Source: https://docs.dixa.io/_bundle/openapi/dixa-api/%40v1/v1.json?download= Initiates a bulk tag operation for a specified conversation. If a tag with the given name does not exist, it will be created. This operation is processed asynchronously. It requires a conversation ID and a list of tags in the request body. ```json { "description": "Initiate bulk tag of a conversation and process it asynchronously. If a tag with corresponding name does not exist it will be created.", "operationId": "postConversationsConversationidTagsBulk", "parameters": [ { "name": "conversationId", "in": "path", "required": true, "schema": { "type": "integer", "format": "int64" } } ], "requestBody": { "description": "The list of tags to add to a conversation", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/BulkTagConversationInput" }, "example": { "data": [ { "name": "Example #1" }, { "name": "Example #2" } ] } } }, "required": true }, "responses": { "202": { "description": "The conversation bulk tag was initiated" }, "400": { "description": "Invalid value for: path parameter conversationId, Invalid value extracted from request context, Invalid value for: body", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/BadRequest" }, "example": { "message": "Invalid value in request" } } } }, "404": { "description": "An entity in this request could not be found", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/NotFound" }, "example": { "message": "The requested resource could not be found" } } } }, "500": { "description": "Internal failure during request processing", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ServerError" }, "example": { "message": "There was an internal server error while processing the request" } } } } } } ``` -------------------------------- ### POST /v1/endusers Source: https://docs.dixa.io/openapi/dixa-api/v1/end-users/postendusers Creates a new end user in the Dixa system. ```APIDOC ## POST /v1/endusers ### Description Creates a new end user record with the provided contact details. ### Method POST ### Endpoint /v1/endusers ### Request Body - **displayName** (string) - Optional - The contact's display name - **email** (string) - Optional - The contact's primary email address - **phoneNumber** (string) - Optional - The contact's primary phone number - **additionalEmails** (array) - Optional - Additional email addresses - **additionalPhoneNumbers** (array) - Optional - Additional phone numbers - **firstName** (string) - Optional - The contact's first name - **lastName** (string) - Optional - The contact's last name - **middleNames** (array) - Optional - The contact's middle names - **avatarUrl** (string) - Optional - The url for the contact's avatar - **externalId** (string) - Optional - Custom external identifier ### Request Example { "displayName": "John Doe", "email": "john@example.com", "externalId": "ext-123" } ### Response #### Success Response (201) - **data** (object) - The created user object - **data.id** (string) - Unique identifier for the contact - **data.createdAt** (string) - Timestamp of creation #### Response Example { "data": { "id": "user_123", "createdAt": "2023-10-27T10:00:00Z", "displayName": "John Doe" } } ``` -------------------------------- ### POST /callbacks Source: https://docs.dixa.io/_bundle/openapi/dixa-api/%40v1/v1.json?download= Creates a new callback request within the Dixa system. ```APIDOC ## POST /callbacks ### Description Initiates a callback request by specifying the requester, direction, and target queue. ### Method POST ### Endpoint /callbacks ### Request Body - **requesterId** (string, uuid) - Required - ID of the user requesting the callback. - **direction** (string) - Required - Direction of the call (Inbound or Outbound). - **contactEndpointId** (string) - Required - The endpoint ID to contact. - **queueId** (string, uuid) - Required - The queue ID to route the callback to. ### Request Example { "requesterId": "550e8400-e29b-41d4-a716-446655440000", "direction": "Outbound", "contactEndpointId": "ext-123", "queueId": "a1b2c3d4-e5f6-7890-abcd-1234567890ab" } ### Response #### Success Response (200) - **id** (string) - The created callback ID. ``` -------------------------------- ### GET /v1/queues/conversation-position/{csid} Source: https://docs.dixa.io/openapi/dixa-api/v1/chatbots Get the approximate position of a given conversation in its current queue. ```APIDOC ## GET /v1/queues/conversation-position/{csid} ### Description Get the approximate position of a given conversation in its current queue. ### Method GET ### Endpoint /v1/queues/conversation-position/{csid} ### Parameters #### Path Parameters - **csid** (string) - Required - The conversation ID. ### Request Example ```json { "example": "request body" } ``` ### Response #### Success Response (200) - **field1** (type) - Description #### Response Example ```json { "example": "response body" } ``` ``` -------------------------------- ### GET /v1/endusers/{userId}/conversations Source: https://docs.dixa.io/openapi/dixa-api/v1/chatbots/getendusersuseridconversations Lists conversations requested by an end user. Note: Custom attributes are not part of the response at this point. If you need to get custom attributes for a conversation use the GET /conversations/{conversationId} endpoint. ```APIDOC ## GET /v1/endusers/{userId}/conversations ### Description Lists conversations requested by an end user. Note: Custom attributes are not part of the response at this point. If you need to get custom attributes for a conversation use the GET /conversations/{conversationId} endpoint. ### Method GET ### Endpoint /v1/endusers/{userId}/conversations ### Parameters #### Path Parameters - **userId** (string) - Required - The ID of the end user. #### Query Parameters - **pageLimit** (integer) - Optional - Maximum number of results per page. May be used in combination with pageKey to change the number of results in between page requests. - **pageKey** (string) - Optional - Base64 encoded form of pagination query parameters. Do not try to construct or change programmatically as the internal structure may change without notice. ### Request Example ```json { "example": "" } ``` ### Response #### Success Response (200) - **data** (array) - The list of conversations. - **meta** (object) - Metadata for pagination. - **meta.previous** (string) - URL for the previous page. - **meta.next** (string) - URL for the next page. #### Error Response (400) - **message** (string) - Required - Error message. #### Error Response (404) - **message** (string) - Required - Error message. #### Error Response (500) - **message** (string) - Required - Error message. #### Response Example (200) ```json { "data": [ { "conversationId": "conv_123", "userId": "user_abc", "createdAt": "2023-10-27T10:00:00Z", "updatedAt": "2023-10-27T10:05:00Z" } ], "meta": { "previous": null, "next": "https://api.dixa.io/v1/endusers/user_abc/conversations?pageKey=base64encodedkey" } } ``` #### Response Example (400) ```json { "message": "Invalid request parameters." } ``` ``` -------------------------------- ### GET /v1/analytics/metrics Source: https://docs.dixa.io/openapi/dixa-api/v1/analytics Lists all available metric IDs that can be used to fetch data in Get Metric Data. ```APIDOC ## GET /v1/analytics/metrics ### Description This endpoint lists all available metric IDs that can be used to fetch data in Get Metric Data. ### Method GET ### Endpoint /v1/analytics/metrics ### Parameters #### Query Parameters - **limit** (integer) - Optional - The maximum number of metrics to return. - **offset** (integer) - Optional - The number of metrics to skip before starting to collect the result set. ### Request Example ``` GET /v1/analytics/metrics?limit=10&offset=0 ``` ### Response #### Success Response (200) - **metrics** (array) - A list of available metric objects. - **id** (string) - The unique identifier for the metric. - **name** (string) - The human-readable name of the metric. - **description** (string) - A description of the metric. #### Response Example ```json { "metrics": [ { "id": "active_users", "name": "Active Users", "description": "The number of unique users who performed an action in the given period." } ] } ``` ``` -------------------------------- ### Create Agent Source: https://docs.dixa.io/openapi/dixa-api/v1/agents Creates a new agent or administrator in the organization. ```APIDOC ## POST /v1/agents ### Description Create an agent. ### Method POST ### Endpoint /v1/agents ### Parameters #### Request Body - **first_name** (string) - Required - The first name of the agent. - **last_name** (string) - Required - The last name of the agent. - **email** (string) - Required - The email address of the agent. - **phone_number** (string) - Optional - The phone number of the agent. ### Request Example ```json { "first_name": "Alice", "last_name": "Smith", "email": "alice.smith@example.com", "phone_number": "+1987654321" } ``` ### Response #### Success Response (201) - **agent_id** (string) - The unique identifier for the newly created agent. - **message** (string) - A confirmation message. #### Response Example ```json { "agent_id": "agent789", "message": "Agent created successfully." } ``` ```