- Getting Started
- Primeiro Pay
- Standalone 3D Secure
- Mobile SDK
- First Integration
- Set Up Your Server
- Ready-to-Use UI
- SDK & Your Own UI
- 3D Secure 2.x
- Apple Pay
- Google Pay
- Klarna Payments
- Manage Payments
- API Reference
- Basic Payment
- Card Account
- Virtual Account
- Bank Account
- Billing Address
- Shipping Address
- Recurring Migration
- 3D Secure
- Custom Parameters
- Async Payments
- Webhook notifications
- Response Parameters
- Card On File
- Result Codes
- Brands Reference
- API Reference
Set Up Your Server
To start working with our SDK, you should expose two APIs on your backend for your app to communicate with:
- Endpoint 1: Preparing the checkout,
- Endpoint 2: Getting result of payment.
Prepare the checkout
Perform a server-to-server POST request to prepare the checkout with the required data, including the payment type, amount and currency. The response to a successful request is a JSON string with the checkout ID (see
"id" in example below), required in the second step to make the transaction.
For a full list of parameters that can be sent in the prepare checkout request, see the API Reference.
Notifications are recommended for merchant server to have relevant data about payment status all the time. This would make the server independent of possible problems with the application (like bad Internet connection or crashes) during the checkout process.
We send an HTTP GET request to the
notificationUrl with the following information:
Make accessible endpoint through the Internet in order to receive this request. This endpoint would be used as your
resourcePath is a path (starting with
/) which is related to the server URL. You must call it to get the information about the notification:
Get the payment status
Once the payment has been processed, your app receives the callback from the mobile SDK.
Then, to get the status of the transaction, you should make a GET request to the
baseUrl + resourcePath, including your authentication parameters.
Important: The baseUrl must end in a "/", e.g. "https://test.oppwa.com/".Get
resourcePathfor specific transaction using mobile SDK. The app should send
resourcePathto your server.
- If you use SDK with ready-to-use UI,
resourcePathwill be returned in callback after submitting a transaction.
- If you use core SDK with your own UI, you will have to request checkout info from the server (SDK provides convenience API for this request).
We recommend that you verify the following fields from the Payment Status response, by comparing the returned values with expected:
Test Your Server
Your can find the values for the sandbox testing account in our Testing Page. To verify your integration, check the transactions in the BIP, where they will appear in real-time.
NOTE: Your need to develop and test your code against your sandbox account before processing live transactions against a production account.
Go to production
When you are ready to start charging real money, transition over to our production environment. At this point, your should be able to generate the checkout and obtain the payment status in the sandbox.