Invoices
Learn how to automate invoice generation with Documint using Airtable, HubSpot, Make, or Zapier. Connect your data and generate professional invoice PDFs automatically.
Connect to your datasource:
Generating Invoices with Airtable
Connect your Airtable Account to Documint
To connect your Airtable account with Documint, go to Settings > Integrations. You'll pick the Airtable option. In OAuth accounts, you'll click Add Account.

A page will show up for you to grant access to your bases. Feel free to add all current and future bases, or select the ones you want to work with.

And you're all connected! Now, let's work on an Invoice Template 🎉

Connect an Invoice Template to your Base
Open the template gallery and select the Invoice Blueprint you want to work with.

Under Sources, you'll see that there's a Custom Data Source. It's holding the fields that are currently in the template. To connect to Airtable, just click Connect in the Airtable option below it.

Map the Fields
After connecting to Airtable, select the base and table you want to connect with Documint.

In the field selector, pick the fields that will be used in the template.
To use fields coming from a Linked Record, you can click the + to expand it and select the fields coming from it.
Click Finish setup, and the Fields mapped will show up in the Fields panel!

Format the Fields
With the fields placed, you might need to adjust the formatting of some content. It's pretty simple. Just double-click the token and the formatting options will show up.
Number
For numerical fields, you can display them as currency or percentage. Feel free to specify your country's currency and the required decimal places.

Date
It's possible to format the date just as you need. There are the standard formats, but you can also change it to the one you need.

Rich Text
If you have rich text content, you can make it display just as it is in your database. For that, you just need to set Markdown as the text type in the token settings.

Displaying a List of Items
If you're working with Line Items, Documint can display them dynamically. For that, you'll need to set up a loop. Just select the element you want to be repeated for each item (in this case, it will be the row). Click Edit Logic in its properties panel.
In the popup, go to the Repeat/Loop tab and select the list field. Don't forget to save.

And that's it! Now a row will be repeated for each item in that list, and the template will display the table dynamically 🎉
Generate the Final Document
Now, back to the table connected with Documint, you will need to create an attachment field. This field will store the PDF generated from each record.

Switch back to Documint and manage your fields. Just sync the connection to load the new field added.

Now, under Sources, click Add Formula in the Airtable connection. Then select the Generation Link option.
Select the Attachment field that will store the generated PDF.
Then click Generate Link and a URL will be available for you to copy. Copy it and switch back to Airtable.

In the table we have the attachment field, create a Button field. This button will store the URL to generate the PDF from each record in that table.

Click the button to test it out!
Generating Invoices with HubSpot
Connect your Documint account with HubSpot
Go to HubSpot's marketplace and look for Documint. Install it, grant the required permissions, and connect app.

Now, you'll need to create an API key. Log in to Documint and go to Settings > API keys. Click New API Key to create a new one and name it HubSpot. The key will show up, and you can copy it.

Back to HubSpot, you will access the Connected Apps. Access Documint and go to Settings. In the Authentication section, click Add/Edit API Key. Paste the API key you just copied and save it.

Map HubSpot Fields
Once the template has been added to your gallery and the Field schema is cleared, launch Documint from a record in one of your standard objects. In this example, we'll use a Deal object.
After selecting a record, you'll see the Documint banner in the right-hand panel.

Launch Documint from the selected record, then select the template you want to use and open its Properties.

In the Properties panel, you'll see the object's primary fields as well as any lists associated with the object.
To make the setup easier, download the complete Field schema. This downloads a JSON file containing the fields available for the object, including fields from associated lists.

Return to your Documint template and set up the Custom Data Source. Upload the JSON file you downloaded in the previous step.
Once the file is uploaded, Documint will automatically map the fields defined in the schema, including fields from associated lists.
Save your changes. The fields from the schema will now appear in the Fields panel, ready to be added to your template.

Format the Fields
Once your fields have been added to the canvas, you may need to adjust how some values are displayed. You can easily customize a field's formatting directly from its token settings. Double-click the token on the canvas to open its formatting options.
Number
For numerical fields, you can choose how the value should be displayed, such as currency or percentage. For currency values, you can specify the currency you want to use and the number of decimal places to display.

