---
title: "Edit template recipients"
url: "https://docs.signnow.com/docs/template/operations/edit-template-routing-details"
type: "endpoint"
section: "template"
slug: "template/operations/edit-template-routing-details"
method: "PUT"
path: "/document/{template_id}/template/routing/detail"
operation_id: "edit-template-routing-details"
authorization: "bearer"
---

# Edit template recipients

`PUT /document/{template_id}/template/routing/detail`

This endpoint allows API users to update the routing details for a specific template, including assigning roles, setting signing orders, adding CC recipients, and configuring recipient settings.

## Authorization

bearer

## Path Parameters

| Name | Type | Required | Description |
|------|------|----------|-------------|
| `template_id` | string | Yes | Template ID. |

## Request Body

**Schema**

```json
{
  "type": "object",
  "properties": {
    "cc": {
      "type": "array",
      "items": {
        "type": "string",
        "description": "Valid email address."
      },
      "description": "A list of email addresses that will receive a carbon copy of the document."
    },
    "cc_step": {
      "type": "array",
      "items": {
        "type": "object",
        "properties": {
          "name": {
            "type": "string",
            "example": "Recipient 1",
            "description": "The display name for the CC recipient."
          },
          "step": {
            "type": "integer",
            "example": 1,
            "description": "The specific step in the signing order when the email should be sent."
          },
          "email": {
            "type": "string",
            "example": "cc@email.com",
            "description": "The email address of the CC recipient."
          }
        }
      },
      "description": "A list of CC recipients assigned to specific steps in the signing order."
    },
    "viewers": {
      "type": "array",
      "items": {
        "type": "object",
        "properties": {
          "name": {
            "type": "string",
            "example": "Viewer",
            "maxLength": 255,
            "description": "The display name of the recipient role."
          },
          "contact_id": {
            "type": "string",
            "example": "55519de93089e889ab9f5283db9b7c39ad667e43",
            "description": "The unique identifier of the contact (from Contacts) linked to the document."
          },
          "inviter_role": {
            "type": "boolean",
            "description": "If set to `true`, designates the document owner (current API user) as the recipient for this role. This corresponds to the 'I am recipient' setting in the UI."
          },
          "default_email": {
            "type": "string",
            "example": "viewer@email.com",
            "maxLength": 250,
            "description": "The email address of the viewer. Note: If `inviter_role` is `true`, this defaults to the document owner's email (retrieved from `GET /user`) and the email input will be locked in the UI."
          },
          "signing_order": {
            "type": "integer",
            "example": 1,
            "maximum": 127,
            "minimum": 1,
            "description": "The step order for the viewer."
          }
        }
      },
      "description": "A list of users with view-only permissions."
    },
    "approvers": {
      "type": "array",
      "items": {
        "type": "object",
        "properties": {
          "name": {
            "type": "string",
            "example": "Approver",
            "maxLength": 255,
            "description": "The display name of the recipient role."
          },
          "inviter_role": {
            "type": "boolean",
            "description": "If set to `true`, designates the document owner (current API user) as the recipient for this role. This corresponds to the 'I am recipient' setting in the UI."
          },
          "default_email": {
            "type": "string",
            "example": "approver@email.com",
            "maxLength": 250,
            "description": "The email address of the recipient. Note: If `inviter_role` is `true`, this defaults to the document owner's email (retrieved from `GET /user`) and the email input will be locked in the UI."
          },
          "signing_order": {
            "type": "integer",
            "example": 1,
            "maximum": 127,
            "minimum": 1,
            "description": "The step order for the approver."
          },
          "expiration_days": {
            "type": "integer",
            "example": 30,
            "maximum": 180,
            "minimum": 3,
            "description": "Number of days before the approval request expires."
          }
        }
      },
      "description": "A list of users required to approve the document."
    },
    "attributes": {
      "type": "object",
      "properties": {
        "brand_id": {
          "type": "string",
          "example": "d7fcf72b4bbc47b0cc629ffe8b24421c66fec6a0",
          "description": "The unique identifier of the brand to apply."
        },
        "on_complete": {
          "enum": [
            "none",
            "document_only",
            "document_and_attachments",
            "document_attachment_only_for_signer"
          ],
          "type": "string",
          "example": "none",
          "description": "The action to take when the document is completed."
        },
        "redirect_uri": {
          "type": "string",
          "example": "https://signnow.com/",
          "maxLength": 2048,
          "description": "The URL to redirect users to after signing (max 2048 chars)."
        }
      },
      "description": "General attributes regarding the document's completion settings and branding."
    },
    "template_data": {
      "type": "array",
      "items": {
        "type": "object",
        "properties": {
          "name": {
            "type": "string",
            "example": "Manager",
            "maxLength": 250,
            "description": "The display name of the recipient role."
          },
          "role_id": {
            "type": "string",
            "example": "14819de93089e889ab9f5283db9b7c39ad667e43",
            "description": "The unique identifier of the role being updated."
          },
          "inviter_role": {
            "type": "boolean",
            "description": "If set to `true`, designates the document owner (current API user) as the recipient for this role. This corresponds to the 'I am recipient' setting in the UI."
          },
          "default_email": {
            "type": "string",
            "example": "signer@email.com",
            "maxLength": 250,
            "description": "The email address of the recipient. Note: If `inviter_role` is `true`, this defaults to the document owner's email (retrieved from `GET /user`) and the email input will be locked in the UI."
          },
          "signing_order": {
            "type": "integer",
            "example": 1,
            "maximum": 127,
            "minimum": 1,
            "description": "The order in the signing workflow."
          }
        }
      },
      "description": "A list of signers and their role configurations."
    },
    "invite_link_instructions": {
      "type": "string",
      "description": "Custom instructions to be displayed when the invite link is accessed."
    }
  },
  "x-examples": {
    "Example 1": {
      "cc": [
        "observer1@example.com",
        "observer2@example.com"
      ],
      "cc_step": [
        {
          "name": "CC 1",
          "step": 1,
          "email": "step1@example.com"
        },
        {
          "name": "CC 2",
          "step": 2,
          "email": "step2@example.com"
        }
      ],
      "viewers": [
        {
          "name": "Viewer 1",
          "contact_id": "38528aa9c323463c9563b3608c18467d9d569e09",
          "inviter_role": false,
          "default_email": "viewer@example.com",
          "signing_order": 1
        }
      ],
      "approvers": [
        {
          "name": "Approver 1",
          "inviter_role": false,
          "default_email": "approver@example.com",
          "signing_order": 3,
          "expiration_days": 15
        }
      ],
      "attributes": {
        "brand_id": "d7fcf72b4bbc47b0cc629ffe8b24421c66fec6a0",
        "on_complete": "none",
        "redirect_uri": "https://signnow.com"
      },
      "template_data": [
        {
          "name": "Signer 1",
          "role_id": "d7fcf72b4bbc47b0cc629ffe8b24421c66fec6a0",
          "inviter_role": false,
          "default_email": "",
          "signing_order": 1
        },
        {
          "name": "Signer 2",
          "role_id": "14819de93089e889ab9f5283db9b7c39ad667e43",
          "inviter_role": false,
          "default_email": "signer2@example.com",
          "signing_order": 2
        }
      ],
      "invite_link_instructions": "Please sign strictly before the deadline."
    }
  }
}
```

