Package io.github.openpaydev.mpesa.core
Class MpesaConfig.MpesaConfigBuilder
java.lang.Object
io.github.openpaydev.mpesa.core.MpesaConfig.MpesaConfigBuilder
- Enclosing class:
- MpesaConfig
-
Method Summary
Modifier and TypeMethodDescriptionbuild()businessShortCode(String businessShortCode) The Business Short Code, which is the identifier for your PayBill or Till Number.consumerKey(String consumerKey) The Consumer Key obtained from the Safaricom Developer Portal.consumerSecret(String consumerSecret) The Consumer Secret obtained from the Safaricom Developer Portal.environment(MpesaEnvironment environment) The Mpesa environment to use, eitherMpesaEnvironment.SANDBOXorMpesaEnvironment.PRODUCTION.The Lipa Na M-Pesa Pass Key, used to encrypt the password for STK Push requests.toString()
-
Method Details
-
consumerKey
The Consumer Key obtained from the Safaricom Developer Portal.- Returns:
this.
-
consumerSecret
The Consumer Secret obtained from the Safaricom Developer Portal.- Returns:
this.
-
businessShortCode
The Business Short Code, which is the identifier for your PayBill or Till Number. Renamed from 'shortCode' to align with the official M-Pesa API documentation.- Returns:
this.
-
passKey
The Lipa Na M-Pesa Pass Key, used to encrypt the password for STK Push requests.- Returns:
this.
-
environment
The Mpesa environment to use, eitherMpesaEnvironment.SANDBOXorMpesaEnvironment.PRODUCTION.- Returns:
this.
-
build
-
toString
-