Pending draft: tick bank entries as cleared (human approves in Taokeh)
create_bank_clearing_draftFiles a pending draft of ticks for Banking → Clear transactions: which book entries appear on the bank statement, each paired with a statement line or given the date it cleared. Nothing is ticked until an admin or bookkeeper approves in Taokeh; approval ticks them as the page's Save ticks does (a tick posts nothing to the books and can be un-ticked). Every id comes from bank_reconciliation_report: bankAccountId, statementId (or asOf, a date, when there is no statement), and per item entryId (from clearStep.uncleared) with either statementLineId (from clearStep.candidateLines; the entry clears on the later of the line's date and its own) or clearedDate (YYYY-MM-DD; defaults to the reconciliation date, as on the page). At most 300 items per draft. A cancelling pair from hints.cancellingPairs is two items with no line and the pair's clearDate. Refused by name at filing (the real tick is run and rolled back) and at approval: an entry that is not uncleared on this account up to the date (posted from a statement line, the opening balance, already ticked, dated later); a line that is posted, fully paired, dated after the reconciliation date, without room left for the entry, or moving money the other way; a cleared date before the entry was booked or after the reconciliation date; a date inside a locked period; a card; a foreign-currency account (Taokeh posts and reconciles only ringgit accounts for now; the refusal names the account); an entry already in another pending draft. If anything the draft was filed against changes before approval, approval refuses and nothing is ticked.
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": {
"bankAccountId": "<bankAccountId>",
"items": "<items>"
},
"name": "create_bank_clearing_draft"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| asOf | No | Reconcile to a date by hand (no statement). Give this OR statementId. | |
| note | No | A short note for the owner: why these are cleared. | |
| items | Yes | The ticks. An unknown key in an item is refused by name. | |
| notes | No | Not a filter on this tool. Pass the owner note as `note`. | |
| ticks | No | Not a filter on this tool. Pass the ticks as `items`: [{entryId, statementLineId?, clearedDate?}]. | |
| bankId | No | Not a filter on this tool. Pass the bank account as `bankAccountId`. | |
| entries | No | Not a filter on this tool. Pass the ticks as `items`: [{entryId, statementLineId?, clearedDate?}]. | |
| needsReview | No | true flags the draft for the reviewer. | |
| statementId | No | The statement you reconcile to, from bank_reconciliation_report `statement.id`. Give this OR asOf. | |
| bankAccountId | Yes | The bank account, from bank_reconciliation_report. |