---
title: "Edit template recipients"
method: PUT
path: "/document/{template_id}/template/routing/detail"
---

# Edit template recipients

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

## Request

- Base URL: `https://api.signnow.com`
- URL: `https://api.signnow.com/document/{template_id}/template/routing/detail`
- Auth: HTTP bearer
- TypeScript: <https://skmtc.dev/signnow/apis/signnow-api/docs/document/:template_id/template/routing/detail/put.ts> (a function with typed inputs; its response is checked against the schema)

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.

## Request body

- object
  - `cc` string[]: A list of email addresses that will receive a carbon copy of the document.
  - `cc_step` object[]: A list of CC recipients assigned to specific steps in the signing order.
    - `name` string: The display name for the CC recipient.
    - `step` integer: The specific step in the signing order when the email should be sent.
    - `email` string: The email address of the CC recipient.
  - `viewers` object[]: A list of users with view-only permissions.
    - `name` string: The display name of the recipient role.
    - `contact_id` string: The unique identifier of the contact (from Contacts) linked to the document.
    - `inviter_role` boolean: 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` string: 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` integer: The step order for the viewer.
  - `approvers` object[]: A list of users required to approve the document.
    - `name` string: The display name of the recipient role.
    - `inviter_role` boolean: 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` string: 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` integer: The step order for the approver.
    - `expiration_days` integer: Number of days before the approval request expires.
  - `attributes` object: General attributes regarding the document's completion settings and branding.
    - `brand_id` string: The unique identifier of the brand to apply.
    - `on_complete` 'none' | 'document_only' | 'document_and_attachments' | 'document_attachment_only_for_signer': The action to take when the document is completed.
    - `redirect_uri` string: The URL to redirect users to after signing (max 2048 chars).
  - `template_data` object[]: A list of signers and their role configurations.
    - `name` string: The display name of the recipient role.
    - `role_id` string: The unique identifier of the role being updated.
    - `inviter_role` boolean: 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` string: 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` integer: The order in the signing workflow.
  - `invite_link_instructions` string: Custom instructions to be displayed when the invite link is accessed.

## Response `200`

Successful response.

- object
  - `cc` string[]: Email addresses of CC recipients.
  - `id` string: ID of the routing details.
  - `data` object[]: Signer roles and their invite settings.
    - `name` string: Name of the signer role.
    - `role_id` string: ID of the signer role.
    - `inviter_role` boolean: `true` if the template owner is the signer.
    - `default_email` string: Default email address of the signer. Empty if not set.
    - `signing_order` integer: Position of the signer in the signing order.
    - `decline_by_signature` boolean: `true` if the signer can decline to sign.
  - `cc_step` object[]: Steps after which CC recipients are notified.
    - `name` string: Name of the CC recipient.
    - `step` integer: Step after which the CC recipient is notified, starting from `1`.
    - `email` string: Email address of the CC recipient.
  - `viewers` object[]: Viewer roles and their invite settings.
    - `name` string: Name of the viewer role.
    - `contact_id` string: ID of the contact linked to the viewer.
    - `inviter_role` boolean: `true` if the template owner is the viewer.
    - `default_email` string: Default email address of the viewer.
    - `signing_order` integer: Position of the viewer in the signing order.
  - `approvers` object[]: Approver roles and their invite settings.
    - `name` string: Name of the approver role.
    - `inviter_role` boolean: `true` if the template owner is the approver.
    - `default_email` string: Default email address of the approver.
    - `signing_order` integer: Position of the approver in the signing order.
    - `expiration_days` integer: Number of days before the invite expires.
  - `attributes` object: Additional invite settings.
    - `brand_id` string: ID of the brand applied to the invite.
    - `on_complete` string: What to send when the document is completed, for example `document_only`.
    - `redirect_uri` string: URL the recipient is redirected to after completing the signing session.
  - `document_id` string: ID of the template.
  - `invite_link_instructions` string: Instructions shown with the invite link.

## Other responses

- `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).

---

[API](https://skmtc.dev/signnow/apis/signnow-api.md) - [All operations](https://skmtc.dev/signnow/apis/signnow-api/llms.txt) - [OpenAPI document](https://skmtc.dev/signnow/apis/signnow-api/revisions/1c9c30a6142b?raw)
