{ "openapi": "3.1.0", "info": { "title": "Wavix APIs", "description": "Wavix provides robust APIs that let you integrate voice and text messaging features directly into your app. Send text, place calls, and access detailed reports programmatically.", "termsOfService": "https://wavix.com/terms-and-conditions", "license": { "name": "MIT", "identifier": "MIT" }, "contact": { "name": "Wavix", "url": "https://wavix.com", "email": "support@wavix.com" }, "version": "2.0.0" }, "servers": [ { "url": "https://api.wavix.com", "description": "https://api.wavix.com", "variables": {} } ], "security": [ { "bearerAuth": [] } ], "tags": [ { "name": "SIP trunks", "description": "SIP trunks" }, { "name": "Buy", "description": "Numbers" }, { "name": "Cart", "description": "Numbers" }, { "name": "My numbers", "description": "Numbers" }, { "name": "Billing", "description": "Billing, transactions, and invoices" }, { "name": "Profile", "description": "Account profile and customer information" }, { "name": "CDRs", "description": "Call detail records and call history" }, { "name": "Speech Analytics", "description": "Call transcription and speech analytics" }, { "name": "SMS and MMS", "description": "Messaging" }, { "name": "Number Validator", "description": "Phone number validation" }, { "name": "Link shortener", "description": "Short link and click metrics" }, { "name": "2FA", "description": "Two-factor authentication" }, { "name": "10DLC", "description": "10DLC Campaigns and Brands" }, { "name": "API Keys", "description": "API key management" }, { "name": "Call webhooks", "description": "Webhook configuration for call events" }, { "name": "Call control", "description": "Programmable Voice" }, { "name": "Call streaming", "description": "Real-time call audio streaming over WebSocket" }, { "name": "Call recording", "description": "Call recording" }, { "name": "Sub-accounts", "description": "Sub-account management" }, { "name": "Voice campaigns", "description": "Outbound voice campaigns" }, { "name": "Wavix Embeddable", "description": "WebRTC embeddable widget" }, { "name": "WhatsApp", "description": "WhatsApp senders, templates, messages, webhooks, and events" }, { "name": "WhatsApp webhook payloads", "description": "Message, template, sender, and marketing preference events Wavix posts to your WhatsApp webhooks" } ], "paths": { "/v1/api-keys": { "get": { "operationId": "api_keys_list", "summary": "List API keys", "description": "Returns the API keys belonging to the authenticated account.", "tags": [ "API Keys" ], "x-fern-sdk-group-name": [ "apiKeys" ], "x-fern-sdk-method-name": "list", "x-mcp": { "readOnly": true, "destructive": false, "openWorld": false, "expose": true }, "parameters": [ { "in": "query", "name": "label", "schema": { "type": "string" }, "description": "Filters API keys by `label`. Matches partial values.", "example": "production" } ], "responses": { "200": { "description": "Returns the list of API keys.", "content": { "application/json": { "schema": { "type": "array", "items": { "$ref": "#/components/schemas/ApiKey" } }, "examples": { "default": { "value": [ { "id": 123, "label": "Production API Key", "value": "abc123def456ghi789jkl012mno345pqr678stu901vwx234yz", "active": true, "restricted": true, "permitted_ips": [ "192.168.1.1", "10.0.0.1" ], "scopes_enabled": true, "last_used_at": "2026-04-20T15:42:11Z", "numbers": { "allow": "read" }, "trunks": { "allow": "none" }, "calls": { "allow": "read" }, "messages": { "allow": "write" }, "recordings": { "allow": "read" }, "campaigns": { "allow": "none" }, "two_fa": { "allow": "write" }, "validator": { "allow": "read" }, "webhooks": { "allow": "none" }, "embeddable": { "allow": "none" }, "billing": { "allow": "read" }, "account": { "allow": "read" }, "subaccounts": { "allow": "none" }, "created_at": "2024-01-15T10:30:00Z" } ] } } } } }, "401": { "$ref": "#/components/responses/UnauthorizedErrorResponse" }, "403": { "$ref": "#/components/responses/ForbiddenErrorResponse" } } }, "post": { "operationId": "api_keys_create", "summary": "Create an API key", "description": "Creates an API key for the authenticated account. Restrict access by listing permitted IP addresses in `permitted_ips`.", "tags": [ "API Keys" ], "x-fern-sdk-group-name": [ "apiKeys" ], "x-fern-sdk-method-name": "create", "x-mcp": { "readOnly": false, "destructive": false, "openWorld": false, "expose": true }, "requestBody": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ApiKeyCreateRequest" }, "example": { "label": "Production API Key", "active": true, "restricted": true, "permitted_ips": [ "192.168.1.1", "10.0.0.1" ], "scopes_enabled": true, "numbers": { "allow": "read" }, "calls": { "allow": "read" }, "messages": { "allow": "write" }, "two_fa": { "allow": "write" }, "billing": { "allow": "read" } } } } }, "responses": { "200": { "description": "Returns the created API key, including the one-time `value` secret.", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ApiKeyWithSecret" }, "examples": { "default": { "value": { "id": 123, "label": "Production API Key", "value": "abc123def456ghi789jkl012mno345pqr678stu901vwx234yz", "active": true, "restricted": true, "permitted_ips": [ "192.168.1.1", "10.0.0.1" ], "scopes_enabled": true, "last_used_at": null, "numbers": { "allow": "read" }, "trunks": { "allow": "none" }, "calls": { "allow": "read" }, "messages": { "allow": "write" }, "recordings": { "allow": "none" }, "campaigns": { "allow": "none" }, "two_fa": { "allow": "write" }, "validator": { "allow": "none" }, "webhooks": { "allow": "none" }, "embeddable": { "allow": "none" }, "billing": { "allow": "read" }, "account": { "allow": "none" }, "subaccounts": { "allow": "none" }, "created_at": "2024-01-15T10:30:00Z" } } } } } }, "400": { "$ref": "#/components/responses/BadRequestErrorResponse" }, "401": { "$ref": "#/components/responses/UnauthorizedErrorResponse" }, "403": { "$ref": "#/components/responses/ForbiddenErrorResponse" }, "422": { "description": "Returns a validation error when a field value is invalid.", "headers": {}, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ValidationErrorResponse" }, "examples": { "ip_invalid": { "summary": "Invalid IP address", "value": { "success": false, "message": "Ip has incorrect format" } }, "scope_not_hash": { "summary": "Scope value is not an object", "value": { "success": false, "message": "API key scope numbers: must be a hash" } }, "scope_extra_keys": { "summary": "Scope object has unexpected keys", "value": { "success": false, "message": "API key scope numbers: must have only \"allow\" key" } }, "scope_invalid_allow": { "summary": "Unsupported allow value", "value": { "success": false, "message": "API key scope numbers: allow must be one of: none, read, write" } } } } } } } } }, "/v1/api-keys/{id}": { "patch": { "operationId": "api_keys_update", "summary": "Update an API key", "description": "Updates an API key identified by `id`. Only the provided fields are changed.", "tags": [ "API Keys" ], "x-fern-sdk-group-name": [ "apiKeys" ], "x-fern-sdk-method-name": "update", "x-mcp": { "readOnly": false, "destructive": false, "openWorld": false, "expose": true }, "parameters": [ { "in": "path", "name": "id", "schema": { "type": "integer" }, "required": true, "description": "The unique ID of the API key.", "example": 123 } ], "requestBody": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ApiKeyUpdateRequest" }, "example": { "active": true, "restricted": true, "scopes_enabled": true, "permitted_ips": [ "192.168.1.1", "10.0.0.1" ], "label": "Production API Key" } } }, "required": false }, "responses": { "200": { "description": "Returns the updated API key.", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ApiKey" } } } }, "400": { "$ref": "#/components/responses/BadRequestErrorResponse" }, "401": { "$ref": "#/components/responses/UnauthorizedErrorResponse" }, "403": { "$ref": "#/components/responses/ForbiddenErrorResponse" }, "404": { "$ref": "#/components/responses/NotFoundErrorResponse" }, "422": { "$ref": "#/components/responses/ValidationErrorResponse" } } }, "delete": { "operationId": "api_keys_delete", "summary": "Delete an API key", "description": "Deletes the API key identified by `id`. Deletion is permanent and revokes the key immediately.", "tags": [ "API Keys" ], "x-fern-sdk-group-name": [ "apiKeys" ], "x-fern-sdk-method-name": "delete", "x-mcp": { "readOnly": false, "destructive": true, "openWorld": false, "expose": true }, "parameters": [ { "in": "path", "name": "id", "schema": { "type": "integer" }, "required": true, "description": "The unique ID of the API key.", "example": 123 } ], "responses": { "200": { "description": "Returns a success confirmation. The API key is revoked.", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/SuccessResponse" }, "examples": { "success": { "summary": "Successful response", "value": { "success": true } } } } } }, "400": { "$ref": "#/components/responses/BadRequestErrorResponse" }, "401": { "$ref": "#/components/responses/UnauthorizedErrorResponse" }, "403": { "$ref": "#/components/responses/ForbiddenErrorResponse" }, "404": { "$ref": "#/components/responses/NotFoundErrorResponse" } } } }, "/v1/trunks": { "get": { "tags": [ "SIP trunks" ], "summary": "List SIP trunks", "description": "Returns a paginated list of SIP trunks for the authenticated account.", "operationId": "sip_trunks_list", "security": [ { "bearerAuth": [ "trunks:read" ] } ], "x-fern-sdk-group-name": [ "sipTrunks" ], "x-fern-sdk-method-name": "list", "x-mcp": { "readOnly": true, "destructive": false, "openWorld": false, "expose": true }, "parameters": [ { "name": "page", "in": "query", "description": "Page number to retrieve. Default `1`.", "style": "form", "schema": { "type": "integer", "format": "int32" } }, { "name": "per_page", "in": "query", "description": "Number of records to return per page. Default `25`.", "style": "form", "schema": { "type": "integer", "format": "int32" } } ], "responses": { "200": { "description": "Returns a paginated list of SIP trunks.", "headers": {}, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/SIPTrunkListResponse" }, "examples": { "success": { "summary": "Successful response", "value": { "sip_trunks": [ { "id": 3107, "label": "My trunk", "name": "32882", "auth_method": "IP auth", "callerid": "14302287001", "host_request": { "host": "127.0.0.1", "status": "pending" }, "encrypted_media": false, "passthrough": false, "multiple_numbers": true, "status": "pending", "charge": "24.637", "talk_time": 65, "machine_detection_enabled": true, "call_recording_enabled": true, "transcription_enabled": true, "transcription_threshold": 6, "access_token": "siped7a3f5c1b9e042d6f8a4c2e7b9d1f3a5c8e0b2d4f6a8c0e2d4b6f8a1c3e5d7" } ], "pagination": { "current_page": 1, "total": 1, "per_page": 25, "total_pages": 1 } } } } } } }, "401": { "$ref": "#/components/responses/UnauthorizedErrorResponse" }, "403": { "$ref": "#/components/responses/ForbiddenErrorResponse" } }, "deprecated": false }, "post": { "tags": [ "SIP trunks" ], "summary": "Create a SIP trunk", "description": "Creates a SIP trunk for routing inbound and outbound calls. Returns the trunk with its generated `access_token`.", "operationId": "sip_trunks_create", "security": [ { "bearerAuth": [ "trunks:write" ] } ], "x-fern-sdk-group-name": [ "sipTrunks" ], "x-fern-sdk-method-name": "create", "x-mcp": { "readOnly": false, "destructive": false, "openWorld": false, "expose": true }, "parameters": [], "requestBody": { "description": "Attributes for the new SIP trunk.", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/SIPTrunkCreateRequest" } } }, "required": true }, "responses": { "201": { "description": "Returns the created SIP trunk.", "headers": {}, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/SIPTrunkResponse" }, "examples": { "success": { "summary": "Successful response", "value": { "id": 293, "name": "67758", "callerid": "example", "label": "example", "ip_restrict": false, "allowed_ips": [ { "id": 6712, "ip": "127.0.0.1" } ], "channels_restrict": false, "max_channels": 123, "cost_limit": false, "max_call_cost": "example", "call_restrict": false, "call_limit": 123, "didinfo_enabled": true, "rewrite_enabled": false, "rewrite_prefix": "example", "rewrite_cond": "example", "call_recording_enabled": false, "machine_detection_enabled": false, "transcription_enabled": false, "transcription_threshold": 6, "created_at": "2023-06-15T10:30:00Z", "host": "example", "multiple_numbers": true, "encrypted_media": true, "access_token": "siped7a3f5c1b9e042d6f8a4c2e7b9d1f3a5c8e0b2d4f6a8c0e2d4b6f8a1c3e5d7" } } } } } }, "400": { "$ref": "#/components/responses/ValidationErrorResponse" }, "401": { "$ref": "#/components/responses/UnauthorizedErrorResponse" }, "403": { "$ref": "#/components/responses/ForbiddenErrorResponse" }, "422": { "$ref": "#/components/responses/ValidationErrorResponse" } }, "deprecated": false } }, "/v1/trunks/{id}": { "get": { "tags": [ "SIP trunks" ], "summary": "Retrieve a SIP trunk", "description": "Returns the SIP trunk identified by `id`.", "operationId": "sip_trunks_get", "security": [ { "bearerAuth": [ "trunks:read" ] } ], "x-fern-sdk-group-name": [ "sipTrunks" ], "x-fern-sdk-method-name": "get", "x-mcp": { "readOnly": true, "destructive": false, "openWorld": false, "expose": true }, "parameters": [ { "name": "id", "in": "path", "description": "The unique ID of the SIP trunk.", "required": true, "style": "simple", "schema": { "type": "integer", "format": "int32", "example": 3107 } } ], "responses": { "200": { "description": "Returns the SIP trunk.", "headers": {}, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/SIPTrunkResponse" }, "examples": { "success": { "summary": "Successful response", "value": { "id": 293, "name": "67758", "callerid": "12345678900", "label": "My trunk", "ip_restrict": false, "allowed_ips": [ { "id": 6712, "ip": "127.0.0.1" } ], "channels_restrict": false, "max_channels": 2, "cost_limit": true, "max_call_cost": "0.18", "call_restrict": false, "call_limit": 3600, "didinfo_enabled": true, "rewrite_enabled": true, "rewrite_prefix": "1", "rewrite_cond": "example", "call_recording_enabled": true, "machine_detection_enabled": true, "transcription_enabled": false, "transcription_threshold": 10, "created_at": "2023-05-16T17:13:25.000Z", "host": "dynamic", "multiple_numbers": true, "encrypted_media": true, "access_token": "123easwqe321132" } } } } } }, "400": { "$ref": "#/components/responses/BadRequestErrorResponse" }, "401": { "$ref": "#/components/responses/UnauthorizedErrorResponse" }, "403": { "$ref": "#/components/responses/ForbiddenErrorResponse" }, "404": { "description": "Returns when no SIP trunk matches `id`, or the account is not provisioned for SIP trunks.", "headers": {}, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ForbiddenErrorResponse" }, "examples": { "success": { "summary": "Successful response", "value": { "success": false, "message": "The service is not provisioned for your account." } } } } } } }, "deprecated": false }, "put": { "tags": [ "SIP trunks" ], "summary": "Update a SIP trunk", "description": "Updates the SIP trunk identified by `id`. Only the provided fields are changed. On trial accounts, every update also applies the trial limits: a `call_limit` of at most 300 seconds (300 when omitted) and one concurrent call.", "operationId": "sip_trunks_update", "security": [ { "bearerAuth": [ "trunks:write" ] } ], "x-fern-sdk-group-name": [ "sipTrunks" ], "x-fern-sdk-method-name": "update", "x-mcp": { "readOnly": false, "destructive": true, "openWorld": false, "expose": true }, "parameters": [ { "name": "id", "in": "path", "description": "The unique ID of the SIP trunk.", "required": true, "style": "simple", "schema": { "type": "integer", "format": "int32", "example": 3107 } } ], "requestBody": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/SIPTrunkUpdateRequest" } } }, "required": true }, "responses": { "200": { "description": "Returns the updated SIP trunk.", "headers": {}, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/SIPTrunkResponse" }, "examples": { "success": { "summary": "Successful response", "value": { "id": 293, "name": "67758", "callerid": "12345678900", "label": "My trunk", "ip_restrict": false, "allowed_ips": [ { "id": 6712, "ip": "127.0.0.1" } ], "channels_restrict": false, "max_channels": 2, "cost_limit": true, "max_call_cost": "0.18", "call_restrict": false, "call_limit": 3600, "didinfo_enabled": true, "rewrite_enabled": true, "rewrite_prefix": "1", "rewrite_cond": "example", "call_recording_enabled": true, "machine_detection_enabled": true, "transcription_enabled": false, "transcription_threshold": 10, "created_at": "2023-05-16T17:13:25.000Z", "host": "dynamic", "multiple_numbers": true, "encrypted_media": true, "access_token": "123easwqe321132" } } } } } }, "400": { "$ref": "#/components/responses/ValidationErrorResponse" }, "401": { "$ref": "#/components/responses/UnauthorizedErrorResponse" }, "403": { "$ref": "#/components/responses/ForbiddenErrorResponse" }, "404": { "$ref": "#/components/responses/NotFoundErrorResponse" } }, "deprecated": false }, "delete": { "tags": [ "SIP trunks" ], "summary": "Delete a SIP trunk", "description": "Deletes the SIP trunk identified by `id`. Deletion is permanent and stops call routing through the trunk.", "operationId": "sip_trunks_delete", "security": [ { "bearerAuth": [ "trunks:write" ] } ], "x-fern-sdk-group-name": [ "sipTrunks" ], "x-fern-sdk-method-name": "delete", "x-mcp": { "readOnly": false, "destructive": true, "openWorld": false, "expose": true }, "parameters": [ { "name": "id", "in": "path", "description": "The unique ID of the SIP trunk.", "required": true, "style": "simple", "schema": { "type": "integer", "format": "int32", "example": 3107 } } ], "responses": { "200": { "description": "Returns a success confirmation. The SIP trunk is deleted.", "headers": {}, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/SuccessResponse" }, "examples": { "success": { "summary": "Successful response", "value": { "success": true } } } } } }, "400": { "$ref": "#/components/responses/BadRequestErrorResponse" }, "401": { "$ref": "#/components/responses/UnauthorizedErrorResponse" }, "403": { "$ref": "#/components/responses/ForbiddenErrorResponse" }, "404": { "$ref": "#/components/responses/NotFoundErrorResponse" } }, "deprecated": false } }, "/v1/buy/countries": { "get": { "tags": [ "Buy" ], "summary": "List countries", "description": "Returns a list of countries where phone numbers are available.", "operationId": "buy_countries_list", "security": [ { "bearerAuth": [ "numbers:read" ] } ], "x-fern-sdk-group-name": [ "buy", "countries" ], "x-fern-sdk-method-name": "list", "x-mcp": { "readOnly": true, "destructive": false, "openWorld": false, "expose": true }, "parameters": [ { "name": "text_enabled_only", "in": "query", "description": "When `true`, returns only countries that offer text-enabled phone numbers.", "style": "form", "explode": true, "schema": { "type": "boolean" } } ], "responses": { "200": { "headers": {}, "description": "Returns the list of countries with available phone numbers.", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/CountryListResponse" }, "examples": { "default": { "value": { "countries": [ { "id": 8669, "has_provinces_or_states": false, "name": "Argentina" }, { "id": 8650, "has_provinces_or_states": true, "name": "Australia" } ] } } } } } }, "401": { "$ref": "#/components/responses/UnauthorizedErrorResponse" }, "403": { "$ref": "#/components/responses/ForbiddenErrorResponse" } }, "deprecated": false } }, "/v1/buy/countries/{country_id}/regions": { "get": { "tags": [ "Buy" ], "summary": "List regions", "description": "Returns a list of regions (states or provinces) for countries where `has_provinces_or_states` is `true`.", "operationId": "buy_regions_list", "security": [ { "bearerAuth": [ "numbers:read" ] } ], "x-fern-sdk-group-name": [ "buy", "regions" ], "x-fern-sdk-method-name": "list", "x-mcp": { "readOnly": true, "destructive": false, "openWorld": false, "expose": true }, "parameters": [ { "name": "country_id", "in": "path", "description": "The unique ID of the country.", "required": true, "style": "simple", "schema": { "type": "integer", "format": "int32", "example": 1892 } }, { "name": "text_enabled_only", "in": "query", "description": "When `true`, returns only regions that offer text-enabled numbers.", "style": "form", "explode": true, "schema": { "type": "boolean" } } ], "responses": { "200": { "description": "Returns the list of regions.", "headers": {}, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/RegionListResponse" }, "examples": { "success": { "summary": "Successful response", "value": { "regions": [ { "id": 13, "name": "Alabama" }, { "id": 15, "name": "Arizona" }, { "id": 16, "name": "Arkansas" }, { "id": 17, "name": "California" } ] } } } } } }, "400": { "$ref": "#/components/responses/BadRequestErrorResponse" }, "401": { "$ref": "#/components/responses/UnauthorizedErrorResponse" }, "403": { "$ref": "#/components/responses/ForbiddenErrorResponse" }, "404": { "$ref": "#/components/responses/NotFoundErrorResponse" }, "422": { "$ref": "#/components/responses/CountryHasNoRegionsErrorResponse" } }, "deprecated": false } }, "/v1/buy/countries/{country_id}/cities": { "get": { "tags": [ "Buy" ], "summary": "List cities", "description": "Returns a list of cities for countries where\n `has_provinces_or_states` is `false`.", "operationId": "buy_cities_list", "security": [ { "bearerAuth": [ "numbers:read" ] } ], "x-fern-sdk-group-name": [ "buy", "cities" ], "x-fern-sdk-method-name": "list", "x-mcp": { "readOnly": true, "destructive": false, "openWorld": false, "expose": true }, "parameters": [ { "name": "country_id", "in": "path", "description": "The unique ID of the country.", "required": true, "style": "simple", "schema": { "type": "integer", "format": "int32", "example": 1891 } }, { "name": "text_enabled_only", "in": "query", "description": "When `true`, returns only cities that offer text-enabled numbers.", "style": "form", "explode": true, "schema": { "type": "boolean" } } ], "responses": { "200": { "description": "Returns the list of cities.", "headers": {}, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/CityListResponse" }, "examples": { "success": { "summary": "Successful response", "value": { "cities": [ { "area_code": 113, "id": 128791, "name": "Buenos Aires" }, { "area_code": 341, "id": 132655, "name": "Rosario" }, { "area_code": 351, "id": 132656, "name": "Cordoba" }, { "area_code": 381, "id": 141803, "name": "Tucuman" }, { "area_code": 387, "id": 141986, "name": "Salta" } ] } } } } } }, "400": { "$ref": "#/components/responses/BadRequestErrorResponse" }, "401": { "$ref": "#/components/responses/UnauthorizedErrorResponse" }, "403": { "$ref": "#/components/responses/ForbiddenErrorResponse" }, "404": { "$ref": "#/components/responses/NotFoundErrorResponse" } }, "deprecated": false } }, "/v1/buy/countries/{country_id}/regions/{region_id}/cities": { "get": { "tags": [ "Buy" ], "summary": "List region cities", "description": "Returns a list of cities in the specified region for countries where `has_provinces_or_states` is `true`.", "operationId": "buy_region_cities_list", "security": [ { "bearerAuth": [ "numbers:read" ] } ], "x-fern-sdk-group-name": [ "buy", "regionCities" ], "x-fern-sdk-method-name": "list", "x-mcp": { "readOnly": true, "destructive": false, "openWorld": false, "expose": true }, "parameters": [ { "name": "country_id", "in": "path", "description": "The unique ID of the country.", "required": true, "style": "simple", "schema": { "type": "integer", "format": "int32", "example": 1891 } }, { "name": "region_id", "in": "path", "description": "The unique ID of the region.", "required": true, "style": "simple", "schema": { "type": "integer", "format": "int32", "example": 821 } }, { "name": "text_enabled_only", "in": "query", "description": "When `true`, returns only cities that offer text-enabled numbers.", "style": "form", "explode": true, "schema": { "type": "boolean" } } ], "responses": { "200": { "description": "Returns the list of cities.", "headers": {}, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/CityListResponse" }, "examples": { "success": { "summary": "Successful response", "value": { "cities": [ { "area_code": 113, "id": 128791, "name": "Buenos Aires" }, { "area_code": 341, "id": 132655, "name": "Rosario" }, { "area_code": 351, "id": 132656, "name": "Cordoba" }, { "area_code": 381, "id": 141803, "name": "Tucuman" }, { "area_code": 387, "id": 141986, "name": "Salta" } ] } } } } } }, "400": { "$ref": "#/components/responses/BadRequestErrorResponse" }, "401": { "$ref": "#/components/responses/UnauthorizedErrorResponse" }, "403": { "$ref": "#/components/responses/ForbiddenErrorResponse" }, "404": { "$ref": "#/components/responses/NotFoundErrorResponse" } }, "deprecated": false } }, "/v1/buy/countries/{country_id}/cities/{city_id}/dids": { "get": { "tags": [ "Buy" ], "summary": "List available phone numbers", "description": "Returns a paginated list of phone numbers available for purchase in the specified city.", "operationId": "buy_numbers_list", "security": [ { "bearerAuth": [ "numbers:read" ] } ], "x-fern-sdk-group-name": [ "buy", "numbers" ], "x-fern-sdk-method-name": "list", "x-mcp": { "readOnly": true, "destructive": false, "openWorld": false, "expose": true }, "parameters": [ { "name": "country_id", "in": "path", "description": "The unique ID of the country.", "required": true, "style": "simple", "schema": { "type": "integer", "format": "int32" } }, { "name": "city_id", "in": "path", "description": "The unique ID of the city.", "required": true, "style": "simple", "schema": { "type": "integer", "format": "int32" } }, { "name": "text_enabled_only", "in": "query", "description": "When `true`, returns only text-enabled phone numbers.", "style": "form", "explode": true, "schema": { "type": "boolean" } }, { "name": "page", "in": "query", "description": "Page number to retrieve. Default `1`.", "style": "form", "explode": true, "schema": { "type": "integer", "format": "int32" } }, { "name": "per_page", "in": "query", "description": "Number of records to return per page. Default `25`.", "style": "form", "explode": true, "schema": { "type": "integer", "format": "int32" } } ], "responses": { "200": { "description": "Returns a paginated list of available phone numbers.", "headers": {}, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/AvailableNumberListResponse" }, "examples": { "success": { "summary": "Successful response", "value": { "dids": [ { "activation_fee": "15.0", "channels": "4", "city": "Buenos Aires", "cnam": false, "country": "Argentina", "country_short_name": "AR", "domestic_cli": false, "free_min": 0, "id": 541139862174, "monthly_fee": "10.0", "number": "541139862174", "per_min": "0.01", "require_docs": [], "sms_enabled": false, "sms_price": 0 } ], "pagination": { "total": 1, "total_pages": 1, "current_page": 1, "per_page": 50 } } } } } } }, "400": { "$ref": "#/components/responses/BadRequestErrorResponse" }, "401": { "$ref": "#/components/responses/UnauthorizedErrorResponse" }, "403": { "$ref": "#/components/responses/ForbiddenErrorResponse" }, "404": { "$ref": "#/components/responses/NotFoundErrorResponse" } }, "deprecated": false } }, "/v1/buy/cart": { "put": { "tags": [ "Cart" ], "summary": "Add to cart", "description": "Adds the listed phone numbers to the purchase cart.", "operationId": "cart_add", "security": [ { "bearerAuth": [ "numbers:write" ] } ], "x-fern-sdk-group-name": [ "cart" ], "x-fern-sdk-method-name": "add", "x-mcp": { "readOnly": false, "destructive": false, "openWorld": false, "expose": true }, "parameters": [], "requestBody": { "description": "Phone numbers to add to the cart.", "content": { "application/json": { "schema": { "type": "object", "additionalProperties": false, "required": [ "ids" ], "properties": { "ids": { "type": "array", "description": "Phone numbers to add to the cart.", "items": { "type": "string" }, "example": [ "541139862174", "541139862175" ] } } } } }, "required": true }, "responses": { "200": { "description": "Returns the phone numbers now in the cart.", "headers": {}, "content": { "application/json": { "schema": { "type": "array", "items": { "$ref": "#/components/schemas/AvailableNumber" }, "example": [ { "activation_fee": "15.0", "channels": "4", "city": "Buenos Aires", "cnam": false, "country": "Argentina", "country_short_name": "AR", "domestic_cli": false, "free_min": 0, "id": 541139862174, "monthly_fee": "10.0", "number": "541139862174", "per_min": "0.01", "require_docs": [], "sms_enabled": false, "sms_price": 0 } ] }, "examples": { "default": { "value": [ { "activation_fee": "15.0", "channels": "4", "city": "Buenos Aires", "cnam": false, "country": "Argentina", "country_short_name": "AR", "domestic_cli": false, "free_min": 0, "id": 541139862174, "monthly_fee": "10.0", "number": "541139862174", "per_min": "0.01", "require_docs": [], "sms_enabled": false, "sms_price": 0 } ] } } } } }, "400": { "$ref": "#/components/responses/BadRequestErrorResponse" }, "401": { "$ref": "#/components/responses/UnauthorizedErrorResponse" }, "403": { "$ref": "#/components/responses/ForbiddenErrorResponse" }, "404": { "$ref": "#/components/responses/NotFoundErrorResponse" } }, "deprecated": false }, "get": { "tags": [ "Cart" ], "summary": "Retrieve the cart", "description": "Returns the current purchase cart, including the phone numbers it contains and the documents each requires.", "operationId": "cart_get", "security": [ { "bearerAuth": [ "numbers:read" ] } ], "x-fern-sdk-group-name": [ "cart" ], "x-fern-sdk-method-name": "get", "x-mcp": { "readOnly": true, "destructive": false, "openWorld": false, "expose": true }, "parameters": [], "responses": { "200": { "description": "Returns the cart.", "headers": {}, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/CartResponse" }, "examples": { "default": { "value": { "dids": [ { "activation_fee": "15.0", "channels": "4", "city": "Buenos Aires", "cnam": false, "country": "Argentina", "country_short_name": "AR", "domestic_cli": false, "free_min": 0, "id": 541139862174, "monthly_fee": "10.0", "number": "541139862174", "per_min": "0.01", "require_docs": [], "sms_enabled": false, "sms_price": 0 } ], "doc_types": [ { "id": 1, "name": "id", "title": "Any form of ID" }, { "id": 2, "name": "address", "title": "Proof of address" }, { "id": 3, "name": "localaddress", "title": "Proof of local address" } ] } } } } } }, "401": { "$ref": "#/components/responses/UnauthorizedErrorResponse" }, "403": { "$ref": "#/components/responses/ForbiddenErrorResponse" } }, "deprecated": false }, "delete": { "tags": [ "Cart" ], "summary": "Remove from cart", "description": "Removes the listed phone numbers from the purchase cart.", "operationId": "cart_remove", "security": [ { "bearerAuth": [ "numbers:write" ] } ], "x-fern-sdk-group-name": [ "cart" ], "x-fern-sdk-method-name": "remove", "x-mcp": { "readOnly": false, "destructive": true, "openWorld": false, "expose": true }, "requestBody": { "required": true, "content": { "application/json": { "schema": { "type": "object", "additionalProperties": false, "required": [ "ids" ], "properties": { "ids": { "type": "array", "items": { "type": "string" }, "description": "Phone numbers to remove from the cart.", "example": [ "541139862174", "541139862175" ] } } } } } }, "responses": { "200": { "description": "Returns a success confirmation. The numbers are removed from the cart.", "headers": {}, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/SuccessResponse" }, "examples": { "default": { "value": { "success": true } } } } } }, "400": { "$ref": "#/components/responses/BadRequestErrorResponse" }, "401": { "$ref": "#/components/responses/UnauthorizedErrorResponse" }, "403": { "$ref": "#/components/responses/ForbiddenErrorResponse" }, "404": { "$ref": "#/components/responses/NotFoundErrorResponse" } }, "deprecated": false } }, "/v1/buy/cart/checkout": { "post": { "tags": [ "Cart" ], "summary": "Check out the cart", "description": "Purchases the listed phone numbers from the cart. Activation and monthly fees are debited from the account balance immediately, and the purchase cannot be reversed through this API.", "operationId": "cart_checkout", "security": [ { "bearerAuth": [ "numbers:write" ] } ], "x-fern-sdk-group-name": [ "cart" ], "x-fern-sdk-method-name": "checkout", "x-mcp": { "readOnly": false, "destructive": true, "openWorld": false, "expose": true }, "parameters": [], "requestBody": { "description": "Phone numbers from the cart to purchase.", "content": { "application/json": { "schema": { "type": "object", "additionalProperties": false, "required": [ "ids" ], "properties": { "ids": { "type": "array", "description": "Phone numbers from the cart to purchase.", "items": { "type": "string" }, "example": [ "541139862174", "541139862175" ] } } } } }, "required": true }, "responses": { "201": { "description": "Returns a success confirmation. The phone numbers are purchased.", "headers": {}, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/SuccessResponse" }, "examples": { "success": { "summary": "Successful response", "value": { "success": true } } } } } }, "400": { "$ref": "#/components/responses/BadRequestErrorResponse" }, "401": { "$ref": "#/components/responses/UnauthorizedErrorResponse" }, "403": { "$ref": "#/components/responses/ForbiddenErrorResponse" }, "404": { "$ref": "#/components/responses/NotFoundErrorResponse" }, "422": { "description": "Returns when the account balance cannot cover the cart total. The numbers that could not be purchased are listed in `error_dids`.", "headers": {}, "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "Human-readable error description.", "example": "Insufficient funds" }, "error_dids": { "type": "array", "description": "Numbers from the cart that could not be purchased.", "items": { "type": "string" }, "example": [ "12565378257" ] } } }, "examples": { "insufficient_funds": { "summary": "Insufficient account balance", "value": { "error": "Insufficient funds", "error_dids": [ "12565378257" ] } } } } } } }, "deprecated": false } }, "/v1/numbers": { "get": { "tags": [ "My numbers" ], "summary": "List phone numbers", "description": "Returns a paginated list of the phone numbers owned by the authenticated account.", "operationId": "my_numbers_list", "security": [ { "bearerAuth": [ "numbers:read" ] } ], "x-fern-sdk-group-name": [ "numbers" ], "x-fern-sdk-method-name": "list", "x-mcp": { "readOnly": true, "destructive": false, "openWorld": false, "expose": true }, "parameters": [ { "name": "city_id", "in": "query", "description": "Filters numbers by the ID of their city or rate center.", "style": "form", "explode": true, "schema": { "type": "integer", "format": "int32", "example": 123 } }, { "name": "search", "in": "query", "description": "Filters numbers by a full or partial phone number.", "style": "form", "explode": true, "schema": { "type": "string", "example": "256537" } }, { "name": "label", "in": "query", "description": "Filters numbers by `label`.", "style": "form", "explode": true, "schema": { "type": "string", "example": "ALEX" } }, { "name": "label_present", "in": "query", "description": "When `true`, returns only numbers that have a label; when `false`, only numbers without one.", "style": "form", "explode": true, "schema": { "type": "boolean", "example": true } }, { "name": "page", "in": "query", "description": "Page number to retrieve. Default `1`.", "style": "form", "explode": true, "schema": { "type": "integer", "format": "int32", "example": 2 } }, { "name": "per_page", "in": "query", "description": "Number of records to return per page. Default `25`.", "style": "form", "explode": true, "schema": { "type": "integer", "format": "int32", "example": 50 } } ], "responses": { "200": { "description": "Returns a paginated list of phone numbers.", "headers": {}, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/NumberListResponse" }, "examples": { "success": { "summary": "Successful response", "value": { "items": [ { "id": 123, "number": "12565378257", "activation_fee": "0.99", "monthly_fee": "0.99", "per_min": "0.01", "city": "DETROIT, MI", "state": "example", "country": "United States", "country_short_name": "US", "destination": [ { "id": 1, "destination": "[did]@sipuri.com", "priority": 1, "transport": 1, "trunk_id": 23123, "srtp": false, "trunk_label": "My trunk" } ], "channels": 24, "require_docs": [ "address" ], "documents": [ { "id": 423, "allow_replace": false, "did_number": "12565378257", "doc_content_type": "image/png", "doc_file_name": "Copy of ID.png", "doc_type": "id", "status": "approved", "url": "https://api.wavix.com/v1/numbers/24882/papers/1" } ], "domestic_cli": true, "free_min": 123, "unlimited": true, "label": "example", "status": "example", "seconds": "example", "added": "2023-04-10T06:42:59.000Z", "paid_until": "2023-12-07", "sms_enabled": false, "sms_relay_url": "https://your-website.com/webhook", "cnam": true, "call_recording_enabled": true, "transcription_enabled": true, "transcription_threshold": 6, "call_status_url": "https://example.com" } ], "doc_types": [ { "id": 2, "name": "address", "title": "Proof of address" } ], "pagination": { "current_page": 2, "per_page": 25, "total": 101, "total_pages": 5 } } } } } } }, "400": { "$ref": "#/components/responses/BadRequestErrorResponse" }, "401": { "$ref": "#/components/responses/UnauthorizedErrorResponse" }, "403": { "$ref": "#/components/responses/ForbiddenErrorResponse" } }, "deprecated": false }, "delete": { "tags": [ "My numbers" ], "summary": "Release phone numbers", "description": "Releases the listed phone numbers back to stock. Selection accepts either `ids` (record IDs) or `dids` (phone numbers), but not both.", "operationId": "my_numbers_delete", "security": [ { "bearerAuth": [ "numbers:write" ] } ], "x-fern-sdk-group-name": [ "numbers" ], "x-fern-sdk-method-name": "delete", "x-mcp": { "readOnly": false, "destructive": true, "openWorld": false, "expose": true }, "parameters": [ { "name": "ids", "in": "query", "description": "Record IDs of the phone numbers to release. Mutually exclusive with `dids`.", "required": false, "schema": { "type": "array", "items": { "type": "integer" }, "example": [ 47832123321, 47832123324, 478321233215 ] }, "style": "form", "explode": true }, { "name": "dids", "in": "query", "description": "Comma-separated phone numbers to release. Mutually exclusive with `ids`.", "required": false, "schema": { "type": "string", "example": "47832123321,47832123324,478321233215" } } ], "responses": { "200": { "description": "Returns a success confirmation. The numbers are released back to stock.", "headers": {}, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/SuccessResponse" }, "examples": { "default": { "value": { "success": true } } } } } }, "401": { "$ref": "#/components/responses/UnauthorizedErrorResponse" }, "403": { "$ref": "#/components/responses/ForbiddenErrorResponse" }, "404": { "$ref": "#/components/responses/NotFoundErrorResponse" }, "422": { "$ref": "#/components/responses/ValidationErrorResponse" } }, "deprecated": false }, "patch": { "tags": [ "My numbers" ], "summary": "Bulk update phone numbers", "description": "Applies the same changes to every listed phone number. Only the provided fields are changed. Destination and SMS callback changes are applied asynchronously and may not be reflected in the response immediately.", "operationId": "my_numbers_bulk_update", "security": [ { "bearerAuth": [ "numbers:write" ] } ], "x-fern-sdk-group-name": [ "numbers" ], "x-fern-sdk-method-name": "bulkUpdate", "x-mcp": { "readOnly": false, "destructive": true, "openWorld": false, "expose": true }, "requestBody": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/NumberBulkUpdateRequest" } } }, "required": true }, "responses": { "200": { "description": "Returns the updated phone numbers.", "headers": {}, "content": { "application/json": { "schema": { "type": "object", "additionalProperties": false, "properties": { "items": { "type": "array", "items": { "$ref": "#/components/schemas/Number" }, "description": "The updated phone numbers." } } } } } }, "400": { "$ref": "#/components/responses/BadRequestErrorResponse" }, "401": { "$ref": "#/components/responses/UnauthorizedErrorResponse" }, "403": { "$ref": "#/components/responses/ForbiddenErrorResponse" }, "404": { "$ref": "#/components/responses/NotFoundErrorResponse" } }, "deprecated": false } }, "/v1/numbers/{id}": { "get": { "tags": [ "My numbers" ], "summary": "Retrieve a phone number", "description": "Returns the phone number identified by `id`, including its destinations, documents, and feature settings.", "operationId": "my_numbers_get", "security": [ { "bearerAuth": [ "numbers:read" ] } ], "x-fern-sdk-group-name": [ "numbers" ], "x-fern-sdk-method-name": "get", "x-mcp": { "readOnly": true, "destructive": false, "openWorld": false, "expose": true }, "parameters": [ { "name": "id", "in": "path", "description": "The unique ID of the phone number.", "required": true, "style": "simple", "schema": { "type": "integer", "format": "int32", "example": 123 } } ], "responses": { "200": { "description": "Returns the phone number.", "headers": {}, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Number" }, "examples": { "success": { "summary": "Successful response", "value": { "id": 123, "number": "12565378257", "activation_fee": "0.99", "monthly_fee": "0.99", "per_min": "0.01", "city": "DETROIT, MI", "state": "example", "country": "United States", "country_short_name": "US", "destination": [ { "id": 1, "destination": "[did]@sipuri.com", "priority": 1, "transport": 1, "trunk_id": 23123, "srtp": false, "trunk_label": "My trunk" } ], "channels": 24, "require_docs": [ "address" ], "documents": [ { "id": 423, "allow_replace": false, "did_number": "12565378257", "doc_content_type": "image/png", "doc_file_name": "Copy of ID.png", "doc_type": "id", "status": "approved", "url": "https://api.wavix.com/v1/numbers/24882/papers/1" } ], "domestic_cli": true, "free_min": 123, "unlimited": true, "label": "example", "status": "example", "seconds": "example", "added": "2023-04-10T06:42:59.000Z", "paid_until": "2023-12-07", "sms_enabled": false, "sms_relay_url": "https://your-website.com/webhook", "cnam": true, "call_recording_enabled": true, "transcription_enabled": true, "transcription_threshold": 6, "call_status_url": "https://example.com" } } } } } }, "400": { "$ref": "#/components/responses/BadRequestErrorResponse" }, "401": { "$ref": "#/components/responses/UnauthorizedErrorResponse" }, "403": { "$ref": "#/components/responses/ForbiddenErrorResponse" }, "404": { "$ref": "#/components/responses/NotFoundErrorResponse" } }, "deprecated": false }, "patch": { "tags": [ "My numbers" ], "summary": "Update a phone number", "description": "Updates the phone number identified by `id`. Only the provided fields are changed.\n\n**Behavior:** With `expected_sms_relay_url`, the `sms_relay_url` change is applied only while the number currently has that URL; an empty string matches a number with no `sms_relay_url`. Otherwise the call returns `409` and no field in the request is changed. Setting the URL the number already has succeeds. To clear `sms_relay_url`, send `null`, not an empty string. If the call returns a `Something went wrong` error, you can retry the request; repeating the `sms_relay_url` change is a no-op, so it is safe even if the first attempt already applied it.", "operationId": "my_numbers_update", "security": [ { "bearerAuth": [ "numbers:write" ] } ], "x-fern-sdk-group-name": [ "numbers" ], "x-fern-sdk-method-name": "update", "x-mcp": { "readOnly": false, "destructive": true, "openWorld": false, "expose": true }, "parameters": [ { "name": "id", "in": "path", "description": "The unique ID of the phone number.", "required": true, "style": "simple", "schema": { "type": "integer", "format": "int32", "example": 123 } } ], "requestBody": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/NumberUpdateRequest" } } }, "required": false }, "responses": { "200": { "description": "Returns the updated phone number.", "headers": {}, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Number" } } } }, "400": { "$ref": "#/components/responses/BadRequestErrorResponse" }, "401": { "$ref": "#/components/responses/UnauthorizedErrorResponse" }, "403": { "$ref": "#/components/responses/ForbiddenErrorResponse" }, "404": { "$ref": "#/components/responses/NotFoundErrorResponse" }, "409": { "$ref": "#/components/responses/WebhookInUseErrorResponse" }, "422": { "$ref": "#/components/responses/ValidationErrorResponse" } }, "deprecated": false } }, "/v1/numbers/papers": { "post": { "tags": [ "My numbers" ], "summary": "Upload a document", "description": "Uploads a verification document for one or more phone numbers.\nUploaded files must meet the following requirements:\n- Allowed formats: PNG, JPG, JPEG, TIFF, BMP, or PDF\n- Maximum file size: 10 MB\n- Files can't be password protected\n- PDF files must not contain digital signatures", "operationId": "my_numbers_papers_upload", "security": [ { "bearerAuth": [ "numbers:write" ] } ], "x-fern-sdk-group-name": [ "numbers", "papers" ], "x-fern-sdk-method-name": "upload", "x-mcp": { "readOnly": false, "destructive": false, "openWorld": false, "expose": false }, "parameters": [], "requestBody": { "content": { "multipart/form-data": { "encoding": {}, "schema": { "required": [ "did_ids", "doc_attachment", "doc_id" ], "type": "object", "additionalProperties": false, "properties": { "did_ids": { "type": "string", "description": "Comma-separated record IDs of the phone numbers the document applies to.", "example": "2321" }, "doc_attachment": { "type": "string", "description": "Document file to upload. Allowed formats are PNG, JPG, JPEG, TIFF, BMP, and PDF. Maximum size is 10 MB.", "format": "binary" }, "doc_id": { "$ref": "#/components/schemas/DocumentType" } } } } }, "required": false }, "responses": { "200": { "description": "Returns the uploaded documents and their review status.", "content": { "application/json": { "schema": { "type": "array", "items": { "$ref": "#/components/schemas/NumberDocument" } }, "examples": { "default": { "value": [ { "id": 101, "allow_replace": false, "did_number": "+14062355770", "doc_content_type": "image/png", "doc_file_name": "user-id-card.png", "doc_type": "id", "status": "pending", "url": "https://api.wavix.com/v1/numbers/1001/papers/101" }, { "id": 102, "allow_replace": true, "did_number": "+14062355771", "doc_content_type": "application/pdf", "doc_file_name": "driver-license.pdf", "doc_type": "address", "status": "approved", "url": "https://api.wavix.com/v1/numbers/1002/papers/102" } ] } } } } }, "400": { "$ref": "#/components/responses/BadRequestErrorResponse" }, "401": { "$ref": "#/components/responses/UnauthorizedErrorResponse" }, "403": { "$ref": "#/components/responses/ForbiddenErrorResponse" } }, "deprecated": false } }, "/v1/cdrs": { "get": { "tags": [ "CDRs" ], "summary": "List CDRs", "description": "Returns a paginated list of call detail records for the authenticated account, within the requested date range.", "operationId": "cdrs_list", "security": [ { "bearerAuth": [ "calls:read" ] } ], "x-fern-sdk-group-name": [ "cdrs" ], "x-fern-sdk-method-name": "list", "x-mcp": { "readOnly": true, "destructive": false, "openWorld": false, "expose": true }, "parameters": [ { "name": "from", "in": "query", "description": "Start of the date range to query, in `YYYY-MM-DD` format. Inclusive.", "required": true, "style": "form", "explode": true, "schema": { "type": "string", "format": "date", "example": "2023-01-01" } }, { "name": "to", "in": "query", "description": "End of the date range to query, in `YYYY-MM-DD` format. Inclusive.", "required": true, "style": "form", "explode": true, "schema": { "type": "string", "format": "date", "example": "2023-09-01" } }, { "name": "type", "in": "query", "description": "Filters CDRs by call direction. One of `placed` (outbound calls dialed by the account) or `received` (inbound calls answered by the account).", "required": true, "style": "form", "explode": true, "schema": { "type": "string", "example": "received" } }, { "name": "disposition", "in": "query", "description": "Filters CDRs by call disposition. One of `answered` (the called party answered), `noanswer` (no answer within the ring timeout), `busy` (the called party was busy), `failed` (the call could not be routed), or `all` (no disposition filter).", "style": "form", "explode": true, "schema": { "$ref": "#/components/schemas/CallDisposition", "type": "string" } }, { "name": "from_search", "in": "query", "description": "Filters CDRs by originating phone number. Accepts a full or partial number.", "style": "form", "explode": true, "schema": { "type": "string", "example": "13524815863" } }, { "name": "to_search", "in": "query", "description": "Filters CDRs by destination phone number. Accepts a full or partial number.", "style": "form", "explode": true, "schema": { "type": "string", "example": "12565378257" } }, { "name": "sip_trunk", "in": "query", "description": "Filters outbound CDRs by SIP trunk login. Ignored for inbound calls.", "style": "form", "explode": true, "schema": { "type": "string", "example": "12321" } }, { "name": "uuid", "in": "query", "description": "Filters CDRs by the unique call ID.", "style": "form", "explode": true, "schema": { "type": "string", "example": "99df5ffd-962a-410f-bcce-d08f1f7f328c" } }, { "name": "page", "in": "query", "description": "Page number to retrieve. Default `1`.", "style": "form", "explode": true, "schema": { "type": "integer", "format": "int32", "example": 1 } }, { "name": "per_page", "in": "query", "description": "Number of records to return per page. Default `25`.", "style": "form", "explode": true, "schema": { "type": "integer", "format": "int32", "default": 25, "example": 25 } } ], "responses": { "200": { "description": "Returns a paginated list of CDRs.", "headers": {}, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/CDRListResponse" }, "examples": { "success": { "summary": "Successful response", "value": { "items": [ { "date": "2023-08-21T06:43:36.000Z", "from": "14302287001", "to": "33170363950", "disposition": "answered", "duration": 6, "destination": "France", "per_minute": "0.027", "charge": "0.822", "sip_trunk": "32882", "forward_fee": "0.0", "uuid": "99df5ffd-962a-410f-bcce-d08f1f7f328c", "call_id": "99df5ffd-962a-410f-bcce-d08f1f7f328c", "parent_uuid": "99df5ffd-962a-410f-bcce-d08f1f7f328c", "answered_by": "human" } ], "pagination": { "current_page": 2, "per_page": 25, "total": 101, "total_pages": 5 } } } } } } }, "400": { "$ref": "#/components/responses/BadRequestErrorResponse" }, "401": { "$ref": "#/components/responses/UnauthorizedErrorResponse" }, "403": { "$ref": "#/components/responses/ForbiddenErrorResponse" }, "404": { "$ref": "#/components/responses/NotFoundErrorResponse" } }, "deprecated": false }, "post": { "tags": [ "CDRs" ], "summary": "Search transcriptions", "description": "Searches call transcriptions for the given keywords or phrases and returns the matching CDRs with their transcriptions.", "operationId": "cdrs_search", "security": [ { "bearerAuth": [ "calls:read" ] } ], "x-fern-sdk-group-name": [ "cdrs" ], "x-fern-sdk-method-name": "search", "x-mcp": { "readOnly": true, "destructive": false, "openWorld": false, "expose": true }, "parameters": [], "requestBody": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/CDRSearchRequest" } } }, "required": true }, "responses": { "200": { "description": "Returns a paginated list of matching CDRs with their transcriptions.", "headers": {}, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/CDRTranscriptionSearchResponse" }, "examples": { "success": { "summary": "Successful response", "value": { "items": [ { "answered_by": "human", "date": "2023-08-21T06:43:36.000Z", "from": "14302287001", "to": "33170363950", "disposition": "answered", "duration": 6, "destination": "France", "per_minute": "0.027", "charge": "example", "sip_trunk": "32882", "forward_fee": "0.0", "uuid": "99df5ffd-962a-410f-bcce-d08f1f7f328c", "call_id": "99df5ffd-962a-410f-bcce-d08f1f7f328c", "parent_uuid": "99df5ffd-962a-410f-bcce-d08f1f7f328c", "transcription": { "uuid": "40d6f322-048d-490b-95c7-4fc5c76a74db", "url": "https://api.wavix.com/v1/cdrs/40d6f322-048d-490b-95c7-4fc5c76a74db/transcription?appid=secret" } } ], "pagination": { "current_page": 2, "per_page": 25, "total": 101, "total_pages": 5 } } } } } } }, "401": { "$ref": "#/components/responses/UnauthorizedErrorResponse" }, "403": { "$ref": "#/components/responses/ForbiddenErrorResponse" }, "422": { "$ref": "#/components/responses/ValidationErrorResponse" } }, "deprecated": false } }, "/v1/cdrs/{call_id}/retranscribe": { "put": { "tags": [ "CDRs" ], "summary": "Transcribe a call recording", "description": "Transcribes the recording of the call identified by `call_id`. Transcription is asynchronous; poll the transcription endpoint for the result. When it completes, the new transcription replaces any earlier one that the transcription endpoints return. Billed per minute at the account's call-transcription rate; fails with an insufficient-funds error when the balance cannot cover it.", "operationId": "cdrs_retranscribe", "security": [ { "bearerAuth": [ "calls:write" ] } ], "x-fern-sdk-group-name": [ "cdrs" ], "x-fern-sdk-method-name": "retranscribe", "x-mcp": { "readOnly": false, "destructive": true, "openWorld": false, "expose": true }, "parameters": [ { "name": "call_id", "in": "path", "description": "The unique ID of the call.", "required": true, "style": "simple", "schema": { "type": "string", "format": "uuid", "pattern": "^[0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12}$", "example": "bbaa37bf-430a-46da-ade3-c248e4070160" } } ], "requestBody": { "description": "Options for the transcription request.", "content": { "application/json": { "schema": { "allOf": [ { "$ref": "#/components/schemas/CDRRetranscriptionRequest" } ], "type": "object" } } }, "required": false }, "responses": { "200": { "description": "Returns a success confirmation. Transcription is queued.", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/SuccessResponse" }, "examples": { "default": { "value": { "success": true } } } } } }, "400": { "$ref": "#/components/responses/BadRequestErrorResponse" }, "401": { "$ref": "#/components/responses/UnauthorizedErrorResponse" }, "403": { "$ref": "#/components/responses/ForbiddenErrorResponse" }, "404": { "$ref": "#/components/responses/NotFoundErrorResponse" }, "422": { "$ref": "#/components/responses/ValidationErrorResponse" } }, "deprecated": false } }, "/v1/cdrs/{call_id}/transcription": { "get": { "tags": [ "CDRs" ], "summary": "Retrieve a transcription", "description": "Returns the transcription of the recorded call identified by `call_id`, including the transcript, speaker turns, and summary.", "operationId": "cdrs_transcription_get", "security": [ { "bearerAuth": [ "calls:read" ] } ], "x-fern-sdk-group-name": [ "cdrs", "transcription" ], "x-fern-sdk-method-name": "get", "x-mcp": { "readOnly": true, "destructive": false, "openWorld": false, "expose": false }, "parameters": [ { "name": "call_id", "in": "path", "description": "The unique ID of the call.", "required": true, "style": "simple", "schema": { "type": "string", "format": "uuid", "pattern": "^[0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12}$", "example": "bbaa37bf-430a-46da-ade3-c248e4070160" } } ], "responses": { "200": { "description": "Returns the call transcription.", "headers": {}, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/CDRTranscriptionResponse" }, "examples": { "success": { "summary": "Successful response", "value": { "transcript": { "16572026750": "", "16465292513": "" }, "turns": [ { "type": "46844685344", "s": 160, "e": 7280, "text": "Hello, how can I help you?" }, { "type": "+16572026750", "s": 2400, "e": 3280, "text": "Hello, I have a question about my bill." } ], "uuid": "e84f350f-6da7-4b56-80eb-41dec572626b", "language": "en", "duration": 102, "charge": "0.01", "status": "completed", "transcription_date": "2023-01-09T10:04:39.734Z", "call_date": "2023-01-09T10:01:13.394Z", "call_uuid": "bbaa37bf-430a-46da-ade3-c248e4070161", "call_score": "3.8", "call_summary": "The agent and client discussed billing issues." } } } } } }, "400": { "$ref": "#/components/responses/BadRequestErrorResponse" }, "401": { "$ref": "#/components/responses/UnauthorizedErrorResponse" }, "403": { "$ref": "#/components/responses/ForbiddenErrorResponse" }, "404": { "$ref": "#/components/responses/NotFoundErrorResponse" } }, "deprecated": false } }, "/v1/cdrs/{call_id}/transcriptions": { "get": { "tags": [ "CDRs" ], "summary": "Retrieve a transcription", "description": "Returns the transcription of the recorded call identified by `call_id`. Alias of the `transcription` endpoint.", "operationId": "cdrs_transcriptions", "security": [ { "bearerAuth": [ "calls:read" ] } ], "x-fern-sdk-group-name": [ "cdrs" ], "x-fern-sdk-method-name": "transcriptions", "x-mcp": { "readOnly": true, "destructive": false, "openWorld": false, "expose": true, "description": "Returns the transcription of the recorded call identified by `call_id`, including the transcript, speaker turns, and summary." }, "parameters": [ { "name": "call_id", "in": "path", "description": "The unique ID of the call.", "required": true, "style": "simple", "schema": { "type": "string", "format": "uuid", "pattern": "^[0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12}$", "example": "bbaa37bf-430a-46da-ade3-c248e4070160" } } ], "responses": { "200": { "description": "Returns the call transcription.", "headers": {}, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/CDRTranscriptionResponse" }, "examples": { "success": { "summary": "Successful response", "value": { "transcript": { "16572026750": "", "16465292513": "" }, "turns": [ { "type": "46844685344", "s": 160, "e": 7280, "text": "Hello, how can I help you?" }, { "type": "+16572026750", "s": 2400, "e": 3280, "text": "Hello, I have a question about my bill." } ], "uuid": "e84f350f-6da7-4b56-80eb-41dec572626b", "language": "en", "duration": 102, "charge": "0.01", "status": "completed", "transcription_date": "2023-01-09T10:04:39.734Z", "call_date": "2023-01-09T10:01:13.394Z", "call_uuid": "bbaa37bf-430a-46da-ade3-c248e4070161", "call_score": "3.8", "call_summary": "The agent and client discussed billing issues." } } } } } }, "401": { "$ref": "#/components/responses/UnauthorizedErrorResponse" }, "403": { "$ref": "#/components/responses/ForbiddenErrorResponse" }, "404": { "$ref": "#/components/responses/NotFoundErrorResponse" } }, "deprecated": false } }, "/v1/cdrs/{call_id}": { "get": { "tags": [ "CDRs" ], "summary": "Retrieve a CDR", "description": "Returns the call detail record for the call identified by `call_id`.", "operationId": "cdrs_get", "security": [ { "bearerAuth": [ "calls:read" ] } ], "x-fern-sdk-group-name": [ "cdrs" ], "x-fern-sdk-method-name": "get", "x-mcp": { "readOnly": true, "destructive": false, "openWorld": false, "expose": true }, "parameters": [ { "name": "call_id", "in": "path", "description": "The unique ID of the call.", "required": true, "style": "simple", "schema": { "type": "string", "format": "uuid", "pattern": "^[0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12}$", "example": "aa566501-c591-4a8b-b3b9-cc1295398b72" } }, { "name": "show_transcription", "in": "query", "description": "When `true`, includes the call transcription in the response.", "style": "form", "explode": true, "schema": { "type": "boolean", "example": true } } ], "responses": { "200": { "description": "Returns the CDR.", "headers": {}, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/CDRResponse" }, "examples": { "success": { "summary": "Successful response", "value": { "date": "2023-08-21T06:43:36.000Z", "from": "14302287001", "to": "33170363950", "disposition": "answered", "duration": 6, "destination": "France", "per_minute": "0.027", "recording_url": "https://api.wavix.com/v1/recordings/recording_id", "charge": "0.162", "sip_trunk": "32882", "forward_fee": "0.0", "uuid": "99df5ffd-962a-410f-bcce-d08f1f7f328c", "call_id": "99df5ffd-962a-410f-bcce-d08f1f7f328c", "parent_uuid": "99df5ffd-962a-410f-bcce-d08f1f7f328c", "answered_by": "human" } } } } } }, "400": { "$ref": "#/components/responses/BadRequestErrorResponse" }, "401": { "$ref": "#/components/responses/UnauthorizedErrorResponse" }, "403": { "$ref": "#/components/responses/ForbiddenErrorResponse" }, "404": { "$ref": "#/components/responses/NotFoundErrorResponse" } }, "deprecated": false } }, "/v1/cdrs/all": { "get": { "tags": [ "CDRs" ], "summary": "Export CDRs", "description": "Streams matching call detail records as newline-delimited JSON (NDJSON), one record per line, for bulk export.", "operationId": "cdrs_list_all", "security": [ { "bearerAuth": [ "calls:read" ] } ], "x-fern-sdk-group-name": [ "cdrs" ], "x-fern-sdk-method-name": "listAll", "x-mcp": { "readOnly": true, "destructive": false, "openWorld": false, "expose": false }, "parameters": [ { "name": "from", "in": "query", "description": "Start of the date range to query, in `YYYY-MM-DD` format. Inclusive.", "required": true, "style": "form", "explode": true, "schema": { "type": "string", "format": "date", "example": "2023-01-01" } }, { "name": "to", "in": "query", "description": "End of the date range to query, in `YYYY-MM-DD` format. Inclusive.", "required": true, "style": "form", "explode": true, "schema": { "type": "string", "format": "date", "example": "2023-09-01" } }, { "name": "type", "in": "query", "description": "Filters CDRs by call direction. One of `placed` (outbound calls dialed by the account) or `received` (inbound calls answered by the account).", "required": true, "style": "form", "explode": true, "schema": { "type": "string", "example": "received" } }, { "name": "disposition", "in": "query", "description": "Filters CDRs by call disposition. One of `answered` (the called party answered), `noanswer` (no answer within the ring timeout), `busy` (the called party was busy), `failed` (the call could not be routed), or `all` (no disposition filter).", "style": "form", "explode": true, "schema": { "$ref": "#/components/schemas/CallDisposition" } }, { "name": "from_search", "in": "query", "description": "Filters CDRs by originating phone number. Accepts a full or partial number.", "style": "form", "explode": true, "schema": { "type": "string", "example": "13524815863" } }, { "name": "to_search", "in": "query", "description": "Filters CDRs by destination phone number. Accepts a full or partial number.", "style": "form", "explode": true, "schema": { "type": "string", "example": "12565378257" } }, { "name": "sip_trunk", "in": "query", "description": "Filters outbound CDRs by SIP trunk login. Ignored for inbound calls.", "style": "form", "explode": true, "schema": { "type": "string", "example": "12321" } }, { "name": "uuid", "in": "query", "description": "Filters CDRs by the unique call ID.", "style": "form", "explode": true, "schema": { "type": "string", "example": "99df5ffd-962a-410f-bcce-d08f1f7f328c" } }, { "name": "page", "in": "query", "description": "Page number to retrieve. Default `1`.", "style": "form", "explode": true, "schema": { "type": "integer", "format": "int32", "example": 1 } }, { "name": "per_page", "in": "query", "description": "Number of records to return per page. Default `25`.", "style": "form", "explode": true, "schema": { "type": "integer", "format": "int32", "default": 25, "example": 25 } } ], "responses": { "200": { "description": "Returns an NDJSON stream of CDRs, one record per line.", "headers": { "Content-Type": { "description": "Media type of the response body. Always `application/x-ndjson`.", "schema": { "type": "string", "example": "application/x-ndjson" } }, "Last-Modified": { "description": "Timestamp when the exported data was last modified.", "schema": { "type": "string", "example": "0" } }, "ETag": { "description": "Entity tag identifying the version of the exported data.", "schema": { "type": "string", "example": "0" } } }, "content": { "application/x-ndjson": { "schema": { "type": "string", "description": "NDJSON stream of CDR records, one per line." }, "example": "{\"charge\":\"0.0059\",\"date\":\"2023-08-28T15:43:31.000Z\",\"destination\":\"My trunk\",\"disposition\":\"answered\",\"duration\":26,\"forward_fee\":\"0.0\",\"from\":\"13524815863\",\"per_minute\":\"0.0059\",\"to\":\"12565378257\",\"uuid\":\"99df5ffd-962a-410f-bcce-d08f1f7f328c\"}\n{\"charge\":\"0.00325\",\"date\":\"2023-11-29T14:48:50.000Z\",\"destination\":\"United States\",\"disposition\":\"answered\",\"duration\":21,\"from\":\"17182444444\",\"per_minute\":\"0.0065\",\"to\":\"18007009909\",\"uuid\":\"aa566501-c591-4a8b-b3b9-cc1295398b72\",\"forward_fee\":\"0.003\"}" } } }, "401": { "$ref": "#/components/responses/UnauthorizedErrorResponse" }, "403": { "$ref": "#/components/responses/ForbiddenErrorResponse" } }, "deprecated": false } }, "/v1/recordings": { "get": { "tags": [ "Call recording" ], "summary": "List call recordings", "description": "Returns a paginated list of call recordings for the authenticated account, filtered by date range, number, call, or SIP trunk.", "operationId": "call_recording_list", "security": [ { "bearerAuth": [ "recordings:read" ] } ], "x-fern-sdk-group-name": [ "callRecording" ], "x-fern-sdk-method-name": "list", "x-mcp": { "readOnly": true, "destructive": false, "openWorld": false, "expose": true }, "parameters": [ { "name": "from_date", "in": "query", "description": "Start of the date range to query, in `YYYY-MM-DD` format. Inclusive.", "required": false, "style": "form", "explode": true, "schema": { "type": "string", "format": "date", "example": "2023-01-01" } }, { "name": "to_date", "in": "query", "description": "End of the date range to query, in `YYYY-MM-DD` format. Inclusive.", "required": false, "style": "form", "explode": true, "schema": { "type": "string", "format": "date", "example": "2023-12-31" } }, { "name": "from", "in": "query", "description": "Filters recordings by originating phone number. Accepts a full or partial number.", "required": false, "style": "form", "explode": true, "schema": { "type": "string", "example": "123456" } }, { "name": "to", "in": "query", "description": "Filters recordings by destination phone number. Accepts a full or partial number.", "required": false, "style": "form", "explode": true, "schema": { "type": "string", "example": "1987654321" } }, { "name": "call_uuid", "in": "query", "description": "Filters recordings by the unique call ID.", "required": false, "style": "form", "explode": true, "schema": { "type": "string", "example": "aa566501-c591-4a8b-b3b9-cc1295398b72" } }, { "name": "sip_trunks", "in": "query", "description": "Filters recordings of outbound calls placed through the listed SIP trunk logins.", "required": false, "style": "form", "explode": true, "schema": { "type": "array", "items": { "type": "string" }, "example": [ "123", "456" ] } }, { "name": "page", "in": "query", "description": "Page number to retrieve. Default `1`.", "style": "form", "explode": true, "schema": { "type": "integer", "format": "int32", "example": 1 } }, { "name": "per_page", "in": "query", "description": "Number of records to return per page. Default `25`.", "style": "form", "explode": true, "schema": { "type": "integer", "format": "int32", "default": 25, "example": 25 } } ], "responses": { "200": { "description": "Returns a paginated list of call recordings.", "headers": {}, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/CallRecordingListResponse" }, "examples": { "success": { "summary": "Successful response", "value": { "recordings": [ { "id": 123, "created_at": "2023-06-15T10:30:00Z", "duration": 120, "from": "1234567890", "to": "0987654321", "call_uuid": "aa566501-c591-4a8b-b3b9-cc1295398b72", "url": "https://api.wavix.com/v1/recordings/uuid" } ], "invalid": { "dids": [ "invalid_did_1", "invalid_did_2" ], "sip_trunks": [ "invalid_trunk_1", "invalid_trunk_2" ] }, "pagination": { "current_page": 2, "per_page": 25, "total": 101, "total_pages": 5 } } } } } } }, "400": { "$ref": "#/components/responses/BadRequestErrorResponse" }, "401": { "$ref": "#/components/responses/UnauthorizedErrorResponse" }, "403": { "$ref": "#/components/responses/ForbiddenErrorResponse" } }, "deprecated": false } }, "/v1/recordings/{call_id}": { "get": { "tags": [ "Call recording" ], "summary": "Retrieve a recording by call ID", "description": "Redirects to the recording file for the call identified by `call_id`. The download URL is returned in the `Location` header.", "operationId": "call_recording_get_by_call", "security": [ { "bearerAuth": [ "recordings:read" ] } ], "x-fern-sdk-group-name": [ "callRecording" ], "x-fern-sdk-method-name": "getByCall", "x-mcp": { "readOnly": true, "destructive": false, "openWorld": false, "expose": false }, "parameters": [ { "name": "call_id", "in": "path", "description": "The unique ID of the call whose recording is retrieved.", "required": true, "style": "simple", "explode": false, "schema": { "type": "string", "example": "aa566501-c591-4a8b-b3b9-cc1295398b72" } } ], "responses": { "200": { "description": "Redirects to the recording file. The URL is in the `Location` header.", "headers": { "Location": { "description": "Download URL of the recording file.", "schema": { "type": "string", "example": "https://api.wavix.com/v1/recordings/uuid" } } } }, "400": { "description": "Returns when the recording has already been deleted.", "headers": {}, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/RecordingDeletedErrorResponse" } } } }, "401": { "$ref": "#/components/responses/UnauthorizedErrorResponse" }, "403": { "$ref": "#/components/responses/ForbiddenErrorResponse" }, "404": { "$ref": "#/components/responses/NotFoundErrorResponse" } }, "deprecated": false } }, "/v1/recordings/{id}": { "get": { "tags": [ "Call recording" ], "summary": "Retrieve a recording", "description": "Returns the call recording identified by `id`, including its metadata and download URL.", "operationId": "call_recording_get", "security": [ { "bearerAuth": [ "recordings:read" ] } ], "x-fern-sdk-group-name": [ "callRecording" ], "x-fern-sdk-method-name": "get", "x-mcp": { "readOnly": true, "destructive": false, "openWorld": false, "expose": true }, "parameters": [ { "name": "id", "in": "path", "description": "The unique ID of the call recording.", "required": true, "style": "simple", "explode": false, "schema": { "type": "integer", "format": "int32", "example": 123 } } ], "responses": { "200": { "description": "Returns the call recording.", "headers": {}, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Recording" }, "examples": { "success": { "summary": "Successful response", "value": { "id": 123, "created_at": "2023-06-15T10:30:00Z", "duration": 120, "from": "1234567890", "to": "0987654321", "call_uuid": "aa566501-c591-4a8b-b3b9-cc1295398b72", "url": "https://api.wavix.com/v1/recordings/uuid" } } } } } }, "401": { "$ref": "#/components/responses/UnauthorizedErrorResponse" }, "403": { "$ref": "#/components/responses/ForbiddenErrorResponse" }, "404": { "$ref": "#/components/responses/NotFoundErrorResponse" } }, "deprecated": false }, "delete": { "tags": [ "Call recording" ], "summary": "Delete a call recording", "description": "Deletes the call recording identified by `id`. Deletion is permanent — the audio file is unrecoverable.", "operationId": "call_recording_delete", "security": [ { "bearerAuth": [ "recordings:write" ] } ], "x-fern-sdk-group-name": [ "callRecording" ], "x-fern-sdk-method-name": "delete", "x-mcp": { "readOnly": false, "destructive": true, "openWorld": false, "expose": true }, "parameters": [ { "name": "id", "in": "path", "description": "The unique ID of the call recording.", "required": true, "style": "simple", "explode": false, "schema": { "type": "integer", "format": "int32", "example": 123 } } ], "responses": { "200": { "description": "Returns a success confirmation. The recording is deleted.", "headers": {}, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/SuccessResponse" }, "examples": { "default": { "value": { "success": true } } } } } }, "400": { "description": "Returns when the recording has already been deleted.", "headers": {}, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/RecordingDeletedErrorResponse" } } } }, "401": { "$ref": "#/components/responses/UnauthorizedErrorResponse" }, "403": { "$ref": "#/components/responses/ForbiddenErrorResponse" }, "404": { "$ref": "#/components/responses/NotFoundErrorResponse" } }, "deprecated": false } }, "/v1/speech-analytics": { "post": { "tags": [ "Speech Analytics" ], "summary": "Upload a file", "description": "Uploads an audio file for transcription. Transcription is asynchronous; Wavix sends a POST callback to `callback_url` when it completes, including the `request_id` returned by this request.\n\nCallback body:\n```json\n {\n \"request_id\": \"e865ea07-25af-4fdd-876e-04b0d41d5ebd\",\n \"status\": \"completed\",\n \"error\": null\n }\n```\n\n- `request_id`: ID of the transcription request.\n- `status`: One of `completed` (transcription succeeded) or `failed` (transcription encountered an error).\n- `error`: Error description, or `null` when the transcription succeeded.", "operationId": "speech_analytics_create", "security": [ { "bearerAuth": [ "calls:write" ] } ], "x-fern-sdk-group-name": [ "speechAnalytics" ], "x-fern-sdk-method-name": "create", "x-mcp": { "readOnly": false, "destructive": false, "openWorld": false, "expose": false }, "parameters": [], "requestBody": { "content": { "multipart/form-data": { "encoding": {}, "schema": { "required": [ "file", "callback_url" ], "type": "object", "additionalProperties": false, "properties": { "file": { "type": "string", "description": "Audio file to transcribe. Maximum size is 25 MB. Supported formats are WAV, MP3, and MP4 stereo.", "format": "binary" }, "callback_url": { "type": "string", "description": "URL that receives the POST callback when transcription completes.", "example": "https://you-site.com/webhook" }, "insights": { "type": "boolean", "description": "When `true`, generates conversation insights alongside the transcript.", "example": true } } } } }, "required": false }, "responses": { "200": { "description": "Returns the transcription `request_id` for the uploaded file.", "headers": {}, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/SubmitFileTranscriptionResponse" }, "examples": { "default": { "value": { "file": "file.mp3", "request_id": "e865ea07-25af-4fdd-876e-04b0d41d5ebd", "success": true } } } } } }, "400": { "$ref": "#/components/responses/BadRequestErrorResponse" }, "401": { "$ref": "#/components/responses/UnauthorizedErrorResponse" }, "403": { "$ref": "#/components/responses/ForbiddenErrorResponse" }, "422": { "$ref": "#/components/responses/ValidationErrorResponse" } }, "deprecated": false } }, "/v1/speech-analytics/{request_id}": { "get": { "tags": [ "Speech Analytics" ], "summary": "Retrieve a transcription", "description": "Returns the transcription for the request identified by `request_id`, including transcript, speaker turns, and insights when available.", "operationId": "speech_analytics_get", "security": [ { "bearerAuth": [ "calls:read" ] } ], "x-fern-sdk-group-name": [ "speechAnalytics" ], "x-fern-sdk-method-name": "get", "x-mcp": { "readOnly": true, "destructive": false, "openWorld": false, "expose": true }, "parameters": [ { "name": "request_id", "in": "path", "description": "The `request_id` of the transcription, returned when the file was uploaded.", "required": true, "style": "simple", "schema": { "type": "string", "example": "e865ea07-25af-4fdd-876e-04b0d41d5ebd" } } ], "responses": { "200": { "description": "Returns the completed transcription.", "headers": {}, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/FileTranscriptionResponse" }, "examples": { "success": { "summary": "Successful response", "value": { "transcript": { "channel_1": "Hi there", "channel_2": "Hello" }, "turns": [ { "speaker": "channel_1", "s": 600, "e": 700, "text": "Hi", "sentiment": "positive" } ], "request_id": "e84f350f-6da7-4b56-80eb-41dec572626b", "language": "en", "duration": 102, "charge": "0.01", "status": "completed", "transcription_date": "2023-01-09T10:04:39.734Z", "transcription_score": "3.8", "transcription_summary": "The agent and client discussed call recording and call transcription", "original_file": "https://api.wavix.com/v1/files/uuid" } } } } } }, "202": { "description": "Accepted. The transcription is still in progress.", "headers": {}, "content": { "application/json": { "schema": { "type": "object", "properties": { "success": { "type": "boolean", "description": "Indicates whether the request was accepted.", "example": true }, "status": { "type": "string", "enum": [ "pending" ], "description": "Machine-readable transcription status.", "example": "pending" }, "message": { "type": "string", "description": "Human-readable status message.", "example": "The transcription is still pending" }, "poll_after": { "type": "integer", "description": "Suggested number of seconds to wait before polling this endpoint again.", "example": 5 } } }, "examples": { "default": { "value": { "success": true, "status": "pending", "message": "The transcription is still pending", "poll_after": 5 } } } } } }, "400": { "$ref": "#/components/responses/BadRequestErrorResponse" }, "401": { "$ref": "#/components/responses/UnauthorizedErrorResponse" }, "403": { "$ref": "#/components/responses/ForbiddenErrorResponse" }, "404": { "$ref": "#/components/responses/NotFoundErrorResponse" } }, "deprecated": false }, "put": { "tags": [ "Speech Analytics" ], "summary": "Retranscribe a file", "description": "Re-runs transcription on the file identified by `request_id`, replacing the existing transcript.", "operationId": "speech_analytics_retranscribe", "security": [ { "bearerAuth": [ "calls:write" ] } ], "x-fern-sdk-group-name": [ "speechAnalytics" ], "x-fern-sdk-method-name": "retranscribe", "x-mcp": { "readOnly": false, "destructive": true, "openWorld": false, "expose": true }, "parameters": [ { "name": "request_id", "in": "path", "description": "The `request_id` of the transcription, returned when the file was uploaded.", "required": true, "style": "simple", "schema": { "type": "string", "example": "e865ea07-25af-4fdd-876e-04b0d41d5ebd" } } ], "requestBody": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/SpeechAnalyticsRetranscribeRequest" } } }, "required": true }, "responses": { "200": { "description": "Returns a success confirmation. Retranscription is queued.", "headers": {}, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/SuccessResponse" }, "examples": { "default": { "value": { "success": true } } } } } }, "400": { "$ref": "#/components/responses/BadRequestErrorResponse" }, "401": { "$ref": "#/components/responses/UnauthorizedErrorResponse" }, "403": { "$ref": "#/components/responses/ForbiddenErrorResponse" }, "404": { "$ref": "#/components/responses/NotFoundErrorResponse" }, "422": { "$ref": "#/components/responses/ValidationErrorResponse" } }, "deprecated": false } }, "/v1/speech-analytics/{request_id}/file": { "get": { "tags": [ "Speech Analytics" ], "summary": "Retrieve the original file", "description": "Returns the original audio file submitted for the transcription identified by `request_id`.", "operationId": "speech_analytics_file_get", "security": [ { "bearerAuth": [ "calls:read" ] } ], "x-fern-sdk-group-name": [ "speechAnalytics", "file" ], "x-fern-sdk-method-name": "get", "x-mcp": { "readOnly": true, "destructive": false, "openWorld": false, "expose": false }, "parameters": [ { "name": "request_id", "in": "path", "description": "The `request_id` of the transcription, returned when the file was uploaded.", "required": true, "style": "simple", "schema": { "type": "string", "example": "e865ea07-25af-4fdd-876e-04b0d41d5ebd" } } ], "responses": { "200": { "description": "Returns the original audio file.", "content": { "audio/wav": { "schema": { "type": "string", "format": "binary" } }, "audio/mpeg": { "schema": { "type": "string", "format": "binary" } }, "audio/mp4": { "schema": { "type": "string", "format": "binary" } } } }, "400": { "$ref": "#/components/responses/BadRequestErrorResponse" }, "401": { "$ref": "#/components/responses/UnauthorizedErrorResponse" }, "403": { "$ref": "#/components/responses/ForbiddenErrorResponse" }, "404": { "$ref": "#/components/responses/NotFoundErrorResponse" } }, "deprecated": false } }, "/v1/calls/webhooks": { "get": { "tags": [ "Call webhooks" ], "summary": "List call webhooks", "description": "Returns the configured call webhooks for the authenticated account. Wavix sends POST callbacks for `on-call` and `post-call` events.", "operationId": "call_webhooks_list", "security": [ { "bearerAuth": [ "webhooks:read" ] } ], "x-fern-sdk-group-name": [ "callWebhooks" ], "x-fern-sdk-method-name": "list", "x-mcp": { "readOnly": true, "destructive": false, "openWorld": false, "expose": true }, "parameters": [], "responses": { "200": { "description": "Returns the list of call webhooks.", "headers": {}, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/CallWebhookListResponse" }, "examples": { "default": { "value": [ { "event_type": "post-call", "url": "https://you-site.com/voice/post-call/webhook" }, { "event_type": "on-call", "url": "https://you-site.com/voice/on-call/webhook" } ] } } } } }, "400": { "$ref": "#/components/responses/BadRequestErrorResponse" }, "401": { "$ref": "#/components/responses/UnauthorizedErrorResponse" }, "403": { "$ref": "#/components/responses/ForbiddenErrorResponse" } }, "deprecated": false }, "post": { "tags": [ "Call webhooks" ], "summary": "Create a call webhook", "description": "Registers a callback URL for the `on-call` or `post-call` event. Wavix sends a POST callback to the URL when the event occurs. Creates persistent configuration that forwards call metadata to the URL on every matching call until the webhook is deleted.\n\n**Behavior:** Without `expected_url`, the webhook is set to `url` whatever it was before. With `expected_url`, the webhook is set only while it currently has that URL; an empty string matches an unset webhook. Otherwise the call returns `409` and the webhook is unchanged. Setting the URL the webhook already has succeeds. If the call returns a `Something went wrong` error, the webhook is unchanged and you can retry the request.", "operationId": "call_webhooks_create", "security": [ { "bearerAuth": [ "webhooks:write" ] } ], "x-fern-sdk-group-name": [ "callWebhooks" ], "x-fern-sdk-method-name": "create", "x-mcp": { "readOnly": false, "destructive": false, "openWorld": true, "expose": true }, "parameters": [], "requestBody": { "description": "Attributes for the new call webhook.", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/CallWebhooksCreateRequest" } } }, "required": true }, "responses": { "201": { "description": "Returns the created call webhook.", "headers": {}, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/CallWebhook" }, "examples": { "default": { "value": { "success": true, "event_type": "post-call", "url": "https://you-site.com/webhook" } } } } } }, "400": { "$ref": "#/components/responses/BadRequestErrorResponse" }, "401": { "$ref": "#/components/responses/UnauthorizedErrorResponse" }, "403": { "$ref": "#/components/responses/ForbiddenErrorResponse" }, "409": { "$ref": "#/components/responses/WebhookInUseErrorResponse" }, "422": { "$ref": "#/components/responses/ValidationErrorResponse" } }, "deprecated": false }, "delete": { "tags": [ "Call webhooks" ], "summary": "Delete a call webhook", "description": "Removes the call webhook for the given event type. Wavix stops sending callbacks for that event.\n\n**Behavior:** Without `expected_url`, the webhook is cleared whatever URL it has. With `expected_url`, the webhook is cleared only while it currently has that URL; an empty value matches an unset webhook. Otherwise the call returns `409` and the webhook is unchanged. Clearing an unset webhook succeeds. Percent-encode the `expected_url` value in the query string. If the call returns a `Something went wrong` error, the webhook is unchanged and you can retry the request.", "operationId": "call_webhooks_delete", "security": [ { "bearerAuth": [ "webhooks:write" ] } ], "x-fern-sdk-group-name": [ "callWebhooks" ], "x-fern-sdk-method-name": "delete", "x-mcp": { "readOnly": false, "destructive": true, "openWorld": false, "expose": true }, "parameters": [ { "name": "event_type", "in": "query", "description": "Event type of the webhook to delete. One of `post-call` (callbacks sent after a call ends) or `on-call` (real-time call status callbacks during a call).", "required": true, "style": "form", "explode": true, "schema": { "type": "string", "enum": [ "post-call", "on-call" ], "example": "post-call" } }, { "name": "expected_url", "in": "query", "description": "Clears the webhook only if it currently has this URL. Percent-encode the value. An empty value clears only an unset webhook.", "required": false, "style": "form", "explode": true, "schema": { "type": "string", "example": "https://your-site.com/webhook" } } ], "responses": { "200": { "description": "Returns a success confirmation. The call webhook is removed.", "headers": {}, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/SuccessResponse" }, "examples": { "default": { "value": { "success": true } } } } } }, "400": { "$ref": "#/components/responses/BadRequestErrorResponse" }, "401": { "$ref": "#/components/responses/UnauthorizedErrorResponse" }, "403": { "$ref": "#/components/responses/ForbiddenErrorResponse" }, "409": { "$ref": "#/components/responses/WebhookInUseErrorResponse" }, "422": { "$ref": "#/components/responses/ValidationErrorResponse" } }, "deprecated": false } }, "/v1/calls": { "post": { "tags": [ "Call control" ], "summary": "Start a call", "description": "Places a real, billable outbound PSTN call. Returns the call with its `uuid` for tracking and control.", "operationId": "call_control_create", "security": [ { "bearerAuth": [ "calls:write" ] } ], "x-fern-sdk-group-name": [ "callControl" ], "x-fern-sdk-method-name": "create", "x-mcp": { "readOnly": false, "destructive": true, "openWorld": true, "expose": true }, "parameters": [], "requestBody": { "description": "Attributes for the new outbound call.", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/CallRequest" } } }, "required": true }, "responses": { "200": { "description": "Returns the created call.", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/CallCreateResponse" }, "examples": { "success": { "summary": "Successful response", "value": { "uuid": "5dccb6b0-f35c-488c-867b-86fb012c4415", "direction": "inbound", "event_type": "call_setup", "event_time": "2025-09-22T12:56:38.547Z", "event_payload": null, "from": "+18045961058", "to": "17653889567", "call_started": "2025-09-22T12:56:38.547Z", "call_answered": "2023-06-15T10:30:00Z", "call_completed": "2023-06-15T10:30:00Z", "machine_detected": false, "tag": "" } } } } } }, "400": { "description": "Returns a validation error when a request parameter is invalid.", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/CallControlValidationErrorResponse" } } } }, "401": { "$ref": "#/components/responses/UnauthorizedErrorResponse" }, "403": { "$ref": "#/components/responses/ForbiddenErrorResponse" }, "404": { "$ref": "#/components/responses/NotFoundErrorResponse" } }, "deprecated": false }, "get": { "tags": [ "Call control" ], "summary": "List active calls", "description": "Returns the calls currently in progress for the authenticated account.", "operationId": "call_control_list", "security": [ { "bearerAuth": [ "calls:read" ] } ], "x-fern-sdk-group-name": [ "callControl" ], "x-fern-sdk-method-name": "list", "x-mcp": { "readOnly": true, "destructive": false, "openWorld": false, "expose": true }, "parameters": [], "responses": { "200": { "description": "Returns the list of active calls.", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/CallListResponse" }, "examples": { "success": { "summary": "Successful response", "value": { "calls": [ { "uuid": "5dccb6b0-f35c-488c-867b-86fb012c4415", "id": "5dccb6b0-f35c-488c-867b-86fb012c4415", "direction": "inbound", "event_type": "call_setup", "event_time": "2025-09-22T12:56:38.547Z", "event_payload": null, "from": "+18045961058", "to": "17653889567", "call_started": "2025-09-22T12:56:38.547Z", "call_answered": "2023-06-15T10:30:00Z", "call_completed": "2023-06-15T10:30:00Z", "machine_detected": false, "tag": "marketing-campaign" } ], "success": true } } } } } }, "400": { "$ref": "#/components/responses/BadRequestErrorResponse" }, "401": { "$ref": "#/components/responses/UnauthorizedErrorResponse" }, "403": { "$ref": "#/components/responses/ForbiddenErrorResponse" }, "404": { "$ref": "#/components/responses/NotFoundErrorResponse" } }, "deprecated": false } }, "/v1/calls/{id}": { "get": { "tags": [ "Call control" ], "summary": "Retrieve a call", "description": "Returns the call identified by `id`, including its current event and timestamps.", "operationId": "call_control_get", "security": [ { "bearerAuth": [ "calls:read" ] } ], "x-fern-sdk-group-name": [ "callControl" ], "x-fern-sdk-method-name": "get", "x-mcp": { "readOnly": true, "destructive": false, "openWorld": false, "expose": true }, "parameters": [ { "name": "id", "in": "path", "description": "The `uuid` of the call.", "required": true, "schema": { "type": "string", "format": "uuid" } } ], "responses": { "200": { "description": "Returns the call.", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/CallResponse" }, "examples": { "success": { "summary": "Successful response", "value": { "call": { "uuid": "5dccb6b0-f35c-488c-867b-86fb012c4415", "id": "5dccb6b0-f35c-488c-867b-86fb012c4415", "direction": "inbound", "event_type": "call_setup", "event_time": "2025-09-22T12:56:38.547Z", "event_payload": null, "from": "+18045961058", "to": "17653889567", "call_started": "2025-09-22T12:56:38.547Z", "call_answered": "2023-06-15T10:30:00Z", "call_completed": "2023-06-15T10:30:00Z", "machine_detected": false, "tag": "marketing-campaign" }, "success": true } } } } } }, "400": { "$ref": "#/components/responses/BadRequestErrorResponse" }, "401": { "$ref": "#/components/responses/UnauthorizedErrorResponse" }, "403": { "$ref": "#/components/responses/ForbiddenErrorResponse" }, "404": { "$ref": "#/components/responses/NotFoundErrorResponse" } }, "deprecated": false }, "delete": { "tags": [ "Call control" ], "summary": "End a call", "description": "Ends the active call identified by `id` by hanging up. Irreversible — the call cannot be resumed once ended.", "operationId": "call_control_delete", "security": [ { "bearerAuth": [ "calls:write" ] } ], "x-fern-sdk-group-name": [ "callControl" ], "x-fern-sdk-method-name": "delete", "x-mcp": { "readOnly": false, "destructive": true, "openWorld": false, "expose": true }, "parameters": [ { "name": "id", "in": "path", "description": "The `uuid` of the call.", "required": true, "schema": { "type": "string", "format": "uuid" } } ], "responses": { "200": { "description": "Returns a success confirmation. The call is ended.", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/SuccessResponse" }, "examples": { "success": { "summary": "Successful response", "value": { "success": true } } } } } }, "400": { "$ref": "#/components/responses/BadRequestErrorResponse" }, "401": { "$ref": "#/components/responses/UnauthorizedErrorResponse" }, "403": { "$ref": "#/components/responses/ForbiddenErrorResponse" }, "404": { "$ref": "#/components/responses/NotFoundErrorResponse" } }, "deprecated": false }, "patch": { "tags": [ "Call control" ], "summary": "Update a call", "description": "Updates the active call identified by `id`. Only the `tag` field can be changed.", "operationId": "call_control_update", "security": [ { "bearerAuth": [ "calls:write" ] } ], "x-fern-sdk-group-name": [ "callControl" ], "x-fern-sdk-method-name": "update", "x-mcp": { "readOnly": false, "destructive": false, "openWorld": false, "expose": true }, "parameters": [ { "name": "id", "in": "path", "description": "The `uuid` of the call.", "required": true, "schema": { "type": "string", "format": "uuid" } } ], "requestBody": { "description": "Fields to update on the call. Only `tag` is changed.", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/UpdateCallRequest" } } }, "required": true }, "responses": { "200": { "description": "Returns a success confirmation. The call `tag` is updated.", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/SuccessResponse" }, "examples": { "success": { "summary": "Successful response", "value": { "success": true } } } } } }, "400": { "$ref": "#/components/responses/BadRequestErrorResponse" }, "401": { "$ref": "#/components/responses/UnauthorizedErrorResponse" }, "403": { "$ref": "#/components/responses/ForbiddenErrorResponse" }, "404": { "$ref": "#/components/responses/NotFoundErrorResponse" } }, "deprecated": false } }, "/v1/calls/{id}/answer": { "post": { "tags": [ "Call control" ], "summary": "Answer a call", "description": "Answers the inbound call identified by `id`. Optionally starts recording, post-call transcription, or live media streaming on answer.", "operationId": "call_control_answer", "security": [ { "bearerAuth": [ "calls:write" ] } ], "x-fern-sdk-group-name": [ "callControl" ], "x-fern-sdk-method-name": "answer", "x-mcp": { "readOnly": false, "destructive": true, "openWorld": true, "expose": true }, "parameters": [ { "name": "id", "in": "path", "description": "The `uuid` of the call.", "required": true, "schema": { "type": "string", "format": "uuid" } } ], "requestBody": { "description": "Options to apply when answering the call.", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/CallAnswerRequest" } } }, "required": true }, "responses": { "200": { "description": "Returns a success confirmation. The call is answered.", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/SuccessResponse" }, "examples": { "success": { "summary": "Successful response", "value": { "success": true } } } } } }, "400": { "description": "Returns a validation error when a request parameter is invalid.", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/CallControlValidationErrorResponse" } } } }, "401": { "$ref": "#/components/responses/UnauthorizedErrorResponse" }, "403": { "$ref": "#/components/responses/ForbiddenErrorResponse" }, "404": { "$ref": "#/components/responses/NotFoundErrorResponse" } }, "deprecated": false } }, "/v1/calls/{call_id}/streams": { "post": { "tags": [ "Call streaming" ], "summary": "Start call streaming", "description": "Starts streaming the audio of the call identified by `call_id` to the WebSocket destination in `stream_url`, in the direction (`stream_type`) and channel (`stream_channel`) you configure. The streamed audio can include the remote party's voice.", "operationId": "call_control_streams_create", "security": [ { "bearerAuth": [ "calls:write" ] } ], "x-fern-sdk-group-name": [ "callControl", "streams" ], "x-fern-sdk-method-name": "create", "x-mcp": { "readOnly": false, "destructive": true, "openWorld": true, "expose": true }, "parameters": [ { "name": "call_id", "in": "path", "description": "The `uuid` of the call.", "required": true, "schema": { "type": "string", "format": "uuid" } } ], "requestBody": { "description": "Destination and options for the media stream.", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/CallStreamCreateRequest" } } }, "required": true }, "responses": { "200": { "description": "Returns the created media stream, including its `stream_id`.", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/CallStreamResponse" }, "examples": { "success": { "summary": "Successful response", "value": { "success": true, "stream_id": "123e4567-e89b-12d3-a456-426614174000" } } } } } }, "400": { "description": "Returns a validation error when a request parameter is invalid.", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/CallControlValidationErrorResponse" } } } }, "401": { "$ref": "#/components/responses/UnauthorizedErrorResponse" }, "403": { "$ref": "#/components/responses/ForbiddenErrorResponse" }, "404": { "$ref": "#/components/responses/NotFoundErrorResponse" }, "422": { "$ref": "#/components/responses/ValidationErrorResponse" } }, "deprecated": false } }, "/v1/calls/{call_id}/streams/{id}": { "delete": { "tags": [ "Call streaming" ], "summary": "Stop call streaming", "description": "Stops the media stream identified by `id` on the call identified by `call_id`.", "operationId": "call_control_streams_delete", "security": [ { "bearerAuth": [ "calls:write" ] } ], "x-fern-sdk-group-name": [ "callControl", "streams" ], "x-fern-sdk-method-name": "delete", "x-mcp": { "readOnly": false, "destructive": true, "openWorld": false, "expose": true }, "parameters": [ { "name": "call_id", "in": "path", "description": "The `uuid` of the call.", "required": true, "schema": { "type": "string", "format": "uuid" } }, { "name": "id", "in": "path", "description": "The `uuid` of the media stream to stop.", "required": true, "schema": { "type": "string", "format": "uuid" } } ], "responses": { "200": { "description": "Returns a success confirmation. The media stream is stopped.", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/SuccessResponse" }, "examples": { "success": { "summary": "Successful response", "value": { "success": true } } } } } }, "400": { "$ref": "#/components/responses/BadRequestErrorResponse" }, "401": { "$ref": "#/components/responses/UnauthorizedErrorResponse" }, "403": { "$ref": "#/components/responses/ForbiddenErrorResponse" }, "404": { "$ref": "#/components/responses/NotFoundErrorResponse" } }, "deprecated": false } }, "/v1/calls/{id}/play": { "post": { "tags": [ "Call control" ], "summary": "Play audio", "description": "Plays an audio prompt into the active call identified by `id`. The audio is audible to the remote party in real time.", "operationId": "call_control_audio_play", "security": [ { "bearerAuth": [ "calls:write" ] } ], "x-fern-sdk-group-name": [ "callControl", "audio" ], "x-fern-sdk-method-name": "play", "x-mcp": { "readOnly": false, "destructive": true, "openWorld": true, "expose": true }, "parameters": [ { "name": "id", "in": "path", "description": "The `uuid` of the call.", "required": true, "schema": { "type": "string", "format": "uuid" } } ], "requestBody": { "description": "Audio source and playback options.", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/CallAudioPlayRequest" } } }, "required": true }, "responses": { "200": { "description": "Returns a success confirmation. Audio playback starts.", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/SuccessResponse" }, "examples": { "success": { "summary": "Successful response", "value": { "success": true } } } } } }, "400": { "description": "Returns a validation error when a request parameter is invalid.", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/CallControlValidationErrorResponse" } } } }, "401": { "$ref": "#/components/responses/UnauthorizedErrorResponse" }, "403": { "$ref": "#/components/responses/ForbiddenErrorResponse" }, "404": { "$ref": "#/components/responses/NotFoundErrorResponse" } }, "deprecated": false } }, "/v1/calls/{id}/audio": { "delete": { "tags": [ "Call control" ], "summary": "Stop audio playback", "description": "Stops audio playback in the active call identified by `id`.", "operationId": "call_control_audio_stop", "security": [ { "bearerAuth": [ "calls:write" ] } ], "x-fern-sdk-group-name": [ "callControl", "audio" ], "x-fern-sdk-method-name": "stop", "x-mcp": { "readOnly": false, "destructive": true, "openWorld": false, "expose": true }, "parameters": [ { "name": "id", "in": "path", "description": "The `uuid` of the call.", "required": true, "schema": { "type": "string", "format": "uuid" } } ], "responses": { "200": { "description": "Returns a success confirmation. Audio playback stops.", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/SuccessResponse" }, "examples": { "success": { "summary": "Successful response", "value": { "success": true } } } } } }, "400": { "$ref": "#/components/responses/BadRequestErrorResponse" }, "401": { "$ref": "#/components/responses/UnauthorizedErrorResponse" }, "403": { "$ref": "#/components/responses/ForbiddenErrorResponse" }, "404": { "$ref": "#/components/responses/NotFoundErrorResponse" } }, "deprecated": false } }, "/v1/calls/{id}/collect": { "post": { "tags": [ "Call control" ], "summary": "Collect DTMF input", "description": "Collects DTMF keypad input from the caller on the active call identified by `id`.", "operationId": "call_control_collect", "security": [ { "bearerAuth": [ "calls:write" ] } ], "x-fern-sdk-group-name": [ "callControl" ], "x-fern-sdk-method-name": "collect", "x-mcp": { "readOnly": false, "destructive": false, "openWorld": false, "expose": true }, "parameters": [ { "name": "id", "in": "path", "description": "The `uuid` of the call.", "required": true, "schema": { "type": "string", "format": "uuid" } } ], "requestBody": { "description": "Options for the DTMF collection.", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/CallDtmfCollectRequest" } } }, "required": true }, "responses": { "200": { "description": "Returns a success confirmation. DTMF collection starts.", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/SuccessResponse" }, "examples": { "success": { "summary": "Successful response", "value": { "success": true } } } } } }, "400": { "description": "Returns a validation error when a request parameter is invalid.", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/CallControlValidationErrorResponse" } } } }, "401": { "$ref": "#/components/responses/UnauthorizedErrorResponse" }, "403": { "$ref": "#/components/responses/ForbiddenErrorResponse" }, "404": { "$ref": "#/components/responses/NotFoundErrorResponse" } }, "deprecated": false } }, "/v2/webrtc/tokens": { "post": { "tags": [ "Wavix Embeddable" ], "summary": "Create a widget token", "description": "Creates a Wavix Embeddable widget token that authenticates a browser-based softphone session. The token expires after `ttl` seconds.", "operationId": "webrtc_tokens_create", "security": [ { "bearerAuth": [ "embeddable:write" ] } ], "x-fern-sdk-group-name": [ "webrtc", "tokens" ], "x-fern-sdk-method-name": "create", "x-mcp": { "readOnly": false, "destructive": false, "openWorld": false, "expose": true }, "parameters": [], "requestBody": { "description": "Attributes for the new widget token.", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/WebRTCTokenCreateRequest" }, "example": { "sip_trunk": "my-sip-trunk", "ttl": 3600, "payload": { "user_id": "42" } } } }, "required": true }, "responses": { "201": { "description": "Returns the created widget token.", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/WebRTCTokenResponse" }, "examples": { "success": { "summary": "Successful response", "value": { "token": "eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9...", "uuid": "uuid", "sip_trunk": "sip trunk", "payload": {}, "ttl": 123 } } } } } }, "400": { "$ref": "#/components/responses/BadRequestErrorResponse" }, "401": { "$ref": "#/components/responses/UnauthorizedErrorResponse" }, "403": { "$ref": "#/components/responses/ForbiddenErrorResponse" }, "404": { "$ref": "#/components/responses/NotFoundErrorResponse" } }, "deprecated": false }, "get": { "tags": [ "Wavix Embeddable" ], "summary": "List widget tokens", "description": "Returns a paginated list of Wavix Embeddable widget tokens for the authenticated account.", "operationId": "webrtc_tokens_list", "security": [ { "bearerAuth": [ "embeddable:read" ] } ], "x-fern-sdk-group-name": [ "webrtc", "tokens" ], "x-fern-sdk-method-name": "list", "x-mcp": { "readOnly": true, "destructive": false, "openWorld": false, "expose": true }, "parameters": [ { "name": "page", "in": "query", "description": "Page number to retrieve. Default `1`.", "style": "form", "schema": { "type": "integer", "format": "int32" } }, { "name": "per_page", "in": "query", "description": "Number of records to return per page. Default `25`.", "style": "form", "schema": { "type": "integer", "format": "int32" } } ], "responses": { "200": { "description": "Returns a paginated list of widget tokens.", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/WebRTCTokensListResponse" }, "examples": { "success": { "summary": "Successful response", "value": { "items": [ { "uuid": "550e8400-e29b-41d4-a716-446655440000", "sip_trunk": "my-sip-trunk", "payload": {}, "ttl": 3600 } ], "pagination": { "current_page": 2, "per_page": 25, "total": 101, "total_pages": 5 } } } } } } }, "401": { "$ref": "#/components/responses/UnauthorizedErrorResponse" }, "403": { "$ref": "#/components/responses/ForbiddenErrorResponse" } }, "deprecated": false } }, "/v2/webrtc/tokens/{id}": { "get": { "tags": [ "Wavix Embeddable" ], "summary": "Retrieve a widget token", "description": "Returns the Wavix Embeddable widget token identified by `id`.", "operationId": "webrtc_tokens_get", "security": [ { "bearerAuth": [ "embeddable:read" ] } ], "x-fern-sdk-group-name": [ "webrtc", "tokens" ], "x-fern-sdk-method-name": "get", "x-mcp": { "readOnly": true, "destructive": false, "openWorld": false, "expose": true }, "parameters": [ { "name": "id", "in": "path", "description": "The UUID of the widget token to retrieve.", "required": true, "schema": { "type": "string", "format": "uuid" } } ], "responses": { "200": { "description": "Returns the widget token.", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/WebRTCToken" }, "examples": { "success": { "summary": "Successful response", "value": { "uuid": "550e8400-e29b-41d4-a716-446655440000", "sip_trunk": "my-sip-trunk", "payload": {}, "ttl": 3600 } } } } } }, "400": { "$ref": "#/components/responses/BadRequestErrorResponse" }, "401": { "$ref": "#/components/responses/UnauthorizedErrorResponse" }, "403": { "$ref": "#/components/responses/ForbiddenErrorResponse" }, "404": { "$ref": "#/components/responses/NotFoundErrorResponse" } }, "deprecated": false }, "put": { "tags": [ "Wavix Embeddable" ], "summary": "Update a widget token", "description": "Updates the `payload` carried by the Wavix Embeddable widget token identified by `id`.", "operationId": "webrtc_tokens_update", "security": [ { "bearerAuth": [ "embeddable:write" ] } ], "x-fern-sdk-group-name": [ "webrtc", "tokens" ], "x-fern-sdk-method-name": "update", "x-mcp": { "readOnly": false, "destructive": false, "openWorld": false, "expose": true }, "parameters": [ { "name": "id", "in": "path", "description": "The UUID of the widget token to update.", "required": true, "schema": { "type": "string", "format": "uuid" } } ], "requestBody": { "description": "Fields to update on the widget token. Only included fields are changed.", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/WebRTCTokenUpdateRequest" } } }, "required": true }, "responses": { "200": { "description": "Returns the updated widget token.", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/WebRTCToken" }, "examples": { "success": { "summary": "Successful response", "value": { "uuid": "550e8400-e29b-41d4-a716-446655440000", "sip_trunk": "my-sip-trunk", "payload": {}, "ttl": 3600 } } } } } }, "400": { "$ref": "#/components/responses/BadRequestErrorResponse" }, "401": { "$ref": "#/components/responses/UnauthorizedErrorResponse" }, "403": { "$ref": "#/components/responses/ForbiddenErrorResponse" }, "404": { "$ref": "#/components/responses/NotFoundErrorResponse" } }, "deprecated": false }, "delete": { "tags": [ "Wavix Embeddable" ], "summary": "Delete a widget token", "description": "Deletes the Wavix Embeddable widget token identified by `id`. The token can no longer authenticate widget sessions, and any active session using it ends.", "operationId": "webrtc_tokens_delete", "security": [ { "bearerAuth": [ "embeddable:write" ] } ], "x-fern-sdk-group-name": [ "webrtc", "tokens" ], "x-fern-sdk-method-name": "delete", "x-mcp": { "readOnly": false, "destructive": true, "openWorld": false, "expose": true }, "parameters": [ { "name": "id", "in": "path", "description": "The UUID of the widget token to delete.", "required": true, "schema": { "type": "string", "format": "uuid" } } ], "responses": { "200": { "description": "Returns a success confirmation. The widget token is deleted.", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/SuccessResponse" }, "examples": { "success": { "summary": "Successful response", "value": { "success": true } } } } } }, "400": { "$ref": "#/components/responses/BadRequestErrorResponse" }, "401": { "$ref": "#/components/responses/UnauthorizedErrorResponse" }, "403": { "$ref": "#/components/responses/ForbiddenErrorResponse" }, "404": { "$ref": "#/components/responses/NotFoundErrorResponse" } }, "deprecated": false } }, "/v3/messages/sender-ids": { "get": { "tags": [ "SMS and MMS" ], "summary": "List Sender IDs", "description": "Returns the Sender IDs registered for the authenticated account.", "operationId": "sms_and_mms_sender_ids_list", "security": [ { "bearerAuth": [ "messages:read" ] } ], "x-fern-sdk-group-name": [ "smsAndMms", "senderIds" ], "x-fern-sdk-method-name": "list", "x-mcp": { "readOnly": true, "destructive": false, "openWorld": false, "expose": true }, "parameters": [], "responses": { "200": { "description": "Returns the list of Sender IDs.", "headers": {}, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/SenderIDListResponse" }, "examples": { "success": { "summary": "Successful response", "value": { "items": [ { "id": "3c7a5a90-43e0-43e0-b006-fdfea30c5a7c", "sender_id": "org_123", "type": "numeric", "allowlisted_in": [ "allowlisted in" ], "usecase": "usecase", "samples": [ "samples" ] } ] } } } } } }, "400": { "$ref": "#/components/responses/BadRequestErrorResponse" }, "401": { "$ref": "#/components/responses/UnauthorizedErrorResponse" }, "403": { "$ref": "#/components/responses/ForbiddenErrorResponse" } }, "deprecated": false }, "post": { "tags": [ "SMS and MMS" ], "summary": "Create a Sender ID", "description": "Creates a Sender ID. Use the 10DLC API to create Sender IDs in the US. Registering a Sender ID incurs a recurring monthly fee, billed to the account balance.", "operationId": "sms_and_mms_sender_ids_create", "security": [ { "bearerAuth": [ "messages:write" ] } ], "x-fern-sdk-group-name": [ "smsAndMms", "senderIds" ], "x-fern-sdk-method-name": "create", "x-mcp": { "readOnly": false, "destructive": true, "openWorld": false, "expose": true }, "parameters": [], "requestBody": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/SenderIDCreateRequest" } } }, "required": true }, "responses": { "201": { "description": "Returns the created Sender ID.", "headers": {}, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/SenderIDDetails" }, "examples": { "success": { "summary": "Successful response", "value": { "id": "3c7a5a90-43e0-43e0-b006-fdfea30c5a7c", "sender_id": "Wavix", "type": "numeric", "allowlisted_in": [ "example" ], "usecase": "example", "samples": [ "example" ] } } } } } }, "400": { "$ref": "#/components/responses/BadRequestErrorResponse" }, "401": { "$ref": "#/components/responses/UnauthorizedErrorResponse" }, "403": { "$ref": "#/components/responses/ForbiddenErrorResponse" }, "404": { "$ref": "#/components/responses/NotFoundErrorResponse" }, "422": { "$ref": "#/components/responses/ValidationErrorResponse" } }, "deprecated": false } }, "/v3/messages/sender-ids/{id}": { "get": { "tags": [ "SMS and MMS" ], "summary": "Retrieve a Sender ID", "description": "Returns the Sender ID identified by `id`.", "operationId": "sms_and_mms_sender_ids_get", "security": [ { "bearerAuth": [ "messages:read" ] } ], "x-fern-sdk-group-name": [ "smsAndMms", "senderIds" ], "x-fern-sdk-method-name": "get", "x-mcp": { "readOnly": true, "destructive": false, "openWorld": false, "expose": true }, "parameters": [ { "name": "id", "in": "path", "required": true, "description": "The unique ID of the Sender ID.", "schema": { "type": "string", "format": "uuid" } } ], "responses": { "200": { "description": "Returns the Sender ID.", "headers": {}, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/SenderIDResponse" }, "examples": { "success": { "summary": "Successful response", "value": { "id": "3c7a5a90-43e0-43e0-b006-fdfea30c5a7c", "sender_id": "Wavix", "type": "alphanumeric", "usecase": "promo", "samples": [ "Sample" ], "allowlisted_in": [ "GB" ] } } } } } }, "400": { "$ref": "#/components/responses/BadRequestErrorResponse" }, "401": { "$ref": "#/components/responses/UnauthorizedErrorResponse" }, "403": { "$ref": "#/components/responses/ForbiddenErrorResponse" }, "404": { "$ref": "#/components/responses/NotFoundErrorResponse" } }, "deprecated": false }, "delete": { "tags": [ "SMS and MMS" ], "summary": "Delete a Sender ID", "description": "Deletes the Sender ID identified by `id`. Deletion is permanent.", "operationId": "sms_and_mms_sender_ids_delete", "security": [ { "bearerAuth": [ "messages:write" ] } ], "x-fern-sdk-group-name": [ "smsAndMms", "senderIds" ], "x-fern-sdk-method-name": "delete", "x-mcp": { "readOnly": false, "destructive": true, "openWorld": false, "expose": true }, "parameters": [ { "name": "id", "in": "path", "description": "The unique ID of the Sender ID.", "required": true, "style": "simple", "schema": { "type": "string", "example": "fc34ba88-1eee-476e-b09e-dae63dc441e0" } } ], "responses": { "200": { "description": "Returns a success confirmation. The Sender ID is deleted.", "headers": {}, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/SuccessResponse" }, "examples": { "success": { "summary": "Successful response", "value": { "success": true } } } } } }, "400": { "$ref": "#/components/responses/BadRequestErrorResponse" }, "401": { "$ref": "#/components/responses/UnauthorizedErrorResponse" }, "403": { "$ref": "#/components/responses/ForbiddenErrorResponse" }, "404": { "description": "Returns when no Sender ID matches `id`.", "headers": {}, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/RecordNotFoundErrorResponse" }, "examples": { "success": { "summary": "Successful response", "value": { "success": false, "message": "Record not found" } } } } } }, "422": { "$ref": "#/components/responses/ValidationErrorResponse" } }, "deprecated": false } }, "/v3/messages/opt-outs": { "get": { "tags": [ "SMS and MMS" ], "summary": "List opted-out phone numbers", "description": "Returns a paginated list of phone numbers that have opted out of receiving messages from the authenticated account.", "operationId": "sms_and_mms_opt_outs_list", "security": [ { "bearerAuth": [ "messages:read" ] } ], "x-fern-sdk-group-name": [ "smsAndMms", "optOuts" ], "x-fern-sdk-method-name": "list", "x-mcp": { "readOnly": true, "destructive": false, "openWorld": false, "expose": true }, "parameters": [ { "in": "query", "name": "sender_id", "schema": { "type": "string" }, "description": "Filters opt-outs by the Sender ID they apply to.", "example": "MySender" }, { "in": "query", "name": "campaign_id", "schema": { "type": "string" }, "description": "Filters opt-outs by the 10DLC campaign ID they apply to.", "example": "C123456" }, { "in": "query", "name": "created_after", "schema": { "type": "string", "format": "date" }, "description": "Returns opt-outs created on or after this date, in `YYYY-MM-DD` format.", "example": "2024-01-01" }, { "in": "query", "name": "created_before", "schema": { "type": "string", "format": "date" }, "description": "Returns opt-outs created on or before this date, in `YYYY-MM-DD` format.", "example": "2024-12-31" }, { "in": "query", "name": "page", "schema": { "type": "integer", "minimum": 1 }, "description": "Page number to retrieve. Minimum `1`, default `1`.", "example": 1 }, { "in": "query", "name": "per_page", "schema": { "type": "integer", "minimum": 1, "maximum": 100 }, "description": "Number of records to return per page. Default `25`, maximum `100`.", "example": 25 } ], "responses": { "200": { "description": "Returns a paginated list of opted-out phone numbers.", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/OptOutsListResponse" }, "examples": { "default": { "value": { "items": [ { "phone_number": "15551234567", "sender_id": "MySender", "campaign_id": null, "created_at": "2024-01-15T10:30:00Z" }, { "phone_number": "15559876543", "sender_id": null, "campaign_id": "C123456", "created_at": "2024-01-16T14:45:00Z" } ], "pagination": { "current_page": 1, "per_page": 25, "total": 2, "total_pages": 1 } } } } } } }, "400": { "$ref": "#/components/responses/BadRequestErrorResponse" }, "401": { "$ref": "#/components/responses/UnauthorizedErrorResponse" }, "403": { "$ref": "#/components/responses/ForbiddenErrorResponse" }, "422": { "$ref": "#/components/responses/ValidationErrorResponse" } }, "deprecated": false }, "post": { "tags": [ "SMS and MMS" ], "summary": "Create an opt-out", "description": "Opts a phone number out of receiving messages from a Sender ID, a 10DLC campaign, or all outbound messages.", "operationId": "sms_and_mms_opt_outs_create", "security": [ { "bearerAuth": [ "messages:write" ] } ], "x-fern-sdk-group-name": [ "smsAndMms", "optOuts" ], "x-fern-sdk-method-name": "create", "x-mcp": { "readOnly": false, "destructive": false, "openWorld": false, "expose": true }, "parameters": [], "requestBody": { "description": "Attributes for the new opt-out.", "content": { "application/json": { "schema": { "allOf": [ { "$ref": "#/components/schemas/OptOutCreateRequest" } ], "type": "object" } } }, "required": true }, "responses": { "201": { "description": "Returns a success confirmation. The opt-out is created.", "headers": {}, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/SuccessResponse" }, "examples": { "default": { "value": { "success": true } } } } } }, "400": { "$ref": "#/components/responses/BadRequestErrorResponse" }, "401": { "$ref": "#/components/responses/UnauthorizedErrorResponse" }, "403": { "$ref": "#/components/responses/ForbiddenErrorResponse" }, "404": { "$ref": "#/components/responses/NotFoundErrorResponse" }, "422": { "$ref": "#/components/responses/ValidationErrorResponse" } }, "deprecated": false } }, "/v3/messages": { "post": { "tags": [ "SMS and MMS" ], "summary": "Send a message", "description": "Sends an SMS or MMS message. MMS is supported for U.S. numbers only. Track delivery using the returned `message_id` and the message status callback. The recipient must be opted in to receive messages from the account; sending to an opted-out number fails.", "operationId": "sms_and_mms_messages_send", "security": [ { "bearerAuth": [ "messages:write" ] } ], "x-fern-sdk-group-name": [ "smsAndMms", "messages" ], "x-fern-sdk-method-name": "send", "x-mcp": { "readOnly": false, "destructive": true, "openWorld": true, "expose": true }, "parameters": [], "requestBody": { "description": "Attributes for the message to send.", "content": { "application/json": { "schema": { "allOf": [ { "$ref": "#/components/schemas/MessageCreateRequest" }, { "description": "Sender, recipient, and content of the message.", "example": { "from": "Wavix", "to": "+447537151866", "message_body": { "text": "Hi there, this is a message from Wavix", "media": null }, "callback_url": "https://you-site.com/webhook", "validity": 3600, "tag": "Fall sale" } } ], "type": "object" }, "example": { "from": "Wavix", "to": "+447537151866", "message_body": { "text": "Hi there, this is a message from Wavix", "media": null }, "callback_url": "https://you-site.com/webhook", "validity": 3600, "tag": "Fall sale" } } }, "required": true }, "responses": { "201": { "description": "Returns the submitted message with its `message_id` and initial status.", "headers": {}, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/SendMessagesResponse" }, "examples": { "default": { "value": { "carrier_fees": "0.0", "charge": "0.0", "delivered_at": "2024-05-28T12:34:56Z", "error_message": null, "from": "Sender", "mcc": "310", "mnc": "260", "message_body": { "text": "This is a test MMS message with multiple media attachments.", "media": [ "https://api.examples.com/v3/messages/attachments/abc123/file1.mp3", "https://api.examples.com/v3/messages/attachments/abc123/file2.mp3", "https://api.examples.com/v3/messages/attachments/abc123/file3.mp3" ] }, "message_id": "abc123de-4567-890f-gh12-ijklmnop3456", "message_type": "mms", "segments": 1, "sent_at": "2024-05-28T12:34:54Z", "status": "accepted", "submitted_at": "2025-09-22T09:07:53", "tag": "campaign_test", "to": "+15551234567" } } } } } }, "400": { "$ref": "#/components/responses/BadRequestErrorResponse" }, "401": { "$ref": "#/components/responses/UnauthorizedErrorResponse" }, "403": { "$ref": "#/components/responses/ForbiddenErrorResponse" }, "404": { "$ref": "#/components/responses/NotFoundErrorResponse" }, "422": { "$ref": "#/components/responses/ValidationErrorResponse" }, "429": { "$ref": "#/components/responses/TooManyRequestsErrorResponse" } }, "deprecated": false }, "get": { "tags": [ "SMS and MMS" ], "summary": "List messages", "description": "Returns a paginated list of SMS and MMS messages for the authenticated account, filtered by direction, date, and other criteria.", "operationId": "sms_and_mms_messages_list", "security": [ { "bearerAuth": [ "messages:read" ] } ], "x-fern-sdk-group-name": [ "smsAndMms", "messages" ], "x-fern-sdk-method-name": "list", "x-mcp": { "readOnly": true, "destructive": false, "openWorld": false, "expose": true }, "parameters": [ { "name": "sent_after", "in": "query", "description": "Returns messages sent on or after this date, in `YYYY-MM-DD` format.", "style": "form", "explode": true, "schema": { "type": "string", "format": "date", "example": "2023-04-10" } }, { "name": "sent_before", "in": "query", "description": "Returns messages sent on or before this date, in `YYYY-MM-DD` format.", "style": "form", "explode": true, "schema": { "type": "string", "format": "date", "example": "2023-04-13" } }, { "name": "type", "in": "query", "description": "Filters messages by direction. One of `inbound` (messages received by the account) or `outbound` (messages sent by the account).", "required": true, "style": "form", "explode": true, "schema": { "type": "string", "example": "outbound" } }, { "name": "from", "in": "query", "description": "Filters by message sender. For `outbound` messages, the Sender ID used to send the message; for `inbound` messages, the originating phone number.", "style": "form", "explode": true, "schema": { "type": "string", "example": "15072429497" } }, { "name": "to", "in": "query", "description": "Filters by message recipient. For `outbound` messages, the destination phone number; for `inbound` messages, an SMS-enabled number on the Wavix platform.", "style": "form", "explode": true, "schema": { "type": "string", "example": "16419252149" } }, { "name": "status", "in": "query", "description": "Filters messages by delivery status. Accepts a `MessageDeliveryStatus` value.", "style": "form", "explode": true, "schema": { "$ref": "#/components/schemas/MessageDeliveryStatus" } }, { "name": "tag", "in": "query", "description": "Filters messages by `tag`. Supported for outbound messages only.", "style": "form", "explode": true, "schema": { "type": "string", "example": "campaignX" } }, { "name": "message_type", "in": "query", "description": "Filters messages by type. One of `sms` (text message) or `mms` (multimedia message).", "style": "form", "explode": true, "schema": { "type": "string", "enum": [ "sms", "mms" ], "example": "sms" } }, { "name": "page", "in": "query", "description": "Page number to retrieve. Default `1`.", "style": "form", "explode": true, "schema": { "type": "integer", "format": "int32", "example": 2 } }, { "name": "per_page", "in": "query", "description": "Number of records to return per page. Default `25`.", "style": "form", "explode": true, "schema": { "type": "integer", "format": "int32", "example": 50 } } ], "responses": { "200": { "description": "Returns a paginated list of messages.", "headers": {}, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/MessageListResponse" }, "examples": { "success": { "summary": "Successful response", "value": { "items": [ { "charge": "0.0475", "delivered_at": "2023-08-29T12:32:45.000Z", "direction": "outbound", "error_message": null, "from": "Sender ID.", "mcc": "234", "message_body": { "text": "Please call me back", "media": null }, "message_id": "3a525ca2-6909-4c72-9399-905adf7f3a74", "message_type": "sms", "mnc": "024", "segments": 1, "sent_at": "2023-08-29T12:32:44.000Z", "status": "delivered", "submitted_at": "2023-08-29T12:32:44.000Z", "carrier_fees": "0.0", "tag": null, "to": "447537151866" } ], "pagination": { "current_page": 1, "per_page": 10, "total": 1, "total_pages": 1 } } } } } } }, "400": { "$ref": "#/components/responses/BadRequestErrorResponse" }, "401": { "$ref": "#/components/responses/UnauthorizedErrorResponse" }, "403": { "$ref": "#/components/responses/ForbiddenErrorResponse" } }, "deprecated": false } }, "/v3/messages/{id}": { "get": { "tags": [ "SMS and MMS" ], "summary": "Retrieve a message", "description": "Returns the SMS or MMS message identified by `id`, including its delivery status and content.", "operationId": "sms_and_mms_messages_get", "security": [ { "bearerAuth": [ "messages:read" ] } ], "x-fern-sdk-group-name": [ "smsAndMms", "messages" ], "x-fern-sdk-method-name": "get", "x-mcp": { "readOnly": true, "destructive": false, "openWorld": false, "expose": true }, "parameters": [ { "name": "id", "in": "path", "description": "The unique ID of the message.", "required": true, "style": "simple", "explode": false, "schema": { "type": "string", "format": "uuid", "pattern": "^[0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12}$", "example": "3a525ca2-6909-4c72-9399-905adf7f3a74" } } ], "responses": { "200": { "description": "Returns the message.", "headers": {}, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/MessageResponse" }, "examples": { "success": { "summary": "Successful response", "value": { "message_id": "3a525ca2-6909-4c72-9399-905adf7f3a74", "message_type": "sms", "from": "15072429497", "to": "16419252149", "direction": "outbound", "mcc": "310", "mnc": "024", "message_body": { "text": "Hello, this is a test message", "media": null }, "tag": "Fall sale", "status": "delivered", "segments": 1, "charge": "0.01", "submitted_at": "2022-04-14T13:51:16.096Z", "sent_at": "2022-04-14T13:51:16.096Z", "delivered_at": "2022-04-14T13:51:16.096Z", "error_message": null, "carrier_fees": "0.0" } } } } } }, "400": { "$ref": "#/components/responses/BadRequestErrorResponse" }, "401": { "$ref": "#/components/responses/UnauthorizedErrorResponse" }, "403": { "$ref": "#/components/responses/ForbiddenErrorResponse" }, "404": { "$ref": "#/components/responses/NotFoundErrorResponse" } }, "deprecated": false } }, "/v3/messages/all": { "get": { "tags": [ "SMS and MMS" ], "summary": "Export messages", "description": "Streams matching SMS and MMS messages as newline-delimited JSON (NDJSON), one message per line, for bulk export.", "operationId": "sms_and_mms_messages_list_all", "security": [ { "bearerAuth": [ "messages:read" ] } ], "x-fern-sdk-group-name": [ "smsAndMms", "messages" ], "x-fern-sdk-method-name": "listAll", "x-mcp": { "readOnly": true, "destructive": false, "openWorld": false, "expose": false }, "parameters": [ { "name": "sent_after", "in": "query", "description": "Returns messages sent on or after this timestamp, in `YYYY-MM-DDTHH:MM:SS` format.", "style": "form", "explode": true, "schema": { "type": "string", "example": "2023-04-10T00:00:00" } }, { "name": "sent_before", "in": "query", "description": "Returns messages sent on or before this timestamp, in `YYYY-MM-DDTHH:MM:SS` format.", "style": "form", "explode": true, "schema": { "type": "string", "example": "2023-04-13T23:59:59" } }, { "name": "type", "in": "query", "description": "Filters messages by direction. One of `inbound` (messages received by the account) or `outbound` (messages sent by the account).", "required": true, "style": "form", "explode": true, "schema": { "type": "string", "example": "outbound" } }, { "name": "from", "in": "query", "description": "Filters by message sender. For `outbound` messages, the Sender ID used to send the message; for `inbound` messages, the originating phone number.", "style": "form", "explode": true, "schema": { "type": "string", "example": "15072429497" } }, { "name": "to", "in": "query", "description": "Filters by message recipient. For `outbound` messages, the destination phone number; for `inbound` messages, the SMS-enabled number that received the message.", "style": "form", "explode": true, "schema": { "type": "string", "example": "16419252149" } }, { "name": "status", "in": "query", "description": "Filters messages by delivery status. Accepts a `MessageDeliveryStatus` value.", "style": "form", "explode": true, "schema": { "$ref": "#/components/schemas/MessageDeliveryStatus" } }, { "name": "tag", "in": "query", "description": "Filters messages by `tag`. Supported for outbound messages only.", "style": "form", "explode": true, "schema": { "type": "string", "example": "campaignX" } }, { "name": "message_type", "in": "query", "description": "Filters messages by type. One of `sms` (text message) or `mms` (multimedia message).", "style": "form", "explode": true, "schema": { "type": "string", "enum": [ "sms", "mms" ], "example": "sms" } } ], "responses": { "200": { "description": "Returns an NDJSON stream of messages, one per line.", "headers": { "Content-Type": { "description": "Media type of the response body. Always `application/x-ndjson`.", "schema": { "type": "string", "example": "application/x-ndjson" } }, "Last-Modified": { "description": "Timestamp when the exported data was last modified.", "schema": { "type": "string", "example": "0" } }, "ETag": { "description": "Entity tag identifying the version of the exported data.", "schema": { "type": "string", "example": "0" } } }, "content": { "application/x-ndjson": { "schema": { "type": "string", "description": "Newline-delimited JSON stream of messages.", "example": "{\"message_id\":\"3a525ca2-6909-4c72-9399-905adf7f3a74\",\"message_type\":\"sms\",\"from\":\"15072429497\",\"to\":\"16419252149\",\"direction\":\"outbound\",\"status\":\"delivered\"}\n{\"message_id\":\"4b636ca3-7900-5d83-a400-016bf8f8f4b85\",\"message_type\":\"sms\",\"from\":\"15072429497\",\"to\":\"16419252150\",\"direction\":\"outbound\",\"status\":\"delivered\"}\n" } } } }, "401": { "$ref": "#/components/responses/UnauthorizedErrorResponse" }, "403": { "$ref": "#/components/responses/ForbiddenErrorResponse" } }, "deprecated": false } }, "/v3/10dlc/brands": { "get": { "tags": [ "10DLC" ], "summary": "List 10DLC Brands", "description": "Returns a paginated list of 10DLC Brands for the authenticated account, filtered by date, name, legal name, and status.", "operationId": "ten_dlc_brands_list", "security": [ { "bearerAuth": [ "campaigns:read" ] } ], "x-fern-sdk-group-name": [ "tenDlc", "brands" ], "x-fern-sdk-method-name": "list", "x-mcp": { "readOnly": true, "destructive": false, "openWorld": false, "expose": true }, "parameters": [ { "name": "dba_name", "in": "query", "description": "Filters Brands by `dba_name` (doing-business-as name). Matches partial values.", "style": "form", "explode": true, "schema": { "type": "string", "example": "Brand" } }, { "name": "company_name", "in": "query", "description": "Filters Brands by `company_name` (registered legal name). Matches partial values.", "style": "form", "explode": true, "schema": { "type": "string", "example": "Company" } }, { "name": "entity_type", "in": "query", "description": "Filters Brands by business entity type, such as `PRIVATE_PROFIT`.", "style": "form", "explode": true, "schema": { "type": "string", "example": "PRIVATE_PROFIT" } }, { "name": "status", "in": "query", "description": "Filters Brands by identity verification status, such as `VERIFIED`.", "style": "form", "explode": true, "schema": { "type": "string", "example": "VERIFIED" } }, { "name": "country", "in": "query", "description": "Filters Brands by registration country, as an ISO 3166-1 alpha-2 code (e.g., `US`).", "style": "form", "explode": true, "schema": { "type": "string", "example": "US" } }, { "name": "show_deleted", "in": "query", "description": "When `true`, includes deleted Brands in the results. Default `false`.", "style": "form", "explode": true, "schema": { "type": "boolean", "default": false, "example": false } }, { "name": "ein_taxid", "in": "query", "description": "Filters Brands by their Employer Identification Number (EIN) or tax ID.", "style": "form", "explode": true, "schema": { "type": "string", "example": "999999999" } }, { "name": "mock", "in": "query", "description": "When `true`, returns only mock Brands used for testing. Default `false`.", "style": "form", "explode": true, "schema": { "type": "boolean", "default": false, "example": false } }, { "name": "created_before", "in": "query", "description": "Returns brands created on or before this date, in `YYYY-MM-DD` format.", "style": "form", "explode": true, "schema": { "type": "string", "example": "2024-08-22" } }, { "name": "created_after", "in": "query", "description": "Returns brands created on or after this date, in `YYYY-MM-DD` format.", "style": "form", "explode": true, "schema": { "type": "string", "example": "2024-08-22" } }, { "name": "page", "in": "query", "description": "Page number to retrieve. Default `1`.", "style": "form", "explode": true, "schema": { "type": "integer", "format": "int32", "example": 1 } }, { "name": "per_page", "in": "query", "description": "Number of records to return per page. Default `25`.", "style": "form", "explode": true, "schema": { "type": "integer", "format": "int32", "example": 25 } } ], "responses": { "200": { "description": "Returns a paginated list of 10DLC Brands.", "headers": {}, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/TenDLCBrandListResponse" }, "examples": { "default": { "value": { "items": [ { "brand_id": "BM20QP9", "city": "Miami", "company_name": "Company legal name", "country": "US", "created_at": "2024-07-24T08:10:49", "dba_name": "New Brand", "ein_taxid": "999999999", "ein_taxid_country": "US", "email": "support@brand.com", "entity_type": "PRIVATE_PROFIT", "feedback": null, "first_name": "John", "last_name": "Dow", "mock": false, "phone_number": "12123450099", "state_or_province": "FL", "status": "VERIFIED", "stock_exchange": null, "stock_symbol": null, "street_address": "10, Street Name", "updated_at": "2024-07-24T08:29:09", "vertical": "HEALTHCARE", "website": "https://brand.com", "zip": "12345" } ], "pagination": { "current_page": 1, "per_page": 25, "total": 1, "total_pages": 1 } } } } } } }, "400": { "$ref": "#/components/responses/BadRequestErrorResponse" }, "401": { "$ref": "#/components/responses/UnauthorizedErrorResponse" }, "403": { "description": "Returns when the 10DLC feature is disabled for the account.", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/AccountErrorResponse" }, "examples": { "success": { "summary": "Successful response", "value": { "success": false, "message": "Request failed. The feature is disabled for the account." } } } } } } }, "deprecated": false }, "post": { "tags": [ "10DLC" ], "summary": "Register a 10DLC Brand", "description": "Registers a 10DLC Brand. Submits the company's legal identity data (EIN/Tax ID, legal company name, contact and address) to The Campaign Registry (TCR), which verifies the brand identity. Charges a 10DLC brand registration fee on successful submission; fails with an insufficient-funds error when the balance cannot cover it. Only brands with `VERIFIED` or `VETTED_VERIFIED` identity status can register 10DLC Campaigns.", "operationId": "ten_dlc_brands_create", "security": [ { "bearerAuth": [ "campaigns:write" ] } ], "x-fern-sdk-group-name": [ "tenDlc", "brands" ], "x-fern-sdk-method-name": "create", "x-mcp": { "readOnly": false, "destructive": true, "openWorld": true, "expose": true }, "parameters": [], "requestBody": { "description": "Attributes for the new 10DLC Brand.", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/TenDLCBrandCreateRequest" } } }, "required": true }, "responses": { "201": { "description": "Returns the registered 10DLC Brand.", "headers": {}, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/TenDLCBrand" }, "examples": { "default": { "value": { "brand_id": "BM20QP9", "city": "Miami", "company_name": "Company legal name", "country": "US", "created_at": "2024-07-24T08:10:49", "dba_name": "New Brand", "ein_taxid": "99999999", "ein_taxid_country": "US", "email": "support@brand.com", "entity_type": "PRIVATE_PROFIT", "feedback": null, "first_name": "John", "last_name": "Dow", "mock": false, "phone_number": "12123450099", "state_or_province": "FL", "status": "REVIEW", "stock_exchange": null, "stock_symbol": null, "street_address": "10, Street Name", "updated_at": "2024-07-24T08:10:49", "vertical": "HEALTHCARE", "website": "https://brand.com", "zip": "12345" } } } } } }, "400": { "$ref": "#/components/responses/BadRequestErrorResponse" }, "401": { "$ref": "#/components/responses/UnauthorizedErrorResponse" }, "403": { "description": "Returns when the 10DLC feature is disabled for the account.", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/AccountErrorResponse" }, "examples": { "success": { "summary": "Successful response", "value": { "success": false, "message": "Request failed. The feature is disabled for the account." } } } } } }, "404": { "$ref": "#/components/responses/NotFoundErrorResponse" }, "422": { "$ref": "#/components/responses/ValidationErrorResponse" } }, "deprecated": false } }, "/v3/10dlc/brands/{brand_id}": { "get": { "tags": [ "10DLC" ], "summary": "Retrieve a 10DLC Brand", "description": "Returns the 10DLC Brand identified by `brand_id`.", "operationId": "ten_dlc_brands_get", "security": [ { "bearerAuth": [ "campaigns:read" ] } ], "x-fern-sdk-group-name": [ "tenDlc", "brands" ], "x-fern-sdk-method-name": "get", "x-mcp": { "readOnly": true, "destructive": false, "openWorld": false, "expose": true }, "parameters": [ { "name": "brand_id", "in": "path", "description": "The unique ID of the 10DLC Brand.", "required": true, "style": "simple", "schema": { "type": "string", "pattern": "^B[A-Z0-9]{6}$", "example": "BM20QP9" } } ], "responses": { "200": { "description": "Returns the 10DLC Brand.", "headers": {}, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/TenDLCBrand" }, "examples": { "success": { "summary": "Successful response", "value": { "brand_id": "BM20QP9", "city": "Miami", "company_name": "Company legal name", "country": "US", "created_at": "2024-07-24T08:10:49", "dba_name": "New Brand", "ein_taxid": "99999999", "ein_taxid_country": "US", "email": "support@brand.com", "entity_type": "PRIVATE_PROFIT", "feedback": null, "first_name": "John", "last_name": "Dow", "mock": false, "phone_number": "12123450099", "state_or_province": "FL", "status": "VERIFIED", "stock_exchange": null, "stock_symbol": null, "street_address": "10, Street Name", "updated_at": "2024-07-24T08:29:09", "vertical": "HEALTHCARE", "website": "https://brand.com", "zip": "12345" } } } } } }, "400": { "$ref": "#/components/responses/BadRequestErrorResponse" }, "401": { "$ref": "#/components/responses/UnauthorizedErrorResponse" }, "403": { "description": "Returns when the 10DLC feature is disabled for the account.", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/AccountErrorResponse" }, "examples": { "success": { "summary": "Successful response", "value": { "success": false, "message": "Request failed. The feature is disabled for the account." } } } } } }, "404": { "description": "Returns when the requested 10DLC resource does not exist.", "headers": {}, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/RecordNotFoundErrorResponse" }, "examples": { "success": { "summary": "Successful response", "value": { "success": false, "message": "Request failed. The Brand is not found." } } } } } } }, "deprecated": false }, "put": { "tags": [ "10DLC" ], "summary": "Update a 10DLC Brand", "description": "Updates the 10DLC Brand identified by `brand_id`. Changing identity fields, including `ein_taxid`, `ein_taxid_country`, and `entity_type`, resets the Brand status to `UNVERIFIED` and triggers automatic re-submission. Brands in `VETTED_VERIFIED` status or with active Campaigns cannot be updated.", "operationId": "ten_dlc_brands_update", "security": [ { "bearerAuth": [ "campaigns:write" ] } ], "x-fern-sdk-group-name": [ "tenDlc", "brands" ], "x-fern-sdk-method-name": "update", "x-mcp": { "readOnly": false, "destructive": false, "openWorld": true, "expose": true }, "parameters": [ { "name": "brand_id", "in": "path", "description": "The unique ID of the 10DLC Brand.", "required": true, "style": "simple", "schema": { "type": "string", "pattern": "^B[A-Z0-9]{6}$", "example": "BM20QP9" } } ], "requestBody": { "description": "Fields to update on the 10DLC Brand. Only included fields are changed.", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/TenDLCBrandUpdateRequest" } } }, "required": true }, "responses": { "200": { "description": "Returns the updated 10DLC Brand.", "headers": {}, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/TenDLCBrand" }, "examples": { "default": { "value": { "brand_id": "BM20QP9", "city": "Miami", "company_name": "Company legal name", "country": "US", "created_at": "2024-07-24T08:10:49", "dba_name": "New Brand", "ein_taxid": "99999999", "ein_taxid_country": "US", "email": "support@brand.com", "entity_type": "PRIVATE_PROFIT", "feedback": null, "first_name": "John", "last_name": "Dow", "mock": false, "phone_number": "12123450099", "state_or_province": "FL", "status": "REVIEW", "stock_exchange": null, "stock_symbol": null, "street_address": "10, Street Name", "updated_at": "2024-07-24T09:02:19", "vertical": "HEALTHCARE", "website": "https://brand.com", "zip": "12345" } } } } } }, "400": { "$ref": "#/components/responses/BadRequestErrorResponse" }, "401": { "$ref": "#/components/responses/UnauthorizedErrorResponse" }, "403": { "description": "Returns when the 10DLC feature is disabled for the account.", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/AccountErrorResponse" }, "examples": { "success": { "summary": "Successful response", "value": { "success": false, "message": "Request failed. The feature is disabled for the account." } } } } } }, "404": { "description": "Returns when the requested 10DLC resource does not exist.", "headers": {}, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/RecordNotFoundErrorResponse" }, "examples": { "success": { "summary": "Successful response", "value": { "success": false, "message": "Request failed. The Brand is not found." } } } } } }, "422": { "description": "Returns when a field value is invalid, or when the Brand has active Campaigns or external vetting and its identity fields cannot be updated.", "headers": {}, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/RecordNotFoundErrorResponse" }, "examples": { "invalid_field": { "summary": "Invalid field value", "value": { "success": false, "message": "Invalid ein_taxid - ein_taxid is a nine-digit number. The format is XX-XXXXXXX. The \\\"-\\\" symbol is also accepted." } }, "cannot_be_updated": { "summary": "Brand identity fields locked", "value": { "success": false, "message": "The 'company_name', 'ein_taxid', 'ein_taxid_country', or 'entity_type' attributes cannot be updated. The Brand has active Campaigns or external vetting." } } } } } } }, "deprecated": false }, "delete": { "tags": [ "10DLC" ], "summary": "Delete a 10DLC Brand", "description": "Deletes a 10DLC Brand. Brands with active campaigns cannot be deleted.", "operationId": "ten_dlc_brands_delete", "security": [ { "bearerAuth": [ "campaigns:write" ] } ], "x-fern-sdk-group-name": [ "tenDlc", "brands" ], "x-fern-sdk-method-name": "delete", "x-mcp": { "readOnly": false, "destructive": true, "openWorld": false, "expose": true }, "parameters": [ { "name": "brand_id", "in": "path", "description": "The unique ID of the 10DLC Brand.", "required": true, "style": "simple", "schema": { "type": "string", "pattern": "^B[A-Z0-9]{6}$", "example": "BM20QP9" } } ], "responses": { "200": { "description": "Returns a success confirmation. The 10DLC Brand is deleted.", "headers": {}, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/SuccessResponse" }, "examples": { "default": { "value": { "success": true } } } } } }, "400": { "description": "Returns when the Brand has active Campaigns and cannot be deleted.", "headers": {}, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/AccountErrorResponse" }, "examples": { "active_campaigns": { "summary": "Brand has active Campaigns", "value": { "success": false, "message": "Brand with active Campaigns cannot be deleted" } } } } } }, "401": { "$ref": "#/components/responses/UnauthorizedErrorResponse" }, "403": { "description": "Returns when the 10DLC feature is disabled for the account.", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/AccountErrorResponse" }, "examples": { "success": { "summary": "Successful response", "value": { "success": false, "message": "Request failed. The feature is disabled for the account." } } } } } }, "404": { "description": "Returns when the requested 10DLC resource does not exist.", "headers": {}, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/RecordNotFoundErrorResponse" }, "examples": { "success": { "summary": "Successful response", "value": { "success": false, "message": "Request failed. The Brand is not found." } } } } } } }, "deprecated": false } }, "/v3/10dlc/brands/{brand_id}/appeals": { "post": { "tags": [ "10DLC" ], "summary": "Appeal a 10DLC Brand identity verification", "description": "Submits an appeal for 10DLC brand identity verification. Provide any additional documentation to support the appeal. Use `appeal_category` to specify the appeal type:\n- `VERIFY_TAX_ID` — Use if the brand is UNVERIFIED due to a tax ID mismatch. Applies to private companies, public companies, non-profits, and government entities.\n- `VERIFY_NON_PROFIT` — Use if a non-profit brand is UNVERIFIED or VERIFIED but missing tax-exempt status.\n- `VERIFY_GOVERNMENT` — Use if a government brand is UNVERIFIED or VERIFIED but missing government entity status.", "operationId": "ten_dlc_brand_appeals_create", "security": [ { "bearerAuth": [ "campaigns:write" ] } ], "x-fern-sdk-group-name": [ "tenDlc", "brandAppeals" ], "x-fern-sdk-method-name": "create", "x-mcp": { "readOnly": false, "destructive": false, "openWorld": true, "expose": true }, "parameters": [ { "name": "brand_id", "in": "path", "description": "The unique ID of the 10DLC Brand.", "required": true, "style": "simple", "schema": { "type": "string", "pattern": "^B[A-Z0-9]{6}$", "example": "BM20QP9" } } ], "requestBody": { "description": "Appeal category and supporting documentation.", "content": { "application/json": { "schema": { "allOf": [ { "$ref": "#/components/schemas/TenDLCBrandAppealCreateRequest" }, { "description": "The appeal request" } ], "type": "object" } } }, "required": true }, "responses": { "200": { "description": "Returns the submitted appeal.", "headers": {}, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/SuccessResponse" }, "examples": { "default": { "value": { "success": true } } } } } }, "400": { "description": "Returns a validation error when a field value is invalid.", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/AccountErrorResponse" }, "examples": { "success": { "summary": "Successful response", "value": { "success": false, "message": "Request failed. The feature is disabled for the account." } } } } } }, "401": { "$ref": "#/components/responses/UnauthorizedErrorResponse" }, "403": { "description": "Returns when the 10DLC feature is disabled for the account.", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/AccountErrorResponse" }, "examples": { "success": { "summary": "Successful response", "value": { "success": false, "message": "Request failed. The feature is disabled for the account." } } } } } }, "404": { "description": "Returns when the requested 10DLC resource does not exist.", "headers": {}, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/RecordNotFoundErrorResponse" }, "examples": { "success": { "summary": "Successful response", "value": { "success": false, "message": "Request failed. The Brand is not found." } } } } } }, "422": { "$ref": "#/components/responses/ValidationErrorResponse" } }, "deprecated": false }, "get": { "tags": [ "10DLC" ], "summary": "List Brand identity appeals", "description": "Returns the identity verification appeals submitted for the 10DLC Brand identified by `brand_id`.", "operationId": "ten_dlc_brand_appeals_list", "security": [ { "bearerAuth": [ "campaigns:read" ] } ], "x-fern-sdk-group-name": [ "tenDlc", "brandAppeals" ], "x-fern-sdk-method-name": "list", "x-mcp": { "readOnly": true, "destructive": false, "openWorld": false, "expose": true }, "parameters": [ { "name": "brand_id", "in": "path", "description": "The unique ID of the 10DLC Brand.", "required": true, "style": "simple", "schema": { "type": "string", "pattern": "^B[A-Z0-9]{6}$", "example": "BM20QP9" } } ], "responses": { "200": { "description": "Returns the list of identity verification appeals.", "headers": {}, "content": { "application/json": { "schema": { "type": "array", "items": { "$ref": "#/components/schemas/TenDLCBrandAppeal" }, "example": [ { "categories": [ "VERIFY_TAX_ID" ], "created_at": "2024-08-01T14:09:43", "evidence": [], "explanation": "Dear partner, please review the registration docs", "outcome": { "optional_attributes": {}, "feedback": { "category": [] }, "vetting_status": "VERIFIED" }, "status": "COMPLETE", "updated_at": "2024-08-01T18:33:15" } ] }, "examples": { "default": { "value": [ { "categories": [ "VERIFY_TAX_ID" ], "created_at": "2024-08-01T14:09:43", "evidence": [], "explanation": "Dear partner, please review the registration docs", "outcome": { "optional_attributes": {}, "feedback": { "category": [] }, "vetting_status": "VERIFIED" }, "status": "COMPLETE", "updated_at": "2024-08-01T18:33:15" } ] } } } } }, "400": { "description": "Returns a validation error when a field value is invalid.", "headers": {}, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/RecordNotFoundErrorResponse" }, "examples": { "success": { "summary": "Successful response", "value": { "success": false, "message": "Invalid Request" } } } } } }, "401": { "$ref": "#/components/responses/UnauthorizedErrorResponse" }, "403": { "description": "Returns when the 10DLC feature is disabled for the account.", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/AccountErrorResponse" }, "examples": { "success": { "summary": "Successful response", "value": { "success": false, "message": "Request failed. The feature is disabled for the account." } } } } } }, "404": { "description": "Returns when the requested 10DLC resource does not exist.", "headers": {}, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/RecordNotFoundErrorResponse" }, "examples": { "success": { "summary": "Successful response", "value": { "success": false, "message": "Request failed. The Brand is not found." } } } } } } }, "deprecated": false } }, "/v3/10dlc/brands/{brand_id}/evidence": { "post": { "tags": [ "10DLC" ], "summary": "Upload Brand evidence", "description": "Uploads a supporting evidence file for the 10DLC Brand identified by `brand_id`. Supported formats include `.jpg`, `.png`, and `.pdf`. Maximum size is 10 MB.", "operationId": "ten_dlc_brand_evidence_upload", "security": [ { "bearerAuth": [ "campaigns:write" ] } ], "x-fern-sdk-group-name": [ "tenDlc", "brandEvidence" ], "x-fern-sdk-method-name": "upload", "x-mcp": { "readOnly": false, "destructive": false, "openWorld": false, "expose": false }, "parameters": [ { "name": "brand_id", "in": "path", "description": "The unique ID of the 10DLC Brand.", "required": true, "style": "simple", "schema": { "type": "string", "pattern": "^B[A-Z0-9]{6}$", "example": "B6AI7PA" } } ], "requestBody": { "content": { "multipart/form-data": { "encoding": {}, "schema": { "required": [ "file" ], "type": "object", "additionalProperties": false, "properties": { "file": { "type": "string", "description": "Evidence file to upload. Maximum size is 10 MB.", "format": "binary" } } } } }, "required": false }, "responses": { "201": { "description": "Returns the uploaded evidence file.", "headers": {}, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/TenDLCBrandEvidence" }, "examples": { "default": { "value": { "file_name": "image.png", "mime_type": "image/png", "url": "https://api.wavix.com/v3/10dlc/brands/B6AI7PA/evidence/191eb205-8357-4d71-b8da-160a25a000d7", "uuid": "191eb205-8357-4d71-b8da-160a25a000d7" } } } } } }, "401": { "$ref": "#/components/responses/UnauthorizedErrorResponse" }, "403": { "description": "Returns when the 10DLC feature is disabled for the account.", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/AccountErrorResponse" }, "examples": { "success": { "summary": "Successful response", "value": { "success": false, "message": "Request failed. The feature is disabled for the account." } } } } } }, "404": { "description": "Returns when no 10DLC Brand matches `brand_id`.", "headers": {}, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/RecordNotFoundErrorResponse" }, "examples": { "success": { "summary": "Successful response", "value": { "success": false, "message": "Request failed. The Brand is not found." } } } } } }, "422": { "description": "Returns when no file is provided in the request.", "headers": {}, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/RecordNotFoundErrorResponse" }, "examples": { "success": { "summary": "Successful response", "value": { "success": false, "message": "File missing" } } } } } } }, "deprecated": false }, "get": { "tags": [ "10DLC" ], "summary": "List Brand evidence", "description": "Returns the evidence files uploaded for the 10DLC Brand identified by `brand_id`.", "operationId": "ten_dlc_brand_evidence_list", "security": [ { "bearerAuth": [ "campaigns:read" ] } ], "x-fern-sdk-group-name": [ "tenDlc", "brandEvidence" ], "x-fern-sdk-method-name": "list", "x-mcp": { "readOnly": true, "destructive": false, "openWorld": false, "expose": true }, "parameters": [ { "name": "brand_id", "in": "path", "description": "The unique ID of the 10DLC Brand.", "required": true, "style": "simple", "schema": { "type": "string", "pattern": "^B[A-Z0-9]{6}$", "example": "B6AI7PA" } } ], "responses": { "200": { "description": "Returns the list of uploaded evidence files.", "headers": {}, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ListBrandEvidenceResponse" }, "examples": { "success": { "summary": "Successful response", "value": { "items": [ { "file_name": "file.png", "mime_type": "image/png", "url": "https://api.wavix.com/v3/10dlc/brands/BRGQVL0/evidence/3d8d97b6-61f7-4f91-8c1c-7ef83828e072", "uuid": "3d8d97b6-61f7-4f91-8c1c-7ef83828e072" } ] } } } } } }, "400": { "$ref": "#/components/responses/BadRequestErrorResponse" }, "401": { "$ref": "#/components/responses/UnauthorizedErrorResponse" }, "403": { "description": "Returns when the 10DLC feature is disabled for the account.", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/AccountErrorResponse" }, "examples": { "success": { "summary": "Successful response", "value": { "success": false, "message": "Request failed. The feature is disabled for the account." } } } } } }, "404": { "description": "Returns when no 10DLC Brand matches `brand_id`.", "headers": {}, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/RecordNotFoundErrorResponse" }, "examples": { "success": { "summary": "Successful response", "value": { "success": false, "message": "Request failed. The Brand is not found." } } } } } } }, "deprecated": false } }, "/v3/10dlc/brands/{brand_id}/evidence/{id}": { "get": { "tags": [ "10DLC" ], "summary": "Download Brand evidence", "description": "Returns the Brand evidence file identified by the evidence ID.", "operationId": "ten_dlc_brand_evidence_get", "security": [ { "bearerAuth": [ "campaigns:read" ] } ], "x-fern-sdk-group-name": [ "tenDlc", "brandEvidence" ], "x-fern-sdk-method-name": "get", "x-mcp": { "readOnly": true, "destructive": false, "openWorld": false, "expose": false }, "parameters": [ { "name": "brand_id", "in": "path", "description": "The unique ID of the 10DLC Brand.", "required": true, "style": "simple", "schema": { "type": "string", "pattern": "^B[A-Z0-9]{6}$", "example": "B6AI7PA" } }, { "name": "id", "in": "path", "description": "The unique ID of the Brand evidence file.", "required": true, "style": "simple", "schema": { "type": "string", "example": "191eb205-8357-4d71-b8da-160a25a000d7" } } ], "responses": { "200": { "description": "Returns the Brand evidence file.", "headers": {}, "content": { "application/octet-stream": { "schema": { "type": "string", "format": "binary" } } } }, "400": { "$ref": "#/components/responses/BadRequestErrorResponse" }, "401": { "$ref": "#/components/responses/UnauthorizedErrorResponse" }, "403": { "description": "Returns when the 10DLC feature is disabled for the account.", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/AccountErrorResponse" }, "examples": { "success": { "summary": "Successful response", "value": { "success": false, "message": "Request failed. The feature is disabled for the account." } } } } } }, "404": { "description": "Returns when the requested 10DLC resource does not exist.", "headers": {}, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/RecordNotFoundErrorResponse" }, "examples": { "success": { "summary": "Successful response", "value": { "success": false, "message": "Request failed. The Brand is not found." } } } } } } }, "deprecated": false }, "delete": { "tags": [ "10DLC" ], "summary": "Delete Brand evidence", "description": "Deletes the Brand evidence file identified by the evidence ID. Deletion is permanent.", "operationId": "ten_dlc_brand_evidence_delete", "security": [ { "bearerAuth": [ "campaigns:write" ] } ], "x-fern-sdk-group-name": [ "tenDlc", "brandEvidence" ], "x-fern-sdk-method-name": "delete", "x-mcp": { "readOnly": false, "destructive": true, "openWorld": false, "expose": true }, "parameters": [ { "name": "brand_id", "in": "path", "description": "The unique ID of the 10DLC Brand.", "required": true, "style": "simple", "schema": { "type": "string", "pattern": "^B[A-Z0-9]{6}$", "example": "B6AI7PA" } }, { "name": "id", "in": "path", "description": "The unique ID of the Brand evidence file.", "required": true, "style": "simple", "schema": { "type": "string", "example": "191eb205-8357-4d71-b8da-160a25a000d7" } } ], "responses": { "200": { "description": "Returns a success confirmation. The evidence file is deleted.", "headers": {}, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/SuccessResponse" }, "examples": { "default": { "value": { "success": true } } } } } }, "400": { "$ref": "#/components/responses/BadRequestErrorResponse" }, "401": { "$ref": "#/components/responses/UnauthorizedErrorResponse" }, "403": { "description": "Returns when the 10DLC feature is disabled for the account.", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/AccountErrorResponse" }, "examples": { "success": { "summary": "Successful response", "value": { "success": false, "message": "Request failed. The feature is disabled for the account." } } } } } }, "404": { "description": "Returns when the requested 10DLC resource does not exist.", "headers": {}, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/RecordNotFoundErrorResponse" }, "examples": { "success": { "summary": "Successful response", "value": { "success": false, "message": "Request failed. The Brand is not found." } } } } } } }, "deprecated": false } }, "/v3/10dlc/brands/{brand_id}/vettings": { "post": { "tags": [ "10DLC" ], "summary": "Request external vetting", "description": "Requests external vetting for a 10DLC Brand. Supported providers: `AEGIS`, `CV`, `WMC`. Supported classes: `STANDARD`, `ENHANCED`. Charges a 10DLC brand vetting fee (Standard or Enhanced); fails with an insufficient-funds error when the balance cannot cover it.", "operationId": "ten_dlc_brand_vettings_create", "security": [ { "bearerAuth": [ "campaigns:write" ] } ], "x-fern-sdk-group-name": [ "tenDlc", "brandVettings" ], "x-fern-sdk-method-name": "create", "x-mcp": { "readOnly": false, "destructive": true, "openWorld": true, "expose": true }, "parameters": [ { "name": "brand_id", "in": "path", "description": "The unique ID of the 10DLC Brand.", "required": true, "style": "simple", "schema": { "type": "string", "pattern": "^B[A-Z0-9]{6}$", "example": "B6AI7PA" } } ], "requestBody": { "description": "Provider and class for the external vetting.", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/TenDLCBrandVettingCreateRequest" } } }, "required": true }, "responses": { "200": { "description": "Returns the requested external vetting.", "headers": {}, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/TenDLCBrandVetting" }, "examples": { "success": { "summary": "Successful response", "value": { "evp_id": "AEGIS", "create_date": "2024-08-01T14:09:43", "vetting_details": { "additional_prop1": {}, "additional_prop2": {}, "additional_prop3": {} }, "vetted_date": "2024-08-01T14:09:43", "vetting_id": "13d8e00c-3cb4-4dc0-9e26-d5057fa938d9", "vetting_token": "3oDcE1vq8OR43claMa6Thu/7V4vzZywAfKRgiJnXDjlw+08wpWbGqOssAXKgeZibHCLaGgXvU/yPb7kISeeb5qGdisGRLdhPnSNpvRR82RnCWYNpTp92orlJWjTJU8ZGmNxL5MwK0tt/9SxCha36iTtPV2+4vND8xCPe5suItuQTonG4A3Yi6F1LMqihgwdesRjxJnKqcE7Thcv9ug1NyNPYEZQvPugFj2F2DdU6jFZcOWgXsnE7ucZ+xNaNX9LkF9if3v0hrcviG9L8bUUrpPBGr02txP0i+cPBTLbj4Rq1Ox83R+WUx1gnoXHCIU1ByDGWvQq2Ef4qxGVOwPJHJbja1BovxKBk4YJxiz8OSO68QAIEfxuPTpj5eZz7KEFtFmBIVaVmxBDe4b8Tpl01C2rek7xgPzXaoURvh7CQVnVmJL00DTWKvyOmUOQQW901XEcgcJ7VWgfIvxhIMuXEXXtVDGNowmEc9JQXXYHVlGuN5QicSbApkwwqRZI7TQ4lsS66zCfqomIIJyBNRJpl+8sGwsa2J2h6fEkAD77J9zdUgIKXMFamHbvRadCKMZNIbMrkOC7PuOjZdSiWKh5A8FSjzkv3PlN2hRDqkaODEoodp5pTQeBtNe37+uAMOuHNfsZXlwvfMgCZjiZJ9HQNSLhJBUq7/IvT/EzszUk4HPTj/WFSbT1YrrkDi+zrB20ZDY9lZFWxN1hlYQoNcanDAAWPmw/yW1+8DroL5WIMGsXX3WFGOG7eWB1GHgFQsziAeRQl78u1qOvsRMN08+GrkASBJwqwy5l7xCesUKqbz3O0QA/dwzzsWIDvFPavZpjqMBSjRTurQLFahAaGmdY0BX/Ii+s2+OxfaHQIa1lgucm0P7GPKeZvLX/8boO01Onr/87ra+NX7ABvQb+SXvwsg+Bm5CziWB6DMKDKRD/KQjHxpjIY35UwSEW7G4ixux7ufizXttthHfPJWd/rWFhfYigFhVLgIPCR12smwFVuZwM7ujvY2CIM0X4E0dsX9uVHkgYmqRIdNf5vshpmRuIcHsXZpTJP/tD7zQM6m214c5xkJSfAVIaD7WzRYS4eVL+R3z4u+6n5p6FjuWSjSzuEffUai3HCWjes4JbtDSjIwoG0tOMtBukgPbreH+pjXcvnhU+1QhCV2aIdG6C3FmaI5Uoo/mthJyiFAThwtOpxQ5YkdsRunqVVEFYZfMNEn4Ig2clCFrLOm46JB2wPcLGP2MoH5RqajYzQ6IV8IXIFQVzG0C7HoHsBkVp+GrpnH6N0FCKR+fpbGjigM2lLf4pYBhChUY4ao9hvV1hd8ikS6QoasvDLPytBBa1YAwbSa8d7YdwO6fXfQqetfS8S9gbHD0zxazw5p9Lp5fXFmajDNkD2voYNMzOHJMMHG/49pWV2", "vetting_score": 80, "vetting_class": "STANDARD", "vetting_status": "PENDING", "reasons": [ "Company size as reported by government or business sources resulted in a score deduction: size range 6-10" ] } } } } } }, "400": { "$ref": "#/components/responses/BadRequestErrorResponse" }, "401": { "$ref": "#/components/responses/UnauthorizedErrorResponse" }, "403": { "description": "Returns when the 10DLC feature is disabled for the account.", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/AccountErrorResponse" }, "examples": { "success": { "summary": "Successful response", "value": { "success": false, "message": "Request failed. The feature is disabled for the account." } } } } } }, "404": { "description": "Returns when the requested 10DLC resource does not exist.", "headers": {}, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/RecordNotFoundErrorResponse" }, "examples": { "success": { "summary": "Successful response", "value": { "success": false, "message": "Request failed. The Brand is not found." } } } } } }, "422": { "$ref": "#/components/responses/ValidationErrorResponse" } }, "deprecated": false }, "put": { "tags": [ "10DLC" ], "summary": "Import external vetting", "description": "Imports an existing external vetting record into the 10DLC Brand identified by `brand_id`.", "operationId": "ten_dlc_brand_vettings_import", "security": [ { "bearerAuth": [ "campaigns:write" ] } ], "x-fern-sdk-group-name": [ "tenDlc", "brandVettings" ], "x-fern-sdk-method-name": "import", "x-mcp": { "readOnly": false, "destructive": false, "openWorld": false, "expose": true }, "parameters": [ { "name": "brand_id", "in": "path", "description": "The unique ID of the 10DLC Brand.", "required": true, "style": "simple", "schema": { "type": "string", "pattern": "^B[A-Z0-9]{6}$", "example": "B6AI7PA" } } ], "requestBody": { "description": "Details of the existing external vetting to import.", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/TenDLCBrandVettingImportRequest" } } }, "required": true }, "responses": { "200": { "description": "Returns the imported external vetting.", "headers": {}, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/TenDLCBrandVetting" }, "examples": { "success": { "summary": "Successful response", "value": { "evp_id": "AEGIS", "create_date": "2024-08-01T14:09:43", "vetting_details": { "additional_prop1": {}, "additional_prop2": {}, "additional_prop3": {} }, "vetted_date": "2024-08-01T14:09:43", "vetting_id": "13d8e00c-3cb4-4dc0-9e26-d5057fa938d9", "vetting_token": "3oDcE1vq8OR43claMa6Thu/7V4vzZywAfKRgiJnXDjlw+08wpWbGqOssAXKgeZibHCLaGgXvU/yPb7kISeeb5qGdisGRLdhPnSNpvRR82RnCWYNpTp92orlJWjTJU8ZGmNxL5MwK0tt/9SxCha36iTtPV2+4vND8xCPe5suItuQTonG4A3Yi6F1LMqihgwdesRjxJnKqcE7Thcv9ug1NyNPYEZQvPugFj2F2DdU6jFZcOWgXsnE7ucZ+xNaNX9LkF9if3v0hrcviG9L8bUUrpPBGr02txP0i+cPBTLbj4Rq1Ox83R+WUx1gnoXHCIU1ByDGWvQq2Ef4qxGVOwPJHJbja1BovxKBk4YJxiz8OSO68QAIEfxuPTpj5eZz7KEFtFmBIVaVmxBDe4b8Tpl01C2rek7xgPzXaoURvh7CQVnVmJL00DTWKvyOmUOQQW901XEcgcJ7VWgfIvxhIMuXEXXtVDGNowmEc9JQXXYHVlGuN5QicSbApkwwqRZI7TQ4lsS66zCfqomIIJyBNRJpl+8sGwsa2J2h6fEkAD77J9zdUgIKXMFamHbvRadCKMZNIbMrkOC7PuOjZdSiWKh5A8FSjzkv3PlN2hRDqkaODEoodp5pTQeBtNe37+uAMOuHNfsZXlwvfMgCZjiZJ9HQNSLhJBUq7/IvT/EzszUk4HPTj/WFSbT1YrrkDi+zrB20ZDY9lZFWxN1hlYQoNcanDAAWPmw/yW1+8DroL5WIMGsXX3WFGOG7eWB1GHgFQsziAeRQl78u1qOvsRMN08+GrkASBJwqwy5l7xCesUKqbz3O0QA/dwzzsWIDvFPavZpjqMBSjRTurQLFahAaGmdY0BX/Ii+s2+OxfaHQIa1lgucm0P7GPKeZvLX/8boO01Onr/87ra+NX7ABvQb+SXvwsg+Bm5CziWB6DMKDKRD/KQjHxpjIY35UwSEW7G4ixux7ufizXttthHfPJWd/rWFhfYigFhVLgIPCR12smwFVuZwM7ujvY2CIM0X4E0dsX9uVHkgYmqRIdNf5vshpmRuIcHsXZpTJP/tD7zQM6m214c5xkJSfAVIaD7WzRYS4eVL+R3z4u+6n5p6FjuWSjSzuEffUai3HCWjes4JbtDSjIwoG0tOMtBukgPbreH+pjXcvnhU+1QhCV2aIdG6C3FmaI5Uoo/mthJyiFAThwtOpxQ5YkdsRunqVVEFYZfMNEn4Ig2clCFrLOm46JB2wPcLGP2MoH5RqajYzQ6IV8IXIFQVzG0C7HoHsBkVp+GrpnH6N0FCKR+fpbGjigM2lLf4pYBhChUY4ao9hvV1hd8ikS6QoasvDLPytBBa1YAwbSa8d7YdwO6fXfQqetfS8S9gbHD0zxazw5p9Lp5fXFmajDNkD2voYNMzOHJMMHG/49pWV2", "vetting_score": 80, "vetting_class": "STANDARD", "vetting_status": "PENDING", "reasons": [ "Company size as reported by government or business sources resulted in a score deduction: size range 6-10" ] } } } } } }, "400": { "$ref": "#/components/responses/BadRequestErrorResponse" }, "401": { "$ref": "#/components/responses/UnauthorizedErrorResponse" }, "403": { "description": "Returns when the 10DLC feature is disabled for the account.", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/AccountErrorResponse" }, "examples": { "success": { "summary": "Successful response", "value": { "success": false, "message": "Request failed. The feature is disabled for the account." } } } } } }, "404": { "description": "Returns when the requested 10DLC resource does not exist.", "headers": {}, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/RecordNotFoundErrorResponse" }, "examples": { "success": { "summary": "Successful response", "value": { "success": false, "message": "Request failed. The Brand is not found." } } } } } }, "422": { "$ref": "#/components/responses/ValidationErrorResponse" } }, "deprecated": false }, "get": { "tags": [ "10DLC" ], "summary": "List external vettings", "description": "Returns the external vettings for the 10DLC Brand identified by `brand_id`.", "operationId": "ten_dlc_brand_vettings_list", "security": [ { "bearerAuth": [ "campaigns:read" ] } ], "x-fern-sdk-group-name": [ "tenDlc", "brandVettings" ], "x-fern-sdk-method-name": "list", "x-mcp": { "readOnly": true, "destructive": false, "openWorld": false, "expose": true }, "parameters": [ { "name": "brand_id", "in": "path", "description": "The unique ID of the 10DLC Brand.", "required": true, "style": "simple", "schema": { "type": "string", "pattern": "^B[A-Z0-9]{6}$", "example": "B6AI7PA" } } ], "responses": { "200": { "description": "Returns the list of external vettings.", "headers": {}, "content": { "application/json": { "schema": { "type": "array", "items": { "$ref": "#/components/schemas/TenDLCBrandVetting" } }, "examples": { "success": { "summary": "Successful response", "value": [ { "evp_id": "AEGIS", "create_date": "2024-08-01T14:09:43", "vetting_details": { "additional_prop1": {}, "additional_prop2": {}, "additional_prop3": {} }, "vetted_date": "2024-08-01T14:09:43", "vetting_id": "13d8e00c-3cb4-4dc0-9e26-d5057fa938d9", "vetting_token": "3oDcE1vq8OR43claMa6Thu/7V4vzZywAfKRgiJnXDjlw+08wpWbGqOssAXKgeZibHCLaGgXvU/yPb7kISeeb5qGdisGRLdhPnSNpvRR82RnCWYNpTp92orlJWjTJU8ZGmNxL5MwK0tt/9SxCha36iTtPV2+4vND8xCPe5suItuQTonG4A3Yi6F1LMqihgwdesRjxJnKqcE7Thcv9ug1NyNPYEZQvPugFj2F2DdU6jFZcOWgXsnE7ucZ+xNaNX9LkF9if3v0hrcviG9L8bUUrpPBGr02txP0i+cPBTLbj4Rq1Ox83R+WUx1gnoXHCIU1ByDGWvQq2Ef4qxGVOwPJHJbja1BovxKBk4YJxiz8OSO68QAIEfxuPTpj5eZz7KEFtFmBIVaVmxBDe4b8Tpl01C2rek7xgPzXaoURvh7CQVnVmJL00DTWKvyOmUOQQW901XEcgcJ7VWgfIvxhIMuXEXXtVDGNowmEc9JQXXYHVlGuN5QicSbApkwwqRZI7TQ4lsS66zCfqomIIJyBNRJpl+8sGwsa2J2h6fEkAD77J9zdUgIKXMFamHbvRadCKMZNIbMrkOC7PuOjZdSiWKh5A8FSjzkv3PlN2hRDqkaODEoodp5pTQeBtNe37+uAMOuHNfsZXlwvfMgCZjiZJ9HQNSLhJBUq7/IvT/EzszUk4HPTj/WFSbT1YrrkDi+zrB20ZDY9lZFWxN1hlYQoNcanDAAWPmw/yW1+8DroL5WIMGsXX3WFGOG7eWB1GHgFQsziAeRQl78u1qOvsRMN08+GrkASBJwqwy5l7xCesUKqbz3O0QA/dwzzsWIDvFPavZpjqMBSjRTurQLFahAaGmdY0BX/Ii+s2+OxfaHQIa1lgucm0P7GPKeZvLX/8boO01Onr/87ra+NX7ABvQb+SXvwsg+Bm5CziWB6DMKDKRD/KQjHxpjIY35UwSEW7G4ixux7ufizXttthHfPJWd/rWFhfYigFhVLgIPCR12smwFVuZwM7ujvY2CIM0X4E0dsX9uVHkgYmqRIdNf5vshpmRuIcHsXZpTJP/tD7zQM6m214c5xkJSfAVIaD7WzRYS4eVL+R3z4u+6n5p6FjuWSjSzuEffUai3HCWjes4JbtDSjIwoG0tOMtBukgPbreH+pjXcvnhU+1QhCV2aIdG6C3FmaI5Uoo/mthJyiFAThwtOpxQ5YkdsRunqVVEFYZfMNEn4Ig2clCFrLOm46JB2wPcLGP2MoH5RqajYzQ6IV8IXIFQVzG0C7HoHsBkVp+GrpnH6N0FCKR+fpbGjigM2lLf4pYBhChUY4ao9hvV1hd8ikS6QoasvDLPytBBa1YAwbSa8d7YdwO6fXfQqetfS8S9gbHD0zxazw5p9Lp5fXFmajDNkD2voYNMzOHJMMHG/49pWV2", "vetting_score": 80, "vetting_class": "STANDARD", "vetting_status": "PENDING", "reasons": [ "Company size as reported by government or business sources resulted in a score deduction: size range 6-10" ] } ] } } } } }, "400": { "$ref": "#/components/responses/BadRequestErrorResponse" }, "401": { "$ref": "#/components/responses/UnauthorizedErrorResponse" }, "403": { "description": "Returns when the 10DLC feature is disabled for the account.", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/AccountErrorResponse" }, "examples": { "success": { "summary": "Successful response", "value": { "success": false, "message": "Request failed. The feature is disabled for the account." } } } } } }, "404": { "description": "Returns when the requested 10DLC resource does not exist.", "headers": {}, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/RecordNotFoundErrorResponse" }, "examples": { "success": { "summary": "Successful response", "value": { "success": false, "message": "Request failed. The Brand is not found." } } } } } } }, "deprecated": false } }, "/v3/10dlc/brands/{brand_id}/vettings/appeals": { "post": { "tags": [ "10DLC" ], "summary": "Appeal external vetting", "description": "Submits an appeal for an external vetting of the 10DLC Brand identified by `brand_id`.", "operationId": "ten_dlc_brand_vetting_appeals_create", "security": [ { "bearerAuth": [ "campaigns:write" ] } ], "x-fern-sdk-group-name": [ "tenDlc", "brandVettingAppeals" ], "x-fern-sdk-method-name": "create", "x-mcp": { "readOnly": false, "destructive": false, "openWorld": true, "expose": true }, "parameters": [ { "name": "brand_id", "in": "path", "description": "The unique ID of the 10DLC Brand.", "required": true, "style": "simple", "schema": { "type": "string", "pattern": "^B[A-Z0-9]{6}$", "example": "B6AI7PA" } } ], "requestBody": { "description": "Appeal category and supporting documentation.", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/TenDLCBrandVettingAppealCreateRequest" } } }, "required": true }, "responses": { "200": { "description": "Returns the submitted appeal.", "headers": {}, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/SuccessResponse" }, "examples": { "default": { "value": { "success": true } } } } } }, "400": { "$ref": "#/components/responses/BadRequestErrorResponse" }, "401": { "$ref": "#/components/responses/UnauthorizedErrorResponse" }, "403": { "description": "Returns when the 10DLC feature is disabled for the account.", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/AccountErrorResponse" }, "examples": { "success": { "summary": "Successful response", "value": { "success": false, "message": "Request failed. The feature is disabled for the account." } } } } } }, "404": { "description": "Returns when the requested 10DLC resource does not exist.", "headers": {}, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/RecordNotFoundErrorResponse" }, "examples": { "success": { "summary": "Successful response", "value": { "success": false, "message": "Request failed. The Brand is not found." } } } } } }, "422": { "description": "Returns when a `VETTED_VERIFIED` Brand requests the `VERIFY_TAX_ID` appeal category.", "headers": {}, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/RecordNotFoundErrorResponse" }, "examples": { "success": { "summary": "Successful response", "value": { "success": false, "message": "Invalid request by VETTED_VERIFIED entity for VERIFY_TAX_ID category" } } } } } } }, "deprecated": false }, "get": { "tags": [ "10DLC" ], "summary": "List external vetting appeals", "description": "Returns the external vetting appeals for the 10DLC Brand identified by `brand_id`.", "operationId": "ten_dlc_brand_vetting_appeals_list", "security": [ { "bearerAuth": [ "campaigns:read" ] } ], "x-fern-sdk-group-name": [ "tenDlc", "brandVettingAppeals" ], "x-fern-sdk-method-name": "list", "x-mcp": { "readOnly": true, "destructive": false, "openWorld": false, "expose": true }, "parameters": [ { "name": "brand_id", "in": "path", "description": "The unique ID of the 10DLC Brand.", "required": true, "style": "simple", "schema": { "type": "string", "pattern": "^B[A-Z0-9]{6}$", "example": "BMQFB7X" } } ], "responses": { "200": { "description": "Returns the list of external vetting appeals.", "headers": {}, "content": { "application/json": { "schema": { "type": "array", "items": { "$ref": "#/components/schemas/TenDLCBrandVettingAppeal" }, "example": [ { "appeal_outcome": { "vet_status": "ACTIVE", "vet_score": 80, "feedback": { "reasons": [ "Company size as reported by government or business sources resulted in a score deduction: size range 6-10." ] } }, "appeal_status": "COMPLETE", "appeal_status_update_date": "2024-08-15T08:42:31", "attachment_uuid_list": [], "brand_id": "BMQFB7X", "category_list": [ "LOW_SCORE" ], "create_date": "2024-08-15T08:41:05", "evp_id": "AEGIS", "explanation": "This is an API test", "vetting_class": "STANDARD", "vetting_id": "48c0ffaa-4e51-4d44-3982-08dcb9856232" } ] }, "examples": { "default": { "value": [ { "appeal_outcome": { "vet_status": "ACTIVE", "vet_score": 80, "feedback": { "reasons": [ "Company size as reported by government or business sources resulted in a score deduction: size range 6-10." ] } }, "appeal_status": "COMPLETE", "appeal_status_update_date": "2024-08-15T08:42:31", "attachment_uuid_list": [], "brand_id": "BMQFB7X", "category_list": [ "LOW_SCORE" ], "create_date": "2024-08-15T08:41:05", "evp_id": "AEGIS", "explanation": "This is an API test", "vetting_class": "STANDARD", "vetting_id": "48c0ffaa-4e51-4d44-3982-08dcb9856232" } ] } } } } }, "400": { "$ref": "#/components/responses/BadRequestErrorResponse" }, "401": { "$ref": "#/components/responses/UnauthorizedErrorResponse" }, "403": { "description": "Returns when the 10DLC feature is disabled for the account.", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/AccountErrorResponse" }, "examples": { "success": { "summary": "Successful response", "value": { "success": false, "message": "Request failed. The feature is disabled for the account." } } } } } }, "404": { "description": "Returns when the requested 10DLC resource does not exist.", "headers": {}, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/RecordNotFoundErrorResponse" }, "examples": { "success": { "summary": "Successful response", "value": { "success": false, "message": "Request failed. The Brand is not found." } } } } } } }, "deprecated": false } }, "/v3/10dlc/brands/{brand_id}/usecases/{use_case}": { "get": { "tags": [ "10DLC" ], "summary": "Qualify a 10DLC Brand for a use case", "description": "Returns the qualification results for a 10DLC Brand use case. Includes MNO-specific attributes, restrictions, and fees.", "operationId": "ten_dlc_brand_usecase_qualify", "security": [ { "bearerAuth": [ "campaigns:read" ] } ], "x-fern-sdk-group-name": [ "tenDlc", "brands" ], "x-fern-sdk-method-name": "qualifyUsecase", "x-mcp": { "readOnly": true, "destructive": false, "openWorld": false, "expose": true }, "parameters": [ { "name": "brand_id", "in": "path", "description": "The unique ID of the 10DLC Brand.", "required": true, "style": "simple", "schema": { "type": "string", "pattern": "^B[A-Z0-9]{6}$", "example": "BMQFB7X" } }, { "name": "use_case", "in": "path", "description": "Name of the use case to qualify the Brand for.", "required": true, "style": "simple", "schema": { "type": "string", "enum": [ "AGENTS_FRANCHISES", "CARRIER_EXEMPT", "CHARITY", "EMERGENCY", "K12_EDUCATION", "LOW_VOLUME", "M2M", "MIXED", "POLITICAL", "PROXY", "SOCIAL", "SOLE_PROPRIETOR", "SWEEPSTAKE", "TRIAL", "UCAAS_HIGH", "UCAAS_LOW", "2FA", "ACCOUNT_NOTIFICATION", "CUSTOMER_CARE", "DELIVERY_NOTIFICATION", "FRAUD_ALERT", "HIGHER_EDUCATION", "MARKETING", "POLLING_VOTING", "PUBLIC_SERVICE_ANNOUNCEMENT", "SECURITY_ALERT" ], "example": "2FA" } } ], "responses": { "200": { "description": "Returns the use case qualification results for the Brand.", "headers": {}, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/TenDLCBrandQualificationResult" }, "examples": { "default": { "value": { "mno_metadata": [ { "att_mms_tpm": null, "att_msg_class": null, "att_sms_tpm": null, "att_tpm_scope": null, "help_required": true, "min_msg_samples": 1, "mno": "T-Mobile", "mno_qualify": true, "mno_review": false, "mno_support": true, "no_embedded_links": false, "no_embedded_phone": false, "optin_required": true, "optout_required": false, "tmobile_brand_dcap": 2000, "tmobile_brand_tier": "LOW" } ], "monthly_fee": 10, "usecase": "2FA" } } } } } }, "400": { "$ref": "#/components/responses/BadRequestErrorResponse" }, "401": { "$ref": "#/components/responses/UnauthorizedErrorResponse" }, "403": { "description": "Returns when the 10DLC feature is disabled for the account.", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/AccountErrorResponse" }, "examples": { "success": { "summary": "Successful response", "value": { "success": false, "message": "Request failed. The feature is disabled for the account." } } } } } }, "404": { "description": "Returns when the requested 10DLC resource does not exist.", "headers": {}, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/RecordNotFoundErrorResponse" }, "examples": { "success": { "summary": "Successful response", "value": { "success": false, "message": "Request failed. The Brand is not found." } } } } } }, "422": { "description": "Returns when the Brand is still being scored or has not yet been submitted to TCR.", "headers": {}, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/RecordNotFoundErrorResponse" }, "examples": { "success": { "summary": "Successful response", "value": { "success": false, "message": "The Brand is in a 'pending' state waiting for the brand scoring task be to completed or the Brand has not been submitted to TCR yet" } } } } } } }, "deprecated": false } }, "/v3/10dlc/brands/campaigns": { "get": { "tags": [ "10DLC" ], "summary": "List 10DLC Campaigns", "description": "Returns a paginated list of 10DLC Campaigns for the authenticated account, filtered by date, status, and use case.", "operationId": "ten_dlc_campaigns_list", "security": [ { "bearerAuth": [ "campaigns:read" ] } ], "x-fern-sdk-group-name": [ "tenDlc", "campaigns" ], "x-fern-sdk-method-name": "list", "x-mcp": { "readOnly": true, "destructive": false, "openWorld": false, "expose": true }, "parameters": [ { "name": "name", "in": "query", "description": "Filters Campaigns by name. Matches partial values.", "style": "form", "explode": true, "schema": { "type": "string", "example": "Name" } }, { "name": "usecase", "in": "query", "description": "Filters Campaigns by use case.", "style": "form", "explode": true, "schema": { "type": "string", "example": "2FA" } }, { "name": "status", "in": "query", "description": "Filters Campaigns by status.", "style": "form", "explode": true, "schema": { "type": "string", "example": "APPROVED" } }, { "name": "mock", "in": "query", "description": "When `true`, returns only mock Campaigns used for testing. Default `false`.", "style": "form", "explode": true, "schema": { "type": "boolean", "default": false, "example": true } }, { "name": "created_before", "in": "query", "description": "Returns Campaigns created on or before this date, in `YYYY-MM-DD` format.", "style": "form", "explode": true, "schema": { "type": "string", "format": "date", "example": "2024-08-22" } }, { "name": "created_after", "in": "query", "description": "Returns Campaigns created on or after this date, in `YYYY-MM-DD` format.", "style": "form", "explode": true, "schema": { "type": "string", "format": "date", "example": "2024-08-22" } }, { "name": "page", "in": "query", "description": "Page number to retrieve. Default `1`.", "style": "form", "explode": true, "schema": { "type": "integer", "format": "int32", "example": 1 } }, { "name": "per_page", "in": "query", "description": "Number of records to return per page. Default `25`.", "style": "form", "explode": true, "schema": { "type": "integer", "format": "int32", "example": 25 } } ], "responses": { "200": { "description": "Returns a paginated list of 10DLC Campaigns.", "headers": {}, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/TenDLCCampaignListResponse" }, "examples": { "default": { "value": { "items": [ { "affiliate_marketing": false, "age_gated": false, "auto_renewal": false, "brand_id": "BM20QP9", "campaign_id": "CKLCK95", "created_at": "2024-08-14T11:57:41", "description": "Our campaign aims to …", "direct_lending": false, "embedded_link_sample": null, "embedded_links": false, "embedded_phones": false, "feedback": null, "help": true, "help_keywords": "help", "help_message": "For help, please visit www.site.com. To opt-out, reply STOP.", "last_bill_date": "2024-08-14T11:57:42", "mock": false, "monthly_fee": "10.0", "name": "My first campaign", "next_bill_date": "2024-11-14T00:00:00", "optin": true, "optin_keywords": "begin,start", "optin_message": "You are now opted-in for help please reply HELP, to stop please reply STOP", "optin_workflow": "Our SMS ...", "optout": true, "optout_keywords": "stop,quit,unsubscribe", "optout_message": "You are now opted out and will receive no further messages", "privacy_policy": "https://site.com/privacy-policy", "sample1": "Your verification code is XXXXXX", "sample2": "XXXX is your verification code", "sample3": null, "sample4": null, "sample5": null, "status": "APPROVED", "terms_conditions": "https://site.com/terms-and-conditions", "updated_at": "2024-08-14T11:57:47", "usecase": "2FA", "phone_numbers": [ "14358684439", "13193337776", "12673296046" ] } ], "pagination": { "current_page": 1, "per_page": 25, "total": 1, "total_pages": 1 } } } } } } }, "400": { "$ref": "#/components/responses/BadRequestErrorResponse" }, "401": { "$ref": "#/components/responses/UnauthorizedErrorResponse" }, "403": { "description": "Returns when the 10DLC feature is disabled for the account.", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/AccountErrorResponse" }, "examples": { "success": { "summary": "Successful response", "value": { "success": false, "message": "Request failed. The feature is disabled for the account." } } } } } }, "404": { "$ref": "#/components/responses/NotFoundErrorResponse" } }, "deprecated": false } }, "/v3/10dlc/brands/{brand_id}/campaigns": { "get": { "tags": [ "10DLC" ], "summary": "List Brand Campaigns", "description": "Returns a paginated list of 10DLC Campaigns associated with the 10DLC Brand identified by `brand_id`.", "operationId": "ten_dlc_brand_campaigns_list", "security": [ { "bearerAuth": [ "campaigns:read" ] } ], "x-fern-sdk-group-name": [ "tenDlc", "campaigns" ], "x-fern-sdk-method-name": "listByBrand", "x-mcp": { "readOnly": true, "destructive": false, "openWorld": false, "expose": true }, "parameters": [ { "name": "brand_id", "in": "path", "description": "The unique ID of the 10DLC Brand.", "required": true, "style": "simple", "schema": { "type": "string", "pattern": "^B[A-Z0-9]{6}$", "example": "BM20QP9" } }, { "name": "name", "in": "query", "description": "Filters Campaigns by name. Matches partial values.", "style": "form", "explode": true, "schema": { "type": "string", "example": "Name" } }, { "name": "usecase", "in": "query", "description": "Filters Campaigns by use case.", "style": "form", "explode": true, "schema": { "type": "string", "example": "2FA" } }, { "name": "status", "in": "query", "description": "Filters Campaigns by status.", "style": "form", "explode": true, "schema": { "type": "string", "example": "APPROVED" } }, { "name": "mock", "in": "query", "description": "When `true`, returns only mock Campaigns used for testing. Default `false`.", "style": "form", "explode": true, "schema": { "type": "boolean", "default": false, "example": true } }, { "name": "created_before", "in": "query", "description": "Returns Campaigns created on or before this date, in `YYYY-MM-DD` format.", "style": "form", "explode": true, "schema": { "type": "string", "format": "date", "example": "2024-08-22" } }, { "name": "created_after", "in": "query", "description": "Returns Campaigns created on or after this date, in `YYYY-MM-DD` format.", "style": "form", "explode": true, "schema": { "type": "string", "format": "date", "example": "2024-08-22" } }, { "name": "page", "in": "query", "description": "Page number to retrieve. Default `1`.", "style": "form", "explode": true, "schema": { "type": "integer", "format": "int32", "example": 1 } }, { "name": "per_page", "in": "query", "description": "Number of records to return per page. Default `25`.", "style": "form", "explode": true, "schema": { "type": "integer", "format": "int32", "example": 25 } } ], "responses": { "200": { "description": "Returns a paginated list of 10DLC Campaigns.", "headers": {}, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/TenDLCCampaignListResponse" }, "examples": { "default": { "value": { "items": [ { "affiliate_marketing": false, "age_gated": false, "auto_renewal": false, "brand_id": "BM20QP9", "campaign_id": "CKLCK95", "created_at": "2024-08-14T11:57:41", "description": "Our campaign aims to …", "direct_lending": false, "embedded_link_sample": null, "embedded_links": false, "embedded_phones": false, "feedback": null, "help": true, "help_keywords": "help", "help_message": "For help, please visit www.site.com. To opt-out, reply STOP.", "last_bill_date": "2024-08-14T11:57:42", "mock": false, "monthly_fee": "10.0", "name": "My first campaign", "next_bill_date": "2024-11-14T00:00:00", "optin": true, "optin_keywords": "begin,start", "optin_message": "You are now opted-in for help please reply HELP, to stop please reply STOP", "optin_workflow": "Our SMS ...", "optout": true, "optout_keywords": "stop,quit,unsubscribe", "optout_message": "You are now opted out and will receive no further messages", "privacy_policy": "https://site.com/privacy-policy", "sample1": "Your verification code is XXXXXX", "sample2": "XXXX is your verification code", "sample3": null, "sample4": null, "sample5": null, "status": "APPROVED", "terms_conditions": "https://site.com/terms-and-conditions", "updated_at": "2024-08-14T11:57:47", "usecase": "2FA", "phone_numbers": [ "14358684439", "13193337776", "12673296046" ] } ], "pagination": { "current_page": 1, "per_page": 25, "total": 1, "total_pages": 1 } } } } } } }, "400": { "$ref": "#/components/responses/BadRequestErrorResponse" }, "401": { "$ref": "#/components/responses/UnauthorizedErrorResponse" }, "403": { "description": "Returns when the 10DLC feature is disabled for the account.", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/AccountErrorResponse" }, "examples": { "success": { "summary": "Successful response", "value": { "success": false, "message": "Request failed. The feature is disabled for the account." } } } } } }, "404": { "description": "Returns when no 10DLC Brand matches `brand_id`.", "headers": {}, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/RecordNotFoundErrorResponse" }, "examples": { "success": { "summary": "Successful response", "value": { "success": false, "message": "Request failed. The Brand is not found." } } } } } } }, "deprecated": false }, "post": { "tags": [ "10DLC" ], "summary": "Register a 10DLC Campaign", "description": "Registers a 10DLC Campaign under the 10DLC Brand identified by `brand_id`. The Brand must have a verified identity status.", "operationId": "ten_dlc_brand_campaigns_create", "security": [ { "bearerAuth": [ "campaigns:write" ] } ], "x-fern-sdk-group-name": [ "tenDlc", "campaigns" ], "x-fern-sdk-method-name": "create", "x-mcp": { "readOnly": false, "destructive": true, "openWorld": true, "expose": true }, "parameters": [ { "name": "brand_id", "in": "path", "description": "The unique ID of the 10DLC Brand.", "required": true, "style": "simple", "schema": { "type": "string", "pattern": "^B[A-Z0-9]{6}$", "example": "BM20QP9" } } ], "requestBody": { "description": "Attributes for the new 10DLC Campaign.", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/TenDLCCampaignCreateRequest" } } }, "required": true }, "responses": { "201": { "description": "Returns the registered 10DLC Campaign.", "headers": {}, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/TenDLCCampaign" }, "examples": { "default": { "value": { "affiliate_marketing": false, "age_gated": false, "auto_renewal": false, "brand_id": "BM20QP9", "campaign_id": "CKLCK95", "created_at": "2024-08-14T11:57:41", "description": "Our campaign aims to …", "direct_lending": false, "embedded_link_sample": null, "embedded_links": false, "embedded_phones": false, "feedback": null, "help": true, "help_keywords": "help", "help_message": "For help, please visit www.site.com. To opt-out, reply STOP.", "last_bill_date": "2024-08-14T11:57:42", "mock": false, "monthly_fee": "10.0", "name": "My first campaign", "next_bill_date": "2024-11-14T00:00:00", "optin": true, "optin_keywords": "begin,start", "optin_message": "You are now opted-in for help please reply HELP, to stop please reply STOP", "optin_workflow": "Our SMS ...", "optout": true, "optout_keywords": "stop,quit,unsubscribe", "optout_message": "You are now opted out and will receive no further messages", "privacy_policy": "https://site.com/privacy-policy", "sample1": "Your verification code is XXXXXX", "sample2": "XXXX is your verification code", "sample3": null, "sample4": null, "sample5": null, "status": "APPROVED", "terms_conditions": "https://site.com/terms-and-conditions", "updated_at": "2024-08-14T11:57:47", "usecase": "2FA", "phone_numbers": [] } } } } } }, "400": { "$ref": "#/components/responses/BadRequestErrorResponse" }, "401": { "$ref": "#/components/responses/UnauthorizedErrorResponse" }, "403": { "description": "Returns when the 10DLC feature is disabled for the account.", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/AccountErrorResponse" }, "examples": { "success": { "summary": "Successful response", "value": { "success": false, "message": "Request failed. The feature is disabled for the account." } } } } } }, "404": { "description": "Returns when no 10DLC Brand matches `brand_id`.", "headers": {}, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/RecordNotFoundErrorResponse" }, "examples": { "success": { "summary": "Successful response", "value": { "success": false, "message": "Request failed. The Brand is not found." } } } } } }, "422": { "$ref": "#/components/responses/ValidationErrorResponse" } }, "deprecated": false } }, "/v3/10dlc/brands/{brand_id}/campaigns/{campaign_id}": { "get": { "tags": [ "10DLC" ], "summary": "Retrieve a 10DLC Campaign", "description": "Returns the 10DLC Campaign identified by `campaign_id` under the Brand identified by `brand_id`.", "operationId": "ten_dlc_brand_campaigns_get", "security": [ { "bearerAuth": [ "campaigns:read" ] } ], "x-fern-sdk-group-name": [ "tenDlc", "campaigns" ], "x-fern-sdk-method-name": "get", "x-mcp": { "readOnly": true, "destructive": false, "openWorld": false, "expose": true }, "parameters": [ { "name": "brand_id", "in": "path", "description": "The unique ID of the 10DLC Brand.", "required": true, "style": "simple", "schema": { "type": "string", "pattern": "^B[A-Z0-9]{6}$", "example": "BM20QP9" } }, { "name": "campaign_id", "in": "path", "description": "The unique ID of the 10DLC Campaign.", "required": true, "style": "simple", "schema": { "type": "string", "example": "CKLCK95" } } ], "responses": { "200": { "description": "Returns the 10DLC Campaign.", "headers": {}, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/TenDLCCampaign" }, "examples": { "default": { "value": { "affiliate_marketing": false, "age_gated": false, "auto_renewal": false, "brand_id": "BM20QP9", "campaign_id": "CKLCK95", "created_at": "2024-08-14T11:57:41", "description": "Our campaign aims to …", "direct_lending": false, "embedded_link_sample": null, "embedded_links": false, "embedded_phones": false, "feedback": null, "help": true, "help_keywords": "help", "help_message": "For help, please visit www.site.com. To opt-out, reply STOP.", "last_bill_date": "2024-08-14T11:57:42", "mock": false, "monthly_fee": "10.0", "name": "My first campaign", "next_bill_date": "2024-11-14T00:00:00", "optin": true, "optin_keywords": "begin,start", "optin_message": "You are now opted-in for help please reply HELP, to stop please reply STOP", "optin_workflow": "Our SMS ...", "optout": true, "optout_keywords": "stop,quit,unsubscribe", "optout_message": "You are now opted out and will receive no further messages", "privacy_policy": "https://site.com/privacy-policy", "sample1": "Your verification code is XXXXXX", "sample2": "XXXX is your verification code", "sample3": null, "sample4": null, "sample5": null, "status": "APPROVED", "terms_conditions": "https://site.com/terms-and-conditions", "updated_at": "2024-08-14T11:57:47", "usecase": "2FA", "phone_numbers": [ "14358684439", "13193337776", "12673296046" ] } } } } } }, "400": { "$ref": "#/components/responses/BadRequestErrorResponse" }, "401": { "$ref": "#/components/responses/UnauthorizedErrorResponse" }, "403": { "description": "Returns when the 10DLC feature is disabled for the account.", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/AccountErrorResponse" }, "examples": { "success": { "summary": "Successful response", "value": { "success": false, "message": "Request failed. The feature is disabled for the account." } } } } } }, "404": { "description": "Returns when no 10DLC Brand matches `brand_id`.", "headers": {}, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/RecordNotFoundErrorResponse" }, "examples": { "success": { "summary": "Successful response", "value": { "success": false, "message": "Request failed. The Brand is not found." } } } } } } }, "deprecated": false }, "put": { "tags": [ "10DLC" ], "summary": "Update a 10DLC Campaign", "description": "Updates the 10DLC Campaign identified by `campaign_id`. Only the provided fields are changed.", "operationId": "ten_dlc_brand_campaigns_update", "security": [ { "bearerAuth": [ "campaigns:write" ] } ], "x-fern-sdk-group-name": [ "tenDlc", "campaigns" ], "x-fern-sdk-method-name": "update", "x-mcp": { "readOnly": false, "destructive": false, "openWorld": false, "expose": true }, "parameters": [ { "name": "brand_id", "in": "path", "description": "The unique ID of the 10DLC Brand.", "required": true, "style": "simple", "schema": { "type": "string", "pattern": "^B[A-Z0-9]{6}$", "example": "BM20QP9" } }, { "name": "campaign_id", "in": "path", "description": "The unique ID of the 10DLC Campaign.", "required": true, "style": "simple", "schema": { "type": "string", "example": "CKLCK95" } } ], "requestBody": { "description": "Fields to update on the 10DLC Campaign. Only included fields are changed.", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/TenDLCCampaignUpdateRequest" } } }, "required": true }, "responses": { "200": { "description": "Returns the updated 10DLC Campaign.", "headers": {}, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/TenDLCCampaign" }, "examples": { "default": { "value": { "affiliate_marketing": false, "age_gated": false, "auto_renewal": false, "brand_id": "BM20QP9", "campaign_id": "CKLCK95", "created_at": "2024-08-14T11:57:41", "description": "Our campaign aims to …", "direct_lending": false, "embedded_link_sample": null, "embedded_links": false, "embedded_phones": false, "feedback": null, "help": true, "help_keywords": "help", "help_message": "For help, please visit www.site.com. To opt-out, reply STOP.", "last_bill_date": "2024-08-14T11:57:42", "mock": false, "monthly_fee": "10.0", "name": "My first campaign", "next_bill_date": "2024-11-14T00:00:00", "optin": true, "optin_keywords": "begin,start", "optin_message": "You are now opted-in for help please reply HELP, to stop please reply STOP", "optin_workflow": "Our SMS ...", "optout": true, "optout_keywords": "stop,quit,unsubscribe", "optout_message": "You are now opted out and will receive no further messages", "privacy_policy": "https://site.com/privacy-policy", "sample1": "Your verification code is XXXXXX", "sample2": "XXXX is your verification code", "sample3": null, "sample4": null, "sample5": null, "status": "APPROVED", "terms_conditions": "https://site.com/terms-and-conditions", "updated_at": "2024-08-14T11:57:47", "usecase": "2FA", "phone_numbers": [] } } } } } }, "400": { "$ref": "#/components/responses/BadRequestErrorResponse" }, "401": { "$ref": "#/components/responses/UnauthorizedErrorResponse" }, "403": { "description": "Returns when the 10DLC feature is disabled for the account.", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/AccountErrorResponse" }, "examples": { "success": { "summary": "Successful response", "value": { "success": false, "message": "Request failed. The feature is disabled for the account." } } } } } }, "404": { "description": "Returns when no 10DLC Brand matches `brand_id`.", "headers": {}, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/RecordNotFoundErrorResponse" }, "examples": { "success": { "summary": "Successful response", "value": { "success": false, "message": "Request failed. The Brand is not found." } } } } } }, "422": { "$ref": "#/components/responses/ValidationErrorResponse" } }, "deprecated": false }, "delete": { "tags": [ "10DLC" ], "summary": "Delete a 10DLC Campaign", "description": "Deletes a 10DLC Campaign. Associated phone numbers cannot be used as Sender IDs once the Campaign is deleted.", "operationId": "ten_dlc_brand_campaigns_delete", "security": [ { "bearerAuth": [ "campaigns:write" ] } ], "x-fern-sdk-group-name": [ "tenDlc", "campaigns" ], "x-fern-sdk-method-name": "delete", "x-mcp": { "readOnly": false, "destructive": true, "openWorld": false, "expose": true }, "parameters": [ { "name": "brand_id", "in": "path", "description": "The unique ID of the 10DLC Brand.", "required": true, "style": "simple", "schema": { "type": "string", "pattern": "^B[A-Z0-9]{6}$", "example": "BM20QP9" } }, { "name": "campaign_id", "in": "path", "description": "The unique ID of the 10DLC Campaign.", "required": true, "style": "simple", "schema": { "type": "string", "example": "CKLCK95" } } ], "responses": { "200": { "description": "Returns a success confirmation. The 10DLC Campaign is deleted.", "headers": {}, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/SuccessResponse" }, "examples": { "default": { "value": { "success": true } } } } } }, "400": { "$ref": "#/components/responses/BadRequestErrorResponse" }, "401": { "$ref": "#/components/responses/UnauthorizedErrorResponse" }, "403": { "description": "Returns when the 10DLC feature is disabled for the account.", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/AccountErrorResponse" }, "examples": { "success": { "summary": "Successful response", "value": { "success": false, "message": "Request failed. The feature is disabled for the account." } } } } } }, "404": { "description": "Returns when no 10DLC Brand matches `brand_id`.", "headers": {}, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/RecordNotFoundErrorResponse" }, "examples": { "success": { "summary": "Successful response", "value": { "success": false, "message": "Request failed. The Brand is not found." } } } } } } }, "deprecated": false } }, "/v3/10dlc/subscriptions": { "post": { "tags": [ "10DLC" ], "summary": "Subscribe to 10DLC events", "description": "Registers a callback URL to receive Wavix 10DLC event notifications.", "operationId": "ten_dlc_subscriptions_create", "security": [ { "bearerAuth": [ "campaigns:write" ] } ], "x-fern-sdk-group-name": [ "tenDlc", "subscriptions" ], "x-fern-sdk-method-name": "create", "x-mcp": { "readOnly": false, "destructive": true, "openWorld": true, "expose": true }, "parameters": [], "requestBody": { "description": "Event categories and callback URL for the subscription.", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/TenDLCEventSubscription" } } }, "required": true }, "responses": { "201": { "description": "Returns the created 10DLC event subscription.", "headers": {}, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/TenDLCEventSubscription" }, "examples": { "default": { "value": { "subscription_category": "brand", "url": "https://webhook.url" } } } } } }, "400": { "$ref": "#/components/responses/BadRequestErrorResponse" }, "401": { "$ref": "#/components/responses/UnauthorizedErrorResponse" }, "403": { "description": "Returns when the 10DLC feature is disabled for the account.", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/AccountErrorResponse" }, "examples": { "success": { "summary": "Successful response", "value": { "success": false, "message": "Request failed. The feature is disabled for the account." } } } } } }, "422": { "$ref": "#/components/responses/ValidationErrorResponse" } }, "deprecated": false }, "get": { "tags": [ "10DLC" ], "summary": "List event subscriptions", "description": "Returns the 10DLC event subscriptions for the authenticated account.", "operationId": "ten_dlc_subscriptions_list", "security": [ { "bearerAuth": [ "campaigns:read" ] } ], "x-fern-sdk-group-name": [ "tenDlc", "subscriptions" ], "x-fern-sdk-method-name": "list", "x-mcp": { "readOnly": true, "destructive": false, "openWorld": false, "expose": true }, "parameters": [], "responses": { "200": { "description": "Returns the list of 10DLC event subscriptions.", "headers": {}, "content": { "application/json": { "schema": { "type": "array", "items": { "$ref": "#/components/schemas/TenDLCEventSubscription" }, "example": [ { "subscription_category": "brand", "url": "https://webhook.url" } ] }, "examples": { "default": { "value": [ { "subscription_category": "brand", "url": "https://webhook.url" } ] } } } } }, "400": { "$ref": "#/components/responses/BadRequestErrorResponse" }, "401": { "$ref": "#/components/responses/UnauthorizedErrorResponse" }, "403": { "description": "Returns when the 10DLC feature is disabled for the account.", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/AccountErrorResponse" }, "examples": { "success": { "summary": "Successful response", "value": { "success": false, "message": "Request failed. The feature is disabled for the account." } } } } } } }, "deprecated": false }, "delete": { "tags": [ "10DLC" ], "summary": "Delete event subscription", "description": "Removes the 10DLC event subscription for the specified event category.", "operationId": "ten_dlc_subscriptions_delete", "security": [ { "bearerAuth": [ "campaigns:write" ] } ], "x-fern-sdk-group-name": [ "tenDlc", "subscriptions" ], "x-fern-sdk-method-name": "delete", "x-mcp": { "readOnly": false, "destructive": true, "openWorld": false, "expose": true }, "parameters": [ { "name": "subscription_category", "in": "query", "description": "Event category to unsubscribe from.", "required": true, "style": "form", "explode": true, "schema": { "type": "string", "example": "number" } } ], "responses": { "200": { "description": "Returns a success confirmation. The event subscription is removed.", "headers": {}, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/SuccessResponse" }, "examples": { "default": { "value": { "success": true } } } } } }, "400": { "$ref": "#/components/responses/BadRequestErrorResponse" }, "401": { "$ref": "#/components/responses/UnauthorizedErrorResponse" }, "403": { "description": "Returns when the 10DLC feature is disabled for the account.", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/AccountErrorResponse" }, "examples": { "success": { "summary": "Successful response", "value": { "success": false, "message": "Request failed. The feature is disabled for the account." } } } } } }, "404": { "$ref": "#/components/responses/NotFoundErrorResponse" } }, "deprecated": false } }, "/v3/10dlc/brands/{brand_id}/campaigns/{campaign_id}/numbers/{number}": { "post": { "tags": [ "10DLC" ], "summary": "Link a number to a 10DLC Campaign", "description": "Links a phone number to a 10DLC Campaign. Wavix automatically creates a Sender ID once the number is approved.", "operationId": "ten_dlc_campaign_numbers_link", "security": [ { "bearerAuth": [ "campaigns:write" ] } ], "x-fern-sdk-group-name": [ "tenDlc", "campaignNumbers" ], "x-fern-sdk-method-name": "link", "x-mcp": { "readOnly": false, "destructive": false, "openWorld": true, "expose": true }, "parameters": [ { "name": "brand_id", "in": "path", "description": "The unique ID of the 10DLC Brand.", "required": true, "style": "simple", "schema": { "type": "string", "pattern": "^B[A-Z0-9]{6}$", "example": "B9FXYNH" } }, { "name": "campaign_id", "in": "path", "description": "The unique ID of the 10DLC Campaign.", "required": true, "style": "simple", "schema": { "type": "string", "example": "CSJ4TV0" } }, { "name": "number", "in": "path", "description": "The phone number to link to the Campaign, in E.164 format.", "required": true, "style": "simple", "schema": { "type": "string", "example": "17029641104" } } ], "responses": { "200": { "description": "Returns a success confirmation. The phone number is linked to the Campaign.", "headers": {}, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/SuccessResponse" }, "examples": { "default": { "value": { "success": true } } } } } }, "400": { "$ref": "#/components/responses/BadRequestErrorResponse" }, "401": { "$ref": "#/components/responses/UnauthorizedErrorResponse" }, "403": { "description": "Returns when the 10DLC feature is disabled for the account.", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/AccountErrorResponse" }, "examples": { "success": { "summary": "Successful response", "value": { "success": false, "message": "Request failed. The feature is disabled for the account." } } } } } }, "404": { "$ref": "#/components/responses/NotFoundErrorResponse" }, "422": { "$ref": "#/components/responses/ValidationErrorResponse" } }, "deprecated": false }, "delete": { "tags": [ "10DLC" ], "summary": "Unlink phone number", "description": "Unlinks a phone number from a 10DLC Campaign. The associated Sender ID is also deleted.", "operationId": "ten_dlc_campaign_numbers_unlink", "security": [ { "bearerAuth": [ "campaigns:write" ] } ], "x-fern-sdk-group-name": [ "tenDlc", "campaignNumbers" ], "x-fern-sdk-method-name": "unlink", "x-mcp": { "readOnly": false, "destructive": true, "openWorld": false, "expose": true }, "parameters": [ { "name": "brand_id", "in": "path", "description": "The unique ID of the 10DLC Brand.", "required": true, "style": "simple", "schema": { "type": "string", "pattern": "^B[A-Z0-9]{6}$", "example": "B9FXYNH" } }, { "name": "campaign_id", "in": "path", "description": "The unique ID of the 10DLC Campaign.", "required": true, "style": "simple", "schema": { "type": "string", "example": "CSJ4TV0" } }, { "name": "number", "in": "path", "description": "The phone number to unlink from the Campaign, in E.164 format.", "required": true, "style": "simple", "schema": { "type": "string", "example": "17029641104" } } ], "responses": { "200": { "description": "Returns a success confirmation. The phone number is unlinked from the Campaign.", "headers": {}, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/SuccessResponse" }, "examples": { "default": { "value": { "success": true } } } } } }, "400": { "$ref": "#/components/responses/BadRequestErrorResponse" }, "401": { "$ref": "#/components/responses/UnauthorizedErrorResponse" }, "403": { "description": "Returns when the 10DLC feature is disabled for the account.", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/AccountErrorResponse" }, "examples": { "success": { "summary": "Successful response", "value": { "success": false, "message": "Request failed. The feature is disabled for the account." } } } } } }, "404": { "$ref": "#/components/responses/NotFoundErrorResponse" } }, "deprecated": false } }, "/v3/10dlc/brands/{brand_id}/campaigns/{campaign_id}/numbers": { "get": { "tags": [ "10DLC" ], "summary": "List Campaign phone numbers", "description": "Returns the phone numbers linked to the 10DLC Campaign identified by `campaign_id`.", "operationId": "ten_dlc_campaign_numbers_list", "security": [ { "bearerAuth": [ "campaigns:read" ] } ], "x-fern-sdk-group-name": [ "tenDlc", "campaignNumbers" ], "x-fern-sdk-method-name": "list", "x-mcp": { "readOnly": true, "destructive": false, "openWorld": false, "expose": true }, "parameters": [ { "name": "brand_id", "in": "path", "description": "The unique ID of the 10DLC Brand.", "required": true, "style": "simple", "schema": { "type": "string", "pattern": "^B[A-Z0-9]{6}$", "example": "B9FXYNH" } }, { "name": "campaign_id", "in": "path", "description": "The unique ID of the 10DLC Campaign.", "required": true, "style": "simple", "schema": { "type": "string", "example": "CSJ4TV0" } } ], "responses": { "200": { "description": "Returns the phone numbers linked to the Campaign.", "headers": {}, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/TenDLCCampaignNumberListResponse" }, "examples": { "success": { "summary": "Successful response", "value": { "brand_id": "B9FXYNH", "campaign_id": "CSJ4TV0", "numbers": [ { "number": "17029641104", "status": "APPROVED" } ] } } } } } }, "400": { "$ref": "#/components/responses/BadRequestErrorResponse" }, "401": { "$ref": "#/components/responses/UnauthorizedErrorResponse" }, "403": { "description": "Returns when the 10DLC feature is disabled for the account.", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/AccountErrorResponse" }, "examples": { "success": { "summary": "Successful response", "value": { "success": false, "message": "Request failed. The feature is disabled for the account." } } } } } }, "404": { "$ref": "#/components/responses/NotFoundErrorResponse" } }, "deprecated": false } }, "/v3/10dlc/brands/{brand_id}/campaigns/{campaign_id}/nudge": { "post": { "tags": [ "10DLC" ], "summary": "Nudge a 10DLC Campaign review", "description": "Requests action on a pending or rejected 10DLC Campaign. Use `nudge_intent` to specify the action: \n- `REVIEW`: Request review for a pending Campaign. - `APPEAL_REJECTION`: Appeal a rejected Campaign.\nNote:\n- The Campaign must be at least 72 hours old.\n- Only one nudge request per Campaign is allowed every 24 hours.", "operationId": "ten_dlc_campaigns_nudge", "security": [ { "bearerAuth": [ "campaigns:write" ] } ], "x-fern-sdk-group-name": [ "tenDlc", "campaigns" ], "x-fern-sdk-method-name": "nudge", "x-mcp": { "readOnly": false, "destructive": false, "openWorld": true, "expose": true }, "parameters": [ { "name": "brand_id", "in": "path", "description": "The unique ID of the 10DLC Brand.", "required": true, "style": "simple", "schema": { "type": "string", "pattern": "^B[A-Z0-9]{6}$", "example": "B9FXYNH" } }, { "name": "campaign_id", "in": "path", "description": "The unique ID of the 10DLC Campaign.", "required": true, "style": "simple", "schema": { "type": "string", "example": "CSJ4TV0" } } ], "requestBody": { "description": "Action to request on the Campaign.", "content": { "application/json": { "schema": { "allOf": [ { "$ref": "#/components/schemas/TenDLCCampaignNudgeRequest" }, { "description": "The nudge request" } ], "type": "object" } } }, "required": true }, "responses": { "200": { "description": "Returns a success confirmation. The nudge request is submitted.", "headers": {}, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/SuccessResponse" }, "examples": { "success": { "summary": "Successful response", "value": { "success": true } } } } } }, "400": { "$ref": "#/components/responses/BadRequestErrorResponse" }, "401": { "$ref": "#/components/responses/UnauthorizedErrorResponse" }, "403": { "description": "Returns when the 10DLC feature is disabled for the account.", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/AccountErrorResponse" }, "examples": { "success": { "summary": "Successful response", "value": { "success": false, "message": "Request failed. The feature is disabled for the account." } } } } } }, "404": { "description": "Returns when the requested 10DLC resource does not exist.", "headers": {}, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/RecordNotFoundErrorResponse" }, "examples": { "success": { "summary": "Successful response", "value": { "success": false, "message": "Request failed. The Brand is not found." } } } } } }, "429": { "description": "Returns when the Campaign is younger than 72 hours and is not yet eligible for a nudge.", "headers": {}, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/AccountErrorResponse" }, "examples": { "too_early": { "summary": "Campaign younger than 72 hours", "value": { "success": false, "message": "Request failed. The campaign should be older than 72 hours." } } } } } } }, "deprecated": false } }, "/v1/validation": { "get": { "tags": [ "Number validator" ], "summary": "Validate a number", "description": "Validates a single phone number and returns line type, carrier, portability, and reachability details. The response's `error_code` is a per-number result code (`000` success; `013` internal error; `021` invalid format; `041` remote timeout; `042` remote query failed; `091` insufficient funds) — distinct from the HTTP status codes below.", "operationId": "number_validator_get", "security": [ { "bearerAuth": [ "validator:read" ] } ], "x-fern-sdk-group-name": [ "numberValidator" ], "x-fern-sdk-method-name": "get", "x-mcp": { "readOnly": true, "destructive": false, "openWorld": false, "expose": true }, "parameters": [ { "name": "phone_number", "in": "query", "description": "The phone number to validate, in E.164 format with or without the leading `+`.", "required": true, "style": "form", "explode": true, "schema": { "type": "string", "example": "971569483322" } }, { "name": "type", "in": "query", "description": "Depth of validation to perform. Accepts a `PhoneNumberValidationType` value.", "required": true, "style": "form", "explode": true, "schema": { "$ref": "#/components/schemas/PhoneNumberValidationType", "type": "string" } } ], "responses": { "200": { "description": "Returns the phone number validation details.", "headers": {}, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/PhoneValidationResponse" }, "examples": { "success": { "summary": "Successful response", "value": { "phone_number": "971569483322", "valid": true, "country_code": "AE", "e164_format": "+971569483322", "national_format": "056 948 3322", "ported": false, "mcc": "424", "mnc": "02", "number_type": "mobile", "carrier_name": "Etisalat", "risky_destination": false, "unallocated_range": false, "reachable": true, "roaming": false, "timezone": "UTC+04:00", "charge": "0.015", "error_code": "000" } } } } } }, "400": { "$ref": "#/components/responses/BadRequestErrorResponse" }, "401": { "$ref": "#/components/responses/UnauthorizedErrorResponse" }, "403": { "$ref": "#/components/responses/ForbiddenErrorResponse" }, "404": { "$ref": "#/components/responses/NotFoundErrorResponse" } }, "deprecated": false }, "post": { "tags": [ "Number validator" ], "summary": "Validate multiple numbers", "description": "Validates a batch of phone numbers. When `async` is `true`, returns a `request_id` to poll for results instead of the validation details.", "operationId": "number_validator_create_bulk", "security": [ { "bearerAuth": [ "validator:write" ] } ], "x-fern-sdk-group-name": [ "numberValidator" ], "x-fern-sdk-method-name": "createBulk", "x-mcp": { "readOnly": false, "destructive": false, "openWorld": false, "expose": true }, "parameters": [], "requestBody": { "description": "Phone numbers to validate and validation options.", "content": { "application/json": { "schema": { "allOf": [ { "$ref": "#/components/schemas/PhoneValidationRequest" } ], "type": "object" } } }, "required": true }, "responses": { "200": { "description": "Returns the validation results, or a `request_id` when validation is asynchronous.", "headers": {}, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/NumberValidatorCreateBulkResponse" }, "examples": { "success": { "summary": "Successful response", "value": { "status": "success", "pending": 0, "count": 1000, "items": [ { "phone_number": "971569483322", "valid": true, "country_code": "AE", "e164_format": "+971569483322", "national_format": "056 948 3322", "ported": false, "mcc": "424", "mnc": "004", "number_type": "mobile", "carrier_name": "Etisalat", "risky_destination": false, "unallocated_range": false, "reachable": true, "roaming": false, "timezone": "UTC+04:00", "charge": "0.015", "error_code": "000" } ] } } } } } }, "400": { "$ref": "#/components/responses/BadRequestErrorResponse" }, "401": { "$ref": "#/components/responses/UnauthorizedErrorResponse" }, "403": { "$ref": "#/components/responses/ForbiddenErrorResponse" }, "404": { "$ref": "#/components/responses/NotFoundErrorResponse" }, "422": { "$ref": "#/components/responses/ValidationErrorResponse" } }, "deprecated": false } }, "/v1/validation/{request_id}": { "get": { "tags": [ "Number validator" ], "summary": "Retrieve validation results", "description": "Returns the results of an asynchronous batch validation identified by `request_id`.", "operationId": "number_validator_results_get", "security": [ { "bearerAuth": [ "validator:read" ] } ], "x-fern-sdk-group-name": [ "numberValidator", "results" ], "x-fern-sdk-method-name": "get", "x-mcp": { "readOnly": true, "destructive": false, "openWorld": false, "expose": true }, "parameters": [ { "name": "request_id", "in": "path", "description": "The `request_id` returned by the asynchronous bulk validation request.", "required": true, "style": "simple", "schema": { "type": "string", "example": "12542c5c-1a17-4d12-a163-5b68543e75f6" } } ], "responses": { "200": { "description": "Returns the batch validation results.", "headers": {}, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/PhoneValidationBatchResultResponse" }, "examples": { "success": { "summary": "Successful response", "value": { "status": "success", "pending": 10, "count": 1000, "items": [ { "phone_number": "971501390098", "valid": true, "country_code": "AE", "e164_format": "+971501390098", "national_format": "050 139 0098", "ported": false, "mcc": "424", "mnc": "02", "number_type": "mobile", "carrier_name": "Etisalat", "risky_destination": false, "unallocated_range": false, "reachable": true, "roaming": false, "timezone": "UTC+04:00", "charge": "0.015", "error_code": "000" }, { "phone_number": "971504359195", "valid": true, "country_code": "AE", "e164_format": "+971504359195", "national_format": "050 435 9195", "ported": false, "mcc": "424", "mnc": "02", "number_type": "mobile", "carrier_name": "Etisalat", "risky_destination": false, "unallocated_range": false, "reachable": true, "roaming": false, "timezone": "UTC+04:00", "charge": "0.015", "error_code": "000" } ] } } } } } }, "400": { "$ref": "#/components/responses/BadRequestErrorResponse" }, "401": { "$ref": "#/components/responses/UnauthorizedErrorResponse" }, "403": { "$ref": "#/components/responses/ForbiddenErrorResponse" }, "404": { "$ref": "#/components/responses/NotFoundErrorResponse" } }, "deprecated": false } }, "/v1/voice-campaigns": { "post": { "tags": [ "Voice campaigns" ], "summary": "Trigger a scenario", "description": "Launches a voice campaign that places a real outbound call using a pre-configured scenario. Track progress with the returned voice campaign `id`.", "operationId": "voice_campaigns_create", "security": [ { "bearerAuth": [ "campaigns:write" ] } ], "x-fern-sdk-group-name": [ "voiceCampaigns" ], "x-fern-sdk-method-name": "create", "x-mcp": { "readOnly": false, "destructive": true, "openWorld": true, "expose": true }, "parameters": [], "requestBody": { "description": "Attributes for the new voice campaign.", "content": { "application/json": { "schema": { "allOf": [ { "$ref": "#/components/schemas/VoiceCampaignCreateRequest" }, { "description": "Scenario and contact details for the campaign." } ], "type": "object" } } }, "required": true }, "responses": { "201": { "description": "Returns the launched voice campaign.", "headers": {}, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/VoiceCampaignsCreateResponse" }, "examples": { "success": { "summary": "Successful response", "value": { "voice_campaign": { "id": 2321423, "status": "status", "timestamp": "2023-06-15T10:30:00Z", "caller_id": "org_123", "contact": "contact" } } } } } } }, "400": { "$ref": "#/components/responses/BadRequestErrorResponse" }, "401": { "$ref": "#/components/responses/UnauthorizedErrorResponse" }, "403": { "$ref": "#/components/responses/ForbiddenErrorResponse" }, "404": { "$ref": "#/components/responses/NotFoundErrorResponse" }, "422": { "description": "Returns when the account has insufficient funds to launch the campaign.", "headers": {}, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/RecordNotFoundErrorResponse" }, "examples": { "default": { "value": { "success": false, "message": "Insufficient funds" } } } } } } }, "deprecated": false } }, "/v1/voice-campaigns/{id}": { "get": { "tags": [ "Voice campaigns" ], "summary": "Retrieve a voice campaign", "description": "Returns the voice campaign identified by `id`, including its current status.", "operationId": "voice_campaigns_get", "security": [ { "bearerAuth": [ "campaigns:read" ] } ], "x-fern-sdk-group-name": [ "voiceCampaigns" ], "x-fern-sdk-method-name": "get", "x-mcp": { "readOnly": true, "destructive": false, "openWorld": false, "expose": true }, "parameters": [ { "name": "id", "in": "path", "description": "The unique ID of the voice campaign to retrieve.", "required": true, "style": "simple", "schema": { "type": "integer", "format": "int32", "example": 2321423 } } ], "responses": { "200": { "description": "Returns the voice campaign.", "headers": {}, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/VoiceCampaignsGetResponse" }, "examples": { "success": { "summary": "Successful response", "value": { "voice_campaign": { "id": 2321423, "status": "in_progress", "timestamp": "2023-08-03T09:04:12.000Z", "caller_id": "13123310912", "contact": "16729923812" } } } } } } }, "400": { "$ref": "#/components/responses/BadRequestErrorResponse" }, "401": { "$ref": "#/components/responses/UnauthorizedErrorResponse" }, "403": { "$ref": "#/components/responses/ForbiddenErrorResponse" }, "404": { "$ref": "#/components/responses/NotFoundErrorResponse" } }, "deprecated": false } }, "/v1/short-links": { "post": { "tags": [ "Link shortener" ], "summary": "Create a short link", "description": "Creates a short link that redirects to the target URL and tracks click metrics.", "operationId": "link_shortener_create", "security": [ { "bearerAuth": [ "campaigns:write" ] } ], "x-fern-sdk-group-name": [ "linkShortener" ], "x-fern-sdk-method-name": "create", "x-mcp": { "readOnly": false, "destructive": false, "openWorld": true, "expose": true }, "parameters": [], "requestBody": { "description": "Attributes for the new short link.", "content": { "application/json": { "schema": { "allOf": [ { "$ref": "#/components/schemas/ShortLinkCreateRequest" } ], "type": "object" } } }, "required": true }, "responses": { "200": { "description": "Returns the created short link.", "headers": {}, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ShortLinkResponse" }, "examples": { "success": { "summary": "Successful response", "value": { "short_link": "https://wx.com/hd82Jhs21" } } } } } }, "400": { "$ref": "#/components/responses/BadRequestErrorResponse" }, "401": { "$ref": "#/components/responses/UnauthorizedErrorResponse" }, "403": { "$ref": "#/components/responses/ForbiddenErrorResponse" }, "404": { "$ref": "#/components/responses/NotFoundErrorResponse" }, "422": { "description": "Returns a validation error when a field value is invalid.", "headers": {}, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/RecordNotFoundErrorResponse" }, "examples": { "default": { "value": { "success": false, "message": "Expiration time can't be in the past" } } } } } } }, "deprecated": false } }, "/v1/short-links/metrics": { "get": { "tags": [ "Link shortener" ], "summary": "List short link metrics", "description": "Returns per-click metrics for short links, including device, location, and campaign attribution, within the requested date range.", "operationId": "link_shortener_metrics_list", "security": [ { "bearerAuth": [ "campaigns:read" ] } ], "x-fern-sdk-group-name": [ "linkShortener", "metrics" ], "x-fern-sdk-method-name": "list", "x-mcp": { "readOnly": true, "destructive": false, "openWorld": false, "expose": true }, "parameters": [ { "name": "from", "in": "query", "description": "Start of the date range to query, in `YYYY-MM-DD` format. Inclusive.", "required": true, "style": "form", "explode": true, "schema": { "type": "string", "format": "date", "example": "2023-05-01" } }, { "name": "to", "in": "query", "description": "End of the date range to query, in `YYYY-MM-DD` format. Inclusive.", "required": true, "style": "form", "explode": true, "schema": { "type": "string", "format": "date", "example": "2023-05-31" } }, { "name": "phone", "in": "query", "description": "Filters metrics by the phone number associated with the click, in E.164 format.", "style": "form", "explode": true, "schema": { "type": "string", "example": "1872025555" } }, { "name": "utm_campaign", "in": "query", "description": "Filters metrics by `utm_campaign` name.", "style": "form", "explode": true, "schema": { "type": "string", "example": "summer" } }, { "name": "page", "in": "query", "description": "Page number to retrieve. Default `1`.", "style": "form", "explode": true, "schema": { "type": "integer", "format": "int32", "example": 1 } }, { "name": "per_page", "in": "query", "description": "Number of records to return per page. Default `25`.", "style": "form", "explode": true, "schema": { "type": "integer", "format": "int32", "example": 25 } } ], "responses": { "200": { "description": "Returns a paginated list of short link metrics.", "headers": {}, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ShortLinkMetricsResponse" }, "examples": { "success": { "summary": "Successful response", "value": { "metrics": [ { "latitude": 59.3247, "longitude": 18.056, "operating_system": "Mac OS X 10.15", "browser": "Firefox", "language": "English", "phone": "12762025555", "utm_campaign": "summer", "created_at": "2023-07-19 18:23:42", "link_hash": "hd82Jhs21", "user_id": 100017 } ], "pagination": { "current_page": 2, "per_page": 25, "total": 101, "total_pages": 5 } } } } } } }, "400": { "$ref": "#/components/responses/BadRequestErrorResponse" }, "401": { "$ref": "#/components/responses/UnauthorizedErrorResponse" }, "403": { "$ref": "#/components/responses/ForbiddenErrorResponse" }, "404": { "$ref": "#/components/responses/NotFoundErrorResponse" } }, "deprecated": false } }, "/v1/two-fa/verification": { "post": { "tags": [ "2FA" ], "summary": "Create a 2FA Verification", "description": "Creates a 2FA verification and sends a real one-time password (OTP) to the destination phone number over the selected channel; this bills the account per OTP sent. Requires a 2FA service configured in the Wavix portal; the service is reused to generate and validate OTPs.\n\nThe verification proceeds through three steps:\n1. Create a verification to generate and send an OTP.\n2. Resend the OTP on the same verification if needed.\n3. Validate the OTP through the check endpoint.", "operationId": "two_fa_verification_create", "security": [ { "bearerAuth": [ "two_fa:write" ] } ], "x-fern-sdk-group-name": [ "twoFa", "verification" ], "x-fern-sdk-method-name": "create", "x-mcp": { "readOnly": false, "destructive": true, "openWorld": true, "expose": true }, "parameters": [], "requestBody": { "description": "Attributes for the new 2FA verification.", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/TwoFactorVerificationCreateRequest" } } }, "required": true }, "responses": { "200": { "description": "Returns the created 2FA verification.", "headers": {}, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/TwoFactorVerificationResponse" }, "examples": { "success": { "summary": "Successful response", "value": { "success": true, "service_id": "7204a030201211ee9fb47d093f2f127c", "session_url": "https://api.wavix.com/v1/two-fa/verification/2953d4308f2e11ecb75fcdafd6d2d687", "session_id": "2953d4308f2e11ecb75fcdafd6d2d687", "destination": "447919433768", "created_at": "2022-02-16T13:41:38.000Z", "number_lookup": { "number_type": "mobile", "country": "GB", "current_carrier": "Vodafone" } } } } } } }, "400": { "$ref": "#/components/responses/BadRequestErrorResponse" }, "401": { "$ref": "#/components/responses/UnauthorizedErrorResponse" }, "403": { "$ref": "#/components/responses/ForbiddenErrorResponse" }, "404": { "$ref": "#/components/responses/NotFoundErrorResponse" }, "422": { "$ref": "#/components/responses/ValidationErrorResponse" } }, "deprecated": false } }, "/v1/two-fa/service/{service_id}/sessions": { "get": { "tags": [ "2FA" ], "summary": "List 2FA verifications", "description": "Returns the 2FA verifications for the service identified by `service_id`, within the requested date range.", "operationId": "two_fa_sessions_list", "security": [ { "bearerAuth": [ "two_fa:read" ] } ], "x-fern-sdk-group-name": [ "twoFa", "sessions" ], "x-fern-sdk-method-name": "list", "x-mcp": { "readOnly": true, "destructive": false, "openWorld": false, "expose": true }, "parameters": [ { "name": "service_id", "in": "path", "description": "The unique ID of the 2FA service.", "required": true, "style": "simple", "schema": { "type": "string", "example": "7204a030201211ee9fb47d093f2f127c" } }, { "name": "from", "in": "query", "description": "Start of the date range to query, in `YYYY-MM-DD` format. Inclusive.", "required": true, "style": "form", "explode": true, "schema": { "type": "string", "format": "date", "example": "2022-01-01" } }, { "name": "to", "in": "query", "description": "End of the date range to query, in `YYYY-MM-DD` format. Inclusive.", "required": true, "style": "form", "explode": true, "schema": { "type": "string", "format": "date", "example": "2022-01-31" } } ], "responses": { "200": { "description": "Returns the list of 2FA verifications.", "headers": {}, "content": { "application/json": { "schema": { "type": "array", "items": { "$ref": "#/components/schemas/ListSessionsResponseItem" }, "example": [ { "created_at": "2022-02-16T13:41:38.000Z", "session_id": "2953d4308f2e11ecb75fcdafd6d2d687", "phone_number": "447919433768", "destination_country": "GB", "status": "verified", "charge": "0.01", "service_id": "7204a030201211ee9fb47d093f2f127c", "service_name": "Wavix 2FA Service" }, { "created_at": "2022-02-16T13:41:38.000Z", "session_id": "8753d4308f2e11ecb75fcdafd6d2d690", "phone_number": "447919433768", "destination_country": "GB", "status": "pending", "charge": "0.01", "service_id": "7204a030201211ee9fb47d093f2f127c", "service_name": "Wavix 2FA Service" } ] }, "examples": { "success": { "summary": "Successful response", "value": [ { "created_at": "2022-02-16T13:41:38.000Z", "session_id": "2953d4308f2e11ecb75fcdafd6d2d687", "phone_number": "447919433768", "destination_country": "GB", "status": "verified", "charge": "0.01", "service_id": "7204a030201211ee9fb47d093f2f127c", "service_name": "Wavix 2FA Service" }, { "created_at": "2022-02-16T13:41:38.000Z", "session_id": "8753d4308f2e11ecb75fcdafd6d2d690", "phone_number": "447919433768", "destination_country": "GB", "status": "pending", "charge": "0.01", "service_id": "7204a030201211ee9fb47d093f2f127c", "service_name": "Wavix 2FA Service" } ] } } } } }, "400": { "description": "Returns a validation error when a required field is missing or invalid.", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ValidationErrorResponse" }, "examples": { "default": { "value": { "success": false, "message": "Request validation errors: Field \"to\" is required" } } } } } }, "401": { "$ref": "#/components/responses/UnauthorizedErrorResponse" }, "403": { "$ref": "#/components/responses/ForbiddenErrorResponse" }, "404": { "description": "Returns when no verifications match the service and date range.", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ValidationErrorResponse" }, "examples": { "default": { "value": { "success": false, "message": "Sessions not found" } } } } } } }, "deprecated": false } }, "/v1/two-fa/verification/{session_id}": { "post": { "tags": [ "2FA" ], "summary": "Resend a code", "description": "Resends the OTP for the verification identified by `session_id` over the specified channel. Previously sent codes are invalidated.", "operationId": "two_fa_verification_resend", "security": [ { "bearerAuth": [ "two_fa:write" ] } ], "x-fern-sdk-group-name": [ "twoFa", "verification" ], "x-fern-sdk-method-name": "resend", "x-mcp": { "readOnly": false, "destructive": true, "openWorld": true, "expose": true }, "parameters": [ { "name": "session_id", "in": "path", "description": "The unique ID of the 2FA verification session.", "required": true, "style": "simple", "schema": { "type": "string", "example": "2953d4308f2e11ecb75fcdafd6d2d687" } } ], "requestBody": { "description": "Channel to resend the OTP over.", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/TwoFactorVerificationResendRequest" } } }, "required": true }, "responses": { "200": { "description": "Returns the resend result, including the channel used.", "headers": {}, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/TwoFactorVerificationResendResponse" }, "examples": { "success": { "summary": "Successful response", "value": { "success": true, "channel": "voice", "destination": "447919433768", "created_at": "2022-02-16T13:41:38.000Z" } } } } } }, "400": { "description": "Returns a validation error when a required field is missing or invalid.", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ValidationErrorResponse" }, "examples": { "default": { "value": { "success": false, "message": "Request validation errors: Field \"channel\" is required" } } } } } }, "401": { "$ref": "#/components/responses/UnauthorizedErrorResponse" }, "403": { "$ref": "#/components/responses/ForbiddenErrorResponse" }, "404": { "$ref": "#/components/responses/NotFoundErrorResponse" }, "422": { "$ref": "#/components/responses/ValidationErrorResponse" } }, "deprecated": false } }, "/v1/two-fa/verification/{session_id}/check": { "post": { "tags": [ "2FA" ], "summary": "Validate a code", "description": "Validates the OTP submitted by the end user against the verification identified by `session_id`. Non-idempotent — each call consumes one of a limited number of attempts tracked server-side; once exhausted, the verification returns `429` until a new verification is created.", "operationId": "two_fa_verification_check", "security": [ { "bearerAuth": [ "two_fa:write" ] } ], "x-fern-sdk-group-name": [ "twoFa", "verification" ], "x-fern-sdk-method-name": "check", "x-mcp": { "readOnly": false, "destructive": true, "openWorld": false, "expose": true }, "parameters": [ { "name": "session_id", "in": "path", "description": "The unique ID of the 2FA verification session.", "required": true, "style": "simple", "schema": { "type": "string", "example": "2953d4308f2e11ecb75fcdafd6d2d687" } } ], "requestBody": { "description": "OTP to validate.", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/TwoFactorVerificationCheckRequest" } } }, "required": true }, "responses": { "200": { "description": "Returns the validation result in `is_valid`.", "headers": {}, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/TwoFactorVerificationCheckResponse" }, "examples": { "success": { "summary": "Successful response", "value": { "is_valid": true } } } } } }, "400": { "description": "Returns a validation error when a required field is missing or invalid.", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ValidationErrorResponse" }, "examples": { "default": { "value": { "success": false, "message": "Request validation errors: Field \"code\" is required" } } } } } }, "401": { "$ref": "#/components/responses/UnauthorizedErrorResponse" }, "403": { "$ref": "#/components/responses/ForbiddenErrorResponse" }, "404": { "$ref": "#/components/responses/NotFoundErrorResponse" }, "429": { "$ref": "#/components/responses/TooManyRequestsErrorResponse" } }, "deprecated": false } }, "/v1/two-fa/verification/{session_id}/cancel": { "patch": { "tags": [ "2FA" ], "summary": "Cancel a 2FA verification", "description": "Cancels the 2FA verification identified by `session_id`. No further codes are sent, and previously sent codes can no longer be validated. A new verification is required to send another code.", "operationId": "two_fa_verification_cancel", "security": [ { "bearerAuth": [ "two_fa:write" ] } ], "x-fern-sdk-group-name": [ "twoFa", "verification" ], "x-fern-sdk-method-name": "cancel", "x-mcp": { "readOnly": false, "destructive": true, "openWorld": false, "expose": true }, "parameters": [ { "name": "session_id", "in": "path", "description": "The unique ID of the 2FA verification session.", "required": true, "style": "simple", "schema": { "type": "string", "example": "2953d4308f2e11ecb75fcdafd6d2d687" } } ], "responses": { "200": { "description": "Returns a success confirmation. The verification is canceled.", "headers": {}, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/SuccessResponse" }, "examples": { "success": { "summary": "Successful response", "value": { "success": true } } } } } }, "400": { "description": "Returns a validation error when a required field is missing or invalid.", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ValidationErrorResponse" }, "examples": { "default": { "value": { "success": false, "message": "Request validation errors: Field \"code\" is required" } } } } } }, "401": { "$ref": "#/components/responses/UnauthorizedErrorResponse" }, "403": { "$ref": "#/components/responses/ForbiddenErrorResponse" }, "404": { "description": "Returns when no verification matches `session_id`.", "headers": {}, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/RecordNotFoundErrorResponse" }, "examples": { "default": { "value": { "success": false, "message": "Two FA session is not canceled" } } } } } } }, "deprecated": false } }, "/v1/two-fa/session/{session_id}/events": { "get": { "tags": [ "2FA" ], "summary": "List 2FA verification events", "description": "Returns the lifecycle events of the 2FA verification identified by `session_id`, such as number lookup and code delivery.", "operationId": "two_fa_events_list", "security": [ { "bearerAuth": [ "two_fa:read" ] } ], "x-fern-sdk-group-name": [ "twoFa", "events" ], "x-fern-sdk-method-name": "list", "x-mcp": { "readOnly": true, "destructive": false, "openWorld": false, "expose": true }, "parameters": [ { "name": "session_id", "in": "path", "description": "The unique ID of the 2FA verification session.", "required": true, "style": "simple", "schema": { "type": "string", "example": "8753d4308f2e11ecb75fcdafd6d2d690" } } ], "responses": { "200": { "description": "Returns the list of 2FA verification events.", "headers": {}, "content": { "application/json": { "schema": { "type": "array", "items": { "$ref": "#/components/schemas/TwoFactorVerificationEvent" }, "example": [ { "created_at": "2022-02-16T13:41:38.000Z", "event": "Number lookup", "status": "success", "charge": "0.005", "error": null }, { "created_at": "2022-02-16T13:41:38.000Z", "event": "Code sent via SMS", "status": "success", "charge": "0.005", "error": null } ] }, "examples": { "default": { "value": [ { "created_at": "2022-02-16T13:41:38.000Z", "event": "Number lookup", "status": "success", "charge": "0.005", "error": null }, { "created_at": "2022-02-16T13:41:38.000Z", "event": "Code sent via SMS", "status": "success", "charge": "0.005", "error": null } ] } } } } }, "400": { "$ref": "#/components/responses/BadRequestErrorResponse" }, "401": { "$ref": "#/components/responses/UnauthorizedErrorResponse" }, "403": { "$ref": "#/components/responses/ForbiddenErrorResponse" }, "404": { "description": "Returns when no verification matches `session_id`.", "headers": {}, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/RecordNotFoundErrorResponse" }, "examples": { "default": { "value": { "success": false, "message": "2FA verification session with ID=1c7d5259092eb11f083eed7e070f20a2b cannot be found" } } } } } } }, "deprecated": false } }, "/v1/billing/transactions": { "get": { "tags": [ "Billing" ], "summary": "List transactions", "description": "Returns a paginated list of billing transactions for the authenticated account within the requested date range.", "operationId": "billing_transactions_list", "security": [ { "bearerAuth": [ "billing:read" ] } ], "x-fern-sdk-group-name": [ "billing", "transactions" ], "x-fern-sdk-method-name": "list", "x-mcp": { "readOnly": true, "destructive": false, "openWorld": false, "expose": true }, "parameters": [ { "name": "from_date", "in": "query", "description": "Start of the date range to query, in `YYYY-MM-DD` format. Inclusive.", "required": true, "style": "form", "explode": true, "schema": { "type": "string", "format": "date", "example": "2023-08-01" } }, { "name": "to_date", "in": "query", "description": "End of the date range to query, in `YYYY-MM-DD` format. Inclusive.", "required": true, "style": "form", "explode": true, "schema": { "type": "string", "format": "date", "example": "2023-08-31" } }, { "name": "type", "in": "query", "description": "Filters transactions by type. Accepts a `TransactionType` value.", "style": "form", "explode": true, "schema": { "$ref": "#/components/schemas/TransactionType", "type": "integer" } }, { "name": "details_contains", "in": "query", "description": "Filters transactions whose `details` contain the given substring.", "style": "form", "explode": true, "schema": { "type": "string", "example": "monthly" } }, { "name": "payments", "in": "query", "description": "When `true`, returns only account top-up transactions. Defaults to all transaction types.", "style": "form", "explode": true, "schema": { "type": "boolean", "example": true } }, { "name": "page", "in": "query", "description": "Page number to retrieve. Default `1`.", "style": "form", "explode": true, "schema": { "type": "integer", "format": "int32", "example": 1 } }, { "name": "per_page", "in": "query", "description": "Number of records to return per page. Default `25`.", "style": "form", "explode": true, "schema": { "type": "integer", "format": "int32", "example": 25 } } ], "responses": { "200": { "description": "Returns a paginated list of billing transactions.", "headers": {}, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/BillingTransactionListResponse" }, "examples": { "default": { "value": { "is_empty": false, "transactions": [ { "id": 24789389, "amount": -0.99, "balance_after": 309.0601, "date": "2023-08-29T14:48:38.000Z", "details": "Monthly fee for 16419252149", "status": "Committed", "type": 3, "show_invoice": false } ], "pagination": { "current_page": 1, "per_page": 25, "total": 1, "total_pages": 1 } } } } } } }, "400": { "$ref": "#/components/responses/BadRequestErrorResponse" }, "401": { "$ref": "#/components/responses/UnauthorizedErrorResponse" }, "403": { "$ref": "#/components/responses/ForbiddenErrorResponse" }, "404": { "$ref": "#/components/responses/NotFoundErrorResponse" }, "503": { "description": "Returns when the billing service is temporarily unavailable.", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ValidationErrorResponse" } } } } }, "deprecated": false } }, "/v1/billing/invoices": { "get": { "tags": [ "Billing" ], "summary": "List financial statements", "description": "Returns the auto-generated financial statements for the authenticated account, paginated and ordered by billing period.", "operationId": "billing_invoices_list", "security": [ { "bearerAuth": [ "billing:read" ] } ], "x-fern-sdk-group-name": [ "billing", "invoices" ], "x-fern-sdk-method-name": "list", "x-mcp": { "readOnly": true, "destructive": false, "openWorld": false, "expose": true }, "parameters": [ { "name": "page", "in": "query", "description": "Page number to retrieve. Default `1`.", "style": "form", "explode": true, "schema": { "type": "integer", "format": "int32", "example": 1 } }, { "name": "per_page", "in": "query", "description": "Number of records to return per page. Default `25`.", "style": "form", "explode": true, "schema": { "type": "integer", "format": "int32", "example": 25 } } ], "responses": { "200": { "description": "Returns a paginated list of financial statements.", "headers": {}, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/InvoiceListResponse" }, "examples": { "success": { "summary": "Successful response", "value": { "is_empty": false, "invoices": [ { "id": 1, "from_date": "2023-08-01", "to_date": "2023-08-31", "amount": "25.00" } ], "pagination": { "current_page": 1, "per_page": 25, "total": 1, "total_pages": 1 } } } } } } }, "400": { "$ref": "#/components/responses/BadRequestErrorResponse" }, "401": { "$ref": "#/components/responses/UnauthorizedErrorResponse" }, "403": { "$ref": "#/components/responses/ForbiddenErrorResponse" } }, "deprecated": false } }, "/v1/billing/invoices/{id}": { "get": { "tags": [ "Billing" ], "summary": "Download statement PDF", "description": "Returns the financial statement identified by `id` as a PDF file.", "operationId": "billing_invoices_download", "security": [ { "bearerAuth": [ "billing:read" ] } ], "x-fern-sdk-group-name": [ "billing", "invoices" ], "x-fern-sdk-method-name": "download", "x-mcp": { "readOnly": true, "destructive": false, "openWorld": false, "expose": false }, "parameters": [ { "name": "id", "in": "path", "description": "The unique ID of the financial statement to download.", "required": true, "style": "simple", "schema": { "type": "integer", "format": "int32", "example": 123 } } ], "responses": { "200": { "description": "Returns the financial statement as a PDF file.", "headers": {}, "content": { "application/pdf": { "schema": { "type": "string", "format": "binary" } } } }, "401": { "$ref": "#/components/responses/UnauthorizedErrorResponse" }, "403": { "$ref": "#/components/responses/ForbiddenErrorResponse" }, "404": { "$ref": "#/components/responses/NotFoundErrorResponse" } }, "deprecated": false } }, "/v1/profile": { "put": { "tags": [ "Profile" ], "summary": "Update a profile", "description": "Updates the profile and billing details of the authenticated account.", "operationId": "profile_update", "security": [ { "bearerAuth": [ "account:write" ] } ], "x-fern-sdk-group-name": [ "profile" ], "x-fern-sdk-method-name": "update", "x-mcp": { "readOnly": false, "destructive": true, "openWorld": false, "expose": true }, "parameters": [], "requestBody": { "description": "Profile and billing fields to set on the account.", "content": { "application/json": { "schema": { "allOf": [ { "$ref": "#/components/schemas/ProfileUpdateRequest" } ], "type": "object" } } }, "required": true }, "responses": { "200": { "description": "Returns the updated profile.", "headers": {}, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ProfileResponse" }, "examples": { "success": { "summary": "Successful response", "value": { "id": 1, "email": "email", "first_name": "first name", "last_name": "last name", "phone": "+12025550123", "additional_info": "additional info", "contact_email": "contact email", "timezone": "timezone", "job_title": "job title", "default_short_link_endpoint": "default short link endpoint", "default_destinations": [ { "transport": "transport", "value": "value" } ], "company_info": { "name": "name", "industry": "telecommunications", "address": "address", "attn_contact_name": "attn contact name", "vat_number": "vat number", "country": { "country_name": "country name", "country_id": 123 } } } } } } } }, "400": { "$ref": "#/components/responses/BadRequestErrorResponse" }, "401": { "$ref": "#/components/responses/UnauthorizedErrorResponse" }, "403": { "$ref": "#/components/responses/ForbiddenErrorResponse" }, "404": { "$ref": "#/components/responses/NotFoundErrorResponse" }, "422": { "$ref": "#/components/responses/ValidationErrorResponse" } }, "deprecated": false }, "get": { "tags": [ "Profile" ], "summary": "Retrieve a profile", "description": "Returns the profile and billing details of the authenticated account.", "operationId": "profile_get", "security": [ { "bearerAuth": [ "account:read" ] } ], "x-fern-sdk-group-name": [ "profile" ], "x-fern-sdk-method-name": "get", "x-mcp": { "readOnly": true, "destructive": false, "openWorld": false, "expose": true }, "parameters": [], "responses": { "200": { "description": "Returns the profile.", "headers": {}, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ProfileResponse" }, "examples": { "success": { "summary": "Successful response", "value": { "id": 1, "email": "info@awesome.com", "first_name": "example", "last_name": "example", "phone": "+12025550123", "additional_info": "example", "contact_email": "example", "timezone": "example", "job_title": "example", "default_short_link_endpoint": "example", "default_destinations": [ { "transport": "example", "value": "example" } ], "company_info": { "name": "example", "industry": "telecommunications", "address": "example", "attn_contact_name": "example", "vat_number": "example", "country": { "country_name": "example", "country_id": 123 } } } } } } } }, "400": { "$ref": "#/components/responses/BadRequestErrorResponse" }, "401": { "$ref": "#/components/responses/UnauthorizedErrorResponse" }, "403": { "$ref": "#/components/responses/ForbiddenErrorResponse" } }, "deprecated": false } }, "/v1/profile/config": { "get": { "tags": [ "Profile" ], "summary": "Retrieve account settings", "description": "Returns the balance and global limits configured for the authenticated account.", "operationId": "profile_config_get", "security": [ { "bearerAuth": [ "account:read" ] } ], "x-fern-sdk-group-name": [ "profile", "config" ], "x-fern-sdk-method-name": "get", "x-mcp": { "readOnly": true, "destructive": false, "openWorld": false, "expose": true }, "parameters": [], "responses": { "200": { "description": "Returns the account settings.", "headers": {}, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ProfileConfigResponse" }, "examples": { "default": { "value": { "balance": "309.06", "global_limits": { "max_call_duration": 3600, "max_sip_channels": 8, "max_call_rate": "99.0" } } } } } } }, "400": { "$ref": "#/components/responses/BadRequestErrorResponse" }, "401": { "$ref": "#/components/responses/UnauthorizedErrorResponse" }, "403": { "$ref": "#/components/responses/ForbiddenErrorResponse" } }, "deprecated": false } }, "/v1/sub-organizations": { "get": { "tags": [ "Sub-accounts" ], "summary": "List sub-accounts", "description": "Returns a paginated list of sub-accounts under the authenticated master account.", "operationId": "sub_accounts_list", "security": [ { "bearerAuth": [ "subaccounts:read" ] } ], "x-fern-sdk-group-name": [ "subAccounts" ], "x-fern-sdk-method-name": "list", "x-mcp": { "readOnly": true, "destructive": false, "openWorld": false, "expose": true }, "parameters": [ { "name": "status", "in": "query", "description": "Filters sub-accounts by status. One of `enabled` (the sub-account is active) or `disabled` (the sub-account is suspended).", "required": false, "style": "form", "explode": true, "schema": { "type": "string", "enum": [ "enabled", "disabled" ], "example": "enabled" } }, { "name": "page", "in": "query", "description": "Page number to retrieve. Default `1`.", "style": "form", "explode": true, "schema": { "type": "integer", "format": "int32" } }, { "name": "per_page", "in": "query", "description": "Number of records to return per page. Default `25`.", "style": "form", "explode": true, "schema": { "type": "integer", "format": "int32" } } ], "responses": { "200": { "description": "Returns a paginated list of sub-accounts.", "headers": {}, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/SubAccountsListResponse" }, "examples": { "success": { "summary": "Successful response", "value": { "sub_organizations": [ { "id": 123, "created_at": "2023-06-15T10:30:00Z", "name": "My sub-account", "api_key": "abc123def456", "master_organization": 456, "status": "enabled", "default_destinations": { "sms_endpoint": "https://examples.com/sms", "dlr_endpoint": "https://examples.com/dlr" } } ], "pagination": { "current_page": 2, "per_page": 25, "total": 123, "total_pages": 123 } } } } } } }, "401": { "$ref": "#/components/responses/UnauthorizedErrorResponse" }, "403": { "$ref": "#/components/responses/ForbiddenErrorResponse" } }, "deprecated": false }, "post": { "tags": [ "Sub-accounts" ], "summary": "Create a sub-account", "description": "Creates a sub-account under the authenticated master account. Returns the sub-account with its generated `api_key`.", "operationId": "sub_accounts_create", "security": [ { "bearerAuth": [ "subaccounts:write" ] } ], "x-fern-sdk-group-name": [ "subAccounts" ], "x-fern-sdk-method-name": "create", "x-mcp": { "readOnly": false, "destructive": true, "openWorld": false, "expose": true }, "parameters": [], "requestBody": { "description": "Attributes for the new sub-account.", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/SubAccountsCreateRequest" }, "example": { "name": "Company", "default_destinations": { "sms_endpoint": "https://examples.com/sms", "dlr_endpoint": "https://examples.com/dlr" } } } }, "required": true }, "responses": { "200": { "description": "Returns the created sub-account.", "headers": {}, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/SubOrganizationResponse" }, "examples": { "success": { "summary": "Successful response", "value": { "id": 123, "created_at": "2023-06-15T10:30:00Z", "name": "My sub-account", "api_key": "abc123def456", "master_organization": 456, "status": "enabled", "default_destinations": { "sms_endpoint": "https://examples.com/sms", "dlr_endpoint": "https://examples.com/dlr" } } } } } } }, "400": { "description": "Returns when a required parameter is missing or invalid.", "headers": {}, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ValidationErrorResponse" }, "examples": { "success": { "summary": "Successful response", "value": { "success": false, "message": "Missing or invalid parameter " } } } } } }, "401": { "$ref": "#/components/responses/UnauthorizedErrorResponse" }, "403": { "$ref": "#/components/responses/ForbiddenErrorResponse" }, "422": { "$ref": "#/components/responses/ValidationErrorResponse" } }, "deprecated": false } }, "/v1/sub-organizations/{id}": { "get": { "tags": [ "Sub-accounts" ], "summary": "Retrieve a sub-account", "description": "Returns the sub-account identified by `id`.", "operationId": "sub_accounts_get", "security": [ { "bearerAuth": [ "subaccounts:read" ] } ], "x-fern-sdk-group-name": [ "subAccounts" ], "x-fern-sdk-method-name": "get", "x-mcp": { "readOnly": true, "destructive": false, "openWorld": false, "expose": true }, "parameters": [ { "name": "id", "in": "path", "description": "The unique ID of the sub-account.", "required": true, "style": "simple", "explode": false, "schema": { "type": "integer", "format": "int32", "example": 123 } } ], "responses": { "200": { "headers": {}, "description": "Returns the sub-account.", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/SubOrganizationResponse" }, "examples": { "success": { "summary": "Successful response", "value": { "id": 123, "created_at": "2023-06-15T10:30:00Z", "name": "My sub-account", "api_key": "abc123def456", "master_organization": 456, "status": "enabled", "default_destinations": { "sms_endpoint": "https://examples.com/sms", "dlr_endpoint": "https://examples.com/dlr" } } } } } } }, "400": { "$ref": "#/components/responses/BadRequestErrorResponse" }, "401": { "$ref": "#/components/responses/UnauthorizedErrorResponse" }, "403": { "$ref": "#/components/responses/ForbiddenErrorResponse" }, "404": { "$ref": "#/components/responses/NotFoundErrorResponse" } }, "deprecated": false }, "put": { "tags": [ "Sub-accounts" ], "summary": "Update a sub-account", "description": "Updates the sub-account identified by `id`. Only the provided fields are changed.", "operationId": "sub_accounts_update", "security": [ { "bearerAuth": [ "subaccounts:write" ] } ], "x-fern-sdk-group-name": [ "subAccounts" ], "x-fern-sdk-method-name": "update", "x-mcp": { "readOnly": false, "destructive": true, "openWorld": false, "expose": true }, "parameters": [ { "name": "id", "in": "path", "description": "The unique ID of the sub-account.", "required": true, "style": "simple", "explode": false, "schema": { "type": "integer", "format": "int32", "example": 123 } } ], "requestBody": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/SubAccountsUpdateRequest" }, "example": { "name": "Updated Company Name", "status": "enabled", "default_destinations": { "sms_endpoint": "https://examples.com/sms", "dlr_endpoint": "https://examples.com/dlr" } } } }, "required": true }, "responses": { "200": { "description": "Returns the updated sub-account.", "headers": {}, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/SubOrganizationResponse" }, "examples": { "success": { "summary": "Successful response", "value": { "id": 123, "created_at": "2023-06-15T10:30:00Z", "name": "My sub-account", "api_key": "abc123def456", "master_organization": 456, "status": "enabled", "default_destinations": { "sms_endpoint": "https://examples.com/sms", "dlr_endpoint": "https://examples.com/dlr" } } } } } } }, "400": { "$ref": "#/components/responses/ValidationErrorResponse" }, "401": { "$ref": "#/components/responses/UnauthorizedErrorResponse" }, "403": { "$ref": "#/components/responses/ForbiddenErrorResponse" }, "404": { "$ref": "#/components/responses/NotFoundErrorResponse" }, "422": { "$ref": "#/components/responses/ValidationErrorResponse" } }, "deprecated": false } }, "/v1/sub-organizations/{id}/billing/transactions": { "get": { "tags": [ "Sub-accounts" ], "summary": "List sub-account transactions", "description": "Returns a paginated list of billing transactions for the sub-account identified by `id`, within the requested date range.", "operationId": "sub_accounts_transactions_list", "security": [ { "bearerAuth": [ "subaccounts:read" ] } ], "x-fern-sdk-group-name": [ "subAccounts", "transactions" ], "x-fern-sdk-method-name": "list", "x-mcp": { "readOnly": true, "destructive": false, "openWorld": false, "expose": true }, "parameters": [ { "name": "id", "in": "path", "description": "The unique ID of the sub-account.", "required": true, "style": "simple", "explode": false, "schema": { "type": "integer", "format": "int32", "example": 123 } }, { "name": "from_date", "in": "query", "required": true, "description": "Start of the date range to query, in `YYYY-MM-DD` format. Inclusive.", "style": "form", "explode": true, "schema": { "type": "string", "format": "date", "example": "2023-01-01" } }, { "name": "to_date", "in": "query", "description": "End of the date range to query, in `YYYY-MM-DD` format. Inclusive.", "required": true, "style": "form", "explode": true, "schema": { "type": "string", "format": "date", "example": "2023-12-31" } }, { "name": "type", "in": "query", "description": "Filters transactions by type. Accepts a single transaction type code or an array of codes.", "required": false, "style": "form", "explode": true, "schema": { "oneOf": [ { "title": "Single type", "type": "integer", "format": "int32", "example": 1 }, { "title": "Multiple types", "type": "array", "items": { "type": "integer", "format": "int32" }, "example": [ 1, 2, 3 ] } ] } }, { "name": "page", "in": "query", "description": "Page number to retrieve. Default `1`.", "style": "form", "explode": true, "schema": { "type": "integer", "format": "int32", "example": 1 } }, { "name": "per_page", "in": "query", "description": "Number of records to return per page. Default `25`.", "style": "form", "explode": true, "schema": { "type": "integer", "format": "int32", "default": 25, "example": 25 } } ], "responses": { "200": { "headers": {}, "description": "Returns a paginated list of sub-account transactions.", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/SubAccountsTransactionsListResponse" }, "examples": { "success": { "summary": "Successful response", "value": { "transactions": [ { "amount": 10.5, "balance_after": 100, "date": "2023-06-15T10:30:00Z", "details": "Account top-up", "status": "committed", "type": 1 } ], "pagination": { "current_page": 1, "per_page": 25, "total": 1, "total_pages": 123 } } } } } } }, "400": { "$ref": "#/components/responses/BadRequestErrorResponse" }, "401": { "$ref": "#/components/responses/UnauthorizedErrorResponse" }, "403": { "$ref": "#/components/responses/ForbiddenErrorResponse" }, "404": { "$ref": "#/components/responses/NotFoundErrorResponse" }, "503": { "description": "Returns when the transaction list is temporarily unavailable.", "headers": {}, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ValidationErrorResponse" } } } } }, "deprecated": false } }, "/v1/whatsapp/wabas": { "get": { "tags": [ "WhatsApp" ], "summary": "List WhatsApp Business Accounts", "description": "Returns a paginated list of the WhatsApp Business Accounts linked to your account, each with its messaging limit and number of senders.\n\n**Behavior:** WhatsApp Business Accounts are ordered from newest to oldest.\n\n**Requires:** Your account must have WhatsApp enabled, must have a subscription plan, and must not be blocked or suspended.", "operationId": "whatsapp_wabas_list", "security": [ { "bearerAuth": [ "whatsapp:read" ] } ], "x-fern-sdk-group-name": [ "whatsapp", "wabas" ], "x-fern-sdk-method-name": "list", "x-fern-ignore": true, "x-fern-pagination": { "offset": "$request.page", "results": "$response.wabas" }, "x-mcp": { "readOnly": true, "destructive": false, "openWorld": false, "expose": true }, "parameters": [ { "$ref": "#/components/parameters/WhatsAppPageParam" }, { "$ref": "#/components/parameters/WhatsAppPerPageParam" } ], "responses": { "200": { "description": "A paginated list of WhatsApp Business Accounts.", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/WhatsAppWabaListResponse" }, "examples": { "default": { "summary": "One WhatsApp Business Account", "value": { "wabas": [ { "id": "102290129340398", "name": "Acme Support", "messaging_limit": "up_to_2k", "sender_count": 2 } ], "pagination": { "current_page": 1, "per_page": 25, "total": 1, "total_pages": 1 } } } } } } }, "401": { "$ref": "#/components/responses/WhatsAppUnauthorizedResponse" }, "403": { "$ref": "#/components/responses/WhatsAppForbiddenResponse" }, "404": { "$ref": "#/components/responses/WhatsAppChannelUnavailableResponse" }, "429": { "$ref": "#/components/responses/WhatsAppTooManyRequestsResponse" }, "500": { "$ref": "#/components/responses/WhatsAppInternalServerErrorResponse" }, "503": { "$ref": "#/components/responses/WhatsAppServiceUnavailableResponse" } }, "deprecated": false } }, "/v1/whatsapp/wabas/{waba_id}": { "get": { "tags": [ "WhatsApp" ], "summary": "Retrieve a WhatsApp Business Account", "description": "Returns the WhatsApp Business Account linked to your account with the given ID, including its messaging limit and number of senders.\n\n**Behavior:** Returns `404` when the WhatsApp Business Account isn't linked to your account.\n\n**Requires:** Your account must have WhatsApp enabled, must have a subscription plan, and must not be blocked or suspended.", "operationId": "whatsapp_wabas_get", "security": [ { "bearerAuth": [ "whatsapp:read" ] } ], "x-fern-sdk-group-name": [ "whatsapp", "wabas" ], "x-fern-sdk-method-name": "get", "x-fern-ignore": true, "x-mcp": { "readOnly": true, "destructive": false, "openWorld": false, "expose": true }, "parameters": [ { "name": "waba_id", "in": "path", "required": true, "description": "ID of a WhatsApp Business Account linked to your account, as returned in `id` by `whatsapp_wabas_list` or in `waba.id` on senders and templates.", "schema": { "type": "string" }, "example": "102290129340398" } ], "responses": { "200": { "description": "The requested WhatsApp Business Account.", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/WhatsAppBusinessAccount" }, "examples": { "default": { "summary": "A WhatsApp Business Account", "value": { "id": "102290129340398", "name": "Acme Support", "messaging_limit": "up_to_2k", "sender_count": 2 } } } } } }, "401": { "$ref": "#/components/responses/WhatsAppUnauthorizedResponse" }, "403": { "$ref": "#/components/responses/WhatsAppForbiddenResponse" }, "404": { "description": "WhatsApp isn't available for your account or isn't enabled yet, or `waba_id` doesn't match a WhatsApp Business Account linked to your account.", "content": { "application/problem+json": { "schema": { "$ref": "#/components/schemas/WhatsAppProblem" }, "examples": { "whatsapp-not-available": { "summary": "WhatsApp is not available for this account", "value": { "type": "https://docs.wavix.com/errors/whatsapp-not-available", "title": "WhatsApp Not Available", "status": 404, "detail": "WhatsApp is not available for this account.", "instance": "3a525ca2-6909-4c72-9399-905adf7f3a74", "error_class": "permanent", "error_code": "WHATSAPP_NOT_AVAILABLE" } }, "channel-not-enabled": { "summary": "WhatsApp is not enabled yet for this account", "value": { "type": "https://docs.wavix.com/errors/channel-not-enabled", "title": "Channel Not Enabled", "status": 404, "detail": "The WhatsApp channel is not enabled for this account.", "instance": "3a525ca2-6909-4c72-9399-905adf7f3a74", "error_class": "permanent", "error_code": "CHANNEL_NOT_ENABLED" } }, "waba-not-linked": { "summary": "The WhatsApp Business Account is not linked to the account", "value": { "type": "https://docs.wavix.com/errors/waba-not-linked", "title": "WABA Not Linked", "status": 404, "detail": "WABA Not Linked", "instance": "3a525ca2-6909-4c72-9399-905adf7f3a74", "error_class": "permanent", "error_code": "WABA_NOT_LINKED" } } } } } }, "429": { "$ref": "#/components/responses/WhatsAppTooManyRequestsResponse" }, "500": { "$ref": "#/components/responses/WhatsAppInternalServerErrorResponse" }, "503": { "$ref": "#/components/responses/WhatsAppServiceUnavailableResponse" } }, "deprecated": false } }, "/v1/whatsapp/senders": { "get": { "tags": [ "WhatsApp" ], "summary": "List WhatsApp senders", "description": "Returns a paginated list of the WhatsApp senders in your account's WhatsApp Business Accounts, each with the WhatsApp Business Account it belongs to.\n\nEvery send needs a registered sender's number in `from`, and this is where that number comes from.\n\n**Behavior:** Senders are ordered from newest to oldest. When both `status` and `waba_id` are specified, a sender must match both filters.\n\n**Requires:** Your account must have WhatsApp enabled, must have a subscription plan, and must not be blocked or suspended.", "operationId": "whatsapp_senders_list", "security": [ { "bearerAuth": [ "whatsapp:read" ] } ], "x-fern-sdk-group-name": [ "whatsapp", "senders" ], "x-fern-sdk-method-name": "list", "x-fern-ignore": true, "x-fern-pagination": { "offset": "$request.page", "results": "$response.senders" }, "x-mcp": { "readOnly": true, "destructive": false, "openWorld": false, "expose": true }, "parameters": [ { "name": "status", "in": "query", "required": false, "description": "Filters senders by registration status. Possible values:\n\n- `banned` — The provider banned the sender.\n- `connected` — The sender can send messages within its messaging limit.\n- `deleted` — The sender was deleted.\n- `disconnected` — The sender is disconnected from the provider.\n- `flagged` — The sender's quality rating dropped to low. The status returns to `connected` if the rating returns to medium or high within seven days.\n- `migrated` — The sender was migrated.\n- `pending` — Registration with the provider is in progress.\n- `rate_limited` — The provider is rate limiting the sender.\n- `restricted` — The sender reached its messaging limit. It can't start new conversations until the 24-hour window resets, but it can still reply to customers who messaged it.\n- `unknown` — The provider hasn't reported a status.\n- `unverified` — The sender isn't verified.", "schema": { "type": "string", "enum": [ "banned", "connected", "deleted", "disconnected", "flagged", "migrated", "pending", "rate_limited", "restricted", "unknown", "unverified" ] }, "example": "connected" }, { "name": "waba_id", "in": "query", "required": false, "description": "Filters senders by the ID of the WhatsApp Business Account they belong to, as returned in `waba.id`.", "schema": { "type": "string" }, "example": "102290129340398" }, { "$ref": "#/components/parameters/WhatsAppPageParam" }, { "$ref": "#/components/parameters/WhatsAppPerPageParam" } ], "responses": { "200": { "description": "A paginated list of WhatsApp senders.", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/WhatsAppSenderListResponse" }, "examples": { "default": { "summary": "One connected sender", "value": { "senders": [ { "phone_number": "+14155550100", "display_name": "Acme Support", "status": "connected", "quality_rating": "high", "waba": { "id": "102290129340398", "name": "Acme Support" } } ], "pagination": { "current_page": 1, "per_page": 25, "total": 1, "total_pages": 1 } } } } } } }, "401": { "$ref": "#/components/responses/WhatsAppUnauthorizedResponse" }, "403": { "$ref": "#/components/responses/WhatsAppForbiddenResponse" }, "404": { "$ref": "#/components/responses/WhatsAppChannelUnavailableResponse" }, "429": { "$ref": "#/components/responses/WhatsAppTooManyRequestsResponse" }, "500": { "$ref": "#/components/responses/WhatsAppInternalServerErrorResponse" }, "503": { "$ref": "#/components/responses/WhatsAppServiceUnavailableResponse" } }, "deprecated": false } }, "/v1/whatsapp/senders/{number}": { "get": { "tags": [ "WhatsApp" ], "summary": "Retrieve a WhatsApp sender", "description": "Returns the WhatsApp sender registered on your account for the given phone number, including its status, quality rating, and WhatsApp Business Account.\n\nCreating a template needs a connected sender, and the sender's `status` shows whether it's connected.\n\n**Behavior:** Returns `404` when no sender on your account has this phone number.\n\n**Requires:** Your account must have WhatsApp enabled, must have a subscription plan, and must not be blocked or suspended.", "operationId": "whatsapp_senders_get", "security": [ { "bearerAuth": [ "whatsapp:read" ] } ], "x-fern-sdk-group-name": [ "whatsapp", "senders" ], "x-fern-sdk-method-name": "get", "x-fern-ignore": true, "x-mcp": { "readOnly": true, "destructive": false, "openWorld": false, "expose": true }, "parameters": [ { "name": "number", "in": "path", "required": true, "description": "Phone number of a sender on your account, in E.164 format, as returned in `phone_number` by `whatsapp_senders_list`. The leading `+` is optional.", "schema": { "type": "string", "pattern": "^\\+?\\d{6,20}$" }, "example": "14155550100" } ], "responses": { "200": { "description": "The requested WhatsApp sender.", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/WhatsAppSender" }, "examples": { "default": { "summary": "A connected sender", "value": { "phone_number": "+14155550100", "display_name": "Acme Support", "status": "connected", "quality_rating": "high", "waba": { "id": "102290129340398", "name": "Acme Support" } } } } } } }, "401": { "$ref": "#/components/responses/WhatsAppUnauthorizedResponse" }, "403": { "$ref": "#/components/responses/WhatsAppForbiddenResponse" }, "404": { "description": "WhatsApp isn't available for your account or isn't enabled yet, or `number` doesn't match one of your senders.", "content": { "application/problem+json": { "schema": { "$ref": "#/components/schemas/WhatsAppProblem" }, "examples": { "whatsapp-not-available": { "summary": "WhatsApp is not available for this account", "value": { "type": "https://docs.wavix.com/errors/whatsapp-not-available", "title": "WhatsApp Not Available", "status": 404, "detail": "WhatsApp is not available for this account.", "instance": "3a525ca2-6909-4c72-9399-905adf7f3a74", "error_class": "permanent", "error_code": "WHATSAPP_NOT_AVAILABLE" } }, "channel-not-enabled": { "summary": "WhatsApp is not enabled yet for this account", "value": { "type": "https://docs.wavix.com/errors/channel-not-enabled", "title": "Channel Not Enabled", "status": 404, "detail": "The WhatsApp channel is not enabled for this account.", "instance": "3a525ca2-6909-4c72-9399-905adf7f3a74", "error_class": "permanent", "error_code": "CHANNEL_NOT_ENABLED" } }, "sender-not-found": { "summary": "No sender matches the given number", "value": { "type": "https://docs.wavix.com/errors/sender-not-found", "title": "Sender Not Found", "status": 404, "detail": "No sender was found for that number on this account.", "instance": "3a525ca2-6909-4c72-9399-905adf7f3a74", "error_class": "permanent", "error_code": "SENDER_NOT_FOUND" } } } } } }, "429": { "$ref": "#/components/responses/WhatsAppTooManyRequestsResponse" }, "500": { "$ref": "#/components/responses/WhatsAppInternalServerErrorResponse" }, "503": { "$ref": "#/components/responses/WhatsAppServiceUnavailableResponse" } }, "deprecated": false } }, "/v1/whatsapp/templates": { "get": { "tags": [ "WhatsApp" ], "summary": "List WhatsApp templates", "description": "Returns a paginated list of the WhatsApp templates in your account's WhatsApp Business Accounts, each with its review status and components.\n\nEvery send names a template by its `name` and `language`, and this is where those values come from.\n\n**Behavior:** Templates are ordered from newest to oldest. When several filters are specified, a template must match all of them. Returns `404` when `sender` doesn't match a sender on your account.\n\n**Requires:** Your account must have WhatsApp enabled, must have a subscription plan, and must not be blocked or suspended.", "operationId": "whatsapp_templates_list", "security": [ { "bearerAuth": [ "whatsapp:read" ] } ], "x-fern-sdk-group-name": [ "whatsapp", "templates" ], "x-fern-sdk-method-name": "list", "x-fern-ignore": true, "x-fern-pagination": { "offset": "$request.page", "results": "$response.templates" }, "x-mcp": { "readOnly": true, "destructive": false, "openWorld": false, "expose": true }, "parameters": [ { "name": "waba_id", "in": "query", "required": false, "description": "Filters templates by the ID of the WhatsApp Business Account that owns them, as returned in `waba.id` by `whatsapp_senders_list`.", "schema": { "type": "string" }, "example": "102290129340398" }, { "name": "sender", "in": "query", "required": false, "description": "Filters templates by the WhatsApp Business Account of the sender with this phone number, in E.164 format. The leading `+` is optional.", "schema": { "type": "string", "pattern": "^\\+?\\d{6,20}$" }, "example": "14155550100" }, { "name": "status", "in": "query", "required": false, "description": "Filters templates by review status. Possible values:\n\n- `draft` — The template is created but not yet submitted to the provider.\n- `pending` — The provider is reviewing the template.\n- `approved` — The template is approved and can be sent.\n- `rejected` — The provider rejected the template.\n- `paused` — The provider paused the template.\n- `flagged` — The provider flagged the template. It can still be sent.\n- `disabled` — The template is disabled and can't be sent.\n- `in_appeal` — An appeal of the review decision is in progress.\n- `pending_deletion` — The template is being deleted.\n- `deleted` — The template was deleted.\n- `unknown` — The provider reported a status that Wavix doesn't recognize.", "schema": { "type": "string", "enum": [ "draft", "pending", "approved", "rejected", "paused", "flagged", "disabled", "in_appeal", "pending_deletion", "deleted", "unknown" ] }, "example": "approved" }, { "name": "name", "in": "query", "required": false, "description": "Filters templates by name.", "schema": { "type": "string" }, "example": "order_shipped" }, { "name": "language", "in": "query", "required": false, "description": "Filters templates by language code.", "schema": { "type": "string" }, "example": "en_US" }, { "$ref": "#/components/parameters/WhatsAppPageParam" }, { "$ref": "#/components/parameters/WhatsAppPerPageParam" } ], "responses": { "200": { "description": "A paginated list of WhatsApp templates.", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/WhatsAppTemplatePageResponse" }, "examples": { "default": { "summary": "One approved template", "value": { "templates": [ { "uuid": "6b1f3c52-9e0a-4d7b-8a15-c2f4e9d07b38", "name": "order_shipped", "language": "en_US", "category": "utility", "status": "approved", "quality_rating": "high", "submitted_at": "2026-01-15T10:30:00Z", "components": [ { "type": "body", "text": "Hi {{1}}, your order {{2}} has shipped.", "example": { "body_text": [ [ "Maria", "#1001" ] ] } } ], "waba": { "id": "102290129340398", "name": "Acme Support" }, "created_at": "2026-01-15T10:30:00Z" } ], "pagination": { "current_page": 1, "per_page": 25, "total": 1, "total_pages": 1 } } } } } } }, "401": { "$ref": "#/components/responses/WhatsAppUnauthorizedResponse" }, "403": { "$ref": "#/components/responses/WhatsAppForbiddenResponse" }, "404": { "description": "WhatsApp isn't available for your account or isn't enabled yet, or `sender` isn't 6–20 digits or doesn't match one of your senders.", "content": { "application/problem+json": { "schema": { "$ref": "#/components/schemas/WhatsAppProblem" }, "examples": { "whatsapp-not-available": { "summary": "WhatsApp is not available for this account", "value": { "type": "https://docs.wavix.com/errors/whatsapp-not-available", "title": "WhatsApp Not Available", "status": 404, "detail": "WhatsApp is not available for this account.", "instance": "3a525ca2-6909-4c72-9399-905adf7f3a74", "error_class": "permanent", "error_code": "WHATSAPP_NOT_AVAILABLE" } }, "channel-not-enabled": { "summary": "WhatsApp is not enabled yet for this account", "value": { "type": "https://docs.wavix.com/errors/channel-not-enabled", "title": "Channel Not Enabled", "status": 404, "detail": "The WhatsApp channel is not enabled for this account.", "instance": "3a525ca2-6909-4c72-9399-905adf7f3a74", "error_class": "permanent", "error_code": "CHANNEL_NOT_ENABLED" } }, "sender-not-found": { "summary": "No sender matches the given number", "value": { "type": "https://docs.wavix.com/errors/sender-not-found", "title": "Sender Not Found", "status": 404, "detail": "No sender was found for that number on this account.", "instance": "3a525ca2-6909-4c72-9399-905adf7f3a74", "error_class": "permanent", "error_code": "SENDER_NOT_FOUND" } } } } } }, "429": { "$ref": "#/components/responses/WhatsAppTooManyRequestsResponse" }, "500": { "$ref": "#/components/responses/WhatsAppInternalServerErrorResponse" }, "503": { "$ref": "#/components/responses/WhatsAppServiceUnavailableResponse" } }, "deprecated": false }, "post": { "tags": [ "WhatsApp" ], "summary": "Create a WhatsApp template", "description": "Creates a WhatsApp template in one of your account's WhatsApp Business Accounts, submits it for review, and returns the new template.\n\nEvery WhatsApp message you send uses a template, so new message content starts with a new template.\n\n**Behavior:** Returns `201` with the new template. Poll `whatsapp_templates_get` for the review outcome. Returns `409` when the WhatsApp Business Account already has a template with the same `name` and `language`.\n\n**Requires:** Your account must have WhatsApp and its templates capability enabled, must have a subscription plan, and must not be blocked or suspended. The WhatsApp Business Account must have a connected sender; when your account has more than one WhatsApp Business Account, specify `waba_id` or `sender`.", "operationId": "whatsapp_templates_create", "security": [ { "bearerAuth": [ "whatsapp:write" ] } ], "x-fern-sdk-group-name": [ "whatsapp", "templates" ], "x-fern-sdk-method-name": "create", "x-fern-ignore": true, "x-mcp": { "readOnly": false, "destructive": false, "openWorld": true, "expose": true }, "parameters": [], "requestBody": { "description": "Attributes of the template to create.", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/WhatsAppTemplateCreateRequest" }, "examples": { "default": { "summary": "Order shipment template with a body and a footer", "value": { "name": "order_shipped", "language": "en_US", "category": "utility", "sender": "14155550100", "components": [ { "type": "body", "text": "Hi {{1}}, your order {{2}} has shipped.", "example": { "body_text": [ [ "Maria", "#1001" ] ] } }, { "type": "footer", "text": "Reply STOP to unsubscribe." } ] } } } } }, "required": true }, "responses": { "201": { "description": "The created WhatsApp template.", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/WhatsAppTemplateResponse" }, "examples": { "default": { "summary": "Created template", "value": { "template": { "uuid": "6b1f3c52-9e0a-4d7b-8a15-c2f4e9d07b38", "name": "order_shipped", "language": "en_US", "category": "utility", "status": "draft", "quality_rating": null, "components": [ { "type": "body", "text": "Hi {{1}}, your order {{2}} has shipped.", "example": { "body_text": [ [ "Maria", "#1001" ] ] } }, { "type": "footer", "text": "Reply STOP to unsubscribe." } ], "waba": { "id": "102290129340398", "name": "Acme Support" }, "created_at": "2026-01-15T10:30:00Z" } } } } } } }, "400": { "description": "The body is invalid. The JSON is malformed, a required field is missing or empty, `sender` doesn't belong to `waba_id`, or you have several WhatsApp Business Accounts and specified neither `waba_id` nor `sender`. The `detail` field says which.", "content": { "application/problem+json": { "schema": { "$ref": "#/components/schemas/WhatsAppProblem" }, "examples": { "invalid-request": { "value": { "type": "https://docs.wavix.com/errors/invalid-request", "title": "Invalid Request", "status": 400, "detail": "the account has several WhatsApp Business Accounts; pass waba_id or sender to choose one (list them with GET /v1/whatsapp/senders)", "instance": "3a525ca2-6909-4c72-9399-905adf7f3a74", "error_class": "permanent", "error_code": "INVALID_REQUEST" } } } } } }, "401": { "$ref": "#/components/responses/WhatsAppUnauthorizedResponse" }, "403": { "description": "Returns when the API key doesn't have the scope the endpoint needs, the request isn't allowed for the account's region, or the templates capability is not enabled for the account.", "content": { "application/problem+json": { "schema": { "$ref": "#/components/schemas/WhatsAppProblem" }, "examples": { "capability-missing": { "summary": "The templates capability is not enabled", "value": { "type": "https://docs.wavix.com/errors/capability-missing", "title": "Capability Missing", "status": 403, "detail": "The templates capability is not enabled for this account.", "instance": "3a525ca2-6909-4c72-9399-905adf7f3a74", "error_class": "permanent", "error_code": "CAPABILITY_MISSING" } } } } } }, "404": { "description": "WhatsApp isn't available for your account or isn't enabled yet. Or `waba_id` isn't linked to your account, or you have no WhatsApp Business Account and omitted `waba_id`. Or `sender` isn't 6–20 digits, isn't a sender of your account, or isn't connected. Or the WhatsApp Business Account has no connected sender.", "content": { "application/problem+json": { "schema": { "$ref": "#/components/schemas/WhatsAppProblem" }, "examples": { "whatsapp-not-available": { "summary": "WhatsApp is not available for this account", "value": { "type": "https://docs.wavix.com/errors/whatsapp-not-available", "title": "WhatsApp Not Available", "status": 404, "detail": "WhatsApp is not available for this account.", "instance": "3a525ca2-6909-4c72-9399-905adf7f3a74", "error_class": "permanent", "error_code": "WHATSAPP_NOT_AVAILABLE" } }, "channel-not-enabled": { "summary": "WhatsApp is not enabled yet for this account", "value": { "type": "https://docs.wavix.com/errors/channel-not-enabled", "title": "Channel Not Enabled", "status": 404, "detail": "The WhatsApp channel is not enabled for this account.", "instance": "3a525ca2-6909-4c72-9399-905adf7f3a74", "error_class": "permanent", "error_code": "CHANNEL_NOT_ENABLED" } }, "waba-not-linked": { "summary": "The WhatsApp Business Account is not linked to the account", "value": { "type": "https://docs.wavix.com/errors/waba-not-linked", "title": "WABA Not Linked", "status": 404, "detail": "WABA Not Linked", "instance": "3a525ca2-6909-4c72-9399-905adf7f3a74", "error_class": "permanent", "error_code": "WABA_NOT_LINKED" } }, "sender-not-found": { "summary": "The sender isn't connected", "value": { "type": "https://docs.wavix.com/errors/sender-not-found", "title": "Sender Not Found", "status": 404, "detail": "sender 14155550100 is not connected", "instance": "3a525ca2-6909-4c72-9399-905adf7f3a74", "error_class": "permanent", "error_code": "SENDER_NOT_FOUND" } }, "no-connected-sender": { "summary": "The WhatsApp Business Account has no connected sender", "value": { "type": "https://docs.wavix.com/errors/sender-not-found", "title": "Sender Not Found", "status": 404, "detail": "no connected sender on WhatsApp Business Account 102290129340398", "instance": "3a525ca2-6909-4c72-9399-905adf7f3a74", "error_class": "permanent", "error_code": "SENDER_NOT_FOUND" } } } } } }, "409": { "description": "A template with this name and language already exists for the WhatsApp Business Account.", "content": { "application/problem+json": { "schema": { "$ref": "#/components/schemas/WhatsAppProblem" }, "examples": { "template-already-exists": { "value": { "type": "https://docs.wavix.com/errors/template-already-exists", "title": "Template Already Exists", "status": 409, "detail": "templates: order_shipped/en_US already exists for this sender with status approved", "instance": "3a525ca2-6909-4c72-9399-905adf7f3a74", "error_class": "permanent", "error_code": "TEMPLATE_ALREADY_EXISTS" } } } } } }, "422": { "description": "The template content is invalid. A component or button has an unknown or missing key or an unknown type, `components` is empty, or `name`, `language`, or `category` has an invalid value. The `detail` field names the field that's wrong.", "content": { "application/problem+json": { "schema": { "$ref": "#/components/schemas/WhatsAppProblem" }, "examples": { "template-invalid": { "value": { "type": "https://docs.wavix.com/errors/template-invalid", "title": "Template Invalid", "status": 422, "detail": "components[0]: unknown key \"foo\"", "instance": "3a525ca2-6909-4c72-9399-905adf7f3a74", "error_class": "invalid_template", "error_code": "TEMPLATE_INVALID" } } } } } }, "429": { "$ref": "#/components/responses/WhatsAppTooManyRequestsResponse" }, "500": { "$ref": "#/components/responses/WhatsAppInternalServerErrorResponse" }, "503": { "$ref": "#/components/responses/WhatsAppServiceUnavailableResponse" } }, "deprecated": false } }, "/v1/whatsapp/templates/{uuid}": { "get": { "tags": [ "WhatsApp" ], "summary": "Retrieve a WhatsApp template", "description": "Returns the WhatsApp template with the given ID, including its review status, components, and WhatsApp Business Account.\n\nA new template's review outcome isn't known when `whatsapp_templates_create` returns, so the `approved` or `rejected` status shows up here.\n\n**Behavior:** Returns `404` when no template with this ID belongs to your account's WhatsApp Business Accounts.\n\n**Requires:** Your account must have WhatsApp enabled, must have a subscription plan, and must not be blocked or suspended.", "operationId": "whatsapp_templates_get", "security": [ { "bearerAuth": [ "whatsapp:read" ] } ], "x-fern-sdk-group-name": [ "whatsapp", "templates" ], "x-fern-sdk-method-name": "get", "x-fern-ignore": true, "x-mcp": { "readOnly": true, "destructive": false, "openWorld": false, "expose": true }, "parameters": [ { "name": "uuid", "in": "path", "required": true, "description": "ID of the template, as returned in `uuid` by `whatsapp_templates_create` or `whatsapp_templates_list`.", "schema": { "type": "string", "format": "uuid" }, "example": "6b1f3c52-9e0a-4d7b-8a15-c2f4e9d07b38" } ], "responses": { "200": { "description": "The requested WhatsApp template.", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/WhatsAppTemplateResponse" }, "examples": { "default": { "summary": "An approved template", "value": { "template": { "uuid": "6b1f3c52-9e0a-4d7b-8a15-c2f4e9d07b38", "name": "order_shipped", "language": "en_US", "category": "utility", "status": "approved", "quality_rating": "high", "submitted_at": "2026-01-15T10:30:00Z", "components": [ { "type": "body", "text": "Hi {{1}}, your order {{2}} has shipped.", "example": { "body_text": [ [ "Maria", "#1001" ] ] } } ], "waba": { "id": "102290129340398", "name": "Acme Support" }, "created_at": "2026-01-15T10:30:00Z" } } } } } } }, "401": { "$ref": "#/components/responses/WhatsAppUnauthorizedResponse" }, "403": { "$ref": "#/components/responses/WhatsAppForbiddenResponse" }, "404": { "description": "WhatsApp isn't available for your account or isn't enabled yet, or no template with this ID belongs to your account.", "content": { "application/problem+json": { "schema": { "$ref": "#/components/schemas/WhatsAppProblem" }, "examples": { "whatsapp-not-available": { "summary": "WhatsApp is not available for this account", "value": { "type": "https://docs.wavix.com/errors/whatsapp-not-available", "title": "WhatsApp Not Available", "status": 404, "detail": "WhatsApp is not available for this account.", "instance": "3a525ca2-6909-4c72-9399-905adf7f3a74", "error_class": "permanent", "error_code": "WHATSAPP_NOT_AVAILABLE" } }, "channel-not-enabled": { "summary": "WhatsApp is not enabled yet for this account", "value": { "type": "https://docs.wavix.com/errors/channel-not-enabled", "title": "Channel Not Enabled", "status": 404, "detail": "The WhatsApp channel is not enabled for this account.", "instance": "3a525ca2-6909-4c72-9399-905adf7f3a74", "error_class": "permanent", "error_code": "CHANNEL_NOT_ENABLED" } }, "template-not-found": { "summary": "No template matches the given ID", "value": { "type": "https://docs.wavix.com/errors/template-not-found", "title": "Template Not Found", "status": 404, "detail": "No template was found for that ID.", "instance": "3a525ca2-6909-4c72-9399-905adf7f3a74", "error_class": "permanent", "error_code": "TEMPLATE_NOT_FOUND" } } } } } }, "429": { "$ref": "#/components/responses/WhatsAppTooManyRequestsResponse" }, "500": { "$ref": "#/components/responses/WhatsAppInternalServerErrorResponse" }, "503": { "$ref": "#/components/responses/WhatsAppServiceUnavailableResponse" } }, "deprecated": false } }, "/v1/whatsapp/messages": { "post": { "tags": [ "WhatsApp" ], "summary": "Send a WhatsApp message", "description": "Sends a WhatsApp message from one of your registered senders to a recipient, and returns the message with its ID.\n\nA message is either a template, named in `template`, or free-form, given in `content`. Send exactly one of the two. A template can be sent at any time. A free-form message can be sent only while the 24-hour service window of the recipient is open, that is, within 24 hours of the last message the recipient sent to the sender. A message sent with `content` is charged at the service rate. A template message is charged at its category's rate, inside the window too.\n\n**Behavior:** Returns `201` with the new message. Poll `whatsapp_messages_get` for the delivery outcome. A repeat send with the same `idempotency_key` returns `200` with the original message and sends nothing. Returns `422` when `content` is sent and the service window is closed. The response then carries `service_window_closed_at`.\n\n**Requires:** Your account must have WhatsApp and its sending capability enabled, must have a subscription plan, and must not be blocked or suspended. `from` must be a sender registered on your account.", "operationId": "whatsapp_messages_send", "security": [ { "bearerAuth": [ "whatsapp:write" ] } ], "x-fern-sdk-group-name": [ "whatsapp", "messages" ], "x-fern-sdk-method-name": "send", "x-fern-ignore": true, "x-mcp": { "readOnly": false, "destructive": true, "openWorld": true, "expose": true }, "parameters": [], "requestBody": { "description": "Attributes of the message to send.", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/WhatsAppMessageSendRequest" }, "examples": { "default": { "summary": "Shipment notification from a template", "value": { "from": "+14155550100", "to": "+447537151866", "idempotency_key": "order-1001-shipped", "template": { "name": "order_shipped", "language": "en_US", "placeholders": [ "Maria", "#1001" ] } } }, "content": { "summary": "Free-form text inside the service window", "value": { "from": "+14155550100", "to": "+447537151866", "idempotency_key": "order-1001-reply", "content": { "type": "text", "text": "Your order ships tomorrow morning." } } } } } }, "required": true }, "responses": { "200": { "description": "The message created by the earlier send with the same `idempotency_key`.", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/WhatsAppMessageSendResponse" }, "examples": { "default": { "summary": "Original message of a repeated send", "value": { "message": { "uuid": "3a525ca2-6909-4c72-9399-905adf7f3a74", "from": "+14155550100", "to": "+447537151866", "status": "delivered", "template": { "name": "order_shipped", "language": "en_US" }, "created_at": "2026-01-15T10:30:00.123Z", "service_window_open_until": "2026-01-16T09:15:00.000Z" } } } } } } }, "201": { "description": "The new message, with its `uuid` and initial status.", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/WhatsAppMessageSendResponse" }, "examples": { "default": { "summary": "New message", "value": { "message": { "uuid": "3a525ca2-6909-4c72-9399-905adf7f3a74", "from": "+14155550100", "to": "+447537151866", "status": "sent", "template": { "name": "order_shipped", "language": "en_US" }, "created_at": "2026-01-15T10:30:00.123Z", "service_window_open_until": "2026-01-16T09:15:00.000Z" } } } } } } }, "400": { "description": "The body is invalid. A required field is missing or unknown, `from` or `to` isn't a valid phone number, `idempotency_key` is longer than 128 characters or begins with `campaign:`, a `header` or `buttons` entry has a missing or unsupported field, both or neither of `template` and `content` are sent, or a `content` field is over its limit.", "content": { "application/problem+json": { "schema": { "$ref": "#/components/schemas/WhatsAppProblem" }, "examples": { "invalid-request": { "value": { "type": "https://docs.wavix.com/errors/invalid-request", "title": "Invalid Request", "status": 400, "detail": "phone numbers must be 6-20 digits, with or without a leading +", "instance": "3a525ca2-6909-4c72-9399-905adf7f3a74", "error_class": "permanent", "error_code": "INVALID_REQUEST" } } } } } }, "401": { "$ref": "#/components/responses/WhatsAppUnauthorizedResponse" }, "403": { "description": "Returns when the API key doesn't have the scope the endpoint needs, the request isn't allowed for the account's region, or the sending capability is not enabled for the account.", "content": { "application/problem+json": { "schema": { "$ref": "#/components/schemas/WhatsAppProblem" }, "examples": { "capability-missing": { "summary": "The sending capability is not enabled", "value": { "type": "https://docs.wavix.com/errors/capability-missing", "title": "Capability Missing", "status": 403, "detail": "The sending capability is not enabled for this account.", "instance": "3a525ca2-6909-4c72-9399-905adf7f3a74", "error_class": "permanent", "error_code": "CAPABILITY_MISSING" } } } } } }, "404": { "description": "WhatsApp isn't available for your account or isn't enabled yet, or `from` doesn't match one of your senders.", "content": { "application/problem+json": { "schema": { "$ref": "#/components/schemas/WhatsAppProblem" }, "examples": { "whatsapp-not-available": { "summary": "WhatsApp is not available for this account", "value": { "type": "https://docs.wavix.com/errors/whatsapp-not-available", "title": "WhatsApp Not Available", "status": 404, "detail": "WhatsApp is not available for this account.", "instance": "3a525ca2-6909-4c72-9399-905adf7f3a74", "error_class": "permanent", "error_code": "WHATSAPP_NOT_AVAILABLE" } }, "channel-not-enabled": { "summary": "WhatsApp is not enabled yet for this account", "value": { "type": "https://docs.wavix.com/errors/channel-not-enabled", "title": "Channel Not Enabled", "status": 404, "detail": "The WhatsApp channel is not enabled for this account.", "instance": "3a525ca2-6909-4c72-9399-905adf7f3a74", "error_class": "permanent", "error_code": "CHANNEL_NOT_ENABLED" } }, "sender-not-found": { "summary": "No sender matches `from`", "value": { "type": "https://docs.wavix.com/errors/sender-not-found", "title": "Sender Not Found", "status": 404, "detail": "no sender \"14155550100\" on channel \"whatsapp\"", "instance": "3a525ca2-6909-4c72-9399-905adf7f3a74", "error_class": "permanent", "error_code": "SENDER_NOT_FOUND" } } } } } }, "422": { "description": "The service window is closed. The recipient hasn't messaged this sender in the last 24 hours, so `content` can't be sent. Send a template instead.", "content": { "application/problem+json": { "schema": { "$ref": "#/components/schemas/WhatsAppProblem" }, "examples": { "service-window-closed": { "summary": "The service window is closed", "value": { "type": "https://docs.wavix.com/errors/service-window-closed", "title": "Service Window Closed", "status": 422, "detail": "The recipient hasn't messaged this sender in the last 24 hours. Send a template instead.", "instance": "3a525ca2-6909-4c72-9399-905adf7f3a74", "error_class": "permanent", "error_code": "SERVICE_WINDOW_CLOSED", "service_window_closed_at": "2026-01-14T09:15:00.000Z" } } } } } }, "429": { "$ref": "#/components/responses/WhatsAppTooManyRequestsResponse" }, "500": { "$ref": "#/components/responses/WhatsAppInternalServerErrorResponse" }, "503": { "$ref": "#/components/responses/WhatsAppServiceUnavailableResponse" } }, "deprecated": false }, "get": { "tags": [ "WhatsApp" ], "summary": "List WhatsApp messages", "description": "Returns a paginated list of the WhatsApp messages your account sent and received, each with its direction, delivery status, and phone numbers, and the content of the messages customers sent.\n\nMessages that customers send to your senders appear here alongside the messages you sent.\n\n**Behavior:** Messages are ordered from newest to oldest. If `direction` isn't specified, the response includes both directions, and when several filters are specified, a message must match all of them. Returns `400` when `direction`, `from`, or `to` isn't valid.\n\n**Requires:** Your account must have WhatsApp enabled, must have a subscription plan, and must not be blocked or suspended.", "operationId": "whatsapp_messages_list", "security": [ { "bearerAuth": [ "whatsapp:read" ] } ], "x-fern-sdk-group-name": [ "whatsapp", "messages" ], "x-fern-sdk-method-name": "list", "x-fern-ignore": true, "x-fern-pagination": { "offset": "$request.page", "results": "$response.messages" }, "x-mcp": { "readOnly": true, "destructive": false, "openWorld": false, "expose": true }, "parameters": [ { "name": "direction", "in": "query", "required": false, "description": "Filters messages by direction. Possible values:\n\n- `outbound` — The message was sent from your account to a recipient.\n- `inbound` — A customer sent the message to one of your senders.", "schema": { "type": "string", "enum": [ "outbound", "inbound" ] }, "example": "outbound" }, { "name": "status", "in": "query", "required": false, "description": "Filters messages by delivery status. A filter matches that status only, so `delivered` doesn't include `read` messages. Inbound messages always have `delivered` status. Possible values:\n\n- `sent` — The message isn't delivered yet.\n- `delivered` — The message was delivered to the recipient.\n- `read` — The recipient opened the message. WhatsApp reports it only when the recipient has read receipts turned on.\n- `undelivered` — The message was sent but not delivered.\n- `expired` — The message expired before it was delivered.\n- `rejected` — The message was permanently rejected before or by the provider.\n- `unknown` — The provider hasn't reported a status.", "schema": { "type": "string", "enum": [ "sent", "delivered", "read", "undelivered", "expired", "rejected", "unknown" ] }, "example": "delivered" }, { "name": "from", "in": "query", "required": false, "description": "Filters messages by the `from` phone number, in E.164 format. The leading `+` is optional.", "schema": { "type": "string", "pattern": "^\\+?\\d{6,20}$" }, "example": "+14155550100" }, { "name": "to", "in": "query", "required": false, "description": "Filters messages by the `to` phone number, in E.164 format. The leading `+` is optional.", "schema": { "type": "string", "pattern": "^\\+?\\d{6,20}$" }, "example": "+447537151866" }, { "name": "from_date", "in": "query", "required": false, "description": "Filters messages to those created on or after the start of this date in your account's time zone, in `YYYY-MM-DD` format.", "schema": { "type": "string", "format": "date" }, "example": "2026-01-01" }, { "name": "to_date", "in": "query", "required": false, "description": "Filters messages to those created on or before the end of this date in your account's time zone, in `YYYY-MM-DD` format.", "schema": { "type": "string", "format": "date" }, "example": "2026-01-31" }, { "$ref": "#/components/parameters/WhatsAppPageParam" }, { "$ref": "#/components/parameters/WhatsAppPerPageParam" } ], "responses": { "200": { "description": "A paginated list of WhatsApp messages.", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/WhatsAppMessageListResponse" }, "examples": { "default": { "summary": "One outbound and one inbound message", "value": { "messages": [ { "uuid": "9d4e1c7a-2b86-4f3d-b5a0-71e8c3f6a924", "direction": "inbound", "status": "delivered", "from": "+447537151866", "to": "+14155550100", "country": "GB", "created_at": "2026-01-15T10:45:00.456Z", "content": { "type": "text", "text": "Hi, is my order on its way?" }, "service_window_open_until": "2026-01-16T10:45:00.456Z" }, { "uuid": "3a525ca2-6909-4c72-9399-905adf7f3a74", "direction": "outbound", "status": "delivered", "from": "+14155550100", "to": "+447537151866", "country": "GB", "created_at": "2026-01-15T10:30:00.123Z", "content": null, "service_window_open_until": "2026-01-16T10:45:00.456Z" } ], "pagination": { "current_page": 1, "per_page": 25, "total": 2, "total_pages": 1 } } } } } } }, "400": { "$ref": "#/components/responses/WhatsAppBadRequestResponse" }, "401": { "$ref": "#/components/responses/WhatsAppUnauthorizedResponse" }, "403": { "$ref": "#/components/responses/WhatsAppForbiddenResponse" }, "404": { "$ref": "#/components/responses/WhatsAppChannelUnavailableResponse" }, "429": { "$ref": "#/components/responses/WhatsAppTooManyRequestsResponse" }, "500": { "$ref": "#/components/responses/WhatsAppInternalServerErrorResponse" }, "503": { "$ref": "#/components/responses/WhatsAppServiceUnavailableResponse" } }, "deprecated": false } }, "/v1/whatsapp/messages/{uuid}": { "get": { "tags": [ "WhatsApp" ], "summary": "Retrieve a WhatsApp message", "description": "Returns the WhatsApp message with the given ID, sent or received, including its direction, current delivery status, and, for a message a customer sent, its content.\n\nThe send response carries only the initial status, so the delivered, read, or undelivered outcome shows up here.\n\n**Behavior:** Returns `404` when no message with this ID belongs to your account.\n\n**Requires:** Your account must have WhatsApp enabled, must have a subscription plan, and must not be blocked or suspended.", "operationId": "whatsapp_messages_get", "security": [ { "bearerAuth": [ "whatsapp:read" ] } ], "x-fern-sdk-group-name": [ "whatsapp", "messages" ], "x-fern-sdk-method-name": "get", "x-fern-ignore": true, "x-mcp": { "readOnly": true, "destructive": false, "openWorld": false, "expose": true }, "parameters": [ { "name": "uuid", "in": "path", "required": true, "description": "ID of the message, as returned in `uuid` by `whatsapp_messages_send` or `whatsapp_messages_list`.", "schema": { "type": "string", "format": "uuid" }, "example": "3a525ca2-6909-4c72-9399-905adf7f3a74" } ], "responses": { "200": { "description": "The requested WhatsApp message.", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/WhatsAppMessageGetResponse" }, "examples": { "default": { "summary": "A delivered outbound message", "value": { "message": { "uuid": "3a525ca2-6909-4c72-9399-905adf7f3a74", "direction": "outbound", "status": "delivered", "from": "+14155550100", "to": "+447537151866", "country": "GB", "created_at": "2026-01-15T10:30:00.123Z", "content": null, "service_window_open_until": "2026-01-16T10:45:00.456Z", "error": null } } }, "undelivered-template": { "summary": "An outbound message that wasn't delivered", "value": { "message": { "uuid": "5b8f2d4e-7a1c-4e9b-8d3f-6c2a9e1b4f70", "direction": "outbound", "status": "undelivered", "from": "+14155550100", "to": "+447537151866", "country": "GB", "created_at": "2026-01-15T11:02:00.000Z", "content": null, "service_window_open_until": null, "error": { "code": "DELIVERY_FAILED", "subcode": "TEMPLATE_INVALID", "message": "The template is invalid or doesn't match its approved version.", "action": "fix_and_resend", "docs_url": "https://docs.wavix.com/errors/delivery-failed" } } } }, "inbound-image": { "summary": "An image a customer sent", "value": { "message": { "uuid": "9d4e1c7a-2b86-4f3d-b5a0-71e8c3f6a924", "direction": "inbound", "status": "delivered", "from": "+447537151866", "to": "+14155550100", "country": "GB", "created_at": "2026-01-15T10:45:00.456Z", "content": { "type": "image", "media_id": "7f3e2c1a-5b9d-4e8f-a1c3-2d4e6f8a0b1c", "media_url": "https://api.wavix.com/v1/whatsapp/media/7f3e2c1a-5b9d-4e8f-a1c3-2d4e6f8a0b1c", "mime_type": "image/jpeg" }, "service_window_open_until": "2026-01-16T10:45:00.456Z" } } } } } } }, "401": { "$ref": "#/components/responses/WhatsAppUnauthorizedResponse" }, "403": { "$ref": "#/components/responses/WhatsAppForbiddenResponse" }, "404": { "description": "WhatsApp isn't available for your account or isn't enabled yet, or no message with this ID belongs to your account.", "content": { "application/problem+json": { "schema": { "$ref": "#/components/schemas/WhatsAppProblem" }, "examples": { "whatsapp-not-available": { "summary": "WhatsApp is not available for this account", "value": { "type": "https://docs.wavix.com/errors/whatsapp-not-available", "title": "WhatsApp Not Available", "status": 404, "detail": "WhatsApp is not available for this account.", "instance": "3a525ca2-6909-4c72-9399-905adf7f3a74", "error_class": "permanent", "error_code": "WHATSAPP_NOT_AVAILABLE" } }, "channel-not-enabled": { "summary": "WhatsApp is not enabled yet for this account", "value": { "type": "https://docs.wavix.com/errors/channel-not-enabled", "title": "Channel Not Enabled", "status": 404, "detail": "The WhatsApp channel is not enabled for this account.", "instance": "3a525ca2-6909-4c72-9399-905adf7f3a74", "error_class": "permanent", "error_code": "CHANNEL_NOT_ENABLED" } }, "resource-not-found": { "summary": "No message matches the given uuid", "value": { "type": "https://docs.wavix.com/errors/resource-not-found", "title": "Resource Not Found", "status": 404, "detail": "Resource Not Found", "instance": "3a525ca2-6909-4c72-9399-905adf7f3a74", "error_class": "permanent", "error_code": "RESOURCE_NOT_FOUND" } } } } } }, "429": { "$ref": "#/components/responses/WhatsAppTooManyRequestsResponse" }, "500": { "$ref": "#/components/responses/WhatsAppInternalServerErrorResponse" }, "503": { "$ref": "#/components/responses/WhatsAppServiceUnavailableResponse" } }, "deprecated": false } }, "/v1/whatsapp/webhooks": { "post": { "tags": [ "WhatsApp" ], "summary": "Create a WhatsApp webhook", "description": "Registers a webhook that receives one group of your account's WhatsApp events and returns it with its signing secret.\n\nCreate a webhook for each group of events you need, with the same URL or different ones, so your server learns about these events without polling.\n\n**Behavior:** Returns `201` with the new webhook. The `secret` can't be retrieved later; to replace it, delete the webhook and create a new one. The webhook receives only events that Wavix records after it's created; read earlier ones with [List WhatsApp events](https://docs.wavix.com/api-reference/whatsapp/list-whatsapp-events).\n\n**Requires:** Your account must have the WhatsApp channel enabled, must have a subscription plan, and must not be blocked or suspended.", "operationId": "whatsapp_webhooks_create", "security": [ { "bearerAuth": [ "whatsapp:write" ] } ], "x-fern-sdk-group-name": [ "whatsapp", "webhooks" ], "x-fern-sdk-method-name": "create", "x-fern-ignore": true, "x-mcp": { "readOnly": false, "destructive": false, "openWorld": true, "expose": true }, "parameters": [], "requestBody": { "description": "Attributes of the webhook to create.", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/WhatsAppWebhookCreateRequest" }, "examples": { "default": { "summary": "Webhook for message events", "value": { "url": "https://example.com/wavix", "group": "messages" } } } } }, "required": true }, "responses": { "201": { "description": "The created WhatsApp webhook, including its `secret`.", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/WhatsAppWebhookResponse" }, "examples": { "default": { "summary": "Created webhook", "value": { "webhook": { "uuid": "6f1c2a4e-8b3d-4c5e-9f70-1a2b3c4d5e6f", "url": "https://example.com/wavix", "group": "messages", "enabled": true, "enabled_events": [ "whatsapp.message.received", "whatsapp.message.sent", "whatsapp.message.delivered", "whatsapp.message.read", "whatsapp.message.failed", "whatsapp.contact.marketing_stopped", "whatsapp.contact.marketing_resumed" ], "created_at": "2026-10-21T12:00:00Z", "secret": "whsec_AQIDBAUGBwgJCgsMDQ4PEBESExQVFhcYGRobHB0eHyA=" } } } } } } }, "400": { "description": "The body is invalid. The JSON is malformed or empty, a field is unknown or `null`, `url` or `group` is missing, or `group` has an unsupported value. The `detail` field says which.", "content": { "application/problem+json": { "schema": { "$ref": "#/components/schemas/WhatsAppProblem" }, "examples": { "invalid-request": { "summary": "The body has an unknown field", "value": { "type": "https://docs.wavix.com/errors/invalid-request", "title": "Invalid Request", "status": 400, "detail": "The request body has an unknown field: \"events\".", "instance": "3a525ca2-6909-4c72-9399-905adf7f3a74", "error_class": "permanent", "error_code": "INVALID_REQUEST" } } } } } }, "401": { "$ref": "#/components/responses/WhatsAppUnauthorizedResponse" }, "403": { "$ref": "#/components/responses/WhatsAppForbiddenResponse" }, "404": { "description": "WhatsApp isn't available for your account or isn't enabled yet.", "content": { "application/problem+json": { "schema": { "$ref": "#/components/schemas/WhatsAppProblem" }, "examples": { "whatsapp-not-available": { "summary": "WhatsApp is not available for this account", "value": { "type": "https://docs.wavix.com/errors/whatsapp-not-available", "title": "WhatsApp Not Available", "status": 404, "detail": "WhatsApp is not available for this account.", "instance": "3a525ca2-6909-4c72-9399-905adf7f3a74", "error_class": "permanent", "error_code": "WHATSAPP_NOT_AVAILABLE" } }, "channel-not-enabled": { "summary": "WhatsApp is not enabled yet for this account", "value": { "type": "https://docs.wavix.com/errors/channel-not-enabled", "title": "Channel Not Enabled", "status": 404, "detail": "The WhatsApp channel is not enabled for this account.", "instance": "3a525ca2-6909-4c72-9399-905adf7f3a74", "error_class": "permanent", "error_code": "CHANNEL_NOT_ENABLED" } } } } } }, "409": { "description": "Your account already has a webhook for this group. Change its URL with [Update a WhatsApp webhook](https://docs.wavix.com/api-reference/whatsapp/update-a-whatsapp-webhook) instead.", "content": { "application/problem+json": { "schema": { "$ref": "#/components/schemas/WhatsAppProblem" }, "examples": { "webhook-already-exists": { "summary": "The account already has a webhook for this group", "value": { "type": "https://docs.wavix.com/errors/webhook-already-exists", "title": "Webhook Already Exists", "status": 409, "detail": "Webhook Already Exists", "instance": "3a525ca2-6909-4c72-9399-905adf7f3a74", "error_class": "permanent", "error_code": "WEBHOOK_ALREADY_EXISTS" } } } } } }, "413": { "description": "The request body is over 16 KiB.", "content": { "application/problem+json": { "schema": { "$ref": "#/components/schemas/WhatsAppProblem" }, "examples": { "payload-too-large": { "summary": "The request body exceeds the size limit", "value": { "type": "https://docs.wavix.com/errors/payload-too-large", "title": "Payload Too Large", "status": 413, "detail": "The request body is too large.", "instance": "3a525ca2-6909-4c72-9399-905adf7f3a74", "error_class": "permanent", "error_code": "PAYLOAD_TOO_LARGE" } } } } } }, "422": { "description": "`url` isn't an `https` URL without credentials, is longer than 2,048 bytes, or has a host with no address, or resolves to an address that isn't public or that Wavix doesn't allow. The `detail` field says which.", "content": { "application/problem+json": { "schema": { "$ref": "#/components/schemas/WhatsAppProblem" }, "examples": { "invalid-webhook-url": { "summary": "The URL isn't a public https URL", "value": { "type": "https://docs.wavix.com/errors/invalid-webhook-url", "title": "Invalid Webhook URL", "status": 422, "detail": "The URL host resolves to an address that is not public or that Wavix does not allow.", "instance": "3a525ca2-6909-4c72-9399-905adf7f3a74", "error_class": "permanent", "error_code": "INVALID_WEBHOOK_URL" } } } } } }, "500": { "$ref": "#/components/responses/WhatsAppInternalServerErrorResponse" }, "503": { "description": "The service is temporarily unavailable, or the lookup of the host of `url` failed. The request may be retried.", "content": { "application/problem+json": { "schema": { "$ref": "#/components/schemas/WhatsAppProblem" }, "examples": { "service-unavailable": { "value": { "type": "https://docs.wavix.com/errors/service-unavailable", "title": "Service Unavailable", "status": 503, "detail": "The service is temporarily unavailable.", "instance": "3a525ca2-6909-4c72-9399-905adf7f3a74", "error_class": "retriable", "error_code": "SERVICE_UNAVAILABLE" } }, "webhook-url-unverified": { "summary": "Wavix couldn't resolve the host of the URL", "value": { "type": "https://docs.wavix.com/errors/webhook-url-unverified", "title": "Webhook URL Unverified", "status": 503, "detail": "Webhook URL Unverified", "instance": "3a525ca2-6909-4c72-9399-905adf7f3a74", "error_class": "retriable", "error_code": "WEBHOOK_URL_UNVERIFIED" } } } } } } }, "deprecated": false }, "get": { "tags": [ "WhatsApp" ], "summary": "List WhatsApp webhooks", "description": "Returns the WhatsApp webhooks registered for your account.\n\nAn account has at most 1 webhook per group, so the list holds up to 3 items. It never includes the signing secrets.\n\n**Requires:** Your account must have WhatsApp available, must have a subscription plan, and must not be blocked or suspended.", "operationId": "whatsapp_webhooks_list", "security": [ { "bearerAuth": [ "whatsapp:read" ] } ], "x-fern-sdk-group-name": [ "whatsapp", "webhooks" ], "x-fern-sdk-method-name": "list", "x-fern-ignore": true, "x-mcp": { "readOnly": true, "destructive": false, "openWorld": false, "expose": true }, "parameters": [], "responses": { "200": { "description": "The WhatsApp webhooks of your account, empty when it has none.", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/WhatsAppWebhookListResponse" }, "examples": { "default": { "summary": "An account with webhooks for messages and templates", "value": { "webhooks": [ { "uuid": "6f1c2a4e-8b3d-4c5e-9f70-1a2b3c4d5e6f", "url": "https://example.com/wavix", "group": "messages", "enabled": true, "enabled_events": [ "whatsapp.message.received", "whatsapp.message.sent", "whatsapp.message.delivered", "whatsapp.message.read", "whatsapp.message.failed", "whatsapp.contact.marketing_stopped", "whatsapp.contact.marketing_resumed" ], "created_at": "2026-10-21T12:00:00Z" }, { "uuid": "2d8e4f6a-1c3b-4a5d-8e7f-9a0b1c2d3e4f", "url": "https://example.com/wavix/templates", "group": "templates", "enabled": true, "enabled_events": [ "whatsapp.template.approved", "whatsapp.template.rejected", "whatsapp.template.paused", "whatsapp.template.disabled", "whatsapp.template.flagged", "whatsapp.template.category_changed", "whatsapp.template.quality_changed", "whatsapp.template.updated" ], "created_at": "2026-10-21T12:05:00Z" } ] } } } } } }, "401": { "$ref": "#/components/responses/WhatsAppUnauthorizedResponse" }, "403": { "$ref": "#/components/responses/WhatsAppForbiddenResponse" }, "404": { "description": "WhatsApp isn't available for your account.", "content": { "application/problem+json": { "schema": { "$ref": "#/components/schemas/WhatsAppProblem" }, "examples": { "whatsapp-not-available": { "summary": "WhatsApp is not available for this account", "value": { "type": "https://docs.wavix.com/errors/whatsapp-not-available", "title": "WhatsApp Not Available", "status": 404, "detail": "WhatsApp is not available for this account.", "instance": "3a525ca2-6909-4c72-9399-905adf7f3a74", "error_class": "permanent", "error_code": "WHATSAPP_NOT_AVAILABLE" } } } } } }, "500": { "$ref": "#/components/responses/WhatsAppInternalServerErrorResponse" }, "503": { "$ref": "#/components/responses/WhatsAppServiceUnavailableResponse" } }, "deprecated": false } }, "/v1/whatsapp/webhooks/{uuid}": { "get": { "tags": [ "WhatsApp" ], "summary": "Retrieve a WhatsApp webhook", "description": "Returns the WhatsApp webhook with the given ID, including its URL, its group, and the event types it receives.\n\nThe URL and the `enabled` value show where Wavix sends events and whether it sends them now. The response never includes the signing secret.\n\n**Requires:** Your account must have WhatsApp available, must have a subscription plan, and must not be blocked or suspended.", "operationId": "whatsapp_webhooks_get", "security": [ { "bearerAuth": [ "whatsapp:read" ] } ], "x-fern-sdk-group-name": [ "whatsapp", "webhooks" ], "x-fern-sdk-method-name": "get", "x-fern-ignore": true, "x-mcp": { "readOnly": true, "destructive": false, "openWorld": false, "expose": true }, "parameters": [ { "name": "uuid", "in": "path", "required": true, "description": "ID of the webhook, as returned in `uuid` when you create the webhook or list your webhooks.", "schema": { "type": "string", "format": "uuid" }, "example": "6f1c2a4e-8b3d-4c5e-9f70-1a2b3c4d5e6f" } ], "responses": { "200": { "description": "The requested WhatsApp webhook.", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/WhatsAppWebhookResponse" }, "examples": { "default": { "summary": "The webhook for sender events", "value": { "webhook": { "uuid": "6f1c2a4e-8b3d-4c5e-9f70-1a2b3c4d5e6f", "url": "https://example.com/wavix", "group": "senders", "enabled": true, "enabled_events": [ "whatsapp.sender.connected", "whatsapp.sender.restricted", "whatsapp.sender.flagged", "whatsapp.sender.banned", "whatsapp.sender.disconnected", "whatsapp.sender.quality_changed", "whatsapp.sender.updated" ], "created_at": "2026-10-21T12:00:00Z" } } } } } } }, "401": { "$ref": "#/components/responses/WhatsAppUnauthorizedResponse" }, "403": { "$ref": "#/components/responses/WhatsAppForbiddenResponse" }, "404": { "description": "No webhook with this ID belongs to your account, or WhatsApp isn't available for your account.", "content": { "application/problem+json": { "schema": { "$ref": "#/components/schemas/WhatsAppProblem" }, "examples": { "whatsapp-not-available": { "summary": "WhatsApp is not available for this account", "value": { "type": "https://docs.wavix.com/errors/whatsapp-not-available", "title": "WhatsApp Not Available", "status": 404, "detail": "WhatsApp is not available for this account.", "instance": "3a525ca2-6909-4c72-9399-905adf7f3a74", "error_class": "permanent", "error_code": "WHATSAPP_NOT_AVAILABLE" } }, "webhook-not-found": { "summary": "No webhook matches the given uuid", "value": { "type": "https://docs.wavix.com/errors/webhook-not-found", "title": "Webhook Not Found", "status": 404, "detail": "Webhook Not Found", "instance": "3a525ca2-6909-4c72-9399-905adf7f3a74", "error_class": "permanent", "error_code": "WEBHOOK_NOT_FOUND" } } } } } }, "500": { "$ref": "#/components/responses/WhatsAppInternalServerErrorResponse" }, "503": { "$ref": "#/components/responses/WhatsAppServiceUnavailableResponse" } }, "deprecated": false }, "patch": { "tags": [ "WhatsApp" ], "summary": "Update a WhatsApp webhook", "description": "Updates the URL of a WhatsApp webhook or turns it off or on, and returns the updated webhook.\n\nMove events to a new URL without deleting the webhook, so its ID and signing secret stay the same, or pause events while your server is down for maintenance.\n\n**Behavior:** Returns `200` with the updated webhook. With `enabled` set to `false`, Wavix cancels the deliveries still waiting. Events that Wavix records while the webhook is disabled aren't sent later; read them with [List WhatsApp events](https://docs.wavix.com/api-reference/whatsapp/list-whatsapp-events). With `enabled` set to `true`, the webhook gets the events that occur from then on.\n\n**Requires:** Your account must have the WhatsApp channel enabled, must have a subscription plan, and must not be blocked or suspended.", "operationId": "whatsapp_webhooks_update", "security": [ { "bearerAuth": [ "whatsapp:write" ] } ], "x-fern-sdk-group-name": [ "whatsapp", "webhooks" ], "x-fern-sdk-method-name": "update", "x-fern-ignore": true, "x-mcp": { "readOnly": false, "destructive": true, "openWorld": true, "expose": true }, "parameters": [ { "name": "uuid", "in": "path", "required": true, "description": "ID of the webhook, as returned in `uuid` when you create the webhook or list your webhooks.", "schema": { "type": "string", "format": "uuid" }, "example": "6f1c2a4e-8b3d-4c5e-9f70-1a2b3c4d5e6f" } ], "requestBody": { "description": "Attributes of the webhook to change.", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/WhatsAppWebhookUpdateRequest" }, "examples": { "new-url": { "summary": "Move events to a new URL", "value": { "url": "https://example.com/wavix/v2" } }, "disable": { "summary": "Stop sending events", "value": { "enabled": false } } } } }, "required": true }, "responses": { "200": { "description": "The updated WhatsApp webhook. It never includes the signing secret.", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/WhatsAppWebhookResponse" }, "examples": { "default": { "summary": "The webhook after a new URL", "value": { "webhook": { "uuid": "6f1c2a4e-8b3d-4c5e-9f70-1a2b3c4d5e6f", "url": "https://example.com/wavix/v2", "group": "messages", "enabled": true, "enabled_events": [ "whatsapp.message.received", "whatsapp.message.sent", "whatsapp.message.delivered", "whatsapp.message.read", "whatsapp.message.failed", "whatsapp.contact.marketing_stopped", "whatsapp.contact.marketing_resumed" ], "created_at": "2026-10-21T12:00:00Z" } } } } } } }, "400": { "description": "The body is invalid. The JSON is malformed or empty, has no fields, or a field is unknown or `null`. The `detail` field says which.", "content": { "application/problem+json": { "schema": { "$ref": "#/components/schemas/WhatsAppProblem" }, "examples": { "invalid-request": { "summary": "The body has an unknown field", "value": { "type": "https://docs.wavix.com/errors/invalid-request", "title": "Invalid Request", "status": 400, "detail": "The request body has an unknown field: \"group\".", "instance": "3a525ca2-6909-4c72-9399-905adf7f3a74", "error_class": "permanent", "error_code": "INVALID_REQUEST" } } } } } }, "401": { "$ref": "#/components/responses/WhatsAppUnauthorizedResponse" }, "403": { "$ref": "#/components/responses/WhatsAppForbiddenResponse" }, "404": { "description": "No webhook with this ID belongs to your account, or WhatsApp isn't available for your account or isn't enabled yet.", "content": { "application/problem+json": { "schema": { "$ref": "#/components/schemas/WhatsAppProblem" }, "examples": { "webhook-not-found": { "summary": "No webhook matches the given uuid", "value": { "type": "https://docs.wavix.com/errors/webhook-not-found", "title": "Webhook Not Found", "status": 404, "detail": "Webhook Not Found", "instance": "3a525ca2-6909-4c72-9399-905adf7f3a74", "error_class": "permanent", "error_code": "WEBHOOK_NOT_FOUND" } } } } } }, "413": { "description": "The request body is over 16 KiB.", "content": { "application/problem+json": { "schema": { "$ref": "#/components/schemas/WhatsAppProblem" }, "examples": { "payload-too-large": { "summary": "The request body exceeds the size limit", "value": { "type": "https://docs.wavix.com/errors/payload-too-large", "title": "Payload Too Large", "status": 413, "detail": "The request body is too large.", "instance": "3a525ca2-6909-4c72-9399-905adf7f3a74", "error_class": "permanent", "error_code": "PAYLOAD_TOO_LARGE" } } } } } }, "422": { "description": "`url` isn't an `https` URL without credentials, is longer than 2,048 bytes, or has a host with no address, or resolves to an address that isn't public or that Wavix doesn't allow. The `detail` field says which.", "content": { "application/problem+json": { "schema": { "$ref": "#/components/schemas/WhatsAppProblem" }, "examples": { "invalid-webhook-url": { "summary": "The URL isn't a public https URL", "value": { "type": "https://docs.wavix.com/errors/invalid-webhook-url", "title": "Invalid Webhook URL", "status": 422, "detail": "The URL host resolves to an address that is not public or that Wavix does not allow.", "instance": "3a525ca2-6909-4c72-9399-905adf7f3a74", "error_class": "permanent", "error_code": "INVALID_WEBHOOK_URL" } } } } } }, "500": { "$ref": "#/components/responses/WhatsAppInternalServerErrorResponse" }, "503": { "description": "The service is temporarily unavailable, or the lookup of the host of `url` failed. The request may be retried.", "content": { "application/problem+json": { "schema": { "$ref": "#/components/schemas/WhatsAppProblem" }, "examples": { "service-unavailable": { "value": { "type": "https://docs.wavix.com/errors/service-unavailable", "title": "Service Unavailable", "status": 503, "detail": "The service is temporarily unavailable.", "instance": "3a525ca2-6909-4c72-9399-905adf7f3a74", "error_class": "retriable", "error_code": "SERVICE_UNAVAILABLE" } }, "webhook-url-unverified": { "summary": "Wavix couldn't resolve the host of the URL", "value": { "type": "https://docs.wavix.com/errors/webhook-url-unverified", "title": "Webhook URL Unverified", "status": 503, "detail": "Webhook URL Unverified", "instance": "3a525ca2-6909-4c72-9399-905adf7f3a74", "error_class": "retriable", "error_code": "WEBHOOK_URL_UNVERIFIED" } } } } } } }, "deprecated": false }, "delete": { "tags": [ "WhatsApp" ], "summary": "Delete a WhatsApp webhook", "description": "Deletes the WhatsApp webhook with the given ID.\n\nDelete a webhook when you no longer need its group of events, or before you create one with a new signing secret. To pause events for a while, disable the webhook with [Update a WhatsApp webhook](https://docs.wavix.com/api-reference/whatsapp/update-a-whatsapp-webhook) instead.\n\n**Behavior:** Returns `204` with no content. Deliveries still waiting are cancelled, and the deletion can't be undone. Your account can then create a new webhook for the same group.\n\n**Requires:** Your account must have WhatsApp available, must have a subscription plan, and must not be blocked or suspended.", "operationId": "whatsapp_webhooks_delete", "security": [ { "bearerAuth": [ "whatsapp:write" ] } ], "x-fern-sdk-group-name": [ "whatsapp", "webhooks" ], "x-fern-sdk-method-name": "delete", "x-fern-ignore": true, "x-mcp": { "readOnly": false, "destructive": true, "openWorld": false, "expose": true }, "parameters": [ { "name": "uuid", "in": "path", "required": true, "description": "ID of the webhook, as returned in `uuid` when you create the webhook or list your webhooks.", "schema": { "type": "string", "format": "uuid" }, "example": "6f1c2a4e-8b3d-4c5e-9f70-1a2b3c4d5e6f" } ], "responses": { "204": { "description": "The webhook was deleted. The response has no content." }, "401": { "$ref": "#/components/responses/WhatsAppUnauthorizedResponse" }, "403": { "$ref": "#/components/responses/WhatsAppForbiddenResponse" }, "404": { "description": "No webhook with this ID belongs to your account, or WhatsApp isn't available for your account.", "content": { "application/problem+json": { "schema": { "$ref": "#/components/schemas/WhatsAppProblem" }, "examples": { "whatsapp-not-available": { "summary": "WhatsApp is not available for this account", "value": { "type": "https://docs.wavix.com/errors/whatsapp-not-available", "title": "WhatsApp Not Available", "status": 404, "detail": "WhatsApp is not available for this account.", "instance": "3a525ca2-6909-4c72-9399-905adf7f3a74", "error_class": "permanent", "error_code": "WHATSAPP_NOT_AVAILABLE" } }, "webhook-not-found": { "summary": "No webhook matches the given uuid", "value": { "type": "https://docs.wavix.com/errors/webhook-not-found", "title": "Webhook Not Found", "status": 404, "detail": "Webhook Not Found", "instance": "3a525ca2-6909-4c72-9399-905adf7f3a74", "error_class": "permanent", "error_code": "WEBHOOK_NOT_FOUND" } } } } } }, "500": { "$ref": "#/components/responses/WhatsAppInternalServerErrorResponse" }, "503": { "$ref": "#/components/responses/WhatsAppServiceUnavailableResponse" } }, "deprecated": false } }, "/v1/whatsapp/webhooks/{uuid}/test": { "post": { "tags": [ "WhatsApp" ], "summary": "Send a WhatsApp webhook test event", "description": "Sends a test event to a WhatsApp webhook's URL and returns what the receiver answered.\n\nSend a test event after creating a webhook to check that your server receives events and verifies their signature.\n\n**Behavior:** Returns `200` whatever the receiver answers; `outcome` says what happened. The call waits up to 10 seconds for the receiver to answer. The event has `type` set to `test`, goes to the webhook whatever its group and even when it's disabled, and is sent once and never retried.\n\n**Requires:** Your account must have the WhatsApp channel enabled, must have a subscription plan, and must not be blocked or suspended.", "operationId": "whatsapp_webhooks_send_test", "security": [ { "bearerAuth": [ "whatsapp:write" ] } ], "x-fern-sdk-group-name": [ "whatsapp", "webhooks" ], "x-fern-sdk-method-name": "sendTest", "x-fern-ignore": true, "x-mcp": { "readOnly": false, "destructive": false, "openWorld": true, "expose": true }, "parameters": [ { "name": "uuid", "in": "path", "required": true, "description": "ID of the webhook, as returned in `uuid` when you create the webhook or list your webhooks.", "schema": { "type": "string", "format": "uuid" }, "example": "6f1c2a4e-8b3d-4c5e-9f70-1a2b3c4d5e6f" } ], "responses": { "200": { "description": "The outcome of the test event.", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/WhatsAppWebhookTestResponse" }, "examples": { "default": { "summary": "The receiver answered with 200", "value": { "test": { "outcome": "delivered", "status_code": 200, "duration_ms": 184 } } }, "http-error": { "summary": "The receiver answered with 500", "value": { "test": { "outcome": "http_error", "status_code": 500, "duration_ms": 92 } } }, "timeout": { "summary": "The receiver didn't answer in time", "value": { "test": { "outcome": "timeout", "status_code": null, "duration_ms": 10000 } } } } } } }, "401": { "$ref": "#/components/responses/WhatsAppUnauthorizedResponse" }, "403": { "$ref": "#/components/responses/WhatsAppForbiddenResponse" }, "404": { "description": "No webhook with this ID belongs to your account, or WhatsApp isn't available for your account or isn't enabled yet.", "content": { "application/problem+json": { "schema": { "$ref": "#/components/schemas/WhatsAppProblem" }, "examples": { "whatsapp-not-available": { "summary": "WhatsApp is not available for this account", "value": { "type": "https://docs.wavix.com/errors/whatsapp-not-available", "title": "WhatsApp Not Available", "status": 404, "detail": "WhatsApp is not available for this account.", "instance": "3a525ca2-6909-4c72-9399-905adf7f3a74", "error_class": "permanent", "error_code": "WHATSAPP_NOT_AVAILABLE" } }, "channel-not-enabled": { "summary": "WhatsApp is not enabled yet for this account", "value": { "type": "https://docs.wavix.com/errors/channel-not-enabled", "title": "Channel Not Enabled", "status": 404, "detail": "The WhatsApp channel is not enabled for this account.", "instance": "3a525ca2-6909-4c72-9399-905adf7f3a74", "error_class": "permanent", "error_code": "CHANNEL_NOT_ENABLED" } }, "webhook-not-found": { "summary": "No webhook matches the given uuid", "value": { "type": "https://docs.wavix.com/errors/webhook-not-found", "title": "Webhook Not Found", "status": 404, "detail": "Webhook Not Found", "instance": "3a525ca2-6909-4c72-9399-905adf7f3a74", "error_class": "permanent", "error_code": "WEBHOOK_NOT_FOUND" } } } } } }, "500": { "$ref": "#/components/responses/WhatsAppInternalServerErrorResponse" }, "503": { "$ref": "#/components/responses/WhatsAppServiceUnavailableResponse" } }, "deprecated": false } }, "/v1/whatsapp/events": { "get": { "tags": [ "WhatsApp" ], "summary": "List WhatsApp events", "description": "Returns a paginated list of your account's WhatsApp events, the same events Wavix posts to your webhooks, oldest first.\n\nRead events here when your server can't receive webhooks, or to catch up on events your webhooks missed. Events are recorded even when your account has no webhook for their group.\n\n**Behavior:** Events are ordered by when Wavix recorded them, oldest first, which can differ from `timestamp`. To read them all, pass `next_cursor` from each page as `after` until `has_more` is `false`; later, pass the last non-null `next_cursor` again, or no `after` if you have none, to get events recorded since. Events are kept for 30 days, and test events never appear. When both `type` and `group` are specified, an event must match both filters.\n\n**Requires:** Your account must have WhatsApp enabled, must have a subscription plan, and must not be blocked or suspended.", "operationId": "whatsapp_events_list", "security": [ { "bearerAuth": [ "whatsapp:read" ] } ], "x-fern-sdk-group-name": [ "whatsapp", "events" ], "x-fern-sdk-method-name": "list", "x-fern-ignore": true, "x-fern-pagination": { "cursor": "$request.after", "next_cursor": "$response.next_cursor", "results": "$response.events" }, "x-mcp": { "readOnly": true, "destructive": false, "openWorld": false, "expose": true }, "parameters": [ { "name": "type", "in": "query", "required": false, "description": "Filters events by type.", "schema": { "$ref": "#/components/schemas/WhatsAppEventType" }, "example": "whatsapp.message.received" }, { "name": "group", "in": "query", "required": false, "description": "Filters events by the webhook group their type belongs to.", "schema": { "$ref": "#/components/schemas/WhatsAppWebhookGroup" }, "example": "messages" }, { "name": "after", "in": "query", "required": false, "description": "Returns only events recorded after the event with this ID. Pass `next_cursor` from the previous page. Without it, the list starts at the oldest event kept.", "schema": { "type": "string", "pattern": "^evt_[0-9a-f]{32}$" }, "example": "evt_8a1d3c5e7f9b4d2a6c8e0f1a3b5c7d9e" }, { "name": "limit", "in": "query", "required": false, "description": "Maximum number of events to return. Defaults to 25.", "schema": { "type": "integer", "format": "int32", "minimum": 1, "maximum": 100, "default": 25 }, "example": 25 } ], "responses": { "200": { "description": "A paginated list of WhatsApp events, oldest first.", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/WhatsAppEventListResponse" }, "examples": { "default": { "summary": "A received message and a delivered message", "value": { "events": [ { "id": "evt_8a1d3c5e7f9b4d2a6c8e0f1a3b5c7d9e", "type": "whatsapp.message.received", "timestamp": "2026-10-21T08:30:00.123456Z", "data": { "message_uuid": "9d4e1c7a-2b86-4f3d-b5a0-71e8c3f6a924", "from": "+447537151866", "to": "+14155550100", "profile_name": "Jane Smith", "content": { "type": "button_reply", "button_reply": { "id": "confirm-order-1001", "title": "Confirm" } }, "context": { "message_uuid": "3a525ca2-6909-4c72-9399-905adf7f3a74" }, "referral": null, "service_window_open_until": "2026-10-22T08:30:00Z" } }, { "id": "evt_1b3d5f7a9c2e4b6d8f0a1c3e5b7d9f2a", "type": "whatsapp.message.delivered", "timestamp": "2026-10-21T08:31:05.000000Z", "data": { "message_uuid": "3a525ca2-6909-4c72-9399-905adf7f3a74", "from": "+14155550100", "to": "+447537151866", "template": { "name": "order_shipped", "language": "en_US" } } } ], "next_cursor": "evt_1b3d5f7a9c2e4b6d8f0a1c3e5b7d9f2a", "has_more": false } }, "caught-up": { "summary": "No events since the cursor", "value": { "events": [], "next_cursor": null, "has_more": false } } } } } }, "400": { "description": "A query parameter is invalid. A parameter is empty or repeated, `type` or `group` has an unsupported value, `limit` isn't an integer from 1 to 100, or `after` isn't an event ID or isn't an event of your account that's still kept. For an `after` that's no longer kept, start again without `after` and discard events you already handled by `id`. The `detail` field says which.", "content": { "application/problem+json": { "schema": { "$ref": "#/components/schemas/WhatsAppProblem" }, "examples": { "invalid-request": { "summary": "The cursor isn't a kept event of your account", "value": { "type": "https://docs.wavix.com/errors/invalid-request", "title": "Invalid Request", "status": 400, "detail": "after: event not found", "instance": "3a525ca2-6909-4c72-9399-905adf7f3a74", "error_class": "permanent", "error_code": "INVALID_REQUEST" } } } } } }, "401": { "$ref": "#/components/responses/WhatsAppUnauthorizedResponse" }, "403": { "$ref": "#/components/responses/WhatsAppForbiddenResponse" }, "404": { "$ref": "#/components/responses/WhatsAppChannelUnavailableResponse" }, "500": { "$ref": "#/components/responses/WhatsAppInternalServerErrorResponse" }, "503": { "$ref": "#/components/responses/WhatsAppServiceUnavailableResponse" } }, "deprecated": false } }, "/v1/whatsapp/media/{media_uuid}": { "get": { "tags": [ "WhatsApp" ], "summary": "Download received media", "description": "Returns a media file your account received in a WhatsApp message.\n\nThe address of the media is the `url` of a media content in a `whatsapp.message.received` event, and the `media_url` of a message from [List WhatsApp messages](https://docs.wavix.com/api-reference/whatsapp/list-whatsapp-messages) or [Retrieve a WhatsApp message](https://docs.wavix.com/api-reference/whatsapp/retrieve-a-whatsapp-message).\n\n**Behavior:** Returns the file itself, with its own media type in the `Content-Type` header. The file stays available at least as long as Wavix keeps the received message.\n\n**Requires:** Your account must have WhatsApp enabled, must have a subscription plan, and must not be blocked or suspended.", "operationId": "whatsapp_media_download", "security": [ { "bearerAuth": [ "whatsapp:read" ] } ], "x-fern-sdk-group-name": [ "whatsapp", "media" ], "x-fern-sdk-method-name": "download", "x-fern-ignore": true, "x-mcp": { "readOnly": true, "destructive": false, "openWorld": false, "expose": false }, "parameters": [ { "name": "media_uuid", "in": "path", "required": true, "description": "ID of the media, as returned in `id` of the media content of a `whatsapp.message.received` event or in `media_id` of a received message.", "schema": { "type": "string", "format": "uuid" }, "example": "7f3e2c1a-5b9d-4e8f-a1c3-2d4e6f8a0b1c" } ], "responses": { "200": { "description": "The media file of the received message.", "headers": { "Content-Type": { "description": "Media type of the file, such as `image/jpeg`, or `application/octet-stream` when the type isn't known.", "schema": { "type": "string" } }, "Content-Length": { "description": "Size of the file in bytes.", "schema": { "type": "integer" } }, "Cache-Control": { "description": "Always `no-store`.", "schema": { "type": "string" } } }, "content": { "application/octet-stream": { "schema": { "type": "string", "format": "binary" } } } }, "401": { "$ref": "#/components/responses/WhatsAppUnauthorizedResponse" }, "403": { "$ref": "#/components/responses/WhatsAppForbiddenResponse" }, "404": { "description": "WhatsApp isn't available for your account or isn't enabled yet, or no media with this ID belongs to your account.", "content": { "application/problem+json": { "schema": { "$ref": "#/components/schemas/WhatsAppProblem" }, "examples": { "whatsapp-not-available": { "summary": "WhatsApp is not available for this account", "value": { "type": "https://docs.wavix.com/errors/whatsapp-not-available", "title": "WhatsApp Not Available", "status": 404, "detail": "WhatsApp is not available for this account.", "instance": "3a525ca2-6909-4c72-9399-905adf7f3a74", "error_class": "permanent", "error_code": "WHATSAPP_NOT_AVAILABLE" } }, "channel-not-enabled": { "summary": "WhatsApp is not enabled yet for this account", "value": { "type": "https://docs.wavix.com/errors/channel-not-enabled", "title": "Channel Not Enabled", "status": 404, "detail": "The WhatsApp channel is not enabled for this account.", "instance": "3a525ca2-6909-4c72-9399-905adf7f3a74", "error_class": "permanent", "error_code": "CHANNEL_NOT_ENABLED" } }, "resource-not-found": { "summary": "No media matches the given ID", "value": { "type": "https://docs.wavix.com/errors/resource-not-found", "title": "Resource Not Found", "status": 404, "detail": "Resource Not Found", "instance": "3a525ca2-6909-4c72-9399-905adf7f3a74", "error_class": "permanent", "error_code": "RESOURCE_NOT_FOUND" } } } } } }, "429": { "$ref": "#/components/responses/WhatsAppTooManyRequestsResponse" }, "500": { "$ref": "#/components/responses/WhatsAppInternalServerErrorResponse" }, "503": { "$ref": "#/components/responses/WhatsAppServiceUnavailableResponse" } }, "deprecated": false } } }, "webhooks": { "OnCallEvent": { "post": { "summary": "On-call event", "operationId": "on_call_event", "security": [], "description": "Sends a notification to track the lifecycle of an active call.status updates. It's triggered when a call is initiated, answered, and ends.", "tags": [ "Call webhooks" ], "requestBody": { "description": "Callback payload.", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Call" } } } }, "responses": { "200": { "description": "Return a 200 status to indicate that the data was successfully received" } } } }, "PostCallEvent": { "post": { "summary": "Post-call event", "operationId": "post_call_event", "security": [], "description": "The `post-call` callback includes details such as call disposition, duration, and cost. It's triggered after the call ends.", "tags": [ "Call webhooks" ], "requestBody": { "description": "Callback payload.", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/CallStatusWebhook" } } } }, "responses": { "200": { "description": "Return a 200 status to indicate that the data was successfully received" } } } }, "AudioFileTranscriptionCompleted": { "post": { "summary": "Audio file transcription completed", "operationId": "audio_file_transcription_completed", "security": [], "description": "Sends a notification when an audio file transcription is complete.", "tags": [ "Speech Analytics" ], "requestBody": { "description": "Callback payload.", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/FileTranscriptionCompletedWebhook" } } } }, "responses": { "200": { "description": "Return a 200 status to indicate that the data was successfully received" } } } }, "CallTranscriptionCompleted": { "post": { "summary": "Call transcription completed", "operationId": "call_transcription_completed", "security": [], "description": "Sends a notification when a call transcription is complete.", "tags": [ "Speech Analytics" ], "requestBody": { "description": "Callback payload.", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/CDRTranscriptionCompletedWebhook" } } } }, "responses": { "200": { "description": "Return a 200 status to indicate that the data was received." } } } }, "DeliveryReport": { "post": { "summary": "Delivery report", "operationId": "delivery_report", "security": [], "description": "Sends a notification when an outbound message delivery status changes.", "tags": [ "SMS and MMS" ], "requestBody": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/MessagesDeliveryReport" } } } }, "responses": { "200": { "description": "Successful callback receipt." } } } }, "InboundMessage": { "post": { "summary": "Inbound message", "operationId": "inbound_message", "security": [], "description": "Sends a notification when a message is received by an SMS-enabled phone number.", "tags": [ "SMS and MMS" ], "requestBody": { "description": "Callback payload.", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/InboundMessage" } } } }, "responses": { "200": { "description": "Return a 200 status to indicate that the data was received." } } } }, "BrandStatusChanged": { "post": { "summary": "Brand status changed", "operationId": "brand_status_changed", "security": [], "description": "Sends a notification when a 10DLC Brand status is updated.", "tags": [ "10DLC" ], "requestBody": { "description": "Callback payload.", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/BrandStatusUpdatedWebhook" } } } }, "responses": { "200": { "description": "Return a 200 status to indicate that the data was received." } } } }, "CampaignStatusChanged": { "post": { "summary": "Campaign status changed", "operationId": "campaign_status_changed", "security": [], "description": "Sends a notification when a 10DLC Campaign status is updated in TCR.", "tags": [ "10DLC" ], "requestBody": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/CampaignStatusUpdatedWebhook" } } } }, "responses": { "200": { "description": "Return a 200 status to indicate that the data was successfully received" } } } }, "NumberStatusChanged": { "post": { "summary": "Number status changed", "operationId": "number_status_changed", "security": [], "description": "Sends a notification when a phone number status is updated.", "tags": [ "10DLC" ], "requestBody": { "description": "Callback payload.", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/NumberStatusUpdatedWebhook" } } } }, "responses": { "200": { "description": "Return a 200 status to indicate that the data was received." } } } }, "WhatsAppMessageEvents": { "post": { "summary": "WhatsApp message event occurred", "operationId": "whatsapp_message_event_occurred", "security": [], "description": "Wavix sends these events to your webhook of the `messages` group when one of your senders receives a message, when a message you sent is sent, delivered, read, or fails, and when a contact stops or resumes marketing messages. A test event you send to the webhook arrives here too.\n\nEach change is a separate event, and `type` names it, so your server can follow a conversation and the status of each message without polling. A media content has an `id` and a `url`; send a `GET` request to the `url` with your API key to download the file, as [Download received media](https://docs.wavix.com/api-reference/whatsapp/download-received-media) describes.\n\n**Behavior:** Return a 2xx status within 10 seconds to acknowledge the event; Wavix doesn't follow redirects, so a 3xx response counts as a failed attempt. After a failed attempt, Wavix retries about 5 seconds, 30 seconds, 2 minutes, 10 minutes, 1 hour, 6 hours, and 24 hours later, up to 8 attempts in total; a `test` event isn't retried. Events can arrive more than once and out of order, so discard repeats by `id` and keep the state from the event with the latest `timestamp`. When two status events of a message share a `timestamp`, keep the later of `sent`, `failed`, `delivered`, `read`.\n\n**Requires:** A webhook of the `messages` group. A disabled webhook gets only test events. Its URL must use `https`, have a valid TLS certificate, and resolve only to public addresses that Wavix allows. If the host resolves to another address at send time, Wavix doesn't send the event and doesn't retry it. Verify every request as the [Standard Webhooks](https://www.standardwebhooks.com/) specification describes, with one of its libraries or by hand. The `webhook-signature` and `webhook-timestamp` headers give the steps.\n\n**Limits:** [List WhatsApp events](https://docs.wavix.com/api-reference/whatsapp/list-whatsapp-events) keeps each event except `test` for 30 days, so you can catch up on events your server missed within that time.", "tags": [ "WhatsApp webhook payloads" ], "parameters": [ { "$ref": "#/components/parameters/WhatsAppWebhookIdHeader" }, { "$ref": "#/components/parameters/WhatsAppWebhookTimestampHeader" }, { "$ref": "#/components/parameters/WhatsAppWebhookSignatureHeader" } ], "requestBody": { "required": true, "description": "The event Wavix posts to your webhook URL.", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/WhatsAppMessagesGroupEvent" }, "examples": { "received-button-reply": { "summary": "A customer tapped a quick reply button", "value": { "id": "evt_8a1d3c5e7f9b4d2a6c8e0f1a3b5c7d00", "type": "whatsapp.message.received", "timestamp": "2026-10-21T08:30:00.123456Z", "data": { "message_uuid": "9d4e1c7a-2b86-4f3d-b5a0-71e8c3f6a924", "from": "+447537151866", "to": "+14155550100", "profile_name": "Jane Smith", "content": { "type": "button_reply", "button_reply": { "id": "confirm-order-1001", "title": "Confirm" } }, "context": { "message_uuid": "3a525ca2-6909-4c72-9399-905adf7f3a74" }, "referral": null, "service_window_open_until": "2026-10-22T08:30:00Z" } } }, "received-text-from-ad": { "summary": "A customer wrote after tapping a click-to-WhatsApp ad", "value": { "id": "evt_8a1d3c5e7f9b4d2a6c8e0f1a3b5c7d01", "type": "whatsapp.message.received", "timestamp": "2026-10-21T08:30:00.123456Z", "data": { "message_uuid": "9d4e1c7a-2b86-4f3d-b5a0-71e8c3f6a924", "from": "+447537151866", "to": "+14155550100", "profile_name": "Jane Smith", "content": { "type": "text", "text": "Hi, is the free delivery offer still on?" }, "context": null, "referral": { "source_type": "ad", "source_id": "120210000000000001", "source_url": "https://fb.me/3cr4Wqqkk", "headline": "Free delivery this week", "body": "Order today and get free delivery.", "click_id": "ARAkLkA8rmlFeiCktEJQ" }, "service_window_open_until": "2026-10-22T08:30:00Z" } } }, "received-image": { "summary": "A customer sent an image", "value": { "id": "evt_8a1d3c5e7f9b4d2a6c8e0f1a3b5c7d02", "type": "whatsapp.message.received", "timestamp": "2026-10-21T08:30:00.123456Z", "data": { "message_uuid": "9d4e1c7a-2b86-4f3d-b5a0-71e8c3f6a924", "from": "+447537151866", "to": "+14155550100", "profile_name": "Jane Smith", "content": { "type": "image", "image": { "id": "7f3e2c1a-5b9d-4e8f-a1c3-2d4e6f8a0b1c", "url": "https://api.wavix.com/v1/whatsapp/media/7f3e2c1a-5b9d-4e8f-a1c3-2d4e6f8a0b1c", "mime_type": "image/jpeg", "caption": "Photo of the damaged box", "filename": null } }, "context": null, "referral": null, "service_window_open_until": "2026-10-22T08:30:00Z" } } }, "received-video": { "summary": "A customer sent a video", "value": { "id": "evt_8a1d3c5e7f9b4d2a6c8e0f1a3b5c7d03", "type": "whatsapp.message.received", "timestamp": "2026-10-21T08:30:00.123456Z", "data": { "message_uuid": "9d4e1c7a-2b86-4f3d-b5a0-71e8c3f6a924", "from": "+447537151866", "to": "+14155550100", "profile_name": "Jane Smith", "content": { "type": "video", "video": { "id": "7f3e2c1a-5b9d-4e8f-a1c3-2d4e6f8a0b1c", "url": "https://api.wavix.com/v1/whatsapp/media/7f3e2c1a-5b9d-4e8f-a1c3-2d4e6f8a0b1c", "mime_type": "video/mp4", "caption": "Unboxing", "filename": null } }, "context": null, "referral": null, "service_window_open_until": "2026-10-22T08:30:00Z" } } }, "received-audio": { "summary": "A customer sent a voice note", "value": { "id": "evt_8a1d3c5e7f9b4d2a6c8e0f1a3b5c7d04", "type": "whatsapp.message.received", "timestamp": "2026-10-21T08:30:00.123456Z", "data": { "message_uuid": "9d4e1c7a-2b86-4f3d-b5a0-71e8c3f6a924", "from": "+447537151866", "to": "+14155550100", "profile_name": "Jane Smith", "content": { "type": "audio", "audio": { "id": "7f3e2c1a-5b9d-4e8f-a1c3-2d4e6f8a0b1c", "url": "https://api.wavix.com/v1/whatsapp/media/7f3e2c1a-5b9d-4e8f-a1c3-2d4e6f8a0b1c", "mime_type": "audio/ogg", "caption": null, "filename": null } }, "context": null, "referral": null, "service_window_open_until": "2026-10-22T08:30:00Z" } } }, "received-document": { "summary": "A customer sent a document", "value": { "id": "evt_8a1d3c5e7f9b4d2a6c8e0f1a3b5c7d05", "type": "whatsapp.message.received", "timestamp": "2026-10-21T08:30:00.123456Z", "data": { "message_uuid": "9d4e1c7a-2b86-4f3d-b5a0-71e8c3f6a924", "from": "+447537151866", "to": "+14155550100", "profile_name": "Jane Smith", "content": { "type": "document", "document": { "id": "7f3e2c1a-5b9d-4e8f-a1c3-2d4e6f8a0b1c", "url": "https://api.wavix.com/v1/whatsapp/media/7f3e2c1a-5b9d-4e8f-a1c3-2d4e6f8a0b1c", "mime_type": "application/pdf", "caption": "My receipt", "filename": "receipt-1001.pdf" } }, "context": null, "referral": null, "service_window_open_until": "2026-10-22T08:30:00Z" } } }, "received-sticker": { "summary": "A customer sent a sticker", "value": { "id": "evt_8a1d3c5e7f9b4d2a6c8e0f1a3b5c7d06", "type": "whatsapp.message.received", "timestamp": "2026-10-21T08:30:00.123456Z", "data": { "message_uuid": "9d4e1c7a-2b86-4f3d-b5a0-71e8c3f6a924", "from": "+447537151866", "to": "+14155550100", "profile_name": "Jane Smith", "content": { "type": "sticker", "sticker": { "id": "7f3e2c1a-5b9d-4e8f-a1c3-2d4e6f8a0b1c", "url": "https://api.wavix.com/v1/whatsapp/media/7f3e2c1a-5b9d-4e8f-a1c3-2d4e6f8a0b1c", "mime_type": "image/webp", "caption": null, "filename": null } }, "context": null, "referral": null, "service_window_open_until": "2026-10-22T08:30:00Z" } } }, "received-location": { "summary": "A customer shared a location", "value": { "id": "evt_8a1d3c5e7f9b4d2a6c8e0f1a3b5c7d07", "type": "whatsapp.message.received", "timestamp": "2026-10-21T08:30:00.123456Z", "data": { "message_uuid": "9d4e1c7a-2b86-4f3d-b5a0-71e8c3f6a924", "from": "+447537151866", "to": "+14155550100", "profile_name": "Jane Smith", "content": { "type": "location", "location": { "latitude": 51.5072, "longitude": -0.1276, "name": "Wavix office", "address": "1 Main Street, London" } }, "context": null, "referral": null, "service_window_open_until": "2026-10-22T08:30:00Z" } } }, "received-contacts": { "summary": "A customer shared a contact card", "value": { "id": "evt_8a1d3c5e7f9b4d2a6c8e0f1a3b5c7d08", "type": "whatsapp.message.received", "timestamp": "2026-10-21T08:30:00.123456Z", "data": { "message_uuid": "9d4e1c7a-2b86-4f3d-b5a0-71e8c3f6a924", "from": "+447537151866", "to": "+14155550100", "profile_name": "Jane Smith", "content": { "type": "contacts", "contacts": [ { "name": "Jane Smith", "phones": [ "+447700900123" ], "emails": [ "jane.smith@example.com" ] } ] }, "context": null, "referral": null, "service_window_open_until": "2026-10-22T08:30:00Z" } } }, "received-reaction": { "summary": "A customer reacted to your message", "value": { "id": "evt_8a1d3c5e7f9b4d2a6c8e0f1a3b5c7d09", "type": "whatsapp.message.received", "timestamp": "2026-10-21T08:30:00.123456Z", "data": { "message_uuid": "9d4e1c7a-2b86-4f3d-b5a0-71e8c3f6a924", "from": "+447537151866", "to": "+14155550100", "profile_name": "Jane Smith", "content": { "type": "reaction", "reaction": { "message_uuid": "3a525ca2-6909-4c72-9399-905adf7f3a74", "emoji": "👍" } }, "context": null, "referral": null, "service_window_open_until": "2026-10-22T08:30:00Z" } } }, "received-list-reply": { "summary": "A customer picked a list item", "value": { "id": "evt_8a1d3c5e7f9b4d2a6c8e0f1a3b5c7d0a", "type": "whatsapp.message.received", "timestamp": "2026-10-21T08:30:00.123456Z", "data": { "message_uuid": "9d4e1c7a-2b86-4f3d-b5a0-71e8c3f6a924", "from": "+447537151866", "to": "+14155550100", "profile_name": "Jane Smith", "content": { "type": "list_reply", "list_reply": { "id": "slot-morning", "title": "Morning, 9 to 12", "description": "Delivery between 9:00 and 12:00" } }, "context": { "message_uuid": "3a525ca2-6909-4c72-9399-905adf7f3a74" }, "referral": null, "service_window_open_until": "2026-10-22T08:30:00Z" } } }, "received-flow-response": { "summary": "A customer completed a WhatsApp Flow", "value": { "id": "evt_8a1d3c5e7f9b4d2a6c8e0f1a3b5c7d0b", "type": "whatsapp.message.received", "timestamp": "2026-10-21T08:30:00.123456Z", "data": { "message_uuid": "9d4e1c7a-2b86-4f3d-b5a0-71e8c3f6a924", "from": "+447537151866", "to": "+14155550100", "profile_name": "Jane Smith", "content": { "type": "flow_response", "flow_response": { "flow_token": "order-1001", "delivery_date": "2026-10-24", "time_slot": "morning" } }, "context": { "message_uuid": "3a525ca2-6909-4c72-9399-905adf7f3a74" }, "referral": null, "service_window_open_until": "2026-10-22T08:30:00Z" } } }, "sent": { "summary": "The message was sent", "value": { "id": "evt_4d6f8a0c2e4b6d8f0a1c3e5b7d9f1a3c", "type": "whatsapp.message.sent", "timestamp": "2026-10-21T08:30:01.250000Z", "data": { "message_uuid": "3a525ca2-6909-4c72-9399-905adf7f3a74", "from": "+14155550100", "to": "+447537151866", "template": { "name": "order_shipped", "language": "en_US" } } } }, "delivered": { "summary": "The message was delivered", "value": { "id": "evt_1b3d5f7a9c2e4b6d8f0a1c3e5b7d9f2a", "type": "whatsapp.message.delivered", "timestamp": "2026-10-21T08:31:05.000000Z", "data": { "message_uuid": "3a525ca2-6909-4c72-9399-905adf7f3a74", "from": "+14155550100", "to": "+447537151866", "template": { "name": "order_shipped", "language": "en_US" } } } }, "read": { "summary": "The recipient read the message", "value": { "id": "evt_5e7a9b1d3f5c4e6a8b0d2f4a6c8e0b1d", "type": "whatsapp.message.read", "timestamp": "2026-10-21T08:31:50.000000Z", "data": { "message_uuid": "3a525ca2-6909-4c72-9399-905adf7f3a74", "from": "+14155550100", "to": "+447537151866", "template": { "name": "order_shipped", "language": "en_US" } } } }, "failed": { "summary": "The message wasn't delivered", "value": { "id": "evt_7c9e1a3b5d7f4c2e8a0b2d4f6a8c0e1b", "type": "whatsapp.message.failed", "timestamp": "2026-10-21T08:32:40.000000Z", "data": { "message_uuid": "3a525ca2-6909-4c72-9399-905adf7f3a74", "from": "+14155550100", "to": "+447537151866", "template": { "name": "order_shipped", "language": "en_US" }, "status": "undelivered", "error": { "code": "RECIPIENT_NOT_ON_WHATSAPP", "subcode": "BLOCKED_BY_OPERATOR", "message": "This number can't receive WhatsApp messages from businesses.", "action": "do_not_resend", "docs_url": "https://docs.wavix.com/errors/recipient-not-on-whatsapp" } } } }, "marketing-stopped": { "summary": "The contact stopped marketing messages", "value": { "id": "evt_2a4c6e8a0c2e4a6c8e0a2c4e6a8c0e2a", "type": "whatsapp.contact.marketing_stopped", "timestamp": "2026-10-21T10:05:00.000000Z", "data": { "from": "+447537151866", "to": "+14155550100" } } }, "test": { "summary": "Test event", "value": { "id": "evt_3f6c0f5e9b2a4d7c8e1f0a2b3c4d5e6f", "type": "test", "timestamp": "2026-10-21T08:30:00.123456Z", "data": { "webhook_id": "6f1c2a4e-8b3d-4c5e-9f70-1a2b3c4d5e6f" } } } } } } }, "responses": { "200": { "description": "Your server acknowledges the event. Any 2xx status counts as delivered." } } } }, "WhatsAppTemplateChanged": { "post": { "summary": "WhatsApp template changed", "operationId": "whatsapp_template_changed", "security": [], "description": "Wavix sends these events to your webhook of the `templates` group when the review status, category, or quality rating of one of your templates changes, so you learn that a template is approved or rejected without polling it. A test event you send to the webhook arrives here too.\n\nEach change is a separate event, and `type` names it, so your server keeps its copy of a template's review status, category, and quality rating current.\n\n**Behavior:** Return a 2xx status within 10 seconds to acknowledge the event; Wavix doesn't follow redirects, so a 3xx response counts as a failed attempt. After a failed attempt, Wavix retries about 5 seconds, 30 seconds, 2 minutes, 10 minutes, 1 hour, 6 hours, and 24 hours later, up to 8 attempts in total; a `test` event isn't retried. Events can arrive more than once and out of order, so discard repeats by `id` and keep the state from the event with the latest `timestamp`.\n\n**Requires:** A webhook of the `templates` group. A disabled webhook gets only test events. Its URL must use `https`, have a valid TLS certificate, and resolve only to public addresses that Wavix allows. If the host resolves to another address at send time, Wavix doesn't send the event and doesn't retry it. Verify every request as the [Standard Webhooks](https://www.standardwebhooks.com/) specification describes, with one of its libraries or by hand. The `webhook-signature` and `webhook-timestamp` headers give the steps.\n\n**Limits:** [List WhatsApp events](https://docs.wavix.com/api-reference/whatsapp/list-whatsapp-events) keeps each event except `test` for 30 days, so you can catch up on events your server missed within that time.", "tags": [ "WhatsApp webhook payloads" ], "parameters": [ { "$ref": "#/components/parameters/WhatsAppWebhookIdHeader" }, { "$ref": "#/components/parameters/WhatsAppWebhookTimestampHeader" }, { "$ref": "#/components/parameters/WhatsAppWebhookSignatureHeader" } ], "requestBody": { "required": true, "description": "The event Wavix posts to your webhook URL.", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/WhatsAppTemplatesGroupEvent" }, "examples": { "approved": { "summary": "The template was approved", "value": { "id": "evt_4c6e8a0b2d4f4a6c8e0b2d4f6a8c0e2d", "type": "whatsapp.template.approved", "timestamp": "2026-10-21T09:12:44.000000Z", "data": { "template_uuid": "6b1f3c52-9e0a-4d7b-8a15-c2f4e9d07b38", "name": "order_shipped", "language": "en_US", "status": "approved", "category": "utility", "quality_rating": "unknown", "previous_attributes": { "status": "pending" } } } }, "category-changed": { "summary": "Meta moved the template to marketing", "value": { "id": "evt_6e8a0c2e4a6c4e8a0c2e4a6c8e0a2c4e", "type": "whatsapp.template.category_changed", "timestamp": "2026-10-22T07:40:02.000000Z", "data": { "template_uuid": "6b1f3c52-9e0a-4d7b-8a15-c2f4e9d07b38", "name": "order_shipped", "language": "en_US", "status": "approved", "category": "marketing", "quality_rating": "high", "previous_attributes": { "category": "utility" } } } }, "rejected": { "summary": "The template was rejected", "value": { "id": "evt_4c6e8a0b2d4f4a6c8e0b2d4f6a8c0e2e", "type": "whatsapp.template.rejected", "timestamp": "2026-10-21T09:15:02.000000Z", "data": { "template_uuid": "6b1f3c52-9e0a-4d7b-8a15-c2f4e9d07b38", "name": "order_shipped", "language": "en_US", "status": "rejected", "category": "utility", "quality_rating": "unknown", "previous_attributes": { "status": "pending" } } } }, "test": { "summary": "Test event", "value": { "id": "evt_3f6c0f5e9b2a4d7c8e1f0a2b3c4d5e6f", "type": "test", "timestamp": "2026-10-21T08:30:00.123456Z", "data": { "webhook_id": "6f1c2a4e-8b3d-4c5e-9f70-1a2b3c4d5e6f" } } } } } } }, "responses": { "200": { "description": "Your server acknowledges the event. Any 2xx status counts as delivered." } } } }, "WhatsAppSenderChanged": { "post": { "summary": "WhatsApp sender changed", "operationId": "whatsapp_sender_changed", "security": [], "description": "Wavix sends these events to your webhook of the `senders` group when the registration status or quality rating of one of your senders changes, so you learn that a sender is connected, restricted, or banned without polling it. Wavix reads the status and quality rating of senders from the provider every 15 minutes, so an event can arrive up to 15 minutes after the change. A test event you send to the webhook arrives here too.\n\nEach change is a separate event, and `type` names it, so your server keeps its copy of a sender's status and quality rating current.\n\n**Behavior:** Return a 2xx status within 10 seconds to acknowledge the event; Wavix doesn't follow redirects, so a 3xx response counts as a failed attempt. After a failed attempt, Wavix retries about 5 seconds, 30 seconds, 2 minutes, 10 minutes, 1 hour, 6 hours, and 24 hours later, up to 8 attempts in total; a `test` event isn't retried. Events can arrive more than once and out of order, so discard repeats by `id` and keep the state from the event with the latest `timestamp`.\n\n**Requires:** A webhook of the `senders` group. A disabled webhook gets only test events. Its URL must use `https`, have a valid TLS certificate, and resolve only to public addresses that Wavix allows. If the host resolves to another address at send time, Wavix doesn't send the event and doesn't retry it. Verify every request as the [Standard Webhooks](https://www.standardwebhooks.com/) specification describes, with one of its libraries or by hand. The `webhook-signature` and `webhook-timestamp` headers give the steps.\n\n**Limits:** [List WhatsApp events](https://docs.wavix.com/api-reference/whatsapp/list-whatsapp-events) keeps each event except `test` for 30 days, so you can catch up on events your server missed within that time.", "tags": [ "WhatsApp webhook payloads" ], "parameters": [ { "$ref": "#/components/parameters/WhatsAppWebhookIdHeader" }, { "$ref": "#/components/parameters/WhatsAppWebhookTimestampHeader" }, { "$ref": "#/components/parameters/WhatsAppWebhookSignatureHeader" } ], "requestBody": { "required": true, "description": "The event Wavix posts to your webhook URL.", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/WhatsAppSendersGroupEvent" }, "examples": { "connected": { "summary": "The sender finished registration", "value": { "id": "evt_9e1a3c5e7a9c4e1a3c5e7a9c1e3a5c7e", "type": "whatsapp.sender.connected", "timestamp": "2026-10-21T09:20:10.000000Z", "data": { "phone_number": "+14155550100", "status": "connected", "quality_rating": "unknown", "previous_attributes": { "status": "pending" } } } }, "quality-changed": { "summary": "The sender's quality rating dropped", "value": { "id": "evt_3c5e7a9c1e3a4c5e7a9c1e3a5c7e9a1c", "type": "whatsapp.sender.quality_changed", "timestamp": "2026-10-23T11:05:33.000000Z", "data": { "phone_number": "+14155550100", "status": "connected", "quality_rating": "medium", "previous_attributes": { "quality_rating": "high" } } } }, "test": { "summary": "Test event", "value": { "id": "evt_3f6c0f5e9b2a4d7c8e1f0a2b3c4d5e6f", "type": "test", "timestamp": "2026-10-21T08:30:00.123456Z", "data": { "webhook_id": "6f1c2a4e-8b3d-4c5e-9f70-1a2b3c4d5e6f" } } } } } } }, "responses": { "200": { "description": "Your server acknowledges the event. Any 2xx status counts as delivered." } } } } }, "components": { "securitySchemes": { "bearerAuth": { "type": "http", "scheme": "bearer", "description": "Wavix API key. Pass as `Authorization: Bearer `. Keys support per-resource scopes (none / read / write). See [Restricted keys and scopes](https://docs.wavix.com/api-reference/authentication#restricted-keys-and-scopes).\n" } }, "schemas": { "ApiKeyScopePermission": { "type": "object", "description": "Permission level for an API key scope group.", "properties": { "allow": { "type": "string", "enum": [ "none", "read", "write" ], "default": "none", "description": "Permission level:\n- `none`: no access\n- `read`: GET only\n- `write`: all methods (includes read)", "example": "read" } } }, "ApiKeyCallsScopePermission": { "type": "object", "description": "Permission level for the `calls` scope group.", "properties": { "allow": { "type": "string", "enum": [ "none", "read", "write" ], "default": "none", "description": "Permission level:\n- `none`: no access\n- `read`: GET requests, `POST /v1/cdrs`\n- `write`: all methods (includes read)", "example": "read" } } }, "ApiKey": { "type": "object", "description": "API key details including IP restrictions and scope permissions.", "required": [ "id", "label", "value", "active", "restricted", "permitted_ips", "scopes_enabled", "last_used_at", "numbers", "trunks", "calls", "messages", "recordings", "campaigns", "two_fa", "validator", "webhooks", "embeddable", "billing", "account", "subaccounts", "created_at" ], "properties": { "id": { "type": "integer", "description": "API key ID.", "example": 123 }, "label": { "type": "string", "description": "API key label.", "example": "Production API Key" }, "value": { "type": "string", "description": "API key value.", "example": "abc123def456ghi789jkl012mno345pqr678stu901vwx234yz" }, "active": { "type": "boolean", "description": "Indicates whether the API key is active.", "example": true }, "restricted": { "type": "boolean", "description": "Indicates whether IP restrictions are enabled. When enabled,\n the API key works only from IP addresses in `permitted_ips`.", "example": true }, "permitted_ips": { "type": "array", "items": { "type": "string" }, "description": "List of permitted IP addresses. If `restricted` is false,\n an empty list means no IP restrictions. If `restricted` is true,\n an empty list prevents all requests.", "example": [ "192.168.1.1", "10.0.0.1" ] }, "scopes_enabled": { "type": "boolean", "description": "When `true`, the key is restricted to the permissions defined in the\nscope fields below. When `false`, the key has full access.", "example": true }, "last_used_at": { "type": [ "string", "null" ], "format": "date-time", "description": "Timestamp of the most recent authenticated request made with this key.", "example": "2026-04-20T15:42:11Z" }, "numbers": { "anyOf": [ { "$ref": "#/components/schemas/ApiKeyScopePermission" }, { "type": "null" } ], "description": "View, buy, release, and configure phone numbers, browse inventory, and manage the cart." }, "trunks": { "anyOf": [ { "$ref": "#/components/schemas/ApiKeyScopePermission" }, { "type": "null" } ], "description": "View, create, update, and delete SIP trunks and their settings." }, "calls": { "anyOf": [ { "$ref": "#/components/schemas/ApiKeyCallsScopePermission" }, { "type": "null" } ], "description": "Access call records and active calls, and control live call actions such as starting, answering, ending, audio playback, DTMF, streaming, and transcription requests." }, "messages": { "anyOf": [ { "$ref": "#/components/schemas/ApiKeyScopePermission" }, { "type": "null" } ], "description": "Access message history and Sender IDs, send messages, manage opt-outs, and create or delete Sender IDs." }, "recordings": { "anyOf": [ { "$ref": "#/components/schemas/ApiKeyScopePermission" }, { "type": "null" } ], "description": "List, download, and delete call recordings." }, "campaigns": { "anyOf": [ { "$ref": "#/components/schemas/ApiKeyScopePermission" }, { "type": "null" } ], "description": "View campaign analytics and Sender ID or Brand status, schedule bulk voice or SMS campaigns, register Brands, and create short links." }, "two_fa": { "anyOf": [ { "$ref": "#/components/schemas/ApiKeyScopePermission" }, { "type": "null" } ], "description": "View 2FA service details and verification logs, trigger OTPs by voice or SMS, and validate verification codes." }, "validator": { "anyOf": [ { "$ref": "#/components/schemas/ApiKeyScopePermission" }, { "type": "null" } ], "description": "View number validation results and trigger single or bulk validation or HLR lookup requests." }, "webhooks": { "anyOf": [ { "$ref": "#/components/schemas/ApiKeyScopePermission" }, { "type": "null" } ], "description": "List, create, and delete webhooks." }, "embeddable": { "anyOf": [ { "$ref": "#/components/schemas/ApiKeyScopePermission" }, { "type": "null" } ], "description": "Manage widget tokens, including listing, viewing, creating, updating, and deleting them." }, "billing": { "anyOf": [ { "$ref": "#/components/schemas/ApiKeyScopePermission" }, { "type": "null" } ], "description": "Access statements, balance, payment methods, usage reports, and billing settings, including payment method updates." }, "account": { "anyOf": [ { "$ref": "#/components/schemas/ApiKeyScopePermission" }, { "type": "null" } ], "description": "View and update account profile information and timezone." }, "subaccounts": { "anyOf": [ { "$ref": "#/components/schemas/ApiKeyScopePermission" }, { "type": "null" } ], "description": "Manage subaccounts: list and view them, create, update, and suspend them." }, "created_at": { "type": "string", "format": "date-time", "description": "Creation date and time in ISO 8601 format.", "example": "2024-01-15T10:30:00Z" } } }, "UnauthorizedErrorResponse": { "title": "UnauthorizedErrorResponse", "type": "object", "properties": { "success": { "type": "boolean", "description": "Indicates whether the request was successful. Always `false` for this error.", "example": false }, "error": { "type": "boolean", "description": "Indicates that the response represents an error. Always `true` for this error.", "example": true }, "message": { "type": "string", "description": "Human-readable description stating that authentication is missing or invalid.", "example": "Unauthorized" } } }, "ForbiddenErrorResponse": { "title": "ForbiddenErrorResponse", "type": "object", "properties": { "success": { "type": "boolean", "description": "Indicates whether the request was successful. Always `false` for this error.", "example": false }, "message": { "type": "string", "description": "Human-readable description of why access is forbidden.", "example": "The service is not provisioned for your account." } } }, "ApiKeyCreateRequest": { "type": "object", "required": [ "label" ], "properties": { "label": { "type": "string", "description": "API key label.", "example": "My API key" }, "active": { "type": "boolean", "description": "Indicates whether the API key should be activated upon creation.", "default": true, "example": true }, "restricted": { "type": "boolean", "description": "Indicates whether to restrict API key access by IP address. When enabled, only requests from IP addresses listed in `permitted_ips` are allowed.", "default": false, "example": true }, "permitted_ips": { "type": "array", "items": { "type": "string" }, "description": "List of permitted IP addresses for this API key. Each must be a valid IPv4 address. Required when `restricted` is true.", "example": [ "192.168.1.1", "10.0.0.1" ] }, "scopes_enabled": { "type": "boolean", "description": "When `true`, scope fields below are enforced. When `false` (default), the\nkey has full access. Omitted scope fields default to `{ allow: none }`,\nso with `scopes_enabled: true` and no scopes set the key has no access.", "default": false, "example": true }, "numbers": { "allOf": [ { "$ref": "#/components/schemas/ApiKeyScopePermission" } ], "description": "View, buy, release, and configure phone numbers, browse inventory, and manage the cart.", "type": "object" }, "trunks": { "allOf": [ { "$ref": "#/components/schemas/ApiKeyScopePermission" } ], "description": "View, create, update, and delete SIP trunks and their settings.", "type": "object" }, "calls": { "allOf": [ { "$ref": "#/components/schemas/ApiKeyCallsScopePermission" } ], "description": "Access call records and active calls, and control live call actions such as starting, answering, ending, audio playback, DTMF, streaming, and transcription requests.", "type": "object" }, "messages": { "allOf": [ { "$ref": "#/components/schemas/ApiKeyScopePermission" } ], "description": "Access message history and Sender IDs, send messages, manage opt-outs, and create or delete Sender IDs.", "type": "object" }, "recordings": { "allOf": [ { "$ref": "#/components/schemas/ApiKeyScopePermission" } ], "description": "List, download, and delete call recordings.", "type": "object" }, "campaigns": { "allOf": [ { "$ref": "#/components/schemas/ApiKeyScopePermission" } ], "description": "View campaign analytics and Sender ID or Brand status, schedule bulk voice or SMS campaigns, register Brands, and create short links.", "type": "object" }, "two_fa": { "allOf": [ { "$ref": "#/components/schemas/ApiKeyScopePermission" } ], "description": "View 2FA service details and verification logs, trigger OTPs by voice or SMS, and validate verification codes.", "type": "object" }, "validator": { "allOf": [ { "$ref": "#/components/schemas/ApiKeyScopePermission" } ], "description": "View number validation results and trigger single or bulk validation or HLR lookup requests.", "type": "object" }, "webhooks": { "allOf": [ { "$ref": "#/components/schemas/ApiKeyScopePermission" } ], "description": "List, create, and delete webhooks.", "type": "object" }, "embeddable": { "allOf": [ { "$ref": "#/components/schemas/ApiKeyScopePermission" } ], "description": "Manage widget tokens, including listing, viewing, creating, updating, and deleting them.", "type": "object" }, "billing": { "allOf": [ { "$ref": "#/components/schemas/ApiKeyScopePermission" } ], "description": "Access statements, balance, payment methods, usage reports, and billing settings, including payment method updates.", "type": "object" }, "account": { "allOf": [ { "$ref": "#/components/schemas/ApiKeyScopePermission" } ], "description": "View and update account profile information and timezone.", "type": "object" }, "subaccounts": { "allOf": [ { "$ref": "#/components/schemas/ApiKeyScopePermission" } ], "description": "Manage subaccounts: list and view them, create, update, and suspend them.", "type": "object" } } }, "ApiKeyWithSecret": { "description": "API key details, including the secret `value`. Returned only at creation time —\nstore it securely, it cannot be retrieved again.", "allOf": [ { "$ref": "#/components/schemas/ApiKey" } ], "type": "object" }, "ValidationErrorResponse": { "title": "ValidationErrorResponse", "type": "object", "properties": { "success": { "type": "boolean", "description": "Indicates whether the request was successful. Always `false` for this error.", "example": false }, "message": { "type": "string", "description": "Human-readable description naming the missing or invalid request parameter.", "example": "Missing or invalid parameter " } } }, "SuccessResponse": { "title": "SuccessResponse", "required": [ "success" ], "type": "object", "properties": { "success": { "type": "boolean", "description": "Indicates whether the request was successful.", "example": true } } }, "NotFoundErrorResponse": { "title": "NotFoundErrorResponse", "type": "object", "properties": { "success": { "type": "boolean", "description": "Indicates whether the request was successful. Always `false` for this error.", "example": false }, "message": { "type": "string", "description": "Human-readable description stating that no resource matches the given ID.", "example": "Record not found" } } }, "ApiKeyUpdateRequest": { "title": "ApiKeyUpdateRequest", "type": "object", "additionalProperties": false, "description": "Fields to update on an API key. All fields are optional; only the provided fields are changed.", "properties": { "active": { "type": "boolean", "description": "Indicates whether the API key is active.", "example": true }, "restricted": { "type": "boolean", "description": "Indicates whether the API key is restricted to the listed permitted IPs.", "example": true }, "scopes_enabled": { "type": "boolean", "description": "Indicates whether per-resource scope permissions are enforced for the API key.", "example": true }, "permitted_ips": { "type": "array", "items": { "type": "string" }, "description": "IP addresses allowed to use the API key when restriction is enabled.", "example": [ "192.168.1.1", "10.0.0.1" ] }, "label": { "type": "string", "description": "Human-readable label for the API key.", "example": "Production API Key" }, "numbers": { "allOf": [ { "$ref": "#/components/schemas/ApiKeyScopePermission" } ], "description": "View, buy, release, and configure phone numbers, browse inventory, and manage the cart.", "type": "object" }, "trunks": { "allOf": [ { "$ref": "#/components/schemas/ApiKeyScopePermission" } ], "description": "View, create, update, and delete SIP trunks and their settings.", "type": "object" }, "calls": { "allOf": [ { "$ref": "#/components/schemas/ApiKeyCallsScopePermission" } ], "description": "Access call records and active calls, and control live call actions such as starting, answering, ending, audio playback, DTMF, streaming, and transcription requests.", "type": "object" }, "messages": { "allOf": [ { "$ref": "#/components/schemas/ApiKeyScopePermission" } ], "description": "Access message history and Sender IDs, send messages, manage opt-outs, and create or delete Sender IDs.", "type": "object" }, "recordings": { "allOf": [ { "$ref": "#/components/schemas/ApiKeyScopePermission" } ], "description": "List, download, and delete call recordings.", "type": "object" }, "campaigns": { "allOf": [ { "$ref": "#/components/schemas/ApiKeyScopePermission" } ], "description": "View campaign analytics and Sender ID or Brand status, schedule bulk voice or SMS campaigns, register Brands, and create short links.", "type": "object" }, "two_fa": { "allOf": [ { "$ref": "#/components/schemas/ApiKeyScopePermission" } ], "description": "View 2FA service details and verification logs, trigger OTPs by voice or SMS, and validate verification codes.", "type": "object" }, "validator": { "allOf": [ { "$ref": "#/components/schemas/ApiKeyScopePermission" } ], "description": "View number validation results and trigger single or bulk validation or HLR lookup requests.", "type": "object" }, "webhooks": { "allOf": [ { "$ref": "#/components/schemas/ApiKeyScopePermission" } ], "description": "List, create, and delete webhooks.", "type": "object" }, "embeddable": { "allOf": [ { "$ref": "#/components/schemas/ApiKeyScopePermission" } ], "description": "Manage widget tokens, including listing, viewing, creating, updating, and deleting them.", "type": "object" }, "billing": { "allOf": [ { "$ref": "#/components/schemas/ApiKeyScopePermission" } ], "description": "Access statements, balance, payment methods, usage reports, and billing settings, including payment method updates.", "type": "object" }, "account": { "allOf": [ { "$ref": "#/components/schemas/ApiKeyScopePermission" } ], "description": "View and update account profile information and timezone.", "type": "object" }, "subaccounts": { "allOf": [ { "$ref": "#/components/schemas/ApiKeyScopePermission" } ], "description": "Manage subaccounts: list and view them, create, update, and suspend them.", "type": "object" } } }, "SIPTrunkSummary": { "title": "SIPTrunkSummary", "required": [ "id", "name", "callerid", "multiple_numbers", "label", "auth_method", "host_request", "status", "talk_time", "charge", "access_token" ], "type": "object", "additionalProperties": false, "properties": { "id": { "type": "integer", "description": "Unique identifier of the SIP trunk on the platform", "format": "int32", "example": 293 }, "name": { "type": "string", "description": "System-generated login name of the SIP trunk", "example": "67758" }, "callerid": { "type": [ "string", "null" ], "description": "Caller ID associated with the SIP trunk. Contains `null` if no Caller ID is set, or an empty string if multiple Caller IDs are allowed.", "example": "12345678900" }, "label": { "type": "string", "description": "User-defined name of the SIP trunk", "example": "My trunk" }, "auth_method": { "description": "SIP trunk authentication method. Can be either `Digest` or `IP auth`.", "type": "string" }, "host_request": { "type": [ "object", "null" ], "description": "For SIP trunks with IP-based authentication, contains the status of the IP authentication request.", "properties": { "host": { "type": "string", "description": "The IP address submitted for authentication", "example": "127.0.0.1" }, "status": { "type": "string", "description": "Status of the IP authentication request", "example": "pending" } } }, "passthrough": { "type": "boolean", "description": "Indicates whether Caller ID passthrough is enabled for the SIP trunk", "example": false }, "multiple_numbers": { "type": "boolean", "description": "Indicates whether multiple Caller IDs are enabled for the SIP trunk", "example": false }, "status": { "type": "string", "description": "Status of the SIP trunk. Possible values are:\n`active` - The SIP trunk is active and can be used to place outbound calls.\n`pending` - The IP authentication request is under review by the Wavix team.\n`rejected` - The IP authentication request was rejected by the Wavix team.\nSIP trunks with a `pending` or `rejected` status can't be used to place calls." }, "talk_time": { "description": "Total duration of all outbound calls placed through the SIP trunk the current month, in seconds. Automatically resets at the beginning of each month.", "type": "integer", "format": "int32", "example": 65 }, "charge": { "description": "Total cost of all outbound calls placed through the SIP trunk in the current month, in USD. Automatically resets at the beginning of each month.", "type": "string", "example": "24.637" }, "call_recording_enabled": { "description": "Indicates whether outbound call recording is enabled for the SIP trunk", "type": "boolean", "default": false }, "machine_detection_enabled": { "description": "Indicates whether automatic voicemail detection is enabled for the SIP trunk.\nAvailable for `Flex Pro` customers only.", "type": "boolean", "default": false }, "transcription_enabled": { "description": "Indicates whether automatic call transcription is enabled for the SIP trunk.\nAvailable for `Flex Pro` customers only.", "type": "boolean", "default": false }, "transcription_threshold": { "description": "Minimum call duration (in seconds) required to automatically generate a transcription. Transcriptions are created for calls that meet or exceed this value.\nAvailable to `Flex Pro` customers only.", "type": "integer", "format": "int32", "default": 6 }, "encrypted_media": { "type": "boolean", "description": "Indicates whether SRTP media encryption is enabled for the SIP trunk.", "example": true }, "access_token": { "type": [ "string", "null" ], "description": "Static authentication token for the SIP trunk.", "example": "siped7a3f5c1b9e042d6f8a4c2e7b9d1f3a5c8e0b2d4f6a8c0e2d4b6f8a1c3e5d7" } }, "description": "A SIP trunk associated with the account.", "example": { "id": 3107, "label": "My trunk", "name": "32882", "auth_method": "Digest", "callerid": "14302287001", "host_request": null, "passthrough": false, "multiple_numbers": false, "status": "active", "charge": "24.637", "talk_time": 65, "machine_detection_enabled": true, "call_recording_enabled": true, "transcription_enabled": true, "transcription_threshold": 6, "access_token": "siped7a3f5c1b9e042d6f8a4c2e7b9d1f3a5c8e0b2d4f6a8c0e2d4b6f8a1c3e5d7" } }, "Pagination": { "title": "Pagination", "required": [ "current_page", "per_page", "total", "total_pages" ], "type": "object", "additionalProperties": false, "properties": { "current_page": { "type": "integer", "description": "Current page number.", "format": "int32", "example": 2 }, "per_page": { "type": "integer", "description": "Number of records per page.", "format": "int32", "example": 25 }, "total": { "type": "integer", "description": "Total number of records.", "format": "int32", "example": 101 }, "total_pages": { "type": "integer", "description": "Total number of pages.", "format": "int32", "example": 5 } } }, "SIPTrunkListResponse": { "title": "SIPTrunkListResponse", "required": [ "sip_trunks", "pagination" ], "type": "object", "additionalProperties": false, "properties": { "sip_trunks": { "type": [ "array", "null" ], "items": { "$ref": "#/components/schemas/SIPTrunkSummary" }, "description": "SIP trunks associated with the account." }, "pagination": { "$ref": "#/components/schemas/Pagination" } }, "example": { "sip_trunks": [ { "id": 3107, "label": "My trunk", "name": "32882", "auth_method": "IP auth", "callerid": "14302287001", "host_request": { "host": "127.0.0.1", "status": "pending" }, "encrypted_media": false, "passthrough": false, "multiple_numbers": true, "status": "pending", "charge": "24.637", "talk_time": 65, "machine_detection_enabled": true, "call_recording_enabled": true, "transcription_enabled": true, "transcription_threshold": 6, "access_token": "siped7a3f5c1b9e042d6f8a4c2e7b9d1f3a5c8e0b2d4f6a8c0e2d4b6f8a1c3e5d7" } ], "pagination": { "current_page": 1, "total": 1, "per_page": 25, "total_pages": 1 } } }, "SIPTrunkCreateRequest": { "title": "SIPTrunkCreateRequest", "required": [ "label", "password", "callerid", "ip_restrict", "didinfo_enabled", "call_restrict", "channels_restrict", "rewrite_enabled", "transcription_enabled", "transcription_threshold" ], "type": "object", "additionalProperties": false, "properties": { "label": { "type": "string", "description": "User-defined name of the SIP trunk", "example": "My trunk" }, "password": { "type": "string", "description": "Password set for the SIP trunk. A strong password helps keep the trunk secure.", "example": "4r=h;EaCB85QNtr2" }, "host_request": { "type": "object", "description": "For SIP trunks with IP authentication, includes the SIP endpoint public static IP address and the status of the authentication request. Wavix authenticates all SIP traffic originating from this IP address.", "additionalProperties": false, "required": [ "host" ], "properties": { "host": { "type": "string", "description": "SIP endpoint public static IP address", "example": "127.0.0.1" } } }, "callerid": { "type": "string", "description": "Caller ID associated with the SIP trunk. Must be an active or verified number on the account.", "example": "13132847320" }, "multiple_numbers": { "type": "boolean", "description": "Indicates whether any active or verified phone number on the account can be used as the Caller ID for the SIP trunk." }, "ip_restrict": { "type": "boolean", "description": "Indicates whether SIP trunk registration is allowed from only specific public static IP addresses. When set to `true`, the `allowed_ips` parameter must be provided.", "example": false }, "allowed_ips": { "type": [ "array", "null" ], "description": "A list of public static IP addresses allowed to register with the SIP trunk", "items": { "type": "object", "additionalProperties": false, "required": [ "ip" ], "properties": { "ip": { "type": "string", "description": "Public static IP address allowed to register with the SIP trunk.", "example": "127.0.0.1" } } } }, "didinfo_enabled": { "type": "boolean", "description": "Indicates whether inbound calls include dialed number information in the `To` header of SIP INVITE requests", "example": true }, "call_restrict": { "type": "boolean", "description": "Indicates whether a maximum call duration limit is enforced for the SIP trunk", "example": true }, "call_limit": { "type": "integer", "description": "Maximum call duration for the SIP trunk, in seconds. Must not exceed the maximum duration set for the account. Ignored when `call_restrict` is `false`.", "format": "int32", "example": 3600 }, "cost_limit": { "type": "boolean", "description": "Indicates if the max cost limit for an outbound call limit is activated for the SIP trunk.", "default": false, "example": true }, "max_call_cost": { "type": "number", "format": "decimal", "description": "Maximum cost for an outbound call, in USD", "example": 0.18 }, "channels_restrict": { "type": "boolean", "description": "Indicates whether a limit on the number of concurrent outbound calls is enforced for the SIP trunk", "example": false }, "max_channels": { "type": "integer", "description": "Maximum number of concurrent outbound calls for the SIP trunk. Must not exceed the outbound channel capacity set for the account. Ignored when `channels_restrict` is `false`.", "format": "int32", "example": 2 }, "rewrite_enabled": { "type": "boolean", "description": "Indicates whether a custom dial plan is activated for the SIP trunk", "example": true }, "rewrite_prefix": { "type": "string", "description": "Digits to automatically prepend to each dialed phone number", "example": "1" }, "rewrite_cond": { "type": "string", "description": "Number of leading digits to automatically remove from each dialed phone number" }, "call_recording_enabled": { "type": "boolean", "description": "Indicates whether outbound call recording is enabled for the SIP trunk", "example": true }, "transcription_enabled": { "type": "boolean", "description": "Indicates whether automatic call transcription is enabled for the SIP trunk.\nAvailable for `Flex Pro` customers only.", "example": true }, "transcription_threshold": { "type": "integer", "description": "Transcriptions will be generated for calls that meet or exceed the specified minimal call duration threshold, in seconds.\nAvailable for `Flex Pro` customers only.", "format": "int32", "example": 10 }, "machine_detection_enabled": { "type": "boolean", "description": "Indicates whether automatic voicemail detection is enabled for the SIP trunk.\nAvailable for `Flex Pro` customers only.", "example": true }, "encrypted_media": { "type": "boolean", "description": "Indicates whether SRTP media encryption is enabled for the SIP trunk.", "example": true } } }, "AllowedIPs": { "title": "AllowedIPs", "type": "array", "items": { "type": "object", "additionalProperties": false, "required": [ "id", "ip" ], "properties": { "id": { "type": "integer", "description": "IP address ID.", "format": "int32", "example": 6712 }, "ip": { "type": "string", "description": "Public static IP address.", "example": "127.0.0.1" } } } }, "SIPTrunkResponse": { "title": "SIPTrunkResponse", "required": [ "id", "name", "callerid", "label", "allowed_ips", "created_at" ], "type": "object", "additionalProperties": false, "properties": { "id": { "type": "integer", "description": "Unique identifier of the SIP trunk on the platform", "format": "int32", "example": 293 }, "name": { "type": "string", "description": "System-generated login name of the SIP trunk", "example": "67758" }, "callerid": { "type": [ "string", "null" ], "description": "Caller ID configured on the SIP trunk. Contains `null` if no Caller ID is set, or an empty string if multiple Caller IDs are allowed.", "example": "12345678900" }, "label": { "type": "string", "description": "User-defined name of the SIP trunk", "example": "My trunk" }, "ip_restrict": { "type": "boolean", "description": "Indicates whether IP restriction must be enabled on the SIP trunk", "default": false, "example": false }, "allowed_ips": { "$ref": "#/components/schemas/AllowedIPs" }, "channels_restrict": { "type": "boolean", "description": "Indicates if the max number of concurrent outbound calls limit is activated for the SIP trunk.", "default": false, "example": false }, "max_channels": { "type": [ "integer", "null" ], "description": "A maximum number of concurrent outbound calls placed via the SIP trunk. Cannot be higher than the outbound channel capacity configured on the account.", "format": "int32", "example": 2 }, "cost_limit": { "type": "boolean", "description": "Indicates if the max cost limit for an outbound call limit is activated for the SIP trunk.", "default": false, "example": true }, "max_call_cost": { "type": [ "string", "null" ], "description": "A maximum cost of an outbound call, in USD.", "example": "0.18" }, "call_restrict": { "type": [ "boolean", "null" ], "description": "Indicates if maximum call duration limit is activated for the SIP trunk.", "default": false, "example": false }, "call_limit": { "type": [ "integer", "null" ], "description": "A maximum call duration for the SIP trunk, in seconds. Cannot be higher than the max call duration set for the account.", "format": "int32", "example": 3600 }, "didinfo_enabled": { "type": "boolean", "description": "Indicates if inbound calls carry dialed number information in the 'To' header of SIP Invites", "default": true, "example": true }, "rewrite_enabled": { "type": "boolean", "description": "Indicates if a custom dial plan is activated for the SIP trunk.", "default": false, "example": true }, "rewrite_prefix": { "type": "string", "description": "Leading digits to be added before the dialed phone numbers.", "example": "1" }, "rewrite_cond": { "type": "string", "description": "Leading digits to be deleted from the dialed phone numbers." }, "call_recording_enabled": { "type": "boolean", "description": "Indicates if outbound call recording is enabled on the SIP trunk. Available for `Flex Pro` customers only.", "default": false, "example": true }, "machine_detection_enabled": { "type": "boolean", "description": "Indicates if automatic voicemail detection is enabled on the SIP trunk. Available for `Flex Pro` customers only.", "default": false, "example": true }, "transcription_enabled": { "type": "boolean", "description": "Indicates if automatic call transcription is enabled on the SIP trunk. Available for `Flex Pro` customers only.", "default": false, "example": false }, "transcription_threshold": { "type": "integer", "description": "Transcriptions will be generated for calls that meet or exceed the specified minimal call duration threshold, in seconds", "format": "int32", "default": 6, "example": 10 }, "created_at": { "type": "string", "description": "Date and time the SIP trunk was created", "format": "date-time", "example": "2023-05-16T17:13:25.000Z" }, "host": { "type": "string", "description": "Registration host for the SIP trunk. `dynamic` for credential-based registration, or a public static IP address for IP authentication.", "example": "dynamic" }, "multiple_numbers": { "type": "boolean", "description": "Indicates whether any active or verified phone number on the account can be used as the Caller ID for the SIP trunk.", "example": true }, "encrypted_media": { "type": "boolean", "description": "Indicates whether SRTP media encryption is enabled for the SIP trunk.", "example": true }, "passthrough": { "type": "boolean", "description": "Indicates whether Caller ID passthrough is enabled.", "example": true }, "access_token": { "type": [ "string", "null" ], "description": "Static authentication token for the SIP trunk.", "example": "123easwqe321132" } } }, "SIPTrunkUpdateRequest": { "title": "SIPTrunkUpdateRequest", "type": "object", "additionalProperties": false, "properties": { "label": { "type": "string", "description": "User-defined name of the SIP trunk", "example": "My trunk" }, "password": { "type": "string", "description": "Password set for the SIP trunk. A strong password helps keep the trunk secure.", "example": "4r=h;EaCB85QNtr2" }, "host_request": { "type": "object", "description": "For SIP trunks with IP authentication, the SIP endpoint public static IP address. Wavix authenticates all SIP traffic originating from this IP address. Ignored when the trunk already has a host request that is pending or approved. Not supported on trial accounts.", "additionalProperties": false, "required": [ "host" ], "properties": { "host": { "type": "string", "description": "SIP endpoint public static IP address", "example": "127.0.0.1" } } }, "callerid": { "type": "string", "description": "Caller ID associated with the SIP trunk. Must be an active or verified number on the account.", "example": "13132847320" }, "multiple_numbers": { "type": "boolean", "description": "Indicates whether any active or verified phone number on the account can be used as the Caller ID for the SIP trunk. Setting it to `true` clears the trunk's `callerid`; on a trunk with Caller ID passthrough (`passthrough`) enabled, `true` is ignored." }, "ip_restrict": { "type": "boolean", "description": "Indicates whether SIP trunk registration is allowed from only specific public static IP addresses. It can be `true` only when the trunk has at least one allowed IP address, either already stored or sent in `allowed_ips`.", "example": false }, "allowed_ips": { "type": [ "array", "null" ], "description": "Public static IP addresses to add to the list allowed to register with the SIP trunk. Addresses already on the list are kept.", "items": { "type": "object", "additionalProperties": false, "required": [ "ip" ], "properties": { "ip": { "type": "string", "description": "Public static IP address allowed to register with the SIP trunk.", "example": "127.0.0.1" } } } }, "didinfo_enabled": { "type": "boolean", "description": "Indicates whether inbound calls include dialed number information in the `To` header of SIP INVITE requests", "example": true }, "call_restrict": { "type": "boolean", "description": "Indicates whether a maximum call duration limit is enforced for the SIP trunk", "example": true }, "call_limit": { "type": "integer", "description": "Maximum call duration for the SIP trunk, in seconds. Must not exceed the maximum duration set for the account. Ignored when `call_restrict` is `false`.", "format": "int32", "example": 3600 }, "cost_limit": { "type": "boolean", "description": "Indicates if the max cost limit for an outbound call limit is activated for the SIP trunk.", "example": true }, "max_call_cost": { "type": "number", "format": "decimal", "description": "Maximum cost for an outbound call, in USD", "example": 0.18 }, "channels_restrict": { "type": "boolean", "description": "Indicates whether a limit on the number of concurrent outbound calls is enforced for the SIP trunk", "example": false }, "max_channels": { "type": "integer", "description": "Maximum number of concurrent outbound calls for the SIP trunk. Must not exceed the outbound channel capacity set for the account. Ignored when `channels_restrict` is `false`.", "format": "int32", "example": 2 }, "rewrite_enabled": { "type": "boolean", "description": "Indicates whether a custom dial plan is activated for the SIP trunk", "example": true }, "rewrite_prefix": { "type": "string", "description": "Digits to automatically prepend to each dialed phone number", "example": "1" }, "rewrite_cond": { "type": "string", "description": "Number of leading digits to automatically remove from each dialed phone number" }, "call_recording_enabled": { "type": "boolean", "description": "Indicates whether outbound call recording is enabled for the SIP trunk", "example": true }, "transcription_enabled": { "type": "boolean", "description": "Indicates whether automatic call transcription is enabled for the SIP trunk.\nAvailable for `Flex Pro` customers only.", "example": true }, "transcription_threshold": { "type": "integer", "description": "Transcriptions will be generated for calls that meet or exceed the specified minimal call duration threshold, in seconds.\nAvailable for `Flex Pro` customers only.", "format": "int32", "example": 10 }, "machine_detection_enabled": { "type": "boolean", "description": "Indicates whether automatic voicemail detection is enabled for the SIP trunk.\nAvailable for `Flex Pro` customers only.", "example": true }, "encrypted_media": { "type": "boolean", "description": "Indicates whether SRTP media encryption is enabled for the SIP trunk.", "example": true } } }, "Country": { "title": "Country", "required": [ "id", "name", "has_provinces_or_states" ], "type": "object", "additionalProperties": false, "properties": { "id": { "type": "integer", "description": "Country ID.", "format": "int32", "example": 8148 }, "name": { "type": "string", "description": "Country name.", "example": "France" }, "has_provinces_or_states": { "type": "boolean", "description": "Indicates whether the country has regions.", "example": false } } }, "CountryListResponse": { "title": "CountryListResponse", "required": [ "countries" ], "type": "object", "additionalProperties": false, "properties": { "countries": { "type": "array", "description": "Countries where phone numbers are available.", "items": { "$ref": "#/components/schemas/Country" } } } }, "Region": { "title": "Region", "required": [ "id", "name" ], "type": "object", "additionalProperties": false, "properties": { "id": { "type": "integer", "description": "Region ID.", "format": "int32", "example": 17 }, "name": { "type": "string", "description": "Region name.", "example": "California" } }, "description": "State or province of the country, if applicable." }, "RegionListResponse": { "title": "RegionListResponse", "required": [ "regions" ], "type": "object", "additionalProperties": false, "properties": { "regions": { "type": "array", "description": "States or provinces available for the requested country.", "items": { "$ref": "#/components/schemas/Region" } } } }, "CountryHasNoRegionsErrorResponse": { "title": "CountryHasNoRegionsErrorResponse", "type": "object", "properties": { "success": { "type": "boolean", "description": "Indicates whether the request succeeded.", "example": false }, "message": { "type": "string", "description": "Human-readable error message.", "example": "Country has no states or provinces" } } }, "City": { "title": "City", "required": [ "id", "name", "area_code" ], "type": "object", "additionalProperties": false, "properties": { "id": { "type": "integer", "description": "City ID.", "format": "int32", "example": 3213 }, "name": { "type": "string", "description": "City name.", "example": "Paris" }, "area_code": { "type": "number", "description": "Rate center." } } }, "CityListResponse": { "title": "CityListResponse", "required": [ "cities" ], "type": "object", "additionalProperties": false, "properties": { "cities": { "type": "array", "description": "Cities available for the requested country or region.", "items": { "$ref": "#/components/schemas/City" } } } }, "DocumentType": { "title": "DocumentType", "type": "string", "description": "Document type required to activate a phone number. One of: `id` - any form of ID,\n`address` - proof of address, `localaddress` - proof of local address within the country.", "enum": [ "id", "address", "localaddress" ] }, "AvailableNumber": { "title": "AvailableNumber", "required": [ "id", "activation_fee", "monthly_fee", "per_min", "channels", "city", "country", "country_short_name", "cnam", "free_min", "number", "require_docs", "sms_enabled", "sms_price" ], "type": "object", "additionalProperties": false, "properties": { "id": { "type": "integer", "description": "Phone number ID.", "format": "int64", "example": 541139862174 }, "activation_fee": { "type": "string", "description": "One-time activation fee in USD.", "example": "15.0" }, "monthly_fee": { "type": "string", "description": "Monthly fee in USD.", "example": "10.0" }, "per_min": { "type": "string", "description": "Price per inbound minute in USD.", "example": "0.01" }, "channels": { "type": "string", "description": "Maximum number of concurrent inbound calls.", "format": "int32", "example": "4" }, "city": { "type": "string", "description": "City where the phone number originates.", "example": "Buenos Aires" }, "country": { "type": "string", "description": "Country where the phone number originates.", "example": "Argentina" }, "country_short_name": { "type": "string", "description": "Two-letter ISO country code.", "example": "AR" }, "cnam": { "type": [ "boolean", "null" ], "description": "Indicates whether CNAM can be activated.", "example": false }, "free_min": { "type": "integer", "description": "Number of free inbound minutes.", "format": "int32", "example": 0 }, "number": { "type": "string", "description": "Phone number in E.164 format.", "example": "541139862174" }, "require_docs": { "type": "array", "items": { "$ref": "#/components/schemas/DocumentType" }, "description": "Documents to activate the number.", "example": [ "address" ] }, "sms_enabled": { "type": "boolean", "description": "Indicates whether the phone number can receive inbound\n SMS and MMS messages.", "example": false }, "sms_price": { "type": "number", "format": "float", "description": "Price per inbound SMS segment in USD.", "example": 0 }, "domestic_cli": { "type": "boolean", "description": "Indicates whether the number can be used as the Caller ID for local calls.", "example": true } }, "description": "Phone number available for purchase." }, "AvailableNumberListResponse": { "title": "AvailableNumberListResponse", "required": [ "dids", "pagination" ], "type": "object", "additionalProperties": false, "properties": { "dids": { "type": "array", "description": "Phone numbers available for purchase that match the search criteria.", "items": { "$ref": "#/components/schemas/AvailableNumber" } }, "pagination": { "$ref": "#/components/schemas/Pagination" } } }, "DocumentTypeInfo": { "title": "DocumentTypeInfo", "description": "Document type required to activate a phone number.", "required": [ "id", "name", "title" ], "type": "object", "additionalProperties": false, "properties": { "id": { "type": "integer", "format": "int32", "description": "Document type ID.", "example": 2 }, "name": { "$ref": "#/components/schemas/DocumentType" }, "title": { "type": "string", "description": "Document type name.", "example": "Proof of address" } } }, "CartResponse": { "title": "CartResponse", "required": [ "dids", "doc_types" ], "type": "object", "additionalProperties": false, "properties": { "dids": { "type": "array", "description": "List of phone numbers in the cart.", "items": { "$ref": "#/components/schemas/AvailableNumber" } }, "doc_types": { "type": "array", "items": { "$ref": "#/components/schemas/DocumentTypeInfo" }, "description": "Document types required to activate phone numbers." } } }, "InboundCallTransport": { "title": "InboundCallTransport", "enum": [ 1, 4, 5 ], "x-enum-varnames": [ "SIP_URI", "PSTN", "SIP_TRUNK" ], "type": "integer", "description": "Transport used to route the inbound call to its destination. One of `1` (SIP URI), `4` (PSTN phone number), or `5` (SIP trunk on the platform)." }, "InboundCallDestination": { "title": "InboundCallDestination", "required": [ "id", "destination", "priority", "transport", "trunk_id", "trunk_label" ], "type": "object", "additionalProperties": false, "properties": { "id": { "type": "integer", "description": "Unique identifier of the inbound call destination", "format": "int32", "example": 1 }, "destination": { "type": "string", "description": "The destination for inbound call routing. Can be either a SIP URI, a PSTN phone number or system-generated login of a SIP trunk on the platform.", "example": "[did]@sipuri.com" }, "priority": { "type": "integer", "description": "For phone numbers with several destinations, sets the order in which the platform routes inbound calls. The lower the value, the higher the priority.", "format": "int32", "example": 1 }, "transport": { "$ref": "#/components/schemas/InboundCallTransport" }, "trunk_id": { "type": [ "integer", "null" ], "description": "Unique identified of a SIP trunk on the platform. In cases when `transport:5`, otherwise, `null`", "format": "int32", "example": 23123 }, "srtp": { "type": "boolean", "description": "Indicates whether SRTP media encryption is enabled for this destination.", "example": false }, "trunk_label": { "type": [ "string", "null" ], "description": "A user-defined name of a SIP trunk on the platform. In cases when `transport:5`, otherwise, `null`", "example": "My trunk" } }, "description": "Inbound call destination" }, "NumberDocument": { "title": "NumberDocument", "required": [ "id", "allow_replace", "did_number", "doc_content_type", "doc_file_name", "doc_type", "status", "url" ], "type": "object", "additionalProperties": false, "properties": { "id": { "type": "integer", "description": "Unique identifier of the uploaded document", "format": "int32", "example": 1 }, "allow_replace": { "type": "boolean", "description": "Indicates whether the document can be replaced. Only documents with `rejected` status can be replaced.", "example": false }, "did_number": { "type": "string", "description": "The phone number the document was uploaded for", "example": "12565378257" }, "doc_content_type": { "type": "string", "description": "The uploaded content type identified by the platform", "example": "image/png" }, "doc_file_name": { "type": "string", "description": "The uploaded document name", "example": "Copy of ID.png" }, "doc_type": { "anyOf": [ { "$ref": "#/components/schemas/DocumentType" }, { "type": "null" } ], "description": "Document type." }, "status": { "type": "string", "description": "Status of the uploaded document. Can be either `approved`, `pending`, or `rejected`" }, "url": { "type": "string", "description": "A link to the uploaded document", "example": "https://api.wavix.com/v1/numbers/24882/papers/1\"" } }, "description": "A document uploaded for a phone number", "example": { "id": 423, "allow_replace": false, "did_number": "12565378257", "doc_content_type": "image/png", "doc_file_name": "Copy of ID.png", "doc_type": "id", "status": "approved", "url": "https://api.wavix.com/v1/numbers/24882/papers/1" } }, "Number": { "title": "Number", "required": [ "id", "number", "activation_fee", "monthly_fee", "per_min", "city", "country", "country_short_name", "destination", "channels", "require_docs", "documents", "label", "status", "seconds", "added", "paid_until", "sms_enabled", "sms_relay_url", "cnam", "call_recording_enabled", "transcription_enabled", "transcription_threshold", "domestic_cli" ], "type": "object", "additionalProperties": false, "properties": { "id": { "type": "integer", "format": "int32", "description": "Phone number ID.", "example": 123 }, "number": { "type": "string", "description": "Phone number.", "example": "12565378257" }, "activation_fee": { "type": "string", "description": "One-time activation fee in USD.", "example": "0.99" }, "monthly_fee": { "type": "string", "description": "Monthly fee in USD.", "example": "0.99" }, "per_min": { "type": "string", "description": "Price per inbound minute in USD.", "example": "0.01" }, "city": { "type": "string", "description": "City or rate center where the phone number originates.", "example": "DETROIT, MI" }, "state": { "type": [ "string", "null" ], "description": "State where the phone number originates. For non-US numbers, this field may be null." }, "country": { "type": "string", "description": "Country where the phone number originates.", "example": "United States" }, "country_short_name": { "type": "string", "description": "Two-letter ISO country code.", "example": "US" }, "destination": { "type": "array", "items": { "$ref": "#/components/schemas/InboundCallDestination" }, "description": "Inbound call destinations set for the phone number." }, "channels": { "type": "integer", "format": "int32", "description": "Maximum number of concurrent inbound calls.", "example": 24 }, "require_docs": { "type": "array", "items": { "$ref": "#/components/schemas/DocumentType" }, "description": "Documents to activate the number.", "example": [ "address" ] }, "documents": { "type": "array", "items": { "$ref": "#/components/schemas/NumberDocument" }, "description": "Uploaded documents." }, "domestic_cli": { "type": "boolean", "description": "Indicates whether the number can be used as the Caller ID for local calls." }, "free_min": { "type": "integer", "description": "Number of free inbound minutes." }, "unlimited": { "type": "boolean", "description": "Indicates whether usage is unlimited." }, "label": { "type": [ "string", "null" ], "description": "Label assigned to the phone number." }, "status": { "type": "string", "description": "Phone number status. `active` means the number can receive and place calls; `inactive` means it cannot." }, "seconds": { "type": "string", "description": "Total inbound call duration in seconds for current month." }, "added": { "type": "string", "format": "date-time", "description": "Date and time the phone number was purchased in ISO 8601 format.", "example": "2023-04-10T06:42:59.000Z" }, "paid_until": { "type": "string", "format": "date", "description": "Date until which the number is paid.", "example": "2023-12-07" }, "sms_enabled": { "type": "boolean", "description": "Indicates whether SMS is enabled.", "example": false }, "sms_relay_url": { "type": [ "string", "null" ], "description": "Callback URL for inbound SMS and MMS messages.", "example": "https://your-website.com/webhook" }, "cnam": { "type": [ "boolean", "null" ], "description": "Indicates whether CNAM is enabled.", "example": true }, "call_recording_enabled": { "type": "boolean", "description": "Indicates whether call recording is enabled.", "example": true }, "transcription_enabled": { "type": "boolean", "description": "Indicates whether transcription is enabled.", "example": true }, "transcription_threshold": { "type": "integer", "format": "int32", "description": "Minimum call duration in seconds to trigger transcription.", "example": 6 }, "call_status_url": { "type": [ "string", "null" ], "description": "Callback URL for call status updates.", "example": "https://example.com" } } }, "NumberListResponse": { "title": "NumberListResponse", "required": [ "items", "doc_types", "pagination" ], "type": "object", "additionalProperties": false, "properties": { "items": { "type": "array", "items": { "$ref": "#/components/schemas/Number" }, "description": "List of phone numbers on the account." }, "doc_types": { "type": "array", "items": { "$ref": "#/components/schemas/DocumentTypeInfo" }, "description": "Documents required to activate phone numbers." }, "pagination": { "$ref": "#/components/schemas/Pagination" } } }, "NumberDestination": { "title": "NumberDestination", "required": [ "destination", "priority", "transport" ], "type": "object", "additionalProperties": false, "properties": { "destination": { "type": "string", "description": "SIP URI, PSTN number, or SIP trunk login for inbound call routing.", "example": "[did]@sipuri.com" }, "priority": { "type": "integer", "format": "int32", "description": "Destination priority (lower is higher priority).", "example": 1 }, "transport": { "$ref": "#/components/schemas/InboundCallTransport" }, "trunk_id": { "type": [ "integer", "null" ], "format": "int32", "description": "SIP trunk ID when `transport` is 5, otherwise null.", "example": 23123 } }, "description": "Inbound call destination", "example": { "destination": "32882", "priority": 1, "transport": 5, "trunk_id": 3107 } }, "NumberBulkUpdateRequest": { "title": "NumberBulkUpdateRequest", "type": "object", "required": [ "ids" ], "additionalProperties": false, "description": "A single patch applied to every listed phone number. All mutable fields are optional.", "properties": { "ids": { "type": "array", "items": { "type": "integer" }, "description": "Numbers (by ID) to apply the patch to. The same patch is\napplied to every listed number.", "example": [ 123, 456 ] }, "sms_enabled": { "type": "boolean", "description": "Indicates whether SMS is enabled for the phone numbers.", "example": true }, "destinations": { "type": "array", "items": { "$ref": "#/components/schemas/NumberDestination" }, "description": "Inbound call routing destinations for the phone numbers." }, "sms_relay_url": { "type": [ "string", "null" ], "format": "uri", "description": "Callback URL for inbound messages. Pass `null` to clear it.", "example": "https://your-site.com/sms" }, "call_recording_enabled": { "type": "boolean", "description": "Indicates whether call recording is enabled.", "example": true }, "transcription_enabled": { "type": "boolean", "description": "Indicates whether call transcription is enabled.", "example": true }, "transcription_threshold": { "type": "integer", "description": "Minimum call duration in seconds before transcription runs.", "example": 30 }, "call_status_url": { "type": "string", "format": "uri", "description": "Callback URL for call status updates.", "example": "https://your-site.com/calls" } } }, "NumberUpdateRequest": { "title": "NumberUpdateRequest", "type": "object", "additionalProperties": false, "description": "Fields to update on a phone number. All fields are optional; only the provided fields are changed.", "properties": { "sms_enabled": { "type": "boolean", "description": "Indicates whether SMS is enabled for the phone number.", "example": true }, "destinations": { "type": "array", "items": { "$ref": "#/components/schemas/NumberDestination" }, "description": "Inbound call routing destinations for the phone number." }, "sms_relay_url": { "type": [ "string", "null" ], "format": "uri", "description": "Callback URL for inbound messages. Pass `null` to clear it.", "example": "https://your-site.com/sms" }, "expected_sms_relay_url": { "type": "string", "description": "Applies the `sms_relay_url` change only if the number currently has this URL. Pass an empty string to set it only while it is unset, or your own URL to clear or replace it. Requires `sms_relay_url`.", "example": "" }, "call_recording_enabled": { "type": "boolean", "description": "Indicates whether call recording is enabled.", "example": true }, "transcription_enabled": { "type": "boolean", "description": "Indicates whether call transcription is enabled.", "example": true }, "transcription_threshold": { "type": "integer", "description": "Minimum call duration in seconds before transcription runs.", "example": 30 }, "call_status_url": { "type": "string", "format": "uri", "description": "Callback URL for call status updates.", "example": "https://your-site.com/calls" } } }, "WebhookInUseErrorResponse": { "title": "WebhookInUseErrorResponse", "type": "object", "required": [ "success", "error", "message" ], "description": "Error returned when a webhook change is rejected because the webhook no longer has the expected URL.", "properties": { "success": { "type": "boolean", "description": "Indicates whether the request was successful. Always `false` for this error.", "example": false }, "error": { "type": "boolean", "description": "Indicates that the request failed. Always `true` for this error.", "example": true }, "message": { "type": "string", "description": "Human-readable description of the conflict.", "example": "Webhook already in use" } } }, "CallDisposition": { "title": "CallDisposition", "enum": [ "answered", "noanswer", "busy", "failed", "all" ], "type": "string", "description": "Final disposition of the call. One of `answered` (the called party answered), `noanswer` (no answer within the ring timeout), `busy` (the called party was busy), `failed` (the call could not be routed), or `all` (matches any disposition when used as a filter)." }, "CDR": { "title": "CDR", "description": "Call detail record (CDR) for an individual call.", "required": [ "date", "from", "to", "disposition", "duration", "destination", "per_minute", "charge", "uuid", "call_id" ], "type": "object", "additionalProperties": false, "properties": { "date": { "type": "string", "format": "date-time", "description": "Date and time of the call in ISO 8601 format.", "example": "2023-08-21T06:43:36.000Z" }, "from": { "type": "string", "description": "Originating phone number (ANI).", "example": "14302287001" }, "to": { "type": "string", "description": "Destination phone number (DNIS).", "example": "33170363950" }, "disposition": { "$ref": "#/components/schemas/CallDisposition" }, "duration": { "type": "integer", "format": "int32", "description": "Call duration in seconds.", "example": 6 }, "destination": { "type": "string", "description": "Destination of the call. For outbound calls,\n contains the country name and, optionally, a mobile carrier\n or city name. For inbound calls, includes the SIP trunk name,\n SIP URI, or PSTN number the call is forwarded to.", "example": "France" }, "per_minute": { "type": "string", "description": "Price per minute in USD.", "example": "0.027" }, "charge": { "type": "string", "description": "Total charge for the call in USD.", "example": "0.822" }, "sip_trunk": { "type": [ "string", "null" ], "description": "System-generated SIP trunk login. For outbound calls only.", "example": "32882" }, "forward_fee": { "type": "string", "description": "PSTN forwarding price in USD. For inbound calls only when forwarded to PSTN.", "example": "0.0" }, "uuid": { "type": "string", "deprecated": true, "description": "Call ID. Deprecated — use `call_id` instead.", "example": "99df5ffd-962a-410f-bcce-d08f1f7f328c" }, "call_id": { "type": "string", "description": "Call ID. Alias of `uuid`.", "example": "99df5ffd-962a-410f-bcce-d08f1f7f328c" }, "parent_uuid": { "type": [ "string", "null" ], "deprecated": true, "description": "Parent call ID. Deprecated — use `parent_call_id` instead.", "example": "99df5ffd-962a-410f-bcce-d08f1f7f328c" }, "parent_call_id": { "type": [ "string", "null" ], "description": "Parent call ID. Alias of `parent_uuid`.", "example": "99df5ffd-962a-410f-bcce-d08f1f7f328c" }, "answered_by": { "type": [ "string", "null" ], "description": "Who answered the call. Possible values are `human`, `machine`.", "example": "human" } } }, "CDRListResponse": { "title": "CDRListResponse", "required": [ "items", "pagination" ], "type": "object", "additionalProperties": false, "properties": { "items": { "type": "array", "items": { "$ref": "#/components/schemas/CDR" }, "description": "List of CDRs" }, "pagination": { "$ref": "#/components/schemas/Pagination" } } }, "TranscriptionFilter": { "title": "TranscriptionFilter", "type": "object", "additionalProperties": false, "properties": { "agent": { "type": "object", "description": "Search in an agent's spoken words and phrases", "properties": { "must": { "type": "array", "items": { "type": "string", "example": "Hello" }, "description": "Only calls with transcription that includes all of the specified keywords and phrases are returned. The listed keywords and phrases are combined using logical AND", "example": [ "Hello", "Thank you" ] }, "match": { "type": "array", "items": { "type": "string", "example": "Nope" }, "description": "Only calls with transcription that includes any of the specified keywords and phrases are returned. The listed keywords and phrases are combined using logical OR", "example": [ "Nope", "Maybe" ] }, "exclude": { "type": "array", "items": { "type": "string", "example": "Richard" }, "description": "Only calls with transcription that does not include any of the specified keywords and phrases are returned. The listed keywords and phrases are combined using logical OR", "example": [ "Richard", "Issue resolved" ] } } }, "client": { "type": "object", "description": "Search in an customer's spoken words and phrases", "properties": { "must": { "type": "array", "items": { "type": "string", "example": "Hello" }, "description": "Only calls with transcription that includes all of the specified keywords and phrases are returned. The listed keywords and phrases are combined using logical AND", "example": [ "Hello", "Thank you" ] }, "match": { "type": "array", "items": { "type": "string", "example": "Nope" }, "description": "Only calls with transcription that includes any of the specified keywords and phrases are returned. The listed keywords and phrases are combined using logical OR", "example": [ "Nope", "Maybe" ] }, "exclude": { "type": "array", "items": { "type": "string", "example": "Richard" }, "description": "Only calls with transcription that does not include any of the specified keywords and phrases are returned. The listed keywords and phrases are combined using logical OR", "example": [ "Richard", "Issue resolved" ] } } }, "any": { "type": "object", "description": "Search in both speakers' spoken words and phrases", "properties": { "must": { "type": "array", "items": { "type": "string", "example": "Hello" }, "description": "Only calls with transcription that includes all of the specified keywords and phrases are returned. The listed keywords and phrases are combined using logical AND", "example": [ "Hello", "Thank you" ] }, "match": { "type": "array", "items": { "type": "string", "example": "Nope" }, "description": "Only calls with transcription that includes any of the specified keywords and phrases are returned. The listed keywords and phrases are combined using logical OR", "example": [ "Nope", "Maybe" ] }, "exclude": { "type": "array", "items": { "type": "string", "example": "Richard" }, "description": "Only calls with transcription that does not include any of the specified keywords and phrases are returned. The listed keywords and phrases are combined using logical OR", "example": [ "Richard", "Issue resolved" ] } } } } }, "CDRSearchRequest": { "title": "CDRSearchRequest", "required": [ "type", "from", "to" ], "type": "object", "additionalProperties": false, "properties": { "type": { "type": "string", "enum": [ "placed", "received" ], "description": "Filters by call type. One of `placed` (outbound calls dialed by the account) or `received` (inbound calls answered by the account).", "example": "placed" }, "from": { "type": "string", "format": "date", "description": "Start date for call search in `YYYY-MM-DD` format.", "example": "2023-08-01" }, "to": { "type": "string", "format": "date", "description": "End date for call search in `YYYY-MM-DD` format.", "example": "2023-08-31" }, "from_search": { "type": "string", "description": "Originating phone number to filter results. Accepts full or partial number.", "example": "4478012" }, "to_search": { "type": "string", "description": "Destination phone number to filter results. Accepts full or partial number.", "example": "44206723" }, "sip_trunk": { "type": "string", "description": "SIP trunk login to filter outbound calls. Ignored for inbound calls.", "example": "87095" }, "min_duration": { "type": "integer", "format": "int32", "description": "Minimum call duration in seconds.", "example": 10 }, "transcription": { "$ref": "#/components/schemas/TranscriptionFilter" }, "uuid": { "type": "string", "description": "Call ID.", "example": "99df5ffd-962a-410f-bcce-d08f1f7f328c" }, "disposition": { "$ref": "#/components/schemas/CallDisposition", "description": "Call disposition to filter results. If omitted, returns only answered\n calls. Allowed values: `answered`, `noanswer`, `busy`,\n `failed`, `all`. Use `all` to return calls\n regardless of their disposition.\n", "type": "string" }, "page": { "type": "integer", "format": "int32", "description": "Page number to retrieve.", "default": 1, "example": 1 }, "per_page": { "type": "integer", "format": "int32", "description": "Number of records per page.", "default": 25, "example": 25 } } }, "TranscriptionReference": { "title": "TranscriptionReference", "required": [ "uuid", "url" ], "type": [ "object", "null" ], "additionalProperties": false, "properties": { "uuid": { "type": "string", "description": "Unique identifier of the call transcription.", "example": "40d6f322-048d-490b-95c7-4fc5c76a74db" }, "url": { "type": "string", "description": "URL for retrieving the full call transcription.", "example": "https://api.wavix.com/v1/cdrs/40d6f322-048d-490b-95c7-4fc5c76a74db/transcription?appid=secret" } } }, "CDRWithTranscription": { "title": "CDRWithTranscription", "required": [ "date", "from", "to", "disposition", "duration", "destination", "per_minute", "charge", "uuid", "call_id", "transcription" ], "type": "object", "additionalProperties": false, "properties": { "answered_by": { "type": [ "string", "null" ], "description": "Who answered the call. Allowed values are `human`, `machine`.", "example": "human" }, "date": { "type": "string", "description": "Date and time of the call", "format": "date-time", "example": "2023-08-21T06:43:36.000Z" }, "from": { "type": "string", "description": "ANI/From attribute of the call", "example": "14302287001" }, "to": { "type": "string", "description": "DNIS/To attribute of the call", "example": "33170363950" }, "disposition": { "$ref": "#/components/schemas/CallDisposition" }, "duration": { "type": "integer", "description": "Duration of the call, in seconds", "format": "int32", "example": 6 }, "destination": { "type": "string", "description": "Destination of the call. For outbound calls, it contains the country name and, optionally, a mobile carrier or city name. For inbound calls, the destination includes the user-defined SIP trunk name, SIP URI, or PSTN number that the call is forwarded to.", "example": "France" }, "per_minute": { "type": "string", "description": "Price per minute, in USD", "example": "0.027" }, "charge": { "type": "string", "description": "Total charge for the call, in USD" }, "sip_trunk": { "type": [ "string", "null" ], "description": "System-generated login of a SIP trunk. For `placed` calls only.", "example": "32882" }, "forward_fee": { "type": "string", "description": "PSTN forwarding price, in USD. For `received` calls only when forwarded to PSTN.", "example": "0.0" }, "uuid": { "type": "string", "deprecated": true, "description": "Call ID. Deprecated — use `call_id` instead.", "example": "99df5ffd-962a-410f-bcce-d08f1f7f328c" }, "call_id": { "type": "string", "description": "Call ID. Alias of `uuid`.", "example": "99df5ffd-962a-410f-bcce-d08f1f7f328c" }, "parent_uuid": { "type": [ "string", "null" ], "deprecated": true, "description": "Parent call ID. Deprecated — use `parent_call_id` instead.", "example": "99df5ffd-962a-410f-bcce-d08f1f7f328c" }, "parent_call_id": { "type": [ "string", "null" ], "description": "Parent call ID. Alias of `parent_uuid`.", "example": "99df5ffd-962a-410f-bcce-d08f1f7f328c" }, "transcription": { "$ref": "#/components/schemas/TranscriptionReference" } }, "description": "A CDR of a single call with call transcription" }, "CDRTranscriptionSearchResponse": { "title": "CDRTranscriptionSearchResponse", "required": [ "items", "pagination" ], "type": "object", "additionalProperties": false, "properties": { "items": { "type": "array", "items": { "$ref": "#/components/schemas/CDRWithTranscription" }, "description": "List of CDRs with transcription links." }, "pagination": { "$ref": "#/components/schemas/Pagination" } } }, "TranscriptionLanguage": { "title": "TranscriptionLanguage", "enum": [ "en", "de", "es", "fr", "it", null ], "type": [ "string", "null" ], "description": "Language of the transcription, as a two-letter ISO 639-1 code. One of `en` (English), `de` (German), `es` (Spanish), `fr` (French), or `it` (Italian). `null` lets the platform auto-detect the language." }, "CDRRetranscriptionRequest": { "title": "CDRRetranscriptionRequest", "type": "object", "additionalProperties": false, "properties": { "language": { "$ref": "#/components/schemas/TranscriptionLanguage" }, "webhook_url": { "type": "string", "description": "Webhook URL to receive status updates.", "example": "https://site.webhook" } } }, "TranscriptTurn": { "title": "TranscriptTurn", "type": "object", "additionalProperties": false, "properties": { "type": { "type": "string", "description": "Phone number of the speaker attributed to this turn, in E.164 format.", "example": "13132847320" }, "s": { "type": "integer", "description": "Start of the `turn`, in milliseconds. The start time is calculated from the moment the call was answered.", "format": "int32", "example": 3000 }, "e": { "type": "integer", "description": "End of the `turn`, in milliseconds. The end time is calculated from the moment the call was answered.", "format": "int32", "example": 18000 }, "text": { "type": "string", "description": "Transcribed text attributed to the speaker for this turn.", "example": "Hi there, how are you?" }, "sentiment": { "type": "string", "description": "Sentiment detected in the speaker's text for this turn, such as `neutral`, `positive`, or `negative`.", "example": "neutral" }, "topics": { "type": "array", "description": "Topics detected in the speaker's text for this turn. Empty when no topic was detected.", "items": { "type": "string" }, "example": [ "billing" ] } }, "description": "Represents a single turn in a call transcript. Each turn carries the text attributed to one speaker, with the start and end times for that text." }, "TranscriptionStatus": { "title": "TranscriptionStatus", "enum": [ "completed", "failed" ], "type": "string", "description": "Outcome of the transcription. One of `completed` (the transcript was produced) or `failed` (the transcription could not be produced)." }, "CDRTranscriptionResponse": { "title": "CDRTranscriptionResponse", "required": [ "transcript", "turns", "uuid", "language", "duration", "charge", "status", "transcription_date", "call_date", "call_uuid", "call_score", "call_summary" ], "type": "object", "additionalProperties": false, "properties": { "transcript": { "type": "object", "description": "Mapping of phone numbers in the call to transcript text.", "additionalProperties": { "type": "string" }, "example": { "16572026750": "", "16465292513": "" } }, "turns": { "type": "array", "description": "List of speaker turns with text and start/end times.", "items": { "$ref": "#/components/schemas/TranscriptTurn" }, "example": [ { "type": "46844685344", "s": 160, "e": 7280, "text": "Hello, how can I help you?" }, { "type": "+16572026750", "s": 2400, "e": 3280, "text": "Hello, I have a question about my bill." } ] }, "uuid": { "type": "string", "description": "Transcription ID.", "example": "e84f350f-6da7-4b56-80eb-41dec572626b" }, "language": { "$ref": "#/components/schemas/TranscriptionLanguage" }, "duration": { "type": "integer", "description": "Call duration in seconds.", "format": "int32", "example": 102 }, "charge": { "type": "string", "description": "Total charge for the transcription in USD.", "example": "0.01" }, "status": { "$ref": "#/components/schemas/TranscriptionStatus" }, "transcription_date": { "type": "string", "description": "Date and time when the transcription was processed in ISO 8601 format.", "format": "date-time", "example": "2023-01-09T10:04:39.734Z" }, "call_date": { "type": "string", "description": "Date and time when the call was placed or received in ISO 8601 format.", "format": "date-time", "example": "2023-01-09T10:01:13.394Z" }, "call_uuid": { "type": "string", "description": "Associated call ID.", "example": "bbaa37bf-430a-46da-ade3-c248e4070161" }, "call_score": { "type": "string", "description": "Call sentiment score. Indicates negative (1.0-3.0), neutral,\n or positive (4.0-5.0).", "example": "3.8" }, "call_summary": { "type": "string", "description": "One- or two-sentence call summary.", "example": "The agent and client discussed billing issues." } } }, "CDRResponse": { "title": "CDRResponse", "required": [ "date", "from", "to", "disposition", "duration", "destination", "per_minute", "charge", "uuid", "call_id" ], "type": "object", "additionalProperties": false, "properties": { "date": { "type": [ "string", "null" ], "description": "Call date and time in ISO 8601 format.", "format": "date-time", "example": "2023-08-21T06:43:36.000Z" }, "from": { "type": "string", "description": "Caller ID (ANI).", "example": "14302287001" }, "to": { "type": "string", "description": "Dialed number (DNIS).", "example": "33170363950" }, "disposition": { "$ref": "#/components/schemas/CallDisposition" }, "duration": { "type": "integer", "description": "Call duration in seconds.", "format": "int32", "example": 6 }, "destination": { "type": [ "string", "null" ], "description": "Destination of the call. For outbound calls,\n contains the country name and, optionally, a mobile carrier\n or city name. For inbound calls, includes the SIP trunk name,\n SIP URI, or PSTN number the call is forwarded to.", "example": "France" }, "per_minute": { "type": [ "string", "null" ], "description": "Price per minute in USD.", "example": "0.027" }, "recording_url": { "type": [ "string", "null" ], "description": "URL of the recorded call file. Call recording can be enabled\n on a SIP trunk for outbound calls and on\n a phone number for inbound calls.", "example": "https://api.wavix.com/v1/recordings/recording_id" }, "charge": { "type": [ "string", "null" ], "description": "Total charge for the call in USD.", "example": "0.162" }, "sip_trunk": { "type": [ "string", "null" ], "description": "System-generated SIP trunk login. For outbound calls only.", "example": "32882" }, "forward_fee": { "type": "string", "description": "PSTN forwarding price in USD. For inbound calls only\n when forwarded to PSTN.", "example": "0.0" }, "uuid": { "type": "string", "deprecated": true, "description": "Call ID. Deprecated — use `call_id` instead.", "example": "99df5ffd-962a-410f-bcce-d08f1f7f328c" }, "call_id": { "type": "string", "description": "Call ID. Alias of `uuid`.", "example": "99df5ffd-962a-410f-bcce-d08f1f7f328c" }, "parent_uuid": { "type": [ "string", "null" ], "deprecated": true, "description": "Parent call ID. Deprecated — use `parent_call_id` instead.", "example": "99df5ffd-962a-410f-bcce-d08f1f7f328c" }, "parent_call_id": { "type": [ "string", "null" ], "description": "Parent call ID. Alias of `parent_uuid`.", "example": "99df5ffd-962a-410f-bcce-d08f1f7f328c" }, "answered_by": { "type": [ "string", "null" ], "description": "Who answered the call. Possible values are `human`, `machine`.", "example": "human" }, "transcription": { "$ref": "#/components/schemas/TranscriptionReference" } } }, "Recording": { "title": "Recording", "required": [ "id", "created_at", "duration", "from", "to", "call_uuid", "url" ], "type": "object", "additionalProperties": false, "properties": { "id": { "type": "integer", "format": "int32", "description": "Recording ID.", "example": 123 }, "created_at": { "type": "string", "format": "date-time", "description": "Date and time when the recording was created in ISO 8601 format.", "example": "2023-06-15T10:30:00Z" }, "duration": { "type": "integer", "format": "int32", "description": "Recording duration in seconds.", "example": 120 }, "from": { "type": "string", "description": "Originating phone number.", "example": "1234567890" }, "to": { "type": "string", "description": "Destination phone number.", "example": "0987654321" }, "call_uuid": { "type": "string", "description": "Call ID.", "example": "aa566501-c591-4a8b-b3b9-cc1295398b72" }, "url": { "type": "string", "description": "Recording file URL.", "example": "https://api.wavix.com/v1/recordings/uuid" } }, "description": "A call recording response" }, "InvalidRecording": { "title": "InvalidRecording", "type": "object", "additionalProperties": false, "properties": { "dids": { "type": "array", "items": { "type": "string" }, "description": "Phone number IDs that did not match any recording.", "example": [ "invalid_did_1", "invalid_did_2" ] }, "sip_trunks": { "type": "array", "items": { "type": "string" }, "description": "SIP trunk IDs that did not match any recording.", "example": [ "invalid_trunk_1", "invalid_trunk_2" ] } }, "description": "An invalid recording filter response" }, "CallRecordingListResponse": { "type": "object", "additionalProperties": false, "properties": { "recordings": { "type": "array", "description": "Call recordings that match the request.", "items": { "$ref": "#/components/schemas/Recording" } }, "invalid": { "$ref": "#/components/schemas/InvalidRecording" }, "pagination": { "$ref": "#/components/schemas/Pagination" } } }, "RecordingDeletedErrorResponse": { "title": "RecordingDeletedErrorResponse", "type": "object", "required": [ "success", "message" ], "properties": { "success": { "type": "boolean", "description": "Indicates whether the request was successful. Always `false` for this error.", "example": false }, "error": { "type": "boolean", "description": "Error flag. Always `true` for this error.", "example": true }, "message": { "type": "string", "description": "Human-readable explanation of why the recording is unavailable.", "example": "deleted due to the retention policy settings" }, "deleted_at": { "type": "string", "format": "date-time", "description": "Timestamp when the recording was deleted, in ISO 8601 format.", "example": "2023-06-15T10:30:00Z" } } }, "SubmitFileTranscriptionResponse": { "title": "SubmitFileTranscriptionResponse", "required": [ "file", "request_id", "success" ], "type": "object", "properties": { "file": { "type": "string", "description": "Uploaded file name.", "example": "file.mp3" }, "request_id": { "type": "string", "description": "Transcription request ID.", "example": "e865ea07-25af-4fdd-876e-04b0d41d5ebd" }, "success": { "type": "boolean", "description": "Indicates whether the request was successful.", "example": true } }, "example": { "file": "file.mp3", "request_id": "e865ea07-25af-4fdd-876e-04b0d41d5ebd", "success": true } }, "FileTranscriptResponse": { "title": "FileTranscriptResponse", "required": [ "channel_1", "channel_2" ], "type": "object", "additionalProperties": false, "properties": { "channel_1": { "type": "string", "description": "Transcription of speaker one.", "example": "Hi there" }, "channel_2": { "type": "string", "description": "Transcription of speaker two.", "example": "Hello" } } }, "FileTranscriptTurn": { "title": "FileTranscriptTurn", "required": [ "speaker", "s", "e", "text", "sentiment" ], "type": "object", "additionalProperties": false, "properties": { "speaker": { "type": "string", "description": "Speaker identifier.", "example": "channel_1" }, "s": { "type": "integer", "description": "Turn start time in milliseconds from the beginning of the file.", "format": "int32", "example": 3000 }, "e": { "type": "integer", "description": "Turn end time in milliseconds from the beginning of the file.", "format": "int32", "example": 18000 }, "text": { "type": "string", "description": "Transcription text attributed to the speaker.", "example": "Hi there, how are you?" }, "sentiment": { "type": "string", "description": "Sentiment associated with the turn. Possible values are `positive`, `neutral`, `negative`.", "example": "positive" } }, "description": "Transcription `turn` details, including speaker, timestamps, text, and sentiment.", "example": { "speaker": "channel_1", "s": 600, "e": 700, "text": "Hi there", "sentiment": "positive" } }, "FileTranscriptionResponse": { "title": "FileTranscriptionResponse", "required": [ "transcript", "turns", "request_id", "language", "duration", "charge", "status", "transcription_date", "transcription_score", "transcription_summary", "original_file" ], "type": "object", "additionalProperties": false, "properties": { "transcript": { "description": "Complete transcription text attributed to each channel.", "oneOf": [ { "$ref": "#/components/schemas/FileTranscriptResponse" }, { "type": "null" } ] }, "turns": { "type": [ "array", "null" ], "items": { "$ref": "#/components/schemas/FileTranscriptTurn" }, "description": "List of transcription turns, including speaker attribution, timestamps, and sentiment.", "example": [ { "speaker": "channel_1", "s": 600, "e": 700, "text": "Hi", "sentiment": "positive" } ] }, "request_id": { "type": "string", "description": "Transcription request ID.", "example": "e84f350f-6da7-4b56-80eb-41dec572626b" }, "language": { "$ref": "#/components/schemas/TranscriptionLanguage", "description": "Transcription language.", "example": "en", "type": [ "string", "null" ] }, "duration": { "type": [ "integer", "null" ], "description": "File duration in seconds.", "format": "int32", "example": 102 }, "charge": { "type": "string", "description": "Total transcription charge in USD.", "example": "0.01" }, "status": { "$ref": "#/components/schemas/TranscriptionStatus", "description": "Transcription status. Possible values are `completed`, `failed`.", "example": "completed", "type": "string" }, "transcription_date": { "type": "string", "description": "Date and time of the transcription in ISO 8601 format.", "format": "date-time", "example": "2023-01-09T10:04:39.734Z" }, "transcription_score": { "type": [ "string", "null" ], "description": "Conversation sentiment score. Scores from 1.0 to 3.0 are negative; scores from 4.0 to 5.0 are positive.", "example": "3.8" }, "transcription_summary": { "type": [ "string", "null" ], "description": "Transcription summary.", "example": "The agent and client discussed call recording and call transcription" }, "original_file": { "type": "string", "description": "Uploaded file URL.", "example": "https://api.wavix.com/v1/files/uuid" } } }, "SpeechAnalyticsRetranscribeRequest": { "type": "object", "additionalProperties": false, "required": [ "callback_url" ], "properties": { "callback_url": { "type": "string", "description": "Callback URL for transcription status updates.", "example": "https://you-site.com/webhook" }, "insights": { "type": "boolean", "description": "Indicates whether to enable insights generation.", "example": true } } }, "CallWebhookListResponse": { "title": "CallWebhookListResponse", "type": "array", "description": "List of call webhooks configured for the phone number.", "items": { "type": "object", "additionalProperties": false, "required": [ "event_type", "url" ], "properties": { "event_type": { "type": "string", "description": "Type of call event the webhook subscribes to. One of `post-call` (delivered once after the call ends) or `on-call` (delivered for in-call events while the call is active).", "enum": [ "post-call", "on-call" ], "example": "post-call" }, "url": { "type": "string", "format": "uri", "description": "Webhook URL", "example": "https://your-site.com/webhook" } } } }, "CallWebhooksCreateRequest": { "type": "object", "additionalProperties": false, "required": [ "url", "event_type" ], "properties": { "url": { "type": "string", "format": "uri", "description": "Webhook URL to send call events to.", "example": "https://you-site.com/webhook" }, "event_type": { "type": "string", "description": "Allowed values: `on-call`, `post-call`.\n - `on-call`: Sends real-time status updates\n when a call starts, is answered, and ends.\n\n - `post-call`: Sends a callback after the call ends\n with disposition, duration, and cost.", "enum": [ "post-call", "on-call" ] }, "expected_url": { "type": "string", "description": "Applies the change only if the webhook currently has this URL. Pass an empty string to set the webhook only while it is unset, or your own URL to replace your webhook. Setting the URL the webhook already has always succeeds.", "example": "" } } }, "CallWebhook": { "title": "CallWebhook", "required": [ "success", "event_type", "url" ], "type": "object", "additionalProperties": false, "properties": { "success": { "type": "boolean", "description": "Indicates whether the request was successful.", "example": true }, "event_type": { "type": "string", "description": "Type of call event the webhook subscribes to. One of `post-call` (delivered once after the call ends) or `on-call` (delivered for in-call events while the call is active).", "enum": [ "post-call", "on-call" ], "example": "post-call" }, "url": { "type": "string", "format": "uri", "description": "Webhook URL", "example": "https://you-site.com/webhook" } }, "description": "A call webhook response" }, "CallDirection": { "type": "string", "enum": [ "inbound", "outbound" ], "description": "Direction of the call. One of `inbound` (call received by the account) or `outbound` (call placed by the account)." }, "OnCallEventPayload": { "type": "object", "description": "Payload for the `on_call_event` event type.", "required": [ "type" ], "properties": { "type": { "type": "string", "description": "Type of in-call sub-event. One of `audio` (audio playback progress) or `collect` (DTMF digit collection progress).", "enum": [ "audio", "collect" ], "example": "audio" }, "payload": { "type": [ "object", "null" ], "description": "Sub-event-specific data. Structure depends on the `type` field:\n- `audio`: `{ \"status\": \"started\" | \"completed\", \"playback_id\": \"\" }`\n- `collect`: `{ \"digits\": \"\", \"status\": \"started\" | \"completed\" | \"failed\" }`", "example": { "status": "completed", "playback_id": "3fa85f64-5717-4562-b3fc-2c963f66afa6" } } } }, "Call": { "type": "object", "additionalProperties": false, "required": [ "uuid", "id", "event_type", "event_time", "event_payload", "from", "to", "call_started", "call_answered", "call_completed", "machine_detected", "tag" ], "properties": { "uuid": { "type": "string", "format": "uuid", "deprecated": true, "description": "Call ID. Deprecated — use `id` instead.", "example": "5dccb6b0-f35c-488c-867b-86fb012c4415" }, "id": { "type": "string", "format": "uuid", "description": "Call ID. Alias of `uuid`.", "example": "5dccb6b0-f35c-488c-867b-86fb012c4415" }, "direction": { "$ref": "#/components/schemas/CallDirection" }, "event_type": { "type": "string", "description": "Most recent lifecycle event for the call. One of:\n\n- `call_setup` — the call is being initiated.\n- `ringing` — the destination is ringing.\n- `early_media` — early media (such as ringback) is playing before answer.\n- `answered` — the destination answered the call.\n- `completed` — the call ended normally.\n- `busy` — the destination was busy.\n- `cancelled` — the call was cancelled before answer.\n- `rejected` — the destination rejected the call.\n- `on_call_event` — an in-call event occurred (see `event_payload`).", "enum": [ "call_setup", "ringing", "early_media", "answered", "completed", "busy", "cancelled", "rejected", "on_call_event" ], "example": "call_setup" }, "event_time": { "type": "string", "format": "date-time", "description": "Date and time of the latest event in ISO 8601 format.", "example": "2025-09-22T12:56:38.547Z" }, "event_payload": { "description": "Event-specific metadata.", "oneOf": [ { "$ref": "#/components/schemas/OnCallEventPayload" }, { "type": "null" } ], "example": { "type": "audio", "payload": { "status": "completed", "playback_id": "3fa85f64-5717-4562-b3fc-2c963f66afa6" } } }, "from": { "type": "string", "description": "Caller ID.", "example": "+18045961058" }, "to": { "type": "string", "description": "Destination number.", "example": "17653889567" }, "call_started": { "type": "string", "format": "date-time", "description": "Date and time when the call started in ISO 8601 format.", "example": "2025-09-22T12:56:38.547Z" }, "call_answered": { "type": [ "string", "null" ], "format": "date-time", "description": "Date and time when the call was answered in ISO 8601 format." }, "call_completed": { "type": [ "string", "null" ], "format": "date-time", "description": "Date and time when the call ended in ISO 8601 format." }, "machine_detected": { "type": "boolean", "description": "Indicates whether the call was answered by a machine.", "example": false }, "tag": { "type": "string", "description": "Call metadata", "example": "marketing-campaign" } } }, "CallListResponse": { "type": "object", "properties": { "calls": { "type": "array", "description": "List of calls", "items": { "$ref": "#/components/schemas/Call" } }, "success": { "type": "boolean", "description": "Indicates whether the request was successful.", "example": true } }, "required": [ "calls", "success" ] }, "CallRequest": { "type": "object", "additionalProperties": false, "required": [ "from", "to", "callback_url" ], "properties": { "from": { "type": "string", "description": "Caller ID. Must be an active or verified phone number on the account.", "example": "+1234567890" }, "to": { "type": "string", "description": "Destination number in E.164 format", "example": "+1987654321" }, "callback_url": { "type": "string", "description": "The callback URL where Wavix sends the call status updates", "example": "https://examples.com/callback" }, "recording": { "type": "boolean", "description": "Specifies whether to record the call", "default": false }, "voicemail_detection": { "type": "boolean", "description": "Specifies whether the AMD is turned on for the call", "default": false }, "tag": { "type": "string", "description": "Call metadata", "example": "marketing-campaign" }, "timeout": { "type": "integer", "description": "The ring timeout, in seconds, before the call is considered unanswered.", "example": 60 } } }, "CallCreateResponse": { "type": "object", "additionalProperties": false, "properties": { "uuid": { "type": "string", "format": "uuid", "deprecated": true, "description": "Call ID. Deprecated — use `id` instead.", "example": "5dccb6b0-f35c-488c-867b-86fb012c4415" }, "id": { "type": "string", "format": "uuid", "description": "Call ID. Alias of `uuid`.", "example": "5dccb6b0-f35c-488c-867b-86fb012c4415" }, "direction": { "$ref": "#/components/schemas/CallDirection" }, "event_type": { "type": "string", "description": "Most recent lifecycle event for the call. One of:\n\n- `call_setup` — the call is being initiated.\n- `ringing` — the destination is ringing.\n- `early_media` — early media (such as ringback) is playing before answer.\n- `answered` — the destination answered the call.\n- `completed` — the call ended normally.\n- `busy` — the destination was busy.\n- `cancelled` — the call was cancelled before answer.\n- `rejected` — the destination rejected the call.\n- `on_call_event` — an in-call event occurred (see `event_payload`).", "enum": [ "call_setup", "ringing", "early_media", "answered", "completed", "busy", "cancelled", "rejected", "on_call_event" ], "example": "call_setup" }, "event_time": { "type": "string", "format": "date-time", "description": "Date and time of the latest event", "example": "2025-09-22T12:56:38.547Z" }, "event_payload": { "description": "Event-specific data", "oneOf": [ { "$ref": "#/components/schemas/OnCallEventPayload" }, { "type": "null" } ], "example": { "type": "audio", "payload": { "status": "completed", "playback_id": "3fa85f64-5717-4562-b3fc-2c963f66afa6" } } }, "from": { "type": "string", "description": "Caller ID", "example": "+18045961058" }, "to": { "type": "string", "description": "Destination number", "example": "17653889567" }, "call_started": { "type": "string", "format": "date-time", "description": "Date and time when the call started", "example": "2025-09-22T12:56:38.547Z" }, "call_answered": { "type": [ "string", "null" ], "format": "date-time", "description": "Date and time when the call was answered" }, "call_completed": { "type": [ "string", "null" ], "format": "date-time", "description": "Date and time when the call ended" }, "machine_detected": { "type": "boolean", "description": "Indicates whether the call was answered by an answering machine", "example": false }, "tag": { "type": "string", "description": "Call metadata", "example": "" } } }, "CallControlValidationErrorResponse": { "title": "CallControlValidationErrorResponse", "type": "object", "required": [ "success", "message" ], "properties": { "success": { "type": "boolean", "description": "Indicates whether the request was successful. Always `false` for this error.", "example": false }, "message": { "type": "string", "description": "Human-readable summary of the validation failure.", "example": "Validation error" }, "errors": { "type": "object", "description": "Field-level validation messages, keyed by the offending request\nfield name (snake_case). Absent when the request body could not be\nparsed at all (for example, malformed JSON).\n", "additionalProperties": { "type": "string" }, "example": { "to": "required" } } } }, "CallResponse": { "type": "object", "properties": { "call": { "$ref": "#/components/schemas/Call" }, "success": { "type": "boolean", "description": "Indicates whether the request was successful.", "example": true } }, "required": [ "call", "success" ] }, "UpdateCallRequest": { "type": "object", "additionalProperties": false, "required": [ "tag" ], "properties": { "tag": { "type": "string", "description": "User-defined label attached to the Call for tracking or reporting.", "example": "marketing-campaign" } } }, "CallStreamType": { "type": "string", "enum": [ "oneway", "twoway" ], "description": "Specifies the streaming type. Can be either `oneway` for unidirectional or `twoway` for bidirectional streaming." }, "CallStreamChannel": { "type": "string", "enum": [ "inbound", "outbound", "both" ], "description": "Audio channel to stream: `inbound` streams the incoming channel (to Wavix), `outbound` the outbound channel (from Wavix), and `both` both channels. For bidirectional call streaming, this setting is ignored and only the inbound channel is streamed." }, "CallAnswerRequest": { "type": "object", "additionalProperties": false, "properties": { "call_recording": { "type": "boolean", "description": "Indicates whether the call should be recorded.", "default": false }, "call_transcription": { "type": "boolean", "description": "Indicates whether the call should be transcribed after it ends.", "default": false }, "stream_url": { "type": "string", "format": "uri", "description": "WebSocket URL (`ws://` or `wss://`) that receives the call's audio, which can include the caller's voice.", "example": "wss://examples.com/stream" }, "stream_type": { "description": "Direction of audio streamed to `stream_url`.", "example": "twoway", "$ref": "#/components/schemas/CallStreamType", "type": "string" }, "stream_channel": { "description": "Audio channel streamed to `stream_url`.", "example": "inbound", "$ref": "#/components/schemas/CallStreamChannel", "type": "string" } } }, "CallStreamCreateRequest": { "type": "object", "additionalProperties": false, "required": [ "stream_url", "stream_type", "stream_channel" ], "properties": { "stream_url": { "type": "string", "format": "uri", "description": "WebSocket URL (`ws://` or `wss://`) that receives the call's audio.", "example": "wss://examples.com/stream" }, "stream_type": { "description": "Direction of audio streamed to `stream_url`.", "example": "twoway", "$ref": "#/components/schemas/CallStreamType", "type": "string" }, "stream_channel": { "description": "Audio channel streamed to `stream_url`.", "example": "inbound", "$ref": "#/components/schemas/CallStreamChannel", "type": "string" } } }, "CallStreamResponse": { "type": "object", "properties": { "success": { "type": "boolean", "description": "Indicates that the request was successful", "example": true }, "stream_id": { "type": "string", "format": "uuid", "description": "Stream ID", "example": "123e4567-e89b-12d3-a456-426614174000" } } }, "CallAudioPlayRequest": { "type": "object", "additionalProperties": false, "required": [ "audio_file" ], "properties": { "audio_file": { "type": "string", "description": "URL of the audio file to play to the call.", "example": "https://examples.com/audio.wav" } } }, "TTSLanguage": { "type": "string", "enum": [ "ru", "en", "sp", "ge" ], "description": "Language used for text-to-speech synthesis. One of `ru` (Russian), `en` (English), `sp` (Spanish), or `ge` (German). `sp` and `ge` are Wavix-specific codes, not the standard ISO 639-1 codes for Spanish (`es`) and German (`de`)." }, "TTSVoiceID": { "type": "string", "enum": [ "Ivy", "Joanna", "Kendra", "Kimberly", "Salli", "Joey", "Justin", "Matthew", "Conchita", "Lucia", "Enrique", "Marlene", "Vicki", "Hans", "Tatyana", "Maxim" ], "description": "Named text-to-speech voice used to read the message. Each value selects a distinct synthesized voice. One of `Ivy`, `Joanna`, `Kendra`, `Kimberly`, `Salli`, `Joey`, `Justin`, or `Matthew` (English voices); `Conchita`, `Lucia`, or `Enrique` (Spanish voices); `Marlene`, `Vicki`, or `Hans` (German voices); or `Tatyana` or `Maxim` (Russian voices)." }, "CallDtmfCollectRequest": { "type": "object", "additionalProperties": false, "properties": { "max_digits": { "type": "integer", "description": "Maximum number of digits to collect.", "minimum": 1, "maximum": 20, "example": 5 }, "timeout": { "type": "integer", "description": "Timeout for digit collection in seconds.", "minimum": 1, "maximum": 60, "example": 10 }, "termination_character": { "type": "string", "description": "DTMF character that ends input collection.", "example": "#" }, "max_attempts": { "type": "integer", "description": "Maximum number of attempts.", "example": 3 }, "prompt": { "type": "object", "description": "Prompt to play before collecting digits.\n Play a prerecorded audio file or use Wavix Text-To-Speech.", "properties": { "play": { "type": "string", "description": "Audio file URL.", "example": "https://examples.com/prompt.wav" }, "say": { "type": "object", "description": "Text to speak and voice to use. Pick `voice` from the language family matching `language` (for example, a German voice such as `Hans` for `ge`, a Spanish voice such as `Conchita` for `sp`) — Wavix does not validate the pairing itself.", "required": [ "text", "voice" ], "properties": { "text": { "type": "string", "description": "Text to speak.", "example": "Press 1 for sales, press 2 for support, or press 3 to repeat this menu." }, "language": { "$ref": "#/components/schemas/TTSLanguage" }, "voice": { "$ref": "#/components/schemas/TTSVoiceID" } } } } } } }, "WebRTCToken": { "title": "WebRTCToken", "description": "Represents a WebRTC token that authorizes the Wavix embeddable widget to register against a SIP trunk.", "type": "object", "additionalProperties": false, "required": [ "uuid", "sip_trunk" ], "properties": { "uuid": { "type": "string", "description": "Unique identifier of the WebRTC token.", "example": "550e8400-e29b-41d4-a716-446655440000" }, "sip_trunk": { "type": "string", "description": "Name of the SIP trunk the token authenticates against.", "example": "my-sip-trunk" }, "payload": { "type": [ "object", "null" ], "description": "Arbitrary client-defined data associated with the token.", "example": {} }, "ttl": { "type": [ "integer", "null" ], "minimum": 1, "description": "Time to live, in seconds. `null` means no expiration.", "example": 3600 } } }, "WebRTCTokensListResponse": { "type": "object", "description": "Paginated list of WebRTC tokens.", "properties": { "items": { "type": "array", "description": "WebRTC tokens on the current page.", "items": { "$ref": "#/components/schemas/WebRTCToken" } }, "pagination": { "$ref": "#/components/schemas/Pagination" } } }, "WebRTCTokenCreateRequest": { "title": "WebRTCTokenCreateRequest", "type": "object", "additionalProperties": false, "required": [ "sip_trunk" ], "properties": { "sip_trunk": { "type": "string", "description": "Name of the SIP trunk the token authenticates against.", "example": "my-sip-trunk" }, "payload": { "type": [ "object", "null" ], "description": "Arbitrary client-defined data to associate with the token.", "example": {} }, "ttl": { "type": [ "integer", "null" ], "minimum": 1, "default": 3600, "description": "Time to live in seconds. Default `3600`; `null` means no expiration.", "example": 3600 } } }, "WebRTCTokenResponse": { "title": "WebRTCTokenResponse", "type": "object", "additionalProperties": false, "required": [ "token", "uuid", "sip_trunk" ], "properties": { "token": { "type": "string", "description": "Signed JWT used by the Wavix embeddable widget to authenticate.", "example": "eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9..." }, "uuid": { "type": "string", "description": "Unique identifier of the WebRTC token.", "example": "550e8400-e29b-41d4-a716-446655440000" }, "sip_trunk": { "type": "string", "description": "Name of the SIP trunk the token authenticates against.", "example": "my-sip-trunk" }, "payload": { "type": [ "object", "null" ], "description": "Arbitrary client-defined data associated with the token.", "example": {} }, "ttl": { "type": [ "integer", "null" ], "description": "Lifetime of the token, in seconds. `null` means the token does not expire.", "example": 3600 } } }, "WebRTCTokenUpdateRequest": { "title": "WebRTCTokenUpdateRequest", "type": "object", "additionalProperties": false, "required": [ "payload" ], "properties": { "payload": { "type": "object", "description": "Arbitrary client-defined data to associate with the token, replacing the existing payload.", "example": {} } } }, "SenderIDType": { "title": "SenderIDType", "enum": [ "numeric", "alphanumeric" ], "type": "string", "description": "Format of the Sender ID. One of `numeric` (a phone number) or `alphanumeric` (a text sender name)." }, "SenderID": { "title": "SenderID", "required": [ "id", "sender_id", "type", "allowlisted_in" ], "type": "object", "additionalProperties": false, "properties": { "id": { "type": "string", "description": "Sender ID ID.", "example": "3c7a5a90-43e0-43e0-b006-fdfea30c5a7c" }, "sender_id": { "type": "string", "description": "Sender ID name.", "example": "Wavix" }, "type": { "$ref": "#/components/schemas/SenderIDType" }, "allowlisted_in": { "type": "array", "items": { "type": "string" }, "description": "Two-letter ISO country codes where the Sender ID is allowlisted." }, "usecase": { "type": "string", "description": "Primary use case declared for the Sender ID, such as `transactional`, `promo`, or `authentication`.", "example": "promo" }, "samples": { "description": "Message samples.", "type": "array", "items": { "type": "string", "example": "sample" } } }, "description": "SMS Sender ID." }, "SenderIDListResponse": { "title": "SenderIDListResponse", "required": [ "items" ], "type": "object", "additionalProperties": false, "properties": { "items": { "type": "array", "items": { "$ref": "#/components/schemas/SenderID" }, "description": "List of Sender IDs." } } }, "SenderIDCreateRequest": { "title": "SenderIDCreateRequest", "required": [ "sender_id", "type", "countries", "usecase" ], "type": "object", "additionalProperties": false, "properties": { "sender_id": { "type": "string", "description": "Sender ID name. Can be either an alphanumeric string or a phone number.", "example": "Wavix" }, "type": { "$ref": "#/components/schemas/SenderIDType" }, "countries": { "type": "array", "items": { "type": "string" }, "description": "Two-letter ISO country codes where the Sender ID is allowlisted." }, "usecase": { "type": "string", "description": "Primary use case for the Sender ID. One of `transactional` (account or order notifications), `promo` (marketing and promotional messages), or `authentication` (one-time passcodes and verification codes).", "enum": [ "transactional", "promo", "authentication" ], "example": "transactional" }, "monthly_volume": { "type": "string", "description": "Expected number of messages sent per month from the Sender ID. One of `1-1000`, `1001-20000`, `20001-50000`, `50001-100000`, or `More than 100000`. Each value is the message-count band for the month.", "enum": [ "1-1000", "1001-20000", "20001-50000", "50001-100000", "More than 100000" ], "example": "1001-20000" }, "samples": { "type": "array", "items": { "type": "string" }, "description": "Message samples.", "example": [ "Sample message 1", "Sample message 2" ] } } }, "SenderIDDetails": { "title": "SenderIDDetails", "required": [ "id", "sender_id", "type", "allowlisted_in" ], "type": "object", "additionalProperties": false, "properties": { "id": { "type": "string", "description": "Sender ID ID.", "example": "3c7a5a90-43e0-43e0-b006-fdfea30c5a7c" }, "sender_id": { "type": "string", "description": "Sender ID name.", "example": "Wavix" }, "type": { "$ref": "#/components/schemas/SenderIDType" }, "allowlisted_in": { "type": "array", "items": { "type": "string" }, "description": "List of countries where the Sender ID is allowlisted." }, "usecase": { "type": "string", "description": "Primary use case declared for the Sender ID, such as `transactional`, `promo`, or `authentication`.", "example": "promo" }, "samples": { "type": "array", "items": { "type": "string" }, "description": "Message samples.", "example": [ "Sample message 1", "Sample message 2" ] } } }, "SenderIDResponse": { "type": "object", "additionalProperties": false, "properties": { "id": { "type": "string", "format": "uuid", "description": "Sender ID ID.", "example": "3c7a5a90-43e0-43e0-b006-fdfea30c5a7c" }, "sender_id": { "type": "string", "description": "Sender ID.", "example": "Wavix" }, "type": { "type": "string", "description": "Format of the Sender ID. One of `alphanumeric` (a text sender name), `numeric` (a phone number), or `shortcode` (a short code).", "enum": [ "alphanumeric", "numeric", "shortcode" ], "example": "alphanumeric" }, "usecase": { "type": "string", "description": "Use case for the Sender ID.", "example": "promo" }, "samples": { "type": "array", "description": "Message samples.", "items": { "type": "string", "example": "Sample" } }, "allowlisted_in": { "type": "array", "description": "List of countries where the Sender ID is allowlisted.", "items": { "type": "string", "example": "GB" } } }, "required": [ "id", "sender_id", "type" ] }, "RecordNotFoundErrorResponse": { "title": "RecordNotFoundErrorResponse", "required": [ "success", "message" ], "type": "object", "properties": { "success": { "type": "boolean", "description": "Indicates whether the request was successful. Always `false` for this error.", "example": false }, "message": { "type": "string", "description": "Human-readable error description", "example": "Record not found" } }, "example": { "success": false, "message": "Record not found" } }, "OptOutItem": { "title": "OptOutItem", "type": "object", "properties": { "phone_number": { "type": "string", "description": "Opted-out phone number.", "example": "15551234567" }, "sender_id": { "type": [ "string", "null" ], "description": "Sender ID. Contains `null` if the phone number opted out of all messages.", "example": "MySender" }, "campaign_id": { "type": [ "string", "null" ], "description": "10DLC campaign ID, if any.", "example": "C123456" }, "created_at": { "type": "string", "format": "date-time", "description": "Opt-out date and time in ISO 8601 format.", "example": "2024-01-15T10:30:00Z" } } }, "OptOutsListResponse": { "title": "OptOutsListResponse", "type": "object", "properties": { "items": { "type": "array", "description": "Opt-out records that match the request.", "items": { "$ref": "#/components/schemas/OptOutItem" } }, "pagination": { "$ref": "#/components/schemas/Pagination" } } }, "OptOut": { "title": "OptOut", "required": [ "number" ], "type": "object", "additionalProperties": false, "properties": { "number": { "type": "string", "description": "Phone number to opt out.", "example": "16419252149" }, "sender_id": { "type": "string", "description": "Sender ID. If omitted, the phone number is opted out of all messages.", "example": "15072429497" } }, "example": { "number": "16419252149", "sender_id": "15072429497" } }, "OptOutCreateRequest": { "title": "OptOutCreateRequest", "required": [ "opt_out" ], "type": "object", "additionalProperties": false, "properties": { "opt_out": { "$ref": "#/components/schemas/OptOut" } } }, "MessageDeliveryStatus": { "title": "MessageDeliveryStatus", "enum": [ "accepted", "pending", "sent", "delivered", "undelivered", "expired", "rejected", "dlr_expired" ], "type": "string", "description": "Current delivery status of the message. One of:\n\n- `accepted` — the message was accepted by the platform for sending.\n- `pending` — the message is queued and awaiting a carrier response.\n- `sent` — the message was handed to the carrier.\n- `delivered` — the carrier confirmed delivery to the handset.\n- `undelivered` — the carrier reported that delivery failed.\n- `expired` — the validity period elapsed before the message was sent.\n- `rejected` — the message was rejected before sending.\n- `dlr_expired` — no delivery receipt arrived from the carrier within the expected window." }, "MessageBody": { "title": "MessageBody", "required": [ "text" ], "type": "object", "additionalProperties": false, "properties": { "text": { "type": "string", "description": "Message text.", "example": "Hi there, this is a sample message" }, "media": { "maxItems": 5, "minItems": 0, "type": [ "array", "null" ], "items": { "type": "string" }, "description": "List of media URLs.\n If provided, the message is sent as an MMS;\n otherwise, it is sent as an SMS.", "example": [ "https://you-site.com/media" ] } } }, "Message": { "title": "Message", "required": [ "message_id", "message_type", "from", "to", "direction", "mcc", "mnc", "message_body", "tag", "status", "segments", "charge", "submitted_at", "sent_at", "delivered_at", "error_message" ], "type": "object", "additionalProperties": false, "properties": { "message_id": { "type": "string", "description": "Message ID.", "example": "871b4eeb-f798-4105-be23-32df9e991456" }, "message_type": { "type": "string", "description": "Message type. Possible values are `sms` or `mms`", "example": "sms" }, "from": { "type": "string", "description": "Sender ID. Can be numeric or alphanumeric.", "example": "Wavix" }, "to": { "type": "string", "description": "Recipient phone number.", "example": "447537151866" }, "carrier_fees": { "type": "string", "description": "Carrier fees for the message in USD.", "format": "float", "example": "0.0" }, "direction": { "type": "string", "description": "Message direction. Possible values are `outbound` or `inbound`.", "example": "outbound" }, "mcc": { "type": [ "string", "null" ], "description": "Mobile country code.", "example": "301" }, "mnc": { "type": [ "string", "null" ], "description": "Mobile network code.", "example": "204" }, "message_body": { "$ref": "#/components/schemas/MessageBody" }, "tag": { "type": [ "string", "null" ], "description": "Tag to group messages, such as for a specific campaign.", "example": "Fall sale" }, "status": { "$ref": "#/components/schemas/MessageDeliveryStatus" }, "segments": { "type": "integer", "description": "Number of SMS segments. Always 1 for MMS.", "format": "int32", "example": 1 }, "charge": { "type": "string", "description": "Total charge for the message in USD.", "example": "0.01" }, "submitted_at": { "type": "string", "description": "Date and time the message was accepted in ISO 8601 format.", "example": "2022-04-14T13:51:16.096Z" }, "sent_at": { "type": [ "string", "null" ], "description": "Date and time the message was sent in ISO 8601 format. For mobile terminated messages only.", "example": "2022-04-14T13:51:16.096Z" }, "delivered_at": { "type": [ "string", "null" ], "description": "Date and time the message was delivered in ISO 8601 format. Refers to DLR reception for mobile-terminated messages\n or webhook relay for mobile-originated messages.", "example": "2022-04-14T13:51:16.096Z" }, "error_message": { "type": [ "string", "null" ], "description": "A human-readable error description." } }, "description": "SMS or MMS message.", "example": { "message_id": "871b4eeb-f798-4105-be23-32df9e991456", "message_type": "sms", "from": "Wavix", "to": "447537151866", "direction": "outbound", "mcc": "301", "mnc": "204", "message_body": { "text": "Hi there, this a message from Wavix", "media": null }, "tag": "Fall sale", "status": "delivered", "segments": 1, "charge": "0.01", "submitted_at": "2022-04-14T13:51:16.096Z", "sent_at": "2022-04-14T13:51:16.096Z", "delivered_at": "2022-04-14T13:51:16.096Z", "error_message": "" } }, "MessageListResponse": { "title": "MessageListResponse", "required": [ "items", "pagination" ], "type": "object", "additionalProperties": false, "properties": { "items": { "type": "array", "description": "Messages that match the request.", "items": { "$ref": "#/components/schemas/Message" } }, "pagination": { "$ref": "#/components/schemas/Pagination" } } }, "MessageCreateRequest": { "title": "MessageCreateRequest", "required": [ "from", "to", "message_body" ], "type": "object", "additionalProperties": false, "properties": { "from": { "type": "string", "description": "Sender ID. Numeric or alphanumeric.", "example": "Wavix" }, "to": { "type": "string", "description": "Recipient phone number.", "example": "447537151866" }, "message_body": { "$ref": "#/components/schemas/MessageBody" }, "callback_url": { "type": "string", "description": "Callback URL for delivery reports.", "example": "https://you-site.com/webhook" }, "validity": { "type": "integer", "description": "Message validity period in seconds. Delivery attempts stop after this period expires.", "format": "int32", "example": 3600 }, "tag": { "type": "string", "description": "Tag to group messages, such as for a specific campaign.", "example": "Fall sale" } } }, "SendMessagesResponse": { "type": "object", "additionalProperties": false, "properties": { "carrier_fees": { "type": [ "string", "null" ], "description": "Mobile carrier fees in USD.", "example": "0.0" }, "charge": { "type": "string", "description": "Total charge for the message in USD.", "example": "0.0" }, "direction": { "type": "string", "description": "Message direction. Possible values are `outbound`, `inbound`.", "example": "outbound" }, "delivered_at": { "type": [ "string", "null" ], "description": "Date and time the message was delivered in ISO 8601 format.", "format": "date-time", "example": "2024-05-28T12:34:56Z" }, "error_message": { "type": [ "string", "null" ], "description": "Error message." }, "from": { "type": "string", "description": "Sender ID.", "example": "Sender ID." }, "mcc": { "type": [ "string", "null" ], "description": "Mobile country code.", "example": "310" }, "mnc": { "type": [ "string", "null" ], "description": "Mobile network code.", "example": "260" }, "message_body": { "$ref": "#/components/schemas/MessageBody" }, "message_id": { "type": "string", "description": "Message ID.", "example": "abc123de-4567-890f-gh12-ijklmnop3456" }, "message_type": { "type": "string", "description": "Message type.", "example": "mms" }, "segments": { "type": "integer", "description": "Number of SMS segments. Always 1 for MMS.", "example": 1 }, "sent_at": { "type": [ "string", "null" ], "description": "Date and time the message was sent in ISO 8601 format.", "format": "date-time", "example": "2024-05-28T12:34:54Z" }, "status": { "type": "string", "description": "Message status.", "example": "accepted" }, "submitted_at": { "type": "string", "description": "Date and time the message was submitted in ISO 8601 format.", "example": "2025-09-22T09:07:53Z" }, "tag": { "type": [ "string", "null" ], "description": "Message tag.", "example": "campaign_test" }, "to": { "type": "string", "description": "Recipient phone number.", "example": "+15551234567" } } }, "TooManyRequestsErrorResponse": { "title": "TooManyRequestsErrorResponse", "required": [ "success", "message" ], "type": "object", "properties": { "success": { "type": "boolean", "description": "Indicates whether the request was successful. Always `false` for this error.", "example": false }, "message": { "type": "string", "description": "Human-readable description stating that the rate limit was exceeded.", "example": "Too many requests. Please retry after the specified interval." } } }, "MessageResponse": { "title": "MessageResponse", "required": [ "message_id", "message_type", "from", "to", "direction", "mcc", "mnc", "message_body", "tag", "status", "segments", "charge", "submitted_at", "sent_at", "delivered_at", "error_message" ], "type": "object", "additionalProperties": false, "properties": { "message_id": { "type": "string", "description": "Message ID.", "example": "871b4eeb-f798-4105-be23-32df9e991456" }, "message_type": { "type": "string", "description": "Message type. Possible values are `sms`, `mms`.", "example": "sms" }, "from": { "type": "string", "description": "Sender ID.", "example": "Wavix" }, "to": { "type": "string", "description": "Recipient phone number.", "example": "447537151866" }, "direction": { "type": "string", "description": "Message direction. Possible values are `outbound`, `inbound`.", "example": "outbound" }, "mcc": { "type": [ "string", "null" ], "description": "Mobile country code.", "example": "301" }, "mnc": { "type": [ "string", "null" ], "description": "Mobile network code.", "example": "204" }, "message_body": { "$ref": "#/components/schemas/MessageBody" }, "tag": { "type": [ "string", "null" ], "description": "Tag to group messages, such as for a specific campaign.", "example": "Fall sale" }, "status": { "$ref": "#/components/schemas/MessageDeliveryStatus" }, "segments": { "type": "integer", "description": "Number of SMS segments. Always 1 for MMS.", "format": "int32", "example": 1 }, "charge": { "type": "string", "description": "Total charge for the message in USD.", "example": "0.01" }, "submitted_at": { "type": "string", "description": "Date and time the message was accepted in ISO 8601 format.", "example": "2022-04-14T13:51:16.096Z" }, "sent_at": { "type": [ "string", "null" ], "description": "Date and time the message was sent in ISO 8601 format. For mobile-terminated messages only.", "example": "2022-04-14T13:51:16.096Z" }, "delivered_at": { "type": [ "string", "null" ], "description": "Date and time the message was delivered in ISO 8601 format. Refers to DLR reception for mobile-terminated messages\n or webhook relay for mobile-originated messages.", "example": "2022-04-14T13:51:16.096Z" }, "error_message": { "type": [ "string", "null" ], "description": "Human-readable error message." }, "carrier_fees": { "type": [ "string", "null" ], "description": "Mobile carrier fees in USD.", "example": "0.0" } } }, "TenDLCBrandEntityType": { "title": "TenDLCBrandEntityType", "enum": [ "PRIVATE_PROFIT", "PUBLIC_PROFIT", "NON_PROFIT", "GOVERNMENT" ], "type": "string", "description": "Legal entity type of the 10DLC Brand. One of `PRIVATE_PROFIT` (privately held for-profit company), `PUBLIC_PROFIT` (publicly traded for-profit company), `NON_PROFIT` (non-profit organization), or `GOVERNMENT` (government entity).", "example": "PRIVATE_PROFIT" }, "TenDLCBrandIdentityVerificationStatus": { "title": "TenDLCBrandIdentityVerificationStatus", "enum": [ "REVIEW", "VERIFIED", "UNVERIFIED", "VETTED_VERIFIED", "SUSPENDED" ], "type": "string", "description": "Identity verification status of the 10DLC Brand. One of:\n\n- `REVIEW` — verification is in progress.\n- `VERIFIED` — the Brand passed standard verification.\n- `UNVERIFIED` — verification has not succeeded.\n- `VETTED_VERIFIED` — the Brand also passed third-party vetting.\n- `SUSPENDED` — the Brand is blocked from sending." }, "TenDLCBrand": { "title": "TenDLCBrand", "required": [ "brand_id", "dba_name", "company_name", "entity_type", "vertical", "ein_taxid", "ein_taxid_country", "status", "first_name", "last_name", "phone_number", "email", "street_address", "city", "country", "zip", "feedback", "created_at", "updated_at" ], "type": "object", "additionalProperties": false, "properties": { "brand_id": { "type": "string", "description": "Unique identifier of the Brand assigned by the registry.", "example": "BM20QP9" }, "dba_name": { "type": "string", "description": "Doing-business-as name, or the public-facing brand name.", "example": "Brand" }, "company_name": { "type": "string", "description": "Registered legal name of the company that owns the Brand.", "example": "Company" }, "entity_type": { "$ref": "#/components/schemas/TenDLCBrandEntityType", "description": "Company entity type.", "example": "PRIVATE_PROFIT", "type": "string" }, "vertical": { "type": "string", "description": "Industry vertical the Brand operates in.", "example": "HEALTHCARE" }, "ein_taxid": { "type": "string", "description": "IRS Employer Identification Number (EIN) or other tax ID of the company.", "example": "999999999" }, "ein_taxid_country": { "type": "string", "description": "ISO 3166-1 alpha-2 country code where the Tax ID was issued.", "example": "US" }, "status": { "$ref": "#/components/schemas/TenDLCBrandIdentityVerificationStatus", "description": "Brand identity verification status.", "example": "VERIFIED", "type": "string" }, "website": { "type": [ "string", "null" ], "description": "Business website URL.", "example": "https://brand.com" }, "stock_symbol": { "type": [ "string", "null" ], "description": "Stock ticker symbol of the company. Required for publicly traded companies." }, "stock_exchange": { "type": [ "string", "null" ], "description": "Code of the stock exchange the company is listed on. Required for publicly traded companies." }, "first_name": { "type": "string", "description": "Business contact first name.", "example": "John" }, "last_name": { "type": "string", "description": "Business contact last name.", "example": "Dow" }, "phone_number": { "type": "string", "description": "Support contact phone number in E.164 format.", "example": "12123450099" }, "email": { "type": "string", "description": "Support contact email address.", "example": "support@brand.com" }, "street_address": { "type": "string", "description": "Street address of the business.", "example": "10, City Name" }, "city": { "type": "string", "description": "City of the business address.", "example": "Miami" }, "state_or_province": { "type": [ "string", "null" ], "description": "State or province of the business address.", "example": "FL" }, "country": { "type": "string", "description": "ISO 3166-1 alpha-2 country code of the business address.", "example": "US" }, "zip": { "type": "string", "description": "ZIP or postal code of the business address.", "example": "12345" }, "feedback": { "type": [ "string", "null" ], "description": "Feedback from the identity verification process explaining the current `status`." }, "mock": { "type": "boolean", "description": "Indicates whether the Brand is a mock brand for testing.", "default": false, "example": false }, "created_at": { "type": "string", "description": "Timestamp when the Brand was created, in ISO 8601 format.", "example": "2024-07-24T08:29:09" }, "updated_at": { "type": "string", "description": "Timestamp when the Brand was last updated, in ISO 8601 format.", "example": "2024-07-24T08:29:09" } }, "description": "Represents a 10DLC brand registered for application-to-person messaging. A Brand identifies the business behind one or more messaging campaigns.", "example": { "brand_id": "BM20QP9", "city": "Miami", "company_name": "Company legal name", "country": "US", "created_at": "2024-07-24T08:10:49", "dba_name": "New Brand", "ein_taxid": "12345", "ein_taxid_country": "US", "email": "support@brand.com", "entity_type": "PRIVATE_PROFIT", "feedback": null, "first_name": "John", "last_name": "Dow", "mock": false, "phone_number": "12123450099", "state_or_province": "FL", "status": "VERIFIED", "stock_exchange": null, "stock_symbol": null, "street_address": "10, Street name", "updated_at": "2024-07-24T08:29:09", "vertical": "HEALTHCARE", "website": "https://brand.com", "zip": "12345" } }, "TenDLCBrandListResponse": { "title": "TenDLCBrandListResponse", "required": [ "items", "pagination" ], "type": "object", "additionalProperties": false, "properties": { "items": { "type": "array", "items": { "$ref": "#/components/schemas/TenDLCBrand" }, "description": "A paginated list of 10DLC Brands matching the filter criteria" }, "pagination": { "allOf": [ { "$ref": "#/components/schemas/Pagination" }, { "description": "Pagination details" } ], "type": "object" } }, "description": "A list of 10DLC Brands", "example": { "items": [ { "brand_id": "BM20QP9", "city": "Miami", "company_name": "Company legal name", "country": "US", "created_at": "2024-07-24T08:10:49", "dba_name": "New Brand", "ein_taxid": "12345", "ein_taxid_country": "US", "email": "support@brand.com", "entity_type": "PRIVATE_PROFIT", "feedback": null, "first_name": "John", "last_name": "Dow", "mock": false, "phone_number": "12123450099", "state_or_province": "FL", "status": "VERIFIED", "stock_exchange": null, "stock_symbol": null, "street_address": "10, Street name", "updated_at": "2024-07-24T08:29:09", "vertical": "HEALTHCARE", "website": "https://brand.com", "zip": "12345" } ], "pagination": { "current_page": 1, "per_page": 25, "total": 1, "total_pages": 1 } } }, "AccountErrorResponse": { "title": "AccountErrorResponse", "required": [ "success", "message" ], "type": "object", "properties": { "success": { "type": "boolean", "description": "Indicates whether the request was successful", "example": false }, "message": { "type": "string", "description": "Human-readable error description", "example": "Request failed. The feature is disabled for the account." } }, "description": "The feature is disabled for the account." }, "TenDLCBrandCreateRequest": { "title": "TenDLCBrandCreateRequest", "type": "object", "description": "10DLC Brand registration request", "additionalProperties": false, "required": [ "dba_name", "company_name", "entity_type", "vertical", "ein_taxid", "ein_taxid_country", "first_name", "last_name", "phone_number", "email", "street_address", "city", "country", "zip" ], "properties": { "dba_name": { "type": "string", "description": "Brand name or DBA", "maxLength": 255, "example": "Brand" }, "company_name": { "type": "string", "description": "Legal name of the company", "maxLength": 255, "example": "Company" }, "entity_type": { "type": "string", "description": "Legal entity type of the company. One of `PRIVATE_PROFIT` (privately held for-profit company), `PUBLIC_PROFIT` (publicly traded for-profit company), `NON_PROFIT` (non-profit organization), or `GOVERNMENT` (government entity).", "enum": [ "PRIVATE_PROFIT", "PUBLIC_PROFIT", "NON_PROFIT", "GOVERNMENT" ], "example": "PUBLIC_PROFIT" }, "vertical": { "type": "string", "description": "Business segment the Brand operates in. One of:\n\n- `HEALTHCARE` — healthcare.\n- `PROFESSIONAL` — professional services.\n- `RETAIL` — retail.\n- `TECHNOLOGY` — technology.\n- `EDUCATION` — education.\n- `FINANCIAL` — financial services.\n- `NON_PROFIT` — non-profit organizations.\n- `GOVERNMENT` — government entities.\n- `OTHER` — any segment not listed above.", "enum": [ "HEALTHCARE", "PROFESSIONAL", "RETAIL", "TECHNOLOGY", "EDUCATION", "FINANCIAL", "NON_PROFIT", "GOVERNMENT", "OTHER" ], "example": "PROFESSIONAL" }, "ein_taxid": { "type": "string", "description": "IRS Employee Identification Number (EIN) for US-based or foreign companies with EIN. The numeric portion of Tax ID for companies incorporated in other countries.", "maxLength": 21, "example": "12-2142342" }, "ein_taxid_country": { "type": "string", "description": "2-letter ISO country code of the Tax ID issuing country", "minLength": 2, "maxLength": 2, "example": "US" }, "website": { "type": "string", "description": "The website of the business", "maxLength": 255, "example": "Tess.com" }, "stock_symbol": { "type": [ "string", "null" ], "description": "The stock symbol of the Brand. For PUBLIC_PROFIT Brands only.", "maxLength": 10 }, "stock_exchange": { "type": [ "string", "null" ], "description": "The stock exchange code. For PUBLIC_PROFIT Brands only.", "maxLength": 10, "example": "NASDAQ" }, "first_name": { "type": "string", "description": "The first name of the business contact", "maxLength": 100, "example": "John" }, "last_name": { "type": "string", "description": "The last name of the business contact", "maxLength": 100, "example": "Dow" }, "phone_number": { "type": "string", "description": "The support contact telephone in E.164 format", "maxLength": 20, "example": "12046661776" }, "email": { "type": "string", "description": "The email address of the support contact", "format": "email", "maxLength": 100, "example": "support@brand.com" }, "street_address": { "type": "string", "description": "Street name and house number", "maxLength": 100, "example": "10, City Name" }, "city": { "type": "string", "description": "The city name", "maxLength": 100, "example": "Miami" }, "state_or_province": { "type": [ "string", "null" ], "description": "State or province. For the United States, it is a 2-character code.", "maxLength": 20, "example": "AL" }, "zip": { "type": "string", "description": "The business zip or postal code", "maxLength": 10, "example": "12345" }, "country": { "type": "string", "description": "2-letter ISO country code the business address", "minLength": 2, "maxLength": 2, "example": "US" }, "mock": { "type": "boolean", "description": "Indicates a mock Brand. Mock Brands are for testing purposes only; production traffic with mock Brands is prohibited.", "default": false, "example": false } }, "oneOf": [ { "description": "PUBLIC_PROFIT brands must provide stock_symbol and stock_exchange.", "properties": { "entity_type": { "const": "PUBLIC_PROFIT" } }, "required": [ "stock_symbol", "stock_exchange" ] }, { "description": "Non-PUBLIC_PROFIT brands must not include stock_symbol or stock_exchange.", "properties": { "entity_type": { "enum": [ "PRIVATE_PROFIT", "NON_PROFIT", "GOVERNMENT" ] }, "stock_symbol": { "type": "null" }, "stock_exchange": { "type": "null" } } } ], "example": { "dba_name": "Brand", "company_name": "Company", "entity_type": "PUBLIC_PROFIT", "vertical": "PROFESSIONAL", "ein_taxid": "12-2142342", "ein_taxid_country": "US", "website": "Tess.com", "stock_symbol": null, "stock_exchange": "NASDAQ", "first_name": "John", "last_name": "Doe", "phone_number": "12046661776", "email": "support@brand.com", "street_address": "10, Street name", "city": "Miami", "state_or_province": "AL", "zip": "12345", "country": "US", "mock": false } }, "TenDLCBrandUpdateRequest": { "title": "TenDLCBrandUpdateRequest", "type": "object", "additionalProperties": false, "description": "A request to update a 10DLC Brand details", "properties": { "dba_name": { "type": "string", "description": "Brand name or DBA", "maxLength": 255, "example": "Brand" }, "company_name": { "type": "string", "description": "Legal name of the company", "maxLength": 255, "example": "Company" }, "entity_type": { "type": "string", "description": "Legal entity type of the company. One of `PRIVATE_PROFIT` (privately held for-profit company), `PUBLIC_PROFIT` (publicly traded for-profit company), `NON_PROFIT` (non-profit organization), or `GOVERNMENT` (government entity).", "enum": [ "PRIVATE_PROFIT", "PUBLIC_PROFIT", "NON_PROFIT", "GOVERNMENT" ], "example": "PRIVATE_PROFIT" }, "vertical": { "type": "string", "description": "Business segment the Brand operates in. One of:\n\n- `HEALTHCARE` — healthcare.\n- `PROFESSIONAL` — professional services.\n- `RETAIL` — retail.\n- `TECHNOLOGY` — technology.\n- `EDUCATION` — education.\n- `FINANCIAL` — financial services.\n- `NON_PROFIT` — non-profit organizations.\n- `GOVERNMENT` — government entities.\n- `OTHER` — any segment not listed above.", "enum": [ "HEALTHCARE", "PROFESSIONAL", "RETAIL", "TECHNOLOGY", "EDUCATION", "FINANCIAL", "NON_PROFIT", "GOVERNMENT", "OTHER" ], "example": "HEALTHCARE" }, "ein_taxid": { "type": "string", "description": "IRS Employee Identification Number (EIN) for US-based or foreign companies with EIN. The numeric portion of Tax ID for companies incorporated in other countries.", "maxLength": 21, "example": "999999999" }, "ein_taxid_country": { "type": "string", "description": "2-letter ISO country code of the Tax ID issuing country", "minLength": 2, "maxLength": 2, "example": "US" }, "website": { "type": "string", "description": "The website of the business", "maxLength": 255, "example": "https://brand.com" }, "stock_symbol": { "type": [ "string", "null" ], "description": "The stock symbol of the Brand. For PUBLIC_PROFIT Brands only.", "maxLength": 10 }, "stock_exchange": { "type": [ "string", "null" ], "description": "The stock exchange code. For PUBLIC_PROFIT Brands only.", "maxLength": 10 }, "first_name": { "type": "string", "description": "The first name of the business contact", "maxLength": 100, "example": "John" }, "last_name": { "type": "string", "description": "The last name of the business contact", "maxLength": 100, "example": "Dow" }, "phone_number": { "type": "string", "description": "The support contact telephone in E.164 format", "maxLength": 20, "example": "12123450099" }, "email": { "type": "string", "description": "The email address of the support contact", "maxLength": 100, "format": "email", "example": "support@brand.com" }, "street_address": { "type": "string", "description": "Street name and house number", "maxLength": 100, "example": "10, City Name" }, "city": { "type": "string", "description": "The city name", "maxLength": 100, "example": "Miami" }, "state_or_province": { "type": [ "string", "null" ], "description": "State or province. For the United States, it is a 2-character code.", "maxLength": 20, "example": "FL" }, "zip": { "type": "string", "description": "The business zip or postal code", "maxLength": 10, "example": "12346" }, "country": { "type": "string", "description": "2-letter ISO country code the business address", "minLength": 2, "maxLength": 2, "example": "US" }, "mock": { "type": "boolean", "description": "Mock flag for testing (optional, defaults to false)", "default": false, "example": false } } }, "TCRErrorMessage": { "title": "TCRErrorMessage", "required": [ "code", "message" ], "type": "object", "additionalProperties": false, "properties": { "code": { "type": "string", "description": "TCR error code" }, "message": { "type": "string", "description": "A human-readable error description" } }, "example": { "code": "TFTI01", "message": "The submitted US EIN is invalid." } }, "TCRFeedbackCategory": { "title": "TCRFeedbackCategory", "required": [ "id", "display_name", "description", "fields", "errors" ], "type": "object", "additionalProperties": false, "properties": { "id": { "type": "string", "description": "The submitted appeal category", "example": "VERIFY_TAX_ID" }, "display_name": { "type": "string", "description": "The display name of the category", "example": "Verify tax ID" }, "description": { "type": "string", "description": "The description of the category", "example": "Select this category if the record is UNVERIFIED due to an inability to match the tax ID." }, "fields": { "type": [ "string", "null" ], "description": "An array of Brand attributes" }, "errors": { "type": [ "array", "null" ], "items": { "$ref": "#/components/schemas/TCRErrorMessage" }, "description": "An array of verification errors, if any" } }, "description": "TCR returns the feedback per submitted appeal category" }, "TCRFeedback": { "title": "TCRFeedback", "required": [ "category" ], "type": "object", "additionalProperties": false, "properties": { "category": { "type": "array", "items": { "$ref": "#/components/schemas/TCRFeedbackCategory" }, "description": "The feedback category" } } }, "TenDLCBrandAppealOutcome": { "title": "TenDLCBrandAppealOutcome", "required": [ "optional_attributes", "vetting_status", "feedback" ], "type": "object", "additionalProperties": false, "properties": { "optional_attributes": { "type": "object", "additionalProperties": false, "description": "An optional attributes that might be returned from TCR" }, "vetting_status": { "$ref": "#/components/schemas/TenDLCBrandIdentityVerificationStatus", "description": "Brand Identity Verification appeal outcome", "example": "UNVERIFIED", "type": "string" }, "feedback": { "allOf": [ { "$ref": "#/components/schemas/TCRFeedback" }, { "description": "Brand Identity Verification appeal feedback, if any" } ], "type": "object" } } }, "TenDLCBrandAppeal": { "title": "TenDLCBrandAppeal", "required": [ "categories", "created_at", "evidence", "outcome", "status", "updated_at", "explanation" ], "type": "object", "additionalProperties": false, "properties": { "categories": { "type": "array", "items": { "type": "string" }, "description": "A list of Brand Identity status appeal categories associated with the original request", "example": [ "VERIFY_TAX_ID" ] }, "created_at": { "type": "string", "description": "The date and time the appeal request is created", "example": "2024-08-01T14:09:43" }, "evidence": { "type": "array", "items": { "type": "string" }, "description": "A list of evidence UUIDs to be associated with the appeal", "example": [ "13d8e00c-3cb4-4dc0-9e26-d5057fa938d9" ] }, "outcome": { "allOf": [ { "$ref": "#/components/schemas/TenDLCBrandAppealOutcome" }, { "description": "The appeal outcome details" } ], "type": "object" }, "status": { "type": "string", "description": "The appeal status", "example": "COMPLETED" }, "updated_at": { "type": "string", "description": "The date and time the appeal request is updated", "example": "2024-08-01T14:09:43" }, "explanation": { "type": "string", "description": "The appeal justification", "example": "Dear partner, please review the uploaded company registration docs." } }, "example": { "categories": [ "VERIFY_TAX_ID" ], "created_at": "2024-08-01T14:09:43", "evidence": [], "explanation": "Dear partner, please review the registration docs", "outcome": { "optional_attributes": {}, "feedback": { "category": [] }, "vetting_status": "VERIFIED" }, "status": "COMPLETE", "updated_at": "2024-08-01T18:33:15" } }, "TenDLCBrandAppealCreateRequest": { "title": "TenDLCBrandAppealCreateRequest", "required": [ "appeal_categories", "evidence" ], "type": "object", "additionalProperties": false, "properties": { "appeal_categories": { "type": "array", "items": { "type": "string", "enum": [ "VERIFY_TAX_ID", "VERIFY_NON_PROFIT", "VERIFY_GOVERNMENT" ] }, "description": "List of appeal categories. Allowed values: `VERIFY_TAX_ID`, `VERIFY_NON_PROFIT`, `VERIFY_GOVERNMENT`", "example": [ "VERIFY_TAX_ID" ] }, "evidence": { "type": "array", "items": { "type": "string" }, "description": "List of evidence IDs associated with the appeal.", "example": [ "855dff49-c097-4645-3983-08dcb9856232" ] }, "explanation": { "type": "string", "description": "Appeal comment or justification.", "example": "Find the company incorporation docs attached and please review the Brand Identity status." } }, "description": "Brand identity verification appeal details." }, "TenDLCBrandEvidence": { "title": "TenDLCBrandEvidence", "required": [ "file_name", "mime_type", "url", "uuid" ], "type": "object", "additionalProperties": false, "properties": { "file_name": { "type": "string", "description": "The uploaded file name", "example": "image.png" }, "mime_type": { "type": "string", "description": "The uploaded file media type", "example": "image/png" }, "url": { "type": "string", "description": "An URL to the uploaded file", "example": "https://api.wavix.com/v3/10dlc/brands/B6AI7PA/evidence/191eb205-8357-4d71-b8da-160a25a000d7" }, "uuid": { "type": "string", "description": "The evidence UUID", "example": "191eb205-8357-4d71-b8da-160a25a000d7" } }, "example": { "file_name": "image.png", "mime_type": "image/png", "url": "https://api.wavix.com/v3/10dlc/brands/B6AI7PA/evidence/191eb205-8357-4d71-b8da-160a25a000d7", "uuid": "191eb205-8357-4d71-b8da-160a25a000d7" } }, "ListBrandEvidenceResponse": { "type": "object", "required": [ "items" ], "properties": { "items": { "type": "array", "description": "List of uploaded evidence files", "items": { "$ref": "#/components/schemas/TenDLCBrandEvidence" } } } }, "TenDLCBrandVetting": { "title": "TenDLCBrandVetting", "description": "Represents the result of an external vetting performed on a 10DLC brand. Vetting can raise a Brand's trust score and unlock higher messaging throughput.", "required": [ "evp_id", "create_date", "vetted_date", "vetting_id", "vetting_token", "vetting_score", "vetting_class", "vetting_status", "reasons" ], "type": "object", "additionalProperties": false, "properties": { "evp_id": { "type": "string", "description": "Code identifying the external vetting provider that performed the vetting.", "example": "AEGIS" }, "create_date": { "type": "string", "description": "Timestamp when the vetting request was created, in ISO 8601 format.", "example": "2024-08-01T14:09:43" }, "vetting_details": { "type": "object", "description": "Additional provider-specific details about the vetting request.", "additionalProperties": true, "example": { "additional_prop1": {}, "additional_prop2": {}, "additional_prop3": {} } }, "vetted_date": { "type": [ "string", "null" ], "description": "Timestamp when the vetting was completed, in ISO 8601 format. Null while the vetting is still in progress.", "example": "2024-08-01T14:09:43" }, "vetting_id": { "type": "string", "description": "Unique identifier of the vetting request.", "example": "13d8e00c-3cb4-4dc0-9e26-d5057fa938d9" }, "vetting_token": { "type": [ "string", "null" ], "description": "Token issued by the vetting provider that uniquely identifies this vetting result.", "example": "3oDcE1vq8OR43claMa6Thu/7V4vzZywAfKRgiJnXDjlw+08wpWbGqOssAXKgeZibHCLaGgXvU/yPb7kISeeb5qGdisGRLdhPnSNpvRR82RnCWYNpTp92orlJWjTJU8ZGmNxL5MwK0tt/9SxCha36iTtPV2+4vND8xCPe5suItuQTonG4A3Yi6F1LMqihgwdesRjxJnKqcE7Thcv9ug1NyNPYEZQvPugFj2F2DdU6jFZcOWgXsnE7ucZ+xNaNX9LkF9if3v0hrcviG9L8bUUrpPBGr02txP0i+cPBTLbj4Rq1Ox83R+WUx1gnoXHCIU1ByDGWvQq2Ef4qxGVOwPJHJbja1BovxKBk4YJxiz8OSO68QAIEfxuPTpj5eZz7KEFtFmBIVaVmxBDe4b8Tpl01C2rek7xgPzXaoURvh7CQVnVmJL00DTWKvyOmUOQQW901XEcgcJ7VWgfIvxhIMuXEXXtVDGNowmEc9JQXXYHVlGuN5QicSbApkwwqRZI7TQ4lsS66zCfqomIIJyBNRJpl+8sGwsa2J2h6fEkAD77J9zdUgIKXMFamHbvRadCKMZNIbMrkOC7PuOjZdSiWKh5A8FSjzkv3PlN2hRDqkaODEoodp5pTQeBtNe37+uAMOuHNfsZXlwvfMgCZjiZJ9HQNSLhJBUq7/IvT/EzszUk4HPTj/WFSbT1YrrkDi+zrB20ZDY9lZFWxN1hlYQoNcanDAAWPmw/yW1+8DroL5WIMGsXX3WFGOG7eWB1GHgFQsziAeRQl78u1qOvsRMN08+GrkASBJwqwy5l7xCesUKqbz3O0QA/dwzzsWIDvFPavZpjqMBSjRTurQLFahAaGmdY0BX/Ii+s2+OxfaHQIa1lgucm0P7GPKeZvLX/8boO01Onr/87ra+NX7ABvQb+SXvwsg+Bm5CziWB6DMKDKRD/KQjHxpjIY35UwSEW7G4ixux7ufizXttthHfPJWd/rWFhfYigFhVLgIPCR12smwFVuZwM7ujvY2CIM0X4E0dsX9uVHkgYmqRIdNf5vshpmRuIcHsXZpTJP/tD7zQM6m214c5xkJSfAVIaD7WzRYS4eVL+R3z4u+6n5p6FjuWSjSzuEffUai3HCWjes4JbtDSjIwoG0tOMtBukgPbreH+pjXcvnhU+1QhCV2aIdG6C3FmaI5Uoo/mthJyiFAThwtOpxQ5YkdsRunqVVEFYZfMNEn4Ig2clCFrLOm46JB2wPcLGP2MoH5RqajYzQ6IV8IXIFQVzG0C7HoHsBkVp+GrpnH6N0FCKR+fpbGjigM2lLf4pYBhChUY4ao9hvV1hd8ikS6QoasvDLPytBBa1YAwbSa8d7YdwO6fXfQqetfS8S9gbHD0zxazw5p9Lp5fXFmajDNkD2voYNMzOHJMMHG/49pWV2" }, "vetting_score": { "type": [ "integer", "null" ], "description": "Score assigned to the Brand by the vetting provider. Null until vetting completes.", "format": "int32", "example": 80 }, "vetting_class": { "type": "string", "description": "Class of vetting performed, such as `STANDARD` or `ENHANCED`.", "example": "STANDARD" }, "vetting_status": { "type": "string", "description": "Current status of the vetting request, such as `PENDING` or `ACTIVE`.", "example": "PENDING" }, "reasons": { "type": [ "array", "null" ], "description": "Reasons explaining the assigned `vetting_score`. Null when no reasons are provided.", "items": { "type": "string" }, "example": [ "Company size as reported by government or business sources resulted in a score deduction: size range 6-10" ] } } }, "TenDLCBrandVettingImportRequest": { "title": "TenDLCBrandVettingImportRequest", "required": [ "evp_id", "vetting_id", "vetting_token" ], "type": "object", "additionalProperties": false, "properties": { "evp_id": { "type": "string", "description": "Code identifying the external vetting provider that issued the vetting.", "example": "AEGIS" }, "vetting_id": { "type": "string", "description": "Unique identifier of the vetting request to import.", "example": "13d8e00c-3cb4-4dc0-9e26-d5057fa938d9" }, "vetting_token": { "type": "string", "description": "Token issued by the vetting provider that uniquely identifies the vetting result to import.", "example": "3oDcE1vq8OR43claMa6Thu/7V4vzZywAfKRgiJnXDjlw+08wpWbGqOssAXKgeZibHCLaGgXvU/yPb7kISeeb5qGdisGRLdhPnSNpvRR82RnCWYNpTp92orlJWjTJU8ZGmNxL5MwK0tt/9SxCha36iTtPV2+4vND8xCPe5suItuQTonG4A3Yi6F1LMqihgwdesRjxJnKqcE7Thcv9ug1NyNPYEZQvPugFj2F2DdU6jFZcOWgXsnE7ucZ+xNaNX9LkF9if3v0hrcviG9L8bUUrpPBGr02txP0i+cPBTLbj4Rq1Ox83R+WUx1gnoXHCIU1ByDGWvQq2Ef4qxGVOwPJHJbja1BovxKBk4YJxiz8OSO68QAIEfxuPTpj5eZz7KEFtFmBIVaVmxBDe4b8Tpl01C2rek7xgPzXaoURvh7CQVnVmJL00DTWKvyOmUOQQW901XEcgcJ7VWgfIvxhIMuXEXXtVDGNowmEc9JQXXYHVlGuN5QicSbApkwwqRZI7TQ4lsS66zCfqomIIJyBNRJpl+8sGwsa2J2h6fEkAD77J9zdUgIKXMFamHbvRadCKMZNIbMrkOC7PuOjZdSiWKh5A8FSjzkv3PlN2hRDqkaODEoodp5pTQeBtNe37+uAMOuHNfsZXlwvfMgCZjiZJ9HQNSLhJBUq7/IvT/EzszUk4HPTj/WFSbT1YrrkDi+zrB20ZDY9lZFWxN1hlYQoNcanDAAWPmw/yW1+8DroL5WIMGsXX3WFGOG7eWB1GHgFQsziAeRQl78u1qOvsRMN08+GrkASBJwqwy5l7xCesUKqbz3O0QA/dwzzsWIDvFPavZpjqMBSjRTurQLFahAaGmdY0BX/Ii+s2+OxfaHQIa1lgucm0P7GPKeZvLX/8boO01Onr/87ra+NX7ABvQb+SXvwsg+Bm5CziWB6DMKDKRD/KQjHxpjIY35UwSEW7G4ixux7ufizXttthHfPJWd/rWFhfYigFhVLgIPCR12smwFVuZwM7ujvY2CIM0X4E0dsX9uVHkgYmqRIdNf5vshpmRuIcHsXZpTJP/tD7zQM6m214c5xkJSfAVIaD7WzRYS4eVL+R3z4u+6n5p6FjuWSjSzuEffUai3HCWjes4JbtDSjIwoG0tOMtBukgPbreH+pjXcvnhU+1QhCV2aIdG6C3FmaI5Uoo/mthJyiFAThwtOpxQ5YkdsRunqVVEFYZfMNEn4Ig2clCFrLOm46JB2wPcLGP2MoH5RqajYzQ6IV8IXIFQVzG0C7HoHsBkVp+GrpnH6N0FCKR+fpbGjigM2lLf4pYBhChUY4ao9hvV1hd8ikS6QoasvDLPytBBa1YAwbSa8d7YdwO6fXfQqetfS8S9gbHD0zxazw5p9Lp5fXFmajDNkD2voYNMzOHJMMHG/49pWV2" } } }, "TenDLCBrandVettingCreateRequest": { "title": "TenDLCBrandVettingCreateRequest", "required": [ "evp_id", "vetting_class" ], "type": "object", "additionalProperties": false, "properties": { "evp_id": { "type": "string", "description": "Code identifying the external vetting provider to perform the vetting.", "example": "AEGIS" }, "vetting_class": { "type": "string", "description": "Class of vetting to request, such as `STANDARD` or `ENHANCED`.", "example": "STANDARD" } } }, "TenDLCBrandVettingAppealOutcomeReason": { "title": "TenDLCBrandVettingAppealOutcomeReason", "required": [ "reasons" ], "type": "object", "additionalProperties": false, "properties": { "reasons": { "type": "array", "items": { "type": "string" }, "description": "An list of human-readable explanations returned by TCR", "example": [ "Company size as reported by government or business sources resulted in a score deduction: size range 6-10." ] } }, "example": { "reasons": [ "Company size as reported by government or business sources resulted in a score deduction: size range 6-10." ] } }, "TenDLCBrandVettingAppealOutcome": { "title": "TenDLCBrandVettingAppealOutcome", "required": [ "vet_status", "vet_score", "feedback" ], "type": "object", "additionalProperties": false, "properties": { "vet_status": { "type": "string", "description": "Current status of the Brand vetting", "example": "ACTIVE" }, "vet_score": { "type": "integer", "description": "The Brand vetting score", "format": "int32", "example": 80 }, "feedback": { "allOf": [ { "$ref": "#/components/schemas/TenDLCBrandVettingAppealOutcomeReason" }, { "description": "The feedback provided by the external vetting provider" } ], "type": "object" } }, "example": { "vet_status": "ACTIVE", "vet_score": 80, "feedback": { "reasons": [ "Company size as reported by government or business sources resulted in a score deduction: size range 6-10." ] } } }, "TenDLCBrandVettingAppeal": { "title": "TenDLCBrandVettingAppeal", "description": "Represents an appeal against a 10DLC brand vetting result. An appeal asks the vetting provider to reconsider the assigned score.", "required": [ "appeal_outcome", "appeal_status", "appeal_status_update_date", "attachment_uuid_list", "brand_id", "category_list", "create_date", "explanation", "evp_id", "vetting_class", "vetting_id" ], "type": "object", "additionalProperties": false, "properties": { "appeal_outcome": { "allOf": [ { "$ref": "#/components/schemas/TenDLCBrandVettingAppealOutcome" }, { "description": "Outcome of the appeal, including the revised vetting status and score.", "example": { "vet_status": "ACTIVE", "vet_score": 80, "feedback": { "reasons": [ "Company size as reported by government or business sources resulted in a score deduction: size range 6-10." ] } } } ], "type": "object" }, "appeal_status": { "type": "string", "description": "Current status of the appeal, such as `PENDING` or `COMPLETE`.", "example": "COMPLETE" }, "appeal_status_update_date": { "type": "string", "description": "Timestamp when the appeal status was last updated, in ISO 8601 format.", "example": "2024-08-15T08:42:31" }, "attachment_uuid_list": { "type": "array", "items": { "type": "string" }, "description": "UUIDs of the evidence files submitted in support of the appeal.", "example": [] }, "brand_id": { "type": "string", "description": "Unique identifier of the Brand the appeal is associated with.", "example": "BMQFB7X" }, "category_list": { "type": "array", "items": { "type": "string" }, "description": "Categories that classify the appeal, such as `LOW_SCORE`.", "example": [ "LOW_SCORE" ] }, "create_date": { "type": "string", "description": "Timestamp when the appeal was created, in ISO 8601 format.", "example": "2024-08-15T08:41:05" }, "explanation": { "type": "string", "description": "Justification provided for the appeal.", "example": "Please review the Brand score" }, "evp_id": { "type": "string", "description": "Code identifying the external vetting provider that handled the appeal.", "example": "AEGIS" }, "vetting_class": { "type": "string", "description": "Class of the vetting being appealed, such as `STANDARD` or `ENHANCED`.", "example": "STANDARD" }, "vetting_id": { "type": "string", "description": "Unique identifier of the vetting request being appealed.", "example": "48c0ffaa-4e51-4d44-3982-08dcb9856232" } }, "example": { "appeal_outcome": { "vet_status": "ACTIVE", "vet_score": 80, "feedback": { "reasons": [ "Company size as reported by government or business sources resulted in a score deduction: size range 6-10." ] } }, "appeal_status": "COMPLETE", "appeal_status_update_date": "2024-08-15T08:42:31", "attachment_uuid_list": [], "brand_id": "BMQFB7X", "category_list": [ "LOW_SCORE" ], "create_date": "2024-08-15T08:41:05", "evp_id": "AEGIS", "explanation": "Please review the Brand score", "vetting_class": "STANDARD", "vetting_id": "48c0ffaa-4e51-4d44-3982-08dcb9856232" } }, "TenDLCBrandVettingAppealCreateRequest": { "title": "TenDLCBrandVettingAppealCreateRequest", "required": [ "appeal_categories", "evidence" ], "type": "object", "additionalProperties": false, "properties": { "appeal_categories": { "type": "array", "items": { "type": "string", "enum": [ "VERIFY_TAX_ID", "VERIFY_NON_PROFIT", "VERIFY_GOVERNMENT", "LOW_SCORE" ] }, "description": "List of appeal categories. Allowed values: `VERIFY_TAX_ID`, `VERIFY_NON_PROFIT`, `VERIFY_GOVERNMENT`, `LOW_SCORE`. `LOW_SCORE` is only valid for vetting appeals — brand identity appeals (`ten_dlc_brand_appeals_create`) do not accept it.", "example": [ "VERIFY_TAX_ID" ] }, "evidence": { "type": "array", "items": { "type": "string" }, "description": "List of evidence IDs associated with the appeal.", "example": [ "855dff49-c097-4645-3983-08dcb9856232" ] }, "explanation": { "type": "string", "description": "Appeal comment or justification.", "example": "Find the company incorporation docs attached and please review the Brand Identity status." }, "evp_id": { "type": "string", "description": "EVP ID.", "example": "AEGIS" }, "vetting_id": { "type": "string", "description": "Vetting ID.", "example": "48c0ffaa-4e51-4d44-3982-08dcb9856232" } }, "description": "Brand external vetting appeal details." }, "TenDLCMNOMetadata": { "title": "TenDLCMNOMetadata", "required": [ "att_mms_tpm", "att_msg_class", "att_sms_tpm", "att_tpm_scope", "help_required", "optin_required", "optout_required", "min_msg_samples", "mno", "mno_qualify", "mno_review", "mno_support", "no_embedded_links", "no_embedded_phone", "tmobile_brand_dcap", "tmobile_brand_tier" ], "type": "object", "additionalProperties": false, "description": "Represents per-MNO 10DLC requirements and throughput limits that apply to a campaign use case.", "properties": { "att_mms_tpm": { "type": [ "integer", "null" ], "description": "MMS throughput per minute allowed on the AT&T network.", "format": "int32" }, "att_msg_class": { "type": [ "string", "null" ], "description": "Message class assigned by AT&T." }, "att_sms_tpm": { "type": [ "integer", "null" ], "description": "SMS throughput per minute allowed on the AT&T network.", "format": "int32" }, "att_tpm_scope": { "type": [ "string", "null" ], "description": "Scope of the AT&T throughput-per-minute allocation.", "format": "int32" }, "help_required": { "type": "boolean", "description": "Indicates whether help keywords and an acknowledgement are mandatory for the use case.", "example": true }, "optin_required": { "type": "boolean", "description": "Indicates whether an opt-in mechanism is mandatory for the use case.", "example": true }, "optout_required": { "type": "boolean", "description": "Indicates whether an opt-out mechanism is mandatory for the use case.", "example": false }, "min_msg_samples": { "type": "integer", "description": "Minimum number of message samples the MNO requires for the use case.", "format": "int32", "example": 1 }, "mno": { "type": "string", "description": "Name of the mobile network operator (MNO) these requirements apply to.", "example": "T-Mobile" }, "mno_qualify": { "type": "boolean", "description": "Indicates whether the Brand qualifies with the MNO for the selected use case.", "example": true }, "mno_review": { "type": "boolean", "description": "Indicates whether the MNO requires a post-approval review of the use case.", "example": false }, "mno_support": { "type": "boolean", "description": "Indicates whether the MNO supports the use case.", "example": true }, "no_embedded_links": { "type": "boolean", "description": "Indicates whether embedded links are prohibited in message content for the use case.", "example": false }, "no_embedded_phone": { "type": "boolean", "description": "Indicates whether embedded phone numbers are prohibited in message content for the use case.", "example": false }, "tmobile_brand_dcap": { "type": [ "integer", "null" ], "description": "Daily message cap allowed on the T-Mobile network.", "format": "int32", "example": 2000 }, "tmobile_brand_tier": { "type": [ "string", "null" ], "description": "Brand tier assigned on the T-Mobile network, such as `LOW`.", "example": "LOW" } }, "example": { "att_mms_tpm": null, "att_msg_class": null, "att_sms_tpm": null, "att_tpm_scope": null, "help_required": true, "min_msg_samples": 1, "mno": "T-Mobile", "mno_qualify": true, "mno_review": false, "mno_support": true, "no_embedded_links": false, "no_embedded_phone": false, "optin_required": true, "optout_required": false, "tmobile_brand_dcap": 2000, "tmobile_brand_tier": "LOW" } }, "TenDLCBrandQualificationResult": { "title": "TenDLCBrandQualificationResult", "required": [ "mno_metadata", "monthly_fee", "usecase" ], "type": "object", "additionalProperties": false, "properties": { "mno_metadata": { "type": "array", "items": { "$ref": "#/components/schemas/TenDLCMNOMetadata" }, "description": "An array MNO-specific attributes (e.g. AT&T message class) for every MNO the Brand is qualified to run a Campaign with the specified use case." }, "monthly_fee": { "type": "number", "description": "Monthly fee associated with any Campaign with this use case", "example": 10 }, "usecase": { "type": "string", "description": "The use case name", "example": "2FA" } }, "example": { "mno_metadata": [ { "att_mms_tpm": null, "att_msg_class": null, "att_sms_tpm": null, "att_tpm_scope": null, "help_required": true, "min_msg_samples": 1, "mno": "T-Mobile", "mno_qualify": true, "mno_review": false, "mno_support": true, "no_embedded_links": false, "no_embedded_phone": false, "optin_required": true, "optout_required": false, "tmobile_brand_dcap": 2000, "tmobile_brand_tier": "LOW" } ], "monthly_fee": 10, "usecase": "2FA" } }, "TenDLCCampaign": { "title": "TenDLCCampaign", "required": [ "affiliate_marketing", "age_gated", "auto_renewal", "last_bill_date", "next_bill_date", "direct_lending", "embedded_links", "embedded_phones", "embedded_link_sample", "brand_id", "campaign_id", "description", "optin_workflow", "feedback", "help", "help_keywords", "help_message", "optin", "optin_keywords", "optin_message", "optout", "optout_keywords", "optout_message", "name", "created_at", "sample1", "sample2", "sample3", "sample4", "sample5", "updated_at", "mock", "usecase", "monthly_fee", "terms_conditions", "privacy_policy", "status", "phone_numbers" ], "type": "object", "additionalProperties": false, "properties": { "affiliate_marketing": { "type": "boolean", "description": "Indicates whether the Campaign is used for affiliate marketing.", "example": false }, "age_gated": { "type": "boolean", "description": "Indicates whether the Campaign messages contain age-gated content.", "example": false }, "auto_renewal": { "type": "boolean", "description": "Indicates whether the Campaign should be automatically renewed.", "example": true }, "last_bill_date": { "type": [ "string", "null" ], "description": "Date and time the Campaign was last billed in ISO 8601 format. `null` if the Campaign has never been billed.", "example": "2024-08-14T11:57:42" }, "next_bill_date": { "type": [ "string", "null" ], "description": "Date and time the Campaign will be billed next in ISO 8601 format. `null` if the next billing date is not scheduled.", "example": "2024-08-14T11:57:42" }, "direct_lending": { "type": "boolean", "description": "Indicates whether the Campaign messages contain direct lending content.", "example": true }, "embedded_links": { "type": "boolean", "description": "Indicates whether the Campaign messages contain embedded links.", "example": true }, "embedded_phones": { "type": "boolean", "description": "Indicates whether the Campaign messages contain embedded phone numbers.", "example": true }, "embedded_link_sample": { "type": [ "string", "null" ], "description": "Sample of an embedded link used in Campaign messages." }, "brand_id": { "type": "string", "description": "Unique identifier of the Brand that owns the Campaign.", "example": "BM20QP9" }, "campaign_id": { "type": "string", "description": "Unique identifier of the Campaign assigned by the registry.", "example": "CKLCK95" }, "description": { "type": [ "string", "null" ], "description": "Description of the Campaign and its messaging purpose.", "example": "Our campaign aims to …" }, "optin_workflow": { "type": [ "string", "null" ], "description": "Description of the workflow through which subscribers opt in to the Campaign.", "example": "Our SMS ..." }, "feedback": { "type": [ "string", "null" ], "description": "Feedback from the registry explaining the current `status`." }, "help": { "type": "boolean", "description": "Indicates whether the campaign includes a help system (for example, keyword: HELP, INFO).", "example": true }, "help_keywords": { "type": "string", "description": "Comma-separated list of help keywords. Keywords are case-insensitive.", "example": "help" }, "help_message": { "type": [ "string", "null" ], "description": "Help message sent upon receiving a help keyword.", "example": "For help, please visit www.site.com. To opt out, reply STOP." }, "optin": { "type": "boolean", "description": "Indicates whether the Campaign requires subscriber opt-in.", "example": true }, "optin_keywords": { "type": "string", "description": "Comma-separated list of opt-in keywords. Keywords are case-insensitive.", "example": "begin,start" }, "optin_message": { "type": [ "string", "null" ], "description": "Opt-in message sent upon receiving an opt-in keyword.", "example": "You are now opted-in for help please reply HELP, to stop please reply STOP" }, "optout": { "type": "boolean", "description": "Indicates whether the campaign includes an opt-out system (for example, keyword: STOP, QUIT).", "example": true }, "optout_keywords": { "type": "string", "description": "Comma-separated list of opt-out keywords. Keywords are case-insensitive.", "example": "stop,quit,unsubscribe" }, "optout_message": { "type": [ "string", "null" ], "description": "Opt-out message sent upon receiving an opt-out keyword.", "example": "You are now opted out and will receive no further messages" }, "name": { "type": "string", "description": "Display name of the Campaign.", "example": "My first campaign" }, "created_at": { "type": "string", "description": "Timestamp when the Campaign was created, in ISO 8601 format.", "example": "2024-08-14T11:57:41" }, "sample1": { "type": [ "string", "null" ], "description": "Sample message demonstrating the content sent through the Campaign.", "example": "Your verification code is XXXXXX" }, "sample2": { "type": [ "string", "null" ], "description": "Sample message demonstrating the content sent through the Campaign." }, "sample3": { "type": [ "string", "null" ], "description": "Sample message demonstrating the content sent through the Campaign." }, "sample4": { "type": [ "string", "null" ], "description": "Sample message demonstrating the content sent through the Campaign." }, "sample5": { "type": [ "string", "null" ], "description": "Sample message demonstrating the content sent through the Campaign." }, "updated_at": { "type": "string", "description": "Timestamp when the Campaign was last updated, in ISO 8601 format.", "example": "2024-08-14T11:57:47" }, "mock": { "type": "boolean", "description": "Indicates whether the Campaign is a mock campaign used for testing. Mock campaigns cannot send production traffic.", "example": false }, "usecase": { "type": "string", "description": "Registered use case for the Campaign, such as `2FA` or `MARKETING`.", "example": "2FA" }, "monthly_fee": { "type": "string", "description": "Recurring monthly fee charged for the Campaign, as a decimal string.", "example": "10.0" }, "privacy_policy": { "type": [ "string", "null" ], "description": "Privacy policy URL.", "example": "https://site.com/privacy-policy" }, "terms_conditions": { "type": [ "string", "null" ], "description": "Terms and conditions URL.", "example": "https://site.com/terms-and-conditions" }, "status": { "type": "string", "description": "Current registration status of the Campaign, such as `APPROVED` or `PENDING`.", "example": "APPROVED" }, "phone_numbers": { "type": "array", "items": { "type": "string" }, "description": "Phone numbers assigned to the Campaign, in E.164 format.", "example": [ "14358684439", "13193337776", "12673296046" ] } }, "description": "Represents a 10DLC campaign registered under a Brand. A Campaign defines the messaging use case, opt-in and opt-out flows, and the phone numbers permitted to send its traffic.", "example": { "affiliate_marketing": false, "age_gated": false, "auto_renewal": false, "brand_id": "BM20QP9", "campaign_id": "CKLCK95", "created_at": "2024-08-14T11:57:41", "description": "Our campaign aims to …", "direct_lending": false, "embedded_link_sample": null, "embedded_links": false, "embedded_phones": false, "feedback": null, "help": true, "help_keywords": "help", "help_message": "For help, please visit www.site.com. To opt-out, reply STOP.", "last_bill_date": "2024-08-14T11:57:42", "mock": false, "monthly_fee": "10.0", "name": "My first campaign", "next_bill_date": "2024-11-14T00:00:00", "optin": true, "optin_keywords": "begin,start", "optin_message": "You are now opted-in for help please reply HELP, to stop please reply STOP", "optin_workflow": "Our SMS ...", "optout": true, "optout_keywords": "stop,quit,unsubscribe", "optout_message": "You are now opted out and will receive no further messages", "privacy_policy": "https://site.com/privacy-policy", "sample1": "Your verification code is XXXXXX", "sample2": "XXXX is your verification code", "sample3": null, "sample4": null, "sample5": null, "status": "APPROVED", "terms_conditions": "https://site.com/terms-and-conditions", "updated_at": "2024-08-14T11:57:47", "usecase": "2FA", "phone_numbers": [ "14358684439", "13193337776", "12673296046" ] } }, "TenDLCCampaignListResponse": { "title": "TenDLCCampaignListResponse", "required": [ "items", "pagination" ], "type": "object", "additionalProperties": false, "properties": { "items": { "type": "array", "items": { "$ref": "#/components/schemas/TenDLCCampaign" }, "description": "10DLC Campaigns on the current page that match the filter criteria." }, "pagination": { "allOf": [ { "$ref": "#/components/schemas/Pagination" }, { "description": "Pagination metadata for the result set." } ], "type": "object" } }, "description": "Paginated list of 10DLC Campaigns.", "example": { "items": [ { "affiliate_marketing": false, "age_gated": false, "auto_renewal": false, "brand_id": "BM20QP9", "campaign_id": "CKLCK95", "created_at": "2024-08-14T11:57:41", "description": "Our campaign aims to …", "direct_lending": false, "embedded_link_sample": null, "embedded_links": false, "embedded_phones": false, "feedback": null, "help": true, "help_keywords": "help", "help_message": "For help, please visit www.site.com. To opt-out, reply STOP.", "last_bill_date": "2024-08-14T11:57:42", "mock": false, "monthly_fee": "10.0", "name": "My first campaign", "next_bill_date": "2024-11-14T00:00:00", "optin": true, "optin_keywords": "begin,start", "optin_message": "You are now opted-in for help please reply HELP, to stop please reply STOP", "optin_workflow": "Our SMS ...", "optout": true, "optout_keywords": "stop,quit,unsubscribe", "optout_message": "You are now opted out and will receive no further messages", "privacy_policy": "https://site.com/privacy-policy", "sample1": "Your verification code is XXXXXX", "sample2": "XXXX is your verification code", "sample3": null, "sample4": null, "sample5": null, "status": "APPROVED", "terms_conditions": "https://site.com/terms-and-conditions", "updated_at": "2024-08-14T11:57:47", "usecase": "2FA", "phone_numbers": [ "14358684439", "13193337776", "12673296046" ] } ], "pagination": { "current_page": 1, "per_page": 25, "total": 1, "total_pages": 1 } } }, "TenDLCCampaignCreateRequest": { "title": "TenDLCCampaignCreateRequest", "required": [ "affiliate_marketing", "age_gated", "auto_renewal", "direct_lending", "embedded_links", "description", "optin_workflow", "help", "help_keywords", "help_message", "optin", "optin_keywords", "optin_message", "optout", "optout_keywords", "optout_message", "name", "sample1", "mock", "usecase", "terms_conditions" ], "type": "object", "additionalProperties": false, "properties": { "affiliate_marketing": { "type": "boolean", "description": "Indicates whether the Campaign is used for affiliate marketing.", "example": false }, "age_gated": { "type": "boolean", "description": "Indicates whether the Campaign messages contain age-gated content.", "example": false }, "auto_renewal": { "type": "boolean", "description": "Indicates whether the Campaign is automatically renewed at the end of each billing period.", "example": true }, "direct_lending": { "type": "boolean", "description": "Indicates whether the Campaign messages contain direct lending content.", "example": true }, "embedded_links": { "type": "boolean", "description": "Indicates whether the Campaign messages contain embedded links.", "example": true }, "embedded_phones": { "type": [ "boolean", "null" ], "description": "Indicates whether the Campaign messages contain embedded phone numbers.", "example": true }, "embedded_link_sample": { "type": [ "string", "null" ], "description": "Sample of an embedded link used in Campaign messages." }, "description": { "type": "string", "description": "Description of the Campaign and its messaging purpose.", "example": "Our campaign aims to …" }, "optin_workflow": { "type": "string", "description": "Description of the workflow through which subscribers opt in to the Campaign.", "example": "Our SMS ..." }, "help": { "type": "boolean", "description": "Indicates whether the Campaign provides a help system that subscribers can trigger with a keyword such as HELP or INFO.", "example": true }, "help_keywords": { "type": "string", "description": "Comma-separated list of help keywords. Keywords are case-insensitive.", "example": "help" }, "help_message": { "type": "string", "description": "Acknowledgement sent when a subscriber texts a help keyword.", "example": "For help, please visit www.site.com. To opt out, reply STOP." }, "optin": { "type": "boolean", "description": "Indicates whether the Campaign requires subscribers to opt in before receiving messages.", "example": true }, "optin_keywords": { "type": "string", "description": "Comma-separated list of opt-in keywords. Keywords are case-insensitive.", "example": "begin,start" }, "optin_message": { "type": "string", "description": "Acknowledgement sent when a subscriber texts an opt-in keyword.", "example": "You are now opted-in for help please reply HELP, to stop please reply STOP" }, "optout": { "type": "boolean", "description": "Indicates whether the Campaign provides an opt-out system that subscribers can trigger with a keyword such as STOP or QUIT.", "example": true }, "optout_keywords": { "type": "string", "description": "Comma-separated list of opt-out keywords. Keywords are case-insensitive.", "example": "stop,quit,unsubscribe" }, "optout_message": { "type": "string", "description": "Acknowledgement sent when a subscriber texts an opt-out keyword.", "example": "You are now opted out and will receive no further messages" }, "name": { "type": "string", "description": "Display name of the Campaign.", "example": "My first campaign" }, "sample1": { "type": "string", "description": "Sample message demonstrating the content sent through the Campaign.", "example": "Your verification code is XXXXXX" }, "sample2": { "type": [ "string", "null" ], "description": "Sample message demonstrating the content sent through the Campaign." }, "sample3": { "type": [ "string", "null" ], "description": "Sample message demonstrating the content sent through the Campaign." }, "sample4": { "type": [ "string", "null" ], "description": "Sample message demonstrating the content sent through the Campaign." }, "sample5": { "type": [ "string", "null" ], "description": "Sample message demonstrating the content sent through the Campaign." }, "mock": { "type": "boolean", "description": "Indicates whether the Campaign is a mock campaign used for testing. Mock campaigns cannot send production traffic.", "example": false }, "usecase": { "type": "string", "description": "Registered use case for the Campaign, such as `2FA` or `MARKETING`.", "example": "2FA" }, "privacy_policy": { "type": "string", "description": "URL of the Campaign privacy policy.", "example": "https://site.com/privacy-policy" }, "terms_conditions": { "type": "string", "description": "URL of the Campaign terms and conditions.", "example": "https://site.com/terms-and-conditions" } }, "example": { "affiliate_marketing": false, "age_gated": false, "auto_renewal": false, "description": "Our campaign aims to …", "direct_lending": false, "embedded_link_sample": "https://site.com/verify", "embedded_links": false, "embedded_phones": false, "help": true, "help_keywords": "help", "help_message": "For help, please visit www.site.com. To opt-out, reply STOP.", "mock": false, "name": "My first campaign", "optin": true, "optin_keywords": "begin,start", "optin_message": "You are now opted-in for help please reply HELP, to stop please reply STOP", "optin_workflow": "Our SMS ...", "optout": true, "optout_keywords": "stop,quit,unsubscribe", "optout_message": "You are now opted out and will receive no further messages", "privacy_policy": "https://site.com/privacy-policy", "sample1": "Your verification code is XXXXXX", "sample2": "XXXX is your verification code", "sample3": "Your code is XXXXXX, valid for 10 minutes", "sample4": "Use code XXXXXX to confirm your login", "sample5": "XXXXXX is your one-time passcode", "terms_conditions": "https://site.com/terms-and-conditions", "usecase": "2FA" } }, "TenDLCCampaignUpdateRequest": { "title": "TenDLCCampaignUpdateRequest", "type": "object", "additionalProperties": false, "properties": { "name": { "type": "string", "description": "Display name of the Campaign.", "maxLength": 120, "example": "Campaign" }, "usecase": { "type": "string", "description": "Registered use case for the Campaign. One of `CUSTOMER_CARE` (customer support messaging), `MARKETING` (promotional content), `ACCOUNT_NOTIFICATION` (account-related alerts), `FRAUD_ALERT` (fraud and suspicious-activity warnings), `PUBLIC_SERVICE_ANNOUNCEMENT` (public-interest notices), or `SECURITY_ALERT` (security-related warnings).\n", "enum": [ "CUSTOMER_CARE", "MARKETING", "ACCOUNT_NOTIFICATION", "FRAUD_ALERT", "PUBLIC_SERVICE_ANNOUNCEMENT", "SECURITY_ALERT" ], "example": "MARKETING" }, "description": { "type": "string", "description": "Description of the Campaign and its messaging purpose.", "minLength": 40, "maxLength": 4096, "example": "Explain how users opt in (e.g., via website or paid ads), specify the message frequency, and clearly state that opting in to messages is optional and not required to use the service." }, "embedded_links": { "type": "boolean", "description": "Indicates whether the Campaign messages contain embedded links.", "default": false, "example": false }, "embedded_phones": { "type": "boolean", "description": "Indicates whether the Campaign messages contain embedded phone numbers.", "default": false, "example": false }, "age_gated": { "type": "boolean", "description": "Indicates whether the Campaign messages contain age-gated content.", "default": false, "example": false }, "direct_lending": { "type": "boolean", "description": "Indicates whether the Campaign messages contain direct lending content.", "default": false, "example": false }, "optin": { "type": "boolean", "description": "Indicates whether the Campaign requires subscribers to opt in before receiving messages.", "default": false, "example": true }, "optout": { "type": "boolean", "description": "Indicates whether the Campaign provides an opt-out system that subscribers can trigger with a keyword.", "default": false, "example": true }, "help": { "type": "boolean", "description": "Indicates whether the Campaign provides a help system that subscribers can trigger with a keyword.", "default": false, "example": true }, "sample1": { "type": "string", "description": "Sample message demonstrating the content sent through the Campaign.", "minLength": 20, "maxLength": 1024, "example": "Example of message sample for campaign 1" }, "sample2": { "type": "string", "description": "Sample message demonstrating the content sent through the Campaign.", "minLength": 20, "maxLength": 1024, "example": "Example of message sample for campaign 2" }, "sample3": { "type": "string", "description": "Sample message demonstrating the content sent through the Campaign.", "minLength": 20, "maxLength": 1024, "example": "Example of message sample for campaign 3" }, "sample4": { "type": "string", "description": "Sample message demonstrating the content sent through the Campaign.", "minLength": 20, "maxLength": 1024, "example": "Example of message sample for campaign 4" }, "sample5": { "type": "string", "description": "Sample message demonstrating the content sent through the Campaign.", "minLength": 20, "maxLength": 1024, "example": "Example of message sample for campaign 5" }, "optin_workflow": { "type": "string", "description": "Description of the workflow through which subscribers opt in to the Campaign.", "minLength": 40, "maxLength": 4096, "example": "Our SMS campaign uses a double opt-in workflow where customers reply START to begin" }, "help_message": { "type": "string", "description": "Acknowledgement sent when a subscriber texts a help keyword.", "minLength": 20, "maxLength": 320, "example": "For help, please visit www.site.com. To opt out, reply STOP." }, "optin_message": { "type": "string", "description": "Acknowledgement sent when a subscriber texts an opt-in keyword.", "minLength": 20, "maxLength": 320, "example": "You have opted in to our campaign. Reply HELP for assistance or STOP to unsubscribe." }, "optout_message": { "type": "string", "description": "Acknowledgement sent when a subscriber texts an opt-out keyword.", "minLength": 20, "maxLength": 320, "example": "You have been unsubscribed and will receive no further messages." }, "auto_renewal": { "type": "boolean", "description": "Indicates whether the Campaign is automatically renewed at the end of each billing period.", "default": true, "example": true }, "optin_keywords": { "type": "string", "description": "Comma-separated list of opt-in keywords. Keywords are case-insensitive.", "maxLength": 255, "example": "start,optin" }, "help_keywords": { "type": "string", "description": "Comma-separated list of help keywords. Keywords are case-insensitive.", "maxLength": 255, "default": "HELP", "example": "help" }, "optout_keywords": { "type": "string", "description": "Comma-separated list of opt-out keywords. Keywords are case-insensitive.", "maxLength": 255, "example": "optout,discard" }, "terms_conditions": { "type": "string", "description": "URL of the Campaign terms and conditions.", "maxLength": 255, "example": "https://site.com/terms-and-conditions" }, "privacy_policy": { "type": "string", "description": "URL of the Campaign privacy policy.", "maxLength": 255, "example": "https://site.com/privacy-policy" }, "embedded_link_sample": { "type": "string", "description": "Sample of an embedded link used in Campaign messages.", "maxLength": 255, "example": "https://example.com" } } }, "TenDLCEventSubscription": { "title": "TenDLCEventSubscription", "required": [ "subscription_category", "url" ], "type": "object", "additionalProperties": false, "properties": { "subscription_category": { "type": "string", "description": "Category of 10DLC events to subscribe to. One of `brand` (brand status changes), `campaign` (campaign status changes), or `number` (number provisioning changes).", "example": "brand" }, "url": { "type": "string", "description": "Webhook URL that events in this category are delivered to.", "example": "https://webhook.url" } }, "description": "Represents a subscription that delivers 10DLC lifecycle events to a webhook URL.", "example": { "subscription_category": "brand", "url": "https://webhook.url" } }, "TenDLCCampaignNumber": { "title": "TenDLCCampaignNumber", "required": [ "number", "status" ], "type": "object", "additionalProperties": false, "properties": { "number": { "type": "string", "description": "Phone number assigned to the 10DLC Campaign, in E.164 format.", "example": "17029641104" }, "status": { "type": "string", "description": "Provisioning status of the phone number, such as `APPROVED`. Only `APPROVED` numbers can be used as Sender IDs.", "example": "APPROVED" } } }, "TenDLCCampaignNumberListResponse": { "title": "TenDLCCampaignNumberListResponse", "required": [ "brand_id", "campaign_id", "numbers" ], "type": "object", "additionalProperties": false, "properties": { "brand_id": { "type": "string", "description": "Unique identifier of the 10DLC Brand that owns the Campaign." }, "campaign_id": { "type": "string", "description": "Unique identifier of the 10DLC Campaign the numbers belong to." }, "numbers": { "type": "array", "items": { "$ref": "#/components/schemas/TenDLCCampaignNumber" }, "description": "Phone numbers assigned to the Campaign, with their provisioning status." } } }, "TenDLCCampaignNudgeRequest": { "title": "TenDLCCampaignNudgeRequest", "required": [ "nudge_intent", "description" ], "type": "object", "additionalProperties": false, "properties": { "nudge_intent": { "type": "string", "description": "Action the nudge requests: `REVIEW` requests review of a pending Campaign, and `APPEAL_REJECTION` appeals a rejected Campaign.", "example": "REVIEW" }, "description": { "type": "string", "description": "Description of the nudge request.", "example": "Please review the campaign." } }, "description": "Nudge configuration. Set the nudge intent to `REVIEW` to request action on a pending approval, or to `APPEAL_REJECTION` to submit an appeal for a rejected campaign." }, "PhoneNumberValidationType": { "title": "PhoneNumberValidationType", "enum": [ "format", "analysis", "validation" ], "type": "string", "description": "Depth of validation to perform on the phone number. One of `format` (checks number syntax only), `analysis` (returns number metadata such as type and country), or `validation` (performs a live network lookup of the number's current status)." }, "PhoneValidationResponse": { "title": "PhoneValidationResponse", "required": [ "phone_number", "valid", "country_code", "e164_format", "national_format", "charge", "error_code" ], "type": "object", "additionalProperties": false, "properties": { "phone_number": { "type": "string", "description": "Phone number.", "example": "971569483322" }, "valid": { "type": "boolean", "description": "Indicates whether the phone number is valid.", "example": true }, "country_code": { "type": [ "string", "null" ], "description": "ISO 3166-1 alpha-2 country code of the phone number.\n `null` if the number is invalid.", "example": "AE" }, "e164_format": { "type": "string", "description": "Phone number in international E.164 format.", "example": "+971569483322" }, "national_format": { "type": "string", "description": "Phone number in the national format of the identified country.", "example": "056 948 3322" }, "ported": { "type": [ "boolean", "null" ], "description": "Indicates whether the phone number was ported or not. `null` if the phone number is invalid.", "example": false }, "mcc": { "type": [ "string", "null" ], "description": "Mobile Country Code of the phone number carrier. For mobile phone numbers only. `null` if the phone number is invalid.", "example": "424" }, "mnc": { "type": [ "string", "null" ], "description": "Mobile Network Code of the phone number carrier. For mobile phone numbers only. `null` if the phone number is invalid", "example": "004" }, "number_type": { "type": [ "string", "null" ], "description": "Number type. Possible values are `mobile`, `landline`, or `toll-free`. `null` if the phone number is invalid.", "example": "mobile" }, "carrier_name": { "type": [ "string", "null" ], "description": "Name of the phone number carrier. `null` if the phone number is invalid.", "example": "Etisalat" }, "risky_destination": { "type": [ "boolean", "null" ], "description": "Indicates whether the phone number belongs to a number range associated with traffic pumping. `null` if the number is invalid.", "example": false }, "unallocated_range": { "type": [ "boolean", "null" ], "description": "Indicates whether the phone number belongs to an unallocated number range. `null` if the number is invalid", "example": false }, "reachable": { "type": [ "boolean", "null" ], "description": "Indicates whether the number is registered in a mobile network. For mobile phone numbers only. `null` if the number is invalid", "example": true }, "roaming": { "type": [ "boolean", "null" ], "description": "Indicates whether the number is roaming. For mobile phone numbers only. `null` if the number is invalid", "example": false }, "timezone": { "type": [ "string", "null" ], "description": "Time zone based on the phone number's country and area code.\n `null` if the number is invalid.", "example": "UTC+04:00" }, "charge": { "type": "string", "description": "Charge for the validation.", "example": "0.015" }, "error_code": { "type": "string", "description": "Error code for the request. `000` indicates success.\nPossible values:\n- `013`: — Internal service error\n- `021`: — Invalid phone number length or format\n- `041`: — Request timeout\n- `042`: — Request failed\n- `091`: — Insufficient funds", "example": "000" } } }, "PhoneValidationRequest": { "title": "PhoneValidationRequest", "required": [ "phone_numbers", "type" ], "type": "object", "additionalProperties": false, "properties": { "phone_numbers": { "type": "array", "items": { "type": "string" }, "maxItems": 1000, "description": "List of phone numbers to get detailed information about. Maximum 1000 numbers per request.", "example": [ "971501390098", "971504359195" ] }, "type": { "$ref": "#/components/schemas/PhoneNumberValidationType" }, "async": { "type": "boolean", "default": false, "description": "Indicates whether the request should be executed asynchronously. If `true`, the response will include a `request_uuid` that can be used to poll for results. If `false` (default), the response will include validation results directly.", "example": true }, "force": { "type": "boolean", "default": false, "description": "Indicates whether to force a fresh validation instead of returning a previously cached result. Defaults to `false`.", "example": true } } }, "PhoneValidationResultResponse": { "title": "PhoneValidationResultResponse", "required": [ "phone_number", "valid", "country_code", "e164_format", "national_format", "charge", "error_code" ], "type": "object", "additionalProperties": false, "properties": { "phone_number": { "type": "string", "description": "Phone number.", "example": "971569483322" }, "valid": { "type": "boolean", "description": "Indicates whether the phone number is valid.", "example": true }, "country_code": { "type": [ "string", "null" ], "description": "Phone number country code in ISO 3166-1 alpha-2 format. `null` if the number is invalid.", "example": "AE" }, "e164_format": { "type": "string", "description": "Phone number in international E.164 format.", "example": "+971569483322" }, "national_format": { "type": "string", "description": "Phone number in the national format of the identified country.", "example": "056 948 3322" }, "ported": { "type": [ "boolean", "null" ], "description": "Indicates whether the phone number is ported. `null` if the phone number is invalid.", "example": false }, "mcc": { "type": [ "string", "null" ], "description": "Mobile Country Code (MCC). Applies to mobile numbers only. `null` if the phone number is invalid.", "example": "424" }, "mnc": { "type": [ "string", "null" ], "description": "Mobile Network Code (MNC). Applies to mobile numbers only. `null` if the phone number is invalid.", "example": "004" }, "number_type": { "type": [ "string", "null" ], "description": "Phone number type. Allowed values: `mobile`, `landline`, `toll-free`. `null` if the phone number is invalid.", "example": "mobile" }, "carrier_name": { "type": [ "string", "null" ], "description": "Carrier name. `null` if the phone number is invalid.", "example": "Etisalat" }, "risky_destination": { "type": [ "boolean", "null" ], "description": "Indicates whether the phone number belongs to a range associated with traffic pumping. `null` if the phone number is invalid.", "example": false }, "unallocated_range": { "type": [ "boolean", "null" ], "description": "Indicates whether the phone number belongs to an unallocated range.\n `null` if the phone number is invalid.", "example": false }, "reachable": { "type": [ "boolean", "null" ], "description": "Indicates whether the number is registered in a mobile network. Applies to mobile numbers only. `null` if the phone number is invalid.", "example": true }, "roaming": { "type": [ "boolean", "null" ], "description": "Indicates whether the number is roaming. Applies to mobile numbers only.\n `null` if the phone number is invalid.", "example": false }, "timezone": { "type": [ "string", "null" ], "description": "Time zone identified based on the country and area code. `null` if the phone number is invalid.", "example": "UTC+04:00" }, "charge": { "type": "string", "description": "Charge for the validation.", "example": "0.015" }, "error_code": { "type": "string", "description": "Result code for the validation. `000` indicates success. Possible values:\n- `013` — internal service error, uncategorized.\n- `021` — invalid phone number length or format.\n- `041` — remote timeout.\n- `042` — remote query failed.\n- `091` — insufficient funds.", "example": "000" } }, "description": "Number validator response details." }, "PhoneValidationBatchResponse": { "title": "PhoneValidationBatchResponse", "required": [ "count", "items", "status", "pending" ], "type": "object", "additionalProperties": false, "properties": { "status": { "type": "string", "description": "Validation request status.", "example": "success" }, "pending": { "type": "integer", "description": "Number of validations still in progress.", "example": 0 }, "count": { "type": "integer", "format": "int32", "description": "Total number of phone numbers in the request.", "example": 1000 }, "items": { "type": "array", "items": { "$ref": "#/components/schemas/PhoneValidationResultResponse" }, "description": "List of validation results for each phone number." } } }, "NumberValidatorCreateBulkResponse": { "anyOf": [ { "$ref": "#/components/schemas/PhoneValidationBatchResponse" }, { "type": "object", "title": "Async Request", "description": "Returned when validation runs asynchronously; poll results using `request_id`.", "properties": { "request_id": { "type": "string", "description": "Request ID. Use to poll validation results when `async` is `true`.", "example": "15323ba4-80c1-41be-b8e7-07bb435c7445" } } } ] }, "PhoneValidationBatchResultResponse": { "title": "PhoneValidationBatchResultResponse", "required": [ "status", "pending", "count", "items" ], "type": "object", "additionalProperties": false, "properties": { "status": { "type": "string", "description": "Request status. Possible values are `success` and `in progress`.\n\n- `success`: All numbers were processed. - `in progress`: Several numbers are pending validation.", "example": "success" }, "pending": { "type": "integer", "description": "The quantity of phone numbers that are pending to be processed.", "format": "int32", "example": 10 }, "count": { "type": "integer", "description": "The quantity of phone numbers passed in the request.", "format": "int32", "example": 1000 }, "items": { "type": "array", "items": { "$ref": "#/components/schemas/PhoneValidationResultResponse" }, "description": "Array of objects containing details for each phone number.\n The returned fields depend on the `type` parameter.", "example": [ { "phone_number": "971501390098", "valid": true, "country_code": "AE", "e164_format": "+971501390098", "national_format": "050 139 0098", "ported": false, "mcc": "424", "mnc": "02", "number_type": "mobile", "carrier_name": "Etisalat", "risky_destination": false, "unallocated_range": false, "reachable": true, "roaming": false, "timezone": "UTC+04:00", "charge": "0.015", "error_code": "000" }, { "phone_number": "971504359195", "valid": true, "country_code": "AE", "e164_format": "+971504359195", "national_format": "050 435 9195", "ported": false, "mcc": "424", "mnc": "02", "number_type": "mobile", "carrier_name": "Etisalat", "risky_destination": false, "unallocated_range": false, "reachable": true, "roaming": false, "timezone": "UTC+04:00", "charge": "0.015", "error_code": "000" } ] } } }, "VoiceCampaignResponse": { "title": "VoiceCampaignResponse", "description": "Represents a voice campaign that places an outbound call running a pre-approved call flow.", "required": [ "callflow_id", "caller_id", "contact" ], "type": "object", "additionalProperties": false, "properties": { "callflow_id": { "type": "integer", "description": "Unique identifier of the call flow to launch, listed on the Call flows page. Every scenario must be pre-approved by the Wavix Service Operations team before it can be used in production.", "format": "int32", "example": 3212 }, "caller_id": { "type": "string", "description": "Phone number on the account used as the Caller ID for the outbound call, in E.164 format.", "example": "13123310912" }, "contact": { "type": "string", "description": "Destination phone number the outbound call is placed to, in E.164 format.", "example": "16729923812" }, "callback_url": { "type": "string", "description": "Webhook URL that receives voice campaign status updates.", "example": "https://you-site.com/webhook" } } }, "VoiceCampaignCreateRequest": { "title": "VoiceCampaignCreateRequest", "required": [ "voice_campaign" ], "type": "object", "additionalProperties": false, "properties": { "voice_campaign": { "$ref": "#/components/schemas/VoiceCampaignResponse" } } }, "VoiceCampaignsCreateResponse": { "type": "object", "additionalProperties": false, "properties": { "voice_campaign": { "type": "object", "additionalProperties": false, "properties": { "id": { "type": "integer", "description": "Unique identifier of the voice campaign.", "example": 2321423 }, "status": { "type": "string", "description": "Current status of the voice campaign, such as `in_progress`.", "example": "in_progress" }, "timestamp": { "type": "string", "format": "date-time", "description": "Timestamp when the voice campaign was created, in ISO 8601 format.", "example": "2023-08-03T09:04:12.000Z" }, "caller_id": { "type": "string", "description": "Phone number used as the Caller ID for the outbound call, in E.164 format.", "example": "13123310912" }, "contact": { "type": "string", "description": "Destination phone number the outbound call is placed to, in E.164 format.", "example": "16729923812" } } } } }, "VoiceCampaignsGetResponse": { "type": "object", "additionalProperties": false, "properties": { "voice_campaign": { "type": "object", "additionalProperties": false, "properties": { "id": { "type": "integer", "description": "Unique identifier of the voice campaign.", "example": 2321423 }, "status": { "type": "string", "description": "Current status of the voice campaign, such as `in_progress`.", "example": "in_progress" }, "timestamp": { "type": "string", "format": "date-time", "description": "Timestamp when the voice campaign was created, in ISO 8601 format.", "example": "2023-08-03T09:04:12.000Z" }, "caller_id": { "type": "string", "description": "Phone number used as the Caller ID for the outbound call, in E.164 format.", "example": "13123310912" }, "contact": { "type": "string", "description": "Destination phone number the outbound call is placed to, in E.164 format.", "example": "16729923812" } } } } }, "ShortLinkCreateRequest": { "title": "ShortLinkCreateRequest", "required": [ "link" ], "type": "object", "additionalProperties": false, "properties": { "link": { "type": "string", "format": "uri", "pattern": "^https://", "description": "Target URL to shorten. Must be `https://` — the short link is publicly resolvable and redirects any visitor here, so only pass URLs you trust; this endpoint is a common target for open-redirect and phishing abuse.", "example": "https://your-site.com/long-url" }, "expiration_time": { "type": "string", "format": "date-time", "description": "Expiration date and time in ISO 8601 format.", "example": "2023-07-19T18:18:34.235Z" }, "fallback_url": { "type": "string", "format": "uri", "pattern": "^https://", "description": "Fallback URL for expired or invalid links. Must be `https://` — same open-redirect/phishing considerations as `link` apply.", "example": "https://examples.com/fallback" }, "phone": { "type": "string", "description": "Phone number the short link is associated with, in E.164 format (without the leading `+`). Used to attribute click metrics returned by short link metrics list.", "example": "15155982927" }, "utm_campaign": { "type": "string", "description": "UTM campaign name for tracking insights.", "example": "summer_promo" } } }, "ShortLinkResponse": { "title": "ShortLinkResponse", "required": [ "short_link" ], "type": "object", "additionalProperties": false, "properties": { "short_link": { "type": "string", "description": "Generated short URL.", "example": "https://wx.com/hd82Jhs21" } } }, "ShortLinkMetricsItem": { "title": "ShortLinkMetricsItem", "required": [ "latitude", "longitude", "operating_system", "browser", "language", "phone", "utm_campaign", "created_at", "user_id", "link_hash" ], "type": "object", "additionalProperties": false, "properties": { "latitude": { "type": [ "number", "null" ], "description": "Latitude of the location derived from the IP address\n used to open the short link.", "example": 59.3247 }, "longitude": { "type": [ "number", "null" ], "description": "Longitude of the location derived from the IP address\n used to open the short link.", "example": 18.056 }, "operating_system": { "type": [ "string", "null" ], "description": "Operating system of the device that opened the short link.", "example": "Mac OS X 10.15" }, "browser": { "type": [ "string", "null" ], "description": "Browser used to open the short link.", "example": "Firefox" }, "language": { "type": [ "string", "null" ], "description": "Browser language preference.", "example": "English" }, "phone": { "type": [ "string", "null" ], "description": "Phone number associated with the short link.", "example": "12762025555" }, "utm_campaign": { "type": [ "string", "null" ], "description": "UTM campaign name associated with the short link.", "example": "summer" }, "created_at": { "type": "string", "description": "Date and time when short link was opened.", "example": "2023-07-19 18:23:42" }, "link_hash": { "type": "string", "description": "Hash of the short link.", "example": "hd82Jhs21" }, "user_id": { "type": "integer", "description": "Account ID.", "example": 100017 } } }, "ShortLinkMetricsResponse": { "title": "ShortLinkMetricsResponse", "required": [ "metrics", "pagination" ], "type": "object", "additionalProperties": false, "properties": { "metrics": { "type": "array", "items": { "$ref": "#/components/schemas/ShortLinkMetricsItem" }, "description": "List of short link metrics matching search criteria." }, "pagination": { "$ref": "#/components/schemas/Pagination" } } }, "TwoFactorVerificationCreateRequest": { "title": "TwoFactorVerificationCreateRequest", "required": [ "service_id", "to", "channel" ], "type": "object", "additionalProperties": false, "properties": { "service_id": { "type": "string", "description": "Unique Wavix 2FA Service ID. Available on the Wavix portal.", "example": "7204a030201211ee9fb47d093f2f127c" }, "to": { "type": "string", "description": "End user's phone number to which the verification code will be sent. The phone number must be in E.164 format.", "example": "447919433768" }, "channel": { "type": "string", "description": "Channel used to deliver the verification code. One of `sms` (sent as a text message) or `voice` (read aloud over a phone call).", "example": "sms" } } }, "PhoneLookupDetails": { "title": "PhoneLookupDetails", "required": [ "number_type", "country", "current_carrier" ], "type": "object", "additionalProperties": false, "properties": { "number_type": { "type": "string", "description": "The destination phone number type", "example": "mobile" }, "country": { "type": "string", "description": "The destination phone number's 2-letter ISO country code", "example": "GB" }, "current_carrier": { "type": "string", "description": "The carrier name the phone number currently belongs to", "example": "Vodafone" } } }, "TwoFactorVerificationResponse": { "title": "TwoFactorVerificationResponse", "required": [ "success", "service_id", "session_url", "session_id", "destination", "created_at", "number_lookup" ], "type": "object", "additionalProperties": false, "properties": { "success": { "type": "boolean", "description": "Indicates whether the 2FA Verification was successfully created", "example": true }, "service_id": { "type": "string", "description": "Unique identifier of the Wavix 2FA Service", "example": "7204a030201211ee9fb47d093f2f127c" }, "session_url": { "type": "string", "description": "Automatically generated 2FA Verification URL. The URL can be used to resend or validate the OTP.", "example": "https://api.wavix.com/v1/two-fa/verification/2953d4308f2e11ecb75fcdafd6d2d687" }, "session_id": { "type": "string", "description": "Unique identifier of the Wavix 2FA Verification", "example": "2953d4308f2e11ecb75fcdafd6d2d687" }, "destination": { "type": "string", "description": "The end user's phone number.", "example": "447919433768" }, "created_at": { "type": "string", "description": "Date and time the 2FA Verification is created", "format": "date-time", "example": "2022-02-16T13:41:38.000Z" }, "number_lookup": { "$ref": "#/components/schemas/PhoneLookupDetails" } } }, "ListSessionsResponseItem": { "type": "object", "additionalProperties": false, "properties": { "created_at": { "type": "string", "format": "date-time", "description": "Date and time the 2FA Verification was created in ISO 8601 format.", "example": "2022-02-16T13:41:38.000Z" }, "session_id": { "type": "string", "description": "2FA Verification ID.", "example": "2953d4308f2e11ecb75fcdafd6d2d687" }, "phone_number": { "type": "string", "description": "Destination phone number.", "example": "447919433768" }, "destination_country": { "type": "string", "description": "Country code of the destination phone number in ISO 3166-1 alpha-2 format.", "example": "GB" }, "status": { "type": "string", "description": "Status of the 2FA Verification.", "example": "verified" }, "charge": { "type": "string", "description": "Charge for the 2FA Verification.", "example": "0.01" }, "service_id": { "type": "string", "description": "2FA Service ID.", "example": "7204a030201211ee9fb47d093f2f127c" }, "service_name": { "type": "string", "description": "2FA Service name.", "example": "Wavix 2FA Service" } } }, "TwoFactorVerificationResendRequest": { "title": "TwoFactorVerificationResendRequest", "required": [ "channel" ], "type": "object", "additionalProperties": false, "properties": { "channel": { "type": "string", "description": "Channel used to resend the verification code. One of `sms` (sent as a text message) or `voice` (read aloud over a phone call).", "enum": [ "sms", "voice" ], "example": "voice" } } }, "TwoFactorVerificationResendResponse": { "title": "TwoFactorVerificationResendResponse", "required": [ "success", "channel", "destination", "created_at" ], "type": "object", "properties": { "success": { "type": "boolean", "description": "Indicates whether the verification code was successfully sent", "example": true }, "channel": { "type": "string", "description": "Indicates whether the code was sent via an SMS or a voice call", "example": "voice" }, "destination": { "type": "string", "description": "The destination phone number the code was sent to", "example": "447919433768" }, "created_at": { "type": "string", "description": "Date and time the code was sent", "format": "date-time", "example": "2022-02-16T13:41:38.000Z" } } }, "TwoFactorVerificationCheckRequest": { "title": "TwoFactorVerificationCheckRequest", "required": [ "code" ], "type": "object", "additionalProperties": false, "properties": { "code": { "type": "string", "description": "The code entered by an end user", "example": "123456" } } }, "TwoFactorVerificationCheckResponse": { "title": "TwoFactorVerificationCheckResponse", "required": [ "is_valid" ], "type": "object", "additionalProperties": false, "properties": { "is_valid": { "type": "boolean", "description": "Indicates whether the entered code is valid", "example": true } } }, "TwoFactorVerificationEvent": { "title": "TwoFactorVerificationEvent", "required": [ "created_at", "event", "status", "charge", "error" ], "type": "object", "additionalProperties": false, "properties": { "created_at": { "type": "string", "description": "Date and time of the event", "format": "date-time", "example": "2022-02-16T13:41:38.000Z" }, "event": { "type": "string", "description": "Human-readable event description. One of the following values:\n- `Number lookup` — the Wavix platform checked whether the destination phone number is valid. Returned only when number validation is enabled for the 2FA Service.\n- `Code sent via SMS` — a code was sent via SMS.\n- `Code sent via voice` — a code was sent via a voice call.\n- `Verification` — a code verification attempt.", "example": "Code sent via SMS" }, "status": { "type": "string", "description": "Status of an action associated with the event. Can be either `success`, `failed`, or `pending`.", "example": "success" }, "charge": { "type": "string", "description": "Cost of an operation associated with the event, in USD", "example": "0.005" }, "error": { "type": [ "string", "null" ], "description": "Error description, if any" } } }, "TransactionType": { "title": "TransactionType", "enum": [ 0, 2, 3, 6, 11, 14, 15, 19, 20, 23, 24, 25, 26, 29, 30, 31, 32, 33, 34, 35, 36, 37, 38, 39, 40, 41, 42, 43, 44, 45, 46, 47, 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 66 ], "x-enum-varnames": [ "PAYMENT_ADJUSTMENT", "PHONE_NUMBER_ACTIVATION_FEE", "PHONE_NUMBER_MONTHLY_FEES", "PHONE_NUMBER_FORWARDING", "PSTN_FORWARDING_FEE", "OUTBOUND_CALL", "OUTBOUND_SMS", "CREDIT_CARD_PAYMENT", "PAYMENT_FEE", "PORTING_FEE", "INBOUND_SMS", "ADMIN_PAYMENT", "SUBSCRIPTION_PAYMENT", "NUMBER_VALIDATOR", "CALL_RECORDING", "STORAGE_CHARGE", "CAMPAIGN_BUILDER", "VOICEMAIL_DETECTION", "SENDER_ID_REGISTRATION", "SENDER_ID_MONTHLY_FEE", "TWO_FA", "IVR", "E911_ACTIVATION", "OUTBOUND_MMS", "INBOUND_MMS", "CALL_TRANSCRIPTION", "TEN_DLC_BRAND_REGISTRATION", "TEN_DLC_CAMPAIGN_REGISTRATION", "PHONE_NUMBER_ORDER", "ADJUSTMENT_IN", "URL_SHORTENER", "TEN_DLC_BRAND_UPDATE", "TEN_DLC_BRAND_APPEAL", "AUDIO_TRANSCRIPTION", "TEN_DLC_BRAND_VETTING", "TEN_DLC_BRAND_VETTING_APPEAL", "OUTBOUND_SMS_CARRIER_FEE", "INBOUND_SMS_CARRIER_FEE", "OUTBOUND_MMS_CARRIER_FEE", "INBOUND_MMS_CARRIER_FEE", "TEN_DLC_CAMPAIGN_VETTING_FEE", "OUTBOUND_SMS_SEGMENT", "INBOUND_SMS_SEGMENT", "OUTBOUND_MMS_SEGMENT", "INBOUND_MMS_SEGMENT", "WHATSAPP_MESSAGE" ], "type": "integer", "description": "Transaction type:\n * 0 - Payment adjustment\n * 2 - Phone number activation fee\n * 3 - Phone number monthly fees\n * 6 - Phone number forwarding\n * 11 - PSTN forwarding fee\n * 14 - Outbound call\n * 15 - Outbound SMS\n * 19 - Credit card payment\n * 20 - Payment fee\n * 23 - Porting fee\n * 24 - Inbound SMS\n * 25 - Admin payment\n * 26 - Subscription payment\n * 29 - Number validator\n * 30 - Call recording\n * 31 - Storage charge\n * 32 - Campaign builder\n * 33 - Voicemail detection\n * 34 - Sender ID registration\n * 35 - Sender ID monthly fee\n * 36 - 2FA\n * 37 - IVR\n * 38 - E911 activation\n * 39 - Outbound MMS\n * 40 - Inbound MMS\n * 41 - Call transcription\n * 42 - 10DLC Brand registration\n * 43 - 10DLC Campaign registration\n * 44 - Phone number order\n * 45 - Adjustment in\n * 46 - URL shortener\n * 47 - 10DLC Brand update\n * 48 - 10DLC Brand appeal\n * 49 - Audio transcription\n * 50 - 10DLC Brand vetting\n * 51 - 10DLC Brand vetting appeal\n * 52 - Outbound SMS carrier fee\n * 53 - Inbound SMS carrier fee\n * 54 - Outbound MMS carrier fee\n * 55 - Inbound MMS carrier fee\n * 56 - 10DLC Campaign vetting fee\n * 57 - Outbound SMS segment\n * 58 - Inbound SMS segment\n * 59 - Outbound MMS segment\n * 60 - Inbound MMS segment\n * 66 - WhatsApp message" }, "TransactionStatus": { "title": "TransactionStatus", "enum": [ "Created", "Pending", "Committed", "Reverted" ], "type": "string", "description": "Current status of the transaction. One of `Created` (the transaction was created but not yet processed), `Pending` (the transaction is being processed), `Committed` (the transaction was applied to the balance), or `Reverted` (the transaction was rolled back)." }, "FinancialTransaction": { "title": "FinancialTransaction", "required": [ "id", "date", "amount", "balance_after", "details", "status", "type", "show_invoice" ], "type": "object", "additionalProperties": false, "properties": { "id": { "type": "integer", "description": "Transaction ID.", "format": "int64", "example": 24789389 }, "date": { "type": "string", "description": "Creation date and time in ISO 8601 format.", "format": "date-time", "example": "2023-08-29T14:48:38.000Z" }, "amount": { "type": "number", "format": "float", "description": "Transaction amount. Negative values decrease balance.", "example": -0.99 }, "balance_after": { "type": "number", "format": "float", "description": "Account balance after the transaction.", "example": 309.0601 }, "details": { "type": "string", "description": "Transaction details.", "example": "Monthly fee for 16419252149" }, "status": { "$ref": "#/components/schemas/TransactionStatus" }, "type": { "$ref": "#/components/schemas/TransactionType" }, "show_invoice": { "type": "boolean", "description": "Indicates whether a transaction receipt is available. Receipts\n are available only for transaction types 0, 8, 9, 19, 23, and 25.", "example": false } }, "description": "Financial transaction.", "example": { "id": 24789389, "date": "2023-08-29T14:48:38.000Z", "amount": -0.99, "balance_after": 309.0601, "details": "Monthly fee for 16419252149", "status": "Committed", "type": 3, "show_invoice": false } }, "BillingTransactionListResponse": { "title": "BillingTransactionListResponse", "required": [ "is_empty", "transactions", "pagination" ], "type": "object", "additionalProperties": false, "properties": { "is_empty": { "type": "boolean", "description": "Indicates whether there are no transactions.", "example": false }, "transactions": { "type": "array", "items": { "$ref": "#/components/schemas/FinancialTransaction" }, "description": "List of transactions.", "example": [ { "id": 24789389, "amount": -0.99, "balance_after": 309.0601, "date": "2023-08-29T14:48:38.000Z", "details": "Monthly fee for 16419252149", "status": "Committed", "type": 3, "show_invoice": false } ] }, "pagination": { "$ref": "#/components/schemas/Pagination" } } }, "Invoice": { "title": "Invoice", "required": [ "id", "amount", "from_date", "to_date" ], "type": "object", "additionalProperties": false, "properties": { "id": { "type": "integer", "description": "Unique identifier of the statement", "format": "int32", "example": 43209 }, "amount": { "type": "string", "description": "Statement amount", "example": "7.72" }, "from_date": { "type": "string", "description": "Start of the billing period", "format": "date", "example": "2023-07-01" }, "to_date": { "type": "string", "description": "End of the billing period", "format": "date", "example": "2023-07-31" } }, "description": "An account financial statement" }, "InvoiceListResponse": { "title": "InvoiceListResponse", "required": [ "is_empty", "invoices", "pagination" ], "type": "object", "additionalProperties": false, "properties": { "is_empty": { "type": "boolean", "description": "Indicates whether the statement list is empty.", "example": false }, "invoices": { "type": "array", "description": "Auto-generated statements for the account.", "items": { "$ref": "#/components/schemas/Invoice" } }, "pagination": { "$ref": "#/components/schemas/Pagination" } } }, "ProfileResponse": { "title": "ProfileResponse", "required": [ "id", "email", "first_name", "last_name", "phone", "additional_info", "contact_email", "timezone", "job_title", "default_short_link_endpoint", "default_destinations", "company_info" ], "type": "object", "additionalProperties": false, "properties": { "id": { "type": "integer", "description": "Account ID.", "format": "int32", "example": 1 }, "email": { "type": "string", "description": "Email associated with the account.", "example": "info@awesome.com" }, "first_name": { "type": [ "string", "null" ], "description": "Account owner's first name.", "example": "Jason" }, "last_name": { "type": [ "string", "null" ], "description": "Account owner's last name.", "example": "Androux" }, "phone": { "type": [ "string", "null" ], "description": "Account owner's phone number.", "example": "13291019312" }, "additional_info": { "type": [ "string", "null" ], "description": "Additional info associated with the account.", "example": "Additional info" }, "contact_email": { "type": [ "string", "null" ], "description": "Additional email address for billing notifications.", "example": "billing@awesome.com" }, "timezone": { "type": "string", "description": "Timezone configured on the account.", "example": "Pacific/Wallis" }, "job_title": { "type": [ "string", "null" ], "description": "Account owner's job title.", "example": "Manager" }, "default_short_link_endpoint": { "type": [ "string", "null" ], "description": "Default short link endpoint.", "example": "https://short.examples.com" }, "default_destinations": { "type": "array", "items": { "type": "object", "additionalProperties": false, "properties": { "transport": { "type": "string", "description": "Transport type.", "example": "sms" }, "value": { "type": "string", "description": "Destination value", "example": "https://webhook.address.com/inboundSMS" } } }, "description": "Default destinations configured for the account.", "example": [ { "transport": "sms", "value": "https://webhook.address.com/inboundSMS" } ] }, "company_info": { "type": [ "object", "null" ], "additionalProperties": false, "description": "Company details.", "properties": { "name": { "type": [ "string", "null" ], "description": "Company name.", "example": "Awesome company" }, "industry": { "type": [ "string", "null" ], "enum": [ "telecommunications", "information technology and services", "fintech and finance", "healthcare and pharmaceuticals", "ecommerce and retail", "education and research", "pickup and delivery", "transportation and logistics", "media and entertainment", "travel and hospitality", "non-profit and charity organizations", "manufacturing and industrial goods", "other", null ], "description": "Industry the company operates in. One of `telecommunications`, `information technology and services`, `fintech and finance`, `healthcare and pharmaceuticals`, `ecommerce and retail`, `education and research`, `pickup and delivery`, `transportation and logistics`, `media and entertainment`, `travel and hospitality`, `non-profit and charity organizations`, `manufacturing and industrial goods`, or `other`. Each value names the company's sector. `null` when the industry is not set.", "example": "telecommunications" }, "address": { "type": [ "string", "null" ], "description": "Company address.", "example": "Baker street" }, "attn_contact_name": { "type": [ "string", "null" ], "description": "Billing contact name.", "example": "James Scott" }, "vat_number": { "type": [ "string", "null" ], "description": "VAT number.", "example": "VAT123456789" }, "country": { "type": "object", "additionalProperties": false, "description": "Country.", "properties": { "country_name": { "type": [ "string", "null" ], "description": "Country name.", "example": "United States" }, "country_id": { "type": [ "integer", "null" ], "description": "Country ID.", "example": 1 } } } } } } }, "ProfileUpdateRequest": { "title": "ProfileUpdateRequest", "type": "object", "additionalProperties": false, "properties": { "additional_info": { "type": "string", "description": "Additional information associated with the account." }, "contacts": { "type": "string", "description": "Email associated with the account." }, "default_short_link_endpoint": { "type": "string", "description": "Default short link endpoint." }, "first_name": { "type": "string", "description": "Account owner's first name." }, "last_name": { "type": "string", "description": "Account owner's last name." }, "phone": { "type": "string", "description": "Account owner's phone number" }, "sms_relay_url": { "type": "string", "description": "Callback URL to forward inbound SMS to." }, "dlr_relay_url": { "type": "string", "description": "Callback URL to forward message delivery reports (DLRs) to." }, "time_zone": { "type": "string", "description": "Timezone configured on the account.", "example": "UTC" }, "job_title": { "type": "string", "description": "Account owner's job title." }, "company_info": { "type": "object", "additionalProperties": false, "properties": { "name": { "type": "string", "description": "Company name." }, "industry": { "type": "string", "enum": [ "telecommunications", "information technology and services", "fintech and finance", "healthcare and pharmaceuticals", "ecommerce and retail", "education and research", "pickup and delivery", "transportation and logistics", "media and entertainment", "travel and hospitality", "non-profit and charity organizations", "manufacturing and industrial goods", "other" ], "description": "Industry the company operates in. One of `telecommunications`, `information technology and services`, `fintech and finance`, `healthcare and pharmaceuticals`, `ecommerce and retail`, `education and research`, `pickup and delivery`, `transportation and logistics`, `media and entertainment`, `travel and hospitality`, `non-profit and charity organizations`, `manufacturing and industrial goods`, or `other`. Each value names the company's sector.", "example": "telecommunications" }, "billing_address": { "type": "string", "description": "Billing address." }, "attn_contact_name": { "type": "string", "description": "Billing contact name." }, "vat_number": { "type": "string", "description": "VAT number." }, "country_code": { "type": "string", "description": "Country code." } } } } }, "AccountLimits": { "title": "AccountLimits", "required": [ "max_call_duration", "max_sip_channels", "max_call_rate" ], "type": "object", "additionalProperties": false, "properties": { "max_call_duration": { "type": "integer", "description": "Maximum outbound call duration, in seconds", "format": "int32", "example": 3600 }, "max_sip_channels": { "type": "integer", "description": "Maximum number of concurrent outbound calls.", "format": "int32", "example": 2 }, "max_call_rate": { "type": "string", "description": "Maximum outbound call rate, in cents", "example": "0.18" } } }, "ProfileConfigResponse": { "title": "ProfileConfigResponse", "required": [ "balance", "global_limits" ], "type": "object", "additionalProperties": false, "properties": { "balance": { "type": "string", "description": "Funds available on the account balance, in USD", "example": "100" }, "global_limits": { "$ref": "#/components/schemas/AccountLimits" } } }, "SubOrganizationResponse": { "title": "SubOrganizationResponse", "required": [ "id", "created_at", "name", "api_key", "master_organization", "status", "default_destinations" ], "type": "object", "description": "Sub-account details including API key and webhook configurations.", "additionalProperties": false, "properties": { "id": { "type": "integer", "format": "int32", "description": "Sub-account ID.", "example": 123 }, "created_at": { "type": "string", "format": "date-time", "description": "Date and time the sub-account was created in ISO 8601 format.", "example": "2023-06-15T10:30:00Z" }, "name": { "type": "string", "description": "Sub-account name.", "example": "My sub-account" }, "api_key": { "type": "string", "description": "Sub-account API key.", "example": "abc123def456" }, "master_organization": { "type": "integer", "format": "int32", "description": "Master account ID.", "example": 456 }, "status": { "type": "string", "description": "Status of the subaccount. One of `enabled` (the subaccount is active and can be used) or `disabled` (the subaccount is suspended).", "enum": [ "enabled", "disabled" ], "example": "enabled" }, "default_destinations": { "type": "object", "additionalProperties": false, "description": "Default webhook URLs for inbound messages and delivery reports.", "required": [ "sms_endpoint", "dlr_endpoint" ], "properties": { "sms_endpoint": { "type": "string", "format": "uri", "description": "Inbound messages webhook URL.", "example": "https://examples.com/sms" }, "dlr_endpoint": { "type": "string", "format": "uri", "description": "Delivery report webhook URL.", "example": "https://examples.com/dlr" } } } }, "example": { "id": 123, "created_at": "2023-06-15T10:30:00Z", "name": "My sub-account", "api_key": "abc123def456", "master_organization": 456, "status": "enabled", "default_destinations": { "sms_endpoint": "https://examples.com/sms", "dlr_endpoint": "https://examples.com/dlr" } } }, "SubAccountsListResponse": { "type": "object", "additionalProperties": false, "properties": { "sub_organizations": { "type": "array", "description": "Subaccounts belonging to the authenticated account.", "items": { "$ref": "#/components/schemas/SubOrganizationResponse" } }, "pagination": { "$ref": "#/components/schemas/Pagination" } } }, "SubAccountsCreateRequest": { "type": "object", "additionalProperties": false, "required": [ "name" ], "properties": { "name": { "type": "string", "description": "Sub-account name.", "maxLength": 75, "example": "Company name" }, "default_destinations": { "type": "object", "additionalProperties": false, "description": "Default webhook URLs for inbound messages and delivery reports.", "properties": { "sms_endpoint": { "type": "string", "format": "uri", "description": "Inbound messages webhook URL.", "example": "https://examples.com/sms" }, "dlr_endpoint": { "type": "string", "format": "uri", "description": "Delivery report webhook URL.", "example": "https://examples.com/dlr" } } } } }, "SubAccountsUpdateRequest": { "type": "object", "additionalProperties": false, "properties": { "name": { "type": "string", "description": "Sub-account name.", "maxLength": 75, "example": "Updated Company Name" }, "status": { "type": "string", "description": "Status of the subaccount. One of `enabled` (the subaccount is active and can be used) or `disabled` (the subaccount is suspended).", "enum": [ "enabled", "disabled" ], "example": "enabled" }, "default_destinations": { "type": "object", "additionalProperties": false, "description": "Default webhook URLs for inbound messages and delivery reports.", "properties": { "sms_endpoint": { "type": "string", "format": "uri", "description": "Inbound messages webhook URL.", "example": "https://examples.com/sms" }, "dlr_endpoint": { "type": "string", "format": "uri", "description": "Delivery report webhook URL.", "example": "https://examples.com/dlr" } } } } }, "SubAccountsTransactionsListResponse": { "type": "object", "additionalProperties": false, "properties": { "transactions": { "type": "array", "description": "Financial transactions for the subaccount.", "items": { "type": "object", "additionalProperties": false, "properties": { "amount": { "type": "number", "format": "float", "description": "Transaction amount.", "example": 10.5 }, "balance_after": { "type": "number", "format": "float", "description": "Sub-account balance after the transaction.", "example": 100 }, "date": { "type": "string", "description": "Transaction date and time in ISO 8601 format.", "format": "date-time", "example": "2023-06-15T10:30:00Z" }, "details": { "type": "string", "description": "Transaction details.", "example": "Account top-up" }, "status": { "type": "string", "description": "Transaction status.", "example": "committed" }, "type": { "type": "integer", "description": "Transaction type.", "example": 1 } } } }, "pagination": { "$ref": "#/components/schemas/Pagination" } } }, "WhatsAppBusinessAccount": { "title": "WhatsAppBusinessAccount", "description": "A WhatsApp Business Account linked to your account. Returned by `whatsapp_wabas_list` and `whatsapp_wabas_get`.", "required": [ "id", "name", "sender_count" ], "type": "object", "additionalProperties": false, "properties": { "id": { "type": "string", "description": "ID of the WhatsApp Business Account, as returned in `waba.id` on senders and templates.", "example": "102290129340398" }, "name": { "type": [ "string", "null" ], "description": "Name of the WhatsApp Business Account.", "example": "Acme Support" }, "messaging_limit": { "type": "string", "description": "Maximum number of unique customers the WhatsApp Business Account can start conversations with in a rolling 24-hour period. Omitted when the limit isn't known yet. Possible values:\n\n- `up_to_250` — Up to 250 unique customers.\n- `up_to_2k` — Up to 2,000 unique customers.\n- `up_to_10k` — Up to 10,000 unique customers.\n- `up_to_100k` — Up to 100,000 unique customers.\n- `unlimited` — No limit on unique customers.", "enum": [ "up_to_250", "up_to_2k", "up_to_10k", "up_to_100k", "unlimited" ], "example": "up_to_2k" }, "sender_count": { "type": "integer", "description": "Number of senders registered in the WhatsApp Business Account.", "example": 2 } } }, "WhatsAppWabaListResponse": { "title": "WhatsAppWabaListResponse", "description": "Returned by `whatsapp_wabas_list`.", "required": [ "wabas", "pagination" ], "type": "object", "additionalProperties": false, "properties": { "wabas": { "type": "array", "description": "WhatsApp Business Accounts linked to your account.", "items": { "$ref": "#/components/schemas/WhatsAppBusinessAccount" } }, "pagination": { "$ref": "#/components/schemas/Pagination" } } }, "WhatsAppProblem": { "title": "WhatsAppProblem", "description": "An RFC 9457 problem document that describes an error from the WhatsApp API. Returned with the `application/problem+json` content type.", "required": [ "type", "title", "status", "detail", "instance" ], "type": "object", "additionalProperties": false, "properties": { "type": { "type": "string", "description": "URI that identifies the problem type.", "example": "https://docs.wavix.com/errors/whatsapp-not-available" }, "title": { "type": "string", "description": "Short, human-readable summary of the problem type.", "example": "WhatsApp Not Available" }, "status": { "type": "integer", "format": "int32", "description": "HTTP status code of the response.", "example": 404 }, "detail": { "type": "string", "description": "Human-readable explanation of this occurrence of the problem.", "example": "WhatsApp is not available for this account." }, "instance": { "type": "string", "description": "Request ID of this occurrence of the problem.", "example": "3a525ca2-6909-4c72-9399-905adf7f3a74" }, "error_class": { "type": "string", "description": "Machine-readable classification of the error. Possible values:\n\n- `permanent` — The request can't succeed as sent. Retrying doesn't help.\n- `retriable` — The failure is temporary. Retrying can succeed.\n- `rate_limited` — The request was rate limited. Retry later.\n- `invalid_template` — The template content is invalid.", "enum": [ "permanent", "retriable", "rate_limited", "invalid_template" ], "example": "permanent" }, "error_code": { "type": "string", "description": "Stable machine-readable error code. It's the problem type slug in upper case, with underscores in place of hyphens.", "example": "WHATSAPP_NOT_AVAILABLE" }, "service_window_closed_at": { "type": [ "string", "null" ], "format": "date-time", "description": "Time the 24-hour service window of the recipient closed. Returned with `service-window-closed`. It's `null` when the recipient never wrote to the sender or the last message is older than the retained history.", "example": "2026-01-14T09:15:00.000Z" } } }, "WhatsAppWaba": { "title": "WhatsAppWaba", "description": "A WhatsApp Business Account linked to your account, embedded in senders and templates.", "required": [ "id", "name" ], "type": "object", "additionalProperties": false, "properties": { "id": { "type": "string", "description": "ID of the WhatsApp Business Account. Pass it to `whatsapp_wabas_get` to retrieve the account.", "example": "102290129340398" }, "name": { "type": [ "string", "null" ], "description": "Name of the WhatsApp Business Account.", "example": "Acme Support" } } }, "WhatsAppSender": { "title": "WhatsAppSender", "description": "A WhatsApp sender, which is a phone number registered with WhatsApp in one of your account's WhatsApp Business Accounts. Returned by `whatsapp_senders_list` and `whatsapp_senders_get`.", "required": [ "phone_number", "display_name", "status", "quality_rating", "waba" ], "type": "object", "additionalProperties": false, "properties": { "phone_number": { "type": "string", "description": "Sender's phone number in E.164 format.", "example": "+14155550100" }, "display_name": { "type": [ "string", "null" ], "description": "Sender's WhatsApp display name.", "example": "Acme Support" }, "status": { "type": "string", "description": "Sender registration status with the provider. Possible values:\n\n- `banned` — The provider banned the sender.\n- `connected` — The sender can send messages within its messaging limit.\n- `deleted` — The sender was deleted.\n- `disconnected` — The sender is disconnected from the provider.\n- `flagged` — The sender's quality rating dropped to low. The status returns to `connected` if the rating returns to medium or high within seven days.\n- `migrated` — The sender was migrated.\n- `pending` — Registration with the provider is in progress.\n- `rate_limited` — The provider is rate limiting the sender.\n- `restricted` — The sender reached its messaging limit. It can't start new conversations until the 24-hour window resets, but it can still reply to customers who messaged it.\n- `unknown` — The provider hasn't reported a status.\n- `unverified` — The sender isn't verified.", "enum": [ "banned", "connected", "deleted", "disconnected", "flagged", "migrated", "pending", "rate_limited", "restricted", "unknown", "unverified" ], "example": "connected" }, "quality_rating": { "type": [ "string", "null" ], "description": "Sender's messaging quality rating. Meta rates quality from customer feedback over the past seven days, such as blocks and reports. Possible values:\n\n- `high` — High quality.\n- `medium` — Medium quality.\n- `low` — Low quality.\n- `unknown` — Not rated yet.", "enum": [ "high", "medium", "low", "unknown", null ], "example": "high" }, "waba": { "$ref": "#/components/schemas/WhatsAppWaba" } } }, "WhatsAppSenderListResponse": { "title": "WhatsAppSenderListResponse", "description": "Returned by `whatsapp_senders_list`.", "required": [ "senders", "pagination" ], "type": "object", "additionalProperties": false, "properties": { "senders": { "type": "array", "description": "Senders that match the request.", "items": { "$ref": "#/components/schemas/WhatsAppSender" } }, "pagination": { "$ref": "#/components/schemas/Pagination" } } }, "WhatsAppTemplateResponseComponent": { "title": "WhatsAppTemplateResponseComponent", "description": "A component of a stored WhatsApp template. Returned inside templates by `whatsapp_templates_list`, `whatsapp_templates_get`, and `whatsapp_templates_create`. Section types other than header, body, footer, and buttons can carry fields of their own.", "required": [ "type" ], "type": "object", "additionalProperties": true, "properties": { "type": { "type": "string", "description": "Component type: `header`, `body`, `footer`, `buttons`, or the lower-cased name of another section type carried over from an imported template, such as `carousel` or `limited_time_offer`.", "example": "body" }, "format": { "type": "string", "description": "Header content format. Present on `header` components only. Possible values:\n\n- `text` — Text header.\n- `image` — Image header.\n- `video` — Video header.\n- `document` — Document header.\n- `location` — Location header.", "enum": [ "text", "image", "video", "document", "location" ], "example": "text" }, "text": { "type": "string", "description": "Component text, with `{{n}}` placeholders where applicable.", "example": "Hi {{1}}, your order {{2}} has shipped." }, "example": { "type": "object", "description": "Sample values for the component's placeholders, in the shape the provider expects.", "additionalProperties": true }, "buttons": { "type": "array", "description": "Button definitions. Present on `buttons` components only.", "items": { "type": "object", "additionalProperties": true } } } }, "WhatsAppTemplate": { "title": "WhatsAppTemplate", "description": "A WhatsApp message template with its review status and components. Returned by `whatsapp_templates_list`, `whatsapp_templates_get`, and `whatsapp_templates_create`.", "required": [ "uuid", "name", "language", "category", "status", "quality_rating", "components", "waba", "created_at" ], "type": "object", "additionalProperties": false, "properties": { "uuid": { "type": "string", "format": "uuid", "description": "ID of the template. Pass it to `whatsapp_templates_get` to check the review outcome.", "example": "6b1f3c52-9e0a-4d7b-8a15-c2f4e9d07b38" }, "name": { "type": "string", "description": "Template name.", "example": "order_shipped" }, "language": { "type": "string", "description": "Template language code.", "example": "en_US" }, "category": { "type": "string", "description": "Template category. Possible values:\n\n- `marketing` — Promotions, offers, and other marketing content.\n- `authentication` — One-time passcodes for verifying a user.\n- `utility` — Transactional updates about an order or an account.", "enum": [ "marketing", "authentication", "utility" ], "example": "utility" }, "status": { "type": "string", "description": "Template review status. Possible values:\n\n- `draft` — The template is created but not yet submitted to the provider.\n- `pending` — The provider is reviewing the template.\n- `approved` — The template is approved and can be sent.\n- `rejected` — The provider rejected the template.\n- `paused` — The provider paused the template.\n- `flagged` — The provider flagged the template. It can still be sent.\n- `disabled` — The template is disabled and can't be sent.\n- `in_appeal` — An appeal of the review decision is in progress.\n- `pending_deletion` — The template is being deleted.\n- `deleted` — The template was deleted.\n- `unknown` — The provider reported a status that Wavix doesn't recognize.", "enum": [ "draft", "pending", "approved", "rejected", "paused", "flagged", "disabled", "in_appeal", "pending_deletion", "deleted", "unknown" ], "example": "approved" }, "quality_rating": { "type": [ "string", "null" ], "description": "Template's messaging quality rating. Meta rates quality from customer feedback over the past seven days, such as blocks and reports. Possible values:\n\n- `high` — High quality.\n- `medium` — Medium quality.\n- `low` — Low quality.\n- `unknown` — Not rated yet.", "enum": [ "high", "medium", "low", "unknown", null ], "example": "high" }, "submitted_at": { "type": "string", "format": "date-time", "description": "Date and time the template's state was last updated from WhatsApp, in ISO 8601 format.", "example": "2026-01-15T10:30:00Z" }, "components": { "type": "array", "description": "Structural components of the template.", "items": { "$ref": "#/components/schemas/WhatsAppTemplateResponseComponent" } }, "waba": { "$ref": "#/components/schemas/WhatsAppWaba" }, "created_at": { "type": "string", "format": "date-time", "description": "Date and time the template was created, in ISO 8601 format.", "example": "2026-01-15T10:30:00Z" } } }, "WhatsAppTemplatePageResponse": { "title": "WhatsAppTemplatePageResponse", "description": "Returned by `whatsapp_templates_list`.", "required": [ "templates", "pagination" ], "type": "object", "additionalProperties": false, "properties": { "templates": { "type": "array", "description": "Templates that match the request.", "items": { "$ref": "#/components/schemas/WhatsAppTemplate" } }, "pagination": { "$ref": "#/components/schemas/Pagination" } } }, "WhatsAppTemplateTextHeaderComponentRequest": { "title": "WhatsAppTemplateTextHeaderComponentRequest", "description": "Text header of a new WhatsApp template. Requires `text`. Consumed by `whatsapp_templates_create`.", "type": "object", "additionalProperties": false, "required": [ "type", "format", "text" ], "properties": { "type": { "type": "string", "description": "Component type.", "const": "header" }, "format": { "type": "string", "description": "Header content format.", "const": "text" }, "text": { "type": "string", "description": "Header text, with an optional `{{1}}` placeholder.", "example": "Order {{1}}" }, "example": { "type": "object", "description": "Sample for the `{{1}}` placeholder.", "additionalProperties": false, "required": [ "header_text" ], "properties": { "header_text": { "type": "array", "description": "Sample value for the `{{1}}` placeholder in the header text.", "minItems": 1, "maxItems": 1, "items": { "type": "string" }, "example": [ "#1001" ] } } } } }, "WhatsAppTemplateMediaHeaderComponentRequest": { "title": "WhatsAppTemplateMediaHeaderComponentRequest", "description": "Media header of a new WhatsApp template. Takes no `text`. Consumed by `whatsapp_templates_create`.", "type": "object", "additionalProperties": false, "required": [ "type", "format" ], "properties": { "type": { "type": "string", "description": "Component type.", "const": "header" }, "format": { "type": "string", "description": "Header content format. Possible values:\n\n- `image` — Image header.\n- `video` — Video header.\n- `document` — Document header.", "enum": [ "image", "video", "document" ], "example": "image" }, "example": { "type": "object", "description": "Sample media file.", "additionalProperties": false, "required": [ "header_handle" ], "properties": { "header_handle": { "type": "array", "description": "Public `http` or `https` URL of a sample media file. Meta's own API expects an upload handle here; Wavix sends the URL to the provider as the sample.", "minItems": 1, "maxItems": 1, "items": { "type": "string" }, "example": [ "https://example.com/sample.png" ] } } } } }, "WhatsAppTemplateLocationHeaderComponentRequest": { "title": "WhatsAppTemplateLocationHeaderComponentRequest", "description": "Location header of a new WhatsApp template. Takes neither `text` nor `example`. Consumed by `whatsapp_templates_create`.", "type": "object", "additionalProperties": false, "required": [ "type", "format" ], "properties": { "type": { "type": "string", "description": "Component type.", "const": "header" }, "format": { "type": "string", "description": "Header content format.", "const": "location" } } }, "WhatsAppTemplateHeaderComponentRequest": { "title": "WhatsAppTemplateHeaderComponentRequest", "description": "Header of a new WhatsApp template. Consumed by `whatsapp_templates_create`. The `format` field selects the variant.", "type": "object", "required": [ "type", "format" ], "oneOf": [ { "$ref": "#/components/schemas/WhatsAppTemplateTextHeaderComponentRequest" }, { "$ref": "#/components/schemas/WhatsAppTemplateMediaHeaderComponentRequest" }, { "$ref": "#/components/schemas/WhatsAppTemplateLocationHeaderComponentRequest" } ], "discriminator": { "propertyName": "format", "mapping": { "text": "#/components/schemas/WhatsAppTemplateTextHeaderComponentRequest", "image": "#/components/schemas/WhatsAppTemplateMediaHeaderComponentRequest", "video": "#/components/schemas/WhatsAppTemplateMediaHeaderComponentRequest", "document": "#/components/schemas/WhatsAppTemplateMediaHeaderComponentRequest", "location": "#/components/schemas/WhatsAppTemplateLocationHeaderComponentRequest" } } }, "WhatsAppTemplateBodyComponentRequest": { "title": "WhatsAppTemplateBodyComponentRequest", "description": "Body of a new WhatsApp template. Required, exactly once. Consumed by `whatsapp_templates_create`.", "type": "object", "additionalProperties": false, "required": [ "type", "text" ], "properties": { "type": { "type": "string", "description": "Component type.", "const": "body" }, "text": { "type": "string", "description": "Body text, with positional `{{n}}` placeholders.", "example": "Hi {{1}}, your order {{2}} has shipped." }, "example": { "type": "object", "description": "Sample values for the placeholders in the body text.", "additionalProperties": false, "required": [ "body_text" ], "properties": { "body_text": { "type": "array", "description": "One set of sample values, one value per placeholder in order.", "minItems": 1, "maxItems": 1, "items": { "type": "array", "minItems": 1, "items": { "type": "string" } }, "example": [ [ "Maria", "#1001" ] ] } } } } }, "WhatsAppTemplateFooterComponentRequest": { "title": "WhatsAppTemplateFooterComponentRequest", "description": "Footer of a new WhatsApp template. Consumed by `whatsapp_templates_create`.", "type": "object", "additionalProperties": false, "required": [ "type", "text" ], "properties": { "type": { "type": "string", "description": "Component type.", "const": "footer" }, "text": { "type": "string", "description": "Footer text.", "example": "Reply STOP to unsubscribe." } } }, "WhatsAppTemplateQuickReplyButtonRequest": { "title": "WhatsAppTemplateQuickReplyButtonRequest", "description": "Button that sends its label back as a reply. Consumed by `whatsapp_templates_create`.", "type": "object", "additionalProperties": false, "required": [ "type", "text" ], "properties": { "type": { "type": "string", "description": "Button type.", "const": "quick_reply" }, "text": { "type": "string", "description": "Button label.", "example": "Stop promotions" } } }, "WhatsAppTemplateUrlButtonRequest": { "title": "WhatsAppTemplateUrlButtonRequest", "description": "Button that opens a URL. Consumed by `whatsapp_templates_create`.", "type": "object", "additionalProperties": false, "required": [ "type", "text", "url" ], "properties": { "type": { "type": "string", "description": "Button type.", "const": "url" }, "text": { "type": "string", "description": "Button label.", "example": "Track order" }, "url": { "type": "string", "description": "Target URL, optionally ending in a `{{1}}` placeholder.", "example": "https://example.com/track/{{1}}" }, "example": { "type": "array", "description": "Sample full URL for a `url` that ends in `{{1}}`.", "minItems": 1, "maxItems": 1, "items": { "type": "string" }, "example": [ "https://example.com/track/1001" ] } } }, "WhatsAppTemplatePhoneNumberButtonRequest": { "title": "WhatsAppTemplatePhoneNumberButtonRequest", "description": "Button that calls a phone number. Consumed by `whatsapp_templates_create`.", "type": "object", "additionalProperties": false, "required": [ "type", "text", "phone_number" ], "properties": { "type": { "type": "string", "description": "Button type.", "const": "phone_number" }, "text": { "type": "string", "description": "Button label.", "example": "Call us" }, "phone_number": { "type": "string", "description": "Phone number to call, in E.164 format.", "example": "+31203692036" } } }, "WhatsAppTemplateCopyCodeButtonRequest": { "title": "WhatsAppTemplateCopyCodeButtonRequest", "description": "Button that copies a code to the clipboard. Consumed by `whatsapp_templates_create`.", "type": "object", "additionalProperties": false, "required": [ "type", "example" ], "properties": { "type": { "type": "string", "description": "Button type.", "const": "copy_code" }, "example": { "type": "string", "description": "Sample code.", "example": "SAVE10" } } }, "WhatsAppTemplateButtonRequest": { "title": "WhatsAppTemplateButtonRequest", "description": "A button in the `buttons` component of a new WhatsApp template. Consumed by `whatsapp_templates_create`. The `type` field selects the variant.", "type": "object", "required": [ "type" ], "oneOf": [ { "$ref": "#/components/schemas/WhatsAppTemplateQuickReplyButtonRequest" }, { "$ref": "#/components/schemas/WhatsAppTemplateUrlButtonRequest" }, { "$ref": "#/components/schemas/WhatsAppTemplatePhoneNumberButtonRequest" }, { "$ref": "#/components/schemas/WhatsAppTemplateCopyCodeButtonRequest" } ], "discriminator": { "propertyName": "type", "mapping": { "quick_reply": "#/components/schemas/WhatsAppTemplateQuickReplyButtonRequest", "url": "#/components/schemas/WhatsAppTemplateUrlButtonRequest", "phone_number": "#/components/schemas/WhatsAppTemplatePhoneNumberButtonRequest", "copy_code": "#/components/schemas/WhatsAppTemplateCopyCodeButtonRequest" } } }, "WhatsAppTemplateButtonsComponentRequest": { "title": "WhatsAppTemplateButtonsComponentRequest", "description": "Buttons component of a new WhatsApp template. Consumed by `whatsapp_templates_create`.", "type": "object", "additionalProperties": false, "required": [ "type", "buttons" ], "properties": { "type": { "type": "string", "description": "Component type.", "const": "buttons" }, "buttons": { "type": "array", "description": "Buttons, in display order.", "minItems": 1, "items": { "$ref": "#/components/schemas/WhatsAppTemplateButtonRequest" } } } }, "WhatsAppTemplateComponentRequest": { "title": "WhatsAppTemplateComponentRequest", "description": "A header, body, footer, or buttons component of a new WhatsApp template. Consumed by `whatsapp_templates_create`. The `type` field selects the variant, and a `header` component is further selected by `format`.", "type": "object", "required": [ "type" ], "oneOf": [ { "$ref": "#/components/schemas/WhatsAppTemplateHeaderComponentRequest" }, { "$ref": "#/components/schemas/WhatsAppTemplateBodyComponentRequest" }, { "$ref": "#/components/schemas/WhatsAppTemplateFooterComponentRequest" }, { "$ref": "#/components/schemas/WhatsAppTemplateButtonsComponentRequest" } ], "discriminator": { "propertyName": "type", "mapping": { "header": "#/components/schemas/WhatsAppTemplateHeaderComponentRequest", "body": "#/components/schemas/WhatsAppTemplateBodyComponentRequest", "footer": "#/components/schemas/WhatsAppTemplateFooterComponentRequest", "buttons": "#/components/schemas/WhatsAppTemplateButtonsComponentRequest" } } }, "WhatsAppTemplateCreateRequest": { "title": "WhatsAppTemplateCreateRequest", "description": "Attributes of a new WhatsApp template. Consumed by `whatsapp_templates_create`.", "required": [ "name", "language", "category", "components" ], "type": "object", "additionalProperties": false, "properties": { "name": { "type": "string", "description": "Template name, made of lowercase letters, digits, and underscores, up to 512 characters.", "example": "order_shipped" }, "language": { "type": "string", "description": "Template language code, such as `en` or `en_US`.", "example": "en_US" }, "category": { "type": "string", "description": "Template category. Possible values:\n\n- `marketing` — Promotions, offers, and other marketing content.\n- `authentication` — One-time passcodes for verifying a user.\n- `utility` — Transactional updates about an order or an account.", "enum": [ "marketing", "authentication", "utility" ], "example": "utility" }, "components": { "type": "array", "description": "Structural components of the template. Each component type can appear once, exactly one `body` component is required, and `type` and `format` values must be lowercase.", "minItems": 1, "items": { "$ref": "#/components/schemas/WhatsAppTemplateComponentRequest" } }, "waba_id": { "type": "string", "description": "ID of the WhatsApp Business Account that owns the template, as returned in `waba.id` by `whatsapp_senders_list`. Required when your account has more than one, unless `sender` is set. When both are set, `sender` must belong to this WhatsApp Business Account.", "example": "102290129340398" }, "sender": { "type": "string", "description": "Phone number of a connected sender whose WhatsApp Business Account owns the template, as an alternative to `waba_id`. When both are set, the sender must belong to `waba_id`. The leading `+` is optional.", "pattern": "^\\+?\\d{6,20}$", "example": "14155550100" } } }, "WhatsAppTemplateResponse": { "title": "WhatsAppTemplateResponse", "description": "Returned by `whatsapp_templates_get` and `whatsapp_templates_create`.", "required": [ "template" ], "type": "object", "additionalProperties": false, "properties": { "template": { "$ref": "#/components/schemas/WhatsAppTemplate" } } }, "WhatsAppInboundMessageContent": { "title": "WhatsAppInboundMessageContent", "description": "Content of a WhatsApp message that one of your WhatsApp senders received. Returned in `content` by [List WhatsApp messages](https://docs.wavix.com/api-reference/whatsapp/list-whatsapp-messages) and [Retrieve a WhatsApp message](https://docs.wavix.com/api-reference/whatsapp/retrieve-a-whatsapp-message).", "required": [ "type" ], "type": "object", "additionalProperties": false, "properties": { "type": { "type": "string", "enum": [ "text", "image", "video", "document", "audio", "sticker", "location", "contacts", "reaction", "button_reply", "list_reply", "flow_response", "unsupported" ], "description": "Type of the content in the message. Possible values:\n\n- `text` — A text message; its body is in `text`.\n- `image` — A picture.\n- `video` — A video clip.\n- `document` — A file, such as a PDF.\n- `audio` — An audio file or a voice message.\n- `sticker` — A WhatsApp sticker.\n- `location` — A location the person who sent the message shared. Its coordinates aren't returned yet.\n- `contacts` — One or more contact cards. Its details aren't returned yet.\n- `reaction` — An emoji reaction to a message. The emoji isn't returned yet.\n- `button_reply` — The person who sent the message tapped a button. The button isn't returned yet.\n- `list_reply` — The person who sent the message picked an item from a list. The item isn't returned yet.\n- `flow_response` — The person who sent the message submitted a WhatsApp Flow. The answers aren't returned yet.\n- `unsupported` — Any other kind of message.", "example": "image" }, "text": { "type": "string", "description": "Body of a `text` message. Present only when `type` is `text`; an empty string when the message has no body.", "example": "Hi, is my order on its way?" }, "media_id": { "type": "string", "format": "uuid", "description": "ID of the file in the message. It's the last part of `media_url`. The file stays available at least as long as Wavix keeps the received message. Absent when the file isn't available.", "example": "7f3e2c1a-5b9d-4e8f-a1c3-2d4e6f8a0b1c" }, "media_url": { "type": "string", "format": "uri", "description": "Address of the file. Send a `GET` request to it with your API key. Present only with `media_id`. See [Download received media](https://docs.wavix.com/api-reference/whatsapp/download-received-media).", "example": "https://api.wavix.com/v1/whatsapp/media/7f3e2c1a-5b9d-4e8f-a1c3-2d4e6f8a0b1c" }, "mime_type": { "type": "string", "description": "Media type the file is served with, such as `image/jpeg`. Present only with `media_id`, and absent when the type isn't known.", "example": "image/jpeg" } } }, "WhatsAppMessageError": { "title": "WhatsAppMessageError", "description": "Why a message you sent wasn't delivered. Returned in `whatsapp.message.failed` events and when you retrieve or list WhatsApp messages. Wavix retries temporary failures itself, so you get an error only after Wavix stops retrying.", "type": "object", "additionalProperties": false, "required": [ "code", "message", "action", "docs_url" ], "properties": { "code": { "type": "string", "description": "Wavix error code, in the same format as the `error_code` of WhatsApp API errors. Wavix can add codes, so handle a code you don't recognize as `DELIVERY_FAILED`. Possible values:\n\n- `RECIPIENT_NOT_ON_WHATSAPP` — The recipient's number isn't on WhatsApp or can't receive messages.\n- `RECIPIENT_OPTED_OUT` — The recipient turned off marketing messages or blocked your sender or template.\n- `SERVICE_WINDOW_CLOSED` — The message isn't a template, and the recipient hasn't messaged your sender in the last 24 hours. Send a template instead.\n- `TEMPLATE_NOT_APPROVED` — The template is pending review, was rejected, or WhatsApp hasn't finished preparing it, so it can't be sent yet.\n- `TEMPLATE_PAUSED_OR_DISABLED` — The template is paused or disabled, so it can't be sent.\n- `INVALID_TEMPLATE_PARAMETERS` — The parameters don't match the template. Correct them and send the message again.\n- `MARKETING_LIMIT_REACHED` — WhatsApp limits how many marketing messages a recipient gets, and the limit for this recipient is reached.\n- `SENDER_LIMIT_REACHED` — Your sender reached its messaging limit and can't start new conversations until the 24-hour window resets.\n- `SENDER_RATE_LIMITED` — WhatsApp slowed down your sender, for example because recipients reported or blocked its messages.\n- `SENDER_UNAVAILABLE` — Your sender isn't registered, or it's banned or disconnected.\n- `SERVICE_UNAVAILABLE` — The provider was unavailable and couldn't take the message. Sending it again later can help.\n- `MESSAGE_EXPIRED` — The message expired before it was delivered.\n- `DELIVERY_FAILED` — The message wasn't delivered, and the cause isn't one of the other codes.", "enum": [ "RECIPIENT_NOT_ON_WHATSAPP", "RECIPIENT_OPTED_OUT", "SERVICE_WINDOW_CLOSED", "TEMPLATE_NOT_APPROVED", "TEMPLATE_PAUSED_OR_DISABLED", "INVALID_TEMPLATE_PARAMETERS", "MARKETING_LIMIT_REACHED", "SENDER_LIMIT_REACHED", "SENDER_RATE_LIMITED", "SENDER_UNAVAILABLE", "SERVICE_UNAVAILABLE", "MESSAGE_EXPIRED", "DELIVERY_FAILED" ], "example": "RECIPIENT_NOT_ON_WHATSAPP" }, "subcode": { "type": [ "string", "null" ], "description": "Finer cause within `code`, or `null` when Wavix has no finer cause. Wavix can add values, so handle a value you don't recognize by `code` alone. Possible values:\n\n- `NOT_REGISTERED` — With `RECIPIENT_NOT_ON_WHATSAPP`. The number isn't registered on WhatsApp.\n- `APP_UPDATE_REQUIRED` — With `RECIPIENT_NOT_ON_WHATSAPP`. The recipient's WhatsApp app can't show the message. The recipient may need to update the app or accept the WhatsApp Terms of Service.\n- `DEVICE_UNSUPPORTED` — With `RECIPIENT_NOT_ON_WHATSAPP`. The recipient's device doesn't support the message.\n- `BLOCKED_BY_OPERATOR` — With `RECIPIENT_NOT_ON_WHATSAPP`. This number can't receive WhatsApp messages from businesses.\n- `MARKETING_OPT_OUT` — With `RECIPIENT_OPTED_OUT`. The recipient turned off marketing messages in WhatsApp.\n- `TEMPLATE_BLOCKED_BY_RECIPIENT` — With `RECIPIENT_OPTED_OUT`. The recipient blocked this template.\n- `SENDER_BLOCKED_BY_RECIPIENT` — With `RECIPIENT_OPTED_OUT`. Messages from your sender to this recipient are blocked.\n- `TEMPLATE_NOT_ELIGIBLE` — With `TEMPLATE_NOT_APPROVED`. WhatsApp can't send this template from your sender. Contact Wavix support.\n- `PER_RECIPIENT_MARKETING_LIMIT` — With `MARKETING_LIMIT_REACHED`. The recipient got the maximum number of marketing messages from all businesses for now.\n- `DAILY_PROMOTIONAL_LIMIT` — With `MARKETING_LIMIT_REACHED`. The recipient reached the daily limit on promotional messages.\n- `UNIQUE_RECIPIENTS_LIMIT` — With `SENDER_LIMIT_REACHED`. Your sender reached the number of recipients it can message in 24 hours.\n- `RECIPIENT_MESSAGE_LIMIT` — With `SENDER_LIMIT_REACHED`. Your sender reached the number of messages it can send to this recipient.\n- `LOW_QUALITY_RATING` — With `SENDER_RATE_LIMITED`. The quality rating of your sender limits how many recipients it can reach.\n- `SENDER_NOT_REGISTERED` — With `SENDER_UNAVAILABLE`. Your sender isn't registered on WhatsApp.\n- `SENDER_RESTRICTED` — With `SENDER_UNAVAILABLE`. WhatsApp restricted what your sender can do.\n- `SENDER_MISCONFIGURED` — With `SENDER_UNAVAILABLE`. Your sender's setup doesn't allow this message. Contact Wavix support.\n- `TEMPLATE_INVALID` — With `DELIVERY_FAILED`. The template is invalid or doesn't match its approved version.\n- `MEDIA_UNSUPPORTED` — With `DELIVERY_FAILED`. WhatsApp doesn't support the media file or its format.\n- `MEDIA_INVALID` — With `DELIVERY_FAILED`. The media file couldn't be read or uploaded.\n- `CONTENT_BLOCKED` — With `DELIVERY_FAILED`. WhatsApp blocked the content for a policy violation.", "example": "BLOCKED_BY_OPERATOR" }, "message": { "type": "string", "description": "Short explanation for people, from the most specific of `subcode` and `code`. The text can change, so base your logic on `code`, `subcode`, and `action` instead.", "example": "This number can't receive WhatsApp messages from businesses." }, "action": { "type": "string", "description": "What to do about the message. Possible values:\n\n- `resend_later` — Send the message again later.\n- `fix_and_resend` — Change the message, template, or media, then send it again.\n- `do_not_resend` — Don't send the message again. It won't be delivered.\n- `contact_support` — Contact Wavix support.", "enum": [ "resend_later", "fix_and_resend", "do_not_resend", "contact_support" ], "example": "do_not_resend" }, "docs_url": { "type": "string", "format": "uri", "description": "Page for this code under `https://docs.wavix.com/errors/`. It explains the error, how to fix it, and whether sending the message again can help.", "example": "https://docs.wavix.com/errors/recipient-not-on-whatsapp" } } }, "WhatsAppMessageListItem": { "title": "WhatsAppMessageListItem", "description": "A WhatsApp message your account sent or received. Returned by `whatsapp_messages_list` and `whatsapp_messages_get`.", "required": [ "uuid", "direction", "status", "created_at", "from", "to", "country" ], "type": "object", "additionalProperties": false, "properties": { "uuid": { "type": "string", "format": "uuid", "description": "ID of the message.", "example": "3a525ca2-6909-4c72-9399-905adf7f3a74" }, "direction": { "type": "string", "description": "Message direction. Possible values:\n\n- `outbound` — The message was sent from your account to a recipient.\n- `inbound` — A customer sent the message to one of your senders.", "enum": [ "outbound", "inbound" ], "example": "outbound" }, "status": { "type": "string", "description": "Message delivery status. Inbound messages always have `delivered` status. Possible values:\n\n- `sent` — The message isn't delivered yet.\n- `delivered` — The message was delivered to the recipient.\n- `read` — The recipient opened the message. WhatsApp reports it only when the recipient has read receipts turned on.\n- `undelivered` — The message was sent but not delivered.\n- `expired` — The message expired before it was delivered.\n- `rejected` — The message was permanently rejected before or by the provider.\n- `unknown` — The provider hasn't reported a status.", "enum": [ "sent", "delivered", "read", "undelivered", "expired", "rejected", "unknown" ], "example": "delivered" }, "from": { "type": "string", "description": "For `outbound` messages, the phone number of your sender. For `inbound`, the customer's phone number.", "example": "+14155550100" }, "to": { "type": "string", "description": "For `outbound` messages, the recipient's phone number. For `inbound`, the phone number of your sender that received it.", "example": "+447537151866" }, "country": { "type": [ "string", "null" ], "description": "Country of the customer's phone number, as an ISO 3166-1 alpha-2 code, or `null` if the country can't be determined from the number.", "example": "GB" }, "created_at": { "type": "string", "format": "date-time", "description": "Date and time the message was created, in ISO 8601 format.", "example": "2026-01-15T10:30:00.123Z" }, "content": { "anyOf": [ { "$ref": "#/components/schemas/WhatsAppInboundMessageContent" }, { "type": "null" } ], "description": "Content of an `inbound` message. `null` for `outbound` messages." }, "service_window_open_until": { "type": [ "string", "null" ], "format": "date-time", "description": "End of the 24-hour window in which you may reply to the customer without a template. It's `null` when the customer hasn't written to the sender in the retained history. A value in the past means the window is closed.", "example": "2026-01-16T09:15:00.000Z" }, "error": { "anyOf": [ { "$ref": "#/components/schemas/WhatsAppMessageError" }, { "type": "null" } ], "description": "Why an `outbound` message wasn't delivered. It's `null` unless `status` is `undelivered`, `expired`, or `rejected`." } } }, "WhatsAppMessageListResponse": { "title": "WhatsAppMessageListResponse", "description": "Returned by `whatsapp_messages_list`.", "required": [ "messages", "pagination" ], "type": "object", "additionalProperties": false, "properties": { "messages": { "type": "array", "description": "Messages that match the request.", "items": { "$ref": "#/components/schemas/WhatsAppMessageListItem" } }, "pagination": { "$ref": "#/components/schemas/Pagination" } } }, "WhatsAppSendTemplateHeader": { "title": "WhatsAppSendTemplateHeader", "description": "Header content, required only when the template's `header` component needs one. Each `type` requires specific fields and rejects the others, as listed in the `type` description. Consumed in `template.header` by `whatsapp_messages_send`.", "required": [ "type" ], "type": "object", "additionalProperties": false, "properties": { "type": { "type": "string", "description": "Header content type. Possible values:\n\n- `text` — Text header with a `{{1}}` placeholder. Requires `placeholder`.\n- `text_named_parameters` — Text header with a named placeholder. Requires `parameter_name` and `text`.\n- `image` — Image header. Requires `media_url`.\n- `video` — Video header. Requires `media_url`.\n- `document` — Document header. Requires `media_url` and `filename`.\n- `location` — Location header. Requires `latitude` and `longitude`.", "enum": [ "text", "text_named_parameters", "image", "video", "document", "location" ], "example": "text" }, "placeholder": { "type": "string", "description": "Value for a `text` header's `{{1}}` placeholder.", "example": "#1001" }, "media_url": { "type": "string", "description": "Media URL for an `image`, `video`, or `document` header.", "example": "https://example.com/media/order-1001.pdf" }, "filename": { "type": "string", "description": "Filename for a `document` header.", "example": "order-1001.pdf" }, "latitude": { "type": "number", "description": "Latitude for a `location` header.", "example": 52.3676 }, "longitude": { "type": "number", "description": "Longitude for a `location` header.", "example": 4.9041 }, "parameter_name": { "type": "string", "description": "Placeholder name for a `text_named_parameters` header.", "example": "order_number" }, "text": { "type": "string", "description": "Value for a `text_named_parameters` header.", "example": "#1001" } } }, "WhatsAppSendTemplateButton": { "title": "WhatsAppSendTemplateButton", "description": "Dynamic values for one button of the template. Each `type` requires specific fields and rejects the others, as listed in the `type` description. Consumed in `template.buttons` by `whatsapp_messages_send`.", "required": [ "type" ], "type": "object", "additionalProperties": false, "properties": { "type": { "type": "string", "description": "Button type. Possible values:\n\n- `quick_reply` — Sends a predefined reply. Requires `parameter`.\n- `url` — Opens a URL. Requires `parameter`.\n- `copy_code` — Copies a code to the clipboard. Requires `parameter`.\n- `flow` — Opens a WhatsApp Flow. Accepts `flow_token` and `data`.\n- `catalog` — Opens the business catalog. Accepts `thumbnail_product_retailer_id`.\n- `multi_product` — Shows a message with several products. Requires `sections` and accepts `thumbnail_product_retailer_id`.\n- `order_details` — Shows order details. Requires `action`.\n- `voice_call` — Starts a voice call. Accepts `call_validity_period` and `call_context_payload`.", "enum": [ "quick_reply", "url", "copy_code", "flow", "catalog", "multi_product", "order_details", "voice_call" ], "example": "url" }, "parameter": { "type": "string", "description": "Dynamic value of a `quick_reply`, `url`, or `copy_code` button. Required for those types.", "example": "1001" }, "flow_token": { "type": "string", "description": "Flow token of a `flow` button." }, "data": { "type": "object", "description": "Initial data passed to the Flow of a `flow` button.", "additionalProperties": true }, "thumbnail_product_retailer_id": { "type": "string", "description": "Retailer ID of the product shown as the thumbnail of a `catalog` or `multi_product` button." }, "sections": { "type": "array", "description": "Product sections of a `multi_product` button. Required for that type.", "items": { "type": "object", "additionalProperties": true } }, "action": { "type": "object", "description": "Order details of an `order_details` button. Required for that type.", "additionalProperties": true }, "call_validity_period": { "type": "integer", "description": "How long a `voice_call` button stays valid." }, "call_context_payload": { "type": "string", "description": "Context payload returned with a call started from a `voice_call` button." } } }, "WhatsAppSendTemplate": { "title": "WhatsAppSendTemplate", "description": "The template to send and the values for its dynamic parts. Consumed in `template` by `whatsapp_messages_send`.", "required": [ "name", "language" ], "type": "object", "additionalProperties": false, "properties": { "name": { "type": "string", "description": "Name of the template to send, as returned by `whatsapp_templates_list`.", "example": "order_shipped" }, "language": { "type": "string", "description": "Language code of the template to send, as returned by `whatsapp_templates_list`.", "example": "en_US" }, "placeholders": { "type": "array", "description": "Values substituted into the template body's `{{n}}` placeholders, in order.", "items": { "type": "string" }, "example": [ "Maria", "#1001" ] }, "header": { "$ref": "#/components/schemas/WhatsAppSendTemplateHeader" }, "buttons": { "type": "array", "description": "Dynamic values for the template's `buttons` component, one entry per button, matching the template's button order. Each entry accepts only the fields its `type` uses.", "items": { "$ref": "#/components/schemas/WhatsAppSendTemplateButton" } } } }, "WhatsAppSendTextContent": { "title": "WhatsAppSendTextContent", "description": "Content of a message without a template that is text. Consumed in `content` of [Send a WhatsApp message](https://docs.wavix.com/api-reference/whatsapp/send-a-whatsapp-message).", "type": "object", "additionalProperties": false, "required": [ "type", "text" ], "properties": { "type": { "type": "string", "const": "text", "description": "Type of the content, always `text`.", "example": "text" }, "text": { "type": "string", "description": "Text of the message.", "minLength": 1, "maxLength": 4096, "example": "Your order ships tomorrow morning." } } }, "WhatsAppSendMedia": { "title": "WhatsAppSendMedia", "description": "A media file to send. Consumed in the `image`, `video`, `audio`, or `document` field of `content` of [Send a WhatsApp message](https://docs.wavix.com/api-reference/whatsapp/send-a-whatsapp-message).", "type": "object", "additionalProperties": false, "required": [ "url" ], "properties": { "url": { "type": "string", "format": "uri", "maxLength": 2048, "description": "Public `https` URL of the file, without embedded credentials (`user:password@`). WhatsApp downloads the file from it, so it must stay reachable until the message is delivered.", "example": "https://example.com/invoices/1001.pdf" }, "caption": { "type": "string", "description": "Caption shown under the file. Not allowed for `audio`.", "maxLength": 1024, "example": "Invoice for order 1001" }, "filename": { "type": "string", "description": "File name the recipient sees. Allowed only for `document`.", "maxLength": 240, "example": "invoice-1001.pdf" } } }, "WhatsAppSendImageContent": { "title": "WhatsAppSendImageContent", "description": "Content of a message without a template that is an image. Consumed in `content` of [Send a WhatsApp message](https://docs.wavix.com/api-reference/whatsapp/send-a-whatsapp-message).", "type": "object", "additionalProperties": false, "required": [ "type", "image" ], "properties": { "type": { "type": "string", "const": "image", "description": "Type of the content, always `image`.", "example": "image" }, "image": { "$ref": "#/components/schemas/WhatsAppSendMedia" } } }, "WhatsAppSendVideoContent": { "title": "WhatsAppSendVideoContent", "description": "Content of a message without a template that is a video. Consumed in `content` of [Send a WhatsApp message](https://docs.wavix.com/api-reference/whatsapp/send-a-whatsapp-message).", "type": "object", "additionalProperties": false, "required": [ "type", "video" ], "properties": { "type": { "type": "string", "const": "video", "description": "Type of the content, always `video`.", "example": "video" }, "video": { "$ref": "#/components/schemas/WhatsAppSendMedia" } } }, "WhatsAppSendAudioContent": { "title": "WhatsAppSendAudioContent", "description": "Content of a message without a template that is an audio file. Consumed in `content` of [Send a WhatsApp message](https://docs.wavix.com/api-reference/whatsapp/send-a-whatsapp-message).", "type": "object", "additionalProperties": false, "required": [ "type", "audio" ], "properties": { "type": { "type": "string", "const": "audio", "description": "Type of the content, always `audio`.", "example": "audio" }, "audio": { "$ref": "#/components/schemas/WhatsAppSendMedia" } } }, "WhatsAppSendDocumentContent": { "title": "WhatsAppSendDocumentContent", "description": "Content of a message without a template that is a document. Consumed in `content` of [Send a WhatsApp message](https://docs.wavix.com/api-reference/whatsapp/send-a-whatsapp-message).", "type": "object", "additionalProperties": false, "required": [ "type", "document" ], "properties": { "type": { "type": "string", "const": "document", "description": "Type of the content, always `document`.", "example": "document" }, "document": { "$ref": "#/components/schemas/WhatsAppSendMedia" } } }, "WhatsAppSendReplyButton": { "title": "WhatsAppSendReplyButton", "description": "A reply button. Consumed in `content.buttons.items` of [Send a WhatsApp message](https://docs.wavix.com/api-reference/whatsapp/send-a-whatsapp-message).", "type": "object", "additionalProperties": false, "required": [ "id", "title" ], "properties": { "id": { "type": "string", "description": "Your ID of the button, returned in `content.button_reply.id` of the `whatsapp.message.received` event when the recipient taps it. Unique within the message.", "minLength": 1, "maxLength": 256, "example": "deliver-today" }, "title": { "type": "string", "description": "Label of the button, unique within the message. Emojis are supported, Markdown isn't.", "minLength": 1, "maxLength": 20, "example": "Today" } } }, "WhatsAppSendButtons": { "title": "WhatsAppSendButtons", "description": "A text with reply buttons. Consumed in `content.buttons` of [Send a WhatsApp message](https://docs.wavix.com/api-reference/whatsapp/send-a-whatsapp-message). When the recipient taps a button, Wavix sends a `whatsapp.message.received` event with the button's `id` in `content.button_reply`.", "type": "object", "additionalProperties": false, "required": [ "body", "items" ], "properties": { "header": { "type": "string", "description": "Text shown in bold at the top of the message.", "maxLength": 60, "example": "Order 1001" }, "body": { "type": "string", "description": "Main text of the message.", "minLength": 1, "maxLength": 1024, "example": "Your order is ready. When should we deliver it?" }, "footer": { "type": "string", "description": "Text shown in small type at the end of the message.", "maxLength": 60, "example": "Reply by 6 PM" }, "items": { "type": "array", "description": "Reply buttons, in the order they're shown.", "minItems": 1, "maxItems": 3, "items": { "$ref": "#/components/schemas/WhatsAppSendReplyButton" } } } }, "WhatsAppSendButtonsContent": { "title": "WhatsAppSendButtonsContent", "description": "Content of a message without a template that is a text with reply buttons. Consumed in `content` of [Send a WhatsApp message](https://docs.wavix.com/api-reference/whatsapp/send-a-whatsapp-message).", "type": "object", "additionalProperties": false, "required": [ "type", "buttons" ], "properties": { "type": { "type": "string", "const": "buttons", "description": "Type of the content, always `buttons`.", "example": "buttons" }, "buttons": { "$ref": "#/components/schemas/WhatsAppSendButtons" } } }, "WhatsAppSendListRow": { "title": "WhatsAppSendListRow", "description": "An item in a list. Consumed in `content.list.sections.items` of [Send a WhatsApp message](https://docs.wavix.com/api-reference/whatsapp/send-a-whatsapp-message).", "type": "object", "additionalProperties": false, "required": [ "id", "title" ], "properties": { "id": { "type": "string", "description": "Your ID of the item, returned in `content.list_reply.id` of the `whatsapp.message.received` event when the recipient picks it. Unique within the message.", "minLength": 1, "maxLength": 200, "example": "slot-morning" }, "title": { "type": "string", "description": "Title of the item.", "minLength": 1, "maxLength": 24, "example": "Morning, 9 to 12" }, "description": { "type": "string", "description": "Text shown under the title.", "maxLength": 72, "example": "Delivery between 9:00 and 12:00" } } }, "WhatsAppSendListSection": { "title": "WhatsAppSendListSection", "description": "A group of items in a list. Consumed in `content.list.sections` of [Send a WhatsApp message](https://docs.wavix.com/api-reference/whatsapp/send-a-whatsapp-message).", "type": "object", "additionalProperties": false, "required": [ "items" ], "properties": { "title": { "type": "string", "description": "Title of the section. Required when the list has more than one section.", "maxLength": 24, "example": "Tomorrow" }, "items": { "type": "array", "description": "Items in the section.", "minItems": 1, "maxItems": 10, "items": { "$ref": "#/components/schemas/WhatsAppSendListRow" } } } }, "WhatsAppSendList": { "title": "WhatsAppSendList", "description": "A text with a button that opens a list of items. Consumed in `content.list` of [Send a WhatsApp message](https://docs.wavix.com/api-reference/whatsapp/send-a-whatsapp-message). When the recipient picks an item, Wavix sends a `whatsapp.message.received` event with the item's `id` in `content.list_reply`.", "type": "object", "additionalProperties": false, "required": [ "body", "button_text", "sections" ], "properties": { "header": { "type": "string", "description": "Text shown in bold at the top of the message.", "maxLength": 60, "example": "Delivery slots" }, "body": { "type": "string", "description": "Main text of the message.", "minLength": 1, "maxLength": 1024, "example": "Pick a time for your delivery." }, "footer": { "type": "string", "description": "Text shown in small type at the end of the message.", "maxLength": 60, "example": "Times are local" }, "button_text": { "type": "string", "description": "Label of the button that opens the list.", "minLength": 1, "maxLength": 20, "example": "Choose a slot" }, "sections": { "type": "array", "description": "Groups of items in the list. All sections together hold at most 10 items.", "minItems": 1, "maxItems": 10, "items": { "$ref": "#/components/schemas/WhatsAppSendListSection" } } } }, "WhatsAppSendListContent": { "title": "WhatsAppSendListContent", "description": "Content of a message without a template that is a text with a list of items to pick from. Consumed in `content` of [Send a WhatsApp message](https://docs.wavix.com/api-reference/whatsapp/send-a-whatsapp-message).", "type": "object", "additionalProperties": false, "required": [ "type", "list" ], "properties": { "type": { "type": "string", "const": "list", "description": "Type of the content, always `list`.", "example": "list" }, "list": { "$ref": "#/components/schemas/WhatsAppSendList" } } }, "WhatsAppSendContent": { "title": "WhatsAppSendContent", "description": "Content of a message sent without a template, inside the 24-hour service window. Consumed in `content` of [Send a WhatsApp message](https://docs.wavix.com/api-reference/whatsapp/send-a-whatsapp-message). The `type` field decides which other field holds the content. Possible values:\n\n- `text` — Text.\n- `image` — An image, with an optional caption.\n- `video` — A video, with an optional caption.\n- `audio` — An audio file.\n- `document` — A document, with an optional file name and caption.\n- `buttons` — A text with up to 3 reply buttons.\n- `list` — A text with a button that opens a list of up to 10 items.", "oneOf": [ { "$ref": "#/components/schemas/WhatsAppSendTextContent" }, { "$ref": "#/components/schemas/WhatsAppSendImageContent" }, { "$ref": "#/components/schemas/WhatsAppSendVideoContent" }, { "$ref": "#/components/schemas/WhatsAppSendAudioContent" }, { "$ref": "#/components/schemas/WhatsAppSendDocumentContent" }, { "$ref": "#/components/schemas/WhatsAppSendButtonsContent" }, { "$ref": "#/components/schemas/WhatsAppSendListContent" } ], "discriminator": { "propertyName": "type", "mapping": { "text": "#/components/schemas/WhatsAppSendTextContent", "image": "#/components/schemas/WhatsAppSendImageContent", "video": "#/components/schemas/WhatsAppSendVideoContent", "audio": "#/components/schemas/WhatsAppSendAudioContent", "document": "#/components/schemas/WhatsAppSendDocumentContent", "buttons": "#/components/schemas/WhatsAppSendButtonsContent", "list": "#/components/schemas/WhatsAppSendListContent" } } }, "WhatsAppMessageSendRequest": { "title": "WhatsAppMessageSendRequest", "description": "Attributes of a WhatsApp message to send. Send exactly one of `template` and `content`. Use `content` only while the 24-hour service window of the recipient is open. Consumed by `whatsapp_messages_send`.", "required": [ "from", "to" ], "type": "object", "additionalProperties": false, "properties": { "from": { "type": "string", "description": "Phone number of a sender registered on your account, in E.164 format, as returned by `whatsapp_senders_list`. The leading `+` is optional.", "pattern": "^\\+?\\d{6,20}$", "example": "+14155550100" }, "to": { "type": "string", "description": "Recipient's phone number in E.164 format. The leading `+` is optional.", "pattern": "^\\+?\\d{6,20}$", "example": "+447537151866" }, "idempotency_key": { "type": "string", "description": "Key that makes the send safe to retry, unique per account. Matching is exact, so case and accents are significant - `ORDER-1` and `order-1` are two different keys and both are sent. Printable ASCII only. Must not begin with `campaign:`, a prefix reserved for campaign messages. A request with a key in that namespace is rejected.", "maxLength": 128, "pattern": "^[\\x20-\\x7e]*$", "example": "order-1001-shipped" }, "template": { "$ref": "#/components/schemas/WhatsAppSendTemplate" }, "content": { "$ref": "#/components/schemas/WhatsAppSendContent" } } }, "WhatsAppMessageTemplate": { "title": "WhatsAppMessageTemplate", "description": "The template that a WhatsApp message was sent with. Returned in `template` by `whatsapp_messages_send`.", "required": [ "name", "language" ], "type": "object", "additionalProperties": false, "properties": { "name": { "type": "string", "description": "Template name.", "example": "order_shipped" }, "language": { "type": "string", "description": "Template language code.", "example": "en_US" } } }, "WhatsAppMessage": { "title": "WhatsAppMessage", "description": "A WhatsApp message you sent. Returned by `whatsapp_messages_send`.", "required": [ "uuid", "from", "to", "status", "template", "created_at" ], "type": "object", "additionalProperties": false, "properties": { "uuid": { "type": "string", "format": "uuid", "description": "ID of the message. Pass it to `whatsapp_messages_get` to check the delivery outcome.", "example": "3a525ca2-6909-4c72-9399-905adf7f3a74" }, "from": { "type": "string", "description": "Sender's phone number in E.164 format.", "example": "+14155550100" }, "to": { "type": "string", "description": "Recipient's phone number in E.164 format.", "example": "+447537151866" }, "status": { "type": "string", "description": "Message delivery status. Possible values:\n\n- `sent` — The message isn't delivered yet.\n- `delivered` — The message was delivered to the recipient.\n- `read` — The recipient opened the message. WhatsApp reports it only when the recipient has read receipts turned on.\n- `undelivered` — The message was sent but not delivered.\n- `expired` — The message expired before it was delivered.\n- `rejected` — The message was permanently rejected before or by the provider.\n- `unknown` — The provider hasn't reported a status.", "enum": [ "sent", "delivered", "read", "undelivered", "expired", "rejected", "unknown" ], "example": "sent" }, "template": { "anyOf": [ { "$ref": "#/components/schemas/WhatsAppMessageTemplate" }, { "type": "null" } ], "description": "Template used to send the message." }, "service_window_open_until": { "type": [ "string", "null" ], "format": "date-time", "description": "End of the 24-hour window in which you may reply to the recipient without a template. It's `null` when the recipient hasn't written to the sender in the retained history. A value in the past means the window is closed.", "example": "2026-01-16T09:15:00.000Z" }, "created_at": { "type": "string", "format": "date-time", "description": "Date and time the message was created, in ISO 8601 format.", "example": "2026-01-15T10:30:00.123Z" } } }, "WhatsAppMessageSendResponse": { "title": "WhatsAppMessageSendResponse", "description": "Returned by `whatsapp_messages_send`.", "required": [ "message" ], "type": "object", "additionalProperties": false, "properties": { "message": { "$ref": "#/components/schemas/WhatsAppMessage" } } }, "WhatsAppMessageGetResponse": { "title": "WhatsAppMessageGetResponse", "description": "Returned by `whatsapp_messages_get`.", "required": [ "message" ], "type": "object", "additionalProperties": false, "properties": { "message": { "$ref": "#/components/schemas/WhatsAppMessageListItem" } } }, "WhatsAppWebhookGroup": { "title": "WhatsAppWebhookGroup", "description": "Group of WhatsApp event types that a webhook receives. Your account can have one webhook per group. Possible values:\n\n- `messages` — Messages your senders receive, the delivery outcome of messages you send, and contacts' marketing preferences.\n- `templates` — Changes to the status, category, and quality rating of your templates.\n- `senders` — Changes to the status and quality rating of your senders.", "type": "string", "enum": [ "messages", "templates", "senders" ], "example": "messages" }, "WhatsAppEventType": { "title": "WhatsAppEventType", "description": "Type of a WhatsApp event. Each type belongs to one webhook group. Wavix can add event types to a group, so ignore an event whose `type` you don't recognize. Possible values:\n\n- `whatsapp.message.received` — One of your senders received a message.\n- `whatsapp.message.sent` — A message you sent has the `sent` status: it isn't delivered yet.\n- `whatsapp.message.delivered` — A message you sent was delivered to the recipient. WhatsApp can skip it when the recipient reads the message right away.\n- `whatsapp.message.read` — The recipient opened a message you sent. WhatsApp reports it only when the recipient has read receipts turned on.\n- `whatsapp.message.failed` — A message you sent wasn't delivered. `data.error` says why.\n- `whatsapp.contact.marketing_stopped` — A contact asked to stop marketing messages from one of your senders. Meta doesn't deliver marketing templates to the contact until they resume them.\n- `whatsapp.contact.marketing_resumed` — A contact asked to receive marketing messages from one of your senders again.\n- `whatsapp.template.approved` — The provider approved one of your templates, so you can send it.\n- `whatsapp.template.rejected` — The provider rejected one of your templates.\n- `whatsapp.template.paused` — The provider paused one of your templates.\n- `whatsapp.template.disabled` — One of your templates is disabled and can't be sent.\n- `whatsapp.template.flagged` — Meta flagged one of your templates because of negative feedback. It can still be sent, but it's at risk of being paused or disabled.\n- `whatsapp.template.category_changed` — Meta moved one of your templates to another category, which changes the rate of each message sent with it.\n- `whatsapp.template.quality_changed` — Meta changed the quality rating of one of your templates.\n- `whatsapp.template.updated` — The status of one of your templates changed to a value that has no event type of its own, such as `pending`, `in_appeal`, or `deleted`.\n- `whatsapp.sender.connected` — One of your senders can send messages within its messaging limit, for example after registration or when a restriction ends.\n- `whatsapp.sender.restricted` — One of your senders reached its messaging limit. It can't start new conversations until the 24-hour window resets, but it can still reply to customers who messaged it.\n- `whatsapp.sender.flagged` — The quality rating of one of your senders dropped to low. The status returns to `connected` if the rating returns to medium or high within 7 days.\n- `whatsapp.sender.banned` — The provider banned one of your senders.\n- `whatsapp.sender.disconnected` — One of your senders is disconnected from the provider.\n- `whatsapp.sender.quality_changed` — Meta changed the quality rating of one of your senders.\n- `whatsapp.sender.updated` — The status of one of your senders changed to a value that has no event type of its own, such as `pending`, `migrated`, or `deleted`.", "type": "string", "enum": [ "whatsapp.message.received", "whatsapp.message.sent", "whatsapp.message.delivered", "whatsapp.message.read", "whatsapp.message.failed", "whatsapp.contact.marketing_stopped", "whatsapp.contact.marketing_resumed", "whatsapp.template.approved", "whatsapp.template.rejected", "whatsapp.template.paused", "whatsapp.template.disabled", "whatsapp.template.flagged", "whatsapp.template.category_changed", "whatsapp.template.quality_changed", "whatsapp.template.updated", "whatsapp.sender.connected", "whatsapp.sender.restricted", "whatsapp.sender.flagged", "whatsapp.sender.banned", "whatsapp.sender.disconnected", "whatsapp.sender.quality_changed", "whatsapp.sender.updated" ], "example": "whatsapp.message.received" }, "WhatsAppWebhook": { "title": "WhatsAppWebhook", "description": "A WhatsApp webhook of your account, returned when you create, list, or retrieve a webhook.", "type": "object", "additionalProperties": false, "required": [ "uuid", "url", "group", "enabled", "enabled_events", "created_at" ], "properties": { "uuid": { "type": "string", "format": "uuid", "description": "Webhook ID. Test events carry it as `data.webhook_id`.", "example": "6f1c2a4e-8b3d-4c5e-9f70-1a2b3c4d5e6f" }, "url": { "type": "string", "format": "uri", "maxLength": 2048, "description": "The https URL that Wavix sends events to.", "example": "https://example.com/wavix" }, "group": { "$ref": "#/components/schemas/WhatsAppWebhookGroup" }, "enabled": { "type": "boolean", "description": "Whether the webhook gets events. A disabled webhook gets only test events. Change it with [Update a WhatsApp webhook](https://docs.wavix.com/api-reference/whatsapp/update-a-whatsapp-webhook).", "example": true }, "enabled_events": { "type": "array", "readOnly": true, "description": "Event types Wavix sends to the webhook, which are every event type of its `group`. When Wavix adds an event type to the group, the list includes it.", "items": { "$ref": "#/components/schemas/WhatsAppEventType" }, "example": [ "whatsapp.message.received", "whatsapp.message.sent", "whatsapp.message.delivered", "whatsapp.message.read", "whatsapp.message.failed", "whatsapp.contact.marketing_stopped", "whatsapp.contact.marketing_resumed" ] }, "created_at": { "type": "string", "format": "date-time", "description": "Date and time when the webhook was created, in ISO 8601 UTC.", "example": "2026-10-21T12:00:00Z" }, "secret": { "type": "string", "pattern": "^whsec_[A-Za-z0-9+/]{43}=$", "description": "The signing secret, in the Standard Webhooks format. Returned only when you create the webhook; store it, because it's never returned again.", "example": "whsec_AQIDBAUGBwgJCgsMDQ4PEBESExQVFhcYGRobHB0eHyA=" } } }, "WhatsAppWebhookListResponse": { "title": "WhatsAppWebhookListResponse", "description": "The WhatsApp webhooks of your account, returned when you list them.", "required": [ "webhooks" ], "type": "object", "additionalProperties": false, "properties": { "webhooks": { "type": "array", "description": "The account's webhooks, ordered by group (`messages`, `templates`, `senders`), at most one per group. The array is empty when the account has none.", "items": { "$ref": "#/components/schemas/WhatsAppWebhook" } } } }, "WhatsAppWebhookCreateRequest": { "title": "WhatsAppWebhookCreateRequest", "description": "Body of the request that creates a WhatsApp webhook.", "type": "object", "additionalProperties": false, "required": [ "url", "group" ], "properties": { "url": { "type": "string", "format": "uri", "maxLength": 2048, "description": "An https URL whose host resolves only to public addresses. Webhooks of different groups can share a URL.", "example": "https://example.com/wavix" }, "group": { "$ref": "#/components/schemas/WhatsAppWebhookGroup" } } }, "WhatsAppWebhookResponse": { "title": "WhatsAppWebhookResponse", "description": "A single WhatsApp webhook, returned when you create or retrieve a webhook.", "required": [ "webhook" ], "type": "object", "additionalProperties": false, "properties": { "webhook": { "$ref": "#/components/schemas/WhatsAppWebhook" } } }, "WhatsAppWebhookUpdateRequest": { "title": "WhatsAppWebhookUpdateRequest", "description": "Fields to update on a WhatsApp webhook. Consumed by [Update a WhatsApp webhook](https://docs.wavix.com/api-reference/whatsapp/update-a-whatsapp-webhook). Specify at least one field; fields you omit keep their values.", "type": "object", "additionalProperties": false, "minProperties": 1, "required": [], "properties": { "url": { "type": "string", "format": "uri", "maxLength": 2048, "description": "New https URL that Wavix sends events to. Wavix checks it the same way as when you create a webhook.", "example": "https://example.com/wavix/v2" }, "enabled": { "type": "boolean", "description": "Whether Wavix sends events to the webhook. When `false`, Wavix sends only test events. Read the others with [List WhatsApp events](https://docs.wavix.com/api-reference/whatsapp/list-whatsapp-events).", "example": false } } }, "WhatsAppWebhookTestResult": { "title": "WhatsAppWebhookTestResult", "description": "Outcome of one test event sent to a WhatsApp webhook.", "type": "object", "additionalProperties": false, "required": [ "outcome", "status_code", "duration_ms" ], "properties": { "outcome": { "type": "string", "description": "What happened to the test event. Possible values:\n\n- `delivered` — The receiver answered with a 2xx status.\n- `http_error` — The receiver answered with any other status.\n- `timeout` — No answer arrived within 10 seconds.\n- `connection_error` — Wavix couldn't connect to the receiver.\n- `tls_error` — The TLS handshake failed or the certificate isn't valid.\n- `blocked` — The host of the URL now resolves to an address that isn't public or that Wavix doesn't allow, so Wavix didn't send the event.", "enum": [ "delivered", "http_error", "timeout", "connection_error", "tls_error", "blocked" ], "example": "delivered" }, "status_code": { "type": [ "integer", "null" ], "description": "The receiver's HTTP status, or null when no response arrived.", "example": 200 }, "duration_ms": { "type": "integer", "minimum": 0, "description": "Time the test attempt took, in milliseconds, until the response headers arrived or the attempt stopped without a response. `0` when Wavix didn't send the event.", "example": 184 } } }, "WhatsAppWebhookTestResponse": { "title": "WhatsAppWebhookTestResponse", "description": "The outcome of a WhatsApp webhook test event, returned when you send one.", "required": [ "test" ], "type": "object", "additionalProperties": false, "properties": { "test": { "$ref": "#/components/schemas/WhatsAppWebhookTestResult" } } }, "WhatsAppEvent": { "title": "WhatsAppEvent", "description": "A WhatsApp event returned by [List WhatsApp events](https://docs.wavix.com/api-reference/whatsapp/list-whatsapp-events). It has the same fields as the event Wavix posts to your webhook, and `type` decides the shape of `data`.", "type": "object", "additionalProperties": false, "required": [ "id", "type", "timestamp", "data" ], "properties": { "id": { "type": "string", "pattern": "^evt_[0-9a-f]{32}$", "description": "Unique ID of the event. It's the same in the event list and in the webhook request, so use it to discard events you already handled.", "example": "evt_8a1d3c5e7f9b4d2a6c8e0f1a3b5c7d9e" }, "type": { "type": "string", "description": "Type of the event, such as `whatsapp.message.received`. The `type` query parameter lists every type. Wavix can add event types, so ignore an event whose `type` you don't recognize.", "example": "whatsapp.message.delivered" }, "timestamp": { "type": "string", "format": "date-time", "description": "When the event happened, in ISO 8601 UTC with 6 fractional digits. The list is ordered by when Wavix recorded events, so `timestamp` can be out of order.", "example": "2026-10-21T08:30:00.123456Z" }, "data": { "type": "object", "additionalProperties": true, "description": "Details of the event. The fields depend on `type` and are the same as `data` in the webhook request for that type.", "example": { "message_uuid": "3a525ca2-6909-4c72-9399-905adf7f3a74", "from": "+14155550100", "to": "+447537151866", "template": { "name": "order_shipped", "language": "en_US" } } } } }, "WhatsAppEventListResponse": { "title": "WhatsAppEventListResponse", "description": "A paginated list of your account's WhatsApp events, returned by [List WhatsApp events](https://docs.wavix.com/api-reference/whatsapp/list-whatsapp-events).", "type": "object", "additionalProperties": false, "required": [ "events", "next_cursor", "has_more" ], "properties": { "events": { "type": "array", "description": "Events in the order Wavix recorded them, oldest first. Empty when no event matches.", "items": { "$ref": "#/components/schemas/WhatsAppEvent" } }, "next_cursor": { "type": [ "string", "null" ], "description": "ID of the last event on this page. Pass it as `after` to get the events that follow. Null when the page is empty; keep the cursor you have, or omit `after` if you have none.", "example": "evt_1b3d5f7a9c2e4b6d8f0a1c3e5b7d9f2a" }, "has_more": { "type": "boolean", "description": "`true` when more events follow this page right now. `false` means you've caught up; events recorded later appear after the same cursor.", "example": false } } }, "CallStatusWebhook": { "title": "CallStatusWebhook", "required": [ "direction", "uuid", "destination", "duration", "charge", "date", "disposition", "from", "to", "per_minute" ], "type": "object", "additionalProperties": false, "properties": { "direction": { "type": "string", "description": "Direction of the call. One of `inbound` (call received by the account) or `outbound` (call placed by the account).", "enum": [ "inbound", "outbound" ], "example": "outbound" }, "uuid": { "type": "string", "description": "Call ID", "example": "99df5ffd-962a-410f-bcce-d08f1f7f328c" }, "destination": { "type": [ "string", "null" ], "description": "Destination of the call. For outbound calls, it contains the country name and, optionally, a mobile carrier or city name. For inbound calls, the destination includes the user-defined SIP trunk name, SIP URI, or PSTN number that the call is forwarded to.", "example": "France" }, "duration": { "type": "integer", "description": "Duration of the call, in seconds", "format": "int32", "example": 6 }, "charge": { "type": "string", "description": "Total charge for the call, in USD", "example": "0.822" }, "date": { "type": "string", "description": "Date and time of the call", "format": "date-time", "example": "2023-08-21T06:43:36.000Z" }, "disposition": { "$ref": "#/components/schemas/CallDisposition" }, "from": { "type": [ "string", "null" ], "description": "ANI/From attribute of the call", "example": "14302287001" }, "to": { "type": [ "string", "null" ], "description": "DNIS/To attribute of the call", "example": "33170363950" }, "per_minute": { "type": "string", "description": "Price per minute, in USD", "example": "0.027" } }, "description": "Post-call webhook payload" }, "FileTranscriptionCompletedWebhook": { "title": "FileTranscriptionCompletedWebhook", "required": [ "request_id", "status", "error" ], "type": "object", "additionalProperties": false, "properties": { "request_id": { "type": "string", "description": "Transcription request ID", "example": "e865ea07-25af-4fdd-876e-04b0d41d5ebd" }, "status": { "type": "string", "description": "Outcome of the transcription. One of `completed` (the transcript was produced) or `failed` (the transcription could not be produced).", "example": "completed" }, "error": { "type": [ "string", "null" ], "description": "A human-readable error description, if any" } } }, "CDRTranscriptionCompletedWebhook": { "title": "CDRTranscriptionCompletedWebhook", "required": [ "uuid", "status" ], "type": "object", "additionalProperties": false, "properties": { "uuid": { "type": "string", "description": "Call UUID", "example": "99df5ffd-962a-410f-bcce-d08f1f7f328c" }, "status": { "type": "string", "description": "Outcome of the transcription. One of `completed` (the transcript was produced) or `failed` (the transcription could not be produced).", "enum": [ "completed", "failed" ], "example": "completed" } } }, "MessagesDeliveryReport": { "title": "MessagesDeliveryReport", "required": [ "message_id", "message_type", "from", "to", "status", "sent", "segments_count", "charge", "carrier_fees" ], "type": "object", "description": "Message delivery report (DLR).", "additionalProperties": false, "properties": { "message_id": { "type": "string", "description": "Message ID.", "example": "871b4eeb-f798-4105-be23-32df9e991456" }, "message_type": { "type": "string", "description": "Type of message. Possible values are `sms`, `mms`.", "example": "sms" }, "from": { "type": "string", "description": "Sender ID. Can be numeric or alphanumeric.", "example": "Wavix" }, "to": { "type": "string", "description": "Destination phone number.", "example": "+447537151866" }, "tag": { "type": [ "string", "null" ], "description": "Tag to identify a group of messages, such as those associated with a campaign.", "example": "Fall sale" }, "status": { "$ref": "#/components/schemas/MessageDeliveryStatus" }, "segments_count": { "type": "integer", "description": "Number of message segments for SMS. For MMS, the value is always 1.", "format": "int32", "example": 1 }, "sent": { "type": [ "string", "null" ], "description": "Date and time the message was accepted in ISO 8601 format.", "format": "date-time", "example": "2024-05-28T12:34:54Z" }, "delivered": { "type": [ "string", "null" ], "description": "Date and time when the final status was received in ISO 8601 format.", "format": "date-time", "example": "2024-05-28T12:34:56Z" }, "error": { "type": [ "string", "null" ], "description": "Human-readable error description." }, "charge": { "type": "string", "description": "Total charge for the message in USD.", "example": "0.01" }, "carrier_fees": { "type": "string", "description": "Mobile carrier fees in USD.", "example": "0.0" } } }, "InboundMessage": { "title": "SMSorMMSmessage", "required": [ "message_id", "from", "to", "message_body", "received_at" ], "type": "object", "additionalProperties": false, "properties": { "message_id": { "type": "string", "description": "Unique identifier of the message generated by the platform", "example": "871b4eeb-f798-4105-be23-32df9e991456" }, "from": { "type": "string", "description": "Sender ID used to send the message. Can be numeric or alphanumeric.", "example": "Wavix" }, "to": { "type": "string", "description": "Phone number on the account that received the message.", "example": "447537151866" }, "message_body": { "$ref": "#/components/schemas/MessageBody" }, "received_at": { "type": "string", "description": "Timestamp the messages is received by Wavix", "format": "date-time", "example": "2022-04-14T13:51:16.096Z" } }, "description": "An inbound message" }, "BrandStatusUpdatedWebhook": { "type": "object", "additionalProperties": false, "required": [ "brand_id", "status" ], "properties": { "brand_id": { "type": "string", "description": "Unique identifier of the 10DLC Brand.", "example": "BX12JH90" }, "status": { "type": "string", "description": "Current verification status of the 10DLC Brand. One of `SELF_DECLARED`, `UNVERIFIED`, `VERIFIED`, `VETTED_VERIFIED`, `REVIEW`, or `SUSPENDED`. `SELF_DECLARED` means the Brand registered without external verification; `UNVERIFIED` means verification has not yet succeeded; `VERIFIED` means the Brand passed standard verification; `VETTED_VERIFIED` means the Brand also passed third-party vetting; `REVIEW` means verification is in progress; `SUSPENDED` means the Brand is blocked from sending.", "enum": [ "SELF_DECLARED", "UNVERIFIED", "VERIFIED", "VETTED_VERIFIED", "REVIEW", "SUSPENDED" ], "example": "VERIFIED" } } }, "CampaignStatusUpdatedWebhook": { "type": "object", "additionalProperties": false, "required": [ "campaign_id", "brand_id", "status" ], "properties": { "brand_id": { "type": "string", "description": "Unique identifier of a 10DLC Brand", "example": "BX12JH90" }, "campaign_id": { "type": "string", "description": "Unique identifier of a 10DLC Campaign", "example": "CX34KL56" }, "status": { "type": "string", "description": "Current status of the 10DLC Campaign. One of:\n\n- `REVIEW` — the campaign is under review.\n- `APPROVED` — the campaign was approved and can send.\n- `DECLINED` — the campaign was rejected during review.\n- `DELETED` — the campaign was removed.\n- `EXPIRED` — the campaign registration lapsed.\n- `SUSPENDED` — the campaign is blocked from sending.\n- `PORTED_OUT` — the campaign was migrated to another provider.", "enum": [ "REVIEW", "APPROVED", "DECLINED", "DELETED", "EXPIRED", "SUSPENDED", "PORTED_OUT" ], "example": "APPROVED" } } }, "NumberStatusUpdatedWebhook": { "type": "object", "additionalProperties": false, "required": [ "number", "campaign_id", "brand_id", "status" ], "properties": { "brand_id": { "type": "string", "description": "10DLC Brand ID.", "example": "BX12JH90" }, "campaign_id": { "type": "string", "description": "10DLC Campaign ID.", "example": "CX34KL56" }, "number": { "type": "string", "description": "Phone number associated with a 10DLC Campaign.", "example": "17029641104" }, "status": { "type": "string", "description": "Status of the phone number's assignment to the 10DLC Campaign. One of `APPROVED` (the number is registered to the campaign), `PENDING` (registration is in progress), or `REJECTED` (registration was declined).", "enum": [ "APPROVED", "PENDING", "REJECTED" ], "example": "APPROVED" } } }, "WhatsAppInboundTextContent": { "title": "WhatsAppInboundTextContent", "description": "Content of a received message that is text. Returned in `content` of a `whatsapp.message.received` event.", "type": "object", "additionalProperties": false, "required": [ "type", "text" ], "properties": { "type": { "type": "string", "const": "text", "description": "Type of the content, always `text`.", "example": "text" }, "text": { "type": "string", "description": "Text of the message.", "example": "Hi, is my order on its way?" } } }, "WhatsAppInboundMedia": { "title": "WhatsAppInboundMedia", "description": "A media file in a received message. Returned in the `image`, `video`, `audio`, `document`, or `sticker` field of the content of a `whatsapp.message.received` event.", "type": "object", "additionalProperties": false, "required": [ "id", "url", "mime_type", "caption", "filename" ], "properties": { "id": { "type": "string", "format": "uuid", "description": "ID of the file. It's the last part of `url`. The file stays available at least as long as Wavix keeps the received message.", "example": "7f3e2c1a-5b9d-4e8f-a1c3-2d4e6f8a0b1c" }, "url": { "type": "string", "format": "uri", "description": "Address of the file. Send a `GET` request to it with your API key to download the file. See [Download received media](https://docs.wavix.com/api-reference/whatsapp/download-received-media).", "example": "https://api.wavix.com/v1/whatsapp/media/7f3e2c1a-5b9d-4e8f-a1c3-2d4e6f8a0b1c" }, "mime_type": { "type": "string", "description": "MIME type of the file.", "example": "image/jpeg" }, "caption": { "type": [ "string", "null" ], "description": "Caption the contact added. Null when there is none, and always null for audio and stickers.", "example": "Photo of the damaged box" }, "filename": { "type": [ "string", "null" ], "description": "Name of the file as the contact sent it. Null for every type except `document`.", "example": null } } }, "WhatsAppInboundImageContent": { "title": "WhatsAppInboundImageContent", "description": "Content of a received message that is an image. Returned in `content` of a `whatsapp.message.received` event.", "type": "object", "additionalProperties": false, "required": [ "type", "image" ], "properties": { "type": { "type": "string", "const": "image", "description": "Type of the content, always `image`.", "example": "image" }, "image": { "$ref": "#/components/schemas/WhatsAppInboundMedia" } } }, "WhatsAppInboundVideoContent": { "title": "WhatsAppInboundVideoContent", "description": "Content of a received message that is a video. Returned in `content` of a `whatsapp.message.received` event.", "type": "object", "additionalProperties": false, "required": [ "type", "video" ], "properties": { "type": { "type": "string", "const": "video", "description": "Type of the content, always `video`.", "example": "video" }, "video": { "$ref": "#/components/schemas/WhatsAppInboundMedia" } } }, "WhatsAppInboundAudioContent": { "title": "WhatsAppInboundAudioContent", "description": "Content of a received message that is an audio file or voice note. Returned in `content` of a `whatsapp.message.received` event.", "type": "object", "additionalProperties": false, "required": [ "type", "audio" ], "properties": { "type": { "type": "string", "const": "audio", "description": "Type of the content, always `audio`.", "example": "audio" }, "audio": { "$ref": "#/components/schemas/WhatsAppInboundMedia" } } }, "WhatsAppInboundDocumentContent": { "title": "WhatsAppInboundDocumentContent", "description": "Content of a received message that is a document. Returned in `content` of a `whatsapp.message.received` event.", "type": "object", "additionalProperties": false, "required": [ "type", "document" ], "properties": { "type": { "type": "string", "const": "document", "description": "Type of the content, always `document`.", "example": "document" }, "document": { "$ref": "#/components/schemas/WhatsAppInboundMedia" } } }, "WhatsAppInboundStickerContent": { "title": "WhatsAppInboundStickerContent", "description": "Content of a received message that is a sticker. Returned in `content` of a `whatsapp.message.received` event.", "type": "object", "additionalProperties": false, "required": [ "type", "sticker" ], "properties": { "type": { "type": "string", "const": "sticker", "description": "Type of the content, always `sticker`.", "example": "sticker" }, "sticker": { "$ref": "#/components/schemas/WhatsAppInboundMedia" } } }, "WhatsAppInboundLocation": { "title": "WhatsAppInboundLocation", "description": "A location in a received message. Returned in `content.location` of a `whatsapp.message.received` event.", "type": "object", "additionalProperties": false, "required": [ "latitude", "longitude", "name", "address" ], "properties": { "latitude": { "type": "number", "format": "double", "description": "Latitude, in degrees.", "example": 51.5072 }, "longitude": { "type": "number", "format": "double", "description": "Longitude, in degrees.", "example": -0.1276 }, "name": { "type": [ "string", "null" ], "description": "Name of the place, or null when the contact shared a point without a name.", "example": "Wavix office" }, "address": { "type": [ "string", "null" ], "description": "Address of the place, or null when WhatsApp doesn't provide one.", "example": "1 Main Street, London" } } }, "WhatsAppInboundLocationContent": { "title": "WhatsAppInboundLocationContent", "description": "Content of a received message that is a location. Returned in `content` of a `whatsapp.message.received` event.", "type": "object", "additionalProperties": false, "required": [ "type", "location" ], "properties": { "type": { "type": "string", "const": "location", "description": "Type of the content, always `location`.", "example": "location" }, "location": { "$ref": "#/components/schemas/WhatsAppInboundLocation" } } }, "WhatsAppInboundContactCard": { "title": "WhatsAppInboundContactCard", "description": "A contact card in a received message. Returned in `content.contacts` of a `whatsapp.message.received` event.", "type": "object", "additionalProperties": false, "required": [ "name", "phones", "emails" ], "properties": { "name": { "type": "string", "description": "Full name on the card.", "example": "Jane Smith" }, "phones": { "type": "array", "description": "Phone numbers on the card, as the contact entered them. Empty when the card has none.", "items": { "type": "string" }, "example": [ "+447700900123" ] }, "emails": { "type": "array", "description": "Email addresses on the card. Empty when the card has none.", "items": { "type": "string" }, "example": [ "jane.smith@example.com" ] } } }, "WhatsAppInboundContactsContent": { "title": "WhatsAppInboundContactsContent", "description": "Content of a received message that is one or more contact cards. Returned in `content` of a `whatsapp.message.received` event.", "type": "object", "additionalProperties": false, "required": [ "type", "contacts" ], "properties": { "type": { "type": "string", "const": "contacts", "description": "Type of the content, always `contacts`.", "example": "contacts" }, "contacts": { "type": "array", "description": "Contact cards the contact shared.", "minItems": 1, "items": { "$ref": "#/components/schemas/WhatsAppInboundContactCard" } } } }, "WhatsAppInboundReaction": { "title": "WhatsAppInboundReaction", "description": "A reaction in a received message. Returned in `content.reaction` of a `whatsapp.message.received` event.", "type": "object", "additionalProperties": false, "required": [ "message_uuid", "emoji" ], "properties": { "message_uuid": { "type": [ "string", "null" ], "format": "uuid", "description": "ID of the message the contact reacted to, or null when Wavix has no record of that message.", "example": "3a525ca2-6909-4c72-9399-905adf7f3a74" }, "emoji": { "type": [ "string", "null" ], "description": "The emoji, or null when the contact removed their reaction.", "example": "👍" } } }, "WhatsAppInboundReactionContent": { "title": "WhatsAppInboundReactionContent", "description": "Content of a received message that is a reaction to an earlier message. Returned in `content` of a `whatsapp.message.received` event.", "type": "object", "additionalProperties": false, "required": [ "type", "reaction" ], "properties": { "type": { "type": "string", "const": "reaction", "description": "Type of the content, always `reaction`.", "example": "reaction" }, "reaction": { "$ref": "#/components/schemas/WhatsAppInboundReaction" } } }, "WhatsAppInboundButtonReply": { "title": "WhatsAppInboundButtonReply", "description": "A tap on a quick reply button. Returned in `content.button_reply` of a `whatsapp.message.received` event.", "type": "object", "additionalProperties": false, "required": [ "id", "title" ], "properties": { "id": { "type": "string", "description": "ID of the button you set when you sent the message, such as the `parameter` of a `quick_reply` template button or the `id` of a button in `content.buttons`. Match on it, not on `title`.", "example": "confirm-order-1001" }, "title": { "type": "string", "description": "Label of the button the contact tapped.", "example": "Confirm" } } }, "WhatsAppInboundButtonReplyContent": { "title": "WhatsAppInboundButtonReplyContent", "description": "Content of a received message that is a tap on a button of a message you sent. Returned in `content` of a `whatsapp.message.received` event.", "type": "object", "additionalProperties": false, "required": [ "type", "button_reply" ], "properties": { "type": { "type": "string", "const": "button_reply", "description": "Type of the content, always `button_reply`.", "example": "button_reply" }, "button_reply": { "$ref": "#/components/schemas/WhatsAppInboundButtonReply" } } }, "WhatsAppInboundListReply": { "title": "WhatsAppInboundListReply", "description": "An item picked from a list. Returned in `content.list_reply` of a `whatsapp.message.received` event.", "type": "object", "additionalProperties": false, "required": [ "id", "title", "description" ], "properties": { "id": { "type": "string", "description": "ID of the item you set when you sent the list. Match on it rather than on `title`.", "example": "slot-morning" }, "title": { "type": "string", "description": "Title of the item the contact picked.", "example": "Morning, 9 to 12" }, "description": { "type": [ "string", "null" ], "description": "Description of the item, or null when it has none.", "example": "Delivery between 9:00 and 12:00" } } }, "WhatsAppInboundListReplyContent": { "title": "WhatsAppInboundListReplyContent", "description": "Content of a received message that is an item picked from a list in a message you sent. Returned in `content` of a `whatsapp.message.received` event.", "type": "object", "additionalProperties": false, "required": [ "type", "list_reply" ], "properties": { "type": { "type": "string", "const": "list_reply", "description": "Type of the content, always `list_reply`.", "example": "list_reply" }, "list_reply": { "$ref": "#/components/schemas/WhatsAppInboundListReply" } } }, "WhatsAppInboundFlowResponseContent": { "title": "WhatsAppInboundFlowResponseContent", "description": "Content of a received message that is the response to a WhatsApp Flow the contact completed. Returned in `content` of a `whatsapp.message.received` event.", "type": "object", "additionalProperties": false, "required": [ "type", "flow_response" ], "properties": { "type": { "type": "string", "const": "flow_response", "description": "Type of the content, always `flow_response`.", "example": "flow_response" }, "flow_response": { "type": "object", "additionalProperties": true, "required": [], "description": "Fields the contact submitted in the Flow, as defined by the Flow. `flow_token` holds the token you set when you sent the Flow.", "example": { "flow_token": "order-1001", "delivery_date": "2026-10-24", "time_slot": "morning" } } } }, "WhatsAppInboundContent": { "title": "WhatsAppInboundContent", "description": "Content of a received message. Returned in `content` of a `whatsapp.message.received` event. The `type` field decides which other field holds the content. Wavix can add content types, so ignore a message whose `type` you don't recognize. Possible values:\n\n- `text` — Text.\n- `image` — An image, with an optional caption.\n- `video` — A video, with an optional caption.\n- `audio` — An audio file or a voice note.\n- `document` — A document, with its file name and an optional caption.\n- `sticker` — A sticker.\n- `location` — A location.\n- `contacts` — One or more contact cards.\n- `reaction` — An emoji reaction to an earlier message, or the removal of one.\n- `button_reply` — A tap on a quick reply button of a message you sent.\n- `list_reply` — An item picked from a list in a message you sent.\n- `flow_response` — The response to a WhatsApp Flow the contact completed.", "oneOf": [ { "$ref": "#/components/schemas/WhatsAppInboundTextContent" }, { "$ref": "#/components/schemas/WhatsAppInboundImageContent" }, { "$ref": "#/components/schemas/WhatsAppInboundVideoContent" }, { "$ref": "#/components/schemas/WhatsAppInboundAudioContent" }, { "$ref": "#/components/schemas/WhatsAppInboundDocumentContent" }, { "$ref": "#/components/schemas/WhatsAppInboundStickerContent" }, { "$ref": "#/components/schemas/WhatsAppInboundLocationContent" }, { "$ref": "#/components/schemas/WhatsAppInboundContactsContent" }, { "$ref": "#/components/schemas/WhatsAppInboundReactionContent" }, { "$ref": "#/components/schemas/WhatsAppInboundButtonReplyContent" }, { "$ref": "#/components/schemas/WhatsAppInboundListReplyContent" }, { "$ref": "#/components/schemas/WhatsAppInboundFlowResponseContent" } ], "discriminator": { "propertyName": "type", "mapping": { "text": "#/components/schemas/WhatsAppInboundTextContent", "image": "#/components/schemas/WhatsAppInboundImageContent", "video": "#/components/schemas/WhatsAppInboundVideoContent", "audio": "#/components/schemas/WhatsAppInboundAudioContent", "document": "#/components/schemas/WhatsAppInboundDocumentContent", "sticker": "#/components/schemas/WhatsAppInboundStickerContent", "location": "#/components/schemas/WhatsAppInboundLocationContent", "contacts": "#/components/schemas/WhatsAppInboundContactsContent", "reaction": "#/components/schemas/WhatsAppInboundReactionContent", "button_reply": "#/components/schemas/WhatsAppInboundButtonReplyContent", "list_reply": "#/components/schemas/WhatsAppInboundListReplyContent", "flow_response": "#/components/schemas/WhatsAppInboundFlowResponseContent" } } }, "WhatsAppInboundContext": { "title": "WhatsAppInboundContext", "description": "The message a received message replies to. Returned in `context` of a `whatsapp.message.received` event.", "type": "object", "additionalProperties": false, "required": [ "message_uuid" ], "properties": { "message_uuid": { "type": [ "string", "null" ], "format": "uuid", "description": "ID of the message the contact replied to, or null when Wavix has no record of that message.", "example": "3a525ca2-6909-4c72-9399-905adf7f3a74" } } }, "WhatsAppInboundReferral": { "title": "WhatsAppInboundReferral", "description": "The ad or post that brought the contact to the conversation. Returned in `referral` of a `whatsapp.message.received` event when the contact tapped a click-to-WhatsApp ad.", "type": "object", "additionalProperties": false, "required": [ "source_type", "source_id", "source_url", "headline", "body", "click_id" ], "properties": { "source_type": { "type": "string", "description": "Type of the source. Possible values:\n\n- `ad` — A click-to-WhatsApp ad.\n- `post` — A Facebook or Instagram post.", "enum": [ "ad", "post" ], "example": "ad" }, "source_id": { "type": "string", "description": "Meta ID of the ad or post.", "example": "120210000000000001" }, "source_url": { "type": "string", "format": "uri", "description": "URL of the ad or post.", "example": "https://fb.me/3cr4Wqqkk" }, "headline": { "type": [ "string", "null" ], "description": "Headline of the ad, or null when it has none.", "example": "Free delivery this week" }, "body": { "type": [ "string", "null" ], "description": "Text of the ad, or null when it has none.", "example": "Order today and get free delivery." }, "click_id": { "type": [ "string", "null" ], "description": "Click ID of the ad, for matching the conversation to the click in Meta's ad reports. Null when Meta doesn't provide one.", "example": "ARAkLkA8rmlFeiCktEJQ" } } }, "WhatsAppMessageReceivedEventData": { "title": "WhatsAppMessageReceivedEventData", "description": "Data of a `whatsapp.message.received` event. It carries the received message, its phone numbers, and what you need to reply.", "type": "object", "additionalProperties": false, "required": [ "message_uuid", "from", "to", "profile_name", "content", "context", "referral", "service_window_open_until" ], "properties": { "message_uuid": { "type": "string", "format": "uuid", "description": "ID of the received message, the same as in [Retrieve a WhatsApp message](https://docs.wavix.com/api-reference/whatsapp/retrieve-a-whatsapp-message).", "example": "9d4e1c7a-2b86-4f3d-b5a0-71e8c3f6a924" }, "from": { "type": "string", "description": "Phone number of the person who sent the message, in E.164 format.", "example": "+447537151866" }, "to": { "type": "string", "description": "Your sender's phone number that received the message, in E.164 format.", "example": "+14155550100" }, "profile_name": { "type": [ "string", "null" ], "description": "Name on the contact's WhatsApp profile, or null when the provider doesn't report it.", "example": "Jane Smith" }, "content": { "$ref": "#/components/schemas/WhatsAppInboundContent" }, "context": { "description": "The message this message replies to, or null when it isn't a reply.", "anyOf": [ { "$ref": "#/components/schemas/WhatsAppInboundContext" }, { "type": "null" } ] }, "referral": { "description": "The ad or post the contact came from, or null when the conversation didn't start from one.", "anyOf": [ { "$ref": "#/components/schemas/WhatsAppInboundReferral" }, { "type": "null" } ] }, "service_window_open_until": { "type": "string", "format": "date-time", "description": "Time until which you can reply to this contact from this sender without a template, in ISO 8601 UTC. Each new message from the contact moves it forward.", "example": "2026-10-22T08:30:00Z" } } }, "WhatsAppMessageReceivedEvent": { "title": "WhatsAppMessageReceivedEvent", "description": "Event that tells you one of your senders received a message. Posted to your webhook and returned by [List WhatsApp events](https://docs.wavix.com/api-reference/whatsapp/list-whatsapp-events).", "type": "object", "additionalProperties": false, "required": [ "id", "type", "timestamp", "data" ], "properties": { "id": { "type": "string", "pattern": "^evt_[0-9a-f]{32}$", "description": "Unique ID of the event. It's the same on every delivery attempt and in the event list, so use it to discard duplicates.", "example": "evt_8a1d3c5e7f9b4d2a6c8e0f1a3b5c7d9e" }, "type": { "type": "string", "const": "whatsapp.message.received", "description": "Type of the event, always `whatsapp.message.received`.", "example": "whatsapp.message.received" }, "timestamp": { "type": "string", "format": "date-time", "description": "When the message was received, in ISO 8601 UTC with 6 fractional digits (microseconds). It isn't the delivery time in the `webhook-timestamp` header.", "example": "2026-10-21T08:30:00.123456Z" }, "data": { "$ref": "#/components/schemas/WhatsAppMessageReceivedEventData" } } }, "WhatsAppMessageStatusEventData": { "title": "WhatsAppMessageStatusEventData", "description": "Data of a `whatsapp.message.sent`, `whatsapp.message.delivered`, or `whatsapp.message.read` event. It identifies the message; the event type carries its status.", "type": "object", "additionalProperties": false, "required": [ "message_uuid", "from", "to", "template" ], "properties": { "message_uuid": { "type": "string", "format": "uuid", "description": "ID of the message, as returned by [Send a WhatsApp message](https://docs.wavix.com/api-reference/whatsapp/send-a-whatsapp-message).", "example": "3a525ca2-6909-4c72-9399-905adf7f3a74" }, "from": { "type": "string", "description": "Your sender's phone number, in E.164 format.", "example": "+14155550100" }, "to": { "type": "string", "description": "Recipient's phone number, in E.164 format.", "example": "+447537151866" }, "template": { "description": "Template the message was sent with, or null when it wasn't sent with a template.", "anyOf": [ { "$ref": "#/components/schemas/WhatsAppMessageTemplate" }, { "type": "null" } ] } } }, "WhatsAppMessageSentEvent": { "title": "WhatsAppMessageSentEvent", "description": "Event of type `whatsapp.message.sent`. A message you sent has the `sent` status: it isn't delivered yet. Posted to your webhook and returned by [List WhatsApp events](https://docs.wavix.com/api-reference/whatsapp/list-whatsapp-events).", "type": "object", "additionalProperties": false, "required": [ "id", "type", "timestamp", "data" ], "properties": { "id": { "type": "string", "pattern": "^evt_[0-9a-f]{32}$", "description": "Unique ID of the event. It's the same on every delivery attempt and in the event list, so use it to discard duplicates.", "example": "evt_0a2c4e6a8c0e4a2c4e6a8c0e2a4c6e8a" }, "type": { "type": "string", "const": "whatsapp.message.sent", "description": "Type of the event, always `whatsapp.message.sent`.", "example": "whatsapp.message.sent" }, "timestamp": { "type": "string", "format": "date-time", "description": "When Wavix recorded the provider accepting the message, in ISO 8601 UTC with 6 fractional digits (microseconds). It isn't the delivery time in the `webhook-timestamp` header.", "example": "2026-10-21T08:31:05.000000Z" }, "data": { "$ref": "#/components/schemas/WhatsAppMessageStatusEventData" } } }, "WhatsAppMessageDeliveredEvent": { "title": "WhatsAppMessageDeliveredEvent", "description": "Event of type `whatsapp.message.delivered`. A message you sent was delivered to the recipient. Posted to your webhook and returned by [List WhatsApp events](https://docs.wavix.com/api-reference/whatsapp/list-whatsapp-events).", "type": "object", "additionalProperties": false, "required": [ "id", "type", "timestamp", "data" ], "properties": { "id": { "type": "string", "pattern": "^evt_[0-9a-f]{32}$", "description": "Unique ID of the event. It's the same on every delivery attempt and in the event list, so use it to discard duplicates.", "example": "evt_1b3d5f7a9c2e4b6d8f0a1c3e5b7d9f2a" }, "type": { "type": "string", "const": "whatsapp.message.delivered", "description": "Type of the event, always `whatsapp.message.delivered`.", "example": "whatsapp.message.delivered" }, "timestamp": { "type": "string", "format": "date-time", "description": "When the provider reported the status, in ISO 8601 UTC with 6 fractional digits (microseconds). It isn't the delivery time in the `webhook-timestamp` header.", "example": "2026-10-21T08:31:05.000000Z" }, "data": { "$ref": "#/components/schemas/WhatsAppMessageStatusEventData" } } }, "WhatsAppMessageReadEvent": { "title": "WhatsAppMessageReadEvent", "description": "Event of type `whatsapp.message.read`. The recipient opened a message you sent. WhatsApp reports it only when the recipient has read receipts turned on. Posted to your webhook and returned by [List WhatsApp events](https://docs.wavix.com/api-reference/whatsapp/list-whatsapp-events).", "type": "object", "additionalProperties": false, "required": [ "id", "type", "timestamp", "data" ], "properties": { "id": { "type": "string", "pattern": "^evt_[0-9a-f]{32}$", "description": "Unique ID of the event. It's the same on every delivery attempt and in the event list, so use it to discard duplicates.", "example": "evt_5d7f9b1c3e5a4c7e9b1d3f5a7c9e1b3d" }, "type": { "type": "string", "const": "whatsapp.message.read", "description": "Type of the event, always `whatsapp.message.read`.", "example": "whatsapp.message.read" }, "timestamp": { "type": "string", "format": "date-time", "description": "When the provider reported the status, in ISO 8601 UTC with 6 fractional digits (microseconds). It isn't the delivery time in the `webhook-timestamp` header.", "example": "2026-10-21T08:31:05.000000Z" }, "data": { "$ref": "#/components/schemas/WhatsAppMessageStatusEventData" } } }, "WhatsAppMessageFailedEventData": { "title": "WhatsAppMessageFailedEventData", "description": "Data of a `whatsapp.message.failed` event. It identifies the message and says why it wasn't delivered.", "type": "object", "additionalProperties": false, "required": [ "message_uuid", "from", "to", "template", "status", "error" ], "properties": { "message_uuid": { "type": "string", "format": "uuid", "description": "ID of the message, as returned by [Send a WhatsApp message](https://docs.wavix.com/api-reference/whatsapp/send-a-whatsapp-message).", "example": "3a525ca2-6909-4c72-9399-905adf7f3a74" }, "from": { "type": "string", "description": "Your sender's phone number, in E.164 format.", "example": "+14155550100" }, "to": { "type": "string", "description": "Recipient's phone number, in E.164 format.", "example": "+447537151866" }, "template": { "description": "Template the message was sent with, or null when it wasn't sent with a template.", "anyOf": [ { "$ref": "#/components/schemas/WhatsAppMessageTemplate" }, { "type": "null" } ] }, "status": { "type": "string", "description": "Status of the message, the same as in [Retrieve a WhatsApp message](https://docs.wavix.com/api-reference/whatsapp/retrieve-a-whatsapp-message). Possible values:\n\n- `undelivered` — The message was sent but not delivered.\n- `expired` — The message expired before it was delivered.\n- `rejected` — The message was permanently rejected before or by the provider.", "enum": [ "undelivered", "expired", "rejected" ], "example": "undelivered" }, "error": { "$ref": "#/components/schemas/WhatsAppMessageError" } } }, "WhatsAppMessageFailedEvent": { "title": "WhatsAppMessageFailedEvent", "description": "Event that tells you a message you sent wasn't delivered. Posted to your webhook and returned by [List WhatsApp events](https://docs.wavix.com/api-reference/whatsapp/list-whatsapp-events).", "type": "object", "additionalProperties": false, "required": [ "id", "type", "timestamp", "data" ], "properties": { "id": { "type": "string", "pattern": "^evt_[0-9a-f]{32}$", "description": "Unique ID of the event. It's the same on every delivery attempt and in the event list, so use it to discard duplicates.", "example": "evt_7c9e1a3b5d7f4c2e8a0b2d4f6a8c0e1b" }, "type": { "type": "string", "const": "whatsapp.message.failed", "description": "Type of the event, always `whatsapp.message.failed`.", "example": "whatsapp.message.failed" }, "timestamp": { "type": "string", "format": "date-time", "description": "When the provider reported the failure, or when Wavix decided the message failed, in ISO 8601 UTC with 6 fractional digits. It isn't the delivery time in the `webhook-timestamp` header.", "example": "2026-10-21T08:32:40.000000Z" }, "data": { "$ref": "#/components/schemas/WhatsAppMessageFailedEventData" } } }, "WhatsAppContactMarketingPreferenceEventData": { "title": "WhatsAppContactMarketingPreferenceEventData", "description": "Data of a `whatsapp.contact.marketing_stopped` or `whatsapp.contact.marketing_resumed` event. It names the contact and the sender the choice applies to.", "type": "object", "additionalProperties": false, "required": [ "from", "to" ], "properties": { "from": { "type": "string", "description": "Phone number of the contact who changed the preference, in E.164 format.", "example": "+447537151866" }, "to": { "type": "string", "description": "Your sender's phone number the preference applies to, in E.164 format.", "example": "+14155550100" } } }, "WhatsAppContactMarketingStoppedEvent": { "title": "WhatsAppContactMarketingStoppedEvent", "description": "Event of type `whatsapp.contact.marketing_stopped`. A contact asked to stop marketing messages from one of your senders. Posted to your webhook and returned by [List WhatsApp events](https://docs.wavix.com/api-reference/whatsapp/list-whatsapp-events).", "type": "object", "additionalProperties": false, "required": [ "id", "type", "timestamp", "data" ], "properties": { "id": { "type": "string", "pattern": "^evt_[0-9a-f]{32}$", "description": "Unique ID of the event. It's the same on every delivery attempt and in the event list, so use it to discard duplicates.", "example": "evt_2a4c6e8a0c2e4a6c8e0a2c4e6a8c0e2a" }, "type": { "type": "string", "const": "whatsapp.contact.marketing_stopped", "description": "Type of the event, always `whatsapp.contact.marketing_stopped`.", "example": "whatsapp.contact.marketing_stopped" }, "timestamp": { "type": "string", "format": "date-time", "description": "When the contact changed the preference, in ISO 8601 UTC with 6 fractional digits (microseconds). It isn't the delivery time in the `webhook-timestamp` header.", "example": "2026-10-21T10:05:00.000000Z" }, "data": { "$ref": "#/components/schemas/WhatsAppContactMarketingPreferenceEventData" } } }, "WhatsAppContactMarketingResumedEvent": { "title": "WhatsAppContactMarketingResumedEvent", "description": "Event of type `whatsapp.contact.marketing_resumed`. A contact asked to receive marketing messages from one of your senders again. Posted to your webhook and returned by [List WhatsApp events](https://docs.wavix.com/api-reference/whatsapp/list-whatsapp-events).", "type": "object", "additionalProperties": false, "required": [ "id", "type", "timestamp", "data" ], "properties": { "id": { "type": "string", "pattern": "^evt_[0-9a-f]{32}$", "description": "Unique ID of the event. It's the same on every delivery attempt and in the event list, so use it to discard duplicates.", "example": "evt_8c0e2a4c6e8a4c0e2a4c6e8a0c2e4a6c" }, "type": { "type": "string", "const": "whatsapp.contact.marketing_resumed", "description": "Type of the event, always `whatsapp.contact.marketing_resumed`.", "example": "whatsapp.contact.marketing_resumed" }, "timestamp": { "type": "string", "format": "date-time", "description": "When the contact changed the preference, in ISO 8601 UTC with 6 fractional digits (microseconds). It isn't the delivery time in the `webhook-timestamp` header.", "example": "2026-10-21T10:05:00.000000Z" }, "data": { "$ref": "#/components/schemas/WhatsAppContactMarketingPreferenceEventData" } } }, "WhatsAppWebhookTestEventData": { "title": "WhatsAppWebhookTestEventData", "description": "Data of a `test` event. It names the webhook the event was sent to.", "type": "object", "additionalProperties": false, "required": [ "webhook_id" ], "properties": { "webhook_id": { "type": "string", "format": "uuid", "description": "ID of the webhook the test event was sent to, the same as its `uuid`.", "example": "6f1c2a4e-8b3d-4c5e-9f70-1a2b3c4d5e6f" } } }, "WhatsAppWebhookTestEvent": { "title": "WhatsAppWebhookTestEvent", "description": "Event that Wavix posts to a WhatsApp webhook when you send a test event to it. It never appears in the event list.", "type": "object", "additionalProperties": false, "required": [ "id", "type", "timestamp", "data" ], "properties": { "id": { "type": "string", "pattern": "^evt_[0-9a-f]{32}$", "description": "Unique ID of the event.", "example": "evt_3f6c0f5e9b2a4d7c8e1f0a2b3c4d5e6f" }, "type": { "type": "string", "const": "test", "description": "Type of the event, always `test`.", "example": "test" }, "timestamp": { "type": "string", "format": "date-time", "description": "When the test event was requested, in ISO 8601 UTC with 6 fractional digits (microseconds). It isn't the delivery time in the `webhook-timestamp` header.", "example": "2026-10-21T08:30:00.123456Z" }, "data": { "$ref": "#/components/schemas/WhatsAppWebhookTestEventData" } } }, "WhatsAppMessagesGroupEvent": { "title": "WhatsAppMessagesGroupEvent", "description": "Event Wavix posts to your webhook of the `messages` group: a received message, the status of a message you sent, a contact's marketing preference, or a test event. The `type` field decides the shape of `data`. Wavix can add event types, so ignore a `type` you don't recognize.", "oneOf": [ { "$ref": "#/components/schemas/WhatsAppMessageReceivedEvent" }, { "$ref": "#/components/schemas/WhatsAppMessageSentEvent" }, { "$ref": "#/components/schemas/WhatsAppMessageDeliveredEvent" }, { "$ref": "#/components/schemas/WhatsAppMessageReadEvent" }, { "$ref": "#/components/schemas/WhatsAppMessageFailedEvent" }, { "$ref": "#/components/schemas/WhatsAppContactMarketingStoppedEvent" }, { "$ref": "#/components/schemas/WhatsAppContactMarketingResumedEvent" }, { "$ref": "#/components/schemas/WhatsAppWebhookTestEvent" } ], "discriminator": { "propertyName": "type", "mapping": { "whatsapp.message.received": "#/components/schemas/WhatsAppMessageReceivedEvent", "whatsapp.message.sent": "#/components/schemas/WhatsAppMessageSentEvent", "whatsapp.message.delivered": "#/components/schemas/WhatsAppMessageDeliveredEvent", "whatsapp.message.read": "#/components/schemas/WhatsAppMessageReadEvent", "whatsapp.message.failed": "#/components/schemas/WhatsAppMessageFailedEvent", "whatsapp.contact.marketing_stopped": "#/components/schemas/WhatsAppContactMarketingStoppedEvent", "whatsapp.contact.marketing_resumed": "#/components/schemas/WhatsAppContactMarketingResumedEvent", "test": "#/components/schemas/WhatsAppWebhookTestEvent" } } }, "WhatsAppTemplatePreviousAttributes": { "title": "WhatsAppTemplatePreviousAttributes", "description": "Value that the changed attribute of a template had before the change. It holds only that attribute — `category` for `whatsapp.template.category_changed`, `quality_rating` for `whatsapp.template.quality_changed`, and `status` for the status events, such as `whatsapp.template.approved`.", "type": "object", "additionalProperties": false, "required": [], "properties": { "status": { "type": "string", "description": "Template review status before the change. Takes the same values as `status`.", "enum": [ "draft", "pending", "approved", "rejected", "paused", "flagged", "disabled", "in_appeal", "pending_deletion", "deleted", "unknown" ], "example": "pending" }, "category": { "type": "string", "description": "Template category before the change. Takes the same values as `category`.", "enum": [ "marketing", "authentication", "utility" ], "example": "utility" }, "quality_rating": { "type": [ "string", "null" ], "description": "Template's quality rating before the change, or null when the provider hadn't reported one. Takes the same values as `quality_rating`.", "enum": [ "high", "medium", "low", "unknown", null ], "example": "high" } } }, "WhatsAppTemplateEventData": { "title": "WhatsAppTemplateEventData", "description": "Data of a template event. It carries the template's status, category, and quality rating after the change, and the previous value of the attribute that changed.", "type": "object", "additionalProperties": false, "required": [ "template_uuid", "name", "language", "status", "category", "quality_rating", "previous_attributes" ], "properties": { "template_uuid": { "type": "string", "format": "uuid", "description": "ID of the template, as returned by [Create a WhatsApp template](https://docs.wavix.com/api-reference/whatsapp/create-a-whatsapp-template).", "example": "6b1f3c52-9e0a-4d7b-8a15-c2f4e9d07b38" }, "name": { "type": "string", "description": "Template name.", "example": "order_shipped" }, "language": { "type": "string", "description": "Template language code.", "example": "en_US" }, "status": { "type": "string", "description": "Template review status after the change. Possible values:\n\n- `draft` — The template is created but not yet submitted to the provider.\n- `pending` — The provider is reviewing the template.\n- `approved` — The template is approved and can be sent.\n- `rejected` — The provider rejected the template.\n- `paused` — The provider paused the template.\n- `flagged` — The provider flagged the template. It can still be sent.\n- `disabled` — The template is disabled and can't be sent.\n- `in_appeal` — An appeal of the review decision is in progress.\n- `pending_deletion` — The template is being deleted.\n- `deleted` — The template was deleted.\n- `unknown` — The provider reported a status that Wavix doesn't recognize.", "enum": [ "draft", "pending", "approved", "rejected", "paused", "flagged", "disabled", "in_appeal", "pending_deletion", "deleted", "unknown" ], "example": "approved" }, "category": { "type": "string", "description": "Template category after the change. Possible values:\n\n- `marketing` — Promotions, offers, and other marketing content.\n- `authentication` — One-time passcodes for verifying a user.\n- `utility` — Transactional updates about an order or an account.", "enum": [ "marketing", "authentication", "utility" ], "example": "utility" }, "quality_rating": { "type": [ "string", "null" ], "description": "Template's quality rating after the change, or null when the provider hasn't reported one. Possible values:\n\n- `high` — High quality.\n- `medium` — Medium quality.\n- `low` — Low quality.\n- `unknown` — Not rated yet.", "enum": [ "high", "medium", "low", "unknown", null ], "example": "high" }, "previous_attributes": { "$ref": "#/components/schemas/WhatsAppTemplatePreviousAttributes" } } }, "WhatsAppTemplateApprovedEvent": { "title": "WhatsAppTemplateApprovedEvent", "description": "Event of type `whatsapp.template.approved`. The provider approved one of your templates, so you can send it. Posted to your webhook and returned by [List WhatsApp events](https://docs.wavix.com/api-reference/whatsapp/list-whatsapp-events).", "type": "object", "additionalProperties": false, "required": [ "id", "type", "timestamp", "data" ], "properties": { "id": { "type": "string", "pattern": "^evt_[0-9a-f]{32}$", "description": "Unique ID of the event. It's the same on every delivery attempt and in the event list, so use it to discard duplicates.", "example": "evt_4c6e8a0b2d4f4a6c8e0b2d4f6a8c0e2d" }, "type": { "type": "string", "const": "whatsapp.template.approved", "description": "Type of the event, always `whatsapp.template.approved`.", "example": "whatsapp.template.approved" }, "timestamp": { "type": "string", "format": "date-time", "description": "When the provider reported the change, in ISO 8601 UTC with 6 fractional digits (microseconds). It isn't the delivery time in the `webhook-timestamp` header.", "example": "2026-10-21T09:12:44.000000Z" }, "data": { "$ref": "#/components/schemas/WhatsAppTemplateEventData" } } }, "WhatsAppTemplateRejectedEvent": { "title": "WhatsAppTemplateRejectedEvent", "description": "Event of type `whatsapp.template.rejected`. The provider rejected one of your templates. Posted to your webhook and returned by [List WhatsApp events](https://docs.wavix.com/api-reference/whatsapp/list-whatsapp-events).", "type": "object", "additionalProperties": false, "required": [ "id", "type", "timestamp", "data" ], "properties": { "id": { "type": "string", "pattern": "^evt_[0-9a-f]{32}$", "description": "Unique ID of the event. It's the same on every delivery attempt and in the event list, so use it to discard duplicates.", "example": "evt_4c6e8a0b2d4f4a6c8e0b2d4f6a8c0e2e" }, "type": { "type": "string", "const": "whatsapp.template.rejected", "description": "Type of the event, always `whatsapp.template.rejected`.", "example": "whatsapp.template.rejected" }, "timestamp": { "type": "string", "format": "date-time", "description": "When the provider reported the change, in ISO 8601 UTC with 6 fractional digits (microseconds). It isn't the delivery time in the `webhook-timestamp` header.", "example": "2026-10-21T09:12:44.000000Z" }, "data": { "$ref": "#/components/schemas/WhatsAppTemplateEventData" } } }, "WhatsAppTemplatePausedEvent": { "title": "WhatsAppTemplatePausedEvent", "description": "Event of type `whatsapp.template.paused`. The provider paused one of your templates. Posted to your webhook and returned by [List WhatsApp events](https://docs.wavix.com/api-reference/whatsapp/list-whatsapp-events).", "type": "object", "additionalProperties": false, "required": [ "id", "type", "timestamp", "data" ], "properties": { "id": { "type": "string", "pattern": "^evt_[0-9a-f]{32}$", "description": "Unique ID of the event. It's the same on every delivery attempt and in the event list, so use it to discard duplicates.", "example": "evt_4c6e8a0b2d4f4a6c8e0b2d4f6a8c0e2f" }, "type": { "type": "string", "const": "whatsapp.template.paused", "description": "Type of the event, always `whatsapp.template.paused`.", "example": "whatsapp.template.paused" }, "timestamp": { "type": "string", "format": "date-time", "description": "When the provider reported the change, in ISO 8601 UTC with 6 fractional digits (microseconds). It isn't the delivery time in the `webhook-timestamp` header.", "example": "2026-10-21T09:12:44.000000Z" }, "data": { "$ref": "#/components/schemas/WhatsAppTemplateEventData" } } }, "WhatsAppTemplateDisabledEvent": { "title": "WhatsAppTemplateDisabledEvent", "description": "Event of type `whatsapp.template.disabled`. One of your templates is disabled and can't be sent. Posted to your webhook and returned by [List WhatsApp events](https://docs.wavix.com/api-reference/whatsapp/list-whatsapp-events).", "type": "object", "additionalProperties": false, "required": [ "id", "type", "timestamp", "data" ], "properties": { "id": { "type": "string", "pattern": "^evt_[0-9a-f]{32}$", "description": "Unique ID of the event. It's the same on every delivery attempt and in the event list, so use it to discard duplicates.", "example": "evt_4c6e8a0b2d4f4a6c8e0b2d4f6a8c0e30" }, "type": { "type": "string", "const": "whatsapp.template.disabled", "description": "Type of the event, always `whatsapp.template.disabled`.", "example": "whatsapp.template.disabled" }, "timestamp": { "type": "string", "format": "date-time", "description": "When the provider reported the change, in ISO 8601 UTC with 6 fractional digits (microseconds). It isn't the delivery time in the `webhook-timestamp` header.", "example": "2026-10-21T09:12:44.000000Z" }, "data": { "$ref": "#/components/schemas/WhatsAppTemplateEventData" } } }, "WhatsAppTemplateFlaggedEvent": { "title": "WhatsAppTemplateFlaggedEvent", "description": "Event of type `whatsapp.template.flagged`. Meta flagged one of your templates because of negative feedback. It can still be sent. Posted to your webhook and returned by [List WhatsApp events](https://docs.wavix.com/api-reference/whatsapp/list-whatsapp-events).", "type": "object", "additionalProperties": false, "required": [ "id", "type", "timestamp", "data" ], "properties": { "id": { "type": "string", "pattern": "^evt_[0-9a-f]{32}$", "description": "Unique ID of the event. It's the same on every delivery attempt and in the event list, so use it to discard duplicates.", "example": "evt_4c6e8a0b2d4f4a6c8e0b2d4f6a8c0e33" }, "type": { "type": "string", "const": "whatsapp.template.flagged", "description": "Type of the event, always `whatsapp.template.flagged`.", "example": "whatsapp.template.flagged" }, "timestamp": { "type": "string", "format": "date-time", "description": "When the provider reported the change, in ISO 8601 UTC with 6 fractional digits (microseconds). It isn't the delivery time in the `webhook-timestamp` header.", "example": "2026-10-21T09:12:44.000000Z" }, "data": { "$ref": "#/components/schemas/WhatsAppTemplateEventData" } } }, "WhatsAppTemplateCategoryChangedEvent": { "title": "WhatsAppTemplateCategoryChangedEvent", "description": "Event of type `whatsapp.template.category_changed`. Meta moved one of your templates to another category, which changes the rate of each message sent with it. Posted to your webhook and returned by [List WhatsApp events](https://docs.wavix.com/api-reference/whatsapp/list-whatsapp-events).", "type": "object", "additionalProperties": false, "required": [ "id", "type", "timestamp", "data" ], "properties": { "id": { "type": "string", "pattern": "^evt_[0-9a-f]{32}$", "description": "Unique ID of the event. It's the same on every delivery attempt and in the event list, so use it to discard duplicates.", "example": "evt_6e8a0c2e4a6c4e8a0c2e4a6c8e0a2c4e" }, "type": { "type": "string", "const": "whatsapp.template.category_changed", "description": "Type of the event, always `whatsapp.template.category_changed`.", "example": "whatsapp.template.category_changed" }, "timestamp": { "type": "string", "format": "date-time", "description": "When the provider reported the change, in ISO 8601 UTC with 6 fractional digits (microseconds). It isn't the delivery time in the `webhook-timestamp` header.", "example": "2026-10-21T09:12:44.000000Z" }, "data": { "$ref": "#/components/schemas/WhatsAppTemplateEventData" } } }, "WhatsAppTemplateQualityChangedEvent": { "title": "WhatsAppTemplateQualityChangedEvent", "description": "Event of type `whatsapp.template.quality_changed`. Meta changed the quality rating of one of your templates. Posted to your webhook and returned by [List WhatsApp events](https://docs.wavix.com/api-reference/whatsapp/list-whatsapp-events).", "type": "object", "additionalProperties": false, "required": [ "id", "type", "timestamp", "data" ], "properties": { "id": { "type": "string", "pattern": "^evt_[0-9a-f]{32}$", "description": "Unique ID of the event. It's the same on every delivery attempt and in the event list, so use it to discard duplicates.", "example": "evt_4c6e8a0b2d4f4a6c8e0b2d4f6a8c0e31" }, "type": { "type": "string", "const": "whatsapp.template.quality_changed", "description": "Type of the event, always `whatsapp.template.quality_changed`.", "example": "whatsapp.template.quality_changed" }, "timestamp": { "type": "string", "format": "date-time", "description": "When the provider reported the change, in ISO 8601 UTC with 6 fractional digits (microseconds). It isn't the delivery time in the `webhook-timestamp` header.", "example": "2026-10-21T09:12:44.000000Z" }, "data": { "$ref": "#/components/schemas/WhatsAppTemplateEventData" } } }, "WhatsAppTemplateUpdatedEvent": { "title": "WhatsAppTemplateUpdatedEvent", "description": "Event of type `whatsapp.template.updated`. The status of one of your templates changed to a value that has no event type of its own, such as `pending` or `deleted`. Posted to your webhook and returned by [List WhatsApp events](https://docs.wavix.com/api-reference/whatsapp/list-whatsapp-events).", "type": "object", "additionalProperties": false, "required": [ "id", "type", "timestamp", "data" ], "properties": { "id": { "type": "string", "pattern": "^evt_[0-9a-f]{32}$", "description": "Unique ID of the event. It's the same on every delivery attempt and in the event list, so use it to discard duplicates.", "example": "evt_4c6e8a0b2d4f4a6c8e0b2d4f6a8c0e32" }, "type": { "type": "string", "const": "whatsapp.template.updated", "description": "Type of the event, always `whatsapp.template.updated`.", "example": "whatsapp.template.updated" }, "timestamp": { "type": "string", "format": "date-time", "description": "When the provider reported the change, in ISO 8601 UTC with 6 fractional digits (microseconds). It isn't the delivery time in the `webhook-timestamp` header.", "example": "2026-10-21T09:12:44.000000Z" }, "data": { "$ref": "#/components/schemas/WhatsAppTemplateEventData" } } }, "WhatsAppTemplatesGroupEvent": { "title": "WhatsAppTemplatesGroupEvent", "description": "Event Wavix posts to your webhook of the `templates` group: a change to the status, category, or quality rating of one of your templates, or a test event. The `type` field decides the shape of `data`. Wavix can add event types, so ignore a `type` you don't recognize.", "oneOf": [ { "$ref": "#/components/schemas/WhatsAppTemplateApprovedEvent" }, { "$ref": "#/components/schemas/WhatsAppTemplateRejectedEvent" }, { "$ref": "#/components/schemas/WhatsAppTemplatePausedEvent" }, { "$ref": "#/components/schemas/WhatsAppTemplateDisabledEvent" }, { "$ref": "#/components/schemas/WhatsAppTemplateFlaggedEvent" }, { "$ref": "#/components/schemas/WhatsAppTemplateCategoryChangedEvent" }, { "$ref": "#/components/schemas/WhatsAppTemplateQualityChangedEvent" }, { "$ref": "#/components/schemas/WhatsAppTemplateUpdatedEvent" }, { "$ref": "#/components/schemas/WhatsAppWebhookTestEvent" } ], "discriminator": { "propertyName": "type", "mapping": { "whatsapp.template.approved": "#/components/schemas/WhatsAppTemplateApprovedEvent", "whatsapp.template.rejected": "#/components/schemas/WhatsAppTemplateRejectedEvent", "whatsapp.template.paused": "#/components/schemas/WhatsAppTemplatePausedEvent", "whatsapp.template.disabled": "#/components/schemas/WhatsAppTemplateDisabledEvent", "whatsapp.template.flagged": "#/components/schemas/WhatsAppTemplateFlaggedEvent", "whatsapp.template.category_changed": "#/components/schemas/WhatsAppTemplateCategoryChangedEvent", "whatsapp.template.quality_changed": "#/components/schemas/WhatsAppTemplateQualityChangedEvent", "whatsapp.template.updated": "#/components/schemas/WhatsAppTemplateUpdatedEvent", "test": "#/components/schemas/WhatsAppWebhookTestEvent" } } }, "WhatsAppSenderPreviousAttributes": { "title": "WhatsAppSenderPreviousAttributes", "description": "Value that the changed attribute of a sender had before the change. It holds only that attribute — `quality_rating` for `whatsapp.sender.quality_changed`, and `status` for every other sender event.", "type": "object", "additionalProperties": false, "required": [], "properties": { "status": { "type": "string", "description": "Sender registration status before the change. Takes the same values as `status`.", "enum": [ "banned", "connected", "deleted", "disconnected", "flagged", "migrated", "pending", "rate_limited", "restricted", "unknown", "unverified" ], "example": "pending" }, "quality_rating": { "type": [ "string", "null" ], "description": "Sender's quality rating before the change, or null when the provider hadn't reported one. Takes the same values as `quality_rating`.", "enum": [ "high", "medium", "low", "unknown", null ], "example": "high" } } }, "WhatsAppSenderEventData": { "title": "WhatsAppSenderEventData", "description": "Data of a sender event. It carries the sender's status and quality rating after the change, and the previous value of the attribute that changed.", "type": "object", "additionalProperties": false, "required": [ "phone_number", "status", "quality_rating", "previous_attributes" ], "properties": { "phone_number": { "type": "string", "description": "Sender's phone number in E.164 format.", "example": "+14155550100" }, "status": { "type": "string", "description": "Sender registration status after the change. Possible values:\n\n- `banned` — The provider banned the sender.\n- `connected` — The sender can send messages within its messaging limit.\n- `deleted` — The sender was deleted.\n- `disconnected` — The sender is disconnected from the provider.\n- `flagged` — The sender's quality rating dropped to low. The status returns to `connected` if the rating returns to medium or high within 7 days.\n- `migrated` — The sender was migrated.\n- `pending` — Registration with the provider is in progress.\n- `rate_limited` — The provider is rate limiting the sender.\n- `restricted` — The sender reached its messaging limit. It can't start new conversations until the 24-hour window resets, but it can still reply to customers who messaged it.\n- `unknown` — The provider hasn't reported a status.\n- `unverified` — The sender isn't verified.", "enum": [ "banned", "connected", "deleted", "disconnected", "flagged", "migrated", "pending", "rate_limited", "restricted", "unknown", "unverified" ], "example": "connected" }, "quality_rating": { "type": [ "string", "null" ], "description": "Sender's quality rating after the change, or null when the provider hasn't reported one. Meta rates quality from customer feedback over the past 7 days, such as blocks and reports. Possible values:\n\n- `high` — High quality.\n- `medium` — Medium quality.\n- `low` — Low quality.\n- `unknown` — Not rated yet, or the provider reported a rating that Wavix doesn't recognize.", "enum": [ "high", "medium", "low", "unknown", null ], "example": "high" }, "previous_attributes": { "$ref": "#/components/schemas/WhatsAppSenderPreviousAttributes" } } }, "WhatsAppSenderConnectedEvent": { "title": "WhatsAppSenderConnectedEvent", "description": "Event of type `whatsapp.sender.connected`. One of your senders can send messages within its messaging limit, for example after registration or when a restriction ends. Posted to your webhook and returned by [List WhatsApp events](https://docs.wavix.com/api-reference/whatsapp/list-whatsapp-events).", "type": "object", "additionalProperties": false, "required": [ "id", "type", "timestamp", "data" ], "properties": { "id": { "type": "string", "pattern": "^evt_[0-9a-f]{32}$", "description": "Unique ID of the event. It's the same on every delivery attempt and in the event list, so use it to discard duplicates.", "example": "evt_9e1a3c5e7a9c4e1a3c5e7a9c1e3a5c7e" }, "type": { "type": "string", "const": "whatsapp.sender.connected", "description": "Type of the event, always `whatsapp.sender.connected`.", "example": "whatsapp.sender.connected" }, "timestamp": { "type": "string", "format": "date-time", "description": "When Wavix detected the change, in ISO 8601 UTC with 6 fractional digits (microseconds). It isn't the delivery time in the `webhook-timestamp` header.", "example": "2026-10-21T09:20:10.000000Z" }, "data": { "$ref": "#/components/schemas/WhatsAppSenderEventData" } } }, "WhatsAppSenderRestrictedEvent": { "title": "WhatsAppSenderRestrictedEvent", "description": "Event of type `whatsapp.sender.restricted`. One of your senders reached its messaging limit. It can't start new conversations until the 24-hour window resets. Posted to your webhook and returned by [List WhatsApp events](https://docs.wavix.com/api-reference/whatsapp/list-whatsapp-events).", "type": "object", "additionalProperties": false, "required": [ "id", "type", "timestamp", "data" ], "properties": { "id": { "type": "string", "pattern": "^evt_[0-9a-f]{32}$", "description": "Unique ID of the event. It's the same on every delivery attempt and in the event list, so use it to discard duplicates.", "example": "evt_9e1a3c5e7a9c4e1a3c5e7a9c1e3a5c7f" }, "type": { "type": "string", "const": "whatsapp.sender.restricted", "description": "Type of the event, always `whatsapp.sender.restricted`.", "example": "whatsapp.sender.restricted" }, "timestamp": { "type": "string", "format": "date-time", "description": "When Wavix detected the change, in ISO 8601 UTC with 6 fractional digits (microseconds). It isn't the delivery time in the `webhook-timestamp` header.", "example": "2026-10-21T09:20:10.000000Z" }, "data": { "$ref": "#/components/schemas/WhatsAppSenderEventData" } } }, "WhatsAppSenderFlaggedEvent": { "title": "WhatsAppSenderFlaggedEvent", "description": "Event of type `whatsapp.sender.flagged`. The quality rating of one of your senders dropped to low. Posted to your webhook and returned by [List WhatsApp events](https://docs.wavix.com/api-reference/whatsapp/list-whatsapp-events).", "type": "object", "additionalProperties": false, "required": [ "id", "type", "timestamp", "data" ], "properties": { "id": { "type": "string", "pattern": "^evt_[0-9a-f]{32}$", "description": "Unique ID of the event. It's the same on every delivery attempt and in the event list, so use it to discard duplicates.", "example": "evt_9e1a3c5e7a9c4e1a3c5e7a9c1e3a5c80" }, "type": { "type": "string", "const": "whatsapp.sender.flagged", "description": "Type of the event, always `whatsapp.sender.flagged`.", "example": "whatsapp.sender.flagged" }, "timestamp": { "type": "string", "format": "date-time", "description": "When Wavix detected the change, in ISO 8601 UTC with 6 fractional digits (microseconds). It isn't the delivery time in the `webhook-timestamp` header.", "example": "2026-10-21T09:20:10.000000Z" }, "data": { "$ref": "#/components/schemas/WhatsAppSenderEventData" } } }, "WhatsAppSenderBannedEvent": { "title": "WhatsAppSenderBannedEvent", "description": "Event of type `whatsapp.sender.banned`. The provider banned one of your senders. Posted to your webhook and returned by [List WhatsApp events](https://docs.wavix.com/api-reference/whatsapp/list-whatsapp-events).", "type": "object", "additionalProperties": false, "required": [ "id", "type", "timestamp", "data" ], "properties": { "id": { "type": "string", "pattern": "^evt_[0-9a-f]{32}$", "description": "Unique ID of the event. It's the same on every delivery attempt and in the event list, so use it to discard duplicates.", "example": "evt_9e1a3c5e7a9c4e1a3c5e7a9c1e3a5c81" }, "type": { "type": "string", "const": "whatsapp.sender.banned", "description": "Type of the event, always `whatsapp.sender.banned`.", "example": "whatsapp.sender.banned" }, "timestamp": { "type": "string", "format": "date-time", "description": "When Wavix detected the change, in ISO 8601 UTC with 6 fractional digits (microseconds). It isn't the delivery time in the `webhook-timestamp` header.", "example": "2026-10-21T09:20:10.000000Z" }, "data": { "$ref": "#/components/schemas/WhatsAppSenderEventData" } } }, "WhatsAppSenderDisconnectedEvent": { "title": "WhatsAppSenderDisconnectedEvent", "description": "Event of type `whatsapp.sender.disconnected`. One of your senders is disconnected from the provider. Posted to your webhook and returned by [List WhatsApp events](https://docs.wavix.com/api-reference/whatsapp/list-whatsapp-events).", "type": "object", "additionalProperties": false, "required": [ "id", "type", "timestamp", "data" ], "properties": { "id": { "type": "string", "pattern": "^evt_[0-9a-f]{32}$", "description": "Unique ID of the event. It's the same on every delivery attempt and in the event list, so use it to discard duplicates.", "example": "evt_9e1a3c5e7a9c4e1a3c5e7a9c1e3a5c82" }, "type": { "type": "string", "const": "whatsapp.sender.disconnected", "description": "Type of the event, always `whatsapp.sender.disconnected`.", "example": "whatsapp.sender.disconnected" }, "timestamp": { "type": "string", "format": "date-time", "description": "When Wavix detected the change, in ISO 8601 UTC with 6 fractional digits (microseconds). It isn't the delivery time in the `webhook-timestamp` header.", "example": "2026-10-21T09:20:10.000000Z" }, "data": { "$ref": "#/components/schemas/WhatsAppSenderEventData" } } }, "WhatsAppSenderQualityChangedEvent": { "title": "WhatsAppSenderQualityChangedEvent", "description": "Event of type `whatsapp.sender.quality_changed`. Meta changed the quality rating of one of your senders. Posted to your webhook and returned by [List WhatsApp events](https://docs.wavix.com/api-reference/whatsapp/list-whatsapp-events).", "type": "object", "additionalProperties": false, "required": [ "id", "type", "timestamp", "data" ], "properties": { "id": { "type": "string", "pattern": "^evt_[0-9a-f]{32}$", "description": "Unique ID of the event. It's the same on every delivery attempt and in the event list, so use it to discard duplicates.", "example": "evt_3c5e7a9c1e3a4c5e7a9c1e3a5c7e9a1c" }, "type": { "type": "string", "const": "whatsapp.sender.quality_changed", "description": "Type of the event, always `whatsapp.sender.quality_changed`.", "example": "whatsapp.sender.quality_changed" }, "timestamp": { "type": "string", "format": "date-time", "description": "When Wavix detected the change, in ISO 8601 UTC with 6 fractional digits (microseconds). It isn't the delivery time in the `webhook-timestamp` header.", "example": "2026-10-21T09:20:10.000000Z" }, "data": { "$ref": "#/components/schemas/WhatsAppSenderEventData" } } }, "WhatsAppSenderUpdatedEvent": { "title": "WhatsAppSenderUpdatedEvent", "description": "Event of type `whatsapp.sender.updated`. The status of one of your senders changed to a value that has no event type of its own, such as `pending` or `deleted`. Posted to your webhook and returned by [List WhatsApp events](https://docs.wavix.com/api-reference/whatsapp/list-whatsapp-events).", "type": "object", "additionalProperties": false, "required": [ "id", "type", "timestamp", "data" ], "properties": { "id": { "type": "string", "pattern": "^evt_[0-9a-f]{32}$", "description": "Unique ID of the event. It's the same on every delivery attempt and in the event list, so use it to discard duplicates.", "example": "evt_9e1a3c5e7a9c4e1a3c5e7a9c1e3a5c83" }, "type": { "type": "string", "const": "whatsapp.sender.updated", "description": "Type of the event, always `whatsapp.sender.updated`.", "example": "whatsapp.sender.updated" }, "timestamp": { "type": "string", "format": "date-time", "description": "When Wavix detected the change, in ISO 8601 UTC with 6 fractional digits (microseconds). It isn't the delivery time in the `webhook-timestamp` header.", "example": "2026-10-21T09:20:10.000000Z" }, "data": { "$ref": "#/components/schemas/WhatsAppSenderEventData" } } }, "WhatsAppSendersGroupEvent": { "title": "WhatsAppSendersGroupEvent", "description": "Event Wavix posts to your webhook of the `senders` group: a change to the status or quality rating of one of your senders, or a test event. The `type` field decides the shape of `data`. Wavix can add event types, so ignore a `type` you don't recognize.", "oneOf": [ { "$ref": "#/components/schemas/WhatsAppSenderConnectedEvent" }, { "$ref": "#/components/schemas/WhatsAppSenderRestrictedEvent" }, { "$ref": "#/components/schemas/WhatsAppSenderFlaggedEvent" }, { "$ref": "#/components/schemas/WhatsAppSenderBannedEvent" }, { "$ref": "#/components/schemas/WhatsAppSenderDisconnectedEvent" }, { "$ref": "#/components/schemas/WhatsAppSenderQualityChangedEvent" }, { "$ref": "#/components/schemas/WhatsAppSenderUpdatedEvent" }, { "$ref": "#/components/schemas/WhatsAppWebhookTestEvent" } ], "discriminator": { "propertyName": "type", "mapping": { "whatsapp.sender.connected": "#/components/schemas/WhatsAppSenderConnectedEvent", "whatsapp.sender.restricted": "#/components/schemas/WhatsAppSenderRestrictedEvent", "whatsapp.sender.flagged": "#/components/schemas/WhatsAppSenderFlaggedEvent", "whatsapp.sender.banned": "#/components/schemas/WhatsAppSenderBannedEvent", "whatsapp.sender.disconnected": "#/components/schemas/WhatsAppSenderDisconnectedEvent", "whatsapp.sender.quality_changed": "#/components/schemas/WhatsAppSenderQualityChangedEvent", "whatsapp.sender.updated": "#/components/schemas/WhatsAppSenderUpdatedEvent", "test": "#/components/schemas/WhatsAppWebhookTestEvent" } } } }, "responses": { "UnauthorizedErrorResponse": { "description": "Unauthorized", "headers": {}, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/UnauthorizedErrorResponse" } } } }, "ForbiddenErrorResponse": { "description": "Request failed. The feature is disabled for your account.", "headers": {}, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ForbiddenErrorResponse" } } } }, "BadRequestErrorResponse": { "description": "Request failed. Missing or invalid parameter ", "headers": {}, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ValidationErrorResponse" } } } }, "NotFoundErrorResponse": { "description": "Request failed. An object with the specified ID is not found.", "headers": {}, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/NotFoundErrorResponse" } } } }, "ValidationErrorResponse": { "description": "Validation error", "headers": {}, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ValidationErrorResponse" } } } }, "CountryHasNoRegionsErrorResponse": { "description": "Country has no states or provinces", "headers": {}, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/CountryHasNoRegionsErrorResponse" } } } }, "WebhookInUseErrorResponse": { "description": "Request failed. The webhook has a different URL than `expected_url` or `expected_sms_relay_url`; nothing was changed.", "headers": {}, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/WebhookInUseErrorResponse" } } } }, "TooManyRequestsErrorResponse": { "description": "Too many requests", "headers": { "Retry-After": { "description": "Number of seconds to wait before retrying the request.", "schema": { "type": "integer", "example": 30 } } }, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/TooManyRequestsErrorResponse" } } } }, "WhatsAppUnauthorizedResponse": { "description": "Authentication failed or wasn't provided, or the account is suspended, blocked, or has no subscription plan.", "headers": {}, "content": { "application/problem+json": { "schema": { "$ref": "#/components/schemas/WhatsAppProblem" }, "examples": { "authentication-required": { "summary": "The API key or token is missing or isn't valid", "value": { "type": "https://docs.wavix.com/errors/authentication-required", "title": "Authentication Required", "status": 401, "detail": "Authentication is required to access this resource.", "instance": "3a525ca2-6909-4c72-9399-905adf7f3a74", "error_class": "permanent", "error_code": "AUTHENTICATION_REQUIRED" } }, "account-suspended": { "summary": "The account is suspended", "value": { "type": "https://docs.wavix.com/errors/authentication-required", "title": "Authentication Required", "status": 401, "detail": "The account is suspended.", "instance": "3a525ca2-6909-4c72-9399-905adf7f3a74", "error_class": "permanent", "error_code": "AUTHENTICATION_REQUIRED" } }, "account-blocked": { "summary": "The account is blocked", "value": { "type": "https://docs.wavix.com/errors/authentication-required", "title": "Authentication Required", "status": 401, "detail": "The account is blocked.", "instance": "3a525ca2-6909-4c72-9399-905adf7f3a74", "error_class": "permanent", "error_code": "AUTHENTICATION_REQUIRED" } }, "account-without-plan": { "summary": "The account has no subscription plan", "value": { "type": "https://docs.wavix.com/errors/authentication-required", "title": "Authentication Required", "status": 401, "detail": "The account has no subscription plan.", "instance": "3a525ca2-6909-4c72-9399-905adf7f3a74", "error_class": "permanent", "error_code": "AUTHENTICATION_REQUIRED" } } } } } }, "WhatsAppForbiddenResponse": { "description": "Returns when the API key doesn't have the scope the operation needs, or the request isn't allowed for the account's region.", "headers": {}, "content": { "application/problem+json": { "schema": { "$ref": "#/components/schemas/WhatsAppProblem" }, "examples": { "access-denied": { "value": { "type": "https://docs.wavix.com/errors/access-denied", "title": "Access Denied", "status": 403, "detail": "The API key has no access to this resource.", "instance": "3a525ca2-6909-4c72-9399-905adf7f3a74", "error_class": "permanent", "error_code": "ACCESS_DENIED" } } } } } }, "WhatsAppChannelUnavailableResponse": { "description": "WhatsApp isn't available for your account, or the WhatsApp channel isn't enabled for it yet.", "content": { "application/problem+json": { "schema": { "$ref": "#/components/schemas/WhatsAppProblem" }, "examples": { "whatsapp-not-available": { "summary": "WhatsApp is not available for this account", "value": { "type": "https://docs.wavix.com/errors/whatsapp-not-available", "title": "WhatsApp Not Available", "status": 404, "detail": "WhatsApp is not available for this account.", "instance": "3a525ca2-6909-4c72-9399-905adf7f3a74", "error_class": "permanent", "error_code": "WHATSAPP_NOT_AVAILABLE" } }, "channel-not-enabled": { "summary": "WhatsApp is not enabled yet for this account", "value": { "type": "https://docs.wavix.com/errors/channel-not-enabled", "title": "Channel Not Enabled", "status": 404, "detail": "The WhatsApp channel is not enabled for this account.", "instance": "3a525ca2-6909-4c72-9399-905adf7f3a74", "error_class": "permanent", "error_code": "CHANNEL_NOT_ENABLED" } } } } } }, "WhatsAppTooManyRequestsResponse": { "description": "Returns when the account has exceeded its request rate limit.", "headers": { "Retry-After": { "description": "Number of seconds to wait before retrying the request.", "schema": { "type": "integer", "example": 30 } } }, "content": { "application/problem+json": { "schema": { "$ref": "#/components/schemas/WhatsAppProblem" }, "examples": { "rate-limited": { "value": { "type": "https://docs.wavix.com/errors/rate-limited", "title": "Rate Limited", "status": 429, "detail": "Too many requests. Try again later.", "instance": "3a525ca2-6909-4c72-9399-905adf7f3a74", "error_class": "rate_limited", "error_code": "RATE_LIMITED" } } } } } }, "WhatsAppInternalServerErrorResponse": { "description": "Returns when an unexpected error occurs on the server; the request may be retried.", "headers": {}, "content": { "application/problem+json": { "schema": { "$ref": "#/components/schemas/WhatsAppProblem" }, "examples": { "internal-error": { "value": { "type": "https://docs.wavix.com/errors/internal-error", "title": "Internal Error", "status": 500, "detail": "Internal Error", "instance": "3a525ca2-6909-4c72-9399-905adf7f3a74", "error_class": "retriable", "error_code": "INTERNAL_ERROR" } } } } } }, "WhatsAppServiceUnavailableResponse": { "description": "Returns when the service is temporarily unavailable; the request may be retried.", "content": { "application/problem+json": { "schema": { "$ref": "#/components/schemas/WhatsAppProblem" }, "examples": { "service-unavailable": { "value": { "type": "https://docs.wavix.com/errors/service-unavailable", "title": "Service Unavailable", "status": 503, "detail": "The service is temporarily unavailable.", "instance": "3a525ca2-6909-4c72-9399-905adf7f3a74", "error_class": "retriable", "error_code": "SERVICE_UNAVAILABLE" } } } } } }, "WhatsAppBadRequestResponse": { "description": "The `direction`, `from`, or `to` query parameter is invalid. The `detail` field says which one.", "headers": {}, "content": { "application/problem+json": { "schema": { "$ref": "#/components/schemas/WhatsAppProblem" }, "examples": { "invalid-request": { "value": { "type": "https://docs.wavix.com/errors/invalid-request", "title": "Invalid Request", "status": 400, "detail": "direction must be inbound or outbound", "instance": "3a525ca2-6909-4c72-9399-905adf7f3a74", "error_class": "permanent", "error_code": "INVALID_REQUEST" } } } } } } }, "parameters": { "WhatsAppPageParam": { "name": "page", "in": "query", "description": "Page number to retrieve. Page numbering starts at 1. Defaults to 1.", "schema": { "type": "integer", "format": "int32", "default": 1 }, "example": 1 }, "WhatsAppPerPageParam": { "name": "per_page", "in": "query", "description": "Number of records to return per page. Defaults to 25. Values above 100 are treated as 100.", "schema": { "type": "integer", "format": "int32", "default": 25 }, "example": 25 }, "WhatsAppWebhookIdHeader": { "name": "webhook-id", "in": "header", "required": true, "description": "ID of the event, the same as `id` in the body. It's the same on every delivery attempt and is part of the signed content.", "schema": { "type": "string", "pattern": "^evt_[0-9a-f]{32}$" }, "example": "evt_3f6c0f5e9b2a4d7c8e1f0a2b3c4d5e6f" }, "WhatsAppWebhookTimestampHeader": { "name": "webhook-timestamp", "in": "header", "required": true, "description": "Time this attempt was sent, in Unix seconds. It's part of the signed content and changes on every attempt. Reject a request whose timestamp is more than 5 minutes away from your clock.", "schema": { "type": "integer", "format": "int64" }, "example": 1792571400 }, "WhatsAppWebhookSignatureHeader": { "name": "webhook-signature", "in": "header", "required": true, "description": "Space-separated signatures, each `v1,` plus the Base64 HMAC-SHA256 of `webhook-id`, `webhook-timestamp`, and the raw body joined by periods. The key is the Base64-decoded secret without `whsec_`.", "schema": { "type": "string", "pattern": "^v1,[A-Za-z0-9+/]{43}=( v1,[A-Za-z0-9+/]{43}=)*$" }, "example": "v1,rnhX+FJ2ZEwDslc495Cj7SxoGvZxHD8Ia/jpaEt0XqM=" } } } }