DomainsEmailAdd

Add emailaccount or forwarder. Only possible for domains with an email package, for example with the Sitebuilder.

Input

Parameter Value Example value
domain_id ID of domain. Retrieve with command DomainsListSingle.
Parameter is required
4312
email Enter the part before the @. When you want to create info@versio.nl, you only send 'info'.
Parameter is required
info
type 'email' or 'forwarder'.
Parameter is required.
email
password Password of email account. At least 5 characters, one lowercase, one uppercase and one number.
Parameter is required when type = 'email'.
dju34
forward_to Destination email address.
Parameter is required when type = 'forwarder'.
email@domain.com


Output

Parameter Value Example value
success command executed successfully 0 = fout
1 = command executed successfully
command_response_message Error
Only sent when value parameter success = 0
incorrect password
email_id ID of the just added email account.
Only sent when value parameter success = 1
34234


Example

<? require("class_versio_api.php"); unset($command); $command = array( "command" => "DomainsEmailAdd", "domain_id" => "4312", "type" => "email", "email" => "info", "password" => "dju34" ); $api = new Versio_api(); $versio = $api->api_send( $command ); IF($versio['success']==0) { echo("Error occured. Error code: ".$versio['command_response_code'].". Error message: ".$versio['command_response_message'].""); } else IF($versio['success']==1) { echo("Email account succesfully added. ID: ".$versio['email_id']."."); } ?>