Bill Payment
Bill payment endpoints for Switch
Get vendor's plan
GET
https://switch-api-staging.herokuapp.com/user/bills/vendors/:id/plans
This endpoint retrieves a particular vendor's plan
Path Parameters
id
string
the id of the vendor
Headers
SWI-CID
string
Client ID
Make Payment
POST
https://switch-api-staging.herokuapp.com/bills/pay
This endpoint makes payment to a particular vendor plan
Headers
SWI-CS
string
Payload checksum
SWI-CID
string
Client
Authorization
string
Format is Bearer token
Request Body
string
Required if user's 2fa is pin.
otp
string
Required if user's 2fa is phone or google_authenticator.
custom_cron
string
The number of days if the event_pattern is custom
event_pattern
string
The repeating pattern. Values can be monthly, weekly or custom
repeat
boolean
Shows if a scheduled bill should be repeatable
start_date
string
This is a date time parameter. It is the start date to schedule a bill payment
save_information
boolean
Boolean flag that determines if the bill information is to be saved
category_id
string
category id of the plan
mandate_id
string
mandate_id of the plan
item_fee
string
item fee of vendor, used to calculate the total amount
plan_name
string
name of plan
plan_id
string
id of the plan
vendor_id
string
id of the vendor
consumer_id_field
string
the customer's device number
amount
string
cost of plan in Naira
payment_code
string
code for making payment
total
string
total cost in Naira
vat
string
vat on the plan
Bills Payment Categories
GET
https://switch-api-staging.herokuapp.com/user/bills/categories
Retrieves all available categories
Headers
SWI-CID
string
Client ID
Authorization
string
Format is Bearer token_string
Get vendors in a category
GET
https://switch-api-staging.herokuapp.com/user/bills/categories/:id/vendors
This endpoint retrieves all the vendors in a category.
Path Parameters
id
number
The id of the category to filter its vendors
Query Parameters
short_name
string
The short name of the vendor.
Headers
SWI-CID
string
Client ID
Bill Payment Vendors
GET
https://switch-api-staging.herokuapp.com/user/bills/vendors
This endpoint retrieves all bill payment vendors
Query Parameters
short_name
string
The short name of the vendor.
Headers
SWI-CID
string
Client ID
Authorization
string
Format is Bearer token
Saved Bill Payment Information
GET
https://switch-api-staging.herokuapp.com/user/bills/saved_bills
This endpoint retrieves all the saved bill payment information.
Query Parameters
per_page
number
number of bill payment info per page
page
number
page number
Headers
SWI-CID
string
Client ID
Authorization
string
Format is Bearer token
Delete a saved bill
DELETE
https://switch-api-staging.herokuapp.com/user/saved_bills/:id
This endpoint deletes a saved bill.
Path Parameters
id
number
the identifier of the saved bill
Headers
SWI-CID
string
Client ID
Last updated
Was this helpful?