Pay Tv
The Pay TV feature is a user-friendly feature that empowers individuals and businesses to effortlessly manage and pay TV bills for both themselves and their clients. Streamlining the payment process, this feature provides a centralized platform where users can conveniently settle multiple TV subscriptions in one place. With secure payment options and an intuitive interface, staying on top of TV bills has never been easier.
Pay Tv Request Parameters
To intergrate to the Pay Tv feature, so as to allow users to make tv subscription payments, the following parameter are required.
Parameter | Type | Required? | Description |
---|---|---|---|
secret_key | string | yes | The secret key of your Lipila account |
amount | double | yes | Amount being paid to the Tv service provider |
accountNumber | string | yes | Account Number for the recepient |
externalId | string | no | The external ID of the payment (optional) |
narration | string | no | Brief transaction description |
billType | string | yes | TV Service Provider(e.g DStv, GoTv) |
The Table below shows the different bill types based on the Tv Service provider
Tv Service provider | billType value |
---|---|
DStv | DStv |
GoTv | GoTV |
Top Star | TopStar |
To initialize the payment transaction, you need to pass the parameters in form of a request and sent to thee Paytv endpoint. The table below lists the full parameters for initializing a payment request.
Below is a sample snapshot of the Pay Tv request and the request Url.
curl -X 'POST' \
'https://lipila-uat.hobbiton.app/transactions/bills/pay-tv' \
-H 'accept: application/json' \
-H 'Authorization: Bearer YOUR_SECRET_KEY' \
-H 'Content-Type: application/json' \
-d '{
"billType": "DStv",
"externalId": "string",
"narration": "string",
"amount": 1,
"phoneNumber": "26096234057",
"accountNumber": "string"
}'
Make sure to replace YOUR_SECRET_KEY with your Lipila secret key. s
Pay TV Response
Once the payment request has been submitted, the API processes the transaction. Based on the result of the process, the API returns a response to the client. Below is a table of the data sent in a Pay TV response.
Field | Type | Description |
---|---|---|
status | string | The status of the transaction |
message | string | The message of the transaction |
transactionId | string | The transaction ID of the transaction |
externalId | string | The external ID of the transaction |
amount | double | Amount paid to the service provider |
accountNumber | string | Account being paid for |
accountHolderName | string | Name of Account Holder |
Response Status Codes
Code | Description |
---|---|
201 | Purchase Successful |
400 | Invalid / Bad Request- Check to verify that the required data is being sent in the right formats |
401 | UnAuthorized- Check to verify that you are sending the correct API key. |
500 | Internal Server Error- Contact Support |
Below is an example of a Transaction sent for processing response:
{
"status": "Pending",
"message": "Transaction sent for processing",
"transactionId": "123456789",
"externalId": "32142",
"amount": 1.0,
"token" : "xxxxxxx"
}