tenant.yaml reference
One file per tenant, in <tenants_dir>/<name>/tenant.yaml. Paths inside it
resolve against the tenant directory.
name: acme
description: Acme Industries
domains: [acme.pbx.example.com]
dids: {...}
caller_id: {...}
accounts: [...]
ring_groups: {...}
inbound_routes: [...]
outbound_routes: [...]
moh: {...}
timezone: Europe/Amsterdam
inter_tenant: [globex]
extensions_dir: extensions
Top level
| Key | Type | Default | Purpose |
|---|---|---|---|
name | string | directory name | The tenant identifier. |
description | string | — | Free text, shown in the editor. |
domains | list | — | SIP domains this tenant's phones register with. Must be unique across tenants. |
dids | object | — | Numbers this tenant owns on the shared trunks. |
caller_id | object | — | Overrides the trunk's caller ID on outgoing calls. |
accounts | list | — | SIP credentials. |
ring_groups | map | — | Named groups of targets. |
inbound_routes | list | — | DID → destination inside this tenant. |
outbound_routes | list | — | Tried before the global routes. Same shape as the global ones. |
moh | object | — | Music-on-hold classes, layered over the global ones. |
timezone | string | global timezone | IANA timezone for this tenant's time conditions. |
inter_tenant | list | — | Tenants this one may dial. Only effective with global allow_inter_tenant. |
extensions_dir | string | extensions | Directory of dialplan files. |
dids
dids:
numbers: ["+31201234567", "+31201234568"]
patterns: ['^\+312012345\d{2}$']
| Key | Type | Notes |
|---|---|---|
numbers | list | Exact claims. Checked before patterns. |
patterns | list | Go regular expressions. Not anchored implicitly. |
A number claimed by two tenants is a validation error.
caller_id
caller_id:
number: "+31201234567"
name: Acme
| Key | Type | Notes |
|---|---|---|
number | string | Presented on outgoing calls, ahead of the trunk's. |
name | string | Display name. |
accounts[]
accounts:
- username: alice
password: "..."
extension: "100"
display_name: Alice
| Key | Type | Required | Notes |
|---|---|---|---|
username | string | yes | SIP username, unique within the tenant. |
password | string | yes | Digest password, stored in plain text. |
extension | string | yes | Extension this account belongs to. Several accounts may share one. |
display_name | string | no | Caller name on internal calls. |
ring_groups
ring_groups:
support:
strategy: simultaneous
targets: ["100", "101", "external:0612345678"]
timeout: 30s
| Key | Type | Required | Notes |
|---|---|---|---|
strategy | string | yes | simultaneous or sequential. |
targets | list | yes | At least one target reference. |
timeout | duration | no | Total ring time for simultaneous; per-target time for sequential. Defaults to 30s. |
inbound_routes[]
inbound_routes:
- did: "+31201234567"
destination: {type: extension, target: "200"}
| Key | Type | Required | Notes |
|---|---|---|---|
did | string | yes | The number as it arrives, or * for a catch-all inside the tenant. |
destination.type | string | yes | extension or ring_group. |
destination.target | string | yes | Extension number, or ring group name. Must exist. |
outbound_routes[]
Identical in shape to the global outbound routes, and tried before them.
moh
moh:
default: ../../sounds/moh/acme.wav
classes:
jazz: ../../sounds/moh/acme-jazz.wav
Layered over the global map key by key: a class defined in both resolves to the tenant's file.
Target references
Wherever a target is accepted — ring group targets, follow-me stage targets, a
dial step's endpoint — these three forms are valid:
| Form | Meaning |
|---|---|
"101" | An account extension of this tenant. |
external:0612345678 | A number placed through the outbound routes. |
tenant:globex/900 | Another tenant's extension, when inter-tenant calling is allowed on both switches. |
Validation
ring_groups: invalid strategy; no targets; a target that is not a valid reference.inbound_routes: a destination type that is notextensionorring_group; an unknown extension or ring group.outbound_routes: a pattern that does not compile; an unknown trunk.- Target references: an extension that is not an account extension of the
tenant; an empty
external:target; atenant:reference withoutallow_inter_tenant, without the tenant ininter_tenant, naming an unknown tenant, or naming an extension that tenant has no account for. - Across tenants: duplicate domains and duplicate DIDs.