Apply Email Routing settings
PUT/zones/{zone_id}/email/routing
Apply the provided settings to your Email Routing zone. Omitted settings retain their current values, as with PATCH.
Security
API Token
The preferred authorization scheme for interacting with the Cloudflare API. Create a token.
Example:
API Email + API Key
The previous authorization scheme for interacting with the Cloudflare API, used in conjunction with a Global API key.
Example:
The previous authorization scheme for interacting with the Cloudflare API. When possible, use API tokens instead of Global API keys.
Example:
Accepted Permissions (at least one required)
Apply Email Routing settings
curl https://api.cloudflare.com/client/v4/zones/$ZONE_ID/email/routing \
-X PUT \
-H 'Content-Type: application/json' \
-H "Authorization: Bearer $CLOUDFLARE_API_TOKEN" \
-d '{
"enabled": true,
"skip_wizard": true,
"support_subaddress": true
}'{
"errors": [
{
"code": 1000,
"message": "message",
"documentation_url": "documentation_url",
"source": {
"pointer": "pointer"
}
}
],
"messages": [
{
"code": 1000,
"message": "message",
"documentation_url": "documentation_url",
"source": {
"pointer": "pointer"
}
}
],
"success": true,
"result": {
"id": "75610dab9e69410a82cf7e400a09ecec",
"enabled": true,
"name": "example.net",
"created": "2014-01-02T02:20:00Z",
"modified": "2014-01-02T02:20:00Z",
"skip_wizard": true,
"status": "ready",
"support_subaddress": true,
"tag": "75610dab9e69410a82cf7e400a09ecec"
}
}Returns Examples
{
"errors": [
{
"code": 1000,
"message": "message",
"documentation_url": "documentation_url",
"source": {
"pointer": "pointer"
}
}
],
"messages": [
{
"code": 1000,
"message": "message",
"documentation_url": "documentation_url",
"source": {
"pointer": "pointer"
}
}
],
"success": true,
"result": {
"id": "75610dab9e69410a82cf7e400a09ecec",
"enabled": true,
"name": "example.net",
"created": "2014-01-02T02:20:00Z",
"modified": "2014-01-02T02:20:00Z",
"skip_wizard": true,
"status": "ready",
"support_subaddress": true,
"tag": "75610dab9e69410a82cf7e400a09ecec"
}
}