PDF Updated? You Don't have to Rebuild Your Template.
If you've ever managed signing templates in production, you've hit this problem. A lawyer updates a clause. Legal sends a revised PDF. Your 14-field NDA template now needs to be rebuilt from scratch: re-upload the document, replace every field, reassign every signer.
For one template that's an hour of work. For ten templates across fifty customer workspaces, it becomes an actual problem.
Template Document Replacement solves it. Swap the underlying PDF on any template and every field, signer assignment, and setting stays exactly where it was.
How It Works

Swap the PDF. Keep Everything Else.
Upload a new PDF. Firma.dev validates that the page count matches the original and that page dimensions are within 1pt tolerance. If both checks pass, the document is swapped instantly. Every field position, every signer assignment, every template setting remains untouched.
Why the Validation Rules Exist
The validation rules aren't arbitrary constraints, they're safeguards. If the page count changes or dimensions shift significantly, field positions would drift off-page or land in the wrong location. The 1pt tolerance covers minor rendering differences between PDF exports from the same source file, while blocking replacements that would misalign your fields.

Using the API
The endpoint is straightforward. Encode your replacement PDF as base64 and POST it to the template (API reference: https://docs.firma.dev/api-reference/v01.09.00/templates/replace-template-document)
The response is the updated template object. If validation fails, you get a 400 with a clear error indicating whether the issue is page count mismatch, dimension mismatch, or an invalid PDF.
Validation Rules
DOC and DOCX uploads via the UI are automatically converted to PDF before validation. The API accepts PDF directly.
Check
Requirement
Page count
Must match the original exactly
Page dimensions
Must match within 1pt tolerance per page
File format
Base64-encoded PDF via API; PDF, DOC, or DOCX (up to 60MB) via UI




