> For the complete documentation index, see [llms.txt](https://documentation.rcore.cz/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://documentation.rcore.cz/paid-resources/rcore_housing/features/alarm-system.md).

# Alarm System

The alarm system reacts to break-in attempts on a property. It has three optional outputs: dispatch alert, alarm sound, and owner SMS.

## 🚨 Triggers

Three alarm events can fire:

| State        | When it fires                        |
| ------------ | ------------------------------------ |
| `ON_START`   | A lockpick or breach attempt begins. |
| `ON_SUCCESS` | A burglar successfully gains entry.  |
| `ON_FAIL`    | A break-in attempt is repelled.      |

Each output has its own `Events` map deciding which states it reacts to - see [security configuration](/paid-resources/rcore_housing/configuration/security.md).

## 👮 Dispatch

```lua
Config.Alarm.Dispatch = { Enable = true, Jobs = { 'police', 'sheriff' }, ... }
```

Dispatch fires by default on `ON_START`. The alert shows a blip at the property for `ShowTime` seconds and re-arms after `DelayPerProperty` seconds.

Dispatch works **without** the alarm upgrade - it always fires. The alarm upgrade is required for sound and SMS.

The dispatch integration is configured under [dispatch integration](/paid-resources/rcore_housing/integrations/dispatch.md).

## 🔊 Alarm Sound

```lua
Config.Alarm.AlarmSound = { Enable = true, Url = '...', Range = 75.0, Duration = 120 }
```

Plays a looping alarm at the property when the configured state fires (default: `ON_FAIL`). Audible within `Range` metres for `Duration` seconds (or once if `Duration = nil`).

Replace `Url` with a self-hosted mirror if you don't want to depend on the rco.re CDN.

## 📱 Owner SMS

```lua
Config.Alarm.Owner = { Enable = true, MaxPhoneList = 3 }
```

The owner can register up to `MaxPhoneList` phone numbers per property. Each registered number receives an SMS when the configured state fires (default: `ON_START`).

Registration uses a PIN verification flow with a `CodeExpiry` of 120 seconds.

SMS delivery uses the [phone integration](/paid-resources/rcore_housing/integrations/phone.md). When the phone bridge is Standalone, SMS is silently dropped.

## ⚡ Alarm Upgrade Requirement

```lua
Config.Alarm.RequireUpgrade = true
```

When `true`, sound and SMS only fire if the property has the [Alarm upgrade](/paid-resources/rcore_housing/features/upgrades.md) installed. Dispatch fires regardless - that's the baseline service.

Set to `false` to make sound and SMS available to every property without buying the upgrade.
