Skip to main content

Prerequisites

  • You have completed onboarding and received a client_token and widget_id.
  • You have a backend server whose IP is registered with Proof.
  • You have a partner_user_id (your internal, stable user identifier) and the user’s email.
  • You know which network and currency the user wants to transact in (e.g. TRC20 + USDT).

Step 1 — Request a session from your backend

Your frontend calls your own backend. Your backend calls POST /widget/session with the client_token (kept server-side) and the user’s real IP in client_ip.
Response:
Save merchant_transaction_id — you use it everywhere downstream (polling, WebSocket, webhook).
Your backend returns the session parameters to the frontend (minus the client_token, which never leaves your server). For the full request and response field reference, see POST /widget/session.

Step 2 — Embed the widget

Your frontend receives the session parameters from your backend and passes them directly to proofWidget.run(). No client_token is needed on the frontend.
The widget renders inside #proof-widget. The user completes identity verification (first time) and payment inside the widget.

Step 3 — Track transaction status

All status calls use your client_token and must go through your backend. Pick one of three delivery channels:

Polling (from your backend)

Poll every 5–10 seconds while status is pending or processing. Stop on completed, failed, or cancelled. See GET /widget/transactions/{id}.

WebSocket (from your backend)

One connection subscribes to one merchant_transaction_id. See WebSocket for details and reconnection patterns.

Outbound webhook

If you provided a webhook_url at onboarding, Proof POSTs the normalized transaction event to that URL on every status change. See Partner Webhook.

Full example


Next steps

Transaction Status

Polling, WebSocket, and webhook delivery in detail.

Off-Ramp (Sell)

Enable sell flow for your users.

Mobile

iOS and Android setup for camera and payments.

Error Handling

Real error codes and how to handle them.