Getting started
First payment
Make an end-to-end Sandbox payment using the Payment Engine.
1. Initiate
curl -X POST https://init-vpay.venlabs.link/merchant/initiate-payment \
-H "Content-Type: application/json" \
-H "X-API-KEY: $VENPAYS_SANDBOX_KEY" \
-d '{
"amount": 1.000,
"currency": "BHD",
"payment_provider": "mastercard"
}'
Successful responses typically include track_id and a payment_url for hosted checkout providers.
2. Complete checkout
Open payment_url in a browser and complete the provider flow (card, Benefit, or Apple Pay web).
3. Confirm status
curl -X POST https://init-vpay.venlabs.link/merchant/payment-status \
-H "Content-Type: application/json" \
-H "X-API-KEY: $VENPAYS_SANDBOX_KEY" \
-d '{"track_id":"<track_id>"}'
Merchant-facing statuses: success, failed, pending.
4. Webhook (recommended)
Configure a Sandbox webhook and verify X-VenPays-Signature before trusting the event. See Webhooks.
Full field reference: Initiate payment.