---
title: Update Email Routing settings
---

[Skip to content](#_top)

[API Reference](https://developers.cloudflare.com/api/typescript)

[Email Routing](https://developers.cloudflare.com/api/typescript/resources/email_routing)

Copy Markdown

Open in **Claude**Open in **ChatGPT**Open in **Cursor**

---

**Copy Markdown****View as Markdown**

# Update Email Routing settings

client.emailRouting.edit(EmailRoutingEditParams {zone\_id, enabled, skip\_wizard, support\_subaddress } params, RequestOptionsoptions?): [Settings](<https://developers.cloudflare.com/api/typescript/resources/email_routing#(resource)%20email_routing%20%3E%20(model)%20settings%20%3E%20(schema)>) {id, enabled, name, 6 more }

PATCH/zones/{zone\_id}/email/routing

Update the settings for your Email Routing zone.

##### Security

<details>

<summary>API Token</summary>



The preferred authorization scheme for interacting with the Cloudflare API. <a href="https://developers.cloudflare.com/fundamentals/api/get-started/create-token/">Create a token</a>.

**Example:**<code>Authorization: Bearer Sn3lZJTBX6kkg7OdcBUAxOO963GEIyGQqnFTOFYY</code>

</details>

<details>

<summary>API Email + API Key</summary>



The previous authorization scheme for interacting with the Cloudflare API, used in conjunction with a Global API key.

**Example:**<code>X-Auth-Email: user@example.com</code>

The previous authorization scheme for interacting with the Cloudflare API. When possible, use API tokens instead of Global API keys.

**Example:**<code>X-Auth-Key: 144c9defac04969c7bfad8efaa8ea194</code>

</details>

##### Accepted Permissions (at least one required)

`Zone Settings Write`

##### ParametersExpand Collapse

<details>

<summary>

params: EmailRoutingEditParams {zone\_id, enabled, skip\_wizard, support\_subaddress }

</summary>

zone\_id: string

Path param: Identifier.

maxLength32

<a href="#(resource)%20email_routing%20%3E%20(method)%20edit%20%3E%20(params)%20default%20%3E%20(param)%20zone_id">Link to this property</a>

<details>

<summary>

enabled?: true| false

Body param: State of your zone Email Routing settings. No-op on this endpoint - use <code>POST</code>/<code>DELETE /zones/{zone_id}/email/routing/dns</code>.

</summary>

One of the following:

true

<a href="#(resource)%20email_routing%20%3E%20(method)%20edit%20%3E%20(params)%20default%20%3E%20(param)%20enabled%20%3E%20(schema)%20%3E%20(member)%200">Link to this property</a>

false

<a href="#(resource)%20email_routing%20%3E%20(method)%20edit%20%3E%20(params)%20default%20%3E%20(param)%20enabled%20%3E%20(schema)%20%3E%20(member)%201">Link to this property</a>

</details>

<a href="#(resource)%20email_routing%20%3E%20(method)%20edit%20%3E%20(params)%20default%20%3E%20(param)%20enabled">Link to this property</a>

<details>

<summary>

skip\_wizard?: true| false

Body param: Flag to check if the user skipped the configuration wizard.

</summary>

One of the following:

true

<a href="#(resource)%20email_routing%20%3E%20(method)%20edit%20%3E%20(params)%20default%20%3E%20(param)%20skip_wizard%20%3E%20(schema)%20%3E%20(member)%200">Link to this property</a>

false

<a href="#(resource)%20email_routing%20%3E%20(method)%20edit%20%3E%20(params)%20default%20%3E%20(param)%20skip_wizard%20%3E%20(schema)%20%3E%20(member)%201">Link to this property</a>

</details>

<a href="#(resource)%20email_routing%20%3E%20(method)%20edit%20%3E%20(params)%20default%20%3E%20(param)%20skip_wizard">Link to this property</a>

<details>

<summary>

support\_subaddress?: true| false

Body param: Whether subaddressing (plus-addressing) is honored when matching incoming mail against routing rules.

</summary>

One of the following:

true

<a href="#(resource)%20email_routing%20%3E%20(method)%20edit%20%3E%20(params)%20default%20%3E%20(param)%20support_subaddress%20%3E%20(schema)%20%3E%20(member)%200">Link to this property</a>

false

<a href="#(resource)%20email_routing%20%3E%20(method)%20edit%20%3E%20(params)%20default%20%3E%20(param)%20support_subaddress%20%3E%20(schema)%20%3E%20(member)%201">Link to this property</a>

</details>

<a href="#(resource)%20email_routing%20%3E%20(method)%20edit%20%3E%20(params)%20default%20%3E%20(param)%20support_subaddress">Link to this property</a>

</details>

[Link to this property](<#(resource)%20email_routing%20%3E%20(method)%20edit%20%3E%20(params)%20default>)

##### ReturnsExpand Collapse

<details>

<summary>

Settings {id, enabled, name, 6 more }

</summary>

id: string

Email Routing settings identifier.

maxLength32

<a href="#(resource)%20email_routing%20%3E%20(model)%20settings%20%3E%20(schema)%20%3E%20(property)%20id">Link to this property</a>

<details>

<summary>

enabled: true| false

State of the zone settings for Email Routing.

</summary>

One of the following:

true

<a href="#(resource)%20email_routing%20%3E%20(model)%20settings%20%3E%20(schema)%20%3E%20(property)%20enabled%20%3E%20(member)%200">Link to this property</a>

false

<a href="#(resource)%20email_routing%20%3E%20(model)%20settings%20%3E%20(schema)%20%3E%20(property)%20enabled%20%3E%20(member)%201">Link to this property</a>

</details>

<a href="#(resource)%20email_routing%20%3E%20(model)%20settings%20%3E%20(schema)%20%3E%20(property)%20enabled">Link to this property</a>

name: string

Domain of your zone.

<a href="#(resource)%20email_routing%20%3E%20(model)%20settings%20%3E%20(schema)%20%3E%20(property)%20name">Link to this property</a>

created?: string

The date and time the settings have been created.

formatdate-time

<a href="#(resource)%20email_routing%20%3E%20(model)%20settings%20%3E%20(schema)%20%3E%20(property)%20created">Link to this property</a>

modified?: string

The date and time the settings have been modified.

formatdate-time

<a href="#(resource)%20email_routing%20%3E%20(model)%20settings%20%3E%20(schema)%20%3E%20(property)%20modified">Link to this property</a>

<details>

<summary>

skip\_wizard?: true| false

Flag to check if the user skipped the configuration wizard.

</summary>

One of the following:

true

<a href="#(resource)%20email_routing%20%3E%20(model)%20settings%20%3E%20(schema)%20%3E%20(property)%20skip_wizard%20%3E%20(member)%200">Link to this property</a>

false

<a href="#(resource)%20email_routing%20%3E%20(model)%20settings%20%3E%20(schema)%20%3E%20(property)%20skip_wizard%20%3E%20(member)%201">Link to this property</a>

</details>

<a href="#(resource)%20email_routing%20%3E%20(model)%20settings%20%3E%20(schema)%20%3E%20(property)%20skip_wizard">Link to this property</a>

<details>

<summary>

status?: "ready"| "unconfigured"| "misconfigured"| 2 more

Show the state of your account, and the type or configuration error.

</summary>

One of the following:

"ready"

<a href="#(resource)%20email_routing%20%3E%20(model)%20settings%20%3E%20(schema)%20%3E%20(property)%20status%20%3E%20(member)%200">Link to this property</a>

"unconfigured"

<a href="#(resource)%20email_routing%20%3E%20(model)%20settings%20%3E%20(schema)%20%3E%20(property)%20status%20%3E%20(member)%201">Link to this property</a>

"misconfigured"

<a href="#(resource)%20email_routing%20%3E%20(model)%20settings%20%3E%20(schema)%20%3E%20(property)%20status%20%3E%20(member)%202">Link to this property</a>

"misconfigured/locked"

<a href="#(resource)%20email_routing%20%3E%20(model)%20settings%20%3E%20(schema)%20%3E%20(property)%20status%20%3E%20(member)%203">Link to this property</a>

"unlocked"

<a href="#(resource)%20email_routing%20%3E%20(model)%20settings%20%3E%20(schema)%20%3E%20(property)%20status%20%3E%20(member)%204">Link to this property</a>

</details>

<a href="#(resource)%20email_routing%20%3E%20(model)%20settings%20%3E%20(schema)%20%3E%20(property)%20status">Link to this property</a>

<details>

<summary>

support\_subaddress?: true| false

Whether subaddressing (plus-addressing) is honored when matching incoming mail against routing rules.

</summary>

One of the following:

true

<a href="#(resource)%20email_routing%20%3E%20(model)%20settings%20%3E%20(schema)%20%3E%20(property)%20support_subaddress%20%3E%20(member)%200">Link to this property</a>

false

<a href="#(resource)%20email_routing%20%3E%20(model)%20settings%20%3E%20(schema)%20%3E%20(property)%20support_subaddress%20%3E%20(member)%201">Link to this property</a>

</details>

<a href="#(resource)%20email_routing%20%3E%20(model)%20settings%20%3E%20(schema)%20%3E%20(property)%20support_subaddress">Link to this property</a>

Deprecatedtag?: string

Email Routing settings tag. (Deprecated, replaced by Email Routing settings identifier)

maxLength32

<a href="#(resource)%20email_routing%20%3E%20(model)%20settings%20%3E%20(schema)%20%3E%20(property)%20tag">Link to this property</a>

</details>

[Link to this property](<#(resource)%20email_routing%20%3E%20(model)%20settings%20%3E%20(schema)>)

### Update Email Routing settings

TypeScript

HTTPTypeScriptPythonGoTerraform

```
import Cloudflare from 'cloudflare';

const client = new Cloudflare({
  apiToken: process.env['CLOUDFLARE_API_TOKEN'], // This is the default and can be omitted
});

const settings = await client.emailRouting.edit({ zone_id: '023e105f4ecef8ad9ca31a8372d0c353' });

console.log(settings.id);
```

200 example

```
{
  "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

200 example

```
{
  "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"
  }
}
```