<Hangup>

The <Hangup> verb ends a call. While <Reject>ed calls are never answered, calls that use the <Hangup> verb for disconnection are still answered, becoming subject to billing.

Verb Attributes

The <Hangup> verb does not support any attributes.

Nesting

No other verbs can be nested within <Hangup> and you cannot nest <Hangup> within any other verbs.

Examples

A Simple Hangup

<?xml version="1.0" encoding="UTF-8"?>
<Response>
    <Hangup/>
</Response>
const { RestClient } = require('@signalwire/node')
const response = new RestClient.LaML.VoiceResponse()

response.hangup()
console.log(response.toString())
<?php
  use SignalWire\LaML;
  $response = new LaML;

  $response->hangup();
  echo $response;
?>
using Twilio.TwiML;
using System;


class Example
{
    static void Main()
    {
        var response = new VoiceResponse();
        response.Hangup();

        Console.WriteLine(response.ToString());;
    }
}
from signalwire.voice_response import VoiceResponse, Hangup

response = VoiceResponse()
response.hangup()

print(response)
require 'signalwire/sdk'

response = Signalwire::Sdk::VoiceResponse.new do |response|
  response.hangup
end

puts response.to_s

SignalWire will answer the call then immediately hangup.