Accepting payments with PayHot
A step-by-step guide: connect PayHot to CreateYourVPN so your clients top up their balance by any amount by card, SBP or cryptocurrency. Application, API key, webhook, payment methods and auto top-up.
PayHot accepts payments by bank card, SBP and cryptocurrency. Your clients use it to top up their balance in the cabinet on your storefront, and they buy plans from that balance: you don't have to grant anything by hand.
With PayHot the client enters the amount, both for a one-time top-up and for an auto top-up. You don't have to set up top-up amounts. If you do, PayHot sells them too, and the client sees them as buttons above the amount field. lava.top works with fixed amounts: the client can only pick one of yours.
The money goes to the balance of your project in PayHot. CreateYourVPN is not a middleman in the payments and takes no commission on your sales.
Accepting payments is available on the paid Max tier: on it your storefront starts selling, and the customer balance turns on by itself. See the billing lesson for platform pricing.
What you'll need
- the Max tier in CreateYourVPN;
- an approved application in PayHot: approval takes a few days, so apply in advance;
- about 15 minutes for the setup once you're approved.
Step 1. Apply
Submit an application to connect on the PayHot website. Approval takes a few days. PayHot decides who can accept payments through it and which documents that takes.
Step 2. Issue an API key
Once your application is approved, you can sign in to the PayHot dashboard. Issue an API key for CreateYourVPN there. If PayHot asks for the key's term and permissions, choose the term "Unlimited" and the "Payments" and "View" permissions: when a key expires, sales stop.
Don't give the key any other permissions, especially payouts. A key with the payouts permission can move money from the balance of your project in PayHot to someone else's card. CreateYourVPN doesn't need payouts: we only create payments and check their status.
Step 3. Connect PayHot in CreateYourVPN
In CreateYourVPN, open the "Monetization" section, click "Connect" on the PayHot card, paste the key into the "PayHot API key" field and click "Connect". The key is checked automatically: if everything is fine, you'll see "PayHot accepted the key".
The card shows the "Webhook URL". Copy it with the "Copy" button, paste it in the PayHot dashboard into the Webhook URL · Production field and save.
After you save, PayHot shows the signing secret once. Copy it, paste it into the "Webhook signing secret (optional)" field under the address on the PayHot card and click "Save".
With the webhook, PayHot tells us about payments and refunds right away, and the card shows the date of the last webhook. Without the webhook and the signing secret, payments are still confirmed: we check them in PayHot ourselves, just later. But without the webhook we never learn about refunds.
Leave the "Accept payments" checkbox on the card on. You can check the key again later: open the card with "Manage" and click "Check key".
Step 4. Turn on payment methods
Make sure the payment methods you need are turned on in the PayHot dashboard: bank cards, SBP, cryptocurrency. Clients only get the methods turned on in PayHot.
On the PayHot card in CreateYourVPN, in the "Payment methods" block, keep the same methods ticked: "Russian cards (₽)", "International cards (€)", "SBP" and "Cryptocurrency". All of them are ticked by default. Untick a method that isn't turned on in PayHot and click "Save": otherwise the client sees the method but can't pay with it.
Step 5. Balance top-ups
You don't need to set anything up in your plans: the client buys them from the balance, and PayHot tops the balance up. The exception is a plan priced in another currency and tied to PayHot earlier: the client pays for it through PayHot directly.
One-time top-up
In the cabinet on your storefront, the client clicks "Top up" and enters the amount in the "Amount" field. Above the field, your amounts from the "Balance top-ups" block on the "Plans" page appear as buttons, if you've added any. An amount can be anything, PayHot doesn't need a lava.top offer: in the amount dialog the cabinet tells you which methods PayHot sells it with.
If the client is short of money for a plan, they click "Top up and buy", and the first amount we suggest is exactly the shortfall, but no less than the minimum payment: the client can top up and buy the plan in one payment.
A method in the customer account currency charges exactly the amount entered. Other currencies, for example an international card in euros or cryptocurrency for an account in roubles, are converted at the rate of your PayHot cash desk; if the cash desk has no rate, cards and SBP use the Bank of Russia rate. The client sees the amount to pay on the "Pay" button, and the balance receives the amount entered. Cryptocurrency is paid in USDT on the TRON network (TRC-20). For an account in dollars there's no international card: PayHot takes a Russian card and SBP in roubles, and cryptocurrency.
PayHot has a minimum payment: 100 ₽ by Russian card or SBP, 5 € by international card and 10 USDT in cryptocurrency. If the client enters less, a hint appears under the field, for example "Minimum amount is ₽100.". A method whose minimum is above the amount is hidden from the client: cryptocurrency shows up only once the amount reaches 10 USDT at the cash desk rate.
Auto top-up
On the "Automatic" tab, the client enters an amount and "Every how many days" to charge it, from 1 to 365. If you also have lava.top auto top-ups, this is the "Custom amount and frequency" row. The client makes the first payment right away, after that we charge the same amount to the linked card or SBP account every chosen number of days, and every charge tops up the balance.
An auto top-up works together with auto-renewal of the plan from the balance: auto-renewal turns on by itself when the client connects the auto top-up, and if the client has no plan yet, the first charge buys it. A client has one auto top-up: through PayHot or through a lava.top subscription.
For auto top-up through PayHot to work:
- you need a subscription plan with a term and a price in the customer account currency: without one, the client has no "Automatic" tab;
- the customer account currency must be roubles, and the connection must have "Russian cards (₽)" or "SBP" ticked: only these can be charged;
- the key must be live, there's no auto top-up in test mode;
- recurring charges must be enabled in your PayHot cash desk. PayHot enables them on request: write to your PayHot manager. If they ask how a client unlinks the card, here's the answer: in the cabinet on your storefront, the auto top-up has a "Turn off" button that unlinks the card or SBP account;
- the PayHot cash desk fee must be on you, not on the client, otherwise the link isn't created.
If the cash desk refuses the link, the client sees "Auto top-up can't be turned on right now. You can still top up without it.", and that method disappears from auto top-up for a day. Once you've set up the cash desk, save the PayHot connection in the Monetization section, and the method comes back right away.
The client turns the auto top-up off on their own, with the "Turn off" button in the cabinet on your storefront. If they turn off auto-renewal of their plan, the auto top-up turns off with it. To turn off auto top-ups for all clients at once, use the "Close subscriptions" button on the PayHot card: the linked cards and SBP accounts are unlinked, and the money on the balances stays.
Step 6. Check a payment
From a client account on your storefront, top up the balance by the minimum amount, which is 100 ₽ for an account in roubles. The money should appear on the balance, and the top-up should get the "Processed" status in the Monetization section, in the "Payment journal" block. With the webhook this usually takes up to a minute, without it longer.
You can check without real money using a PayHot test key (it starts with phk_test_v2_): paste it into the card instead of the live one. The payment goes through PayHot's test page and appears in the journal with the "test" mark, and the balance doesn't change. With a test key, only the methods in the customer account currency remain, with no cryptocurrency and no auto top-up. While the test key is in place, all your clients pay in test mode and see no warning about it: test before you start selling and paste the live key back right away.
Money matters
- Payments go to the balance of your project in PayHot. PayHot charges its fee on its own terms; CreateYourVPN adds none.
- Refunds are made in PayHot: in the PayHot dashboard or through its support. If the webhook and the signing secret are set up, the top-up gets a "Top-up refund" note in the journal; without them, keep track of refunds in PayHot yourself. The client's balance doesn't go down by itself after a refund: deduct the same amount with an adjustment in the client's card.
If the key leaks
Reissue the API key in PayHot: the old key stops working immediately. Then paste the new key into the PayHot card in the Monetization section and save.