Hangup

The Hangup command terminates a Call. If Hangup is used as the first action in a PerCL response, it does not prevent FreeClimb from answering the Call and billing your account. See the Reject command to hang up an inbound ringing call at no charge.

Nesting Rules

You cannot nest any actions within Hangup and you cannot nest Hangup within any other actions.

Example

A caller who has spent a long time in a Queue is dequeued, advised to call back later, and then hung up on. Notice that the Hangup command in this specific example technically is redundant, because it is the last command in the PerCL script (that isn't a Terminal command). But we show it here for illustrating the syntax. Remember that a Terminal command will have an actionUrl that picks up the call after the PerCL command has executed. In this case, there is no actionUrl with Hangup or Say, and when a script with no Terminal command ends, the call is hung up.

[
  {
    "Say" : {
      "text" : "The wait time is high. Please call back later."
    }
  },
  {
    "Hangup" : {
      "reason" : "busy"
    }
  }

]

Command Attributes

The Hangup command supports the following attributes that modify its behavior:

AttributeDescription
reasonThe user defined reason for the hangup.

reason

OPTIONAL

Type: string
Default: null

The user defined reason for the hangup. In general, applications should use a set of enumerated values that are predefined to cover all exit points of the Call flows for the given application.