Delete a profile

    This API lets you delete a particular profile from your account. This action is irreversible. Please note that you cannot delete the primary profile of you account.

    API Endpoint

    DELETEhttps://api.plivo.com/v1/Account/{auth_id}/Profile/{profile_uuid}

    Arguments

    No arguments need to be passed.

    Response

    HTTP Status Code: 200

    {‚Äč
    "api_id": "aaf7717a-c149-11ec-a932-0242ac110003",
    "message": "Profile deleted successfully."
    }
    
    1
    2
    3
    4
    5
    6
    7
    8
    9
    10
    11
    12
    13
    14
    15
    
    // Available in versions >= 4.30.0 (https://github.com/plivo/plivo-node/releases/tag/v4.30.0)
    
    let plivo = require('plivo');
    
    var client = new plivo.Client("<auth_id>", "<auth_token>");
    client.profile.list({
        limit: 5,
        offset: 0,
    })
        .then(function (response) {
            console.log(response);
        })
        .catch(function (error) {
            console.log(error);
        });
    
    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
    
    <?php
    
    # Available in versions >= 4.29.0 (https://github.com/plivo/plivo-php/releases/tag/v4.29.0)
    
    require '/etc/plivo-php/vendor/autoload.php';
    use Plivo\RestClient;
    
    $client = new RestClient("<auth_id>", "<auth_token>");
    
    // delete Powerpack
    $client
        ->client
        ->setTimeout(60);
    try
    {
        // $res =  $client->profile->list();
        $res = $client
            ->profile
            ->delete("<profile_uuid>");
        print_r($res);
    }
    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
    25
    26
    27
    28
    29
    30
    31
    32
    
    // Available in versions >= 5.9.0 (https://github.com/plivo/plivo-dotnet/releases/tag/v5.9.0)
    
    using System;
    using System.Collections.Generic;
    using Plivo;
    using Plivo.Exception;
    using Plivo.Resource.Profile;
    
    namespace dotnet_project
    {
        class Ten_dlc
        {
            static void Main(string[] args)
            {
    
                var api = new PlivoApi("<auth_id>", "<auth_token>");
    
                // Delete a  Profile
                try
                {
                    var response = api.Profile.Delete("f8ca5a50-50b8-438d-8068-28427b1c0e90");
                    Console.WriteLine(response);
                }
                catch (PlivoRestException e)
                {
                    Console.WriteLine("Exception: " + e.Message);
                }
    
    
            }
        }
    }
    
    1
    2
    
    curl -X DELETE -i --user auth_id:auth_token \
        https://api.plivo.com/v1/Account/{auth_id}/Profile/{profile_uuid}/