POST
/api/public/v1/email-addresses

Create an email address

Create a new email address on a custom domain. Optionally assign it to one or more employees.

Required scope

The access token must carry this scope. A token missing it gets 403 Forbidden. Grant them to an API client under Dev Tools → API, to an assistant or CLI sign-in when you approve or edit it under Dev Tools, and to a teammate under Employee → Permissions.

email:addresses:write

Request Body

PropertyTypeDescription
domainIdstringTarget domain.
localPartstringLocal part of the address (before @).
employeeIdsarrayEmployee IDs to assign the address to.
POSTExample request
curl
curl -X POST "https://www.pxb.app/api/public/v1/email-addresses" \
  -H "Authorization: Bearer your_access_token" \
  -H "Content-Type: application/json" \
  -d '{
    "domainId": "dom_123",
    "localPart": "support",
    "employeeIds": [
      "emp_456"
    ]
  }'
200Example response
json
{
  "message": "Email address created successfully!",
  "content": {
    "emailAddress": {
      "id": "ea_1",
      "username": "support@example.com"
    }
  }
}

In the console

The same thing done by hand, for anyone comparing the API against the screen they already use.

Domains
/domains
  1. Add an address on one of your domains.