{
  "info": {
    "_postman_id": "ebbfafb9-ef66-5875-a9c7-95d920c3ea86",
    "name": "Qlara API - SMS",
    "description": "The SMS section of API Reference in the Qlara documentation.",
    "schema": "https://schema.getpostman.com/json/collection/v2.1.0/collection.json"
  },
  "item": [
    {
      "id": "2f8d3f93-9edc-5ada-ace8-602ed2220544",
      "name": "List SMS senders",
      "request": {
        "name": "List SMS senders",
        "description": {
          "content": "Returns every SMS sender ID registered for your account, alphanumeric or numeric, in one response: the list is not paginated.\n\n- **Status**: each entry is `APPROVED`, `PENDING` (waiting for review) or `REJECTED`.\n- **Only `APPROVED` senders can send**: a message sent under a `PENDING` or `REJECTED` sender can be refused.\n- **Platform default sender**: when one is enabled, the list ends with it, marked `isDefaultSender` true. `totalCount` does not count that entry.",
          "type": "text/plain"
        },
        "url": {
          "path": [
            "api",
            "partner-gateway",
            "sms",
            "senders"
          ],
          "host": [
            "{{baseUrl}}"
          ],
          "query": [],
          "variable": []
        },
        "header": [
          {
            "key": "Accept",
            "value": "application/json"
          }
        ],
        "method": "GET",
        "auth": {
          "type": "apikey",
          "apikey": [
            {
              "key": "key",
              "value": "X-API-Key"
            },
            {
              "key": "value",
              "value": "{{apiKey}}"
            },
            {
              "key": "in",
              "value": "header"
            }
          ]
        }
      },
      "response": [
        {
          "id": "1ff77b9c-c2ab-5695-ac20-dcb45359cf22",
          "name": "The SMS senders of your account.",
          "originalRequest": {
            "url": {
              "path": [
                "api",
                "partner-gateway",
                "sms",
                "senders"
              ],
              "host": [
                "{{baseUrl}}"
              ],
              "query": [],
              "variable": []
            },
            "header": [
              {
                "key": "Accept",
                "value": "application/json"
              }
            ],
            "method": "GET",
            "body": {}
          },
          "status": "OK",
          "code": 200,
          "header": [
            {
              "key": "Content-Type",
              "value": "application/json"
            }
          ],
          "body": "{}",
          "cookie": [],
          "_postman_previewlanguage": "json"
        },
        {
          "id": "0b0f5215-d987-5557-ae99-aceecc6b0f9a",
          "name": "The API key is missing, invalid, or lacks the `SMS` operation.",
          "originalRequest": {
            "url": {
              "path": [
                "api",
                "partner-gateway",
                "sms",
                "senders"
              ],
              "host": [
                "{{baseUrl}}"
              ],
              "query": [],
              "variable": []
            },
            "header": [
              {
                "key": "Accept",
                "value": "application/json"
              }
            ],
            "method": "GET",
            "body": {}
          },
          "status": "Unauthorized",
          "code": 401,
          "header": [
            {
              "key": "Content-Type",
              "value": "application/json"
            }
          ],
          "body": "\"\"",
          "cookie": [],
          "_postman_previewlanguage": "json"
        }
      ],
      "event": [],
      "protocolProfileBehavior": {
        "disableBodyPruning": true
      }
    },
    {
      "id": "e1c668c1-001f-5b52-ab67-fc1d9d16314e",
      "name": "Campaigns",
      "item": [
        {
          "id": "5a768699-47f5-5f63-a401-266170aa1aa4",
          "name": "Create an SMS campaign",
          "request": {
            "name": "Create an SMS campaign",
            "description": {
              "content": "Creates a bulk SMS campaign, as a draft or already marked ready to send. Nothing is sent until you confirm it.\n\n- **Channel**: set `sendingMode` to `SMS`. The campaign needs an approved sender (`smsSender`) and the text (`smsBody`).\n- **Recipients**: contact lists in `contactListIds` (`destinationType` `0`), phone numbers in `destinations` (`destinationType` `1`), or both (`destinationType` `2`).\n- **Schedule**: set `scheduledDate` to a future time (`yyyy-MM-dd HH:mm:ss.SSSZ`) to send later. Without it the campaign is sent as soon as it is confirmed.\n- **The sender is checked against your account**: `smsSender` must be an approved sender (see `GET /sms/senders`). Nothing is created when the check fails.\n- **Personalisation**: `smsBody` accepts placeholders in single braces named after your contact fields, such as `{firstName}`.\n- **API key**: `CAMPAIGNS` opens every campaign. A key without it manages only the campaigns whose `sendingMode` uses its channel operations, all of them for a combined mode: `SMS` campaigns need `SMS`, `RCS_SMS` campaigns need `RCS` and `SMS`.\n\n<details>\n<summary>From draft to sending, step by step</summary>\n\n1. Create the campaign with `readyToSend` false to save it as a draft.\n2. Adjust it with `PUT /campaigns/{id}`, as many times as you need.\n3. Check the recipient count and the price with `GET /campaigns/{id}/price`.\n4. Set `readyToSend` to true with `PUT /campaigns/{id}` when the configuration is final.\n5. Confirm it with `PUT /campaigns/{id}/confirm`: the campaign is priced, the amount is reserved and the sending starts, at once or at the `scheduledDate`.\n\n</details>\n\n`POST /campaigns` is one endpoint for SMS, RCS and WhatsApp: this page describes it for SMS. See it for [RCS](/api-channel-rcs/create-campaign) or [WhatsApp](/api-channel-whatsapp/create-campaign).",
              "type": "text/plain"
            },
            "url": {
              "path": [
                "api",
                "partner-gateway",
                "campaigns"
              ],
              "host": [
                "{{baseUrl}}"
              ],
              "query": [],
              "variable": []
            },
            "header": [
              {
                "key": "Content-Type",
                "value": "application/json"
              },
              {
                "key": "Accept",
                "value": "application/json"
              }
            ],
            "method": "POST",
            "auth": {
              "type": "apikey",
              "apikey": [
                {
                  "key": "key",
                  "value": "X-API-Key"
                },
                {
                  "key": "value",
                  "value": "{{apiKey}}"
                },
                {
                  "key": "in",
                  "value": "header"
                }
              ]
            },
            "body": {
              "mode": "raw",
              "raw": "{\n  \"name\": \"Spring Promo\",\n  \"sendingMode\": \"SMS\",\n  \"smsSender\": \"MYCOMPANY\",\n  \"smsBody\": \"Hi {firstName}, your exclusive 20% discount is ready!\",\n  \"destinationType\": 0,\n  \"contactListIds\": [\n    101,\n    102\n  ],\n  \"readyToSend\": false\n}",
              "options": {
                "raw": {
                  "language": "json"
                }
              }
            }
          },
          "response": [
            {
              "id": "70ff08a1-a228-5fa5-ae16-03014e0fb1a4",
              "name": "Campaign created, returned as stored with its `id`.",
              "originalRequest": {
                "url": {
                  "path": [
                    "api",
                    "partner-gateway",
                    "campaigns"
                  ],
                  "host": [
                    "{{baseUrl}}"
                  ],
                  "query": [],
                  "variable": []
                },
                "header": [
                  {
                    "key": "Accept",
                    "value": "application/json"
                  }
                ],
                "method": "POST",
                "body": {
                  "mode": "raw",
                  "raw": "{\n  \"name\": \"Spring Promo\",\n  \"sendingMode\": \"SMS\",\n  \"smsSender\": \"MYCOMPANY\",\n  \"smsBody\": \"Hi {firstName}, your exclusive 20% discount is ready!\",\n  \"destinationType\": 0,\n  \"contactListIds\": [\n    101,\n    102\n  ],\n  \"readyToSend\": false\n}",
                  "options": {
                    "raw": {
                      "language": "json"
                    }
                  }
                }
              },
              "status": "Created",
              "code": 201,
              "header": [
                {
                  "key": "Content-Type",
                  "value": "application/json"
                }
              ],
              "body": "{\n  \"id\": 1002,\n  \"name\": \"Spring Promo\",\n  \"status\": \"DRAFT\",\n  \"sendingMode\": \"SMS\",\n  \"smsSender\": \"MYCOMPANY\",\n  \"smsBody\": \"Hi {firstName}, your discount is ready!\",\n  \"contactListIds\": [\n    101,\n    102\n  ],\n  \"readyToSend\": false\n}",
              "cookie": [],
              "_postman_previewlanguage": "json"
            },
            {
              "id": "29d450cc-43ff-5ea8-aaa8-3a004ea075f5",
              "name": "A required field is missing, `sendingMode` is not a valid value, or `whatsappTemplateId` is sent without `whatsappPhoneNumberId`.",
              "originalRequest": {
                "url": {
                  "path": [
                    "api",
                    "partner-gateway",
                    "campaigns"
                  ],
                  "host": [
                    "{{baseUrl}}"
                  ],
                  "query": [],
                  "variable": []
                },
                "header": [
                  {
                    "key": "Accept",
                    "value": "application/json"
                  }
                ],
                "method": "POST",
                "body": {
                  "mode": "raw",
                  "raw": "{\n  \"name\": \"Spring Promo\",\n  \"sendingMode\": \"SMS\",\n  \"smsSender\": \"MYCOMPANY\",\n  \"smsBody\": \"Hi {firstName}, your exclusive 20% discount is ready!\",\n  \"destinationType\": 0,\n  \"contactListIds\": [\n    101,\n    102\n  ],\n  \"readyToSend\": false\n}",
                  "options": {
                    "raw": {
                      "language": "json"
                    }
                  }
                }
              },
              "status": "Bad Request",
              "code": 400,
              "header": [
                {
                  "key": "Content-Type",
                  "value": "application/json"
                }
              ],
              "body": "\"\"",
              "cookie": [],
              "_postman_previewlanguage": "json"
            },
            {
              "id": "84f44f99-6b64-5d40-a4df-456d4d6edf5c",
              "name": "The API key is missing or invalid, or holds neither `CAMPAIGNS` nor the operation of every channel of the campaign's `sendingMode`.",
              "originalRequest": {
                "url": {
                  "path": [
                    "api",
                    "partner-gateway",
                    "campaigns"
                  ],
                  "host": [
                    "{{baseUrl}}"
                  ],
                  "query": [],
                  "variable": []
                },
                "header": [
                  {
                    "key": "Accept",
                    "value": "application/json"
                  }
                ],
                "method": "POST",
                "body": {
                  "mode": "raw",
                  "raw": "{\n  \"name\": \"Spring Promo\",\n  \"sendingMode\": \"SMS\",\n  \"smsSender\": \"MYCOMPANY\",\n  \"smsBody\": \"Hi {firstName}, your exclusive 20% discount is ready!\",\n  \"destinationType\": 0,\n  \"contactListIds\": [\n    101,\n    102\n  ],\n  \"readyToSend\": false\n}",
                  "options": {
                    "raw": {
                      "language": "json"
                    }
                  }
                }
              },
              "status": "Unauthorized",
              "code": 401,
              "header": [
                {
                  "key": "Content-Type",
                  "value": "application/json"
                }
              ],
              "body": "\"\"",
              "cookie": [],
              "_postman_previewlanguage": "json"
            },
            {
              "id": "2cd64154-18d9-57a5-ad18-b4f9cb8a2bf7",
              "name": "`smsSender` is not an approved sender of your account (see `GET /sms/senders`).",
              "originalRequest": {
                "url": {
                  "path": [
                    "api",
                    "partner-gateway",
                    "campaigns"
                  ],
                  "host": [
                    "{{baseUrl}}"
                  ],
                  "query": [],
                  "variable": []
                },
                "header": [
                  {
                    "key": "Accept",
                    "value": "application/json"
                  }
                ],
                "method": "POST",
                "body": {
                  "mode": "raw",
                  "raw": "{\n  \"name\": \"Spring Promo\",\n  \"sendingMode\": \"SMS\",\n  \"smsSender\": \"MYCOMPANY\",\n  \"smsBody\": \"Hi {firstName}, your exclusive 20% discount is ready!\",\n  \"destinationType\": 0,\n  \"contactListIds\": [\n    101,\n    102\n  ],\n  \"readyToSend\": false\n}",
                  "options": {
                    "raw": {
                      "language": "json"
                    }
                  }
                }
              },
              "status": "Forbidden",
              "code": 403,
              "header": [
                {
                  "key": "Content-Type",
                  "value": "application/json"
                }
              ],
              "body": "\"\"",
              "cookie": [],
              "_postman_previewlanguage": "json"
            },
            {
              "id": "0a9f9e13-c8bb-5da5-af0c-9ecc221083fb",
              "name": "`rcsTemplateId` is not an enabled RCS template of your account, or `whatsappPhoneNumberId` is not one of your WhatsApp phone numbers.",
              "originalRequest": {
                "url": {
                  "path": [
                    "api",
                    "partner-gateway",
                    "campaigns"
                  ],
                  "host": [
                    "{{baseUrl}}"
                  ],
                  "query": [],
                  "variable": []
                },
                "header": [
                  {
                    "key": "Accept",
                    "value": "application/json"
                  }
                ],
                "method": "POST",
                "body": {
                  "mode": "raw",
                  "raw": "{\n  \"name\": \"Spring Promo\",\n  \"sendingMode\": \"SMS\",\n  \"smsSender\": \"MYCOMPANY\",\n  \"smsBody\": \"Hi {firstName}, your exclusive 20% discount is ready!\",\n  \"destinationType\": 0,\n  \"contactListIds\": [\n    101,\n    102\n  ],\n  \"readyToSend\": false\n}",
                  "options": {
                    "raw": {
                      "language": "json"
                    }
                  }
                }
              },
              "status": "Not Found",
              "code": 404,
              "header": [
                {
                  "key": "Content-Type",
                  "value": "application/json"
                }
              ],
              "body": "\"\"",
              "cookie": [],
              "_postman_previewlanguage": "json"
            }
          ],
          "event": [],
          "protocolProfileBehavior": {
            "disableBodyPruning": true
          }
        },
        {
          "id": "bc761df8-a668-5164-ae87-9bc214b25a30",
          "name": "Update an SMS campaign",
          "request": {
            "name": "Update an SMS campaign",
            "description": {
              "content": "Updates a campaign that has not been confirmed yet. Fields you leave out keep their value, with the exceptions below.\n\n- **Only before confirmation**: the campaign must be in status `DRAFT`, whether or not `readyToSend` is true. Once confirmed with `PUT /campaigns/{id}/confirm` (`PRE_BILLED` and later) it can no longer be updated.\n- **Always required**: `sendingMode` (send the current one to keep it) and `destinationType` (send the value the campaign was created with: an update cannot change it).\n- **The sender is checked against your account**: `smsSender` must be an approved sender (see `GET /sms/senders`). The campaign is not changed when the check fails.\n- **After changing recipients or content**, call `GET /campaigns/{id}/price` for the new recipient count and price.\n\n> **Two fields are reset when you leave them out.** An update without `scheduledDate` removes the schedule, and an update without `readyToSend: true` moves the campaign back to `DRAFT`. Repeat both in every update of a scheduled campaign that is ready to send.\n\n`PUT /campaigns/{id}` is one endpoint for SMS, RCS and WhatsApp: this page describes it for SMS. See it for [RCS](/api-channel-rcs/update-campaign) or [WhatsApp](/api-channel-whatsapp/update-campaign).",
              "type": "text/plain"
            },
            "url": {
              "path": [
                "api",
                "partner-gateway",
                "campaigns",
                ":id"
              ],
              "host": [
                "{{baseUrl}}"
              ],
              "query": [],
              "variable": [
                {
                  "disabled": false,
                  "type": "any",
                  "value": "2518",
                  "key": "id",
                  "description": "(Required) ID of the campaign."
                }
              ]
            },
            "header": [
              {
                "key": "Content-Type",
                "value": "application/json"
              },
              {
                "key": "Accept",
                "value": "application/json"
              }
            ],
            "method": "PUT",
            "auth": {
              "type": "apikey",
              "apikey": [
                {
                  "key": "key",
                  "value": "X-API-Key"
                },
                {
                  "key": "value",
                  "value": "{{apiKey}}"
                },
                {
                  "key": "in",
                  "value": "header"
                }
              ]
            },
            "body": {
              "mode": "raw",
              "raw": "{\n  \"sendingMode\": \"SMS\",\n  \"destinationType\": 0,\n  \"smsBody\": \"Hi {firstName}, your 25% discount on the new Summer collection is ready! Code: SUMMER25\",\n  \"scheduledDate\": \"2027-06-01 09:00:00.000+0200\",\n  \"readyToSend\": true\n}",
              "options": {
                "raw": {
                  "language": "json"
                }
              }
            }
          },
          "response": [
            {
              "id": "d4d13da0-de06-5500-aa46-54fe69ca460d",
              "name": "Campaign updated, returned as stored.",
              "originalRequest": {
                "url": {
                  "path": [
                    "api",
                    "partner-gateway",
                    "campaigns",
                    ":id"
                  ],
                  "host": [
                    "{{baseUrl}}"
                  ],
                  "query": [],
                  "variable": [
                    {
                      "disabled": false,
                      "type": "any",
                      "value": "2518",
                      "key": "id",
                      "description": "(Required) ID of the campaign."
                    }
                  ]
                },
                "header": [
                  {
                    "key": "Accept",
                    "value": "application/json"
                  }
                ],
                "method": "PUT",
                "body": {
                  "mode": "raw",
                  "raw": "{\n  \"sendingMode\": \"SMS\",\n  \"destinationType\": 0,\n  \"smsBody\": \"Hi {firstName}, your 25% discount on the new Summer collection is ready! Code: SUMMER25\",\n  \"scheduledDate\": \"2027-06-01 09:00:00.000+0200\",\n  \"readyToSend\": true\n}",
                  "options": {
                    "raw": {
                      "language": "json"
                    }
                  }
                }
              },
              "status": "OK",
              "code": 200,
              "header": [
                {
                  "key": "Content-Type",
                  "value": "application/json"
                }
              ],
              "body": "{\n  \"id\": 1001,\n  \"userId\": 3440,\n  \"companyId\": 3785,\n  \"creationDate\": \"2026-09-01 10:17:53.200+0000\",\n  \"scheduledDate\": \"2026-09-02 09:00:00.000+0000\",\n  \"lastUpdateDate\": \"2026-09-01 10:20:04.512+0000\",\n  \"startDate\": \"2026-09-02 09:00:01.031+0000\",\n  \"endDate\": \"2026-09-02 09:14:37.870+0000\",\n  \"name\": \"Spring Promo\",\n  \"description\": \"string\",\n  \"status\": \"ENDED\",\n  \"sendingMode\": \"SMS\",\n  \"contactListIds\": [\n    5034,\n    8474\n  ],\n  \"totalDestinations\": 7511,\n  \"totalPrice\": 3215,\n  \"walletKind\": \"CREDITS\",\n  \"smsSender\": \"string\",\n  \"smsBody\": \"string\",\n  \"placeholderFields\": {\n    \"key_0\": {}\n  },\n  \"totalSuccess\": 1626,\n  \"totalFailed\": 1602,\n  \"totalSent\": 6969,\n  \"totalRead\": 9188,\n  \"totalFallback\": 8539,\n  \"smsSent\": 7447,\n  \"smsPending\": 9924,\n  \"smsSuccess\": 1230,\n  \"smsFailed\": 8002,\n  \"smsFallback\": 1800,\n  \"destinationType\": 9508,\n  \"destinations\": [\n    \"string\",\n    \"string\"\n  ],\n  \"isUpdatable\": true,\n  \"maxUpdateTime\": \"string\",\n  \"readyToSend\": false,\n  \"numOfDistinctContact\": 1910\n}",
              "cookie": [],
              "_postman_previewlanguage": "json"
            },
            {
              "id": "99cfa5bb-098c-5727-ae3e-55904099ad8b",
              "name": "The body is invalid (including a missing `sendingMode` or `destinationType`, or `whatsappTemplateId` without `whatsappPhoneNumberId`), or the campaign can no longer be edited.",
              "originalRequest": {
                "url": {
                  "path": [
                    "api",
                    "partner-gateway",
                    "campaigns",
                    ":id"
                  ],
                  "host": [
                    "{{baseUrl}}"
                  ],
                  "query": [],
                  "variable": [
                    {
                      "disabled": false,
                      "type": "any",
                      "value": "2518",
                      "key": "id",
                      "description": "(Required) ID of the campaign."
                    }
                  ]
                },
                "header": [
                  {
                    "key": "Accept",
                    "value": "application/json"
                  }
                ],
                "method": "PUT",
                "body": {
                  "mode": "raw",
                  "raw": "{\n  \"sendingMode\": \"SMS\",\n  \"destinationType\": 0,\n  \"smsBody\": \"Hi {firstName}, your 25% discount on the new Summer collection is ready! Code: SUMMER25\",\n  \"scheduledDate\": \"2027-06-01 09:00:00.000+0200\",\n  \"readyToSend\": true\n}",
                  "options": {
                    "raw": {
                      "language": "json"
                    }
                  }
                }
              },
              "status": "Bad Request",
              "code": 400,
              "header": [
                {
                  "key": "Content-Type",
                  "value": "application/json"
                }
              ],
              "body": "\"\"",
              "cookie": [],
              "_postman_previewlanguage": "json"
            },
            {
              "id": "3bb0a854-4216-5211-a3bf-af57f4dda994",
              "name": "The API key is missing or invalid, or holds neither `CAMPAIGNS` nor the operation of every channel of the campaign's `sendingMode`.",
              "originalRequest": {
                "url": {
                  "path": [
                    "api",
                    "partner-gateway",
                    "campaigns",
                    ":id"
                  ],
                  "host": [
                    "{{baseUrl}}"
                  ],
                  "query": [],
                  "variable": [
                    {
                      "disabled": false,
                      "type": "any",
                      "value": "2518",
                      "key": "id",
                      "description": "(Required) ID of the campaign."
                    }
                  ]
                },
                "header": [
                  {
                    "key": "Accept",
                    "value": "application/json"
                  }
                ],
                "method": "PUT",
                "body": {
                  "mode": "raw",
                  "raw": "{\n  \"sendingMode\": \"SMS\",\n  \"destinationType\": 0,\n  \"smsBody\": \"Hi {firstName}, your 25% discount on the new Summer collection is ready! Code: SUMMER25\",\n  \"scheduledDate\": \"2027-06-01 09:00:00.000+0200\",\n  \"readyToSend\": true\n}",
                  "options": {
                    "raw": {
                      "language": "json"
                    }
                  }
                }
              },
              "status": "Unauthorized",
              "code": 401,
              "header": [
                {
                  "key": "Content-Type",
                  "value": "application/json"
                }
              ],
              "body": "\"\"",
              "cookie": [],
              "_postman_previewlanguage": "json"
            },
            {
              "id": "6733f2a5-6e9f-5653-ad41-87aa7007ff5b",
              "name": "`smsSender` is not an approved sender of your account (see `GET /sms/senders`).",
              "originalRequest": {
                "url": {
                  "path": [
                    "api",
                    "partner-gateway",
                    "campaigns",
                    ":id"
                  ],
                  "host": [
                    "{{baseUrl}}"
                  ],
                  "query": [],
                  "variable": [
                    {
                      "disabled": false,
                      "type": "any",
                      "value": "2518",
                      "key": "id",
                      "description": "(Required) ID of the campaign."
                    }
                  ]
                },
                "header": [
                  {
                    "key": "Accept",
                    "value": "application/json"
                  }
                ],
                "method": "PUT",
                "body": {
                  "mode": "raw",
                  "raw": "{\n  \"sendingMode\": \"SMS\",\n  \"destinationType\": 0,\n  \"smsBody\": \"Hi {firstName}, your 25% discount on the new Summer collection is ready! Code: SUMMER25\",\n  \"scheduledDate\": \"2027-06-01 09:00:00.000+0200\",\n  \"readyToSend\": true\n}",
                  "options": {
                    "raw": {
                      "language": "json"
                    }
                  }
                }
              },
              "status": "Forbidden",
              "code": 403,
              "header": [
                {
                  "key": "Content-Type",
                  "value": "application/json"
                }
              ],
              "body": "\"\"",
              "cookie": [],
              "_postman_previewlanguage": "json"
            },
            {
              "id": "952efb7a-ff4d-525d-a10a-52834d727ff9",
              "name": "No campaign with this ID in your account, `rcsTemplateId` is not an enabled RCS template of your account, or `whatsappPhoneNumberId` is not one of your WhatsApp phone numbers.",
              "originalRequest": {
                "url": {
                  "path": [
                    "api",
                    "partner-gateway",
                    "campaigns",
                    ":id"
                  ],
                  "host": [
                    "{{baseUrl}}"
                  ],
                  "query": [],
                  "variable": [
                    {
                      "disabled": false,
                      "type": "any",
                      "value": "2518",
                      "key": "id",
                      "description": "(Required) ID of the campaign."
                    }
                  ]
                },
                "header": [
                  {
                    "key": "Accept",
                    "value": "application/json"
                  }
                ],
                "method": "PUT",
                "body": {
                  "mode": "raw",
                  "raw": "{\n  \"sendingMode\": \"SMS\",\n  \"destinationType\": 0,\n  \"smsBody\": \"Hi {firstName}, your 25% discount on the new Summer collection is ready! Code: SUMMER25\",\n  \"scheduledDate\": \"2027-06-01 09:00:00.000+0200\",\n  \"readyToSend\": true\n}",
                  "options": {
                    "raw": {
                      "language": "json"
                    }
                  }
                }
              },
              "status": "Not Found",
              "code": 404,
              "header": [
                {
                  "key": "Content-Type",
                  "value": "application/json"
                }
              ],
              "body": "\"\"",
              "cookie": [],
              "_postman_previewlanguage": "json"
            }
          ],
          "event": [],
          "protocolProfileBehavior": {
            "disableBodyPruning": true
          }
        },
        {
          "id": "ee425da7-58d1-5549-a47a-96cf8af3b2ab",
          "name": "Get the total price of an SMS campaign",
          "request": {
            "name": "Get the total price of an SMS campaign",
            "description": {
              "content": "Returns the campaign with its total price, computed on every call from the current configuration.\n\n- **What sets the price**: the `sendingMode`, the distinct recipients of the campaign's contact lists and `destinations`, and the per-message rate of your account.\n- **In the response**: `totalPrice`, its unit (`walletKind`) and the number of distinct recipients (`numOfDistinctContact`).\n- **Nothing is reserved**: use it as a cost preview. `PUT /campaigns/{id}/confirm` prices the campaign again and reserves the amount.\n\n\n`GET /campaigns/{id}/price` is one endpoint for SMS, RCS and WhatsApp: this page describes it for SMS. See it for [RCS](/api-channel-rcs/get-total-price) or [WhatsApp](/api-channel-whatsapp/get-total-price).",
              "type": "text/plain"
            },
            "url": {
              "path": [
                "api",
                "partner-gateway",
                "campaigns",
                ":id",
                "price"
              ],
              "host": [
                "{{baseUrl}}"
              ],
              "query": [],
              "variable": [
                {
                  "disabled": false,
                  "type": "any",
                  "value": "2518",
                  "key": "id",
                  "description": "(Required) ID of the campaign."
                }
              ]
            },
            "header": [
              {
                "key": "Accept",
                "value": "application/json"
              }
            ],
            "method": "GET",
            "auth": {
              "type": "apikey",
              "apikey": [
                {
                  "key": "key",
                  "value": "X-API-Key"
                },
                {
                  "key": "value",
                  "value": "{{apiKey}}"
                },
                {
                  "key": "in",
                  "value": "header"
                }
              ]
            }
          },
          "response": [
            {
              "id": "fa4e5103-2c44-530f-a8fb-c47de0f4341d",
              "name": "The campaign with its `totalPrice`, `walletKind` and `numOfDistinctContact`.",
              "originalRequest": {
                "url": {
                  "path": [
                    "api",
                    "partner-gateway",
                    "campaigns",
                    ":id",
                    "price"
                  ],
                  "host": [
                    "{{baseUrl}}"
                  ],
                  "query": [],
                  "variable": [
                    {
                      "disabled": false,
                      "type": "any",
                      "value": "2518",
                      "key": "id",
                      "description": "(Required) ID of the campaign."
                    }
                  ]
                },
                "header": [
                  {
                    "key": "Accept",
                    "value": "application/json"
                  }
                ],
                "method": "GET",
                "body": {}
              },
              "status": "OK",
              "code": 200,
              "header": [
                {
                  "key": "Content-Type",
                  "value": "application/json"
                }
              ],
              "body": "{\n  \"id\": 1001,\n  \"userId\": 3440,\n  \"companyId\": 3785,\n  \"creationDate\": \"2026-09-01 10:17:53.200+0000\",\n  \"scheduledDate\": \"2026-09-02 09:00:00.000+0000\",\n  \"lastUpdateDate\": \"2026-09-01 10:20:04.512+0000\",\n  \"startDate\": \"2026-09-02 09:00:01.031+0000\",\n  \"endDate\": \"2026-09-02 09:14:37.870+0000\",\n  \"name\": \"Spring Promo\",\n  \"description\": \"string\",\n  \"status\": \"ENDED\",\n  \"sendingMode\": \"SMS\",\n  \"contactListIds\": [\n    5034,\n    8474\n  ],\n  \"totalDestinations\": 7511,\n  \"totalPrice\": 3215,\n  \"walletKind\": \"CREDITS\",\n  \"smsSender\": \"string\",\n  \"smsBody\": \"string\",\n  \"placeholderFields\": {\n    \"key_0\": {}\n  },\n  \"totalSuccess\": 1626,\n  \"totalFailed\": 1602,\n  \"totalSent\": 6969,\n  \"totalRead\": 9188,\n  \"totalFallback\": 8539,\n  \"smsSent\": 7447,\n  \"smsPending\": 9924,\n  \"smsSuccess\": 1230,\n  \"smsFailed\": 8002,\n  \"smsFallback\": 1800,\n  \"destinationType\": 9508,\n  \"destinations\": [\n    \"string\",\n    \"string\"\n  ],\n  \"isUpdatable\": true,\n  \"maxUpdateTime\": \"string\",\n  \"readyToSend\": false,\n  \"numOfDistinctContact\": 1910\n}",
              "cookie": [],
              "_postman_previewlanguage": "json"
            },
            {
              "id": "55b07825-e111-5fca-a61f-4a26d1fbe981",
              "name": "The campaign is incomplete or has no valid recipient.",
              "originalRequest": {
                "url": {
                  "path": [
                    "api",
                    "partner-gateway",
                    "campaigns",
                    ":id",
                    "price"
                  ],
                  "host": [
                    "{{baseUrl}}"
                  ],
                  "query": [],
                  "variable": [
                    {
                      "disabled": false,
                      "type": "any",
                      "value": "2518",
                      "key": "id",
                      "description": "(Required) ID of the campaign."
                    }
                  ]
                },
                "header": [
                  {
                    "key": "Accept",
                    "value": "application/json"
                  }
                ],
                "method": "GET",
                "body": {}
              },
              "status": "Bad Request",
              "code": 400,
              "header": [
                {
                  "key": "Content-Type",
                  "value": "application/json"
                }
              ],
              "body": "\"\"",
              "cookie": [],
              "_postman_previewlanguage": "json"
            },
            {
              "id": "4a84b420-6417-54aa-aef3-0cb3f77d3afd",
              "name": "The API key is missing or invalid, or holds neither `CAMPAIGNS` nor the operation of every channel of the campaign's `sendingMode`.",
              "originalRequest": {
                "url": {
                  "path": [
                    "api",
                    "partner-gateway",
                    "campaigns",
                    ":id",
                    "price"
                  ],
                  "host": [
                    "{{baseUrl}}"
                  ],
                  "query": [],
                  "variable": [
                    {
                      "disabled": false,
                      "type": "any",
                      "value": "2518",
                      "key": "id",
                      "description": "(Required) ID of the campaign."
                    }
                  ]
                },
                "header": [
                  {
                    "key": "Accept",
                    "value": "application/json"
                  }
                ],
                "method": "GET",
                "body": {}
              },
              "status": "Unauthorized",
              "code": 401,
              "header": [
                {
                  "key": "Content-Type",
                  "value": "application/json"
                }
              ],
              "body": "\"\"",
              "cookie": [],
              "_postman_previewlanguage": "json"
            },
            {
              "id": "9cb1ef8f-fca4-5344-ae28-5ed0e32deb76",
              "name": "No campaign with this ID in your account.",
              "originalRequest": {
                "url": {
                  "path": [
                    "api",
                    "partner-gateway",
                    "campaigns",
                    ":id",
                    "price"
                  ],
                  "host": [
                    "{{baseUrl}}"
                  ],
                  "query": [],
                  "variable": [
                    {
                      "disabled": false,
                      "type": "any",
                      "value": "2518",
                      "key": "id",
                      "description": "(Required) ID of the campaign."
                    }
                  ]
                },
                "header": [
                  {
                    "key": "Accept",
                    "value": "application/json"
                  }
                ],
                "method": "GET",
                "body": {}
              },
              "status": "Not Found",
              "code": 404,
              "header": [
                {
                  "key": "Content-Type",
                  "value": "application/json"
                }
              ],
              "body": "\"\"",
              "cookie": [],
              "_postman_previewlanguage": "json"
            }
          ],
          "event": [],
          "protocolProfileBehavior": {
            "disableBodyPruning": true
          }
        },
        {
          "id": "9154ddc1-36af-5279-acd5-5aee9f732ae5",
          "name": "Confirm / schedule an SMS campaign",
          "request": {
            "name": "Confirm / schedule an SMS campaign",
            "description": {
              "content": "Confirms a campaign: it is priced from its current configuration, the amount is reserved on your wallet and the sending is queued, at once or at the `scheduledDate`.\n\n- **What the campaign needs**: a name, `sendingMode` `SMS` and a valid `destinationType`, `smsSender` and `smsBody`, the recipients its `destinationType` asks for, and enough credit to cover the price.\n- **Preview the price** with `GET /campaigns/{id}/price`. `POST /campaigns/{id}/calculateGoal` is not needed: it only writes the campaign description.\n- **`readyToSend`**: set it to true once the configuration is final. Confirmation does not currently check the flag.\n- **After confirmation** the campaign is `PRE_BILLED` and can no longer be updated. Without a `scheduledDate` it starts sending at once and cannot be deleted. A scheduled campaign can still be deleted with `DELETE /campaigns/{id}` while its `scheduledDate` is outside the platform's edit window, which releases the reserved amount.\n\n> **After a timeout, check before you retry.** A campaign that is already confirmed answers `400` as well, so read its status with `GET /campaigns/{id}` first.\n\n`PUT /campaigns/{id}/confirm` is one endpoint for SMS, RCS and WhatsApp: this page describes it for SMS. See it for [RCS](/api-channel-rcs/confirm-campaign) or [WhatsApp](/api-channel-whatsapp/confirm-campaign).",
              "type": "text/plain"
            },
            "url": {
              "path": [
                "api",
                "partner-gateway",
                "campaigns",
                ":id",
                "confirm"
              ],
              "host": [
                "{{baseUrl}}"
              ],
              "query": [],
              "variable": [
                {
                  "disabled": false,
                  "type": "any",
                  "value": "2518",
                  "key": "id",
                  "description": "(Required) ID of the campaign."
                }
              ]
            },
            "header": [
              {
                "key": "Accept",
                "value": "application/json"
              }
            ],
            "method": "PUT",
            "auth": {
              "type": "apikey",
              "apikey": [
                {
                  "key": "key",
                  "value": "X-API-Key"
                },
                {
                  "key": "value",
                  "value": "{{apiKey}}"
                },
                {
                  "key": "in",
                  "value": "header"
                }
              ]
            }
          },
          "response": [
            {
              "id": "09c4d67a-2b29-5c6a-a2df-2571ce85be47",
              "name": "Campaign confirmed and queued for sending. No response body.",
              "originalRequest": {
                "url": {
                  "path": [
                    "api",
                    "partner-gateway",
                    "campaigns",
                    ":id",
                    "confirm"
                  ],
                  "host": [
                    "{{baseUrl}}"
                  ],
                  "query": [],
                  "variable": [
                    {
                      "disabled": false,
                      "type": "any",
                      "value": "2518",
                      "key": "id",
                      "description": "(Required) ID of the campaign."
                    }
                  ]
                },
                "header": [
                  {
                    "key": "Accept",
                    "value": "application/json"
                  }
                ],
                "method": "PUT",
                "body": {}
              },
              "status": "Accepted",
              "code": 202,
              "header": [
                {
                  "key": "Content-Type",
                  "value": "application/json"
                }
              ],
              "body": "\"\"",
              "cookie": [],
              "_postman_previewlanguage": "json"
            },
            {
              "id": "1d581fa6-c1f3-58d9-ae6f-6128d114b8fe",
              "name": "A required field or the recipients are missing, the computed price is zero (for example, no valid recipient), your wallet balance does not cover the price, or the campaign is already confirmed.",
              "originalRequest": {
                "url": {
                  "path": [
                    "api",
                    "partner-gateway",
                    "campaigns",
                    ":id",
                    "confirm"
                  ],
                  "host": [
                    "{{baseUrl}}"
                  ],
                  "query": [],
                  "variable": [
                    {
                      "disabled": false,
                      "type": "any",
                      "value": "2518",
                      "key": "id",
                      "description": "(Required) ID of the campaign."
                    }
                  ]
                },
                "header": [
                  {
                    "key": "Accept",
                    "value": "application/json"
                  }
                ],
                "method": "PUT",
                "body": {}
              },
              "status": "Bad Request",
              "code": 400,
              "header": [
                {
                  "key": "Content-Type",
                  "value": "application/json"
                }
              ],
              "body": "\"\"",
              "cookie": [],
              "_postman_previewlanguage": "json"
            },
            {
              "id": "d1d06c77-312d-5f1a-ac45-7781c338b9ae",
              "name": "The API key is missing or invalid, or holds neither `CAMPAIGNS` nor the operation of every channel of the campaign's `sendingMode`.",
              "originalRequest": {
                "url": {
                  "path": [
                    "api",
                    "partner-gateway",
                    "campaigns",
                    ":id",
                    "confirm"
                  ],
                  "host": [
                    "{{baseUrl}}"
                  ],
                  "query": [],
                  "variable": [
                    {
                      "disabled": false,
                      "type": "any",
                      "value": "2518",
                      "key": "id",
                      "description": "(Required) ID of the campaign."
                    }
                  ]
                },
                "header": [
                  {
                    "key": "Accept",
                    "value": "application/json"
                  }
                ],
                "method": "PUT",
                "body": {}
              },
              "status": "Unauthorized",
              "code": 401,
              "header": [
                {
                  "key": "Content-Type",
                  "value": "application/json"
                }
              ],
              "body": "\"\"",
              "cookie": [],
              "_postman_previewlanguage": "json"
            },
            {
              "id": "3e9707ea-782d-52c8-af7e-4419b1898925",
              "name": "No campaign with this ID in your account.",
              "originalRequest": {
                "url": {
                  "path": [
                    "api",
                    "partner-gateway",
                    "campaigns",
                    ":id",
                    "confirm"
                  ],
                  "host": [
                    "{{baseUrl}}"
                  ],
                  "query": [],
                  "variable": [
                    {
                      "disabled": false,
                      "type": "any",
                      "value": "2518",
                      "key": "id",
                      "description": "(Required) ID of the campaign."
                    }
                  ]
                },
                "header": [
                  {
                    "key": "Accept",
                    "value": "application/json"
                  }
                ],
                "method": "PUT",
                "body": {}
              },
              "status": "Not Found",
              "code": 404,
              "header": [
                {
                  "key": "Content-Type",
                  "value": "application/json"
                }
              ],
              "body": "\"\"",
              "cookie": [],
              "_postman_previewlanguage": "json"
            }
          ],
          "event": [],
          "protocolProfileBehavior": {
            "disableBodyPruning": true
          }
        },
        {
          "id": "ef2a73f3-1c3f-58bc-aca1-de795be08854",
          "name": "Get an SMS campaign",
          "request": {
            "name": "Get an SMS campaign",
            "description": {
              "content": "Returns one campaign with its configuration, status and delivery counters. It works at every stage: draft, confirmed, sending or finished.\n\n- **Status**: `status` names the stage the campaign is in; the values are listed on the field. A campaign marked ready to send is reported as `DRAFT` with `readyToSend` true.\n- **Configuration**: `sendingMode`, the message content (`smsBody`), the recipients (`contactListIds`, `destinations`) and the `scheduledDate`, if any.\n- **Results**: `totalDestinations`, `totalSuccess`, `totalFailed` and the SMS counters.\n\n`GET /campaigns/{id}` is one endpoint for SMS, RCS and WhatsApp: this page describes it for SMS. See it for [RCS](/api-channel-rcs/get-campaign-by-id) or [WhatsApp](/api-channel-whatsapp/get-campaign-by-id).",
              "type": "text/plain"
            },
            "url": {
              "path": [
                "api",
                "partner-gateway",
                "campaigns",
                ":id"
              ],
              "host": [
                "{{baseUrl}}"
              ],
              "query": [],
              "variable": [
                {
                  "disabled": false,
                  "type": "any",
                  "value": "2518",
                  "key": "id",
                  "description": "(Required) ID of the campaign."
                }
              ]
            },
            "header": [
              {
                "key": "Accept",
                "value": "application/json"
              }
            ],
            "method": "GET",
            "auth": {
              "type": "apikey",
              "apikey": [
                {
                  "key": "key",
                  "value": "X-API-Key"
                },
                {
                  "key": "value",
                  "value": "{{apiKey}}"
                },
                {
                  "key": "in",
                  "value": "header"
                }
              ]
            }
          },
          "response": [
            {
              "id": "ce765d1e-04bf-5778-a7f4-f741f861cd3f",
              "name": "The campaign.",
              "originalRequest": {
                "url": {
                  "path": [
                    "api",
                    "partner-gateway",
                    "campaigns",
                    ":id"
                  ],
                  "host": [
                    "{{baseUrl}}"
                  ],
                  "query": [],
                  "variable": [
                    {
                      "disabled": false,
                      "type": "any",
                      "value": "2518",
                      "key": "id",
                      "description": "(Required) ID of the campaign."
                    }
                  ]
                },
                "header": [
                  {
                    "key": "Accept",
                    "value": "application/json"
                  }
                ],
                "method": "GET",
                "body": {}
              },
              "status": "OK",
              "code": 200,
              "header": [
                {
                  "key": "Content-Type",
                  "value": "application/json"
                }
              ],
              "body": "{\n  \"id\": 1001,\n  \"name\": \"Spring Promo\",\n  \"status\": \"ENDED\",\n  \"sendingMode\": \"SMS\",\n  \"smsSender\": \"MYCOMPANY\",\n  \"smsBody\": \"Hi! Your 20% discount is ready.\",\n  \"contactListIds\": [\n    101,\n    102\n  ],\n  \"totalDestinations\": 500,\n  \"totalSuccess\": 485,\n  \"totalFailed\": 15,\n  \"readyToSend\": false\n}",
              "cookie": [],
              "_postman_previewlanguage": "json"
            },
            {
              "id": "d3ecef19-8051-5360-a215-b4a08deeeb94",
              "name": "The API key is missing or invalid, or holds neither `CAMPAIGNS` nor the operation of every channel of the campaign's `sendingMode`.",
              "originalRequest": {
                "url": {
                  "path": [
                    "api",
                    "partner-gateway",
                    "campaigns",
                    ":id"
                  ],
                  "host": [
                    "{{baseUrl}}"
                  ],
                  "query": [],
                  "variable": [
                    {
                      "disabled": false,
                      "type": "any",
                      "value": "2518",
                      "key": "id",
                      "description": "(Required) ID of the campaign."
                    }
                  ]
                },
                "header": [
                  {
                    "key": "Accept",
                    "value": "application/json"
                  }
                ],
                "method": "GET",
                "body": {}
              },
              "status": "Unauthorized",
              "code": 401,
              "header": [
                {
                  "key": "Content-Type",
                  "value": "application/json"
                }
              ],
              "body": "\"\"",
              "cookie": [],
              "_postman_previewlanguage": "json"
            },
            {
              "id": "ef2d6417-3a59-5284-a776-19a6809e766b",
              "name": "No campaign with this ID in your account.",
              "originalRequest": {
                "url": {
                  "path": [
                    "api",
                    "partner-gateway",
                    "campaigns",
                    ":id"
                  ],
                  "host": [
                    "{{baseUrl}}"
                  ],
                  "query": [],
                  "variable": [
                    {
                      "disabled": false,
                      "type": "any",
                      "value": "2518",
                      "key": "id",
                      "description": "(Required) ID of the campaign."
                    }
                  ]
                },
                "header": [
                  {
                    "key": "Accept",
                    "value": "application/json"
                  }
                ],
                "method": "GET",
                "body": {}
              },
              "status": "Not Found",
              "code": 404,
              "header": [
                {
                  "key": "Content-Type",
                  "value": "application/json"
                }
              ],
              "body": "\"\"",
              "cookie": [],
              "_postman_previewlanguage": "json"
            }
          ],
          "event": [],
          "protocolProfileBehavior": {
            "disableBodyPruning": true
          }
        },
        {
          "id": "59c8d3e0-0337-5f9d-a1cd-dcc6dc9217c0",
          "name": "List SMS campaigns",
          "request": {
            "name": "List SMS campaigns",
            "description": {
              "content": "Returns the campaigns of your account, one page at a time, newest first by creation date.\n\n- **Confirmed campaigns by default**: without a status filter only confirmed campaigns are listed (`PRE_BILLED` onwards). Drafts are left out.\n- **Status filters**: `isDraft`, `isProgrammed` and `readyToSend` choose the stage to list. `readyToSend` wins over the other two, and `isDraft=true` wins over `isProgrammed`.\n- **SMS campaigns only**: send `sendingMode=SMS`. Without `sendingMode` the list holds the campaigns of every channel. The mode is matched exactly, so `SMS` does not include `RCS_SMS` or `WHATSAPP_SMS`.\n- **Sender**: `channel=SMS` and `channelId` go together, and keep the campaigns of one SMS sender: `channelId` is the sender name.\n- **Search**: `search` is a case-insensitive partial match on the campaign name and on the SMS text. The description is never searched.\n- **Date window**: `startDate` and `endDate` (`yyyy-MM-dd`) keep the campaigns scheduled in that window, or created in it when they have no `scheduledDate`. `endDate` includes the whole day.\n- **Keys scoped by channel**: a key without `CAMPAIGNS` lists only the campaigns whose channels it holds (`SMS`, `RCS`, `WHATSAPP`). A `sendingMode` filter with a channel the key lacks answers `401`.\n\n<details>\n<summary>What each status filter lists</summary>\n\n| Filter | Campaigns listed |\n|---|---|\n| `isDraft=true` | Not yet confirmed, including those marked ready to send, which come back with status `DRAFT` and `readyToSend` true. |\n| `isDraft=false` | Same as leaving it out: confirmed campaigns only. |\n| `isProgrammed=true` | Confirmed and not yet fully sent (`PRE_BILLED` through `STARTED`), whether scheduled for later or sending now. |\n| `isProgrammed=false` | Sent, ended or archived. |\n| `readyToSend=true` | Drafts marked ready to send. |\n| `readyToSend=false` | The other drafts. |\n\n</details>\n\n`GET /campaigns` is one endpoint for SMS, RCS and WhatsApp: this page describes it for SMS. See it for [RCS](/api-channel-rcs/get-campaigns) or [WhatsApp](/api-channel-whatsapp/get-campaigns).",
              "type": "text/plain"
            },
            "url": {
              "path": [
                "api",
                "partner-gateway",
                "campaigns"
              ],
              "host": [
                "{{baseUrl}}"
              ],
              "query": [
                {
                  "disabled": false,
                  "key": "channel",
                  "value": "string",
                  "description": "`SMS` (case-insensitive), only together with `channelId`: it says that `channelId` is an SMS sender name. To filter by sending mode use `sendingMode`."
                },
                {
                  "disabled": false,
                  "key": "channelId",
                  "value": "string",
                  "description": "SMS sender name to filter by, only together with `channel`."
                },
                {
                  "disabled": false,
                  "key": "direction",
                  "value": "string",
                  "description": "Sort by creation date: `DESC` (default, newest first) or `ASC`."
                },
                {
                  "disabled": false,
                  "key": "endDate",
                  "value": "string",
                  "description": "End of the date window (`yyyy-MM-dd`), whole day included."
                },
                {
                  "disabled": false,
                  "key": "isDraft",
                  "value": "true",
                  "description": "`true` lists the campaigns not yet confirmed (drafts, including those marked ready to send). `false` or omitted lists confirmed campaigns only."
                },
                {
                  "disabled": false,
                  "key": "isProgrammed",
                  "value": "true",
                  "description": "`true` lists confirmed campaigns not yet fully sent, scheduled or sending. `false` lists campaigns sent, ended or archived. Ignored with `isDraft=true` or `readyToSend`."
                },
                {
                  "disabled": false,
                  "key": "limit",
                  "value": "719",
                  "description": "Page size, at most 1000 (default 10; 0 also means the default)."
                },
                {
                  "disabled": false,
                  "key": "page",
                  "value": "5496",
                  "description": "Page number, 0-based."
                },
                {
                  "disabled": false,
                  "key": "readyToSend",
                  "value": "true",
                  "description": "`true` lists the drafts marked ready to send, `false` the other drafts. Overrides `isDraft` and `isProgrammed`."
                },
                {
                  "disabled": false,
                  "key": "search",
                  "value": "string",
                  "description": "Case-insensitive partial match on the name and on the SMS text. The description is not searched."
                },
                {
                  "disabled": false,
                  "key": "sendingMode",
                  "value": "string",
                  "description": "`SMS` (case-insensitive) to list the SMS campaigns only. Omit it for the campaigns of every channel."
                },
                {
                  "disabled": false,
                  "key": "startDate",
                  "value": "string",
                  "description": "Start of the date window (`yyyy-MM-dd`), matched against `scheduledDate`, or `creationDate` when there is none."
                }
              ],
              "variable": []
            },
            "header": [
              {
                "key": "Accept",
                "value": "application/json"
              }
            ],
            "method": "GET",
            "auth": {
              "type": "apikey",
              "apikey": [
                {
                  "key": "key",
                  "value": "X-API-Key"
                },
                {
                  "key": "value",
                  "value": "{{apiKey}}"
                },
                {
                  "key": "in",
                  "value": "header"
                }
              ]
            }
          },
          "response": [
            {
              "id": "a3827390-b0b1-5d80-a863-dc18df23b3ac",
              "name": "The campaigns that match the filters, one page at a time.",
              "originalRequest": {
                "url": {
                  "path": [
                    "api",
                    "partner-gateway",
                    "campaigns"
                  ],
                  "host": [
                    "{{baseUrl}}"
                  ],
                  "query": [
                    {
                      "key": "channel",
                      "value": "string"
                    },
                    {
                      "key": "channelId",
                      "value": "string"
                    },
                    {
                      "key": "direction",
                      "value": "string"
                    },
                    {
                      "key": "endDate",
                      "value": "string"
                    },
                    {
                      "key": "isDraft",
                      "value": "true"
                    },
                    {
                      "key": "isProgrammed",
                      "value": "true"
                    },
                    {
                      "key": "limit",
                      "value": "719"
                    },
                    {
                      "key": "page",
                      "value": "5496"
                    },
                    {
                      "key": "readyToSend",
                      "value": "true"
                    },
                    {
                      "key": "search",
                      "value": "string"
                    },
                    {
                      "key": "sendingMode",
                      "value": "string"
                    },
                    {
                      "key": "startDate",
                      "value": "string"
                    }
                  ],
                  "variable": []
                },
                "header": [
                  {
                    "key": "Accept",
                    "value": "application/json"
                  }
                ],
                "method": "GET",
                "body": {}
              },
              "status": "OK",
              "code": 200,
              "header": [
                {
                  "key": "Content-Type",
                  "value": "application/json"
                }
              ],
              "body": "{}",
              "cookie": [],
              "_postman_previewlanguage": "json"
            },
            {
              "id": "11399685-c44b-5cea-a5a7-e5654730fa65",
              "name": "`channel` or `channelId` is sent without the other, `channel` is unknown, `channelId` is not numeric with `channel=WHATSAPP`, `startDate` or `endDate` is not a valid date, `sendingMode` is not a valid value, `page` is negative, or `limit` is negative or above 1000.",
              "originalRequest": {
                "url": {
                  "path": [
                    "api",
                    "partner-gateway",
                    "campaigns"
                  ],
                  "host": [
                    "{{baseUrl}}"
                  ],
                  "query": [
                    {
                      "key": "channel",
                      "value": "string"
                    },
                    {
                      "key": "channelId",
                      "value": "string"
                    },
                    {
                      "key": "direction",
                      "value": "string"
                    },
                    {
                      "key": "endDate",
                      "value": "string"
                    },
                    {
                      "key": "isDraft",
                      "value": "true"
                    },
                    {
                      "key": "isProgrammed",
                      "value": "true"
                    },
                    {
                      "key": "limit",
                      "value": "719"
                    },
                    {
                      "key": "page",
                      "value": "5496"
                    },
                    {
                      "key": "readyToSend",
                      "value": "true"
                    },
                    {
                      "key": "search",
                      "value": "string"
                    },
                    {
                      "key": "sendingMode",
                      "value": "string"
                    },
                    {
                      "key": "startDate",
                      "value": "string"
                    }
                  ],
                  "variable": []
                },
                "header": [
                  {
                    "key": "Accept",
                    "value": "application/json"
                  }
                ],
                "method": "GET",
                "body": {}
              },
              "status": "Bad Request",
              "code": 400,
              "header": [
                {
                  "key": "Content-Type",
                  "value": "application/json"
                }
              ],
              "body": "\"\"",
              "cookie": [],
              "_postman_previewlanguage": "json"
            },
            {
              "id": "2294c27a-1f15-5b77-a65d-424f8c6ad6f7",
              "name": "The API key is missing or invalid, or holds neither `CAMPAIGNS` nor the operation of every channel of the campaign's `sendingMode`.",
              "originalRequest": {
                "url": {
                  "path": [
                    "api",
                    "partner-gateway",
                    "campaigns"
                  ],
                  "host": [
                    "{{baseUrl}}"
                  ],
                  "query": [
                    {
                      "key": "channel",
                      "value": "string"
                    },
                    {
                      "key": "channelId",
                      "value": "string"
                    },
                    {
                      "key": "direction",
                      "value": "string"
                    },
                    {
                      "key": "endDate",
                      "value": "string"
                    },
                    {
                      "key": "isDraft",
                      "value": "true"
                    },
                    {
                      "key": "isProgrammed",
                      "value": "true"
                    },
                    {
                      "key": "limit",
                      "value": "719"
                    },
                    {
                      "key": "page",
                      "value": "5496"
                    },
                    {
                      "key": "readyToSend",
                      "value": "true"
                    },
                    {
                      "key": "search",
                      "value": "string"
                    },
                    {
                      "key": "sendingMode",
                      "value": "string"
                    },
                    {
                      "key": "startDate",
                      "value": "string"
                    }
                  ],
                  "variable": []
                },
                "header": [
                  {
                    "key": "Accept",
                    "value": "application/json"
                  }
                ],
                "method": "GET",
                "body": {}
              },
              "status": "Unauthorized",
              "code": 401,
              "header": [
                {
                  "key": "Content-Type",
                  "value": "application/json"
                }
              ],
              "body": "\"\"",
              "cookie": [],
              "_postman_previewlanguage": "json"
            }
          ],
          "event": [],
          "protocolProfileBehavior": {
            "disableBodyPruning": true
          }
        },
        {
          "id": "a57b0576-aedb-52ef-acde-c667e413946f",
          "name": "Get SMS campaign statistics",
          "request": {
            "name": "Get SMS campaign statistics",
            "description": {
              "content": "Returns delivery statistics for a date range, grouped by time bucket, newest bucket first.\n\n- **Required**: `startDate` and `endDate` (`yyyy-MM-dd`) and `aggregateOn` (`hour`, `day`, `week` or `month`, case-insensitive). `endDate` cannot be before `startDate`, and the window cannot exceed 1 year.\n- **Campaign rows** (`isHttpStat` false): each one adds up the campaigns of one time bucket, `sendingMode` and `destinationType`, placed by the date they started sending.\n- **API rows** (`isHttpStat` true): the messages you sent through the API, outside any campaign, one row per time bucket and channel. Leave them out when you need campaign figures only.\n- **Drafts**: `isDraft` defaults to false, which counts confirmed campaigns. `isDraft=true` counts only the campaigns not yet confirmed, which have usually sent nothing. API rows are included either way.\n- **Keys scoped by channel**: a key without `CAMPAIGNS` must send a `sendingMode` whose channels it holds (`RCS_SMS` needs `RCS` and `SMS`).\n- **Pagination is optional**: without `page` and `limit` every row comes back in one page. `page` is 0-based, `limit` sets the page size (default 10, at most 1000), and a `limit` without `page` returns the first page. `direction` is currently ignored.\n\nWith `sendingMode=SMS` the rows count the `SMS` campaigns and the SMS sent through the API. Without `sendingMode` they cover every channel.\n\n`GET /campaigns/stats` is one endpoint for SMS, RCS and WhatsApp: this page describes it for SMS. See it for [RCS](/api-channel-rcs/get-stats) or [WhatsApp](/api-channel-whatsapp/get-stats).",
              "type": "text/plain"
            },
            "url": {
              "path": [
                "api",
                "partner-gateway",
                "campaigns",
                "stats"
              ],
              "host": [
                "{{baseUrl}}"
              ],
              "query": [
                {
                  "disabled": false,
                  "key": "aggregateOn",
                  "value": "string",
                  "description": "(Required) Time bucket the rows are grouped by: `hour`, `day`, `week` or `month` (case-insensitive)."
                },
                {
                  "disabled": false,
                  "key": "direction",
                  "value": "string",
                  "description": "Currently ignored: rows always come newest time bucket first."
                },
                {
                  "disabled": false,
                  "key": "endDate",
                  "value": "string",
                  "description": "(Required) End date (`yyyy-MM-dd`), not before `startDate` and at most 1 year after it."
                },
                {
                  "disabled": false,
                  "key": "isDraft",
                  "value": "true",
                  "description": "`false` (default) counts confirmed campaigns, `true` the campaigns not yet confirmed. Rows for messages sent through the API are included either way."
                },
                {
                  "disabled": false,
                  "key": "limit",
                  "value": "719",
                  "description": "Page size, at most 1000 (default 10; 0 also means the default). Sent without `page`, it returns the first page."
                },
                {
                  "disabled": false,
                  "key": "page",
                  "value": "5496",
                  "description": "Page number, 0-based. Without `page` and `limit` every row is returned in one page."
                },
                {
                  "disabled": false,
                  "key": "sendingMode",
                  "value": "string",
                  "description": "`SMS` (case-insensitive) for the SMS figures only. Omit it for every channel."
                },
                {
                  "disabled": false,
                  "key": "startDate",
                  "value": "string",
                  "description": "(Required) Start date (`yyyy-MM-dd`)."
                }
              ],
              "variable": []
            },
            "header": [
              {
                "key": "Accept",
                "value": "application/json"
              }
            ],
            "method": "GET",
            "auth": {
              "type": "apikey",
              "apikey": [
                {
                  "key": "key",
                  "value": "X-API-Key"
                },
                {
                  "key": "value",
                  "value": "{{apiKey}}"
                },
                {
                  "key": "in",
                  "value": "header"
                }
              ]
            }
          },
          "response": [
            {
              "id": "90829c95-1b80-5b1c-abb3-ca6ffc613ff0",
              "name": "The statistics rows of the date range.",
              "originalRequest": {
                "url": {
                  "path": [
                    "api",
                    "partner-gateway",
                    "campaigns",
                    "stats"
                  ],
                  "host": [
                    "{{baseUrl}}"
                  ],
                  "query": [
                    {
                      "key": "aggregateOn",
                      "value": "string"
                    },
                    {
                      "key": "direction",
                      "value": "string"
                    },
                    {
                      "key": "endDate",
                      "value": "string"
                    },
                    {
                      "key": "isDraft",
                      "value": "true"
                    },
                    {
                      "key": "limit",
                      "value": "719"
                    },
                    {
                      "key": "page",
                      "value": "5496"
                    },
                    {
                      "key": "sendingMode",
                      "value": "string"
                    },
                    {
                      "key": "startDate",
                      "value": "string"
                    }
                  ],
                  "variable": []
                },
                "header": [
                  {
                    "key": "Accept",
                    "value": "application/json"
                  }
                ],
                "method": "GET",
                "body": {}
              },
              "status": "OK",
              "code": 200,
              "header": [
                {
                  "key": "Content-Type",
                  "value": "application/json"
                }
              ],
              "body": "{\n  \"data\": [\n    {\n      \"timeBucket\": \"2026-09-01 00:00:00\",\n      \"sendingMode\": \"SMS\",\n      \"isHttpStat\": false,\n      \"numMessageCampaigns\": 5,\n      \"destinationType\": 9499,\n      \"totalDestinations\": 2643,\n      \"totalSent\": 2907,\n      \"totalSuccess\": 396,\n      \"totalRead\": 7422,\n      \"totalFailed\": 6884,\n      \"totalFallback\": 1311,\n      \"smsSent\": 7191,\n      \"smsPending\": 3467,\n      \"smsSuccess\": 6663,\n      \"smsFailed\": 3885,\n      \"smsFallback\": 3430,\n      \"totalSms\": 2392,\n      \"totalPending\": 6474,\n      \"totalDelivered\": 1998,\n      \"totalError\": 3766,\n      \"totalCreditError\": 8461\n    },\n    {\n      \"timeBucket\": \"2026-09-01 00:00:00\",\n      \"sendingMode\": \"SMS\",\n      \"isHttpStat\": false,\n      \"numMessageCampaigns\": 5,\n      \"destinationType\": 8797,\n      \"totalDestinations\": 3113,\n      \"totalSent\": 3753,\n      \"totalSuccess\": 9700,\n      \"totalRead\": 6039,\n      \"totalFailed\": 161,\n      \"totalFallback\": 4892,\n      \"smsSent\": 3183,\n      \"smsPending\": 4026,\n      \"smsSuccess\": 2419,\n      \"smsFailed\": 8226,\n      \"smsFallback\": 5285,\n      \"totalSms\": 4447,\n      \"totalPending\": 8036,\n      \"totalDelivered\": 6891,\n      \"totalError\": 5939,\n      \"totalCreditError\": 2285\n    }\n  ],\n  \"totalCount\": 52,\n  \"page\": 0,\n  \"limit\": 10,\n  \"totalPages\": 6\n}",
              "cookie": [],
              "_postman_previewlanguage": "json"
            },
            {
              "id": "acbf3206-4a77-5599-a8cf-e4ad3ac35893",
              "name": "`startDate`, `endDate` or `aggregateOn` is missing or invalid, the date window is reversed or longer than 1 year, or a key without `CAMPAIGNS` sends no `sendingMode`.",
              "originalRequest": {
                "url": {
                  "path": [
                    "api",
                    "partner-gateway",
                    "campaigns",
                    "stats"
                  ],
                  "host": [
                    "{{baseUrl}}"
                  ],
                  "query": [
                    {
                      "key": "aggregateOn",
                      "value": "string"
                    },
                    {
                      "key": "direction",
                      "value": "string"
                    },
                    {
                      "key": "endDate",
                      "value": "string"
                    },
                    {
                      "key": "isDraft",
                      "value": "true"
                    },
                    {
                      "key": "limit",
                      "value": "719"
                    },
                    {
                      "key": "page",
                      "value": "5496"
                    },
                    {
                      "key": "sendingMode",
                      "value": "string"
                    },
                    {
                      "key": "startDate",
                      "value": "string"
                    }
                  ],
                  "variable": []
                },
                "header": [
                  {
                    "key": "Accept",
                    "value": "application/json"
                  }
                ],
                "method": "GET",
                "body": {}
              },
              "status": "Bad Request",
              "code": 400,
              "header": [
                {
                  "key": "Content-Type",
                  "value": "application/json"
                }
              ],
              "body": "\"\"",
              "cookie": [],
              "_postman_previewlanguage": "json"
            },
            {
              "id": "d4b17977-730d-5ad5-a3ad-ccdc31d46888",
              "name": "The API key is missing or invalid, or holds neither `CAMPAIGNS` nor the operation of every channel of the campaign's `sendingMode`.",
              "originalRequest": {
                "url": {
                  "path": [
                    "api",
                    "partner-gateway",
                    "campaigns",
                    "stats"
                  ],
                  "host": [
                    "{{baseUrl}}"
                  ],
                  "query": [
                    {
                      "key": "aggregateOn",
                      "value": "string"
                    },
                    {
                      "key": "direction",
                      "value": "string"
                    },
                    {
                      "key": "endDate",
                      "value": "string"
                    },
                    {
                      "key": "isDraft",
                      "value": "true"
                    },
                    {
                      "key": "limit",
                      "value": "719"
                    },
                    {
                      "key": "page",
                      "value": "5496"
                    },
                    {
                      "key": "sendingMode",
                      "value": "string"
                    },
                    {
                      "key": "startDate",
                      "value": "string"
                    }
                  ],
                  "variable": []
                },
                "header": [
                  {
                    "key": "Accept",
                    "value": "application/json"
                  }
                ],
                "method": "GET",
                "body": {}
              },
              "status": "Unauthorized",
              "code": 401,
              "header": [
                {
                  "key": "Content-Type",
                  "value": "application/json"
                }
              ],
              "body": "\"\"",
              "cookie": [],
              "_postman_previewlanguage": "json"
            }
          ],
          "event": [],
          "protocolProfileBehavior": {
            "disableBodyPruning": true
          }
        },
        {
          "id": "c6196153-3455-5ccd-a5af-6e9a2f756e69",
          "name": "Generate the description of an SMS campaign",
          "request": {
            "name": "Generate the description of an SMS campaign",
            "description": {
              "content": "Generates a description of the campaign with an AI model and saves it as the campaign `description`, replacing the current one.\n\n- **Source**: the SMS text of the campaign.\n- **No content yet**: nothing is generated and the stored description is left unchanged.\n- **Not a pricing step**: it computes neither recipients nor cost, and confirming a campaign does not require it. For the recipient count and the price, use `GET /campaigns/{id}/price`.\n\n`POST /campaigns/{id}/calculateGoal` is one endpoint for SMS, RCS and WhatsApp: this page describes it for SMS. See it for [RCS](/api-channel-rcs/calculate-goal) or [WhatsApp](/api-channel-whatsapp/calculate-goal).",
              "type": "text/plain"
            },
            "url": {
              "path": [
                "api",
                "partner-gateway",
                "campaigns",
                ":id",
                "calculateGoal"
              ],
              "host": [
                "{{baseUrl}}"
              ],
              "query": [],
              "variable": [
                {
                  "disabled": false,
                  "type": "any",
                  "value": "2518",
                  "key": "id",
                  "description": "(Required) ID of the campaign."
                }
              ]
            },
            "header": [
              {
                "key": "Accept",
                "value": "application/json"
              }
            ],
            "method": "POST",
            "auth": {
              "type": "apikey",
              "apikey": [
                {
                  "key": "key",
                  "value": "X-API-Key"
                },
                {
                  "key": "value",
                  "value": "{{apiKey}}"
                },
                {
                  "key": "in",
                  "value": "header"
                }
              ]
            }
          },
          "response": [
            {
              "id": "59bc400a-77d0-54f2-a963-e19c0409467c",
              "name": "Description generated. The campaign is returned with it.",
              "originalRequest": {
                "url": {
                  "path": [
                    "api",
                    "partner-gateway",
                    "campaigns",
                    ":id",
                    "calculateGoal"
                  ],
                  "host": [
                    "{{baseUrl}}"
                  ],
                  "query": [],
                  "variable": [
                    {
                      "disabled": false,
                      "type": "any",
                      "value": "2518",
                      "key": "id",
                      "description": "(Required) ID of the campaign."
                    }
                  ]
                },
                "header": [
                  {
                    "key": "Accept",
                    "value": "application/json"
                  }
                ],
                "method": "POST",
                "body": {}
              },
              "status": "OK",
              "code": 200,
              "header": [
                {
                  "key": "Content-Type",
                  "value": "application/json"
                }
              ],
              "body": "{\n  \"id\": 1001,\n  \"userId\": 3440,\n  \"companyId\": 3785,\n  \"creationDate\": \"2026-09-01 10:17:53.200+0000\",\n  \"scheduledDate\": \"2026-09-02 09:00:00.000+0000\",\n  \"lastUpdateDate\": \"2026-09-01 10:20:04.512+0000\",\n  \"startDate\": \"2026-09-02 09:00:01.031+0000\",\n  \"endDate\": \"2026-09-02 09:14:37.870+0000\",\n  \"name\": \"Spring Promo\",\n  \"description\": \"string\",\n  \"status\": \"ENDED\",\n  \"sendingMode\": \"SMS\",\n  \"contactListIds\": [\n    5034,\n    8474\n  ],\n  \"totalDestinations\": 7511,\n  \"totalPrice\": 3215,\n  \"walletKind\": \"CREDITS\",\n  \"smsSender\": \"string\",\n  \"smsBody\": \"string\",\n  \"placeholderFields\": {\n    \"key_0\": {}\n  },\n  \"totalSuccess\": 1626,\n  \"totalFailed\": 1602,\n  \"totalSent\": 6969,\n  \"totalRead\": 9188,\n  \"totalFallback\": 8539,\n  \"smsSent\": 7447,\n  \"smsPending\": 9924,\n  \"smsSuccess\": 1230,\n  \"smsFailed\": 8002,\n  \"smsFallback\": 1800,\n  \"destinationType\": 9508,\n  \"destinations\": [\n    \"string\",\n    \"string\"\n  ],\n  \"isUpdatable\": true,\n  \"maxUpdateTime\": \"string\",\n  \"readyToSend\": false,\n  \"numOfDistinctContact\": 1910\n}",
              "cookie": [],
              "_postman_previewlanguage": "json"
            },
            {
              "id": "48b555f4-ae63-586f-ace6-598dd6a0c539",
              "name": "The API key is missing or invalid, or holds neither `CAMPAIGNS` nor the operation of every channel of the campaign's `sendingMode`.",
              "originalRequest": {
                "url": {
                  "path": [
                    "api",
                    "partner-gateway",
                    "campaigns",
                    ":id",
                    "calculateGoal"
                  ],
                  "host": [
                    "{{baseUrl}}"
                  ],
                  "query": [],
                  "variable": [
                    {
                      "disabled": false,
                      "type": "any",
                      "value": "2518",
                      "key": "id",
                      "description": "(Required) ID of the campaign."
                    }
                  ]
                },
                "header": [
                  {
                    "key": "Accept",
                    "value": "application/json"
                  }
                ],
                "method": "POST",
                "body": {}
              },
              "status": "Unauthorized",
              "code": 401,
              "header": [
                {
                  "key": "Content-Type",
                  "value": "application/json"
                }
              ],
              "body": "\"\"",
              "cookie": [],
              "_postman_previewlanguage": "json"
            },
            {
              "id": "f21193d0-d899-5378-a297-cf09e18c78aa",
              "name": "No campaign with this ID in your account.",
              "originalRequest": {
                "url": {
                  "path": [
                    "api",
                    "partner-gateway",
                    "campaigns",
                    ":id",
                    "calculateGoal"
                  ],
                  "host": [
                    "{{baseUrl}}"
                  ],
                  "query": [],
                  "variable": [
                    {
                      "disabled": false,
                      "type": "any",
                      "value": "2518",
                      "key": "id",
                      "description": "(Required) ID of the campaign."
                    }
                  ]
                },
                "header": [
                  {
                    "key": "Accept",
                    "value": "application/json"
                  }
                ],
                "method": "POST",
                "body": {}
              },
              "status": "Not Found",
              "code": 404,
              "header": [
                {
                  "key": "Content-Type",
                  "value": "application/json"
                }
              ],
              "body": "\"\"",
              "cookie": [],
              "_postman_previewlanguage": "json"
            }
          ],
          "event": [],
          "protocolProfileBehavior": {
            "disableBodyPruning": true
          }
        },
        {
          "id": "487724ab-7cc0-54d2-a653-50598be9590d",
          "name": "Delete an SMS campaign",
          "request": {
            "name": "Delete an SMS campaign",
            "description": {
              "content": "Deletes a campaign. This cannot be undone.\n\n- **Not yet confirmed**: the campaign can always be deleted, whether or not it is marked ready to send.\n- **Confirmed and scheduled** (`PRE_BILLED`): it can be deleted only while its `scheduledDate` is still outside the platform's edit window. Deleting it releases the funds reserved at confirmation.\n- **From `READY` onwards**: the campaign is being prepared or sent and can no longer be deleted.\n\nTo stop a scheduled campaign before it is sent, delete it well before its `scheduledDate`.\n\n`DELETE /campaigns/{id}` is one endpoint for SMS, RCS and WhatsApp: this page describes it for SMS. See it for [RCS](/api-channel-rcs/delete-campaign) or [WhatsApp](/api-channel-whatsapp/delete-campaign).",
              "type": "text/plain"
            },
            "url": {
              "path": [
                "api",
                "partner-gateway",
                "campaigns",
                ":id"
              ],
              "host": [
                "{{baseUrl}}"
              ],
              "query": [],
              "variable": [
                {
                  "disabled": false,
                  "type": "any",
                  "value": "2518",
                  "key": "id",
                  "description": "(Required) ID of the campaign."
                }
              ]
            },
            "header": [
              {
                "key": "Accept",
                "value": "application/json"
              }
            ],
            "method": "DELETE",
            "auth": {
              "type": "apikey",
              "apikey": [
                {
                  "key": "key",
                  "value": "X-API-Key"
                },
                {
                  "key": "value",
                  "value": "{{apiKey}}"
                },
                {
                  "key": "in",
                  "value": "header"
                }
              ]
            }
          },
          "response": [
            {
              "id": "501d1f1f-d455-5c1e-ab66-b6e2498ad319",
              "name": "Campaign deleted. No response body.",
              "originalRequest": {
                "url": {
                  "path": [
                    "api",
                    "partner-gateway",
                    "campaigns",
                    ":id"
                  ],
                  "host": [
                    "{{baseUrl}}"
                  ],
                  "query": [],
                  "variable": [
                    {
                      "disabled": false,
                      "type": "any",
                      "value": "2518",
                      "key": "id",
                      "description": "(Required) ID of the campaign."
                    }
                  ]
                },
                "header": [
                  {
                    "key": "Accept",
                    "value": "application/json"
                  }
                ],
                "method": "DELETE",
                "body": {}
              },
              "status": "No Content",
              "code": 204,
              "header": [
                {
                  "key": "Content-Type",
                  "value": "application/json"
                }
              ],
              "body": "\"\"",
              "cookie": [],
              "_postman_previewlanguage": "json"
            },
            {
              "id": "1583f852-438e-5892-a484-bae04ed97cc7",
              "name": "The campaign can no longer be deleted.",
              "originalRequest": {
                "url": {
                  "path": [
                    "api",
                    "partner-gateway",
                    "campaigns",
                    ":id"
                  ],
                  "host": [
                    "{{baseUrl}}"
                  ],
                  "query": [],
                  "variable": [
                    {
                      "disabled": false,
                      "type": "any",
                      "value": "2518",
                      "key": "id",
                      "description": "(Required) ID of the campaign."
                    }
                  ]
                },
                "header": [
                  {
                    "key": "Accept",
                    "value": "application/json"
                  }
                ],
                "method": "DELETE",
                "body": {}
              },
              "status": "Bad Request",
              "code": 400,
              "header": [
                {
                  "key": "Content-Type",
                  "value": "application/json"
                }
              ],
              "body": "\"\"",
              "cookie": [],
              "_postman_previewlanguage": "json"
            },
            {
              "id": "35fe81e8-0f30-5fec-ae66-86206fc82de6",
              "name": "The API key is missing or invalid, or holds neither `CAMPAIGNS` nor the operation of every channel of the campaign's `sendingMode`.",
              "originalRequest": {
                "url": {
                  "path": [
                    "api",
                    "partner-gateway",
                    "campaigns",
                    ":id"
                  ],
                  "host": [
                    "{{baseUrl}}"
                  ],
                  "query": [],
                  "variable": [
                    {
                      "disabled": false,
                      "type": "any",
                      "value": "2518",
                      "key": "id",
                      "description": "(Required) ID of the campaign."
                    }
                  ]
                },
                "header": [
                  {
                    "key": "Accept",
                    "value": "application/json"
                  }
                ],
                "method": "DELETE",
                "body": {}
              },
              "status": "Unauthorized",
              "code": 401,
              "header": [
                {
                  "key": "Content-Type",
                  "value": "application/json"
                }
              ],
              "body": "\"\"",
              "cookie": [],
              "_postman_previewlanguage": "json"
            },
            {
              "id": "c353bdfd-15c8-55b6-a4d7-4f3a482acd65",
              "name": "No campaign with this ID in your account.",
              "originalRequest": {
                "url": {
                  "path": [
                    "api",
                    "partner-gateway",
                    "campaigns",
                    ":id"
                  ],
                  "host": [
                    "{{baseUrl}}"
                  ],
                  "query": [],
                  "variable": [
                    {
                      "disabled": false,
                      "type": "any",
                      "value": "2518",
                      "key": "id",
                      "description": "(Required) ID of the campaign."
                    }
                  ]
                },
                "header": [
                  {
                    "key": "Accept",
                    "value": "application/json"
                  }
                ],
                "method": "DELETE",
                "body": {}
              },
              "status": "Not Found",
              "code": 404,
              "header": [
                {
                  "key": "Content-Type",
                  "value": "application/json"
                }
              ],
              "body": "\"\"",
              "cookie": [],
              "_postman_previewlanguage": "json"
            }
          ],
          "event": [],
          "protocolProfileBehavior": {
            "disableBodyPruning": true
          }
        }
      ]
    },
    {
      "id": "5cbb7cb0-05f4-5302-afc8-66c378cd9bdb",
      "name": "Single SMS sends",
      "item": [
        {
          "id": "9c7007e3-55ed-5af3-af02-d29c1d0213dd",
          "name": "Send SMS Universal",
          "request": {
            "name": "Send SMS Universal",
            "description": {
              "content": "Sends an SMS message to the specified recipient.\n\n- **Placeholders**: insert `{name}` in the body and fill the `placeholders` map.\n- **Concatenation**: long messages are split into parts automatically (multipart SMS).\n- **UDH**: custom User Data Header data for binary SMS.\n- **Scheduling**: set `scheduledDate` to send later.\n- **Dry run**: set `simulation: true` to validate the request without sending.\n\n> **A `202` does not mean the message was accepted.** A request that passes validation is answered `202` also when the message is rejected: check `results.sms.accepted` and, if it is `false`, `results.sms.reasons`.",
              "type": "text/plain"
            },
            "url": {
              "path": [
                "api",
                "message-server",
                "sms",
                "send"
              ],
              "host": [
                "{{baseUrl}}"
              ],
              "query": [],
              "variable": []
            },
            "header": [
              {
                "key": "Content-Type",
                "value": "application/json"
              },
              {
                "key": "Accept",
                "value": "application/json"
              }
            ],
            "method": "POST",
            "auth": null,
            "body": {
              "mode": "raw",
              "raw": "{\n  \"destination\": \"+393201234567\",\n  \"sender\": \"MyBrand\",\n  \"body\": \"Ciao, il tuo ordine è stato spedito!\"\n}",
              "options": {
                "raw": {
                  "language": "json"
                }
              }
            }
          },
          "response": [
            {
              "id": "35e0a22c-f89a-5157-a331-e9fa1ed60a72",
              "name": "Request accepted. Check `results.sms.accepted` to see whether the message was accepted.\n\n- **`accepted: true`** means the message was accepted for sending, not that it was delivered. Delivery confirmation arrives via webhook.\n- **`reasons`** is present only when the message is rejected.",
              "originalRequest": {
                "url": {
                  "path": [
                    "api",
                    "message-server",
                    "sms",
                    "send"
                  ],
                  "host": [
                    "{{baseUrl}}"
                  ],
                  "query": [],
                  "variable": []
                },
                "header": [
                  {
                    "key": "Accept",
                    "value": "application/json"
                  }
                ],
                "method": "POST",
                "body": {
                  "mode": "raw",
                  "raw": "{\n  \"destination\": \"+393201234567\",\n  \"sender\": \"MyBrand\",\n  \"body\": \"Ciao, il tuo ordine è stato spedito!\"\n}",
                  "options": {
                    "raw": {
                      "language": "json"
                    }
                  }
                }
              },
              "status": "Accepted",
              "code": 202,
              "header": [
                {
                  "key": "Content-Type",
                  "value": "application/json"
                }
              ],
              "body": "{\n  \"messageId\": \"a1b2c3d4-e5f6-7890-abcd-ef1234567890\",\n  \"simulation\": false,\n  \"results\": {\n    \"sms\": {\n      \"accepted\": true,\n      \"unicode\": false,\n      \"parts\": 1\n    }\n  }\n}",
              "cookie": [],
              "_postman_previewlanguage": "json"
            },
            {
              "id": "1a2447ac-b938-5410-a6ec-b287f4b018fc",
              "name": "Invalid request. Fields that fail validation are listed in `data`, an object that maps the path of each invalid field (such as `sendSms.request.destination`) to its messages (a too long `campaignId` is reported as `sendSms.request.groupId`); a body that cannot be read, for example a `scheduledDate` in another format, gives `data: \"Invalid request body\"`.",
              "originalRequest": {
                "url": {
                  "path": [
                    "api",
                    "message-server",
                    "sms",
                    "send"
                  ],
                  "host": [
                    "{{baseUrl}}"
                  ],
                  "query": [],
                  "variable": []
                },
                "header": [
                  {
                    "key": "Accept",
                    "value": "application/json"
                  }
                ],
                "method": "POST",
                "body": {
                  "mode": "raw",
                  "raw": "{\n  \"destination\": \"+393201234567\",\n  \"sender\": \"MyBrand\",\n  \"body\": \"Ciao, il tuo ordine è stato spedito!\"\n}",
                  "options": {
                    "raw": {
                      "language": "json"
                    }
                  }
                }
              },
              "status": "Bad Request",
              "code": 400,
              "header": [
                {
                  "key": "Content-Type",
                  "value": "application/json"
                }
              ],
              "body": "{\n  \"status\": \"fail\",\n  \"data\": {\n    \"sendSms.request.destination\": [\n      \"'destination' can't be blank\"\n    ]\n  }\n}",
              "cookie": [],
              "_postman_previewlanguage": "json"
            },
            {
              "id": "03dc53ea-2bfd-53fd-a3e6-40d5cf9aad69",
              "name": "Missing or invalid credentials. The body is empty.",
              "originalRequest": {
                "url": {
                  "path": [
                    "api",
                    "message-server",
                    "sms",
                    "send"
                  ],
                  "host": [
                    "{{baseUrl}}"
                  ],
                  "query": [],
                  "variable": []
                },
                "method": "POST",
                "body": {
                  "mode": "raw",
                  "raw": "{\n  \"destination\": \"+393201234567\",\n  \"sender\": \"MyBrand\",\n  \"body\": \"Ciao, il tuo ordine è stato spedito!\"\n}",
                  "options": {
                    "raw": {
                      "language": "json"
                    }
                  }
                }
              },
              "status": "Unauthorized",
              "code": 401,
              "header": [
                {
                  "key": "Content-Type",
                  "value": "text/plain"
                }
              ],
              "body": "",
              "cookie": [],
              "_postman_previewlanguage": "text"
            },
            {
              "id": "12d88ff4-230d-50d2-a99a-5cdea1d20237",
              "name": "The platform cannot find your account: the message is not stored. Contact support",
              "originalRequest": {
                "url": {
                  "path": [
                    "api",
                    "message-server",
                    "sms",
                    "send"
                  ],
                  "host": [
                    "{{baseUrl}}"
                  ],
                  "query": [],
                  "variable": []
                },
                "header": [
                  {
                    "key": "Accept",
                    "value": "application/json"
                  }
                ],
                "method": "POST",
                "body": {
                  "mode": "raw",
                  "raw": "{\n  \"destination\": \"+393201234567\",\n  \"sender\": \"MyBrand\",\n  \"body\": \"Ciao, il tuo ordine è stato spedito!\"\n}",
                  "options": {
                    "raw": {
                      "language": "json"
                    }
                  }
                }
              },
              "status": "Forbidden",
              "code": 403,
              "header": [
                {
                  "key": "Content-Type",
                  "value": "application/json"
                }
              ],
              "body": "{\n  \"status\": \"fail\",\n  \"message\": \"Company not found\",\n  \"code\": 102\n}",
              "cookie": [],
              "_postman_previewlanguage": "json"
            },
            {
              "id": "6373fd1c-a731-5885-a378-9fb48d750169",
              "name": "Unexpected error while handling the message",
              "originalRequest": {
                "url": {
                  "path": [
                    "api",
                    "message-server",
                    "sms",
                    "send"
                  ],
                  "host": [
                    "{{baseUrl}}"
                  ],
                  "query": [],
                  "variable": []
                },
                "header": [
                  {
                    "key": "Accept",
                    "value": "application/json"
                  }
                ],
                "method": "POST",
                "body": {
                  "mode": "raw",
                  "raw": "{\n  \"destination\": \"+393201234567\",\n  \"sender\": \"MyBrand\",\n  \"body\": \"Ciao, il tuo ordine è stato spedito!\"\n}",
                  "options": {
                    "raw": {
                      "language": "json"
                    }
                  }
                }
              },
              "status": "Internal Server Error",
              "code": 500,
              "header": [
                {
                  "key": "Content-Type",
                  "value": "application/json"
                }
              ],
              "body": "{\n  \"status\": \"error\",\n  \"message\": \"Something bad happened. Please try again!\",\n  \"code\": 8\n}",
              "cookie": [],
              "_postman_previewlanguage": "json"
            },
            {
              "id": "e0fc6033-7e00-5183-ac18-4676a32f1333",
              "name": "The calling IP address is outside the IP ranges configured for your account",
              "originalRequest": {
                "url": {
                  "path": [
                    "api",
                    "message-server",
                    "sms",
                    "send"
                  ],
                  "host": [
                    "{{baseUrl}}"
                  ],
                  "query": [],
                  "variable": []
                },
                "header": [
                  {
                    "key": "Accept",
                    "value": "application/json"
                  }
                ],
                "method": "POST",
                "body": {
                  "mode": "raw",
                  "raw": "{\n  \"destination\": \"+393201234567\",\n  \"sender\": \"MyBrand\",\n  \"body\": \"Ciao, il tuo ordine è stato spedito!\"\n}",
                  "options": {
                    "raw": {
                      "language": "json"
                    }
                  }
                }
              },
              "status": "Network Authentication Required",
              "code": 511,
              "header": [
                {
                  "key": "Content-Type",
                  "value": "application/json"
                }
              ],
              "body": "{\n  \"status\": \"error\",\n  \"message\": \"IP address not allowed\",\n  \"code\": 100\n}",
              "cookie": [],
              "_postman_previewlanguage": "json"
            }
          ],
          "event": [],
          "protocolProfileBehavior": {
            "disableBodyPruning": true
          }
        },
        {
          "id": "e7714ff8-92c8-55a8-ab5f-8b62b601f959",
          "name": "Get the delivery status of an SMS message",
          "request": {
            "name": "Get the delivery status of an SMS message",
            "description": {
              "content": "Returns the current delivery status of one message, looked up by its `customerMessageId` and channel.\n\n- **Which ID to use**: the `messageId` you set when sending (cut to 200 characters), or the one the platform generated; the send response returns it as `messageId`.\n- **`channel` is required**: send `channel=SMS`. With any other channel an SMS answers `404`.\n- **A status exists only after dispatch**: a scheduled message has none before its `scheduledDate`. Allow a few seconds after the send.\n- **Keep your IDs unique**: the platform does not check them. For a reused ID, or an SMS split into several parts, this endpoint returns one of the matching records, chosen arbitrarily, while `GET /messages/status` returns them all.\n\n> **A `404` does not mean the send failed.** It is also the answer while the message has not been dispatched yet, so do not send the message again.\n\n<details>\n<summary>Delivery statuses</summary>\n\n| `deliveryStatus` | Meaning |\n| --- | --- |\n| `ACCEPTED` | Forwarded to the carrier, no delivery receipt yet: the status of an SMS in flight. |\n| `DELIVERED` | The carrier or channel provider confirmed that the message reached the recipient's device. |\n| `REJECTED` | The carrier refused the message. |\n| `UNDELIVERABLE` | The destination cannot receive the message, typically an unreachable or invalid number. |\n| `DELETED` | The message was cancelled before it could be delivered. |\n| `EXPIRED` | Not delivered within its time-to-live window: the carrier discarded it. |\n| `UNKNOWN` | No status information. |\n\nThe Delivery Statuses table in the API overview gives the numeric code the delivery webhook sends for each status.\n\n</details>\n\nTo check many messages in one call, use `GET /messages/status`.\n\n`GET /messages/status/{customerMessageId}` is one endpoint for SMS, RCS and WhatsApp: this page describes it for SMS. See it for [RCS](/api-channel-rcs/get-single-status) or [WhatsApp](/api-channel-whatsapp/get-single-status).",
              "type": "text/plain"
            },
            "url": {
              "path": [
                "api",
                "partner-gateway",
                "messages",
                "status",
                ":customerMessageId"
              ],
              "host": [
                "{{baseUrl}}"
              ],
              "query": [
                {
                  "disabled": false,
                  "key": "channel",
                  "value": "SMS",
                  "description": "(Required) `SMS` (case-insensitive): the channel the messages were sent on."
                }
              ],
              "variable": [
                {
                  "disabled": false,
                  "type": "any",
                  "value": "string",
                  "key": "customerMessageId",
                  "description": "(Required) The `customerMessageId` of the message, returned as `messageId` by the send endpoint."
                }
              ]
            },
            "header": [
              {
                "key": "Accept",
                "value": "application/json"
              }
            ],
            "method": "GET",
            "auth": {
              "type": "apikey",
              "apikey": [
                {
                  "key": "key",
                  "value": "X-API-Key"
                },
                {
                  "key": "value",
                  "value": "{{apiKey}}"
                },
                {
                  "key": "in",
                  "value": "header"
                }
              ]
            }
          },
          "response": [
            {
              "id": "154c09a4-1e00-5707-ad92-2ff554f38941",
              "name": "The delivery status of the message.",
              "originalRequest": {
                "url": {
                  "path": [
                    "api",
                    "partner-gateway",
                    "messages",
                    "status",
                    ":customerMessageId"
                  ],
                  "host": [
                    "{{baseUrl}}"
                  ],
                  "query": [
                    {
                      "key": "channel",
                      "value": "SMS"
                    }
                  ],
                  "variable": [
                    {
                      "disabled": false,
                      "type": "any",
                      "value": "string",
                      "key": "customerMessageId",
                      "description": "(Required) The `customerMessageId` of the message, returned as `messageId` by the send endpoint."
                    }
                  ]
                },
                "header": [
                  {
                    "key": "Accept",
                    "value": "application/json"
                  }
                ],
                "method": "GET",
                "body": {}
              },
              "status": "OK",
              "code": 200,
              "header": [
                {
                  "key": "Content-Type",
                  "value": "application/json"
                }
              ],
              "body": "{\n  \"customerMessageId\": \"msg-sms-001\",\n  \"channel\": \"SMS\",\n  \"destination\": \"+39333123456\",\n  \"deliveryStatus\": \"DELIVERED\",\n  \"deliveryStatusDescription\": \"delivered\",\n  \"sendDate\": \"2025-03-10T14:30:00+01:00\",\n  \"deliveryDate\": \"2025-03-10T14:30:05+01:00\",\n  \"readDate\": null\n}",
              "cookie": [],
              "_postman_previewlanguage": "json"
            },
            {
              "id": "492197f7-0e94-557a-ac00-46f842d36e6f",
              "name": "`channel` is missing or is not one of `RCS`, `WHATSAPP`, `SMS`.",
              "originalRequest": {
                "url": {
                  "path": [
                    "api",
                    "partner-gateway",
                    "messages",
                    "status",
                    ":customerMessageId"
                  ],
                  "host": [
                    "{{baseUrl}}"
                  ],
                  "query": [
                    {
                      "key": "channel",
                      "value": "SMS"
                    }
                  ],
                  "variable": [
                    {
                      "disabled": false,
                      "type": "any",
                      "value": "string",
                      "key": "customerMessageId",
                      "description": "(Required) The `customerMessageId` of the message, returned as `messageId` by the send endpoint."
                    }
                  ]
                },
                "header": [
                  {
                    "key": "Accept",
                    "value": "application/json"
                  }
                ],
                "method": "GET",
                "body": {}
              },
              "status": "Bad Request",
              "code": 400,
              "header": [
                {
                  "key": "Content-Type",
                  "value": "application/json"
                }
              ],
              "body": "\"\"",
              "cookie": [],
              "_postman_previewlanguage": "json"
            },
            {
              "id": "8a07edbb-bc34-5bcd-a858-136984a6354e",
              "name": "The API key is missing, invalid, or lacks the `MESSAGES` operation.",
              "originalRequest": {
                "url": {
                  "path": [
                    "api",
                    "partner-gateway",
                    "messages",
                    "status",
                    ":customerMessageId"
                  ],
                  "host": [
                    "{{baseUrl}}"
                  ],
                  "query": [
                    {
                      "key": "channel",
                      "value": "SMS"
                    }
                  ],
                  "variable": [
                    {
                      "disabled": false,
                      "type": "any",
                      "value": "string",
                      "key": "customerMessageId",
                      "description": "(Required) The `customerMessageId` of the message, returned as `messageId` by the send endpoint."
                    }
                  ]
                },
                "header": [
                  {
                    "key": "Accept",
                    "value": "application/json"
                  }
                ],
                "method": "GET",
                "body": {}
              },
              "status": "Unauthorized",
              "code": 401,
              "header": [
                {
                  "key": "Content-Type",
                  "value": "application/json"
                }
              ],
              "body": "\"\"",
              "cookie": [],
              "_postman_previewlanguage": "json"
            },
            {
              "id": "c329ff73-a46a-5d40-acb1-315af722924f",
              "name": "No message with this `customerMessageId` on this channel for your account: the ID is unknown, the channel is not the one the message was sent on, or the message has not been dispatched yet.",
              "originalRequest": {
                "url": {
                  "path": [
                    "api",
                    "partner-gateway",
                    "messages",
                    "status",
                    ":customerMessageId"
                  ],
                  "host": [
                    "{{baseUrl}}"
                  ],
                  "query": [
                    {
                      "key": "channel",
                      "value": "SMS"
                    }
                  ],
                  "variable": [
                    {
                      "disabled": false,
                      "type": "any",
                      "value": "string",
                      "key": "customerMessageId",
                      "description": "(Required) The `customerMessageId` of the message, returned as `messageId` by the send endpoint."
                    }
                  ]
                },
                "header": [
                  {
                    "key": "Accept",
                    "value": "application/json"
                  }
                ],
                "method": "GET",
                "body": {}
              },
              "status": "Not Found",
              "code": 404,
              "header": [
                {
                  "key": "Content-Type",
                  "value": "application/json"
                }
              ],
              "body": "\"\"",
              "cookie": [],
              "_postman_previewlanguage": "json"
            },
            {
              "id": "633ec7ce-b136-5baa-aa4d-4bacc27718fb",
              "name": "Unexpected server error. Retry after a short delay.",
              "originalRequest": {
                "url": {
                  "path": [
                    "api",
                    "partner-gateway",
                    "messages",
                    "status",
                    ":customerMessageId"
                  ],
                  "host": [
                    "{{baseUrl}}"
                  ],
                  "query": [
                    {
                      "key": "channel",
                      "value": "SMS"
                    }
                  ],
                  "variable": [
                    {
                      "disabled": false,
                      "type": "any",
                      "value": "string",
                      "key": "customerMessageId",
                      "description": "(Required) The `customerMessageId` of the message, returned as `messageId` by the send endpoint."
                    }
                  ]
                },
                "header": [
                  {
                    "key": "Accept",
                    "value": "application/json"
                  }
                ],
                "method": "GET",
                "body": {}
              },
              "status": "Internal Server Error",
              "code": 500,
              "header": [
                {
                  "key": "Content-Type",
                  "value": "application/json"
                }
              ],
              "body": "\"\"",
              "cookie": [],
              "_postman_previewlanguage": "json"
            }
          ],
          "event": [],
          "protocolProfileBehavior": {
            "disableBodyPruning": true
          }
        },
        {
          "id": "64367020-4a66-523d-a827-d79f40211677",
          "name": "Get the delivery status of several SMS messages",
          "request": {
            "name": "Get the delivery status of several SMS messages",
            "description": {
              "content": "Returns the delivery status of several messages in one call, which is much more efficient than calling the single-status endpoint in a loop.\n\n- **Channel**: send `channel=SMS`. All the IDs must be of SMS messages.\n- **`ids`**: the `customerMessageId` values, separated by commas and without spaces, for example `ids=msg-001,msg-002,msg-003`.\n- **At most 200 IDs per call**: split larger lookups over several requests.\n- **Missing IDs are left out, not reported**: an ID that matches no message of your account on that channel is silently omitted, and so is a message not dispatched yet, such as a scheduled message before its `scheduledDate`. If nothing matches you get `200` with an empty array, not `404`.\n- **One ID can return several entries**: an SMS too long for a single part has one entry per part, each with the same `customerMessageId` and no part number, and an ID reused on several sends returns one entry per send.\n\n> **Do not compare counts.** The array is unordered and can be shorter or longer than your list of IDs. To find the missing messages, compare the distinct `customerMessageId` values returned with your list.\n\nEach entry has the fields of `GET /messages/status/{customerMessageId}`, including `deliveryStatus`, whose values are in the Delivery Statuses table of the API overview. To list the messages sent through the API in a date range, use `GET /messages/history`.\n\n`GET /messages/status` is one endpoint for SMS, RCS and WhatsApp: this page describes it for SMS. See it for [RCS](/api-channel-rcs/get-batch-status) or [WhatsApp](/api-channel-whatsapp/get-batch-status).",
              "type": "text/plain"
            },
            "url": {
              "path": [
                "api",
                "partner-gateway",
                "messages",
                "status"
              ],
              "host": [
                "{{baseUrl}}"
              ],
              "query": [
                {
                  "disabled": false,
                  "key": "channel",
                  "value": "SMS",
                  "description": "(Required) `SMS` (case-insensitive): the channel the messages were sent on."
                },
                {
                  "disabled": false,
                  "key": "ids",
                  "value": "string",
                  "description": "(Required) Comma-separated `customerMessageId` values returned at send time, such as `msg-001,msg-002,msg-003`, at most 200."
                }
              ],
              "variable": []
            },
            "header": [
              {
                "key": "Accept",
                "value": "application/json"
              }
            ],
            "method": "GET",
            "auth": {
              "type": "apikey",
              "apikey": [
                {
                  "key": "key",
                  "value": "X-API-Key"
                },
                {
                  "key": "value",
                  "value": "{{apiKey}}"
                },
                {
                  "key": "in",
                  "value": "header"
                }
              ]
            }
          },
          "response": [
            {
              "id": "8930089b-aaf5-53a3-a6d4-5232ca926b92",
              "name": "The delivery status entries found, in no particular order: an empty array when no ID matches.",
              "originalRequest": {
                "url": {
                  "path": [
                    "api",
                    "partner-gateway",
                    "messages",
                    "status"
                  ],
                  "host": [
                    "{{baseUrl}}"
                  ],
                  "query": [
                    {
                      "key": "channel",
                      "value": "SMS"
                    },
                    {
                      "key": "ids",
                      "value": "string"
                    }
                  ],
                  "variable": []
                },
                "header": [
                  {
                    "key": "Accept",
                    "value": "application/json"
                  }
                ],
                "method": "GET",
                "body": {}
              },
              "status": "OK",
              "code": 200,
              "header": [
                {
                  "key": "Content-Type",
                  "value": "application/json"
                }
              ],
              "body": "[\n  {\n    \"customerMessageId\": \"msg-001\",\n    \"channel\": \"SMS\",\n    \"destination\": \"+39333123456\",\n    \"deliveryStatus\": \"DELIVERED\",\n    \"deliveryStatusDescription\": \"delivered\",\n    \"sendDate\": \"2025-03-10T14:30:00+01:00\",\n    \"deliveryDate\": \"2025-03-10T14:30:05+01:00\",\n    \"readDate\": null\n  },\n  {\n    \"customerMessageId\": \"msg-002\",\n    \"channel\": \"SMS\",\n    \"destination\": \"+39333654321\",\n    \"deliveryStatus\": \"UNDELIVERABLE\",\n    \"deliveryStatusDescription\": \"undeliverable\",\n    \"sendDate\": \"2025-03-10T14:30:00+01:00\",\n    \"deliveryDate\": null,\n    \"readDate\": null\n  }\n]",
              "cookie": [],
              "_postman_previewlanguage": "json"
            },
            {
              "id": "79da500d-943c-5179-a6bf-7c3d0abda017",
              "name": "`channel` or `ids` is missing, `channel` is not one of `RCS`, `WHATSAPP`, `SMS`, or `ids` holds more than 200 values.",
              "originalRequest": {
                "url": {
                  "path": [
                    "api",
                    "partner-gateway",
                    "messages",
                    "status"
                  ],
                  "host": [
                    "{{baseUrl}}"
                  ],
                  "query": [
                    {
                      "key": "channel",
                      "value": "SMS"
                    },
                    {
                      "key": "ids",
                      "value": "string"
                    }
                  ],
                  "variable": []
                },
                "header": [
                  {
                    "key": "Accept",
                    "value": "application/json"
                  }
                ],
                "method": "GET",
                "body": {}
              },
              "status": "Bad Request",
              "code": 400,
              "header": [
                {
                  "key": "Content-Type",
                  "value": "application/json"
                }
              ],
              "body": "\"\"",
              "cookie": [],
              "_postman_previewlanguage": "json"
            },
            {
              "id": "9a77463e-a895-5c19-a84f-04013d789c3f",
              "name": "The API key is missing, invalid, or lacks the `MESSAGES` operation.",
              "originalRequest": {
                "url": {
                  "path": [
                    "api",
                    "partner-gateway",
                    "messages",
                    "status"
                  ],
                  "host": [
                    "{{baseUrl}}"
                  ],
                  "query": [
                    {
                      "key": "channel",
                      "value": "SMS"
                    },
                    {
                      "key": "ids",
                      "value": "string"
                    }
                  ],
                  "variable": []
                },
                "header": [
                  {
                    "key": "Accept",
                    "value": "application/json"
                  }
                ],
                "method": "GET",
                "body": {}
              },
              "status": "Unauthorized",
              "code": 401,
              "header": [
                {
                  "key": "Content-Type",
                  "value": "application/json"
                }
              ],
              "body": "\"\"",
              "cookie": [],
              "_postman_previewlanguage": "json"
            },
            {
              "id": "a04e7a06-943b-520a-a979-bc5f3e075988",
              "name": "Unexpected server error. Retry after a short delay.",
              "originalRequest": {
                "url": {
                  "path": [
                    "api",
                    "partner-gateway",
                    "messages",
                    "status"
                  ],
                  "host": [
                    "{{baseUrl}}"
                  ],
                  "query": [
                    {
                      "key": "channel",
                      "value": "SMS"
                    },
                    {
                      "key": "ids",
                      "value": "string"
                    }
                  ],
                  "variable": []
                },
                "header": [
                  {
                    "key": "Accept",
                    "value": "application/json"
                  }
                ],
                "method": "GET",
                "body": {}
              },
              "status": "Internal Server Error",
              "code": 500,
              "header": [
                {
                  "key": "Content-Type",
                  "value": "application/json"
                }
              ],
              "body": "\"\"",
              "cookie": [],
              "_postman_previewlanguage": "json"
            }
          ],
          "event": [],
          "protocolProfileBehavior": {
            "disableBodyPruning": true
          }
        },
        {
          "id": "2e080053-7699-59c4-a800-e28a22d62c76",
          "name": "List the SMS send history",
          "request": {
            "name": "List the SMS send history",
            "description": {
              "content": "Returns the messages sent through the API on SMS in a date range, one page at a time.\n\n- **Required**: `channel=SMS` and the send-date range `from` and `to`, both inclusive.\n- **Campaign messages are not included**, not even those of campaigns created with `POST /campaigns`. Follow a campaign with `GET /campaigns/{id}` and `GET /campaigns/stats`, or export its delivery reports with `POST /exports/delivery-reports` and its `campaignId`.\n- **One entry per sent record**: an SMS too long for a single part appears once per part, every part with the same `customerMessageId`. `page` and `limit` count those entries.\n- **Pagination**: `page` is 0-based and `limit` goes from 1 to 1000 (default 20). Without `status`, move to the next page until one comes back with fewer items than `limit`.\n- **Large ranges**: to extract thousands of messages, queue a CSV file with `POST /messages/history/export` instead of paging.\n\n> **With `status`, a short or empty page does not mean the end.** The filter is applied to each page of `limit` messages after it has been read, so a page can hold fewer items than `limit`, or none, while later pages still hold matching messages. To collect every message in one status, page without `status` and keep the entries whose `deliveryStatus` you want.\n\n<details>\n<summary>Date formats of from and to</summary>\n\n| Format | Example | Read as |\n|---|---|---|\n| Date alone | `2025-01-15` | The whole day in UTC: `00:00:00Z` as `from`, `23:59:59Z` as `to`. |\n| Date-time without offset | `2025-01-15T10:30:00` | UTC. |\n| ISO-8601 date-time with offset | `2025-01-15T00:00:00+01:00` or `2025-06-15T23:59:59Z` | That instant. |\n\nPercent-encode a `+` in the offset as `%2B`: an unencoded `+` is decoded as a space.\n\n</details>\n\n<details>\n<summary>Values of the status filter</summary>\n\n`ACCEPTED`, `REJECTED`, `DELIVERED`, `EXPIRED`, `DELETED`, `UNDELIVERABLE`, `ERROR`, `DISABLED`, `UNSUPPORTED`, `CONVERSATION_CLOSED` or `UNKNOWN`, in any letter case. Which ones can appear depends on the channel: see the Delivery Statuses table in the API overview. Leave `status` out for every status.\n\nFor SMS, the export is an alternative to the filter: its `Delivery result` column carries the SMS status. On RCS and WhatsApp the export only tells sent from delivered.\n\n</details>\n\n`GET /messages/history` is one endpoint for SMS, RCS and WhatsApp: this page describes it for SMS. See it for [RCS](/api-channel-rcs/get-history) or [WhatsApp](/api-channel-whatsapp/get-history).",
              "type": "text/plain"
            },
            "url": {
              "path": [
                "api",
                "partner-gateway",
                "messages",
                "history"
              ],
              "host": [
                "{{baseUrl}}"
              ],
              "query": [
                {
                  "disabled": false,
                  "key": "channel",
                  "value": "SMS",
                  "description": "(Required) `SMS` (case-insensitive): the channel the messages were sent on."
                },
                {
                  "disabled": false,
                  "key": "from",
                  "value": "2025-01-15T00:00:00Z",
                  "description": "(Required) Start of the send-date range, inclusive: `yyyy-MM-dd` (a whole day, UTC), `yyyy-MM-ddTHH:mm:ss` (UTC) or ISO-8601 with an offset, such as `2025-01-15T00:00:00+01:00` or `2025-01-15T00:00:00Z`. A date alone means the start of that day, `00:00:00Z`."
                },
                {
                  "disabled": false,
                  "key": "limit",
                  "value": "20",
                  "description": "Page size, from 1 to 1000. Defaults to 20."
                },
                {
                  "disabled": false,
                  "key": "page",
                  "value": "0",
                  "description": "Page index, 0-based."
                },
                {
                  "disabled": false,
                  "key": "status",
                  "value": "EXPIRED",
                  "description": "Delivery-status filter, case-insensitive: `ACCEPTED`, `REJECTED`, `DELIVERED`, `EXPIRED`, `DELETED`, `UNDELIVERABLE`, `ERROR`, `DISABLED`, `UNSUPPORTED`, `CONVERSATION_CLOSED` or `UNKNOWN`. It is applied to each page after the page has been read, so a filtered page can be short or empty while later pages still hold matching messages."
                },
                {
                  "disabled": false,
                  "key": "to",
                  "value": "2025-01-31T23:59:59Z",
                  "description": "(Required) End of the send-date range, inclusive: `yyyy-MM-dd` (a whole day, UTC), `yyyy-MM-ddTHH:mm:ss` (UTC) or ISO-8601 with an offset, such as `2025-01-15T00:00:00+01:00` or `2025-01-15T00:00:00Z`. A date alone means the end of that day, `23:59:59Z`."
                }
              ],
              "variable": []
            },
            "header": [
              {
                "key": "Accept",
                "value": "application/json"
              }
            ],
            "method": "GET",
            "auth": {
              "type": "apikey",
              "apikey": [
                {
                  "key": "key",
                  "value": "X-API-Key"
                },
                {
                  "key": "value",
                  "value": "{{apiKey}}"
                },
                {
                  "key": "in",
                  "value": "header"
                }
              ]
            }
          },
          "response": [
            {
              "id": "37cdf7a9-63fe-5eeb-a3e4-0f2e1d8a77c7",
              "name": "One page of sent messages: an empty array when nothing on the page matches the filters.",
              "originalRequest": {
                "url": {
                  "path": [
                    "api",
                    "partner-gateway",
                    "messages",
                    "history"
                  ],
                  "host": [
                    "{{baseUrl}}"
                  ],
                  "query": [
                    {
                      "key": "channel",
                      "value": "SMS"
                    },
                    {
                      "key": "from",
                      "value": "2025-01-15T00:00:00Z"
                    },
                    {
                      "key": "limit",
                      "value": "20"
                    },
                    {
                      "key": "page",
                      "value": "0"
                    },
                    {
                      "key": "status",
                      "value": "EXPIRED"
                    },
                    {
                      "key": "to",
                      "value": "2025-01-31T23:59:59Z"
                    }
                  ],
                  "variable": []
                },
                "header": [
                  {
                    "key": "Accept",
                    "value": "application/json"
                  }
                ],
                "method": "GET",
                "body": {}
              },
              "status": "OK",
              "code": 200,
              "header": [
                {
                  "key": "Content-Type",
                  "value": "application/json"
                }
              ],
              "body": "[\n  {\n    \"customerMessageId\": \"msg-sms-001\",\n    \"channel\": \"SMS\",\n    \"destination\": \"+39333123456\",\n    \"deliveryStatus\": \"DELIVERED\",\n    \"deliveryStatusDescription\": \"delivered\",\n    \"sendDate\": \"2025-01-15T10:00:00+01:00\",\n    \"deliveryDate\": \"2025-01-15T10:00:03+01:00\",\n    \"readDate\": null\n  }\n]",
              "cookie": [],
              "_postman_previewlanguage": "json"
            },
            {
              "id": "57d3db40-59f0-5d59-ab67-5f2cd16485b8",
              "name": "`channel`, `from` or `to` is missing or malformed, `from` is later than `to`, `status` is not one of the accepted values, or `page` or `limit` is not a whole number in range (`page` below 0, `limit` below 1 or above 1000, or `page` multiplied by `limit` above 2147483647). The response body names the parameter.",
              "originalRequest": {
                "url": {
                  "path": [
                    "api",
                    "partner-gateway",
                    "messages",
                    "history"
                  ],
                  "host": [
                    "{{baseUrl}}"
                  ],
                  "query": [
                    {
                      "key": "channel",
                      "value": "SMS"
                    },
                    {
                      "key": "from",
                      "value": "2025-01-15T00:00:00Z"
                    },
                    {
                      "key": "limit",
                      "value": "20"
                    },
                    {
                      "key": "page",
                      "value": "0"
                    },
                    {
                      "key": "status",
                      "value": "EXPIRED"
                    },
                    {
                      "key": "to",
                      "value": "2025-01-31T23:59:59Z"
                    }
                  ],
                  "variable": []
                },
                "header": [
                  {
                    "key": "Accept",
                    "value": "application/json"
                  }
                ],
                "method": "GET",
                "body": {}
              },
              "status": "Bad Request",
              "code": 400,
              "header": [
                {
                  "key": "Content-Type",
                  "value": "application/json"
                }
              ],
              "body": "\"\"",
              "cookie": [],
              "_postman_previewlanguage": "json"
            },
            {
              "id": "7f5288f1-d730-5a56-a121-6d81a1649a4e",
              "name": "The API key is missing, invalid, or lacks the `MESSAGES` operation.",
              "originalRequest": {
                "url": {
                  "path": [
                    "api",
                    "partner-gateway",
                    "messages",
                    "history"
                  ],
                  "host": [
                    "{{baseUrl}}"
                  ],
                  "query": [
                    {
                      "key": "channel",
                      "value": "SMS"
                    },
                    {
                      "key": "from",
                      "value": "2025-01-15T00:00:00Z"
                    },
                    {
                      "key": "limit",
                      "value": "20"
                    },
                    {
                      "key": "page",
                      "value": "0"
                    },
                    {
                      "key": "status",
                      "value": "EXPIRED"
                    },
                    {
                      "key": "to",
                      "value": "2025-01-31T23:59:59Z"
                    }
                  ],
                  "variable": []
                },
                "header": [
                  {
                    "key": "Accept",
                    "value": "application/json"
                  }
                ],
                "method": "GET",
                "body": {}
              },
              "status": "Unauthorized",
              "code": 401,
              "header": [
                {
                  "key": "Content-Type",
                  "value": "application/json"
                }
              ],
              "body": "\"\"",
              "cookie": [],
              "_postman_previewlanguage": "json"
            },
            {
              "id": "1bff2978-e66e-58c1-a0c6-8725959fd3c1",
              "name": "Unexpected server error. Retry after a short delay.",
              "originalRequest": {
                "url": {
                  "path": [
                    "api",
                    "partner-gateway",
                    "messages",
                    "history"
                  ],
                  "host": [
                    "{{baseUrl}}"
                  ],
                  "query": [
                    {
                      "key": "channel",
                      "value": "SMS"
                    },
                    {
                      "key": "from",
                      "value": "2025-01-15T00:00:00Z"
                    },
                    {
                      "key": "limit",
                      "value": "20"
                    },
                    {
                      "key": "page",
                      "value": "0"
                    },
                    {
                      "key": "status",
                      "value": "EXPIRED"
                    },
                    {
                      "key": "to",
                      "value": "2025-01-31T23:59:59Z"
                    }
                  ],
                  "variable": []
                },
                "header": [
                  {
                    "key": "Accept",
                    "value": "application/json"
                  }
                ],
                "method": "GET",
                "body": {}
              },
              "status": "Internal Server Error",
              "code": 500,
              "header": [
                {
                  "key": "Content-Type",
                  "value": "application/json"
                }
              ],
              "body": "\"\"",
              "cookie": [],
              "_postman_previewlanguage": "json"
            }
          ],
          "event": [],
          "protocolProfileBehavior": {
            "disableBodyPruning": true
          }
        }
      ]
    }
  ],
  "auth": {
    "type": "apikey",
    "apikey": [
      {
        "key": "key",
        "value": "X-Api-Key",
        "type": "string"
      },
      {
        "key": "value",
        "value": "{{apiKey}}",
        "type": "string"
      },
      {
        "key": "in",
        "value": "header",
        "type": "string"
      }
    ]
  },
  "variable": [
    {
      "key": "baseUrl",
      "value": "https://api.qlara.ai",
      "type": "string"
    },
    {
      "key": "apiKey",
      "value": "YOUR_API_KEY",
      "type": "string"
    }
  ]
}
