
Before you switch a store, a billing panel or a bot to crypto, you want to see the whole flow work: the invoice is created, the customer picks a coin, the payment is confirmed and your system marks the order paid. With SnapEX Pay you can do all of that without sending a single coin.
What a test invoice is
A test invoice is an ordinary SnapEX Pay invoice with environment set to test. It goes through the same statuses and sends the same webhooks as a live invoice, with data.environment set to "test" in every event. It never changes your real balance.
There are no separate test API keys: you use the same key and only change one field in the request.
Create a test invoice through the API
Add "environment": "test" to the request that creates an invoice:
curl -sS -X POST https://pay.snapex.pro/api/v1/merchant/invoices \
-H "Authorization: Bearer <your API key>" \
-H "Content-Type: application/json" \
-H "Accept: application/json" \
-H "Idempotency-Key: order-15-test" \
-d '{
"amount_usd": "15.00",
"environment": "test",
"external_id": "order-15"
}'
The key needs the invoices.write scope. The response contains the payment link, exactly as for a live invoice.
Or create it in the merchant cabinet
In the cabinet, open Invoices and switch the mode to Test. Invoices you create there are test ones, and the list shows only test invoices, so they never mix with real payments.
Pay it
Open the payment link. The page shows a Test badge. Pick any coin and network: the page shows a test address (not a real one), and about 10 seconds later the payment confirms by itself. Nothing has to be sent.
What to check on your side
- Webhook delivery. Your endpoint receives
invoice.paidwithdata.environment = "test". Check that the signature verifies and that a repeated delivery of the sameWebhook-Iddoes not mark the order paid twice. - Order status. The order in your system becomes paid only on
invoice.paid. - Live and test stay apart. Make sure your code ignores test events once you go live, or keeps test orders separate.
Test mode in the ready-made modules
The WHMCS, BILLmanager, WooCommerce, CS-Cart, FOSSBilling, Paymenter and Remnawave modules have a test mode that creates test invoices. In WHMCS only logged-in admins see the payment button while it is on, in WooCommerce only shop managers see the method; in BILLmanager and CS-Cart you limit the test method to a test client or user group. Place an order, pay it on the SnapEX Pay page and check that the order becomes paid, then turn test mode off. The setup guides on pay.snapex.pro describe this step for each module.
Then go live
Remove "environment": "test" (or turn test mode off in the module), and the next invoices are live. Test payments are never applied to live orders.
Full API reference: SnapEX Pay API documentation.