# Create default email address This function configures a default (catchall) email address. : When you disable the Mail Receive role, the system this function. Endpoint: GET /Email/set_default_address Version: 11.134.0.5 Security: BasicAuth ## Query parameters: - `fwdopt` (string, required) The method to use to handle unroutable mail. * — Forward messages to the parameter’s address. * — Bounce messages back to the sender, and include the parameter’s failure message. * — Send messages to the directory. This method does generate a failure notice. * — Pipe mail to the parameter’s application. This parameter requires the File Storage role. Enum: "fwd", "fail", "blackhole", "pipe" - `domain` (string) The domain whose default email behavior you want to configure. : This parameter defaults to the cPanel account’s main domain. Example: "example.com" - `failmsgs` (string) The failure message for the message’s sender. : Use this parameter if you used the method for the parameter. Example: "Failure echos loud. That address does not exist. Softly I regret. - an email failure haiku" - `fwdemail` (string) The email address to which the system forwards messages. : Use this parameter if you used the method for the parameter. Example: "admin@example.com" - `pipefwd` (string) The application to which the system pipes messages. : Use this parameter if you used the method for the parameter. : This parameter requires the File Storage role. Example: "mailscript.pl" ## Response 200 fields (application/json): - `apiversion` (integer) The version of the API. Example: 3 - `func` (string) The name of the method called. Example: "set_default_address" - `module` (string) The name of the module called. Example: "Email" - `result` (object) - `result.data` (array) An array of hashes of forwarder information. This array of hashes includes the domain and dest returns. - `result.data.dest` (string) The destination to which the system sends unroutable mail. - An email address The system forwards mail to this address. - :fail: The system bounces mail back to the sender, and sends a failure message. - :blackhole: The system deletes mail without a failure message. - The path to an application The system pipes mail to this application. Example: "admin@example.com" - `result.data.domain` (string) The domain. A valid domain on the account. Example: "example.com" - `result.errors` (array,null) List of errors if the API failed. - `result.messages` (array,null) List of messages generated by the API. - `result.metadata` (object) - `result.metadata.transformed` (integer) Post-processing may have transformed the data. Enum: 1 - `result.status` (integer) - — Success. - — Failed. Check the field for more details. Enum: 0, 1 - `result.warnings` (array,null) List of warnings generated by the API. Warnings describe non-critical failures or other problematic conditions noted while running a API.