Create and download document in realtime

This recipe assumes:

Locate your template ID

In the PandaDoc app navigate to the template you would like to use for this particular document. When you are viewing the template the ID is the final part of the URL. For example, in the template ID is “ustHNnVaPCD6MzuoNBbZ8L”

Structure your Document details

Use the create document endpoint description to decide what metadata and details you need to pass to your document. The simplest possible document schema consists of a name, template ID, and at least one recipient. Include your template ID under “template_uuid”

 "name": "My minimal document",
 "template_uuid": "ustHNnVaPCD6MzuoNBbZ8L",
 "recipients": [
     "email":"[email protected]"

Create the Document

Using your authentication token or API key, and the content-type application/json
The response will contain the document ID as the element “id”

  "name":"My minimal document",

Wait for the Document to enter a draft status

See Listening for changes in document status. If you are actively polling your document ID is “id” from the previous step.

Download Document

Using the document ID you can leverage the document download endpoint to retrieve your document.