Skip to main content
Glama
shukiv

blesta-mcp

by shukiv

Charge payment account on file

process_payment
Destructive

Charge a client's stored payment account and apply the funds to selected invoices, with an optional receipt email.

Instructions

Charge a client's stored card or bank account through the payment gateway and apply the result to invoices. Wraps Payments.processPayment with account_id only; raw card data is never accepted. Sends the client a receipt unless disabled. Moves real money. DISABLED: set BLESTA_ALLOW_PAYMENTS=1 to enable.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
typeYesKind of stored account
amountYes
currencyYes
invoicesNoMap of invoice_id -> amount to apply; total must not exceed amount
staff_idNo
client_idYes
account_idYesStored payment account id from get_payment_accounts
email_receiptNo

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.1.0

TDQS

A4.1/5.0
Behavior4/5

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

Annotations already flag destructive/non-idempotent behavior, and the description adds valuable context: 'Moves real money', receipt sending unless disabled, and the disabled-by-default environment gate. It does not detail failure modes or partial invoice application, but it meaningfully extends the annotation profile without contradicting it.

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?

Five short sentences, front-loaded with the core action and outcome. Every sentence earns its place, and the critical warnings ('Moves real money', disabled state) are placed efficiently without filler.

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

Completeness3/5

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

For a destructive financial mutation with 8 parameters, a nested object, and no output schema, the description covers side effects and the enablement gate but omits the return value/error contract and exact invoice-application semantics. An agent would still need to infer what a successful call returns.

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

Parameters3/5

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

Schema coverage is only 38%, so the description must compensate. It helps with account_id ('from get_payment_accounts'), type (stored card vs bank account), invoices (mapping and total constraint), and email_receipt ('unless disabled'). However, amount, currency, and staff_id remain unexplained, leaving a notable gap.

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 uses a specific verb ('Charge') and names the resource ('client's stored card or bank account through the payment gateway'), plus the outcome ('apply the result to invoices'). It clearly differentiates this from manual-payment or invoice-link siblings by emphasizing stored-account-only charging.

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

Usage Guidelines4/5

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

It provides clear context: use this when charging a stored account and applying payment to invoices, and it gives an exclusion ('raw card data is never accepted') plus an activation requirement ('set BLESTA_ALLOW_PAYMENTS=1'). However, it never explicitly names sibling alternatives such as record_manual_payment or create_invoice_payment_link.

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