Stop speaking text during a call

    This endpoint allows for stopping active text that are being spoken in the call.

    API Endpoint

    DELETE https://api.plivo.com/v1/Account/{auth_id}/Call/{call_uuid}/Speak/

    Arguments

    No arguments need to be passed.

    Response

    HTTP Status Code: 204

    {
        "message" : "speak stopped",
        "api_id" : "cf2359c8-f4d6-11e6-b886-067c5485c240"
    }
    

    Example Request

    1
    2
    3
    4
    5
    6
    
    import plivo
    
    client = plivo.RestClient()
    response = client.calls.speak_stop(
        call_uuid='3a2e4c90-dcee-4931-8a59-f123ab507e60', )
    print(response)
    
    1
    2
    3
    4
    5
    6
    7
    8
    9
    10
    11
    12
    13
    14
    15
    16
    17
    18
    19
    
    #
    # Example for Call Speak Delete
    #
    require 'rubygems'
    require 'plivo'
    
    include Plivo
    include Plivo::Exceptions
    
    api = RestClient.new("YOUR_AUTH_ID", "YOUR_AUTH_TOKEN")
    
    begin
      response = api.calls.stop_speak(
        'eba53b9e-8fbd-45c1-9444-696d2172fbc8'
      )
      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
    
    // Example for Call Speak 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.calls.stopSpeakingText(
            "eba53b9e-8fbd-45c1-9444-696d2172fbc8", // call uuid
        ).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 Call Speak delete
     */
    require 'vendor/autoload.php';
    use Plivo\RestClient;
    use Plivo\Exceptions\PlivoRestException;
    $client = new RestClient("YOUR_AUTH_ID", "YOUR_AUTH_TOKEN");
    
    try {
        $response = $client->calls->stopSpeaking(
            'eba53b9e-8fbd-45c1-9444-696d2172fbc8'
        );
        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
    
    package com.plivo.api.samples.call.speak;
    
    import java.io.IOException;
    import com.plivo.api.Plivo;
    import com.plivo.api.exceptions.PlivoRestException;
    import com.plivo.api.models.call.Call;
    
    /**
    * Example for Call Speak delete
    */
    class SpeakDelete {
        public static void main(String [] args) {
            Plivo.init();
            try {
                Call.speakStopper("eba53b9e-8fbd-45c1-9444-696d2172fbc8")
                    .speakStop();
    
                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
    
    /**
     * Example for Call Speak 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.Call.StopSpeaking(
                        callUuid:"10c94053-73b4-46fe-b74a-12159d1d3d60"
                    );
                    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}/Call/{call_uuid}/Speak/
    
    1
    2
    3
    4
    5
    6
    7
    8
    9
    10
    11
    12
    13
    14
    15
    16
    17
    18
    19
    
    // Example for Call Speak 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.Calls.StopSpeaking(
    		"eba53b9e-8fbd-45c1-9444-696d2172fbc8",
    	)
    	if err != nil {
    		panic(err)
    	}
    	fmt.Println("Deleted successfully.")
    }