Progress will discontinue Telerik Platform on May 10th, 2018. Learn more

Deleting User Accounts

Deleting User Accounts

The delete user account operation allows you to remove a single or all user account from the Users content type.

Single user

If you want to delete single user, you must specify the Id in the URL.

$.ajax({
    type: "DELETE",
    url: 'https://api.everlive.com/v1/your-app-id/Users/item-id-here',
    headers: { "Authorization" : "Bearer your-access-token-here" },
    contentType: "application/json",
    success: function(){
        alert("User successfully deleted.");
    },
    error: function(error){
        alert(JSON.stringify(error));
    }
});
Request:
    DELETE https://api.everlive.com/v1/your-app-id/Users/item-id-here 
Headers:
    Authorization  Bearer your-access-token-here
    Content-Type: application/json 
Response:
    Status: 200 OK
    Content-Type: application/json

Multiple users

You can delete users by filter. The filter is represented as JavaScript object. In the example below every "John Smith" will be deleted.

var filter = { "DisplayName" : "John Smith" };

$.ajax({
    type: "DELETE",
    url: 'https://api.everlive.com/v1/your-app-id/Users',
    headers: {"Authorization" : "Bearer your-access-token-here",
              "X-Everlive-Filter" : JSON.stringify(filter)},
    contentType: "application/json",
    success: function (data) {
        alert("Users successfully deleted.");
    },
    error: function (error) {
        alert(JSON.stringify(error));
    }
});
Request:
    DELETE https://api.everlive.com/v1/your-app-id/Users
Headers:
    Authorization  Bearer your-access-token-here
    X-Everlive-Filter {"DisplayName":"John Smith"}
Response:
    Status: 200 OK
    Content-Type: application/json

It is simple to delete all users of your application with a single request. The url is as follows, without any Ids or filters in the back.

$.ajax({
    type: "DELETE",
    url: 'https://api.everlive.com/v1/your-app-id/Users',
    headers: {"Authorization" : "Bearer your-access-token-here"},
    contentType: "application/json",
    success: function (data) {
        alert("Users successfully deleted.");
    },
    error: function (error) {
        alert(JSON.stringify(error));
    }
});
Request:
    DELETE https://api.everlive.com/v1/your-app-id/Users
Headers:
    Authorization  Bearer your-access-token-here
Response:
    Status: 200 OK
    Content-Type: application/json
Start a free trial Request a demo
Contact us: +1-888-365-2779
sales@telerik.com
Copyright © 2016-2017, Progress Software Corporation and/or its subsidiaries or affiliates. All rights reserved.