Templates allow you to create transactions from a template that is preconfigured in advance. Template parameters automatically apply to all transactions created from it.
A template can bear 2 states:
draft
: the template is not yet published. It can be edited but not used to create a transaction.published
: the template can be used to create a transaction.
A template contains at least:
- a document or a specimen,
- a field,
- a participant.
A specimen is a temporary document added to the template by its creator. The specimen needs to be replaced by the final document to be signed during the transaction creation.
Note that when creating a transaction from a template, only the template_id
parameter is required. All other parameters are optional, unless they are requested by the template creator.
Templates usage requirements:
- If the template contains a specimen, the latter needs to be replaced by the final document when creating the transaction.
- If the template contains an unknown participant, you need to set the requested information (email, full name and phone number) when creating the transaction.
- If the template creator sets a
duration
, it will automatically apply to the created transaction. If s/he sets an expiration date, you need to set theexpires_at
parameter when creating the transaction.