Skip to main content

Developer Documentation

Window Checkout

Getting Started

This is perhaps the simplest way to integrate Billwerk+ Payments Checkout. Simply initialize it once a payment session have been created. This will automatically redirect the client to the Billwerk+ Payments Checkout Window, within the same browser tab.

  1. Include the Billwerk+ Javascript SDK.

    HTML include the reepay javascript SDK

    <script src="https://checkout.reepay.com/checkout.js"></script>
  2. Open Checkout as a window.

    Window Initialise using the reepay Javascript SDK

    var rp = new Reepay.WindowCheckout(' YOUR SESSION ID HERE ');

Note

Notice that for Subscription sessions the method name is WindowSubscription.

Window initialize for subscription sessions

var rp = new Reepay.WindowSubscription(' YOUR SESSION ID HERE ');

Events

Events will be fired directly to the Accept and Cancel URLs provided in the session create request as GET parameters, like so :

HTTP

GET https://yourdomain?id=<the current session id>&invoice=<invoice/charge handle>&customer=<customer handle>&payment_method=<payment method ID stored in Reepay for recurring session or charge session with recurring flag>

Parameter

Type

Description

id

string

The current session id

invoice

string

Invoice/charge handle (charge session)

customer

string

Customer handle

subscription

string

Subscription handle (subscription session)

payment_method

string

Payment method if a new one is created (recurring session or charge session with recurring flag)

error

string

Potential error code on cancel url