biterp

reverse_receivable_receipt

Referência da tool reverse_receivable_receipt do MCP Server do bitERP (Contas a receber).

Reverse Receivable Receipt · Contas a receber

Somente leituraDestrutivaIdempotenteMundo aberto
NãoSimSimNão

Descrição

A descrição abaixo é a que o servidor publica, em inglês, e é o texto que o agente lê para decidir quando usar a tool.

UNDOES a receipt settled manually or by a payment gateway (Stripe), and its linked gateway fee: soft-deletes the transaction and allocation, leaving NO trace in the statement. Undoing a gateway one diverges from the provider balance; confirm with the user. Not for bank statement lines (Open Finance): use remove_receivable_allocation. If the money came back, use reverse_receivable_settlement, which keeps both lines.

Parâmetros

ParâmetroTipoObrigatórioDescrição
tenantstringSimDefines which tenant will have data read or changed. Use list_tenants first and prefer the returned tenant slug. Writes are permanent, so when the user has more than one tenant you must confirm the tenant before any write and never assume or reuse a previous choice without confirmation. UUID is accepted only when already known safely.
receivable_idstring (UUID)SimThe receivable ID
transaction_idstring (UUID)SimThe settlement transaction ID to undo

Resposta

O structuredContent da resposta traz os campos abaixo (até dois níveis; o schema completo está no outputSchema publicado no tools/list).

CampoTipoDescrição
receivableobject—
receivable.idstring (UUID)—
receivable.tenant_idstring (UUID)—
receivable.record_numberinteger—
receivable.customer_idstring (UUID) ou null—
receivable.customerobject ou null—
receivable.financial_account_idstring (UUID)—
receivable.financial_accountobject ou null—
receivable.payment_method_idstring (UUID) ou null—
receivable.payment_methodobject ou null—
receivable.financial_category_idstring (UUID) ou null—
receivable.financial_categoryobject ou null—
receivable.account_scope_maskobject—
receivable.reference_codestring ou null—
receivable.statusstringValores: pending, partial, paid, overdue, cancelled.
receivable.amountstring—
receivable.discount_amountstring—
receivable.surcharge_amountstring—
receivable.issue_datestring (date)—
receivable.due_datestring (date)—
receivable.paid_atstring (date-time) ou null—
receivable.installment_group_idstring (UUID) ou null—
receivable.installment_numberinteger ou null—
receivable.installment_countinteger ou null—
receivable.descriptionstring ou null—
receivable.notesstring ou null—
receivable.metadataobject—
receivable.created_by_user_idstring (UUID) ou null—
receivable.updated_by_user_idstring (UUID) ou null—
receivable.deleted_by_user_idstring (UUID) ou null—
receivable.created_atstring (date-time)—
receivable.updated_atstring (date-time)—
receivable.deleted_atstring (date-time) ou null—
receivable.sales_order_idstring (UUID) ou null—
receivable.sales_orderobject ou null—
receivable.invoice_idstring (UUID) ou null—
receivable.invoiceobject ou null—
receivable.parent_receivable_idstring (UUID) ou null—
receivable.parentobject ou null—
receivable.typestringValores: standard, interest, fine.
receivable.remaining_amountstring—
receivable.settlementsarray de objetos—
receivable.hidden_settlementsarray de objetos—
receivable.charge_titlesarray de objetos—
receivable.offsetsarray de objetos—
receivable.reversible_manual_receiptsarray de objetos—
reversed_transaction_idstring (UUID)—
removed_allocation_idstring (UUID)—
financial_account_idstring (UUID)—
_tenantobject—
_tenant.idstring (UUID)—
_tenant.slugstring—
_tenant.company_namestring—

Exemplo de chamada

Requisição tools/call com os parâmetros obrigatórios. Os valores são ilustrativos: troque minha-empresa pelo tenant devolvido por list_tenants e cada <...> por um valor real.

{
    "jsonrpc": "2.0",
    "id": 1,
    "method": "tools/call",
    "params": {
        "name": "reverse_receivable_receipt",
        "arguments": {
            "tenant": "minha-empresa",
            "receivable_id": "<uuid>",
            "transaction_id": "<uuid>"
        }
    }
}

Nesta página