Date
You can customize how date values are displayed in your document. Choose from the available standard date formats, or enter a custom format to match your requirements.

Rich Text
If your data source contains rich text, you can preserve its formatting when displaying it in your document. To do this, open the token settings and set the Text Type to Markdown. This allows the rich text content to be rendered with its original formatting.

Displaying Line Items
Line Items is an associated list. In the Field schema, you'll see that Line Items is defined as a Collection. Collections allow you to create dynamic templates that can display a variable number of items.
You can repeat an element in your template for each item in the collection. This is especially useful for invoices, where the number of line items can vary from one record to another.
In the Invoice template, we'll use the line_items collection to create a dynamic table. When the document is generated, the table will automatically display all the items included in the Line Items list for the selected record.
Just select the element you want to be repeated for each item (in this case, it will be the row). Click Edit Logic in its properties panel.
In the popup, go to the Repeat/Loop tab and select the list field. Don't forget to save.

And that's it! Now a row will be repeated for each item in that list, and the template will display the table dynamically 🎉
Preview the Template with Real Data
Once your template is ready, return to HubSpot and launch Documint from a record.
Select the Invoice template you've been working on. The Preview tab will open and display the template using real data from the selected record.

Review the preview carefully to make sure all fields and dynamic content are displaying as expected. If anything needs adjustment, return to the template editor, make the necessary changes, and preview the document again.
Generate the Final Document
Once your template is active, return to HubSpot and click Generate.
Documint will generate the final PDF using the data from the selected record. The generated document will be added to the record's Notes and will also be available in its Attachments.

And that's it! Get ready to save countless hours spent manually editing documents with variable information 🎉
Generating Invoices with Make.com
Get an Invoice Template
Select one of the Invoice templates from our gallery and check whether the available fields meet your needs.

If you need to add additional fields, access the schema by clicking Manage fields in the Fields panel. In the Field Editor, click Add field and enter a name for each field. Then, select the appropriate field type.
Once you've added all the fields you need, save the schema and place the new fields on your template.

When everything is set up, return to Make.com to continue configuring your scenario.
Add Documint's Module (action)
Add a new module to your scenario, search for Documint, and select the Create a document action.
You'll first need to connect your Documint account to Make.com. In the Connection section, click Add.

To create the connection:
In Documint, go to Settings > API Keys.
Click
New API keyand give it a name, such as Make.com.Copy the generated API key.

Return to Make.com and paste the API key into the connection settings.
Save the connection.

Once the connection is saved, your Documint account will be synced with Make.com. The Invoice template you prepared will then be available to select from the template dropdown.

Map Source Fields to Template Fields
Once you select your template, its fields will appear, ready to be mapped to your source data.
For each template field, select the corresponding source field by clicking the name that matches the field. Repeat this process for each field until all the template fields are mapped to the appropriate data.

Don't forget to save once all the fields are mapped.
Generating Invoices with Zapier
Get an Invoice Template
Select one of the Invoice templates from our gallery and check whether the available fields meet your needs.
If you need to add additional fields, access the schema by clicking Manage fields in the Fields panel. In the Field Editor, click Add field and enter a name for each field. Then, select the appropriate field type.
Once you've added all the fields you need, save the schema and place the new fields on your template.
When everything is set up, return to Zapier to continue configuring your Zap.
Add Documint's Step
Add a step and look for Documint. In the Setup, select the Create Document as the Action event. And then, connect your account. For that, you'll need an API key. To get an API key, let's go back to Documint.
To create the connection:
In Documint, go to Settings > API Keys.
Click
New API keyand give it a name, such as Zapier.Copy the generated API key.
Return to Zapier and paste the API key into the connection settings.
Save the connection.
Once the connection is saved, your Documint account will be synced with Zapier. Click Continue to the Configure step. The Invoice template you prepared will then be available to select from the template dropdown.
Map Source Fields to Template Fields
Once you select your template, click the Template Fields dropdown and the fields will appear, ready to be mapped to your source data.
For each template field, select the corresponding source field by clicking the name that matches the field. Repeat this process for each field until all the template fields are mapped to the appropriate data.
Continue once all the fields are mapped and test the Documint step.
Last updated
Was this helpful?











