Sample - Box Platform API
DELETE/users/{user_id}/email_aliases/{email_alias_id}

Remove an email alias

Deletes an email alias from a user account. Supply both user_id and email_alias_id to identify the account and alias to remove. The operation returns an empty response when the alias is removed.

  • RetriesRetries up to 2×, 500ms backoff, 30s timeout.

2 parameters
user_idstringrequired
The unique identifier of the user account containing the email alias.
email_alias_idstringrequired
The unique identifier of the email alias to remove.

2 status codes
204Returns an empty response after removing the email alias.
defaultReturned when an unexpected client error occurs.
typestringoptional
The value will always be `error`.
Allowed:error
statusintegeroptional
The HTTP status of the response.
codestringoptional
A Box-specific error code.
Allowed:createdacceptedno_contentredirectnot_modifiedbad_requestunauthorizedforbiddennot_foundmethod_not_allowedconflictprecondition_failed
messagestringoptional
A short message describing the error.
context_infoobjectoptional
A free-form object that contains additional context about the error. The possible fields are defined on a per-endpoint basis. `message` is only one example.
help_urlstringoptional
A URL that links to more information about why this error occurred.
request_idstringoptional
A unique identifier for this response, which can be used when contacting Box support.

Error handling

user_id must identify the user account associated with the alias, and email_alias_id must identify the email alias to remove. Supply both path identifiers exactly as issued by the API.