v1

latestOpenAPI 3.1.02026-07-2691531.2 KB
Payment Channels

Create payment channel

Registers an M-Pesa shortcode (Paybill or Till Number) as a payment channel. You can pass a channelId when initiating STK Push to route the payment through a specific shortcode.

Mark a channel as isDefault: true to use it automatically when no channelId is specified in payment requests.

post/payment-wallet/channels

Request body

namestring required

Human-readable label for the channel.

type'PAYBILL' | 'TILL_NUMBER' | 'SEND_MONEY' required
shortcodestring required

M-Pesa shortcode (Paybill number or Till number).

accountNumberstring nullable

Account number for Paybill channels (not used for Till).

isDefaultboolean

Set this channel as the default for payment requests that do not specify a channelId.

Example request

{
  "name": "Main Collections Paybill",
  "shortcode": "123456",
  "accountNumber": "ACCOUNT001"
}

Response

Channel created successfully.

successboolean required
requestIdstring uuid required

Unique identifier for this API request. Include in support tickets.

Example response

{
  "success": true,
  "data": {
    "category": "PAYMENT_WALLET",
    "shortcode": "123456",
    "name": "Main Collections Paybill",
    "accountNumber": "ACCOUNT001",
    "isDefault": true
  },
  "requestId": "c1b2a3d4-e5f6-7890-abcd-ef1234567890"
}