Save payrun
save_payrunCreate or update a pay run header: period window, pay date, frequency and the tax returns it files. Omit id to create; pass an id to update that run. A created run is saved with payactionenabled false, so it never finalises itself and its drafts stay editable; arm it with an update only when the user asks. Writes no payslip and posts nothing to the ledger.
Tool call template
This tool declares no required parameters. Add optional parameters from the input schema as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {},
"name": "save_payrun"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| id | No | ||
| kind | No | ||
| notes | No | ||
| paydate | No | The day the employees are paid, YYYY-MM-DD. | |
| returns | No | The tax returns finalising files, as source ids from get_payroll_setup. Leave it out for the country's defaults. | |
| frequency | No | How often the run pays: monthly, semimonthly (twice a month), fortnightly or weekly. | |
| payaction | No | ||
| periodend | No | The last day of the pay period, YYYY-MM-DD. | |
| competence | No | ||
| periodstart | No | The first day of the pay period, YYYY-MM-DD. | |
| payactionenabled | No | Whether the run finalises and posts its draft payslips itself on its pay date. A created run is always saved with false. On an update, false lets its drafts be edited again and true arms it; only arm a run the user has asked to arm. |