Chilkat Online Tools

C# / Plivo REST API / Kick or disconnect a member from a conference

Back to Collection Items

// This example assumes the Chilkat API to have been previously unlocked.
// See Global Unlock Sample for sample code.

Chilkat.Http http = new Chilkat.Http();
bool success;

http.BasicAuth = true;
http.Login = "{{auth_id}}";
http.Password = "password";

Chilkat.HttpResponse resp = http.QuickRequest("DELETE","https://api.plivo.com/v1/Account/<auth_id>/Conference/{conference_name}/Member/{member_id}/Kick/");
if (http.LastMethodSuccess == false) {
    Debug.WriteLine(http.LastErrorText);
    return;
}

Debug.WriteLine(Convert.ToString(resp.StatusCode));
Debug.WriteLine(resp.BodyStr);

Curl Command

curl -X DELETE
	-u '{{auth_id}}:password'
https://api.plivo.com/v1/Account/<auth_id>/Conference/{conference_name}/Member/{member_id}/Kick/

Postman Collection Item JSON

{
  "name": "Kick or disconnect a member from a conference",
  "request": {
    "method": "DELETE",
    "header": [
    ],
    "url": {
      "raw": "https://api.plivo.com/v1/Account/{{auth_id}}/Conference/{conference_name}/Member/{member_id}/Kick/",
      "protocol": "https",
      "host": [
        "api",
        "plivo",
        "com"
      ],
      "path": [
        "v1",
        "Account",
        "{{auth_id}}",
        "Conference",
        "{conference_name}",
        "Member",
        "{member_id}",
        "Kick",
        ""
      ]
    },
    "description": "This method lets you disconnect a member in a conference. When the member is disconnected the next action would be performed based on the next element in the XML.\n\nMore Information can be found [here](https://www.plivo.com/docs/voice/api/conference/member#kick-a-member-from-conference)"
  },
  "response": [
    {
      "name": "Kick or disconnect a member from a conference",
      "originalRequest": {
        "method": "DELETE",
        "header": [
        ],
        "url": {
          "raw": "https://api.plivo.com/v1/Account/{{auth_id}}/Conference/{conference_name}/Member/{member_id}/Kick/",
          "protocol": "https",
          "host": [
            "api",
            "plivo",
            "com"
          ],
          "path": [
            "v1",
            "Account",
            "{{auth_id}}",
            "Conference",
            "{conference_name}",
            "Member",
            "{member_id}",
            "Kick",
            ""
          ]
        }
      },
      "code": 202,
      "_postman_previewlanguage": "json",
      "header": [
      ],
      "cookie": [
      ],
      "body": "{\n  \"message\": \"kicked\",\n  \"member_id\": \"10\",\n  \"api_id\": \"2867b6e2-58c3-11e1-86da-adf28403fe48\"\n}"
    }
  ]
}