**Example** (`Example 1`)

```json
{
  "cc": [
    "observer1@example.com",
    "observer2@example.com"
  ],
  "cc_step": [
    {
      "name": "CC 1",
      "step": 1,
      "email": "step1@example.com"
    },
    {
      "name": "CC 2",
      "step": 2,
      "email": "step2@example.com"
    }
  ],
  "viewers": [
    {
      "name": "Viewer 1",
      "contact_id": "38528aa9c323463c9563b3608c18467d9d569e09",
      "inviter_role": false,
      "default_email": "viewer@example.com",
      "signing_order": 1
    }
  ],
  "approvers": [
    {
      "name": "Approver 1",
      "inviter_role": false,
      "default_email": "approver@example.com",
      "signing_order": 3,
      "expiration_days": 15
    }
  ],
  "attributes": {
    "brand_id": "d7fcf72b4bbc47b0cc629ffe8b24421c66fec6a0",
    "on_complete": "none",
    "redirect_uri": "https://signnow.com"
  },
  "template_data": [
    {
      "name": "Signer 1",
      "role_id": "d7fcf72b4bbc47b0cc629ffe8b24421c66fec6a0",
      "inviter_role": false,
      "default_email": "",
      "signing_order": 1
    },
    {
      "name": "Signer 2",
      "role_id": "14819de93089e889ab9f5283db9b7c39ad667e43",
      "inviter_role": false,
      "default_email": "signer2@example.com",
      "signing_order": 2
    }
  ],
  "invite_link_instructions": "Please sign strictly before the deadline."
}
```

