### Get Modem Full Info - JSON Example Source: https://www.smseagle.eu/docs/apiv2/index Fetches comprehensive details for a specific modem, including its status, signal strength, network information, and SIM card details. Requires the modem number as a path parameter. The response is a JSON array of modem objects. ```json [ { "modem_no": 1, "modem_enabled": true, "signal_strength": 57, "net_name": "T-Mobile 4G", "sim_status": "Operational", "sim_network_registration_status": "Registered Home", "imei": 123789456987, "imsi": 123789323987, "number": 123654789 } ] ``` -------------------------------- ### Get Voices List Response Sample Source: https://www.smseagle.eu/docs/apiv2/index This JSON example demonstrates the response format for the 'Get voices list' endpoint. It returns a list of voice objects, each containing an ID, name, locale name, language, quality setting, ONNX file path, ONNX JSON file path, creator ID, and insertion date. This structure is crucial for clients integrating with the voice management features. ```json [ { "id": 12, "name": "Dave", "locale_name": "es_ES", "language": "Spanish", "quality": "medium", "onnx_file": "123abc456def.onnx", "onnx_json_file": "123abc456def.onnx.json", "creator_id": 2, "insert_date": "2022-02-15T13:41:49+00:00" } ] ``` -------------------------------- ### Send SMS Request Example - C# Source: https://www.smseagle.eu/docs/apiv2/index Example of how to send an SMS using C#. This snippet shows the process of creating the request body and invoking the API. ```csharp // C# sample not provided in the input text. ``` -------------------------------- ### Send SMS Request Example - PHP Source: https://www.smseagle.eu/docs/apiv2/index Example of how to send an SMS using PHP. This snippet illustrates how to prepare the request data and send it to the smseagle API. ```php // PHP sample not provided in the input text. ``` -------------------------------- ### Send SMS Request Example - C++ Source: https://www.smseagle.eu/docs/apiv2/index Example of how to send an SMS using C++. This snippet demonstrates constructing the request payload and making the HTTP POST request to the API endpoint. ```cpp // C++ sample not provided in the input text. ``` -------------------------------- ### Send SMS Request Example - Powershell Source: https://www.smseagle.eu/docs/apiv2/index Example of sending an SMS using Powershell. This script demonstrates making an HTTP request with a JSON body to the API. ```powershell // Powershell sample not provided in the input text. ``` -------------------------------- ### Send SMS Request Example - Java Source: https://www.smseagle.eu/docs/apiv2/index Example of how to send an SMS using Java. This snippet would demonstrate making an HTTP POST request with the JSON payload using libraries like Apache HttpClient or OkHttp. ```java // Java sample not provided in the input text. ``` -------------------------------- ### Send SMS Request Example - Shell Source: https://www.smseagle.eu/docs/apiv2/index Example of sending an SMS using a shell script. This could involve using tools like `curl` to interact with the API. ```bash # Shell sample not provided in the input text. ``` -------------------------------- ### Get SIM Network Registration Status (JSON) Source: https://www.smseagle.eu/docs/apiv2/index Obtains the network registration status of the SIM card for a given modem. The output includes the modem number and its registration status, for example, 'Registered Home'. ```json { "modem_no": 2, "sim_network_registration_status": "Registered Home" } ``` -------------------------------- ### Get Modem Phone Number - JSON Example Source: https://www.smseagle.eu/docs/apiv2/index Retrieves the phone number associated with a specific modem. Returns a JSON object containing the modem number and its corresponding phone number. Requires the modem number as a path parameter. ```json { "modem_no": 2, "number": "123654789" } ``` -------------------------------- ### Send SMS Request Example - VBA Source: https://www.smseagle.eu/docs/apiv2/index Example of sending an SMS using VBA (Visual Basic for Applications). This snippet would typically involve using WinHTTP or similar to make the web request. ```vba ' VBA sample not provided in the input text. ``` -------------------------------- ### Send SMS Request Example - cURL Source: https://www.smseagle.eu/docs/apiv2/index Example of sending an SMS using cURL. This command-line snippet shows how to POST a JSON payload to the SMS Eagle API. ```bash // cURL sample not provided in the input text. ``` -------------------------------- ### Get Wave Files List Response Sample Source: https://www.smseagle.eu/docs/apiv2/index This JSON snippet shows a sample response for the 'Get wave files list' endpoint. It returns an array of objects, where each object represents a wave file with its ID, name, the associated wave file name, creator ID, and insertion date. This helps in understanding the structure of wave file data returned by the API. ```json [ { "id": 12, "name": "AudioTest", "wave_file": "123abc456def.wav", "creator_id": 2, "insert_date": "2022-02-15T13:41:49+00:00" } ] ``` -------------------------------- ### Send SMS Request Payload Example Source: https://www.smseagle.eu/docs/apiv2/index Example of the JSON payload for sending an SMS message. It includes fields for recipients, message content, scheduling, priority, encoding, and other message-specific options. ```json { "to": [ "+48123456789" ], "contacts": [ 12, 15 ], "groups": [ 57, 35 ], "text": "Lorem ipsum dolor sit amet", "date": "2022-12-27T12:20:31+05:01", "priority": 5, "encoding": "unicode", "flash": true, "oid": "123abc456def789ghi123abc456def789ghi", "validity": "30m", "send_after": "12:05", "send_before": "17:15", "test": true, "modem_no": 2 } ``` -------------------------------- ### Send SMS Request Example - Python Source: https://www.smseagle.eu/docs/apiv2/index Example of how to send an SMS using Python. This code snippet would typically use the 'requests' library to send a POST request with the JSON payload. ```python # Python sample not provided in the input text. ``` -------------------------------- ### Get ElevenLabs Voices List Response Sample Source: https://www.smseagle.eu/docs/apiv2/index This JSON output illustrates a sample response from the 'Get voices list for ElevenLabs' endpoint. Each voice object includes its ID, name, ElevenLabs voice ID, locale name, accent, creator ID, and insertion date. This format is specific to ElevenLabs voices managed through the gateway. ```json [ { "id": 12, "name": "Raju", "voice_id": "pzxut4zZz4GImZNlqQ3H", "locale_name": "en", "accent": "Indian", "creator_id": 2, "insert_date": "2022-02-15T13:41:49+00:00" } ] ``` -------------------------------- ### Send SMS Message with C++ Source: https://www.smseagle.eu/docs/apiv2/openapi This C++ code snippet demonstrates how to send an SMS message using the SMS Eagle API v2. It utilizes the libcurl library for making HTTP requests. The example shows how to construct a JSON payload with various message parameters and send it to the API endpoint. Ensure libcurl is installed and linked correctly. ```C++ #include #include #include int main(void) { CURL *curl; CURLcode res; using namespace std; curl = curl_easy_init(); if(curl) { char const *path = "https://smseagleip/index.php/api/v2/messages/sms"; curl_easy_setopt(curl, CURLOPT_URL, path); string jsonPayload = R"({ "to": ["+4812345678"], "contacts": [12,15], "groups": [57,35], "text": "my message", "date": "2022-12-27T12:20:31+05:01", "priority": 5, "encoding": "unicode", "flash": true, "oid": "123abc456def789ghi123abc456def789ghi", "validity": "30m", "send_after": "12:05", "send_before": "17:15", "test": true, "modem_no": 2 })"; struct curl_slist* headers = NULL; headers = curl_slist_append(headers, "Content-Type: application/json"); headers = curl_slist_append(headers, "access-token: 0005gOjCOlMH8F2BP8"); curl_easy_setopt(curl, CURLOPT_HTTPHEADER, headers); curl_easy_setopt(curl, CURLOPT_POSTFIELDS, jsonPayload.c_str()); res = curl_easy_perform(curl); if(res != CURLE_OK) fprintf(stderr, "curl_easy_perform() failed: %s\n", curl_easy_strerror(res)); curl_easy_cleanup(curl); } return 0; } ``` -------------------------------- ### GET /api/v2/modem/full_info/{modem_no} Source: https://www.smseagle.eu/docs/apiv2/index Fetches comprehensive information for a specified modem, including its status, signal strength, and network details. ```APIDOC ## Get Modem Full Info ### Description Retrieves detailed information for all or selected modems. ### Method GET ### Endpoint `/api/v2/modem/full_info/{modem_no}` ### Parameters #### Path Parameters - **modem_no** (integer) - Required - Modem number. Example: 2 ### Request Example ```json { "modem_no": 1, "modem_enabled": true, "signal_strength": 57, "net_name": "T-Mobile 4G", "sim_status": "Operational", "sim_network_registration_status": "Registered Home", "imei": 123789456987, "imsi": 123789323987, "number": 123654789 } ``` ### Response #### Success Response (200) - **modem_no** (integer) - Modem number. - **modem_enabled** (boolean) - Indicates if the modem is enabled. - **signal_strength** (integer) - The signal strength of the modem. - **net_name** (string) - The network name the modem is connected to. - **sim_status** (string) - The status of the SIM card. - **sim_network_registration_status** (string) - The network registration status of the SIM. - **imei** (integer) - The IMEI of the modem. - **imsi** (integer) - The IMSI of the modem. - **number** (integer) - The phone number associated with the modem. #### Response Example ```json [ { "modem_no": 1, "modem_enabled": true, "signal_strength": 57, "net_name": "T-Mobile 4G", "sim_status": "Operational", "sim_network_registration_status": "Registered Home", "imei": 123789456987, "imsi": 123789323987, "number": 123654789 } ] ``` ``` -------------------------------- ### GET /modem/full_info/{modem_no} Source: https://www.smseagle.eu/docs/apiv2/openapi Retrieves comprehensive information about a specific modem or all modems. You can filter by modem number. ```APIDOC ## GET /modem/full_info/{modem_no} ### Description Get full info from all or selected modem. ### Method GET ### Endpoint /modem/full_info/{modem_no} ### Parameters #### Path Parameters - **modem_no** (integer) - Optional - Modem number. Example: 2, Minimum: 1, Maximum: 8 ### Request Example ```json { "example": "No request body needed for this GET request." } ``` ### Response #### Success Response (200) - **ModemFullInfo** (object) - Full information about the modem(s). #### Response Example ```json { "example": "Schema reference: #/components/schemas/ModemFullInfo" } ``` ``` -------------------------------- ### GET /calls/waves Source: https://www.smseagle.eu/docs/apiv2/openapi Retrieves a list of all uploaded wave files. Supports filtering by ID, name, and other criteria. ```APIDOC ## GET /calls/waves ### Description List all uploaded wave files. Supports filtering by ID and name. ### Method GET ### Endpoint /calls/waves ### Parameters #### Query Parameters - **id_from** (integer) - Optional - Minimal ID of wave file. - **id_to** (integer) - Optional - Maximal ID of wave file. - **name** (string) - Optional - Wave file name. ### Response #### Success Response (200) - **WavesResponse** - A schema defining the structure of the wave files list response. #### Response Example (Response structure depends on the `#/components/schemas/WavesResponse` schema) ``` -------------------------------- ### GET /messages/whatsapp/{folder} Source: https://www.smseagle.eu/docs/apiv2/openapi Retrieves WhatsApp messages from a specified folder. Supports filtering by ID, date, sender, and other criteria. ```APIDOC ## GET /messages/whatsapp/{folder} ### Description Read WhatsApp messages from specified folder. Supports filtering by ID, date, sender, and other criteria. ### Method GET ### Endpoint `/messages/whatsapp/{folder}` ### Parameters #### Path Parameters - **folder** (string) - Required - Folder's name to read messages from. Allowed values: inbox, outbox, sent, error. #### Query Parameters - **id_from** (integer) - Optional - Minimal ID of message. - **id_to** (integer) - Optional - Maximal ID of message. - **number** (string) - Optional - Telephone number of message sender or receiver. - **date_from** (string) - Optional - Show only messages sent/received on this date/time and later. Format: 'YYYY-MM-DDThh:mm:ssZ'. Examples: '2022-12-27T12:20:31', '2022-12-27T12:20:31Z', '2022-12-27T12:20:31+05:01'. - **date_to** (string) - Optional - Show only messages sent/received on this date/time and earlier. Format: 'YYYY-MM-DDThh:mm:ssZ'. Examples: '2022-12-27T12:20:31', '2022-12-27T12:20:31Z', '2022-12-27T12:20:31+05:01'. - **limit** (integer) - Optional - How many messages to show. Minimum: 1. Example: 7. - **unread** (boolean) - Optional - Show only unread messages (for inbox folder). Allowed values: 0, 1. Default: 0. - **sender_id** (integer) - Optional - ID of a SMSEagle sender. Examples: 12, 56. - **attachments** (boolean) - Optional - Show base64 encoded attachments. Allowed values: 0, 1. Default: 0. ### Request Example ```json { "example": "GET /messages/whatsapp/inbox?limit=10&unread=1" } ``` ### Response #### Success Response (200) - **WhatsAppSent** (object) - Schema containing message details. #### Response Example ```json { "example": "{\"id\": 1, \"to\": \"123456789\", \"from\": \"987654321\", \"date\": \"2023-01-01T10:00:00Z\", \"content\": \"Hello!\", \"status\": \"sent\", \"read\": false}" } ``` #### Error Responses - **400** - Bad request. Example: `{"message": {"date_from": "Wrong date format."}}` - **401** - Unauthorized - **403** - Forbidden - **404** - Not Found - **405** - Method Not Allowed - **500** - Internal Server Error ``` -------------------------------- ### Get SMS Used Count - JSON Example Source: https://www.smseagle.eu/docs/apiv2/index Retrieves the count of sent or received SMS messages for a specified folder (inbox or sent) within a given date range. Supports filtering by modem number and user ID. The response is a JSON object indicating the count for the specified folder. ```json { "inbox": 4 } ``` -------------------------------- ### POST /api/v2/calls/wave Source: https://www.smseagle.eu/docs/apiv2/index Initiates a call using a pre-recorded wave file or a dynamically generated one. Requires either a `wave_id` or `content` parameter. ```APIDOC ## POST /api/v2/calls/wave ### Description Initiates a call using a pre-recorded wave file or a dynamically generated one. Requires either a `wave_id` or `content` parameter. ### Method POST ### Endpoint /api/v2/calls/wave ### Parameters #### Request Body - **to** (array of strings) - Required - One or multiple telephone numbers. - **contacts** (array of items) - Required - One or multiple contacts from Phonebook. - **groups** (array of items) - Required - One or multiple groups from Phonebook. - **wave_id** (integer) - Required - ID of the wave file to use in call. - **content** (string) - Required - Content of a temporary wave file in Base64 format. Required .wav file parameters: 8 kHz or 16 kHz sampling frequency, Mono, 16-bit quantization, Max. 20MB. - **date** (string) - Optional - Date when to make a call. If this parameter is not null, the call will be scheduled for the given date and time. - **call_after** (string) - Optional - Make a call after a specified time. It can be used to prevent calling at night. - **call_before** (string) - Optional - Make a call before a specified time. It can be used to prevent calling at night. - **duration** (integer) - Optional - Default: 10 - Duration of call (in seconds). - **priority** (integer) - Optional - Default: 0 - Call priority. - **modem_no** (integer) - Optional - [ 1 .. 8 ] - Sending modem number (only for multimodem devices). ### Request Example ```json { "to": [ "+48123456789" ], "contacts": [ 12, 15 ], "groups": [ 57, 35 ], "wave_id": 2, "content": "123ABC456def", "date": "2022-12-27T12:20:31+05:01", "call_after": "12:05", "call_before": "17:15", "duration": 5, "priority": 2, "modem_no": 2 } ``` ### Response #### Success Response (200) - **status** (string) - The status of the call request (e.g., "queued"). - **message** (string) - A confirmation message (e.g., "OK"). - **number** (string) - The phone number the call was placed to. - **id** (integer) - The unique identifier for the call. #### Response Example ```json [ { "status": "queued", "message": "OK", "number": "123456789", "id": 1821 } ] ``` #### Error Responses - **400** - Bad request - **401** - Unauthorized - **403** - Forbidden - **404** - Not found - **405** - Method not found - **500** - Internal server error ``` -------------------------------- ### POST /websites/smseagle_eu_apiv2/wave Source: https://www.smseagle.eu/docs/apiv2/openapi Initiates a call using a pre-recorded wave file. This endpoint allows you to specify the wave file by its ID or by providing its content in Base64 format, and also supports call scheduling and timing options. ```APIDOC ## POST /websites/smseagle_eu_apiv2/wave ### Description Initiates a call using a pre-recorded wave file. This endpoint allows you to specify the wave file by its ID or by providing its content in Base64 format, and also supports call scheduling and timing options. ### Method POST ### Endpoint /websites/smseagle_eu_apiv2/wave ### Parameters #### Request Body - **to** (array[string]) - Required - One or multiple telephone numbers. - **contacts** (array[integer]) - Required - One or multiple contacts from Phonebook. - **groups** (array[integer]) - Required - One or multiple groups from Phonebook. - **wave_id** (integer) - Optional - ID of the wave file to use in call. - **content** (string) - Optional - Content of a temporary wave file in Base64 format. Required .wav file parameters: 8 kHz or 16 kHz sampling frequency, Mono, 16-bit quantization, Max. 20MB. - **date** (string) - Optional - Date when to make a call. If this parameter is not null, the call will be scheduled for the given date and time. Format: 'YYYY-MM-DDThh:mm:ssZ'. - **call_after** (string) - Optional - Make a call after a specified time. It can be used to prevent calling at night. Format: 'hh:mm'. - **call_before** (string) - Optional - Make a call before a specified time. It can be used to prevent calling at night. Format: 'hh:mm'. ### Request Example ```json { "to": ["+48123456789"], "contacts": [12, 15], "groups": [57, 35], "wave_id": 2, "content": "123ABC456def", "date": "2022-12-27T12:20:31+05:01", "call_after": "12:05", "call_before": "17:15" } ``` ### Response #### Success Response (200) (Response details not provided in the input text) #### Response Example (Response example not provided in the input text) ``` -------------------------------- ### Modem Full Information Source: https://www.smseagle.eu/docs/apiv2/openapi This section describes the structure of the `ModemFullInfo` object, which provides comprehensive details about each connected modem, including its status, signal strength, network information, and SIM card details. ```APIDOC ## Modem Full Information Structure ### Description Provides detailed information about each connected modem. ### Fields - **modem_no** (integer) - The modem's identification number. - **modem_enabled** (boolean) - Indicates if the modem is enabled. - **signal_strength** (integer) - The current signal strength of the modem. - **net_name** (string) - The name of the network the modem is connected to. Possible values: 'Network_Name Network_Type', 'Unknown'. - **sim_status** (string) - The operational status of the SIM card. Possible values: 'Modem Not Found', 'Operational', 'PIN Required', 'PUK Required', 'Not Inserted', 'Unknown Error'. - **sim_network_registration_status** (string) - The registration status of the SIM card on the network. Possible values: 'Registered Home', 'Registered Roaming', 'Registered Emergency', 'Searching', 'Not Registered', 'Unknown', 'Denied', 'Unset'. - **imei** (string) - The International Mobile Equipment Identity of the modem. - **imsi** (string) - The International Mobile Subscriber Identity of the SIM card. - **number** (string) - The phone number associated with the SIM card. Please note that not every carrier supports this feature. If that's the case, the method will return null for the specified modem. ``` -------------------------------- ### POST /api/v2/calls Source: https://www.smseagle.eu/docs/apiv2/openapi Initiates a new call. Supports both immediate calls and scheduled calls. ```APIDOC ## POST /api/v2/calls ### Description Initiates a new call. Supports both immediate calls and scheduled calls. ### Method POST ### Endpoint /api/v2/calls ### Parameters #### Request Body - **to** (string) - Required - Recipient's telephone number. - **type** (string) - Optional - Type of call. Enum: 'ring', 'tts'. Default: 'ring'. - **date** (string) - Optional - Date and time for scheduling the call in 'YYYY-MM-DDThh:mm:ssZ' format. - **duration** (integer) - Optional - Duration of call in seconds. Default: 10. - **priority** (integer) - Optional - Call priority. Default: 0. - **text** (string) - Optional - Text-to-speech message content (max 960 characters). - **modem_no** (integer) - Optional - Modem number to use for the call (1-8). Default: 1. ### Request Example ```json { "to": "+48123456789", "type": "tts", "date": "2022-12-27T12:20:31Z", "duration": 5, "priority": 2, "text": "This is text-to-speech message.", "modem_no": 1 } ``` ### Response #### Success Response (200) - **status** (string) - Indicates the success of the operation. - **id** (integer) - The ID of the initiated call. #### Response Example ```json { "status": "success", "id": 123 } ``` ``` -------------------------------- ### Make a Wave Call Request Sample Source: https://www.smseagle.eu/docs/apiv2/index This JSON payload demonstrates how to structure a request to make a call using a pre-recorded wave file. It includes parameters for recipients (to, contacts, groups), the wave file identifier or content, and call scheduling options. Ensure the wave file meets the specified format requirements. ```json { "to": [ "+48123456789" ], "contacts": [ 12, 15 ], "groups": [ 57, 35 ], "wave_id": 2, "content": "123ABC456def", "date": "2022-12-27T12:20:31+05:01", "call_after": "12:05", "call_before": "17:15", "duration": 5, "priority": 2, "modem_no": 2 } ``` -------------------------------- ### POST /call Source: https://www.smseagle.eu/docs/apiv2/openapi Initiates a call. This endpoint is deprecated and a newer version might be available. ```APIDOC ## POST /call ### Description Make a call. ### Method POST ### Endpoint /call ### Parameters #### Request Body - **(schema)** - Required - Schema for making a call, referenced by '#/components/schemas/CallsPOSTRequest'. ### Request Example ```json { "example": "Request body for POST /call" } ``` ### Response #### Success Response (200) - **(schema)** - Schema for the response to a call, referenced by '#/components/schemas/CallsResponse'. #### Response Example ```json { "example": "Success response for POST /call" } ``` #### Error Responses - **400**: Bad request. Includes details about invalid fields like 'to'. - **401**: Unauthorized. - **403**: Forbidden. - **404**: Not Found. - **405**: Method Not Allowed. - **500**: Internal Server Error. ``` -------------------------------- ### Get Groups (GET /phonebook/groups/{id}) Source: https://www.smseagle.eu/docs/apiv2/index Retrieves information about a specific group by its ID. Query parameters allow filtering by name, public access, and owner ID. Returns group details on success. ```json [ { "id": 51, "name": "Site B1", "owner_id": 7, "public": true } ] ``` -------------------------------- ### Make a Call - Request Payload Source: https://www.smseagle.eu/docs/apiv2/index This JSON payload demonstrates how to initiate a standard voice call. It includes parameters for recipients, contacts, groups, scheduling, and call parameters like duration and priority. The API supports specifying individual phone numbers, contacts from a phonebook, or groups from a phonebook. ```json { "to": [ "+48123456789" ], "contacts": [ 12, 15 ], "groups": [ 57, 35 ], "date": "2022-12-27T12:20:31+05:01", "call_after": "12:05", "call_before": "17:15", "duration": 5, "priority": 2, "modem_no": 2 } ``` -------------------------------- ### GET /calls/elevenlabs_voices Source: https://www.smseagle.eu/docs/apiv2/openapi Retrieves a list of all ElevenLabs voices saved on the gateway. ```APIDOC ## GET /calls/elevenlabs_voices ### Description List all ElevenLabs voices saved on the gateway. ### Method GET ### Endpoint /calls/elevenlabs_voices ### Parameters (No specific parameters mentioned in the provided text for this endpoint) ### Response #### Success Response (200) (Response structure not detailed in the provided text) #### Response Example (Response structure not detailed in the provided text) ``` -------------------------------- ### Wave File Management Source: https://www.smseagle.eu/docs/apiv2/openapi Endpoints for managing uploaded wave files for voice calls. ```APIDOC ## GET /api/waves ### Description Retrieves a list of all available wave files. ### Method GET ### Endpoint /api/waves ### Parameters None ### Response #### Success Response (200) - **waves** (array) - An array of Wave objects. #### Response Example ```json [ { "id": 12, "name": "AudioTest", "wave_file": "123abc456def.wav", "creator_id": 2, "insert_date": "2022-02-15T13:41:49+00:00" } ] ``` ``` ```APIDOC ## POST /api/waves ### Description Uploads a new wave file. ### Method POST ### Endpoint /api/waves ### Parameters #### Request Body - **file** (file) - Required - The wave file to upload (e.g., .wav format). - **name** (string) - Required - A name for the wave file. ### Request Example (This is a file upload, refer to multipart/form-data for specific implementation) ### Response #### Success Response (200) - **message** (string) - "Resource(s) updated successfully." #### Response Example ```json { "message": "Resource(s) updated successfully." } ``` ``` ```APIDOC ## DELETE /api/waves/{id} ### Description Deletes a wave file by its ID. ### Method DELETE ### Endpoint /api/waves/{id} ### Parameters #### Path Parameters - **id** (integer) - Required - The ID of the wave file to delete. ### Response #### Success Response (200) - **message** (string) - "Resource(s) updated successfully." #### Response Example ```json { "message": "Resource(s) updated successfully." } ``` ``` -------------------------------- ### GET /phonebook/groups/{id} Source: https://www.smseagle.eu/docs/apiv2/index Retrieves information about a specific group by its ID. ```APIDOC ## Get groups Retrieves information about a specific group by its ID. ### Method GET ### Endpoint /phonebook/groups/{id} ### Parameters #### Path Parameters - **id** (integer >= 1) - Group ID. #### Query Parameters - **name** (string) - Filter by group name. - **public** (boolean) - Filter by group access (true/false). - **owner_id** (integer >= 1) - Filter by owner ID. ### Response #### Success Response (200) - **id** (integer) - The group's unique identifier. - **name** (string) - The name of the group. - **owner_id** (integer) - The ID of the group owner. - **public** (boolean) - Indicates if the group is public. #### Response Example ```json [ { "id": 51, "name": "Site B1", "owner_id": 7, "public": true } ] ``` ``` -------------------------------- ### Escalation API Source: https://www.smseagle.eu/docs/apiv2/openapi Endpoint for configuring escalation settings. ```APIDOC ## POST /escalation ### Description Configures escalation settings. ### Method POST ### Endpoint /escalation ### Parameters #### Request Body - **status** (boolean) - Required - Escalation status. - **interval** (integer) - Optional - Interval between messages (required if status is true). - **stop_word** (string) - Optional - Stop word to stop sending messages (required if status is true). ### Request Example ```json { "status": true, "interval": 5, "stop_word": "stop" } ``` ### Response #### Success Response (200) - **message** (string) - Success message. #### Response Example ```json { "message": "Escalation settings updated." } ``` ``` -------------------------------- ### Get SIM Status Source: https://www.smseagle.eu/docs/apiv2/index Retrieves the status of the SIM card in the specified modem. ```APIDOC ## GET /api/v2/modem/sim_status/{modem_no} ### Description Get SIM status. Retrieves the current status of the SIM card within the specified modem. ### Method GET ### Endpoint http://smseagleip/api/v2/modem/sim_status/{modem_no} ### Parameters #### Path Parameters - **modem_no** (integer) - Required - Modem number. Must be between 1 and 8. Example: 2 ### Response #### Success Response (200) - **modem_no** (integer) - The modem number. - **sim_status** (string) - The status of the SIM card (e.g., "PIN Required", "Ready"). #### Response Example ```json { "modem_no": 2, "sim_status": "PIN Required" } ``` ``` -------------------------------- ### Call Forwarding API Source: https://www.smseagle.eu/docs/apiv2/openapi Manage call forwarding settings for modems. ```APIDOC ## PUT /modem/{modem_no}/callforward ### Description Configures call forwarding for a specific modem. ### Method PUT ### Endpoint /modem/{modem_no}/callforward ### Parameters #### Path Parameters - **modem_no** (integer) - Required - Modem number (1-8). #### Request Body - **call_forwarding** (boolean) - Required - Call forwarding status (true/false). - **number** (string) - Required - Telephone number to forward calls to. ### Request Example ```json { "call_forwarding": true, "number": "723459098" } ``` ### Response #### Success Response (200) - **message** (string) - Confirmation message. #### Response Example ```json { "message": "Call forwarding updated successfully." } ``` ``` -------------------------------- ### GET /phonebook/groups/{id}/escalation Source: https://www.smseagle.eu/docs/apiv2/index Retrieves the escalation settings for a specific group. ```APIDOC ## GET /phonebook/groups/{id}/escalation ### Description Retrieves the escalation settings for a specific group. ### Method GET ### Endpoint /api/v2/phonebook/groups/{id}/escalation ### Parameters #### Path Parameters - **id** (integer) - Required - The ID of the group. ### Response #### Success Response (200) - **status** (boolean) - The escalation status (true/false). - **interval** (integer) - The interval between escalation messages. - **stop_word** (string) - The stop word to halt escalation messages. #### Response Example ```json { "status": true, "interval": 5, "stop_word": "stop" } ``` ``` -------------------------------- ### Voice Management Source: https://www.smseagle.eu/docs/apiv2/openapi Endpoints for managing available text-to-speech voices. ```APIDOC ## GET /api/voices ### Description Retrieves a list of all available text-to-speech voices. ### Method GET ### Endpoint /api/voices ### Parameters None ### Response #### Success Response (200) - **voices** (array) - An array of Voice objects. #### Response Example ```json [ { "id": 12, "name": "Dave", "locale_name": "es_ES", "language": "Spanish", "quality": "medium", "onnx_file": "123abc456def.onnx", "onnx_json_file": "123abc456def.onnx.json" } ] ``` ``` -------------------------------- ### Modem API Source: https://www.smseagle.eu/docs/apiv2/openapi Endpoints for managing modem status. ```APIDOC ## PATCH /modems/{id}/status ### Description Changes the status of a modem. ### Method PATCH ### Endpoint /modems/{id}/status ### Parameters #### Path Parameters - **id** (integer) - Required - The ID of the modem to update. #### Request Body - **enabled** (boolean) - Required - Modem status (true for enabled, false for disabled). ### Request Example ```json { "enabled": false } ``` ### Response #### Success Response (200) - **message** (string) - Success message. #### Response Example ```json { "message": "Modem status updated." } ``` ``` -------------------------------- ### GET /phonebook/groups/{id}/members Source: https://www.smseagle.eu/docs/apiv2/index Retrieves all contacts belonging to a specified group. ```APIDOC ## GET /phonebook/groups/{id}/members ### Description Retrieves all contacts belonging to a specified group. ### Method GET ### Endpoint /api/v2/phonebook/groups/{id}/members ### Parameters #### Path Parameters - **id** (integer) - Required - The ID of the group (>= 1). ### Response #### Success Response (200) - **id** (integer) - Contact ID. - **name** (string) - Contact name. - **number** (string) - Contact phone number. - **owner_id** (integer) - Owner ID. - **public** (boolean) - Public status. - **vacation_mode** (boolean) - Vacation mode status. - **assigned_modem** (integer) - Assigned modem ID. - **groups** (array) - List of groups the contact belongs to. - **shifts** (array) - List of shifts the contact is assigned to. #### Response Example ```json [ { "id": 51, "name": "John Doe", "number": "+48616713413", "owner_id": 7, "public": true, "vacation_mode": false, "assigned_modem": 2, "groups": [ { "id": 5, "name": "Site B1" } ], "shifts": [ { "id": 3, "name": "Day shift" } ] } ] ``` ``` -------------------------------- ### Call Forwarding API Source: https://www.smseagle.eu/docs/apiv2/openapi Endpoint for setting up call forwarding for a specific modem. ```APIDOC ## POST /call-forwarding ### Description Sets up call forwarding for a modem. ### Method POST ### Endpoint /call-forwarding ### Parameters #### Request Body - **modem_no** (integer) - Required - Modem number (1-8). Defaults to 1. - **call_forwarding** (boolean) - Required - Call forwarding status. - **number** (string) - Required - Telephone number to forward calls to. ### Request Example ```json { "modem_no": 1, "call_forwarding": true, "number": "723459098" } ``` ### Response #### Success Response (200) - **message** (string) - Success message. #### Response Example ```json { "message": "Call forwarding settings updated." } ``` ``` -------------------------------- ### GET /api/v2/phonebook/contacts/{id} Source: https://www.smseagle.eu/docs/apiv2/index Retrieves detailed information about a specific contact by their ID. ```APIDOC ## GET /api/v2/phonebook/contacts/{id} ### Description Retrieves detailed information about a specific contact by their ID. ### Method GET ### Endpoint /api/v2/phonebook/contacts/{id} ### Parameters #### Path Parameters - **id** (integer) - Required - Contact ID. #### Query Parameters - **number** (string) - Optional - Number. - **name** (string) - Optional - Name. - **owner_id** (integer) - Optional - Owner ID. - **public** (boolean) - Optional - Contact access. - **vacation_mode** (boolean) - Optional - Status of vacation mode. ### Response #### Success Response (200) - **id** (integer) - Contact ID. - **name** (string) - Contact name. - **number** (string) - Contact number. - **owner_id** (integer) - Owner ID. - **public** (boolean) - Contact access. - **vacation_mode** (boolean) - Status of vacation mode. - **assigned_modem** (integer) - Assigned modem number. - **groups** (array) - List of groups the contact belongs to. - **shifts** (array) - List of shifts the contact is assigned to. #### Response Example ```json [ { "id": 51, "name": "John Doe", "number": "+48616713413", "owner_id": 7, "public": true, "vacation_mode": false, "assigned_modem": 2, "groups": [ { "id": 5, "name": "Site B1" } ], "shifts": [ { "id": 3, "name": "Day shift" } ] } ] ``` ``` -------------------------------- ### GET /calls/{status} Source: https://www.smseagle.eu/docs/apiv2/openapi Retrieves a list of calls based on their status and other optional filters. ```APIDOC ## GET /calls/{status} ### Description List all queued/done calls. ### Method GET ### Endpoint /calls/{status} ### Parameters #### Path Parameters - **status** (string) - Required - Status of call. Enum: [ queued, done ] #### Query Parameters - **type** (string) - Optional - Type of call. Enum: [ ring, tts, tts_advanced, wave ] - **id_from** (integer) - Optional - Minimal ID of call. Minimum: 1. Example: 1 - **id_to** (integer) - Optional - Maximal ID of call. Minimum: 1. Example: 7 - **number** (string) - Optional - Telephone number of call receiver. Example: '723459098' - **modem_no** (integer) - Optional - Show calls assigned to a chosen modem (for multimodem devices only). Example: 1 ### Request Example ```json { "example": "Request example for GET /calls/{status}" } ``` ### Response #### Success Response (200) - **(schema)** - Schema for the response containing calls, referenced by '#/components/schemas/CallsResponse'. #### Response Example ```json { "example": "Success response for GET /calls/{status}" } ``` #### Error Responses - **400**: Bad request. Includes details about invalid fields like 'modem_no'. - **401**: Unauthorized. - **403**: Forbidden. - **404**: Not Found. - **405**: Method Not Allowed. - **500**: Internal Server Error. ``` -------------------------------- ### GET /api/v2/messages/status/{id} Source: https://www.smseagle.eu/docs/apiv2/index Checks the status of a queued or already sent message by its ID. ```APIDOC ## GET /api/v2/messages/status/{id} ### Description Checks the status of a queued or already sent message by its ID. ### Method GET ### Endpoint /api/v2/messages/status/{id} ### Parameters #### Path Parameters - **id** (integer) - Required - >= 1 - Message ID. ### Request Example ```json { "message": "This is a sample request body." } ``` ### Response #### Success Response (200) - **Message status** (object) - An object containing the status of the message. #### Response Example ```json { "status": "SendingError", "id": 786, "folder": "sentitems" } ``` ``` -------------------------------- ### Send SMS Response Sample (200 OK) Source: https://www.smseagle.eu/docs/apiv2/index Example of a successful response (HTTP 200 OK) when sending an SMS. It indicates the status of the message, a confirmation message, the recipient number, and a unique message ID. ```json [ { "status": "queued", "message": "OK", "number": "123456789", "id": 1821 } ] ``` -------------------------------- ### GET /modem/sim_status/{modem_no} Source: https://www.smseagle.eu/docs/apiv2/openapi Retrieves the current status of the SIM card within the specified modem. ```APIDOC ## GET /modem/sim_status/{modem_no} ### Description Retrieves the current status of the SIM card within the specified modem. ### Method GET ### Endpoint /modem/sim_status/{modem_no} #### Path Parameters - **modem_no** (integer) - Required - Modem number. Minimum: 1, Maximum: 8. ### Response #### Success Response (200) - **modem_no** (integer) - The modem number. - **sim_status** (string) - The status of the SIM card. Possible values: 'Modem Not Found', 'Operational', 'PIN Required', 'PUK Required', 'Not Inserted', 'Unknown Error'. #### Response Example ```json { "modem_no": 2, "sim_status": "PIN Required" } ``` ```