Preview: SendMock has no stable release yet. These docs follow develop.

MCP reference

Checkout tools

sendmock_checkout_complete

Pay, decline or cancel from the checkout page.

Toolset payments.

    InputTypeDescription
    session_idrequiredstring
    The SMTP session's ID, from GET /api/v1/logs/smtp.Example: 01JB7T9Q2R5W8X3Y6Z1A4B7C9D
    actionrequiredstring
    What the customer does: pay, decline, cancel, delay (pending), require_three_ds, three_ds_approve or three_ds_fail.One of: pay, decline, cancel, delay, require_three_ds, three_ds_approve, three_ds_failExample: pay
    method_keystring
    The method the customer paid with.Example: card
    cardCheckoutCard
    The card typed, for card methods.
    entriesCheckoutStepEntries
    What was typed in the flow's other steps.
    decline_reasonstring
    For decline: why the bank declined.One of: insufficient_funds, expired_card, incorrect_cvc, generic_decline, fraudulent, authentication_failedExample: insufficient_funds

    Example call

    {
      "name": "sendmock_checkout_complete",
      "arguments": {
        "session_id": "01JB7T9Q2R5W8X3Y6Z1A4B7C9D",
        "action": "pay",
        "method_key": "card",
        "decline_reason": "insufficient_funds"
      }
    }

    Result: CheckoutSession

    API
    POST/api/v1/checkout-sessions/{sessionId}/complete
    CLI
    sendmock payments checkout complete <sessionId> <action>
    In the app
    Test checkout page > pay, Test controls

    sendmock_checkout_get

    What a test checkout page shows: order, methods and flows.

    Toolset payments.

    • Read only
    InputTypeDescription
    session_idrequiredstring
    The SMTP session's ID, from GET /api/v1/logs/smtp.Example: 01JB7T9Q2R5W8X3Y6Z1A4B7C9D

    Example call

    {
      "name": "sendmock_checkout_get",
      "arguments": {
        "session_id": "01JB7T9Q2R5W8X3Y6Z1A4B7C9D"
      }
    }

    Result: CheckoutSession

    API
    GET/api/v1/checkout-sessions/{sessionId}
    CLI
    sendmock payments checkout show <sessionId>
    In the app
    Test checkout page