How call flows work¶
Everything a call does in siphon-pbx is decided by a call flow: what plays, who rings, when the office is closed, where a call goes when nobody answers. A flow is drawn on a canvas in the console, not written as a dialplan, and the same flow runs live calls and simulated ones.
Blocks, ports and cables¶
A flow is a set of blocks joined by cables. Each block does one thing, such as checking the time against a
schedule, playing a prompt or ringing a group, and leaves by one of its output ports: a time schedule
leaves by inside, outside or holiday, a ring group by no_answer, busy or unavailable. A cable
runs from a port to the next block. A port carries at most one cable; a block can take any number.
Every port has to be connected before a flow can be published, so no call is ever left with nowhere to go.
The exceptions are the ones a block answers for itself: a Dial out block's failure ports, and the
transferred port of the voice blocks. A block that hands the call to a person (a ring that is answered,
a queue agent who picks up, a call placed out that connects) ends the flow for that call, so only its
failure ports carry on.
Cables may loop back, so a menu can repeat itself. A flow cannot spin, though: a call that runs a long chain of steps without ever waiting for anything (a key, a ring, a prompt) is ended with an error.
Flow blocks lists every block, its settings and its ports.
Where a flow starts¶
A flow starts with one of two blocks, and that decides which calls it takes.
- Inbound number: calls to the organisation's numbers. It claims numbers one by one, blocks of consecutive numbers, or, as a catch-all, every number of the organisation that no other flow claims. A call takes the most specific claim that matches it.
- Outbound call: calls the organisation's own phones place to anything that is not an extension. The Destination block then branches on what kind of number was dialled (emergency, national, international, premium and so on), read against the organisation's dialling plan.
A Go to flow block hands a call from one flow to another of the same direction, carrying its variables with it, so a menu shared by several numbers is drawn once.
Draft, publish, make live¶
A flow is edited as a draft. Publishing validates it, and a flow with errors is not published: the editor shows each problem on the block it belongs to. A published version never changes. The flow's version list keeps every one, and Make live on an earlier version is how you roll back.
A call keeps the version it started on until it ends, so publishing never changes what happens to a call already in progress.
Trying a flow without a phone¶
The editor's simulation panel runs the flow on the same engine that runs live calls, against a scripted call instead of a real one. You set:
- the caller's number and the number dialled;
- when the call arrives, so a schedule, a holiday or an override can be checked at any date and time;
- the keys the caller presses;
- each phone the flow rings: free, on a call or away, and how long it takes to answer.
Running it shows the path the call takes through the blocks and how it ends: answered by whom, a message left, refused and why, or placed out to which number. Because the simulation runs on its own clock, "what happens when this number calls on a public holiday at 18:05 and presses 1" takes a second to answer.
A PBX with no telephony configured still validates, publishes, versions and simulates flows, so a flow can be built and tested before the first phone is connected.
Variables¶
Every call starts with variables that describe it, and a flow can set its own.
| Variable | What it holds |
|---|---|
caller.number |
The caller's number in international form (with a leading +) where it can be read that way, otherwise as delivered. |
caller.delivered |
The caller's number exactly as it arrived. |
caller.national |
The caller's number in the organisation's national form, absent for a caller abroad. |
caller.name |
The caller's display name, when there is one. |
dialled.number |
The number that was dialled. |
Built-in variables start with caller. or dialled. and cannot be overwritten. Set variable stores a
value of your own for the rest of the call, and Match variable branches on one: on the caller's number,
for example, to send known customers to their account manager.
After the call¶
Every call records the path it took: each block it passed through, with timings. The call log in the console shows it, so "why did this caller end up in voicemail" is answered by looking, not by guessing.
Building flows with an assistant¶
The console's copilot drafts and explains flows in plain language. What it proposes is always a draft you can read, simulate and publish yourself, never a change to a live flow. A program can do the same through the organisation's MCP server, which reads, validates and simulates flows. The rest of the console is the public API; see the integrator API.