Skip to main content
Glama

Save journal entry

save_journal_entry

Create or replace a WHOLE journal entry with all its lines; to fix one line on an existing entry use update_journal_line, and to add one use add_journal_line. Pass an id to update it; omit id to create a new one. Returns the new journal entry id on create. To create/update many at once, send an items array — one all-or-nothing transaction with a single ledger recompute; each item with an id updates, each without creates.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
idNoJournal entry id. Present → update; omit → create a new one.
dateNoJournal entry date (ISO 8601).
nameNoDescription of the journal entry.
itemsNoVector of journal entry objects to create/update in one all-or-nothing batch. Preferred over repeated calls. Each item with an id updates; each without creates.
linesNoJournal lines. Each line debits or credits one account; total debits must equal total credits.
notesNoFree-text notes.
amountNoTotal amount of the journal entry.
openingNoWhether this is an opening balance entry.

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed2 schema fields changed
    • addedInput schema / properties / items / items / properties / lines / items / properties / role
      Added value: +{
      +  "description": "Optional line role: what the amount is (e.g. sars-3601), set by the producer. Lowercase letters, digits and hyphens, at most 64 characters. Send \"$delete\" to clear it; omit it to leave it alone.",
      +  "type": "string"
      +}
    • addedInput schema / properties / lines / items / properties / role
      Added value: +{
      +  "description": "Optional line role: what the amount is (e.g. sars-3601), set by the producer. Lowercase letters, digits and hyphens, at most 64 characters. Send \"$delete\" to clear it; omit it to leave it alone.",
      +  "type": "string"
      +}
  2. Changed2 schema fields changed
    • changedInput schema / properties / items / items / properties / lines / items / required
      Previous value: -[
      -  "accountid",
      -  "debit",
      -  "credit"
      -]New value: +[]
    • changedInput schema / properties / lines / items / required
      Previous value: -[
      -  "accountid",
      -  "debit",
      -  "credit"
      -]New value: +[]
  3. First observed

TDQS

A4.7/5.0
Behavior4/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

Annotations cover the read/write safety profile (readOnlyHint=false, destructiveHint=false); beyond that the description adds real behavior: the returned id on create, and that items are one all-or-nothing transaction with a single ledger recompute. It does not address what happens to existing lines on replace or permission needs, so not a full 5.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness5/5

Is the description appropriately sized, front-loaded, and free of redundancy?

It is front-loaded with the core action, then routing guidance, then id semantics, then batch behavior. Every sentence carries distinct, actionable information with no filler.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness5/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

With no output schema, the description supplies the key return value (new journal entry id on create) and covers single, update, and batch-item flows. Nothing an agent needs to call it correctly is missing.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters4/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema description coverage is 100% so the schema already documents all 8 params (baseline 3). The description adds meaning beyond the schema by explaining the id-present/absent create-vs-update rule and the atomic, single-recompute semantics of the items array.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description gives a specific verb (create or replace) plus resource (whole journal entry with all lines) and explicitly names the distinguishing siblings update_journal_line and add_journal_line, so an agent can tell it apart without opening a schema.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines5/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

It states when to use this vs alternatives ('to fix one line use update_journal_line, to add one use add_journal_line'), how id selects update vs create, and when to prefer the items batch array. Routing is fully specified.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

Try in Browser

Glama MCP Gateway

Add one secure layer between your agents and this server.

Resources