POST: Pay Hero Wallet- Withdraw To Mobile
This end point is used to withdraw funds from your payments wallet to Mobile wallet eg: MPESA or Airtel Money
Request Method
Endpoint enables you to withdraw funds to MPESA
POST
https://backend.payhero.co.ke/api/v2/withdraw
Headers
Authorization:*
String
Basic basicAuthToken
Request Body
external_reference
String
Your unique reference to track this transaction Eg: INV-009
amount*
Integer
Eg: 100
phone_number*
String
Eg: 254787677676, Note: must start with country code.
network_code*
String
A unique digit code used for identifying the various mobile money providers:
63902 (MPesa)
63903 (Airtel Money)
callback_url
String
Your endpoint URL that we will use to send payment status response eg: https://example.com/callback.php
channel*
String
Value: mobile
channel_id
Integer
Enter your Payment Wallet Channel ID
payment_service
String
Value: b2c
Sample Code
This represents PHP Curl example of how to make the request, you can implement this in your specific language of choice
Callback URL Response Sample
This represents the JSON that will be sent to your request callback_url
Last updated
Was this helpful?