Integration Guide

COPYandPAY Integration Guide

COPYandPAY was the first SAQ-A compliant payment-form solution, making it both secure and simple-to-integrate.

There are just three simple steps required to integrate:


How it works

Prepare the checkout

Send the request parameters server-to-server to prepare the payment form.

Create the payment form

Display the payment form on your checkout page and the shopper submits their payment information.

Get the payment status

Find out if the payment was successful.


1. Prepare the checkout

First, perform a server-to-server POST request to prepare the checkout with the required data, including the order type, amount and currency. The response to a successful request is a JSON string with an id, which is required in the second step to create the payment form.

For a full list of parameters that can be sent in the prepare checkout request, please see the API Reference

2. Create the payment form

To create the payment form you just need to add the following lines of HTML/Javascript to your page and populating the following variables

  • The checkout's id that you got in the response from step 1
    <script src="https://test.oppwa.com/v1/paymentWidgets.js?checkoutId={checkoutId}"></script>
  • The shopperResultUrl, which is the page on your site where the customer should be redirected to after the payment is processed and the brands that will be available.
    <form action="{shopperResultUrl}" class="paymentWidgets">VISA MASTER AMEX</form>

View the customization guide for more information on customizing the payment form.

3. Get the payment status

Once the payment has been processed, the customer is redirected to your shopperResultUrl along with a GET parameter resourcePath.

Important: The baseUrl must end in a "/", e.g. "https://test.oppwa.com/".

Then, to get the status of the payment, you should make a GET request to the baseUrl + resourcePath, including your authentication parameters.

Example of a resourcePath:

resourcePath=/v1/checkouts/{checkoutId}/payment

We recommend that you verify the following fields from the Payment Status response, by comparing the returned values with expected:

  • ID(s)
  • Amount
  • Currency
  • Brand
  • Type

Show all supported brands

BrandAsync / sync workflow

Backoffice operations

COPYandPAY is used to securely accept the payment data. Once the payment data has been processed you can perform refunds or other backoffice operations by following our backoffice operations guide.