## Responses

### 200

OK

**Example** (`Example 1`)

```json
{
  "cc": [
    "manager@example.com",
    "records@example.com"
  ],
  "id": "c81e728d9d4c2f63a5b9e0f1a2b3c4d5e6f7a8b9",
  "data": [
    {
      "name": "Signer 1",
      "role_id": "a1b2c3d4e5f67890123456789abcdef012345678",
      "inviter_role": true,
      "default_email": "",
      "signing_order": 1
    },
    {
      "name": "Signer 2",
      "role_id": "b2c3d4e5f67890123456789abcdef0123456789",
      "inviter_role": false,
      "default_email": "jane.smith@example.com",
      "signing_order": 1,
      "decline_by_signature": true
    },
    {
      "name": "Signer 3",
      "role_id": "c3d4e5f67890123456789abcdef01234567890",
      "inviter_role": false,
      "default_email": "bob.jones@example.com",
      "signing_order": 2
    }
  ],
  "cc_step": [
    {
      "name": "HR Team",
      "step": 1,
      "email": "hr.team@example.com"
    },
    {
      "name": "Legal Team",
      "step": 2,
      "email": "legal.team@example.com"
    }
  ],
  "viewers": [
    {
      "name": "External Auditor",
      "contact_id": "d4e5f67890123456789abcdef012345678901",
      "inviter_role": false,
      "default_email": "auditor@example.com",
      "signing_order": 1
    }
  ],
  "approvers": [
    {
      "name": "Director of Operations",
      "inviter_role": false,
      "default_email": "director@example.com",
      "signing_order": 3,
      "expiration_days": 15
    }
  ],
  "attributes": {
    "brand_id": "e5f67890123456789abcdef0123456789012",
    "on_complete": "document_only",
    "redirect_uri": "https://example.com/success"
  },
  "document_id": "3f4e5d6c7b8a901234567890abcdef1234567890",
  "invite_link_instructions": "Please review the document carefully before signing."
}
```

### 400

- Incorrect payload.
- User is not document owner.
- Document not found.
- The `viewers` value length is incorrect.
- The `approvers` value length is incorrect.
- The payment request name is missing.
- The payment request name format is incorrect.
- The payment request type is missing.
- The payment request type format is incorrect.
- The payment request type value is incorrect.
- The `template_data.name` format is incorrect.
- The `template_data.name` length is incorrect.
- The `template_data.name` contains unsupported characters.
- The `template_data.role_id` format is incorrect.
- The `template_data.role_id` value is incorrect.
- The `cc` format is incorrect.
- The `cc` value format is incorrect.
- The `cc_step` format is incorrect.
- The `cc_step` item format is incorrect.
- The `cc_step.email` format is incorrect.
- The `viewers` format is incorrect.
- The `viewers` item format is incorrect
- The `viewers.default_email` format is incorrect.
- The `viewers.default_email` is missing.
- The `viewers.default_email` length is incorrect.
- The `viewers.default_email` contains unsupported characters.
- The `viewers.default_email` value format is incorrect.
- The `viewers.name` format is incorrect.
- The `viewers.name` is missing.
- The `viewers.name` length is incorrect.
- The `viewers.name` contains unsupported characters.
- The `viewers.signing_order` format is incorrect.
- The `viewers.signing_order` is missing.
- The `viewers.signing_order` value is incorrect.
- The `viewers.inviter_role` format is incorrect.
- The `viewers.contact_id` format is incorrect.
- The `viewers.contact_id` value is incorrect.
- The `approvers` format is incorrect.
- The `approvers` item format is incorrect.
- The `approvers.default_email` format is incorrect.
- The `approvers.default_email` is missing.
- The `approvers.default_email` length is incorrect.
- The `approvers.default_email` contains unsupported characters.
- The `approvers.default_email` value format is incorrect.
- The `approvers.name` format is incorrect.
- The `approvers.name` is missing.
- The `approvers.name` length is incorrect.
- The `approvers.name` contains unsupported characters.
- The `approvers.signing_order` format is incorrect.
- The `approvers.signing_order` is missing.
- The `approvers.signing_order` value is incorrect.
- The `approvers.inviter_role` format is incorrect.
- The `approvers.expiration_days` format is incorrect.
- The `approvers.expiration_days` value is incorrect.
- The `attributes` format is incorrect.
- The `attributes.brand_id` value is incorrect.
- The `attributes.on_complete` value is incorrect.
- The `attributes.redirect_uri` format is incorrect.
- The `attributes.redirect_uri` is missing.
- The `attributes.redirect_uri` url format is incorrect.
- The `attributes.redirect_uri` length is incorrect.
- Payment request configuration is incorrect (multi-role).
- Payment request configuration is incorrect (existing field).
- The `role_id` configuration is incorrect (mismatch).
- The `role_id` is incorrect (not in doc).
- The `role_id` is incorrect (not active signer).
- Recipient configuration is incorrect (fulfilled).
- Recipient configuration is incorrect (signed).
- Recipient configuration is incorrect (forbidden).

