[go: up one dir, main page]

DELETE managers/{id} – REST API

Delete a Manager: DELETE /managers/{id}

Remove a single manager by passing the manager’s email as an id.

You can not remove the owner account via this method. Owners must delete their entire account manually through the website’s Profile settings.

Query Parameters

  • id: A unique ID for the manager – parameter accepts the manager’s email.

JSON Result Details

HTTP SUCCESS STATUS CODE: 204
A successful deletion will not return any body data.

<?php
$curl = curl_init();

curl_setopt_array($curl, array(
  CURLOPT_URL => "https://api.libib.com/managers/samgee@example.com",
  CURLOPT_RETURNTRANSFER => true,
  CURLOPT_ENCODING => "",
  CURLOPT_CONNECTTIMEOUT => 5,
  CURLOPT_TIMEOUT => 15,
  CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
  CURLOPT_CUSTOMREQUEST => "DELETE",
  CURLOPT_HTTPHEADER => array(
    "x-api-key: YOUR_API_KEY",
    "x-api-user: YOUR_API_USER"
  ),
));

$response = curl_exec($curl);
$err = curl_error($curl);

curl_close($curl);

if ($err) {
  echo "cURL Error #:" . $err;
} else {
  $obj = json_decode($response);
}
Updated on April 13, 2024
Was this article helpful?

Related Articles