Hangup a Member
This method lets you hangup a particular member present in a conference. The member to be disconnected needs to be identified using the member_id
API Endpoint
DELETE
https://api.plivo.com/v1/Account/{auth_id}/Conference/{conference_name}/Member/{member_id}/
The member_id
attribute which is passed in the URL can be one of the following two forms:
Member ID: The member specified by the
member_id
.‘all’: The string ‘all’, this action will be performed on all members of the conference.
Arguments
No arguments need to be passed.
Response
HTTP Status Code: 204
Example Request
1
2
3
4
5
6
7
import plivo
client = plivo.RestClient()
response = client.conferences.hangup_member(
conference_name='testing',
member_id=27697, )
print(response)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
#
# Example for Conference Member Delete
#
require 'rubygems'
require 'plivo'
include Plivo
include Plivo::Exceptions
api = RestClient.new("YOUR_AUTH_ID", "YOUR_AUTH_TOKEN")
begin
response = api.conferences.delete_member(
'My Conf Room',
10
)
puts response
rescue PlivoRESTError => e
puts 'Exception: ' + e.message
end
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
// Example for Conference delete
var plivo = require('plivo');
(function main() {
'use strict';
// As the auth_id and auth_token are unspecified, Plivo will fetch them from the PLIVO_AUTH_ID and PLIVO_AUTH_TOKEN environment variables.
var client = new plivo.Client();
client.conferences.hangupMember(
"My Conf Room", // conference name
"1", // member id
).then(function (response) {
console.log(response);
}, function (err) {
console.error(err);
});
})();
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
<?php
/**
* Example for Conference member delete
*/
require 'vendor/autoload.php';
use Plivo\RestClient;
use Plivo\Exceptions\PlivoRestException;
$client = new RestClient("YOUR_AUTH_ID", "YOUR_AUTH_TOKEN");
try {
$response = $client->conferences->hangUpMember(
'My conference',
123
);
print_r($response);
}
catch (PlivoRestException $ex) {
print_r($ex);
}
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
package com.plivo.api.samples.conference.member;
import com.plivo.api.Plivo;
import com.plivo.api.exceptions.PlivoRestException;
import com.plivo.api.models.conference.Conference;
import java.io.IOException;
/**
* Example for Conference Member delete
*/
class MemberDelete {
public static void main(String [] args) {
Plivo.init();
try {
Conference.memberHangupper("My Conf Room", "1")
.hangup();
System.out.println("Deleted successfully.");
} catch (PlivoRestException | IOException e) {
e.printStackTrace();
}
}
}
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
/**
* Example for Conference Member Delete
*/
using System;
using System.Collections.Generic;
using Plivo;
using Plivo.Exception;
namespace PlivoExamples
{
internal class Program
{
public static void Main(string[] args)
{
var api = new PlivoApi("YOUR_AUTH_ID", "YOUR_AUTH_TOKEN");
try
{
var response = api.Conference.HangupMember(
memberId:"28720",
conferenceName:"testing"
);
Console.WriteLine(response);
}
catch (PlivoRestException e)
{
Console.WriteLine("Exception: " + e.Message);
}
}
}
}
1
2
curl -X DELETE --user AUTH_ID:AUTH_TOKEN \
https://api.plivo.com/v1/Account/{auth_id}/Conference/{conference_name}/Member/{member_id}/
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
// Example for Conference Member delete
package main
import "fmt"
import "github.com/plivo/plivo-go"
func main() {
client, err := plivo.NewClient("", "", &plivo.ClientOptions{})
if err != nil {
panic(err)
}
_, err = client.Conferences.MemberHangup(
"My Conf Room",
"1",
)
if err != nil {
panic(err)
}
fmt.Println("Deleted successfully.")
}
Rate this page
🥳 Thank you! It means a lot to us!
×
Help Us Improve
Thank you so much for rating the page, we would like to get your input for further improvements!
Subscribe to Updates
Thank you for your feedback!