Integrate Ozow payments
Integration guides, API reference and working code for accepting payments, issuing refunds and sending payouts in South Africa.
On this page2 sections
Build with AI 8 packages
A build package is every page for one task, with the API operations they use. Copy the prompt into a coding assistant, or hand it the package itself: slim links to each page, full inlines all of them in one document.
- Take a paymentEverything needed to take a payment end to end with One API, from credentials through the hosted page to the webhook that confirms it, and the test cases that prove each outcome before you go live.
- Embed checkout in your own pageEverything needed to keep the customer on your site while they pay, as an iframe, a modal, or the Wallet SDK for Apple Pay and Google Pay, with the notification that actually confirms the payment.
- Take a recurring paymentEverything needed to collect from a customer on a schedule with One API, from the consent the customer gives once through to each collection and the webhook that reports it.
- Migrate a payin from the Payments API to One APIEverything needed to move an existing redirect payin onto One API, with the legacy guide and its One API counterpart side by side.
New to Ozow? Start with How Ozow works: payinsPayin A payment made by a consumer to a merchant. The direction most of this site is about: money coming in. Its counterpart is a payout, which sends money out and is not tied to any payment anyone made you. and payoutsPayout Money sent from a merchant to a bank account. Unlike a refund, a payout is not tied to a payment anyone made you, so you can pay anyone with a bank account. Payouts draw on your float rather than on your incoming payments, and they are not self-service: they need approval from Ozow and testing in staging first., settlementSettlement Ozow paying the money you have collected into your bank account. Payins arrive at Ozow first and are settled to you on a schedule, so what a customer paid you today and what has been settled to you today are different amounts., and how the pieces fit together.
Ready to build? Pick a starting point:
- Accept a payment Redirect to Ozow or embed the checkout in your own page - one integration, every payment method.
- Send a payout Pay money into a bank account from your own system, with no incoming payment required.
- Install a plugin Shopify, WooCommerce, Magento and seven more, with no code to write.
- Read the API reference Endpoints, fields, parameters and error responses for every Ozow API.
Not sure which route suits you? How to integrate with Ozow compares no-code, plugins and building against the APIs.
Note
You need an Ozow merchant account before you can integrate. Not set up yet? Start with Prerequisites and onboarding, join our merchant family or speak to your account manager to get set up.
Your first payment request
This is the call that starts a payment. It returns a URL you send your customer to, and Ozow tells your webhookWebhook A URL of yours that Ozow calls when something happens, rather than you polling to find out. The call carries no credential of yours and arrives at a public URL, so authenticate it before acting on it: a hash field on the Payments API, a Svix signature on One API. how it ended.
POST https://one.ozow.com/v1/payments
Authorization: Bearer YOUR_ACCESS_TOKEN
Content-Type: application/json
curl -X POST "https://one.ozow.com/v1/payments" \
-H "Authorization: Bearer YOUR_ACCESS_TOKEN" \
-H "Content-Type: application/json" \
-d '{
"siteCode": "YOUR_SITE_CODE",
"amount": {
"currency": "ZAR",
"value": 100.00
},
"merchantReference": "ORDER-001",
"expireAt": "2026-12-31T23:59:59Z",
"returnUrl": "https://yourstore.com/order-complete"
}'
var client = new HttpClient();
client.DefaultRequestHeaders.Authorization = new AuthenticationHeaderValue(
"Bearer",
"YOUR_ACCESS_TOKEN"
);
var payload = new
{
siteCode = "YOUR_SITE_CODE",
amount = new { currency = "ZAR", value = 100.00 },
merchantReference = "ORDER-001",
expireAt = "2026-12-31T23:59:59Z",
returnUrl = "https://yourstore.com/order-complete",
};
var response = await client.PostAsync(
"https://one.ozow.com/v1/payments",
new StringContent(JsonSerializer.Serialize(payload), Encoding.UTF8, "application/json")
);
var result = await response.Content.ReadAsStringAsync();
Console.WriteLine(result);
<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://one.ozow.com/v1/payments",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_POST => true,
CURLOPT_POSTFIELDS => json_encode([
"siteCode" => "YOUR_SITE_CODE",
"amount" => ["currency" => "ZAR", "value" => 100.0],
"merchantReference" => "ORDER-001",
"expireAt" => "2026-12-31T23:59:59Z",
"returnUrl" => "https://yourstore.com/order-complete",
]),
CURLOPT_HTTPHEADER => [
"Authorization: Bearer YOUR_ACCESS_TOKEN",
"Content-Type: application/json",
],
]);
$response = curl_exec($curl);
curl_close($curl);
echo $response;
?>
const response = await fetch("https://one.ozow.com/v1/payments", {
method: "POST",
headers: {
"Authorization": "Bearer YOUR_ACCESS_TOKEN",
"Content-Type": "application/json",
},
body: JSON.stringify({
siteCode: "YOUR_SITE_CODE",
amount: { currency: "ZAR", value: 100.0 },
merchantReference: "ORDER-001",
expireAt: "2026-12-31T23:59:59Z",
returnUrl: "https://yourstore.com/order-complete",
}),
});
const data = await response.json();
console.log(data);
import requests
response = requests.post(
"https://one.ozow.com/v1/payments",
headers={
"Authorization": "Bearer YOUR_ACCESS_TOKEN",
"Content-Type": "application/json",
},
json={
"siteCode": "YOUR_SITE_CODE",
"amount": {"currency": "ZAR", "value": 100.00},
"merchantReference": "ORDER-001",
"expireAt": "2026-12-31T23:59:59Z",
"returnUrl": "https://yourstore.com/order-complete",
},
)
print(response.json())
The Authorization header carries an access token you exchange your client ID
and secret for. Quick start covers that
exchange and takes this request through to a confirmed payment.
Not writing code?
You don't need a developer to get paid with Ozow.
- Payment requests: create a link or upload a batch, send by email, SMS or WhatsApp
- Refunds: refund a transaction from the Dashboard
- Bulk payouts: upload a CSV of payouts for approval
- Plugins and Platforms: install and configure, nothing to build