fill_form
Fill a PDF form with the given field values and save the result to disk.
WORKFLOW: 1) Call list_form_fields first to get exact field names and their x/y positions.
2) Use position coordinates to confirm which field is which — higher y = higher on page.
3) Pass exact field names from list_form_fields here. Never guess field names.
Use for single-page or short forms (under 5 pages). Use fill_form_multipage for longer forms.
Returns ok:false with unknown_fields if ALL provided field names are invalid.
Returns ok:true with a warnings.unknown_fields list if SOME names are invalid (partial fill).Tool call template
Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {
"pdf_path": "<pdf_path>",
"field_values": "<field_values>",
"output_path": "<output_path>"
},
"name": "fill_form"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| api_key | No | Your FormFill API key (get one at formfill.plenitudo.ai). | |
| pdf_path | Yes | Absolute path to the source PDF file. | |
| output_path | Yes | Absolute path where the filled PDF will be saved. | |
| field_values | Yes | Map of field names to values. Use list_form_fields to discover field names. | |
| payment_proof | No | x402 payment proof (tx hash). Alternative to api_key for pay-per-use. |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| result | Yes |