**Example** (`Incorrect payload`)

```json
{
  "errors": [
    {
      "code": 65536,
      "message": "Invalid payload"
    }
  ]
}
```

**Example** (`Document not found`)

```json
{
  "errors": [
    {
      "code": 65582,
      "message": "Document not found"
    }
  ]
}
```

**Example** (`User is not document owner`)

```json
{
  "errors": [
    {
      "code": 65582,
      "message": "User is not document owner"
    }
  ]
}
```

**Example** (`The `cc` format is incorrect`)

```json
{
  "errors": [
    {
      "code": 65536,
      "message": "cc must be array"
    }
  ]
}
```

**Example** (`The `viewers.name` is missing`)

```json
{
  "errors": [
    {
      "code": 65536,
      "message": "The name value should not be blank."
    }
  ]
}
```

**Example** (`The `approvers.name` is missing`)

```json
{
  "errors": [
    {
      "code": 65536,
      "message": "The name value should not be blank."
    }
  ]
}
```

**Example** (`The `cc_step` format is incorrect`)

```json
{
  "errors": [
    {
      "code": 65536,
      "message": "cc_step must be array"
    }
  ]
}
```

**Example** (`The `viewers` format is incorrect`)

```json
{
  "errors": [
    {
      "code": 65536,
      "message": "Viewer value should be of type array."
    }
  ]
}
```

**Example** (`The `cc` value format is incorrect`)

```json
{
  "errors": [
    {
      "code": 65536,
      "message": "Email must be a valid email."
    }
  ]
}
```

**Example** (`The `approvers` format is incorrect`)

```json
{
  "errors": [
    {
      "code": 65536,
      "message": "Approvers value should be of type array."
    }
  ]
}
```

**Example** (`The payment request name is missing`)

```json
{
  "errors": [
    {
      "code": 65536,
      "message": "The field name for the payment request is required"
    }
  ]
}
```

**Example** (`The payment request type is missing`)

```json
{
  "errors": [
    {
      "code": 65536,
      "message": "The field type for the payment request is required"
    }
  ]
}
```

**Example** (`The `attributes` format is incorrect`)

```json
{
  "errors": [
    {
      "code": 65536,
      "message": "Attributes value should be of type array."
    }
  ]
}
```

**Example** (`The `cc_step` item format is incorrect`)

```json
{
  "errors": [
    {
      "code": 65536,
      "message": "all cc_steps must be arrays"
    }
  ]
}
```

**Example** (`The `viewers.default_email` is missing`)

```json
{
  "errors": [
    {
      "code": 65536,
      "message": "The default_email value should not be null."
    }
  ]
}
```

**Example** (`The `viewers.name` format is incorrect`)

```json
{
  "errors": [
    {
      "code": 65536,
      "message": "The name value should be of type string."
    }
  ]
}
```

**Example** (`The `viewers.name` length is incorrect`)

