pdf_create_from_template
Create a polished PDF by populating a named template (invoice, report, or letter) with structured data that is validated against the template's schema.
Instructions
Create a polished PDF from a named template (invoice, report, or letter). Pass structured data matching the template's fields; data is validated against the template's schema.
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": {
"templateName": "<templateName>",
"data": "<data>",
"outputPath": "<outputPath>"
},
"name": "pdf_create_from_template"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| templateName | Yes | Template to use: invoice, report, or letter | |
| data | Yes | Template data. Invoice: companyName, clientName, invoiceNumber, invoiceDate, items[{description, quantity, unitPrice}], taxRate, currency (ISO code or symbol, default USD), dueDate, notes, paymentTerms. Report: title, author, date, subtitle, sections[{heading, body}]. Letter: senderName, senderAddress, recipientName, recipientAddress, subject, body, closing, signatureName. | |
| outputPath | Yes | Absolute path for the output PDF file |