---
title: "Edit document group"
method: PATCH
path: "/v2/document-groups/{document_group_id}"
---

# Edit document group

`PATCH /v2/document-groups/{document_group_id}`

## Request

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

This endpoint allows users to reorder documents and update the action performed upon document group completion.
> Document group should not have pending or fulfilled signature invites.

## Request body

- object
  - `order` string[]: List of document IDs in the group.
  - `email_action_on_complete` string: Specifies the action to be taken upon invite completion. Allowed values: `documents_and_attachments`: Email documents and attachments to all parties. `documents_and_attachments_only_to_recipients`: Email documents and attachments only to recipients. `without_documents_and_attachments`: Do not email documents or any attachments.

## Response `204`

Success.

## Other responses

- `400`: **Authorization errors:** * Wrong, expired, or missing token. **Validation errors:** - `order` type is incorrect. - Document ID is incorrect. Document IDs must match `[a-z0-9]{40}`. - Document IDs are not unique. - `email_action_on_complete` value is incorrect.
- `404`: Document group not found.
- `422`: - User is not the owner of the document group. - Payload documents do not match the group. - Document group has pending or fulfilled invites.

---

[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)
