@sammachin/node-red-dragonpbx
v1.2.2
Published
Node-RED nodes for building DragonPBX call scripts (announce, connect, response, pause, record, pickup)
Maintainers
Readme
@sammachin/node-red-dragonpbx
Node-RED nodes for building DragonPBX call
scripts. Each node appends a verb object to msg.callScript; wire the nodes in sequence
and return the resulting array from your CallHook to control the call.
Installation
Run the following command in your Node-RED user directory (typically ~/.node-red):
npm install @sammachin/node-red-dragonpbxVerbs
All verb nodes appear under the dragonpbx palette category and use typed inputs, so
every field can be a literal or a msg/flow/global/jsonata/env reference. Unset
fields are omitted from the emitted verb.
| Node | Verb | Options |
|---|---|---|
| announce | announce | url, answer, statusLabel |
| connect | connect | reconnect, callerId, callerName, ringtone, dest[] (type, address, timeout, headers; trunk_id/trunk_name for trunks; username/password/codecs/proxy for sip), statusLabel |
| response | response | code, reason, headers, statusLabel |
| pause | pause | duration, statusLabel |
| record | record | siprecServer, legs, codec, requireSiprec, from, proxy, auth, headers, metadata, statusLabel |
| pickup | pickup | target, state, statusLabel |
statusLabel
Every verb accepts an optional statusLabel. It defaults to the boolean false, which
suppresses status events for that verb. Set it to a string instead to re-enable events
and have that label echoed back on them.
Other nodes
- auth — computes the SIP digest challenge/response for RegHook authentication (reads
msg.payload, setsmsg.payloadto the auth result). Not a call-script verb. - callScript (basenode) — appends an arbitrary JSON object (with mustache templating)
to
msg.callScript, for verbs or fields not yet covered by a dedicated node.
Example
- Inject or receive the incoming CallHook request.
- Chain the verb nodes you want, e.g.
record→connect. - Return
msg.callScriptin your HTTP response to DragonPBX.
See the DragonPBX docs/verbs.md for the full verb/option reference.
License
MIT
