Skip to content
HisarPay
  • Industries
  • Published:
  • Reading time: 5 min read
  • Türkçe oku

Selling online courses for crypto, from enrolment to access

Taking the money is the easy part of selling a course. You also want to know who paid, open the lesson for the right person and find the records when the term is over. This article builds the whole path, using a small colour-grading school as the example.

On this page
  1. Choose your way first: links or the API
  2. Enrolment without code
  3. One link per module
  4. Opening access when the payment is final
  5. Enrolling with a QR code on a live stream
  6. Payment buttons in WordPress
  7. Write the refund terms in advance
  8. What to have at the end of term
  9. Frequently asked questions

Choose your way first: links or the API

Both open the same payment page. What differs is who matches the payment to the student.

TopicPayment linkInvoice through the API
Setting upA few minutes in the dashboard, no codeA little development on your site
Matching the studentBy hand, from your formAutomatic, by enrolment number
Opening accessYou do itYour system does, on a webhook
SuitsA few dozen students a termPlatforms that enrol all year

A payment through a link tells you which module was sold; if the link asks for a name and an e-mail address, the invoice also says who paid. If you have an enrolment form of your own, the flow below matches the two with a single number.

Enrolment without code

  1. The student enters a name, an e-mail address and the module in the form on your site.
  2. The last page of the form has that module’s payment link. Pressing the button opens a fresh invoice, and the student picks a coin and pays.
  3. Once the payment is final, the “Receipt no” on the PDF receipt is the full invoice number. Ask the student to enter it in a second field or to send it in reply to your e-mail.
  4. Type the whole number into the dashboard search. If the status is paid, open the module. What counts is the status in the dashboard, not a picture of the receipt.
Holding placesCount a place as taken when the payment is final, not when the form arrives. If you say up front that unpaid forms lapse after 24 hours, the waiting list looks after itself.

Splitting an eight-week programme makes the student’s risk smaller, and any refund discussion with it. An example:

ModulePriceWhen the link is shared
1. Reading scopes$39On the course page, public
2. Skin tones$49By e-mail to those who finished module 1
3. Matching shots$59In the last lesson of module 2
Feedback sessionOpen amount from $10All term, for anybody

The lowest amount on a link is $10. When enrolment closes, pause the link instead of deleting it; next term you update the price and reopen the same address. Mention the customer’s costs on the course page: the 1 USDT network fee on USDT, and the 0.4% commission if you pass it on.

Price in dollars. The amount locks when the student picks a coin, while TRX you have received moves with the market until you withdraw it. If you pay teachers in dollars, limiting the link to USDT keeps the sums simple; see rate locks.

Opening access when the payment is final

If your site can run code, nobody has to copy a number. Create an invoice when the enrolment is saved and put its number in order_id. The invoice.paid event that follows a final payment carries it back:

Create the invoice, open the lesson once it is paidTypeScript
// when the enrolment form is submitted
const invoice = await hisarpay.invoices.create({
  price_usd: '49.00',
  order_id: 'enrol-318-skin-tones',
  description: 'Module 2: Skin tones',
  success_url: 'https://school.example/welcome',
});

// webhook: the body has to be read raw
app.post('/webhooks/hisarpay', express.raw({ type: 'application/json' }), async (req, res) => {
  const event = HisarPay.webhooks.constructEvent(
    req.body,
    req.headers['x-hisarpay-signature'],
    process.env.HISARPAY_WEBHOOK_SECRET!,
  );
  if (event.livemode && (event.type === 'invoice.paid' || event.type === 'invoice.overpaid')) {
    await academy.openAccess(event.data.invoice.order_id);
  }
  res.sendStatus(200);
});

Make openAccess safe to call twice, because events can be repeated. After an invoice expires use a new order_id, for example with an attempt number, since the same one returns the old invoice. And do not treat a visit to the welcome page as proof. Webhook signatures covers errors, test mode a safe rehearsal.

Enrolling with a QR code on a live stream

At the end of an open lesson, show the link’s QR code (PNG) and stay on that scene for at least two minutes. Post the address in the chat and the description as well: somebody watching on a phone cannot scan their own screen. A separate link per stream shows how many enrolments each brought, under Payments. If the recording stays online, pause the link when the offer ends.

Payment buttons in WordPress

With the WordPress payment buttons plugin, one line on the lesson page is enough. Use a link you prepared in the dashboard and the statistics gather under that module:

Replace the slug with the one of your own link
[hisarpay_button link="pl_7kQm2xPaW4" style="card" label="Join module 2"]

Write the refund terms in advance

A crypto payment cannot be reversed; you send refunds from your balance. Your text should answer four questions: until when, how much, in which coin, to which address? A starting point:

Sample wording“If you cancel at least 48 hours before a module begins, we send its dollar price in USDT to the TRON (TRC20) address you give us in writing. The network fee is not refunded. Recorded lessons that have been watched are not refundable.”

The periods are only examples; consumer law may ask more of you, so check with a lawyer. As the smallest withdrawal is worth $10, smaller refunds may have to become credit. The steps are in our article on refunds.

Cover late payments too. Money sent to an expired invoice is credited and flagged as late; if the class is full by then, ask whether the student prefers next term or a refund.

What to have at the end of term

  • The enrolment list: name, e-mail, module, invoice number.
  • The invoices as CSV or Excel: date, order number, dollar amount, coin, amount paid, description.
  • Withdrawals for refunds, with the enrolment number in the note.

HisarPay does not issue tax invoices; ask your accountant which documents you need. Accounting exports explains the files.

Frequently asked questions

Can I sell in instalments?
There are no automatic instalments. The closest thing is to split the programme into modules with a link each.
Does the lesson open if a student sends too little?
Not if the shortfall is beyond your tolerance: the invoice becomes partially paid and invoice.paid is not sent. Access opens once the rest reaches the same address.
How long until a payment is final?
20 confirmations after it appears on the network, about a minute. Tell people who join at the last moment.
Can a company pay for a group?
Yes. Create one invoice for the total, name the company in the description and keep the participant list in your own form.
  • #Online education
  • #Payment links
  • #Webhooks
  • #WordPress

Try crypto payments in test mode

No setup or monthly fees. Experiment as much as you like in test mode and go live when you are ready.

More guides that go well with this one.