Testing your point-of-sale integration

You can use test mode to begin developing your Point of Sale (POS) integration without purchasing physical terminal hardware. A virtual test terminal allows you to simulate the entire payment flow and validate if your integration is working correctly.

📘

Ensure the Point of Sale payment method is enabled on your profile. Doing so automatically generates a test mode terminal.

To start testing your integration:

  1. Get your test terminal ID - fetch your test terminal ID from the Web App (with test mode active) or via the List Terminals endpoint using your test credentials. If you are using an access token, ensure you pass testmode=true as a query parameter.
  2. Create a test payment - use your test credentials and the retrieved terminal ID to call the Create Payment endpoint. Set the method to pointofsale and pass the test terminal ID in the terminalId parameter.

Example:

curl -X POST https://api.mollie.com/v2/payments \
    -H "Authorization: Bearer test_dHar4XY7LxsDOtmnkVtjNVWXLSlXsM" \
    -d "amount[currency]=EUR" \
    -d "amount[value]=10.00" \
    -d "description=My first in-person payment" \
    -d "redirectUrl=https://cash-register.example.org/order/12345/" \
    -d "webhookUrl=https://cash-register.example.org/payments/webhook/" \
    -d "method=pointofsale" \
    -d "terminalId=term_7MgL4wea46qkRcoTZjWEH"
<?php

$mollie = new \Mollie\Api\MollieApiClient();
$mollie->setApiKey("test_dHar4XY7LxsDOtmnkVtjNVWXLSlXsM");

$payment = $mollie->payments->create([
    "amount" => [
        "currency" => "EUR",
        "value" => "10.00"
    ],
    "description" => "My first in-person payment",
    "redirectUrl" => "https://cash-register.example.org/order/12345/",
    "webhookUrl" => "https://cash-register.example.org/payments/webhook/",
    "method" => "pointofsale",
    "terminalId" => "term_7MgL4wea46qkRcoTZjWEH"
]);
  1. Simulate payment statuses - since there is no physical device to interact with, the API response includes a changePaymentState URL. Use this URL to simulate different payment statuses (such as paid, canceled, or failed) to ensure your integration handles them correctly. Depending on the payment status, this will also trigger a call to your webhook server.

See Handling payment status for a breakdown of all payment stages and check out Webhooks for more details on how to handle webhook events.


Did this page help you?