# Word Document (DOCX) & PowerPoint (PPTX)

## Getting Started

You can use Word Documents or PowerPoint ( **.docx, .pptx** is the supported format ) as your document template, you can build your document in Ms Word, Google Docs or Zoho Writer and then upload it to Docupilot as a .docx or .pptx file. If you are already using a word document for your business, replace the information that will change like client company name, client name to {{client.name}}, {{client.company}}.

![Word (.docx) template overview](https://191679573-files.gitbook.io/~/files/v0/b/gitbook-legacy-files/o/assets%2F-LDwD-wIOendMUiQ8uVr%2F-LMwHpCGdcPEUiWZ-Ll1%2F-LMwK4fecqRa4lgDmXDc%2Fimage.png?alt=media\&token=3c2be81c-2814-4cab-a65f-8a8d1676b1bc)

### Uploading DOCX

![](https://191679573-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F-LDwD-wIOendMUiQ8uVr%2Fuploads%2FnShBlz0k9O7Qb2OzISEu%2Fnew%20docx1.gif?alt=media\&token=10a33fd9-516e-454f-9008-e577e97c7980)

### Updating DOCX

You can update your Word Document templates in any of the following ways:

**Option 1: Using the Microsoft Word Add-In**\
With the Microsoft Word Add-In, you can upload your templates directly from Microsoft Word to Docupilot. For installation and usage refer to our [Word Add-In Guide](https://help.docupilot.app/integrations/microsoft-word-add-in#installing-the-docupilot-word-add-in-beta).

**Option 2: Manual Update**\
Alternatively, you can edit your template in any document editor (like Microsoft Word, Google Docs, or Zoho Writer), save it as a .docx file, and upload it manually to Docupilot.

![](https://191679573-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F-LDwD-wIOendMUiQ8uVr%2Fuploads%2FkvPbYeNT5iPIzecRN2Y8%2Fnew%20docx2.gif?alt=media\&token=0284149e-c2de-4286-bdfb-9742321c7dfd)

{% hint style="warning" %}
You cannot modify your Word Document template inside Docupilot.
{% endhint %}

## Types of Merge Fields <a href="#types-of-merge-fields" id="types-of-merge-fields"></a>

Docupilot supports a variety of merge fields for you to use.

* Tokens (Merge Field)
* Conditions (`if-else`)
* Loops
* Tables

### Tokens (Merge Field) <a href="#tokens-merge-field" id="tokens-merge-field"></a>

Tokens are placeholders that Docupilot replaces with your data when generating documents.

Tokens are placeholders enclosed within double curly brackets `{{ }}` that Docupilot replaces with your custom data when generating documents.

**Basic Tokens**

Each token corresponds to a specific data field. For example:

* `{{email}}` → Replaced with the email address.
* `{{clientName}}` → Replaced with the client’s name.
* `{{company_name}}` → Replaced with the company name.

**Nested Tokens (to handle grouped data)**

You can structure data hierarchically using dot notation. This is useful when working with related fields within an entity. For example:

* `{{client.first_name}}` → Replaced with the client’s first name.
* `{{client.last_name}}` → Replaced with the client’s last name.

### Condition (`if-else`)

You can use conditional statements to show or hide contents based on your data. For example, If you are creating an invoice, you want to display CASH if the payment\_mode is cash, else if the payment\_mode is the card you want to show CARD.

```
{{#if (payment_mode == "cash")}}
CASH
{{else if (payment_mode == "card")}}
CARD
{{else}}
Please Insert preferred Mode of Payment{{/if}}
```

To use conditional statement for checking inverse or negation of a condition, use the **not** in the condition. For example, to add an instruction requesting to add secure link if payment mode is not available on record:

```
{{#if (not payment_mode)}}
Please Add your payment details in this secure link: <your secure payment link>
{{/if}}
```

You can use the conditional statements in three ways

* `if`&#x20;
* `if-else`&#x20;
* `if-else if`&#x20;
* `if-else if-else`
* `if-else if-else if`
* `if-else if-else if-else`
* and so on&#x20;

Below are a few examples:

| <p><code>{{#if show\_payment\_details}}</code></p><p><code>ACH to {{acNumber}}</code></p><p><code>{{/if}}</code></p>                                                                                                                                                   | prints the text `ACH to xxxxxxxxx` if `show_payment_details` is present and not `false`.                                                                                                                                                                 |
| ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| <p><code>{{#if (payment\_status == "paid")}}</code></p><p><code>payment cleared</code></p><p><code>{{/if}}</code></p>                                                                                                                                                  | prints `payment cleared` if `payment_status` equals to `"paid"` (case-sensitive)                                                                                                                                                                         |
| <p><code>{{#if (payment\_status != "paid")}}</code></p><p><code>unpaid</code></p><p> <code>{{/if}}</code></p>                                                                                                                                                          | prints `unpaid` if `payment_status` not equal to `"paid"` (case-sensitive)                                                                                                                                                                               |
| <p><code>{{#if (payment\_status == "paid")}}</code></p><p><code>paid</code></p><p><code>{{else}}</code></p><p><code>unpaid</code></p><p><code>{{/if}}</code></p>                                                                                                       | prints `paid` if `payment_status` equals to `"paid"` otherwise prints `unpaid`                                                                                                                                                                           |
| <p><code>{{#if (payment\_status == "paid")}}</code></p><p><code>paid</code></p><p><code>{{else if (payment\_status == "initiated")}}</code></p><p><code>payment initiated</code></p><p><code>{{else}}</code></p><p><code>pending</code></p><p><code>{{/if}}</code></p> | <p>prints <code>paid</code> if <code>payment\_status</code> equals to <code>"paid"</code> </p><p>prints <code>payment initiated</code> if <code>payment\_status</code> equals to <code>initiated</code> </p><p>otherwise prints <code>pending</code></p> |
| <p><code>{{#if (price > 1000)}}</code></p><p><code>good deal</code></p><p><code>{{/if}}</code></p>                                                                                                                                                                     | prints the text `good deal` if price is greater than 1000                                                                                                                                                                                                |
| <p><code>{{#if (price >= 1000)}}</code></p><p><code>decent deal</code></p><p><code>{{/if}}</code></p>                                                                                                                                                                  | prints text `decent deal` if price is greater than or equal to 1000                                                                                                                                                                                      |
| <p><code>{{#if (price < 1000)}}</code></p><p><code>small deal</code></p><p><code>{{/if}}</code></p>                                                                                                                                                                    | prints text `small deal` If price less than 1000                                                                                                                                                                                                         |
| <p><code>{{#if (price <= 1000)}}</code></p><p><code>okay-ish deal</code></p><p><code>{{/if}}</code></p>                                                                                                                                                                | prints text `okay-ish deal` If price less than or equal to 1000                                                                                                                                                                                          |
| <p><code>{{#if (payment\_message contains "paid")}}</code></p><p><code>Payment is cleared</code><br><code>{{/if}}</code></p>                                                                                                                                           | prints `Payment is cleared` if `payment_message` contains the text `paid` *(for example, `this invoice has been paid` contains the text `paid` in it)*                                                                                                   |
| <p><code>{{#if (payment\_message not\_contains "paid")}}</code></p><p><code>Payment is due</code><br><code>{{/if}}</code></p>                                                                                                                                          | prints `Payment is due` if `payment_message` does not contain the text `paid` *(for example, `this invoice is not cleared` does not contain the text `paid` in it)*                                                                                      |
| <p><code>{{#if (status == "open" or status == "on-hold")}}</code></p><p><code>Payment is pending</code></p><p><code>{{/if}}</code></p>                                                                                                                                 | prints `Payment is pending` if `status` is `open` OR `on-hold`                                                                                                                                                                                           |
| <p><code>{{#if (status == "open" or status == "on-hold" or status == "under review")}}</code></p><p><code>Payment is pending</code></p><p><code>{{/if}}</code></p>                                                                                                     | prints `Payment is pending` if `status` is `open` OR `on-hold` OR `under review`                                                                                                                                                                         |
| <p><code>{{#if (status != "open" and status != "on-hold")}}</code></p><p><code>Payment is not pending</code></p><p><code>{{/if}}</code></p>                                                                                                                            | prints `Payment is not pending` if `status` is not `open` AND not `on-hold`                                                                                                                                                                              |
| <p><code>{{#if (status == "open" and priority == "high")}}</code></p><p><code>High priority open task</code></p><p><code>{{/if}}</code></p>                                                                                                                            | prints `High priority open task` if `status` is `open` AND if `priority` is `high`                                                                                                                                                                       |
| <p><code>{{#if (payment\_status != "paid")}}Please Clear the Dues within 30 days</code> </p><p><code>{{/if}}</code></p>                                                                                                                                                | prints `Please Clear the Dues within 30 days` if the `payment_status` is not equal to `paid`                                                                                                                                                             |
| <p><code>{{#if (status in "open,pending")}}In Progress... Please stay tuned for further updates.</code></p><p><code>{{/if}}</code></p>                                                                                                                                 | prints `In Progress... Please stay tuned for further updates.` if `status` is sub-string of `"open,pending"`                                                                                                                                             |

#### Hiding Empty Sections & Lines

In the following example, when the `address` field has a value, it gives desired outcome. If the address is empty, it leaves an empty line in the output.

```
{{customer_name}},
{{#if address}}{{address}},{{/if}}
{{city}}, {{country}}
```

<table><thead><tr><th>Data</th><th>Output</th></tr></thead><tbody><tr><td><pre><code>customer_name = John Doe
city = NY
country = US
</code></pre></td><td><pre><code>John Doe,

NY, US </code></pre></td></tr><tr><td><pre><code>customer\_name = John Doe
street = WinWood St.
city = NY
country = US </code></pre></td><td><pre><code>John Doe,
WinWood St.,
NY, US </code></pre></td></tr></tbody></table>

To hide empty lines, we should open the `if` condition in previous line or close it in next line. Here are examples on how the output will look like when street address is passed and when it is not:

<table><thead><tr><th>Syntax</th><th>Data</th><th>Output</th></tr></thead><tbody><tr><td><pre><code>{{customer_name}},{{#if street}}
{{street}},{{/if}}
{{city}}, {{country}}
</code></pre></td><td><pre><code>customer_name = John Doe
city = NY
country = US
</code></pre></td><td><pre><code>John Doe,
NY, US
</code></pre></td></tr><tr><td><pre><code>{{customer_name}},{{#if street}}
{{street}},{{/if}}
{{city}}, {{country}}
</code></pre></td><td><pre><code>customer_name = John Doe
street = WinWood St.
city = NY
country = US
</code></pre></td><td><pre><code>John Doe,
WinWood St.,
NY, US
</code></pre></td></tr><tr><td><pre><code>{{customer_name}},
{{#if street}}{{street}},
{{/if}}{{city}}, {{country}}
</code></pre></td><td><pre><code>customer_name = John Doe
city = NY
country = US
</code></pre></td><td><pre><code>John Doe,
NY, US
</code></pre></td></tr><tr><td><pre><code>{{customer_name}},
{{#if street}}{{street}},
{{/if}}{{city}}, {{country}}
</code></pre></td><td><pre><code>customer_name = John Doe
street = WinWood St.
city = NY
country = US
</code></pre></td><td><pre><code>John Doe,
WinWood St.,
NY, US
</code></pre></td></tr></tbody></table>

{% hint style="warning" %}

#### Avoid Placing {{/if}} and Section Break on the Same Line

If you are using section breaks in your Word template, avoid placing `{{#if ...}}` or `{{/if}}` and the section break on the same line. Doing so may cause headers or footers from the next section to appear in the previous section.

**Why this happens:**

Based on how the if condition is evaluated, it may remove the section break altogether thereby applying the same headers/footers/styles to both the sections.

**How to avoid this from happening:**

* Do not place the opening or closing `if` and the section break on the same line.
* Instead, add the section break on a new line before or after the `if` block like in the examples below:

*Adding if condition after the section break*

```
<insert section break here>
{{#if condition}}
...content...
{{/if}}
```

-or-

*Adding if condition before the section break*

```
{{#if condition}}
...content...
{{/if}}
<insert section break here>
```

{% endhint %}

### Lists (Loops) <a href="#loops-list" id="loops-list"></a>

Lists are used when you want to print a list of items in your document.

* Simple List
* Advanced List
* Bulleted List
* Numbered List

#### Simple List <a href="#simple-loop-list" id="simple-loop-list"></a>

```
{{#each items}}
{{this}}
{{/each}}
```

{% code title="Output" %}

```
Apple
Orange
Strawberry
```

{% endcode %}

#### Advanced List <a href="#complex-loop-list" id="complex-loop-list"></a>

You can use an advanced loop if you want to print list of items like line items. Think of this as a subform with multiple rows in your main form.

```
{{#each line_items}}
{{name}} ${{price}}
{{/each}}
```

{% code title="Output" %}

```
Iphone6 $799
Iphone7 $899
Iphone8 $999
```

{% endcode %}

### Bulleted List

![Bulleted List](https://191679573-files.gitbook.io/~/files/v0/b/gitbook-legacy-files/o/assets%2F-LDwD-wIOendMUiQ8uVr%2F-Lfyx9IPqwBQkRXRcGDn%2F-LfyxD-XDVHpdmRw6lVq%2Fbullet.JPG?alt=media\&token=9e4a3159-6533-4fe8-b57a-bf4c48ba75c8)

#### Nested Bullets:

Bulleted lists can be nested so as to have a multi layered information.

For example, below syntax demonstrates nested list up to 2 levels.

![Nested Bullet List 1](https://191679573-files.gitbook.io/~/files/v0/b/gitbook-legacy-files/o/assets%2F-LDwD-wIOendMUiQ8uVr%2F-MX6wMVQgpsY9Tjt-krH%2F-MX6wpiQ0ZPcaLGGl3nD%2FWordnested%201.jpg?alt=media\&token=632203fe-6ae7-44b1-b5d8-672411fec24c)

{% hint style="info" %}
Note : The second level will be printed only when `products` has at least one entry.
{% endhint %}

Similarly, for a nested list up to 3 levels.

![Nested Bullet List 2](https://191679573-files.gitbook.io/~/files/v0/b/gitbook-legacy-files/o/assets%2F-LDwD-wIOendMUiQ8uVr%2F-MX6wMVQgpsY9Tjt-krH%2F-MX6xLjFLSf9DRct_ORA%2Fwordnested%202.jpg?alt=media\&token=c5d69c64-a620-4efc-8f1b-0fed94aabebe)

{% hint style="info" %}
Note : In the above example second and third levels will be printed only when `items` and `sub_categories` have at least one entry.
{% endhint %}

{% hint style="info" %}
Note : The above syntax can be extended for multiple levels based on requirement.
{% endhint %}

### Numbered List

![Numbered List](https://191679573-files.gitbook.io/~/files/v0/b/gitbook-legacy-files/o/assets%2F-LDwD-wIOendMUiQ8uVr%2F-Lfyx9IPqwBQkRXRcGDn%2F-LfyxI4N9uO64-R32NFU%2Fnumber.JPG?alt=media\&token=58cbe80c-e2e9-45da-ad5c-a1961196ff3c)

### Tables <a href="#tables" id="tables"></a>

Tables are similar to Complex list, but the data will be rendered in a table. Example if you want to generate a invoice, you may want display a table with all the line items.

![Tables Syntax](https://191679573-files.gitbook.io/~/files/v0/b/gitbook-legacy-files/o/assets%2F-LDwD-wIOendMUiQ8uVr%2F-LMwR6QYoV4KVTcn2yeN%2F-LMwUlijwo0K6BPkDDid%2Ftables.JPG?alt=media\&token=35847355-0237-4875-8ec1-d743baa36b50)

#### Hiding Empty Tables <a href="#hiding-empty-tables" id="hiding-empty-tables"></a>

You can use IF condition to hide empty tables, you should wrap the entire table inside a IF condition.

```
{{#if line_items}}
{{!...INSERT THE ABOVE TABLE IN THIS LINE...}}
{{/if}}
```

#### Filtering rows in a Table based on empty column value

![If the value for name is empty in any row, it will be skipped in the output table.](https://191679573-files.gitbook.io/~/files/v0/b/gitbook-legacy-files/o/assets%2F-LDwD-wIOendMUiQ8uVr%2F-Lfyx9IPqwBQkRXRcGDn%2F-LfyxmsAz8ZpgBermb66%2F1.JPG?alt=media\&token=c31ddd02-55ac-484b-9949-ed4b8323edc5)

#### Filtering rows in a Table based on a column value

![If the value for name is Iphone in any row, it will be skipped in the output table.](https://191679573-files.gitbook.io/~/files/v0/b/gitbook-legacy-files/o/assets%2F-LDwD-wIOendMUiQ8uVr%2F-Lfyx9IPqwBQkRXRcGDn%2F-LfyxvtCYMeY9kPoN4LH%2F2.JPG?alt=media\&token=89e2b81b-cf8f-4ed2-9694-3a098257cb80)

## Inserting a dynamic image

This will be helpful if you want to insert dynamic image in the document.

Format - **{{insert\_image image1 width="width" height="height"}}**

Example - **{{insert\_image image1 width="300" height="300"}}**

If you want to automatically adjust the height to keep proportions, you can use:

Example - **{{insert\_image image1 width="300"}}**

Similarly to automatically adjust the width to keep proportions, you can use:&#x20;

Example - **{{insert\_image image1 height="300"}}**

{% hint style="info" %}
&#x20;The image URL need to be publicly accessible so we can download and insert it in the document.
{% endhint %}

## Inserting Dynamic Links

You can insert **dynamic hyperlinks** into images and text within your templates. These links change based on the data you pass when generating a document.

### Adding hyperlink to an image:

1. Right-click the image
2. Select **Link**
3. in the **Address** field, enter: `docupilot:my_link`&#x20;

<figure><img src="https://191679573-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F-LDwD-wIOendMUiQ8uVr%2Fuploads%2FfYNM7Lz3OZRbpTnQh8DB%2FSyntax%20for%20Clickable%20Image.png?alt=media&#x26;token=367c9860-16a1-4791-bb4c-e05015b1bdc7" alt="Dynamic hyperlink for images"><figcaption><p>Dynamic hyperlink for images in Word and Powerpoint</p></figcaption></figure>

### Adding hyperlink to text:

1. Highlight the text you want to link
2. Right-click and select **Link**
3. In the **Address** field, enter: `docupilot:my_link`

<figure><img src="https://191679573-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F-LDwD-wIOendMUiQ8uVr%2Fuploads%2FK0Yyi9VCvyilzr2dO4gH%2FSyntax%20for%20Cliclable%20Text.png?alt=media&#x26;token=5b274063-8351-4eeb-ae64-51471dfd94e1" alt="Dynamic hyperlink for text in Word and Powerpoint"><figcaption><p>Dynamic hyperlink for text in Word and Powerpoint</p></figcaption></figure>

#### How It Works

* `my_link` is a dynamic token.
* During document generation, Docupilot will replace it with the actual URL you provide in your data.
* Clicking the image or text in the generated document will open the corresponding URL.

{% hint style="info" %}
Tip: You can use multiple dynamic links in a template by giving each one a unique token (e.g., `docupilot:link1`, `docupilot:link2`)
{% endhint %}

## Inserting a dynamic QR Code <a href="#inserting-qr-code" id="inserting-qr-code"></a>

This will be helpful if you want to insert dynamic QR code from your data in the document.

Format - **{{insert\_qr url size="qr\_size" margin="qr\_margin" color="color\_code(in hex values)" bg\_color="color\_code(in hex values)" branding\_url="image\_url" branding\_ratio="ratio\_value(between 1 to 10)"}}**&#x200C;

| Order | Name            | Description                                                                                                               | Mandatory                     |
| ----- | --------------- | ------------------------------------------------------------------------------------------------------------------------- | ----------------------------- |
| 1     | size            | QR Size                                                                                                                   | <p>No<br>Default: 100</p>     |
| 2     | margin          | QR Image height (px)                                                                                                      | <p>No</p><p>Default: 4</p>    |
| 3     | color           | Color of QR core                                                                                                          | <p>No<br>Default: #000000</p> |
| 4     | bg\_color       | Background Color for QR                                                                                                   | <p>No<br>Default: #FFFFFF</p> |
| 5     | branding\_url   | Inserts an image in QR for branding                                                                                       | No                            |
| 6     | branding\_ratio | Set the size of the QR code’s branding image on a scale from 1 to 10, where 10 is the smallest size and 1 is the largest. | <p>No<br>Default: 4</p>       |

Example - `{{insert_qr url size="100"}}`

<div align="center" data-full-width="true"><img src="https://191679573-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F-LDwD-wIOendMUiQ8uVr%2Fuploads%2FptM44aTB2clhjq39Ro16%2F100%20QR%20Final.png?alt=media&#x26;token=194ab445-a9b8-42e7-b30e-6ff001b79d2f" alt="Qr with size 100 and default margin 4 with value https://docupilot.com/"></div>

Example - `{{insert_qr url size="100" margin="3" bg_color="#3399FF"}}`

<div align="center"><img src="https://191679573-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F-LDwD-wIOendMUiQ8uVr%2Fuploads%2FtnzaKhyxR2PFQbdNtXl0%2FMargin%20Final.png?alt=media&#x26;token=f1d240c4-206f-460a-9677-1150ae209f5b" alt="Qr with size 100 and margin 3 with value https://docupilot.com"></div>

Example: `{{insert_qr url margin="7" color="#FFFFFF" bg_color="#000000"}}`

<div align="center"><figure><img src="https://191679573-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F-LDwD-wIOendMUiQ8uVr%2Fuploads%2FriWAi4fihw9X9apoz3kn%2FScreenshot%202025-08-05%20at%207.15.05%E2%80%AFPM.png?alt=media&#x26;token=51dab0b3-9b52-4642-8fd2-103c1907c42f" alt=""><figcaption><p>Qr with margin 7, white color and black background</p></figcaption></figure></div>

Example: `{{insert_qr url color="0000FF"}}`

<figure><img src="https://191679573-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F-LDwD-wIOendMUiQ8uVr%2Fuploads%2FiqzYpykTOAi7hzs52dwg%2FBlue%20QR%20final.png?alt=media&#x26;token=10f0dcbc-464a-4a49-b17b-c86f7c4be694" alt=""><figcaption><p>QR with color blue &#x26; value <a href="https://docupilot.app/">https://docupilot.com/</a></p></figcaption></figure>

Example: `{{insert_qr url margin="1" color="#FFFFFF" bg_color="#000000"}}`

<figure><img src="https://191679573-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F-LDwD-wIOendMUiQ8uVr%2Fuploads%2FDxFpNGlO95dlEZ0QXTuN%2FFinal%20Margin%20QR.png?alt=media&#x26;token=bdff6091-61fc-4442-adf1-92e8420dccd4" alt=""><figcaption><p>QR with white color and black background</p></figcaption></figure>

{% hint style="info" %}
The color of the QR should be given in hex coding only.
{% endhint %}

Example: `{{insert_qr url margin="1" color="#FFFFFF" bg_color="#000000" branding_url=image_url branding_ratio="4"}}`

<figure><img src="https://191679573-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F-LDwD-wIOendMUiQ8uVr%2Fuploads%2Fif0EsJe1ODtgfXaaxGOz%2FQR%20code%20with%20logo.png?alt=media&#x26;token=b52117e0-fa8d-404f-957e-aa9a8433fc32" alt="" width="226"><figcaption><p>QR code with branding image</p></figcaption></figure>

{% hint style="info" %}
The image URL need to be publicly accessible so we can download and insert it in the document.
{% endhint %}

#### Inserting a Barcode with a Transparent Background

This is useful if you need to insert a barcode with a transparent background into your document.

Example: `{{insert_qr url color="#FFFFFF" bg_color=”ffffff00”}}`

<figure><img src="https://191679573-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F-LDwD-wIOendMUiQ8uVr%2Fuploads%2Fp9akylKv7OYldtdCkGgv%2FTransparent%20Background.png?alt=media&#x26;token=4ebdf224-7507-4f7a-b729-565fb59b0409" alt="" width="312"><figcaption><p>QR code with transparent background</p></figcaption></figure>

## Inserting Google Maps <a href="#inserting-google-maps" id="inserting-google-maps"></a>

This will be helpful if you want to insert Google Maps from your data in the document.‌

Format - **{{insert\_map Location width="map\_width" height="map\_height" map\_type="maptype" zoom="map\_zoom"}}**&#x200C;

The supported map types are as follows. The default map type is the roadmap.‌

1. roadmap
2. satellite
3. hybrid
4. terrain

Example - **{{insert\_map Location width="500" height="500" map\_type="roadmap"}}**

![Location Value is Manchester](https://blobscdn.gitbook.com/v0/b/gitbook-28427.appspot.com/o/assets%2F-LDwD-wIOendMUiQ8uVr%2F-LjqKFkGneund1-S_wz0%2F-LjqNJ8CNhiKfWOErv08%2Fstaticmap.png?alt=media\&token=18e9b585-fae8-4902-bec9-5306e424fd69)

Example: **{{insert\_map Location  map\_type="roadmap" zoom= "20"}}**

<figure><img src="https://191679573-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F-LDwD-wIOendMUiQ8uVr%2Fuploads%2FKoqBIyQFPMXJNLQMepw7%2Fmaps%20new.jpg?alt=media&#x26;token=5e7c1dee-eda9-4c94-891c-9cd970cca85e" alt=""><figcaption><p><strong>Location value is Manchester, with map type as road map and a Zoom set to 20</strong></p></figcaption></figure>

Example: **{{insert\_map Location height="300" zoom= "5"}}**

<figure><img src="https://191679573-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F-LDwD-wIOendMUiQ8uVr%2Fuploads%2F2FZvABkrPNXmFWOXpxEM%2Fmaps%20new.jpg?alt=media&#x26;token=432040a3-8481-4b28-b3c3-131d9dfb95f1" alt=""><figcaption><p><strong>Location value is Manchester with height as 300 px and zoom set to 5</strong></p></figcaption></figure>

## Grid Helper

The Grid Helper will render the list input in a grid format, with specified column size.

Syntax: `{{#grid items col_size=3}}`\
`{{@item1}}{{@item2}{{@item3}}`\
`{{/grid}}`

&#x20;Example:

<figure><img src="https://191679573-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F-LDwD-wIOendMUiQ8uVr%2Fuploads%2Fr4ShV77HNyOKEpFxWx6N%2FGrid%20DOCX%20helper.png?alt=media&#x26;token=40acb0fc-86cd-4f03-ad5b-f30013f64223" alt=""><figcaption><p>Grid helper</p></figcaption></figure>

{% hint style="info" %}
If the number of columns ( i.e.,`col_size`) is 5, then **{{@item4}}** and **{{@item5}}** can be used to access entries 4th and 5th column items in each row.
{% endhint %}

## Rich Text Helper

The rich text helper enables content formatting in various ways, including bold, italic, underlined text, different fonts, sizes, colors, and more, surpassing plain text capabilities.It supports both HTML and Markdown format input to richtext.

Syntax : `{{richtext content}}`

Example:

<div><figure><img src="https://191679573-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F-LDwD-wIOendMUiQ8uVr%2Fuploads%2FcVE9RLEoBS19TS6SviwZ%2FRIchText%20new%20Airtableinput.png?alt=media&#x26;token=5681e071-ef6b-42b9-8a4d-75874e1df3bc" alt=""><figcaption><p>Example Rich Input from Airtable demonstrating Bold text, Headings and List items.</p></figcaption></figure> <figure><img src="https://191679573-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F-LDwD-wIOendMUiQ8uVr%2Fuploads%2FwZwHfhr5c1Bb1Z6Sdw4Z%2FScreenshot%202024-05-14%20at%204.32.05%E2%80%AFPM.png?alt=media&#x26;token=57bd9f66-7c1f-40ce-8426-d700be41ef33" alt=""><figcaption><p>Document Generated retaining the same input structure while matching the style with the document template.</p></figcaption></figure></div>

## Repeat Slides

The Repeat Slides functionality allows you to repeat one or more slides within your presentation dynamically based on a list data. Place the repeat slide syntax anywhere within a dedicated text box on a slide.

Syntax:

`{{repeat_slides items count=3}}`&#x20;

where `items` is the token referring to list data, `count` defines the number of slides to be repeated. For example, when `count` is set to `3`, 3 slides including the current one are repeated for each item in `items`.

Examples:

Simple product catalog: Consider the case where you want to repeat a slide for each product in your catalog, and you need to add 1 product into each slide separately, use the syntax `{{repeat_slides products}}` and add the placeholders like `{{product_name}}`, `{{specifications}}`, etc into the same slide. The generated document will contain appropriate resulting items.

Detailed product catalog: Consider similar case as above, but you want to add the each of the product details in 3 slides. Say, first slide of each product contains basic information, next slide contains specifications and the 3rd slide related to that product contains pricing and warranty information. Use the syntax `{{repeat_slides products count=3}}` and add placeholders for basic information `{{product_name}}`, etc., in first slide, `{{material_used}}`, `{{dimensions}}`, etc., in second slide and `{{price}}`, or a pricing table, and `{{warranty_information}}`, etc in third slide. For each product passed, the generated document will have 3 slides.

<div><figure><img src="https://191679573-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F-LDwD-wIOendMUiQ8uVr%2Fuploads%2FdBZ36Ufh8JUVDAfPZRZd%2FRepeat%20slide%20new%20input.gif?alt=media&#x26;token=2522aaab-a81d-452d-a6aa-664fe365446c" alt="" width="563"><figcaption><p>Repeat Slides - Input</p></figcaption></figure> <figure><img src="https://191679573-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F-LDwD-wIOendMUiQ8uVr%2Fuploads%2F1a3tRcMCt0x3QPwFYThz%2Frepeat%20output.gif?alt=media&#x26;token=247ed99c-35c5-4d23-b21f-aacbf007ca70" alt="" width="563"><figcaption><p>Repeat Slides - Output</p></figcaption></figure></div>

## Embedding Fonts in a DOCX Template

To ensure a document retains a specific font that is not supported on our end, you must embed the fonts within the document. This will make sure that the generated document maintains the same font as the original.

**Here's how to embed fonts in your DOCX template:**

1. **Open Your DOCX Template:** Begin by opening your template using Microsoft Office.                               &#x20;
2. **Enable Font Embedding:** &#x20;

   * For Mac Users: Navigate to Preferences -> Save -> "Embed fonts in the file."
   * For Windows Users: Go to Options -> Save ->"Embed fonts in the file".

   If you're having trouble locating these settings within Microsoft Office, refer to this [article](https://www.support.microsoft.com/en-us/office/benefits-of-embedding-custom-fonts-cb3982aa-ea76-4323-b008-86670f222dbc) for guidance.
3. **Save and Upload:** Finally, save your document with the embedded fonts and upload the updated document to Docupilot.

<figure><img src="https://191679573-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F-LDwD-wIOendMUiQ8uVr%2Fuploads%2FGiLVAGuYuDoA0eCNPpkJ%2FEmbedding%20fonts%20-%20Mac.gif?alt=media&#x26;token=3e3055b0-7ead-4b01-8eb6-26264152667e" alt=""><figcaption><p>Mac Users-Embedding Font in a DOCX Template </p></figcaption></figure>

<figure><img src="https://191679573-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F-LDwD-wIOendMUiQ8uVr%2Fuploads%2FEwKi70JvYXUstCjrUJzP%2FEmbedding%20fonts%20-%20windows.gif?alt=media&#x26;token=d92c8ef8-b999-442b-b117-8846409d7c65" alt=""><figcaption><p>Windows Users-Embedding Font in a DOCX Template </p></figcaption></figure>

## Comments

You can add comments in the document template to help your future editors. The comments will be removed in the output document.&#x20;

{% hint style="success" %}
Comments Syntax :  **{{!Your comments here}}**
{% endhint %}
