Skip to main content
Glama

Wait for PayPay Payment

wait_for_payment
Read-only

Polls PayPay until a payment reaches a terminal state or timeout, then returns the final status and full payment details.

Instructions

Poll PayPay until a payment reaches a terminal state (COMPLETED, AUTHORIZED, REFUNDED, FAILED, CANCELED) or the timeout elapses. Uses PayPay's recommended 2–3s polling interval by default. Returns the final status and full payment detail.

取引が終了状態(COMPLETED / AUTHORIZED / REFUNDED / FAILED / CANCELED)に達するかタイムアウトするまで、PayPayをポーリングします。 PayPay推奨の2〜3秒間隔をデフォルトで使用します。 最終ステータスと取引詳細を返します。

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
timeout_secondsNoGive up after this many seconds. Default: 120.
merchant_payment_idYesThe merchantPaymentId of the payment to wait on.
poll_interval_secondsNoHow often to poll (seconds). PayPay recommends 2–3s.

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.2.1

TDQS

A4.1/5.0
Behavior4/5

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

Annotations provide readOnlyHint=true, which already signals no state mutation. The description adds valuable behavioral context beyond that: it explicitly mentions the polling action, the timeout behavior, and that it returns final status and full payment detail. It also discloses the default 2–3s polling interval, which is not in the annotations. No contradictions found, and the description augments the safety profile with concrete operational details.

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 English portion is concise and front-loaded: the first sentence states the core purpose (poll until terminal or timeout), and subsequent sentences add default interval and return value. The Japanese duplicate doubles length but is likely intentional for localization. The structure is well-organized with no wasted words, though the duplication could be trimmed for a purely English audience.

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

Completeness4/5

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

The tool has 3 parameters, all fully described in the schema, and no output schema. The description covers the core behavior (polling, terminal states, timeout, return of final status and details) and integrates well with the annotations. A minor gap is the lack of explicit behavior on timeout (e.g., does it return the last status or raise an error?), but overall it provides enough information for an agent to correctly invoke the tool. Sibling tools are distinct, and this description sufficiently differentiates it.

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 description coverage is 100%, and each parameter (merchant_payment_id, timeout_seconds, poll_interval_seconds) has a clear description and defaults/min/max. The description itself adds little beyond the schema—it mentions the default polling interval, but that's already in the schema ('default 3', 'PayPay recommends 2–3s'). It does not introduce new meaning for the parameters, so a baseline of 3 is appropriate.

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 states a specific verb (poll), resource (PayPay payment), and the exact terminal states it waits for (COMPLETED, AUTHORIZED, REFUNDED, FAILED, CANCELED). It clearly distinguishes itself from siblings like get_payment_details (which likely returns a one-time snapshot) and create_qr_code/delete_qr_code (which create/delete resources). The purpose is unambiguous and directly tied to its name.

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?

The description implicitly tells when to use this tool: when you need to wait for a payment to reach a terminal state, as opposed to fetching a single status snapshot. While it doesn't explicitly name the alternative (get_payment_details) or state 'use this instead of X', the context is clear from the polling behavior. It lacks explicit exclusions or 'when not to use' guidance, but the intended use case is well communicated.

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