capabilities.work

PDF Services Generate Document from Template

A 6-step recipe with Adobe Creative Suite. We can help you get access.

Recipe · 6 steps

PDF Services Generate Document from Template

Upload a template, merge data, resolve the output, and clean up the template asset.

  1. Request an upload asset for the Word document template, receiving an asset id and a pre-signed upload URI.
  2. Submit a document-generation operation merging the supplied JSON data into the uploaded template. The API returns a job id for polling.
  3. Poll the document-generation operation status, repeating while it is in progress and branching once it is done or failed.
  4. Retrieve the generated document asset metadata and a fresh temporary download URI for the output file.
  5. Delete the uploaded template asset now that the generated document has been retrieved, releasing storage before the automatic 24 hour expiry.
  6. Surface the error details from the failed document-generation operation.
What you'll need to have ready
  • outputFormat: Output format of the generated document (pdf or docx).
  • jsonDataForMerge: JSON data whose keys map to template tags in the document.
  • notTaggedAdds: Whether to include non-tagged content as plain text additions.
For your developer

Arazzo workflow adobe-creative-suite:generate-document-from-template, 6 operations: uploadAsset → generateDocument → getOperationStatus → getAsset → deleteAsset → getOperationStatus. Specs on APIs.io.