Pre-fill documents from your CRM

How-to guide3 min read

Data fields are filled from the dataobject you send. Your code (or your integration tool) maps your system's field names to the template's data names once. Notriv doesn't need to know how your CRM is organized.

Map your fields

Your CRM fieldTemplate data name
Contact → Full Nameclient_name
Deal → Amountpurchase_price
Deal → Close Dateclosing_date
const deal = await crm.deals.get(dealId)

await notriv.envelopes.create({
  template: 'tmpl_purchase_agreement',
  signers: { client: { name: deal.contact.fullName, email: deal.contact.email } },
  data: {
    client_name: deal.contact.fullName,
    purchase_price: deal.amount,
    closing_date: deal.closeDate,
  },
  metadata: { crm_deal_id: deal.id },
})
Tip
Using Zapier, Make or n8n? They read the template's data_keys and show a dropdown for each one, so you map fields by clicking.

Values filled automatically

Leave these out and Notriv fills them for you:

Data nameFilled with
todayToday's date, MM/DD/YYYY
sender.nameYour account name
sender.emailYour account email
client.nameThe signer's name for that role (works for any role)
client.emailThe signer's email for that role

Mistakes are caught before sending

Nothing is sent if the data is wrong, and the error says exactly what to fix:

ProblemError
A required value is missingmissing_data
A name the template doesn’t use (often a typo)unknown_data_key
A signer role is missingsigner_missing

Next steps

Was this page helpful?