bridge@v3

Bridge the outbound leg of a dial@v2 (or dial@v1); a beep (feedback) is played to both legs before bridging unless disabled.

Versionbridge@v3
Runs ininbound-call and your own branches

Parameters

NameTypeRequiredDefaultDescription
feedbackobjectSound played to both legs before bridging: a built-in sound (beep by default) or an audio file of your library (at most one of sound / audioFile).
feedback.enabledbooleantrueaccepts ${{ }}
feedback.soundbeep, loading, heartbeat"beep"accepts ${{ }}
feedback.audioFileobjectAn audio file of your library, by its SID (REST API v2 identifier). audio file of your library: sid
feedback.delaynumber0Seconds to wait before playing: 0..60
accepts ${{ }}

Every parameter that accepts ${{ }} can be computed from an expression.

Examples

If you handle the outbound leg of a dial@v2 in another branch, you can use this action to bridge the call. Before bridging, a short sound is played to both legs (feedback). By default it is a beep, as bridge@v2 did.

branches:
  inbound-call:
    actions:
      - action: dial@v2
        params:
          targets:
            - number: "+33199004242"
              timeout: 20
          answerOnBranch: callee-branch

  callee-branch:
    actions:
      - action: gather@v4
        params:
          maxDigits: 1
          tts:
            text: Hello! Press 1 to accept the call
        result: $digits

      - if: $digits.input == '1'
        action: bridge@v3

      - action: hangup@v1

Full example with defaults

- action: bridge@v3
  params:
    feedback:
      enabled: true # false to bridge silently
      delay: 0 # (0..60) accepted, no effect on bridge
      sound: beep # beep|loading|heartbeat
      # or an audio file of your library instead of sound:
      # audioFile:
      #   sid: 'fdsanjkf'

Older versions

Older versions keep working in existing scenarios. Use the version above in new scenarios.

  • bridge@v2: Bridge the outbound leg of a dial@v1
  • bridge@v1: Bridge the outbound leg of a dial@v1

Did this page help you?