Docupilot
HomeLoginSignup
  • Docupilot Help Documentation
  • Getting Started
  • Building Templates
    • Tokens (Merge Field)
    • Document Builder
    • AI-Powered Template Builder
    • Word Document (DOCX) & PowerPoint (PPTX)
    • Excel (XLSX)
    • Fillable PDF
    • Template Preferences
    • Formatting Your Data
    • Numerical Calculations
    • Advanced usage
  • Test your document template
  • Deliveries
    • Email
    • Webhook
    • Dropbox
    • Google Drive
    • One Drive
    • DropboxSign (formerly Hellosign)
    • DocuSign
    • SignNow
    • Xodo sign (formerly Eversign)
    • Signable
    • Yousign
    • Amazon S3
    • Azure Blob Delivery
    • SFTP
    • Box Drive
  • Create document
    • Data Capture Form
    • API & Webhook Integration
    • Bulk Create
    • Integrate with Zapier
    • Integrate with Make
    • Integrate with Zoho Flow
    • Integrate with Integrately
  • Integrations
    • Google Forms
    • Google Sheets
    • Airtable Extension
    • Microsoft Word Add-In
  • Collaborating with multiple users
    • Invite users
    • Manage & delete users
  • Reports
  • Settings
    • Workspace
    • API Settings
    • Manage Subscription
    • Linked Accounts
  • Folders & Templates management
    • Manage Folders
    • Manage Templates
    • Share Templates & Folders
  • Profile & Account Security
  • Frequently Asked Questions (FAQs)
  • Developers
    • API Overview
    • Templates API
    • Folders API
  • Updates
    • Scheduled Downtime Notification
Powered by GitBook
On this page
  • What is a token?
  • Token with special characters
  • Predefined tokens
  • Auto Number
  • Conversion of token to plain text
  • Dynamic Tokens

Was this helpful?

  1. Building Templates

Tokens (Merge Field)

Tokens helps you to generalize your template’s dynamic information and standardize the document creation process.

What is a token?

Tokens help you to generalize your template’s dynamic information and standardize the document creation process. These tokens can automatically populate a Recipient’s Name, email address, Company name, and more.The format for token is {{company_name}}, {{client.name}}. Think of the information that is always changing in your document, then replace that with a token.

  • The token cannot contain any spaces in between.

  • Special characters are not supported in tokens. Tokens only support underscores (_) and nested tokens are separated by a dot (.)

  • Token names should not start with an underscore (_) except for predefined tokens.

  • Token names cannot contain any special character except underscore(_).

Token with special characters

To insert a token containing spaces and special characters, it should be enclosed with square brackets. For example:

  1. {{[company name]}}

  2. {{[Discount %]}}

  3. {{[Invoice #]}}

Tokens with special characters can be used inside formatters. Examples:

  1. {{upper [First Name]}}

  2. {{abbreviate [Full Name]}}

  3. {{multiply [Sub Total] [Discount %]}}

Note: Closing square bracket character ] cannot be used as a token name.

Predefined tokens

These tokens are predefined by Docupilot. They will automatically populate certain information specific to your document. (Ex. Current Date and Date Time with timezone)

Here is a list of all available predefined tokens:

Token

Description

{{_date}}

Displays the current date.

{{_datetime}}

Displays the current data and time with Timezone support.

{{_auto_number}}

Auto Number

Auto Number feature allows you to generate unique number in the document. This feature will be useful if you are generating invoices, tickets, or other documents that need unique number in the document. You will need to define a starting number and with each new document generation, we will automatically increment that number. You can always reset it back to the number of your choice.

To display the Auto Number in your generated document, or in the output file name, or if you want to use it inside a delivery configuration you will need to use the token {{_auto_number}} in respective content/configurations. You can set the starting number in Preferences page -> Advance settings

Conversion of token to plain text

When a token is preceded by a '\' (backslash) then it is considered as plain text and is printed in the output document. Examples:

Input

Output

\{{name}}

{{name}}

\{{client.name}}

{{client.name}}

\{{[Company name]}}

{{[Company name]}}

Dynamic Tokens

Tokens can be generated dynamically inside a template by using the var helper in tandem with the concat helper.

Token
Value passed
Final token

{{var (concat Title "value")}}

Title: Final

{{var "Final_value"}}

{{#each (group_by firms lookup=”firmname”)}} {{var (concat key "_brand_value")}} {{/each}}

firmname: Google

{{var "Google_brand_value"}}

PreviousBuilding TemplatesNextDocument Builder

Last updated 1 year ago

Was this helpful?

Displays unique number in the document. You will need to define a starting number in and with each document that is generated, this number will be incremented by 1.

You can set the starting number in Preferences page -> Advance settings
template preferences