Test mode
The test environment at https://testapi.suawave.com runs the same API as production on simulated chains. Point your staging shop or your code at it, create orders as usual, send a simulated deposit with one call, and receive the same signed pending and confirmed callbacks you will get in production. With no server of your own yet, let the callback sink on the test host receive them. Nothing touches a real blockchain and no money moves.
What is the same and what differs
Production https://api.suawave.com | Test https://testapi.suawave.com | |
|---|---|---|
| Endpoints, parameters, errors | As documented | The same, plus the test helpers and the callback sink below |
| Tickers | Every listed ticker | trc20/usdt, bep20/usdt, bep20/usdc, erc20/usdt, erc20/usdc |
| Deposits | Sent by the payer on the real chain | Sent by you with POST /test_helpers/{ticker}/deposit/ |
| Callbacks | Signed with the production key, sent to your HTTPS endpoint | Signed with the test key, and carry livemode equal to "0"; sent to your endpoint or to a callback sink |
| Responses | No livemode field | Every JSON response carries livemode equal to "0" and the header Suawave-Livemode: false |
| Orders and addresses | Production database | A separate database: an order created on one host does not exist on the other |
| Minimums and fees | Production values | Test values, readable from GET /{ticker}/info/ on the test host |
Warning
Deposit addresses from the test environment look like real addresses but belong to a public test key. Never send real funds to them: anything sent on a real network can be taken by anyone and is not recoverable.
Keys
There is no API key in production and none in test mode. The test environment signs callbacks with its own key pair. Fetch the test key once from the test host and keep it apart from the production key:
curl "https://testapi.suawave.com/pubkey/"Verify test callbacks with the test key and production callbacks with the production key, exactly as described in Verify callback signatures. Refuse a callback whose livemode is "0" in production, so a test callback can never mark a real order paid.
Walk-through
The commands run as they are in a bash shell. Pick a random sink id and a nonce, and build the callback URL of the order from them. The callback URL identifies the order on the test host as it does in production; to use your staging shop instead, put its public HTTPS callback URL in CALLBACK.
SINK=$(openssl rand -hex 8)
NONCE=$(openssl rand -hex 8)
CALLBACK="https://testapi.suawave.com/sink/$SINK?order=1001&nonce=$NONCE"Create an order on the test host. Any valid address of the ticker's network works as the payout address; the example below has no known key, so never use it in production:
curl -G "https://testapi.suawave.com/trc20/usdt/create/" \
--data-urlencode "address=TWe5GkE5VFQwTnJ4KmcFyevwMAfosdHcEW" \
--data-urlencode "callback=$CALLBACK" \
--data-urlencode "pending=1"Send a simulated deposit to that order. value is optional and defaults to the minimum:
curl -X POST -G "https://testapi.suawave.com/test_helpers/trc20/usdt/deposit/" \
--data-urlencode "callback=$CALLBACK" \
--data-urlencode "value=25.5"Within a few seconds the callback URL receives the pending callback (with pending=1 at create) and then the confirmed callback with txid_in, txid_out, value_coin, value_forwarded_coin and fee_coin, signed with the test key. Read them from the sink:
curl "https://testapi.suawave.com/sink/$SINK/"On your own endpoint, verify the signature with the test key and answer *ok* as usual; the sink does both for you.
To test the other cases, choose the value:
| Case | Value |
|---|---|
| Paid | The amount your order expects |
| Underpaid | Less than the order expects, at least the minimum: forwarded, your shop decides |
| Overpaid | More than the order expects |
| Below the minimum | Less than minimum_transaction_coin: not forwarded and no callback |
| Several payments | Call the helper more than once: each deposit is forwarded with its own callbacks |
Test helpers
The helpers exist only on the test host and answer 404 on https://api.suawave.com. They take their parameters in the query string and identify the order by ticker and callback URL, like logs.
Simulate a deposit (test environment only)
POST /test_helpers/{ticker}/deposit/
Test environment only: exists on the test host and answers 404 on the production host. Sends a simulated deposit of value to the address_in of the order identified by ticker and callback, exactly as create identifies it. The deposit goes through detection, forwarding and the normal signed callbacks (pending with pending=1, then confirmed), which carry livemode 0. A value below minimum_transaction_coin is not forwarded and triggers no callback. Parameters go in the query string; no request body. Limited to 30 deposits per client IP in 10 minutes.
Parameters
| Name | In | Required | Type | Description |
|---|---|---|---|---|
ticker | path | yes | string | Lowercase registry token ticker including slash, for example trc20/usdt, bep20/usdt or erc20/usdt. The server accepts both path segments as one ticker; clients must retain the slash. The bare native ticker trx (TRX on TRON, 6 decimals) is coming soon and is not enabled on mainnet; it is not currently resolved there. When it launches, direct TRX transfers (TransferContract) only are credited; fees, minimum and maximum come from GET /trx/info/. |
callback | query | yes | string | The callback URL of the test order, exactly as given at create, URL-encoded, exactly once. A callback sink URL on the test host works, as does your own public HTTPS endpoint. |
value | query | no | string | Deposit amount in whole asset units, at most 1000000. Defaults to minimum_transaction_coin. |
Example request
curl -X POST -G "https://testapi.suawave.com/test_helpers/trc20/usdt/deposit/" \
--data-urlencode "callback=https://testapi.suawave.com/sink/4f9d2c7a1b3e5f60?order=1001&nonce=7f3a9c"Response 200
Deposit sent to the simulated chain; callbacks follow within seconds.
| Field | Type | Required | Description |
|---|---|---|---|
status | string, always success | yes | |
livemode | string, always 0 | yes | Always 0 in the test environment. |
ticker | string | yes | |
address_in | string | yes | The order's deposit address. |
txid_in | string | yes | Hash of the simulated deposit; the callbacks carry it as txid_in. |
value_coin | string | yes | |
minimum_transaction_coin | string | yes | |
forwarded | string, one of 0, 1 | yes | 1 when the value reaches the minimum and will be forwarded. |
{
"status": "success",
"livemode": "0",
"ticker": "trc20/usdt",
"address_in": "TDepositAddressExample0000000000",
"txid_in": "4b0e3f5a9c1d2e7f8a6b5c4d3e2f1a0b9c8d7e6f5a4b3c2d1e0f9a8b7c6d5e4f",
"value_coin": "25.500000",
"minimum_transaction_coin": "10.000000",
"forwarded": "1"
}Errors
Statuses 400, 429, 503 use the standard error body described in Errors.
| Status | Meaning |
|---|---|
404 | No order exists for this ticker and callback, or the production host was called. |
List simulated deposits (test environment only)
GET /test_helpers/{ticker}/deposits/
Test environment only: exists on the test host and answers 404 on the production host. Lists the simulated deposits of the order, newest first, at most 100, with their transaction hashes and state. Unlike logs it also lists deposits that are still pending or below the minimum.
Parameters
| Name | In | Required | Type | Description |
|---|---|---|---|---|
ticker | path | yes | string | Lowercase registry token ticker including slash, for example trc20/usdt, bep20/usdt or erc20/usdt. The server accepts both path segments as one ticker; clients must retain the slash. The bare native ticker trx (TRX on TRON, 6 decimals) is coming soon and is not enabled on mainnet; it is not currently resolved there. When it launches, direct TRX transfers (TransferContract) only are credited; fees, minimum and maximum come from GET /trx/info/. |
callback | query | yes | string | The callback URL of the test order, exactly as given at create, URL-encoded, exactly once. A callback sink URL on the test host works, as does your own public HTTPS endpoint. |
Example request
curl -G "https://testapi.suawave.com/test_helpers/trc20/usdt/deposits/" \
--data-urlencode "callback=https://testapi.suawave.com/sink/4f9d2c7a1b3e5f60?order=1001&nonce=7f3a9c"Response 200
Simulated deposits of the order.
| Field | Type | Required | Description |
|---|---|---|---|
status | string, always success | yes | |
livemode | string, always 0 | yes | |
ticker | string | yes | |
address_in | string | yes | |
deposits | array of object | yes | |
deposits[].txid_in | string | yes | |
deposits[].value_coin | string | yes | |
deposits[].state | string, one of pending, confirming, forwarding, forwarded, below_minimum, held, rejected, orphaned | yes | pending: seen, not final; confirming: final and credited; forwarding: forwarding transaction in flight; forwarded: forwarded and confirmed; below_minimum: not forwarded. |
deposits[].txid_out | string | no | Forwarding transaction hash |
deposits[].seen_at | string | yes |
{
"status": "success",
"livemode": "0",
"ticker": "trc20/usdt",
"address_in": "TDepositAddressExample0000000000",
"deposits": [
{
"txid_in": "4b0e3f5a9c1d2e7f8a6b5c4d3e2f1a0b9c8d7e6f5a4b3c2d1e0f9a8b7c6d5e4f",
"value_coin": "25.500000",
"state": "forwarded",
"txid_out": "7d6c5b4a39281706f5e4d3c2b1a09f8e7d6c5b4a39281706f5e4d3c2b1a09f8e",
"seen_at": "2026-11-21T12:00:00Z"
},
{
"txid_in": "0f1e2d3c4b5a69788796a5b4c3d2e1f00f1e2d3c4b5a69788796a5b4c3d2e1f0",
"value_coin": "1.000000",
"state": "below_minimum",
"seen_at": "2026-11-21T11:59:00Z"
}
]
}Errors
Statuses 400, 429, 503 use the standard error body described in Errors.
| Status | Meaning |
|---|---|
404 | No order exists for this ticker and callback, or the production host was called. |
The deposit helper is limited to 30 deposits per client address in 10 minutes. /{ticker}/logs/ works on the test host too and lists forwarded deposits with their callback attempts.
Callback sink
A callback sink receives the callbacks of test orders for you, so you can follow an order before your own endpoint exists. Use https://testapi.suawave.com/sink/{id} as the callback URL, with an id of 8 to 64 letters, digits, - or _ and any query string you like, such as your order reference and nonce. The sink verifies the x-ca-signature of each callback with the test key, stores it and answers *ok*; a request whose signature does not verify is refused with 401 and not stored. post=1 and json=1 work too.
A sink keeps the last 25 callbacks of an id for one hour, in memory: a restart of the test environment empties it. It has no access control, so anyone who knows the id can read it; use a random id and never put anything secret in the URL. The sink exists only on the test host and answers 404 on https://api.suawave.com. In production your callback URL is your own HTTPS endpoint.
Read a callback sink (test environment only)
GET /sink/{id}/
Test environment only: exists on the test host and answers 404 on the production host. Lists the callbacks that reached the callback URL https://testapi.suawave.com/sink/{id} (any query string), newest first. The sink stores a callback only when its x-ca-signature verifies with the test key, answers *ok* to it, and refuses anything else with 401. At most 25 callbacks per id, kept for one hour in memory; a restart of the test environment empties every sink. Anyone who knows the id can read it, so use a random id. Limited to 60 reads per client IP a minute.
Parameters
| Name | In | Required | Type | Description |
|---|---|---|---|---|
id | path | yes | string | Sink id, 8 to 64 letters, digits, - or _. Choose a random one; a sink exists as soon as a callback reaches it. |
Example request
curl "https://testapi.suawave.com/sink/4f9d2c7a1b3e5f60/"Response 200
Callbacks the sink received, newest first; an empty list when none arrived yet.
| Field | Type | Required | Description |
|---|---|---|---|
status | string, always success | yes | |
livemode | string, always 0 | yes | |
sink | string | yes | The sink id. |
callbacks | array of object | yes | |
callbacks[].received_at | string | yes | |
callbacks[].method | string, one of GET, POST | yes | GET by default, POST with post=1 or json=1 at create. |
callbacks[].url | string | yes | The full callback URL as signed for GET callbacks. |
callbacks[].content_type | string | no | Content type of a POST callback. |
callbacks[].body | string | no | Raw body of a POST callback |
callbacks[].signature | string | yes | The x-ca-signature header; it verified with the test key. |
callbacks[].fields | object | yes | The query string values and, for POST callbacks, the body fields, by name. |
{
"status": "success",
"livemode": "0",
"sink": "4f9d2c7a1b3e5f60",
"callbacks": [
{
"received_at": "2026-11-29T12:00:05Z",
"method": "GET",
"url": "https://testapi.suawave.com/sink/4f9d2c7a1b3e5f60?order=1001&nonce=7f3a9c&address_in=TDepositAddressExample0000000000&address_out=TWe5GkE5VFQwTnJ4KmcFyevwMAfosdHcEW&coin=trc20_usdt&confirmations=1&fee_coin=1.200000&livemode=0&pending=0&txid_in=4b0e3f5a9c1d2e7f8a6b5c4d3e2f1a0b9c8d7e6f5a4b3c2d1e0f9a8b7c6d5e4f&txid_out=7d6c5b4a39281706f5e4d3c2b1a09f8e7d6c5b4a39281706f5e4d3c2b1a09f8e&uuid=8c4e2a61-5b3d-47f9-a0e2-1d6c9b7f3e45&value_coin=25.500000&value_forwarded_coin=24.300000",
"signature": "kq3V...base64...==",
"fields": {
"order": "1001",
"nonce": "7f3a9c",
"uuid": "8c4e2a61-5b3d-47f9-a0e2-1d6c9b7f3e45",
"address_in": "TDepositAddressExample0000000000",
"address_out": "TWe5GkE5VFQwTnJ4KmcFyevwMAfosdHcEW",
"txid_in": "4b0e3f5a9c1d2e7f8a6b5c4d3e2f1a0b9c8d7e6f5a4b3c2d1e0f9a8b7c6d5e4f",
"coin": "trc20_usdt",
"pending": "0",
"txid_out": "7d6c5b4a39281706f5e4d3c2b1a09f8e7d6c5b4a39281706f5e4d3c2b1a09f8e",
"confirmations": "1",
"value_coin": "25.500000",
"value_forwarded_coin": "24.300000",
"fee_coin": "1.200000",
"livemode": "0"
}
}
]
}Errors
Statuses 400, 429 use the standard error body described in Errors.
Plugins and SDKs
The WooCommerce, Magento, OpenCart and PrestaShop plugins have a Test mode switch and a separate field for the test callback public key. With Test mode on they use https://testapi.suawave.com, verify callbacks with the test key, refuse production callbacks and mark new orders as test orders. Turn it off before going live, and switch only when no order is waiting for payment.
The Go and JavaScript SDKs export the test base URL and wrap both helpers (SimulateDeposit and TestDeposits in Go, simulateDeposit and testDeposits in JavaScript).
Limits of the test environment
- The environment can be reset after maintenance; create a new order if an old callback URL is no longer found.
- Simulated block times, confirmation counts and transaction hashes are not those of the real chains.
- Request limits are lower than in production.
- Callback sinks are in memory: they keep 25 callbacks per id for one hour and are emptied by a restart.
