How can I create an email using the API?
Emails can be created using the add_pop UAPI call. In the following example, the UAPI call is used to create the firstname.lastname@example.org email address on the cpusername cPanel account with P@$$w0rd set as the email account's password.
uapi --user=cpusername Email add_pop email=emailuser password=P@$$w0rd quota=0 domain=example.com skip_update_db=1
Please note that P@$$w0rd is a very insecure password and should never be used. When creating an email account, a secure password should be used.
Documentation for the add_pop API call be found here: