v1

latestSwagger 2.02026-07-134026156.7 KB
Templates

Update a template's document with a cached S3 file upload

Updates a PDF template's document using a cached file upload. This is a three-step process: First, request a presigned URL to upload your PDF file to our S3 bucket. Then, use that URL to upload your PDF file. Finally, submit the ID of the uploaded file to replace the template's document.

put/templates/{template_id}?endpoint_variant=update_template_pdf_with_cached_upload

Path parameters

template_idstring required

Request body

Example request

{
  "template": {
    "name": "Replaced Template",
    "document": {
      "id": "original-b6903dbfb15c13bbad1444c35064df9e",
      "storage": "cache",
      "metadata": {
        "size": 62553,
        "filename": "fw8ben-presigned.pdf",
        "mime_type": "application/pdf",
        "md5_hash": "ca6fdfed355b9e89f9a94ee54688a231",
        "s3_bucket": null,
        "s3_region": null
      }
    }
  }
}

Response

returns a template with updated document

status'success' | 'error' required
errorsstring[]