Hosted Payment
Hosted Payment is ZenPay's integrated checkout solution. Your frontend initialises the Hosted Payment Page (HPP) with $.zpPayment(...) using values prepared by your backend, then launches the ZenPay-hosted payment experience either in a modal iframe or via full-page redirect.
- the HPP script is the launcher
- the hosted payment page is the payment UI
- your backend is the source of trust

When to use Hosted Payment
- Your site or app needs to launch ZenPay checkout
- You want ZenPay to host the payment UI and handle sensitive data
- You want modal or redirect flexibility
- You want your backend to remain responsible for trust and payment state
Other ways to take payments
- Use Payment Links when you want a hosted payment link without building an embedded integration.
- Use the REST API when you need backend-only server-to-server payment operations.
To debug fingerprints, return URLs or validation issues, use the developer tools.
The payment journey (high-level flow)
- Your frontend requests payment bootstrap data from your backend
- Your backend generates the fingerprint and prepares the payment payload
- Your backend returns safe bootstrap data to the frontend
- Your frontend initialises
$.zpPayment(...)and launches the HPP - The customer completes payment on the ZenPay-hosted UI
- ZenPay redirects the customer back to your site
- If you supplied a
callbackUrl, ZenPay sends a server-to-server callback to it - Your backend validates the callback before confirming the result

Trust model: who's responsible for what
This split is the reasoning behind the fingerprint, the payload, and the callback validation.
Browser responsibilities. The browser should:
- Request bootstrap data from your backend
- Initialise
$.zpPayment(...) - Launch the payment flow
- Show pending, success, failed, or cancelled UI states
- Handle return-page UX
The browser must not:
- Generate the fingerprint
- Contain merchant secrets
- Verify the callback
- Treat redirect query parameters as the only source of truth
Backend responsibilities. Your backend should:
- Hold ZenPay credentials securely
- Generate the fingerprint server-side
- Create a fresh
merchantUniquePaymentIdandtimestampper attempt - Receive and validate callbacks
- Update local payment state
- Return authoritative payment status to the frontend
Playground
Experiment with HPP options in the Playground without building a full integration first, and see how each option changes the code.