Mpesa supports two types of merchant accounts; Paybill and Till Number.  The below setup guidelines will assist you in setting up the two accounts on Peach Console.


  • Paybill

Configuration details to be shared by the merchant 

  • Pass Key

  • Consumer Key 

  • Consumer Secret 

  • Initiator Name

  • Paybill

   

            Setting  up on the console 


  1. Create a merchant account 






  1. Add the Live configuration  as follows

    1. Party B - Paybill Number 

    2. Business Shortcode - Paybill Number 

    3. Passkey - Pass Key as shared by the merchant 

    4. Consumer Key - Consumer Key as shared by the merchant 

    5. Consumer Secret - Consumer Secret as shared by the merchant 

    6. Initiator Name - Initiator Name as shared by the merchant 

    7. Account Type - Select Paybill 







  1. Create a channel and attach the Merchant account to it



  • Till Number 


Configuration details to be shared by the merchant 

  • Pass Key

  • Consumer Key 

  • Consumer Secret 

  • Initiator Name

  • Till Number 

  • Store Number 



  1. Create a Merchant Account 




  1. Add the Live configuration  as follows

Party B - Till Number 

Business Shortcode - Store Number 

Passkey - Pass Key as shared by the merchant 

Consumer Key - Consumer Key as shared by the merchant 

Consumer Secret - Consumer Secret as shared by the merchant 

Initiator Name - Initiator Name as shared by the merchant 

Account Type - Select Till Number  




  1. Create a channel and attach the Merchant account to it




Differentiating API requests between a Till Number and a Paybill


Till Number - The Transaction type is CustomerBuyGoodsOnline 


"request_data": {

      "AccountReference": "M-Pesa_23",

      "Amount": "1",

      "BusinessShortCode": "566777",

      "CallBackURL": "https://qaapi.ppay.io/webhooks/mpesa/",

      "PartyA": "254727038986",

      "PartyB": "174379",

      "Password": "XXXXXXX",

      "PhoneNumber": "254727038986",

      "Timestamp": "202203XXXXXXX5402",

      "TransactionDesc": "Margaret Paypal Demo",

      "TransactionType": "CustomerBuyGoodsOnline"

    },

    "url": "https://sandbox.safaricom.co.ke/mpesa/stkpush/v1/processrequest"

  },



Paybill  - The Transaction type is CustomerPayBillOnline 


"request_data": {

      "AccountReference": "4654bd9f-",

      "Amount": "288",

      "BusinessShortCode": "684065",

      "CallBackURL": "https://api.peachpayments.com/webhooks/mpesa/",

      "PartyA": "254113658075",

      "PartyB": "684065",

      "Password": "XXXXXXX",

      "PhoneNumber": "254113658075",

      "Timestamp": "202203XXXXXXX3320",

      "TransactionDesc": "test",

      "TransactionType": "CustomerPayBillOnline"

    },