Payment

In the Sentinal system, a payment refers to a payment instruction a client is needing to make using an approved Payment Provider.

Create payment

POST /v1/payment/createPayment

This endpoint allows clients to submit a payment for processing to their associated processor that is approved by the Sentinal system. The payment will be associated with a transaction that will be processed by the Sentinal system.

Headers

Name
Type
Description

x-api-key*

string

Request Body

Name
Type
Description

ref*

string

External reference

totalAmount*

number

countryCode*

string

currency*

string

redirectUrl*

string

provider*

string

FLUTTERWAVE | KORA

customer*

object

An object containing the customer details. An email is required, and you can also pass a name and phoneNumber

Code sample: JavaScript (Node.js) using Axios

const axios = require('axios');

const paymentData = {
  ref: 'unique_reference_number',
  totalAmount: 100.00,
  countryCode: 'NG',
  currency: 'NGN',
  redirectUrl: 'https://example.com/redirect',
  provider: 'FLUTTERWAVE', // Can be 'FLUTTERWAVE' or 'KORA'
  customer: {
    email: '[email protected]',
    name: 'John Doe',
    phoneNumber: '+11100099998'
  }
};

axios.post('https://api.sentinal.network/createPayment', paymentData, {
  headers: {
    'x-api-key': 'your_client_api_key'
  }
})
.then((response) => {
  console.log('Payment Link:', response.data.content.link);
})
.catch((error) => {
  console.error('Error:', error.response ? error.response.data : error.message);
});

Last updated