> For the complete documentation index, see [llms.txt](https://docs.zapsign.com.br/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.zapsign.com.br/zapsign-api/english/templates/create-template-docx/update-form.md).

# Configure Template Form

When creating a document from a template without pre-filling all dynamic fields, the signer will need to complete the required information to generate and sign the document. This endpoint configures the form to enhance the signer’s experience and minimize errors.

### **Configure Form**

<mark style="color:green;">**`POST`**</mark> `https://api.zapsign.com.br/api/v1/templates/update-form/`

#### Headers

<table><thead><tr><th width="198">Name</th><th width="163">Type</th><th>Description</th></tr></thead><tbody><tr><td>Authorization<mark style="color:red;">*</mark></td><td>string</td><td><p>apiToken ahead of the "Bearer" text. </p><p>Ex: Bearer c7f35c84-7893-4087-b4fb-d1f06c23</p></td></tr></tbody></table>

#### Request Body

| custom\_intro        | string         | Message with instructions for the signer (displayed at the beginning of the form). Default: `""`                                                           |
| -------------------- | -------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------- |
| youtube\_video\_code | string         | Adds a YouTube video at the start of the form. If the video URL is `https://www.youtube.com/watch?v=Fi0qJgEjYAw`, the code is `Fi0qJgEjYAw`. Default: `""` |
| inputs \[variable]   | array \<input> | Configuration of dynamic fields.                                                                                                                           |

### **Dynamic Field Configuration (inputs)**

Configures the form fields to assist the signer and prevent errors.

* **variable** (string, required): The name of the dynamic field inside the DOCX file. Example: {{name}}.
* **input\_type** (string, optional): Field type to validate the format. Default: "input".

<table><thead><tr><th width="198">input type</th><th>Description</th></tr></thead><tbody><tr><td>input</td><td>Short text.</td></tr><tr><td>email</td><td>Email address.</td></tr><tr><td>signer_fullname</td><td>Full name</td></tr><tr><td>radio</td><td>Multiple-choice option (requires "options" parameter).</td></tr><tr><td>dropdown-list</td><td>Dropdown list for the signer to select an option from the list. The "options" parameter must be used to define the options.</td></tr><tr><td>checklist</td><td>Checkbox (requires "options" parameter).</td></tr><tr><td>date</td><td>Date in dd/mm/yyyy format.</td></tr><tr><td>ext-date</td><td>Written signature date (automatically filled with the document's signing date).</td></tr><tr><td>date-signature</td><td>Signature date in dd/mm/yyyy format (automatically filled with the document's signing date).</td></tr></tbody></table>

* **label** (string, optional): Field title in the form. Example: Full Name. Default: Same as variable, without brackets {{}}.
* **help\_text** (string, optional): Help text displayed below the field title. Example: Maria Perez. Default: "".
* **options** (string, optional): Options for multiple-choice (radio) or checkbox (checklist) fields. Example: "Option A; Option B; Option C".
* **required** (boolean, optional): Defines whether the field is mandatory. Default: true.
* **order** (integer, optional): Order in which the field appears in the form.

### Request

```javascript
{
    "template_id":"780c299e-8f2b-421a-941e-d130577f4968",
    "custom_intro": "Fill in the information",
    "youtube_video_code": "",
    "inputs": [
        {
            "variable": "{{full name}}",
            "input_type": "signer_fullname",
            "label": "First and last name",
            "help_text": "John DOe",
            "options": "",
            "required": true,
            "order": 1
        },
        {
            "variable": "{{email}}",
            "input_type": "email",
            "label": "Email",
            "help_text": "email@email.com",
            "options": "",
            "required": true,
            "order": 2
        },
        {
            "variable": "{{date}}",
            "input_type": "date",
            "label": "Date",
            "help_text": "",
            "options": "",
            "required": false,
            "order": 3
        },
        {
            "variable": "{{city}}",
            "input_type": "radio",
            "label": "City",
            "help_text": "Select an option",
            "options": "Bogota;Medellin;Cali",
            "required": true,
            "order": 4
        }
    ]
}
```

### Response

```javascript
{
    "token": "780c299e-8f2b-421a-941e-d130577f4968",
    "template_type": "docx",
    "name": "Template name",
    "active": true,
    "template_file": "https://zapsign.s3.amazonaws.com/dev/2025/1/api/e99a404a-15cd-482d-a4ac-79391ff46de1.docx?AWSAccessKeyId=AKIASUFZJ7JCTI2ZRGWX&Signature=YpD8LWxhK74T3EnHzRPCh1lavQI%3D&Expires=1738257648",
    "created_at": "2025-01-30T16:16:06.456597Z",
    "last_update_at": "2025-01-30T16:20:48.351407Z",
    "redirect_link": "",
    "folder_path": "/",
    "lang": "en",
    "signers": [
        {
            "name": "First signer",
            "auth_mode": "assinaturaTela",
            "email": "",
            "phone_country": "1",
            "phone_number": "",
            "lock_name": true,
            "lock_phone": false,
            "lock_email": false,
            "hide_phone": false,
            "blank_phone": true,
            "hide_email": false,
            "blank_email": false,
            "require_selfie_photo": true,
            "require_document_photo": false,
            "selfie_validation_type": "none",
            "qualification": "Witness"
        }
    ],
    "inputs": [
        {
            "variable": "{{name}}",
            "input_type": "signer_fullname",
            "label": "First and last name",
            "help_text": "John Doe",
            "options": "",
            "required": true,
            "order": 1
        },
        {
            "variable": "{{email}}",
            "input_type": "email",
            "label": "Email",
            "help_text": "email@email.com",
            "options": "",
            "required": true,
            "order": 2
        },
        {
            "variable": "{{Phone}}",
            "input_type": "input",
            "label": "Phone",
            "help_text": "",
            "options": "",
            "required": true,
            "order": 3
        },
        {
            "variable": "{{Date}}",
            "input_type": "date",
            "label": "Date",
            "help_text": "",
            "options": "",
            "required": false,
            "order": 3
        },
        {
            "variable": "{{city}}",
            "input_type": "radio",
            "label": "City",
            "help_text": "Selecciona una opción",
            "options": "Bogota;Medellin;Cali",
            "required": true,
            "order": 4
        },
        {
            "variable": "{{signature date}}",
            "input_type": "input",
            "label": "Date",
            "help_text": "",
            "options": "",
            "required": true,
            "order": 8
        }
    ],
    "extra_templates": [],
    "notify_extra_emails": "email@email.com",
    "custom_intro": "Fill in the information",
    "youtube_video_code": ""
}
```


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation by asking a question.

Perform an HTTP GET request on the following URL with the `ask` and `goal` query parameters:

```
GET https://docs.zapsign.com.br/zapsign-api/english/templates/create-template-docx/update-form.md?ask=<question>&goal=<user_goal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is what the user is ultimately trying to achieve, the reason they need the answer. Sharing it helps GitBook give you a better, more relevant answer. A goal is most helpful when it describes the outcome the user wants rather than restating the question. For example, with `ask=how do I create an API token`, a goal like `automate deployments from our CI pipeline` lets GitBook tailor the answer to that use case.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
