> For the complete documentation index, see [llms.txt](https://mango-5m.gitbook.io/mango5m-docs/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://mango-5m.gitbook.io/mango5m-docs/resources/mango-dispatch/features/911-calls.md).

# 911 Calls

The player-facing /911 command - what it sends and how it is limited.

Any player can report an emergency. They do not need to be a unit, have a job, or own a phone item.

```
/911 someone is breaking into the store on Innocence Blvd
```

### What units receive

A normal call with:

| Field               | Filled with                                                                 |
| ------------------- | --------------------------------------------------------------------------- |
| Code                | `911`                                                                       |
| Title / description | The player's message, trimmed to 150 / 255 characters                       |
| Caller name         | Their character name, from the framework                                    |
| Caller number       | Their phone number if the framework has one, otherwise `Unknown`            |
| Location            | Their exact coordinates, plus the street and area resolved on their machine |

The caller gets a confirmation notification: *"Your 911 call has been passed to dispatch."*

### Configuration

```lua
    call911 = {
        enabled = true,
        command = '911',
        cooldownSeconds = 15,
    },
```

| Key               | Effect                                                                                         |
| ----------------- | ---------------------------------------------------------------------------------------------- |
| `enabled = false` | The command is never registered at all - hand 911 to your phone resource instead               |
| `command`         | Rename it. `'call911'` gives `/call911`                                                        |
| `cooldownSeconds` | Per-player. Inside the window they are told they already called recently and no call is raised |

The command is registered with a chat suggestion, so it autocompletes with a usage hint. Sending it with no message replies with the usage line rather than raising an empty call.

### Guards

* Empty or whitespace-only messages are rejected.
* Coordinates are validated server-side; a call with impossible coordinates never reaches the board.
* The cooldown is keyed to the player's **identifier**, so reconnecting does not reset it.

### Routing 911 through your own phone

Turn the built-in command off and raise the call yourself, so you keep your phone's UI and history:

```lua
Config.Dispatch.call911.enabled = false
```

```lua
-- in your phone resource, server side
exports['mango_dispatch']:CreateCall({
    code = '911',
    title = message,
    callerName = callerName,
    callerNumber = number,
    x = coords.x, y = coords.y, z = coords.z,
})
```

See [Raising Calls](/mango5m-docs/resources/mango-dispatch/developer-guide/raising-calls.md) for the full field list.
