Sandbox / Test Keys
Want to try the SmartPay payment button without creating a merchant account and completing Level 2 verification? Use the shared sandbox (test) keys below. They behave exactly like your own keys, but they operate against the test environment.
Shared Sandbox Keys
PUBLIC_KEY = pk_test_c6649e69315edc3389a3cc439e7b0649
SECRET_KEY = sk_test_82249499f91c116a92bce2c6ab6a91133f3f1a52cb0fcfd455b5d420eb42504e
| Key | Value | Where to use it |
|---|---|---|
| Public Key | pk_test_c6649e69315edc3389a3cc439e7b0649 | publicKey prop of the SmartPay component (frontend) |
| Secret Key | sk_test_82249499f91c116a92bce2c6ab6a91133f3f1a52cb0fcfd455b5d420eb42504e | x-secret-key header in the preorder call (backend) |
The sandbox uses the same API host as production (https://pb-api.apolopay.app) — the key prefix (pk_test_ / sk_test_) is what selects the test environment.
Try It in 3 Steps
1. Create a test preorder
curl -X POST https://pb-api.apolopay.app/payment-button/process/preorder \
-H "Content-Type: application/json" \
-H "x-secret-key: sk_test_82249499f91c116a92bce2c6ab6a91133f3f1a52cb0fcfd455b5d420eb42504e" \
-d '{
"amount": 1.00,
"metadata": {
"orderId": "TEST-0001",
"customerEmail": "[email protected]"
}
}'
The response wraps the created preorder in a result object:
{
"success": true,
"message": "OK",
"result": {
"id": "660cbb7f-6d78-4638-862b-1dbc3911ecbe",
"amount": 1,
"status": "pre_order",
"createdAtMs": 1790095153955
}
}
| Field | Description |
|---|---|
success | true when the preorder was created |
message | Human-readable status ("OK") |
result.id | The process ID (UUID) you pass to the payment button |
result.amount | Amount registered for the preorder |
result.status | pre_order until the customer completes the payment |
result.createdAtMs | Creation timestamp in milliseconds |
2. Render the button
Pass the test public key and result.id as the button's process-id:
<payment-button
publicKey="pk_test_c6649e69315edc3389a3cc439e7b0649"
process-id="PROCESS_ID_FROM_BACKEND"
></payment-button>
3. Complete a test payment
Interact with the button, pick a cryptocurrency and network, and follow the payment flow. No real funds are moved.
Sandbox vs Your Own Keys
| Shared sandbox keys | Your own keys | |
|---|---|---|
| Public key | pk_test_c6649e69315edc3389a3cc439e7b0649 | Generated in the dashboard |
| Secret key | sk_test_8224... | Generated in the dashboard |
| Requirement | None — use them as-is | Level 2 verified account |
| Audience | Anyone evaluating SmartPay | Your production integration |
The sandbox keys are published on purpose so anyone can test the button. Because of that:
- Never use them in production — use your own keys from the dashboard
- Don't send sensitive data in
metadataor in the payment flow - Don't point real webhooks at them, and don't treat sandbox data as private
The "never expose your secret key" rule still applies to your private keys. This page only publishes a shared test secret key. Live secret keys must never appear in frontend code, public repositories or client-side JavaScript — they belong on your server only.
Next Steps
- Backend Integration → — Create preorders with the secret key
- Choose your framework → — Render the button
- Create Your Own Button → — Get your own keys