Update a mailbox

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

Updates a given mailbox.

Path parameters

mail_hosting_id
requiredinteger

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

Examples:69947
mailbox_name
requiredstring

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

Examples:example

Body Parameters

application/json
passwordstring

Mailbox password

Examples:9;cDm^my{@^?dk1l*3J$
full_namestring

Specify full name

Examples:Sierra Farrell
notestring

Add a note

Examples:example
has_move_spamboolean

Specify if spam are moved to spam folder

authorized_senders

Specify white list

blocked_senders

Specify black list

has_responderboolean

Specify if mailbox responder is enabled

has_mail_filteringboolean

Specify if mail filtering is enabled

mail_filtering_folder_commercialsstring

Specify commercial folder

Examples:example
mail_filtering_folder_social_networksstring

Specify social networks folder

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'
];

$body = '{
    "password": "9;cDm^my{@^?dk1l*3J$",
    "full_name": "Sierra Farrell",
    "note": "example",
    "has_move_spam": true,
    "has_responder": false,
    "has_mail_filtering": false,
    "mail_filtering_folder_commercials": "example",
    "mail_filtering_folder_social_networks": "example"
}';

$request = new Request('PATCH', '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":false
}