Skip to main content
Glama
Flowsery

flowsery

Official

Delete Payments

delete_payments
Destructive

Permanently delete payment records by transaction ID, visitor ID, or creation date. Irreversible. Confirm filters and range before use.

Instructions

Permanently delete payment records matching every filter given (filters combine with AND): one transactionId, all payments of a visitorId, and/or a createdAt window. At least one of transactionId, visitorId, startAt, or endAt is required or the call fails before reaching the API; startAt and endAt are independent, so one bound alone is allowed. Without a date range, matches are deleted across the whole history. Returns the number of rows deleted. Cannot be undone and removes revenue from every report and visitor profile, so restate website, filters, and range and get explicit confirmation first. To reverse a charge while keeping history, use track_payment with isRefund instead. Requires websiteId or domain with a workspace token.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
endAtNoISO 8601 end of the deletion window, inclusive (e.g. "2026-01-31T23:59:59Z"). May be used without startAt.
domainNoWebsite domain from list_websites (e.g. "example.com"). Alternative to websiteId with a workspace token.
startAtNoISO 8601 start of the deletion window, inclusive (e.g. "2026-01-01T00:00:00Z"). May be used without endAt.
visitorIdNoDelete all payments of this visitor (the id get_visitor takes)
websiteIdNoWebsite ID from list_websites. Required with a workspace token unless domain is given; ignored with a website key.
transactionIdNoDelete the single payment with this transaction ID. Combined with the other filters using AND.

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
resultNoObject with status and data: deleted (number of payment records removed) and a confirmation message.

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed7 schema fields changedv0.1.1
    • changedInput schema / properties / domain / description
      Previous value: -"Website domain to query. Required when using a workspace token unless websiteId is provided."New value: +"Website domain from list_websites (e.g. \"example.com\"). Alternative to websiteId with a workspace token."
    • changedInput schema / properties / endAt / description
      Previous value: -"ISO 8601 end timestamp"New value: +"ISO 8601 end of the deletion window, inclusive (e.g. \"2026-01-31T23:59:59Z\"). May be used without startAt."
    • changedInput schema / properties / startAt / description
      Previous value: -"ISO 8601 start timestamp"New value: +"ISO 8601 start of the deletion window, inclusive (e.g. \"2026-01-01T00:00:00Z\"). May be used without endAt."
    • changedInput schema / properties / transactionId / description
      Previous value: -"Delete the payment with this transaction ID"New value: +"Delete the single payment with this transaction ID. Combined with the other filters using AND."
    • changedInput schema / properties / visitorId / description
      Previous value: -"Delete all payments for this visitor"New value: +"Delete all payments of this visitor (the id get_visitor takes)"
    • changedInput schema / properties / websiteId / description
      Previous value: -"Website ID to query. Required when using a workspace token unless domain is provided."New value: +"Website ID from list_websites. Required with a workspace token unless domain is given; ignored with a website key."
    • changedOutput schema / properties / result / description
      Previous value: -"Confirmation of the payment record deletion."New value: +"Object with status and data: deleted (number of payment records removed) and a confirmation message."
  2. First observedv0.1.0

TDQS

A5/5.0
Behavior5/5

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

It goes beyond the destructiveHint annotation by warning that deletion is permanent, cannot be undone, and removes revenue from reports and visitor profiles, advising explicit confirmation before proceeding.

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 concise yet comprehensive, using separate sentences for function, filters, requirements, output, warning, alternative, and authentication. No redundant information.

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?

All relevant context is covered: purpose, filter semantics, return value, destructive consequences, alternative for reversal, and authentication details. No gaps remain.

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

Parameters5/5

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

Each parameter has a detailed description in the schema, and the description adds clarity on how filters combine with AND and that startAt/endAt are independent. Schema coverage is 100%.

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 clearly states that the tool permanently deletes payment records matching filters, and explicitly contrasts it with track_payment for reversing charges. It also differentiates from delete_goals by specifying the payment domain.

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 specifies when to use (delete payments) and when not to (use track_payment with isRefund for reversal), lists required filter conditions, and notes authentication requirements with websiteId/domain.

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