> ## Documentation Index
> Fetch the complete documentation index at: https://docs.firetone.com.au/llms.txt
> Use this file to discover all available pages before exploring further.

# SMS

> Text messages through your own FireFlo account: sender IDs, templates, and what was sent.

FireTone sends SMS through **your organisation's own** FireFlo account. You
bring the account; FireTone keeps its login, a copy of what your provider has
approved, and every message it sends with what became of it. SMS costs you what
FireFlo charges; FireTone adds nothing.

## Connecting the account

**Settings → SMS** (operators: choose the organisation in the page header first):

| Field               | What to put                                                                                                            |
| ------------------- | ---------------------------------------------------------------------------------------------------------------------- |
| **Gateway address** | Your FireFlo gateway, e.g. `https://sms.example.com`. No `/secure/` path                                               |
| **Login**           | A FireFlo login of type **HTTP**. An SMPP login cannot use the API, and FireFlo refuses it as *Authentication failure* |
| **Password**        | Stored encrypted and never shown again                                                                                 |

**Connect** tests the login and syncs your balance, your sender IDs and your
approved wording. **Sync now** refreshes them; do it after your provider
approves something.

<Note>
  A gateway on a private network is refused unless the server allows private
  addresses (`FIRETONE_HTTP_ALLOW_PRIVATE`), the same rule as an IVR's Fetch
  data step.
</Note>

## Sender IDs

The names your messages come from. Your provider approves them; FireTone shows
their state:

| State         | Can send?                                                 |
| ------------- | --------------------------------------------------------- |
| **Approved**  | Yes                                                       |
| **Pending**   | No, waiting for your provider                             |
| **Rejected**  | No                                                        |
| **Withdrawn** | No: it was approved and your provider has switched it off |
| **Gone**      | No: FireFlo no longer lists it                            |

**Make default** chooses the one every SMS comes from unless its template or
IVR step names another. **Request a sender ID** files the request with your
provider; it is usable once they approve it. Without any sender ID, FireFlo
sends from your login name, which an enforcing account usually refuses.

## Approved wording

Some accounts accept only messages that match wording the provider approved
(India's DLT rules are the usual reason). The account card says which yours is.
On such an account, every template is checked against the approved wording as
you edit it, and a warning says when FireFlo would refuse it. **Request
wording** files new wording, with `{#var#}`, `{#num#}` or `{#alp#}` where it
varies.

## Templates

**SMS templates** holds the wording for each kind of SMS: after a missed call,
after a call, new voicemail, and alerts. Each starts with built-in wording that
you can replace, and **Reset** puts it back. **IVR SMS templates** are named
ones for the IVR's Send SMS step.

* Variables work as in email: click one to insert it (`{{caller}}`,
  `{{org.name}}`). A variable the SMS does not have is refused when you save.
* The editor counts characters and SMS parts with the sample values. Curly
  quotes, dashes and ellipses are replaced with plain ones before sending,
  because one of them would make the whole message Unicode: 70 characters per
  SMS instead of 160. The editor names any character that still does that.
* **Send from** picks an approved sender ID, or leaves the default.
* **Send test** sends it, with the sample values, to a number in international
  form (`+61412345678`).

## After-call SMS

**After-call SMS** texts the caller once a call is over:

* **After a missed call**: the call rang an extension or a queue, nobody
  answered, and the caller left no message. A call the caller finished in the
  IVR on their own is not missed.
* **After a call that reached somebody.**

Each rule can apply to every number or to one, send from a chosen sender ID,
and has a **quiet window** (60 minutes unless you change it): a caller who rings
three times in that window is texted once. The wording is the *After a missed
call* or *After a call* template. Only callers with a mobile number are texted:
an internal extension or an anonymous caller is not. Flow test calls never are.

## Alerts and voicemail by SMS

* **Alerts**: in Organisations → edit, **Text alerts to** takes up to five
  mobiles. A toll-fraud alert is texted to them as well as emailed.
* **Voicemail**: in the extension's settings, **Text new voicemail to** gets a
  short text for each new message: who called, how long, and a link to listen.

## Sent SMS

Every SMS, newest first:

| Status          | Meaning                                                         |
| --------------- | --------------------------------------------------------------- |
| **Queued**      | Waiting to go, or waiting to try again                          |
| **Accepted**    | FireFlo took it. Not yet a delivery                             |
| **Delivered**   | The handset got it (a delivery receipt said so)                 |
| **Undelivered** | The network gave up; the receipt's error code is shown          |
| **Failed**      | FireFlo refused it (credit, sender ID, wording), with its words |

A refusal is not retried; **Send again** is there when you have fixed the cause.
A busy gateway (429, 500) is retried after 1, 5 and 30 minutes. If FireFlo took
the message and then did not answer, FireTone does not send it again, because
FireFlo has no way to tell a repeat from a new message. That row says to check
the FireFlo portal.

Delivery receipts need the platform's base domain, which FireFlo reports to. The
account card shows the address. Without it, SMS stay at **Accepted**.

An organisation sends at most 500 SMS an hour, so a loop in a flow cannot empty
the account before anybody notices.
