List payment channels
GET
/api/v2/payment_channels
const url = 'https://api.payhero.africa/api/v2/payment_channels';const options = {method: 'GET', headers: {Authorization: 'Basic <credentials>'}};
try { const response = await fetch(url, options); const data = await response.json(); console.log(data);} catch (error) { console.error(error);}curl --request GET \ --url https://api.payhero.africa/api/v2/payment_channels \ --header 'Authorization: Basic <credentials>'List the external channels (bank, Till, Paybill, or wallet) configured on
your account. Use the id of an active channel as the channel_id
when creating a Payment Channel collection.
Authorizations
Section titled “Authorizations”Responses
Section titled “Responses”The account’s payment channels.
Media typeapplication/json
object
payment_channels
Array<object>
An external channel (bank, Till, Paybill, or wallet) on your account.
object
id
Channel ID — use as channel_id in a Payment Channel collection.
integer
transaction_type
M-Pesa transaction type.
string
channel_type
string
account_id
integer
short_code
Till / Paybill / bank paybill number.
string
account_number
Destination account (for bank / paybill channels).
string
description
string
is_active
Only active channels can be used in a collection.
boolean
created_at
string format: date-time
updated_at
string format: date-time
pagination
object
count
integer
page
integer
per
integer
num_pages
integer
next_page
integer | null
prev_page
integer | null
Example
{ "payment_channels": [ { "id": 8949, "account_number": "1234567890", "channel_type": "bank", "is_active": true, "short_code": "123456", "description": "My Bank Account", "created_at": "2026-01-15T10:00:00Z", "updated_at": "2026-01-15T10:00:00Z" }, { "id": 1501, "account_number": "0700111222", "channel_type": "wallet", "is_active": true, "short_code": "100200", "description": "My Wallet", "created_at": "2026-01-15T10:00:00Z", "updated_at": "2026-01-15T10:00:00Z" } ], "pagination": { "count": 2, "page": 1, "per": 20, "num_pages": 1, "next_page": null, "prev_page": null }}Missing or invalid Basic auth credentials.
Media typeapplication/json
object
error_code
string
error_message
string
status_code
integer
Example
{ "error_code": "invalid_argument", "error_message": "the transaction amount is insufficient as it wont cater for cost: (4.62)", "status_code": 400}
