iCryptoNow

เอกสารสำหรับนักพัฒนาเป็นภาษาอังกฤษ โค้ด ชื่อฟิลด์ และเส้นทาง API เหมือนกันทุกภาษา

Payment page

POST/v1/checkout-sessions

No cashier page of your own? Create a checkout session and send the player to our payment page. The player picks a network, sees their deposit address with a QR code, the minimum amount and clear warnings, watches the payment arrive, and is sent back to your site.

How it works

  1. In the console, open Developers → Integration and choose iCryptoNow payment page (2FA). Until then this endpoint answers 403 checkout_disabled.
  2. When a player wants to deposit, your server calls POST /v1/checkout-sessions with the player's player_ref.
  3. Redirect the player to the url in the response (or open it in a new tab or a webview).
  4. Credit the player when you receive the deposit.confirmed webhook, exactly as with your own cashier: deposits are matched by player_ref.

The page shows the player's usual deposit address on each network (the same one POST /v1/addresses returns), so a session never holds funds: anything the player sends to that address is credited, also after the link expired. On a network set to Standard (TRON and Ethereum), the page works differently, see below.

Create a session

FieldTypeDescription
player_refstring · requiredYour id for the player, 1–128 characters of A-Z a-z 0-9 _ . : @ -.
player_namestring · optionalThe player's username on your site, shown next to player_ref in the merchant console and returned on deposits. Display only: deposits are still matched by player_ref. Up to 64 characters, any language. Same as on Create address; send "" to clear it.
order_idstring · optionalYour reference for this deposit (same characters). Sending the same order_id again returns the same session (200), so retries are safe. Reusing it for another player gives 409 order_id_conflict.
amountstring · optionalAmount to show the player, in token units as a decimal string ("100", "25.5"). On Pro networks it is display only: whatever the player actually sends (at or above the minimum) is credited. On Standard networks it is the amount the player pays; without it, the player enters the amount on the page.
assetsstring[] · optionalNetworks to offer, for example ["bsc:USDT", "tron:USDT"]. Default: every network enabled for your account.
expires_ininteger · optionalSeconds the link stays usable, 300–86400. Default 3600.
callback_urlstring · optionalSend this session's deposit webhooks here instead of your webhook URL, for example with your own query parameters to check (?did=…). https, on the same host as the webhook URL set in the console. See Callback URL.
const { body } = await icn("POST", "/v1/checkout-sessions", {
  player_ref: "player_1024",
  player_name: "alice88",
  order_id: "DEP-20261014-0042",
  amount: "100",
});
// redirect the player to body.url
201 Created
{
  "id": "6f1c2d3e-8a9b-4c5d-9e0f-1a2b3c4d5e6f",
  "url": "https://app.icryptonow.com/pay/q8Xc2LmN4pRt6VwY0bZd3FhK",
  "status": "open",
  "player_ref": "player_1024",
  "player_name": "alice88",
  "order_id": "DEP-20261014-0042",
  "amount": "100",
  "assets": null,
  "expires_at": "2026-10-14T14:00:00.000Z",
  "created_at": "2026-10-14T13:00:00.000Z",
  "deposits": []
}

Callback URL

Pass callback_url to have this session's deposit.* webhooks delivered to that URL instead of your usual one, with any query parameters you add. It must be https and on the same host as the webhook URL in the console (set that first, or the request answers 400). Deliveries are signed with the same webhook secret, over the path and query of the callback URL, and retried the same way.

A deposit belongs to a session when it is first seen while the player has a session open (the newest one, if several); on a Standard network, it belongs to the session whose exact amount it paid. All its deposit.* webhooks then carry "checkout": { "id", "order_id" }, also without a callback URL. A deposit sent before the session or after it expired is still credited, but its webhooks go to your usual URL without checkout.

Standard networks (TRON, Ethereum)

On TRON and Ethereum each brand chooses Standard or Pro per network in the console (Vault → How players pay, 2FA); see Pricing. Pro is the way described above: every player has their own permanent deposit address. With Standard, players pay into your vault's receiving address, so there is no deposit network fee, only your rate. The funds are in your own vault either way. Nothing changes in your integration: the same session and the same url; the page handles Standard by itself.

  1. Best: let the player pick the network and enter the amount on your own site (list them with GET /v1/networks), then create the session with that amount and that one network in assets. The page opens straight on the next step. Otherwise the page asks the player for both.
  2. The page shows an exact amount to send: the amount plus a small unique number of cents, for example 100.37, and your receiving address. The player has 30 minutes; a payment that arrives up to 2 hours later is still matched.
  3. The payment is matched by that exact amount and reported once final as deposit.confirmed, with address = your receiving address and the session's player_ref and checkout. Credit the player data.amount as usual. There is no deposit.detected for Standard deposits.

The player must send exactly that amount; paying from an exchange, they add the exchange's withdrawal fee on top. The address is shared by all your players, so they should use the page every time and not save the address.

A payment with a wrong amount, after the time ran out, or sent without the page matches no order. It is not credited: you receive deposit.unmatched and the payment waits in the console under Payments waiting for you, where you assign it to a player (it then arrives as a normal deposit.confirmed) or mark it as your own top-up (vault.topup).

High-risk ("black") USDT is still detected and never credited (deposit.flagged), but it has already landed in the shared receiving address, so a freeze by the token issuer would affect that whole address. A daily transfer to your cold wallet keeps the amount held there small.

Standard needs the payment page. If you use your own cashier (POST /v1/addresses), players keep their own addresses and those deposits are priced as Pro. Payouts on a Standard network use the Standard payout price, which GET /v1/quote with direction=out returns. Other networks (BSC, Arbitrum, Base, Polygon) are Pro only.

Get a session

GET/v1/checkout-sessions/{id}

Returns the session with the player's deposits since it was created (newest first, same fields as Get deposit). Useful to show a status on your side; crediting still follows the webhooks.

Status

  • open: waiting, no deposit seen yet.
  • pending: a deposit was seen on-chain and is waiting for confirmation (deposit.detected). Not used on Standard networks, where a payment is reported once final.
  • completed: a deposit was confirmed and credited (deposit.confirmed).
  • expired: the link ran out with nothing seen. Deposits sent later to the player's address are still credited (on Standard: a payment of the quoted amount within its 2 hours).

What the player sees

  • Your brand name, the amount and order id (when given), and the networks with their minimum amount; BEP20 is marked as the cheapest.
  • After choosing: the deposit address with QR code and copy button, "send only USDT on this network" and "below the minimum is not credited automatically" warnings.
  • On a Standard network: first the amount (unless the session has one), then the exact amount to send with a 30-minute countdown, and the warnings "send exactly this amount", "from an exchange, add its withdrawal fee" and "use this page every time, don't save the address".
  • Live status (the page polls every few seconds): waiting → received, confirming → complete, then the player is sent back to your site automatically (the page they came from, on whichever domain or mirror). A deposit below the minimum shows a message to contact your support.
  • English by default; ten languages (the player can switch, the choice is remembered). To open it in the player's language, add ?lang=zh to the url (en zh zh-hant th vi id hi ne bn ur). Phone-first layout.

Errors

  • 400 bad_request: a field is missing or invalid (the message says which).
  • 403 checkout_disabled: the payment page is not chosen for this brand in the console.
  • 404 asset_not_enabled: a network in assets is not enabled for your account.
  • 409 order_id_conflict: the order_id belongs to another player.
สมัครเลย