Skip to main content
Glama

Atualizar transação

update_transaction
Idempotent

Atualiza uma transação existente (parcial — campo omitido/vazio mantém o valor atual). Se amount, type ou accountId mudarem, reverte o efeito de saldo da versão antiga e reaplica com os novos valores (retorna 400 se a nova conta não tiver saldo suficiente para EXPENSE/TRANSFER). Não reajusta parcelas irmãs (currentInstallment/totalInstallments) nem faturas de cartão — para mudanças que afetam cartão, prefira excluir e recriar. Dispara recálculo de projeções e insights (best-effort).

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
idYesID da transação a atualizar
dateNoData ISO ou dd/mm/yyyy
typeNoEXPENSE, INCOME, TRANSFER ou INVOICE_PAYMENT
amountNoNovo valor da transação
cardIdNoNovo cartão vinculado
isPaidNoMarca/desmarca como paga (sem reverter/aplicar efeito de saldo automaticamente — use confirm_pending_transaction pra isso)
natureNoPERSONAL, PROFESSIONAL, MIXED ou BUSINESS
agentIdNoNovo contato/agente vinculado
categoryNoRótulo texto livre da categoria (independente de categoryId)
paidDateNoData ISO em que foi efetivamente paga
accountIdNoNova conta debitada/creditada
categoryIdNoId da Category do usuário
descriptionNoNova descrição/título
costCenterIdNoNovo centro de custo
scheduledDateNoData ISO — reagenda a transação
destinationAccountIdNoConta de destino, se type for TRANSFER

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
countNo

Schema Changelog

Changes observed during successful MCP inspections. Dates show when Glama detected each change.

  1. Changed8 schema fields changed
    • addedInput schema / properties / accountId / description
      Added value: +"Nova conta debitada/creditada"
    • addedInput schema / properties / agentId / description
      Added value: +"Novo contato/agente vinculado"
    • addedInput schema / properties / amount / description
      Added value: +"Novo valor da transação"
    • addedInput schema / properties / cardId / description
      Added value: +"Novo cartão vinculado"
    • addedInput schema / properties / costCenterId / description
      Added value: +"Novo centro de custo"
    • addedInput schema / properties / description / description
      Added value: +"Nova descrição/título"
    • addedInput schema / properties / isPaid / description
      Added value: +"Marca/desmarca como paga (sem reverter/aplicar efeito de saldo automaticamente — use confirm_pending_transaction pra isso)"
    • addedInput schema / properties / paidDate / description
      Added value: +"Data ISO em que foi efetivamente paga"
  2. Changed10 schema fields changed
    • addedInput schema / properties / agentId
      Added value: +{
      +  "type": "string"
      +}
    • addedInput schema / properties / category
      Added value: +{
      +  "description": "Rótulo texto livre da categoria (independente de categoryId)",
      +  "type": "string"
      +}
    • addedInput schema / properties / categoryId / description
      Added value: +"Id da Category do usuário"
    • addedInput schema / properties / costCenterId
      Added value: +{
      +  "type": "string"
      +}
    • addedInput schema / properties / date / description
      Added value: +"Data ISO ou dd/mm/yyyy"
    • addedInput schema / properties / destinationAccountId
      Added value: +{
      +  "description": "Conta de destino, se type for TRANSFER",
      +  "type": "string"
      +}
    • addedInput schema / properties / id / description
      Added value: +"ID da transação a atualizar"
    • addedInput schema / properties / nature
      Added value: +{
      +  "description": "PERSONAL, PROFESSIONAL, MIXED ou BUSINESS",
      +  "type": "string"
      +}
    • addedInput schema / properties / scheduledDate
      Added value: +{
      +  "description": "Data ISO — reagenda a transação",
      +  "type": "string"
      +}
    • addedInput schema / properties / type / description
      Added value: +"EXPENSE, INCOME, TRANSFER ou INVOICE_PAYMENT"
  3. First observed

TDQS

A4.9/5.0
Behavior5/5

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

The description discloses substantial behavior beyond the annotations: balance-effect reversal/reapplication when amount, type, or accountId change, a 400 error for insufficient balance, no adjustment of sibling installments or card invoices, and best-effort recalculation of projections/insights. This adds real operational context that annotations alone do not provide.

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?

The description is four dense sentences with no filler. It front-loads the main action and partial-update behavior, then covers side effects, exclusions, and post-update recalculations. Every sentence earns its place.

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?

For a 16-parameter mutation tool, the description covers scope, partial semantics, balance side effects, error conditions, exclusions, and alternative strategies. The output schema and per-parameter descriptions carry the remaining details, so nothing critical is missing for an agent to call this correctly.

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 baseline is 3. The description adds important cross-parameter semantics, such as how changing amount/type/accountId triggers balance reversal and reapplication, and the insufficient-balance 400 condition. This goes beyond what individual parameter descriptions state.

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 opens with a specific verb and resource, 'Atualiza uma transação existente', and immediately explains partial update semantics. It also distinguishes itself from related operations by stating what it does not do (adjust sibling installments or credit card invoices), which separates it clearly from create/delete/confirm tools.

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?

The description gives concrete when-to-use and when-not-to-use guidance: partial updates are supported, but for card-affecting changes it directs the agent to 'prefira excluir e recriar'. The isPaid parameter description also explicitly routes to confirm_pending_transaction, clarifying the correct alternative.

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.

TDQS

A3.7/5.0
Disambiguation3/5

The tools are individually well-described and many cross-reference their closest neighbors, but the set contains several easily confused clusters: create_transaction/confirm_new_transaction, update_equity/add_equity_valuation, the invoice tools (current_invoice, next_invoice, list_pending_invoices, get_invoice), and the many analytics/projection tools. The descriptions help a careful reader, but with 81 tools an agent is likely to misselect among these overlapping surfaces.

Naming Consistency3/5

CRUD operations consistently use create_/list_/update_/delete_ plus a resource noun, and all names are snake_case. However, there is a large second group of noun-phrase analytics tools (cashflow_forecast, spending_projection, categories_insights, transport_routine) plus one-off verbs such as can_afford, pay_invoice, and validate_current_invoices, so the naming convention is mixed even though it remains readable.

Tool Count1/5

81 tools is far beyond the practical MCP tool surface and exceeds the rubric's 50+ extreme-mismatch threshold. Even if each tool maps to a real finance endpoint, the volume overwhelms an agent's context window and makes selection much harder.

Completeness4/5

The server covers the finance lifecycle extensively: accounts, cards, invoices, transactions, recurring rules, budgets, goals, debts, equities, categories, tags, cost centers, profile, projections, and insights all have working read/write paths. Minor gaps remain, such as no update/delete for tags and no direct update/delete for system-generated invoices, but agents can usually work around these.