```json
{
  "errors": [
    {
      "code": 65536,
      "message": "The name value is too long. It should have 255 characters or less."
    }
  ]
}
```

**Example** (`The `viewers.signing_order` is missing`)

```json
{
  "errors": [
    {
      "code": 65536,
      "message": "The signing_order value should not be blank."
    }
  ]
}
```

**Example** (`The `viewers` item format is incorrect`)

```json
{
  "errors": [
    {
      "code": 65536,
      "message": "All viewer value should be of type array."
    }
  ]
}
```

**Example** (`The `cc_step.email` format is incorrect`)

```json
{
  "errors": [
    {
      "code": 65536,
      "message": "Email must be a valid email."
    }
  ]
}
```

**Example** (`The `role_id` is incorrect (not in doc)`)

```json
{
  "errors": [
    {
      "code": 65536,
      "message": "The role id {$roleId} is not belongs to the document"
    }
  ]
}
```

**Example** (`The `viewers` value length is incorrect`)

```json
{
  "errors": [
    {
      "code": 65536,
      "message": "The viewers value is too long. It should have 65535 characters or less in json string format."
    }
  ]
}
```

**Example** (`The `approvers.default_email` is missing`)

```json
{
  "errors": [
    {
      "code": 65536,
      "message": "The default_email value should not be null."
    }
  ]
}
```

**Example** (`The `approvers.name` format is incorrect`)

```json
{
  "errors": [
    {
      "code": 65536,
      "message": "The name value should be of type string."
    }
  ]
}
```

**Example** (`The `approvers.name` length is incorrect`)

```json
{
  "errors": [
    {
      "code": 65536,
      "message": "The name value is too long. It should have 255 characters or less."
    }
  ]
}
```

**Example** (`The `approvers.signing_order` is missing`)

```json
{
  "errors": [
    {
      "code": 65536,
      "message": "The signing_order value should not be blank."
    }
  ]
}
```

**Example** (`The `approvers` item format is incorrect`)

```json
{
  "errors": [
    {
      "code": 65536,
      "message": "All approvers value should be of type array."
    }
  ]
}
```

**Example** (`The `attributes.redirect_uri` is missing`)

```json
{
  "errors": [
    {
      "code": 65536,
      "message": "The redirect_uri attribute format is invalid."
    }
  ]
}
```

**Example** (`The `approvers` value length is incorrect`)

```json
{
  "errors": [
    {
      "code": 65536,
      "message": "The approvers value is too long. It should have 65535 characters or less in json string format."
    }
  ]
}
```

**Example** (`The `viewers.contact_id` value is incorrect`)

```json
{
  "errors": [
    {
      "code": 65536,
      "message": "The contact_id should be valid unique id."
    }
  ]
}
```

**Example** (`The payment request type value is incorrect`)

```json
{
  "errors": [
    {
      "code": 65536,
      "message": "Not allowed field type for the payment request"
    }
  ]
}
```

**Example** (`The `attributes.brand_id` value is incorrect`)

```json
{
  "errors": [
    {
      "code": 65536,
      "message": "The brand_id attribute should be valid unique id"
    }
  ]
}
```

**Example** (`The `template_data.name` format is incorrect`)

```json
{
  "errors": [
    {
      "code": 65536,
      "message": "The name value should be of type string."
    }
  ]
}
```

**Example** (`The `template_data.name` length is incorrect`)

```json
{
  "errors": [
    {
      "code": 65536,
      "message": "The name value is too long. It should have 255 characters or less."
    }
  ]
}
```

**Example** (`The `viewers.contact_id` format is incorrect`)

```json
{
  "errors": [
    {
      "code": 65536,
      "message": "The contact_id value should be of type string."
    }
  ]
}
```

**Example** (`The payment request name format is incorrect`)

```json
{
  "errors": [
    {
      "code": 65536,
      "message": "The field name for the payment request must be a string"
    }
  ]
}
```

**Example** (`The payment request type format is incorrect`)

```json
{
  "errors": [
    {
      "code": 65536,
      "message": "The field type for the payment request must be a string"
    }
  ]
}
```

**Example** (`Recipient configuration is incorrect (signed)`)

