Skip to main content
Glama

MAQAMI Travel

chargeFlightExtraCharges

Overview

Confirms a pending extra-charge batch created by /extra-charges/precharges. Captures the Stripe PaymentIntent or bills the credit line, then appends the lines to the booking.

Access

Requires Flights API access. Post-booking extra charges are not enabled by default — contact the LiteAPI support team to request access.

Idempotency

Idempotent on chargesId, mirroring POST /flights/bookings prebookId replay:

  • Already confirmed — HTTP 200 with data.message and the persisted extras (no re-capture / no duplicate credit-line billing)

  • Concurrent confirm — HTTP 409 / 45035 while another confirm for the same chargesId holds the Redis lock; retry after the first completes

When to Use

  • After the customer confirmed the Stripe PaymentIntent (status requires_capture / succeeded), or immediately for CREDIT bookings

Constraints

  • Body only needs chargesId + payment (charge lines are encoded in chargesId)

  • payment.method must match the booking's original payment (TRANSACTION_ID or CREDIT)

  • For Stripe, payment.transactionId must be the id returned by precharges

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
paymentYesPayment details for capturing the extra charge. method must match the booking original payment.
bookingIdYesFlight booking identifier
chargesIdYesOpaque token from precharges

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observed

TDQS

A4/5.0
Behavior1/5

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

The description explicitly states 'Idempotent on chargesId' and details replay behavior (HTTP 200 on already-confirmed, 409/45035 on concurrent confirm), but the annotations declare idempotentHint=false. This directly contradicts the structured hint and could mislead an agent into replaying the call.

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

Conciseness4/5

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

The markdown headers (Overview, Access, Idempotency, When to Use, Constraints) make it easy to scan and the key purpose is front-loaded. It is somewhat verbose for a 3-parameter tool, but each section carries distinct 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?

For a mutation tool with no output schema and 3 required nested params, the description covers access gating (support-team enablement), idempotency/replay semantics, error codes, and required vs optional fields. An agent has everything needed to invoke it correctly, aside from the annotation conflict.

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 coverage is already 100%, so the baseline is 3, but the description adds real meaning beyond the schema: only chargesId + payment are needed (lines encoded in chargesId), payment.method must match the booking's original payment, and transactionId must be the id from precharges.

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?

States a specific verb and resource ('Confirms a pending extra-charge batch created by /extra-charges/precharges') and describes the side effects (Stripe capture, credit-line billing, appending lines to the booking). An agent can clearly distinguish it from the sibling prechargeFlightExtraCharges, which creates the batch this tool confirms.

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 'When to Use' section gives an explicit precondition (after the customer confirmed the PaymentIntent at requires_capture/succeeded, or immediately for CREDIT bookings) and the Overview names the upstream tool that produces chargesId. Alternatives and timing are 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