Standard Checkout

The SeerBit Standard Checkout allows you to accept payments securely by calling our /payment initialize endpoint from your server to generate a checkout link which redirects your users to the generated link for them to make payment.

How it Works

When a customer clicks on a payment button on your application a POST request is made to our API. We will return a redirect link for the customer to input their payment details to complete the transaction. After payment has been made the users are redirected to your website using the callback_url

Before you begin

When a customer clicks on a payment button on your application a POST request is made to our API. We will return a redirect link for the customer to input their payment details to complete the transaction. After payment has been made the users are redirected to your website using the callback_url.

Authenticating your API calls

Key Encryption
This service allows you to generate a bearer token that will be used in authenticating your API calls to SeerBit. It expects a string of your 'merchantPrivateKey' 'merchantPublicKey' in a JSON request. SeerBit inturn returns the token in the encryptedKey field.
See sample request and response below.
Request Sample
The code snippet below shows an example request for generating a bearer token
1curl --location 'https://seerbitapi.com/api/v2/encrypt/keys' \
2--header 'Content-Type: application/json' \
3--data '{
4  "key": "YOUR_SECRET_KEY.YOUR_PUBLIC_KEY"
5}'
1var request = require('request');
2var options = {
3  'method': 'POST',
4  'url': 'https://seerbitapi.com/api/v2/encrypt/keys',
5  'headers': {
6    'Content-Type': 'application/json'
7  },
8  body: JSON.stringify({
9    "key": "YOUR_SECRET_KEY.YOUR_PUBLIC_KEY"
10  })
11
12};
13request(options, function (error, response) {
14  if (error) throw new Error(error);
15  console.log(response.body);
16});
1<?php
2
3$curl = curl_init();
4
5curl_setopt_array($curl, array(
6  CURLOPT_URL => 'https://seerbitapi.com/api/v2/encrypt/keys',
7  CURLOPT_RETURNTRANSFER => true,
8  CURLOPT_ENCODING => '',
9  CURLOPT_MAXREDIRS => 10,
10  CURLOPT_TIMEOUT => 0,
11  CURLOPT_FOLLOWLOCATION => true,
12  CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
13  CURLOPT_CUSTOMREQUEST => 'POST',
14  CURLOPT_POSTFIELDS =>'{
15  "key": "YOUR_SECRET_KEY.YOUR_PUBLIC_KEY"
16}',
17  CURLOPT_HTTPHEADER => array(
18    'Content-Type: application/json'
19  ),
20));
21
22$response = curl_exec($curl);
23
24curl_close($curl);
25echo $response;
Response Sample
The code snippet below shows an example request for generating a bearer token
1{
2    "status": "SUCCESS",
3    "data": {
4        "code": "00",
5        "EncryptedSecKey": {
6            "encryptedKey": "WquhSwMepYp6k+AIAlU1Jp18QwRWMm2SK0WVIOACIArw6ao3Ql4qKOMGwFVMvI9nOiM1xarW6qAIxE+GTOyINRVQnnFuy2EJk+DwmCgiFUuRVkOIdMBgwpJTCSzcFFfD"
7        },
8        "message": "Successful"
9    }
10}
1{
2  "message": "Bad Request",
3  "error": "There has been a problem with reading or understanding the request."
4}
1{
2  "error": "Not Found"
3}
1{
2 "message": "Internal Server Error",
3 "error": "PROCESSING"
4}

Requesting a Payment/ Initializing a Transaction

For the full specification, see our API Reference
Request Sample
The code snippet below shows an example request for generating a payment link to complete a payment
1curl --location 'https://seerbitapi.com/api/v2/payments' \
2--header 'Content-Type: application/json' \
3--header 'Authorization: Bearer YOUR_ENCRYPTED_KEY' \
4--data-raw '{
5    "publicKey": "YOUR_PUBLIC_KEY",
6    "amount": "500",
7    "currency": "NGN",
8    "country": "NG",
9    "paymentReference": "payment_reference",
10    "email": "ts@emaildomain.com",
11    "fullName": "Halil TS",
12     "tokenize": "false",
13    "callbackUrl": "https://seerbit.com"
14}'
1var request = require('request');
2var options = {
3  'method': 'POST',
4  'url': 'https://seerbitapi.com/api/v2/payments',
5  'headers': {
6    'Content-Type': 'application/json',
7    'Authorization': 'Bearer YOUR_ENCRYPTED_KEY'
8  },
9  body: JSON.stringify({
10    "publicKey": "YOUR_PUBLIC_KEY",
11    "amount": "500",
12    "currency": "NGN",
13    "country": "NG",
14    "paymentReference": "payment_reference",
15    "email": "ts@emaildomain.com",
16    "fullName": "Halil TS",
17    "tokenize": "false",
18    "callbackUrl": "https://seerbit.com"
19  })
20
21};
22request(options, function (error, response) {
23  if (error) throw new Error(error);
24  console.log(response.body);
25});
1<?php
2
3$curl = curl_init();
4
5curl_setopt_array($curl, array(
6  CURLOPT_URL => 'https://seerbitapi.com/api/v2/payments',
7  CURLOPT_RETURNTRANSFER => true,
8  CURLOPT_ENCODING => '',
9  CURLOPT_MAXREDIRS => 10,
10  CURLOPT_TIMEOUT => 0,
11  CURLOPT_FOLLOWLOCATION => true,
12  CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
13  CURLOPT_CUSTOMREQUEST => 'POST',
14  CURLOPT_POSTFIELDS =>'{
15    "publicKey": "YOUR_PUBLIC_KEY",
16    "amount": "500",
17    "currency": "NGN",
18    "country": "NG",
19    "paymentReference": "payment_reference",
20    "email": "ts@emaildomain.com",
21    "fullName": "Halil TS",
22    "tokenize": "false",
23    "callbackUrl": "https://seerbit.com"
24}',
25  CURLOPT_HTTPHEADER => array(
26    'Content-Type: application/json',
27    'Authorization: Bearer YOUR_ENCRYPTED_KEY'
28  ),
29));
30
31$response = curl_exec($curl);
32
33curl_close($curl);
34echo $response;
Response Sample
The code snippet below shows an example request for generating a bearer token
1{
2 "status": "SUCCESS",
3 "data": {
4          "code": "00",
5          "payments": {
6                       "redirectLink": "http://checkout.seerbitapi.com/#/?mid=merchantpublickey&paymentReference=643108207792124616573324",
7                       "paymentStatus": "08"
8          },
9        "message": "Successful"
10    }
11}
1{
2    "message": "Transaction Exists",
3    "error": "PROCESSING"
4}

Notes

Note that in cases where you require your customers to bear the charge for a transaction, the agreed charge should be added to the transaction amount. This charge will be deducted after the transaction is completed and the merchant settled the transaction amount.
Merchant is expected to use the redirect link returned in the repsonse to navigate to the seerBit checkout modal to continue the transaction
Need something else?
If you have any questions or need general help, visit our support page
Signup for developer update
You can unsubscribe at any time. Read our privacy policy.