Retrieves the specified document from the envelope. If the account has the Highlight Data Changes feature enabled, there is an option to request that any changes in the envelope be highlighted.

The {documentID} parameter takes two special values:

Value Description
combined Retrieve a PDF that contains the combined content of all documents and the certificate.
archive Retrieve a ZIP archive that contains all of the PDF documents, the certificate, and any .WAV files used for voice authentication.

Request

HTTP request

GET /v2.1/accounts/{accountId}/envelopes/{envelopeId}/documents/{documentId}

Parameters

Parameter NameValueDescription
Path Parameters
accountIdstring

The external account number (int) or account ID GUID.

documentIdstring

Integer that identifies the document in the envelope.

envelopeIdstring

The envelope's GUID.

Example: 93be49ab-afa0-4adf-933c-f752070d71ec

Optional Query Parameters
certificatestring

When set to false, the envelope signing certificate is removed from the download.

documents_by_useridstring

When set to true, allows recipients to get documents by their user id. For example, if a user is included in two different routing orders with different visibilities, using this parameter returns all of the documents from both routing orders.

encodingstring

encryptstring

When set to true, the PDF bytes returned in the response are encrypted for all the key managers configured on your DocuSign account. The documents can be decrypted with the KeyManager Decrypt Document API.

languagestring

Specifies the language for the Certificate of Completion in the response. The supported languages are: Chinese Simplified (zh_CN), Chinese Traditional (zh_TW), Dutch (nl), English US (en), French (fr), German (de), Italian (it), Japanese (ja), Korean (ko), Portuguese (pt), Portuguese (Brazil) (pt_BR), Russian (ru), Spanish (es).

recipient_idstring

Allows the sender to retrieve the documents as one of the recipients that they control. The documents_by_userid parameter must be set to false for this functionality to work.

shared_user_idstring

The ID of a shared user that you want to impersonate in order to retrieve their view of the list of documents. This parameter is used in the context of a shared inbox (i.e., when you share envelopes from one user to another through the RADmin console).

show_changesstring

When set to true, any changed fields for the returned PDF are highlighted in yellow and optional signatures or initials outlined in red.

watermarkstring

When set to true, the account has the watermark feature enabled, and the envelope is not complete, the watermark for the account is added to the PDF documents. This option can remove the watermark.

Responses

CodeDescriptionReference
200

Successful response.

400

Error encountered.

errorDetails

SDK Method

Envelopes::getDocument

Definitions

errorDetails

This object describes errors that occur. It is only valid for responses and ignored in requests.

errorCodestring

The code associated with the error condition.

messagestring

A brief message describing the error condition.

Examples

Get a Single Document as a PDF File

This example shows how to retrieve a single document from an envelope as a PDF file.

The request for this endpoint has no payload.

Request

GET /restapi/v2.1/accounts/1703061/envelopes/44efc9e6-915e-4b1d-9b54-801410d6922d/documents/3

Response
"PDF File"
Get All Documents as a Single PDF File

If you use combined instead of a document id the response is a PDF file that contains all of the documents in the specified envelope.

The request for this endpoint has no payload.

Request

GET /restapi/v2.1/accounts/1703061/envelopes/44efc9e6-915e-4b1d-9b54-801410d6922d/documents/combined

Response
"PDF File"
List All Documents in an Envelope

This example shows how to get a list of all the documents in an envelope.

The request for this endpoint has no payload.

Request

GET /restapi/v2.1/accounts/1703061/envelopes/44efc9e6-915e-4b1d-9b54-801410d6922d/documents

Response
{
  "envelopeDocuments": [
    {
      "availableDocumentTypes": [
        {
          "isDefault": "true",
          "type": "electronic"
        }
      ],
      "display": "inline",
      "documentId": "1",
      "includeInDownload": "true",
      "name": "NDA.pdf",
      "order": "1",
      "pages": "3",
      "signerMustAcknowledge": "no_interaction",
      "type": "content",
      "uri": "/envelopes/44efc9e6-915e-4b1d-9b54-801410d6922d/documents/1"
    },
    {
      "availableDocumentTypes": [
        {
          "isDefault": "true",
          "type": "electronic"
        }
      ],
      "display": "inline",
      "documentId": "2",
      "includeInDownload": "true",
      "name": "House.pdf",
      "order": "2",
      "pages": "1",
      "signerMustAcknowledge": "no_interaction",
      "type": "content",
      "uri": "/envelopes/44efc9e6-915e-4b1d-9b54-801410d6922d/documents/2"
    },
    {
      "availableDocumentTypes": [
        {
          "isDefault": "true",
          "type": "electronic"
        }
      ],
      "display": "inline",
      "documentId": "3",
      "includeInDownload": "true",
      "name": "contractor_agreement.docx",
      "order": "3",
      "pages": "2",
      "signerMustAcknowledge": "no_interaction",
      "type": "content",
      "uri": "/envelopes/44efc9e6-915e-4b1d-9b54-801410d6922d/documents/3"
    },
    {
      "availableDocumentTypes": [
        {
          "isDefault": "true",
          "type": "electronic"
        }
      ],
      "display": "inline",
      "documentId": "certificate",
      "includeInDownload": "true",
      "name": "Summary",
      "order": "999",
      "pages": "4",
      "signerMustAcknowledge": "no_interaction",
      "type": "summary",
      "uri": "/envelopes/44efc9e6-915e-4b1d-9b54-801410d6922d/documents/certificate"
    }
  ],
  "envelopeId": "44efc9e6-915e-4b1d-9b54-801410d6922d"
}
}} />