Set all participants with a given booking id to deregistered
For every API request you make, you'll need to present the API access key in the HTTP Header as X-API-Key to be authenticated.
| Name | Required | Value | Description | ||||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| config | optional | object |
|
$request_url = 'https://api.frontcore.com/v2/booking/:id/deregister';
$ch = curl_init();
curl_setopt($ch, CURLOPT_URL, $request_url);
curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
curl_setopt($ch, CURLOPT_CUSTOMREQUEST, "PUT");
curl_setopt($ch, CURLOPT_HTTPHEADER, array(
'X-API-Key: {your-api-key}',
'Accept: application/json',
));
$result = curl_exec($ch);
curl_close($ch);
If the method is successful it responds with an JSON structure, as it is shown below.
{
"successful": true,
"booking_id": "473576",
"participants": [
.. a list of participants that were affected (Same object structure as "Get Participants" endpoint)
]
}
Unsuccessful response sample:
{
"successful": false,
"errors": [
{
"code" => some_error_code,
"message" => "A human readable error response"
}
]
}
| unauthorized | You are not authorized to execute this operation. |
| resource_not_found | 'We can not find any booking with given ID. |