```json
{
  "errors": [
    {
      "code": 65536,
      "message": "Actor {$roleName} not allowed to edit, because he has some signed fields."
    }
  ]
}
```

**Example** (`The `role_id` is incorrect (not active signer)`)

```json
{
  "errors": [
    {
      "code": 65536,
      "message": "The role id {$roleId} is not active signer actor."
    }
  ]
}
```

**Example** (`The `template_data.role_id` value is incorrect`)

```json
{
  "errors": [
    {
      "code": 65536,
      "message": "Field role_id should be valid unique id"
    }
  ]
}
```

**Example** (`The `viewers.inviter_role` format is incorrect`)

```json
{
  "errors": [
    {
      "code": 65536,
      "message": "The inviter_role value should be of type bool."
    }
  ]
}
```

**Example** (`The `viewers.signing_order` value is incorrect`)

```json
{
  "errors": [
    {
      "code": 65536,
      "message": "The signing_order value should be between 1 and 127."
    }
  ]
}
```

**Example** (`The `attributes.on_complete` value is incorrect`)

```json
{
  "errors": [
    {
      "code": 65536,
      "message": "The on_complete attribute value is invalid."
    }
  ]
}
```

**Example** (`The `template_data.role_id` format is incorrect`)

```json
{
  "errors": [
    {
      "code": 65536,
      "message": "The role_id value should be of type string."
    }
  ]
}
```

**Example** (`The `viewers.default_email` format is incorrect`)

```json
{
  "errors": [
    {
      "code": 65536,
      "message": "The default_email value should be of type string."
    }
  ]
}
```

**Example** (`The `viewers.default_email` length is incorrect`)

```json
{
  "errors": [
    {
      "code": 65536,
      "message": "The default_email value is too long. It should have 250 characters or less."
    }
  ]
}
```

**Example** (`The `viewers.signing_order` format is incorrect`)

```json
{
  "errors": [
    {
      "code": 65536,
      "message": "The signing_order value should be of type integer."
    }
  ]
}
```

**Example** (`Recipient configuration is incorrect (forbidden)`)

```json
{
  "errors": [
    {
      "code": 65536,
      "message": "Actor {$roleName} not allowed to edit, forbidden after correction."
    }
  ]
}
```

**Example** (`Recipient configuration is incorrect (fulfilled)`)

```json
{
  "errors": [
    {
      "code": 65536,
      "message": "Actor {$roleName} not allowed to edit, because he has fulfilled invite."
    }
  ]
}
```

**Example** (`The `approvers.inviter_role` format is incorrect`)

```json
{
  "errors": [
    {
      "code": 65536,
      "message": "The inviter_role value should be of type bool."
    }
  ]
}
```

**Example** (`The `approvers.signing_order` value is incorrect`)

```json
{
  "errors": [
    {
      "code": 65536,
      "message": "The signing_order value should be between 1 and 127."
    }
  ]
}
```

**Example** (`The `approvers.default_email` format is incorrect`)

```json
{
  "errors": [
    {
      "code": 65536,
      "message": "The default_email value should be of type string."
    }
  ]
}
```

**Example** (`The `approvers.default_email` length is incorrect`)

```json
{
  "errors": [
    {
      "code": 65536,
      "message": "The default_email value is too long. It should have 250 characters or less."
    }
  ]
}
```

**Example** (`The `approvers.signing_order` format is incorrect`)

```json
{
  "errors": [
    {
      "code": 65536,
      "message": "The signing_order value should be of type integer."
    }
  ]
}
```

**Example** (`The `attributes.redirect_uri` format is incorrect`)

```json
{
  "errors": [
    {
      "code": 65536,
      "message": "The redirect_uri attribute must be a string."
    }
  ]
}
```

**Example** (`The `attributes.redirect_uri` length is incorrect`)

```json
{
  "errors": [
    {
      "code": 65536,
      "message": "The redirect_uri attribute format is invalid."
    }
  ]
}
```

**Example** (`The `approvers.expiration_days` value is incorrect`)

```json
{
  "errors": [
    {
      "code": 65536,
      "message": "The expiration_days value should be between 3 and 180."
    }
  ]
}
```

**Example** (`The `viewers.name` contains unsupported characters`)

