Skip to main content

In-app checkout

Most sellers do not need this: link your download page to your Licensr buy page and you are done. Use in-app checkout only if you want a Buy button inside your product.

POST /v1/billing/checkout needs a full-access API key, not a Client key, so call it from your own server and never embed that key in a distributed product. It returns { "checkout_url": "..." }. Open that link in the customer's browser.

After payment Licensr creates the license and emails the key. You do not set up payment webhooks. The customer pastes the key into your license screen as usual.

See the checkout endpoint for the request fields.

Custom return pages​

By default the customer returns to Licensr's own "thank you" and "cancelled" pages after paying. To send them back to your website instead, pass success_url and cancel_url in the checkout request.

Each URL must use https and its website must be listed on the product, otherwise the request fails with 403 redirect_not_allowed:

  • Browser products: add the website under Advanced options → Allowed websites.
  • Native products (desktop apps, WordPress and other server-side code): add the website under Advanced options → Checkout return websites.

List each website as https://host[:port] with no path. * is not accepted for return pages.