Delete a mailbox

v1
mail
delete
/1/mail_hostings/{mail_hosting_id}/mailboxes/{mailbox_name}

Deletes a given mailbox.

Path parameters

mail_hosting_id
requiredinteger

The unique identifier (ID) of the mail hosting to request.

Examples:8954
mailbox_name
requiredstring

The username (that is the part before the @) of the email address you want to request.

Examples:example

Response Body

application/json
resultrequiredstring
Possible values:successerrorasynchronous

Result of the HTTP request

Examples:success
databoolean

Example request

                <?php
use GuzzleHttp\Client;

$client = new Client();
$headers = [
	'Authorization' => 'Bearer YOUR-TOKEN-HERE',
	'Content-Type' => 'application/json'
];

$request = new Request('DELETE', 'https://api.infomaniak.com/1/mail_hostings/{mail_hosting_id}/mailboxes/{mailbox_name}', $headers, $body);
$res = $client->sendAsync($request)->wait();
echo $res->getBody();
            

Example response

application/json
                
                    
{
"result":"success",
"data":true
}