```json
{
  "errors": [
    {
      "code": 65536,
      "message": "4-byte characters in name are not supported."
    }
  ]
}
```

**Example** (`The `approvers.expiration_days` format is incorrect`)

```json
{
  "errors": [
    {
      "code": 65536,
      "message": "The expiration_days value should be of type integer."
    }
  ]
}
```

**Example** (`The `role_id` configuration is incorrect (mismatch)`)

```json
{
  "errors": [
    {
      "code": 65536,
      "message": "The role_id do not belongs to the role name. Role id: {$roleId} . Role name: {$roleName}"
    }
  ]
}
```

**Example** (`The `approvers.name` contains unsupported characters`)

```json
{
  "errors": [
    {
      "code": 65536,
      "message": "4-byte characters in name are not supported."
    }
  ]
}
```

**Example** (`The `attributes.redirect_uri` url format is incorrect`)

```json
{
  "errors": [
    {
      "code": 65536,
      "message": "The redirect_uri attribute format is invalid."
    }
  ]
}
```

**Example** (`The `viewers.default_email` value format is incorrect`)

```json
{
  "errors": [
    {
      "code": 65536,
      "message": "The default_email value is not a valid email address."
    }
  ]
}
```

**Example** (`Payment request configuration is incorrect (multi-role)`)

```json
{
  "errors": [
    {
      "code": 65582,
      "message": "Adding a payment requesting on the field with several actors is disallowed"
    }
  ]
}
```

**Example** (`The `approvers.default_email` value format is incorrect`)

```json
{
  "errors": [
    {
      "code": 65536,
      "message": "The default_email value is not a valid email address."
    }
  ]
}
```

**Example** (`The `template_data.name` contains unsupported characters`)

```json
{
  "errors": [
    {
      "code": 65536,
      "message": "4-byte characters in name are not supported."
    }
  ]
}
```

**Example** (`Payment request configuration is incorrect (existing field)`)

```json
{
  "errors": [
    {
      "code": 65582,
      "message": "Adding a payment requesting on the document with payment field is disallowed"
    }
  ]
}
```

**Example** (`The `viewers.default_email` contains unsupported characters`)

```json
{
  "errors": [
    {
      "code": 65536,
      "message": "4-byte characters in default_email are not supported."
    }
  ]
}
```

**Example** (`The `approvers.default_email` contains unsupported characters`)

```json
{
  "errors": [
    {
      "code": 65536,
      "message": "4-byte characters in default_email are not supported."
    }
  ]
}
```

## Code Examples

> Replace `$SIGNNOW_ACCESS_TOKEN` and any `{placeholder}` values before running.

### cURL

```bash
curl -X PUT \
  "https://api.signnow.com/document/{template_id}/template/routing/detail" \
  -H "Authorization: Bearer $SIGNNOW_ACCESS_TOKEN" \
  -H "Content-Type: application/json" \
  -d '{"cc": ["observer1@example.com", "observer2@example.com"], "cc_step": [{"name": "CC 1", "step": 1, "email": "step1@example.com"}, {"name": "CC 2", "step": 2, "email": "step2@example.com"}], "viewers": [{"name": "Viewer 1", "contact_id": "38528aa9c323463c9563b3608c18467d9d569e09", "inviter_role": false, "default_email": "viewer@example.com", "signing_order": 1}], "approvers": [{"name": "Approver 1", "inviter_role": false, "default_email": "approver@example.com", "signing_order": 3, "expiration_days": 15}], "attributes": {"brand_id": "d7fcf72b4bbc47b0cc629ffe8b24421c66fec6a0", "on_complete": "none", "redirect_uri": "https://signnow.com"}, "template_data": [{"name": "Signer 1", "role_id": "d7fcf72b4bbc47b0cc629ffe8b24421c66fec6a0", "inviter_role": false, "default_email": "", "signing_order": 1}, {"name": "Signer 2", "role_id": "14819de93089e889ab9f5283db9b7c39ad667e43", "inviter_role": false, "default_email": "signer2@example.com", "signing_order": 2}], "invite_link_instructions": "Please sign strictly before the deadline."}'
```

---
*Full reference: https://docs.signnow.com/docs/template/operations/edit-template-routing-details*
