Copy and pay API is a secure way to easily integrate card acceptance into your website without the need to worry about PCI compliance.
Here is the copy and pay documentation: https://peachpayments.docs.oppwa.com/tutorials/integration-guide
- How to add and save cards with copy and pay
- How to query transaction status if checkout ID expires
- How to Tokenize cards using the peach payments API. (NB, tokenization only works with the API here)
Steps do complete Copy and Pay integration:
1) Create a checkout to get the Checkout ID:
In the server to server call, the response has a checkout ID (Highlighted below). THe checkout id is a session id and expires after 30mins. You don't need to store this ID. Use it to initialize the payment widget in step 2 below.
If you need to tokenize the card, add the below parameter in this checkout request:
Also make sure you add a transaction ID in the request:
merchantTransactionId = 123445 or $orderID
API reference here: https://peachpayments.docs.oppwa.com/reference/parameters
2) Use Checkout ID to Initialise our Secure payment Widget:
<form action="https://www.someredirecturl.com" class="paymentWidgets" data-brands="VISA MASTER AMEX"></form>
3) Query Transaction Status:
Once the transaction is completed, you do a GET request to get transaction status and redirect shopper to the shopperResultUrl.
If you add createRegistration =true in the initial checkout request, you should recieve a token (Registration id) in the response.
You can use the registration ID for recurring subscriptions using our recurring API or once click payments.
Recurring API docs: https://peachpayments.docs.oppwa.com/tutorials/manage-payments/recurring
Once Click payment docs: https://peachpayments.docs.oppwa.com/tutorials/integration-guide/one-click
If you have further questions, please contact firstname.lastname@example.org