Documentation ¶
Overview ¶
Package cli provides the command line interface for the mpesaoverlay. The cli package is responsible for parsing the command line arguments and passing them to the appropriate function.
The cli package is divided into subpackages:
auth: responsible for the GetToken command.
b2c: responsible for the B2CPayment command.
balance: responsible for the AccountBalance command.
c2b: responsible for the C2BRegisterURL and C2BSimulate commands.
express: responsible for the stkpush and stkpushquery commands.
qrcode: responsible for the generateqrcode command.
reversal: responsible for the Reversal command.
tax: responsible for the RemitTax command.
transaction: responsible for the TransactionStatus command.
log: responsible for the logError and logJSON functions.
Index ¶
- func AccountBalance(sdk mpesa.SDK) error
- func AddCommands(app *fisk.Application, sdk mpesa.SDK)
- func B2CPayment(sdk mpesa.SDK) error
- func C2BRegisterURL(sdk mpesa.SDK) error
- func C2BSimulate(sdk mpesa.SDK) error
- func QRCode(sdk mpesa.SDK) error
- func RemitTax(sdk mpesa.SDK) error
- func Reversal(sdk mpesa.SDK) error
- func STKPush(sdk mpesa.SDK) error
- func STKPushQuery(sdk mpesa.SDK) error
- func Token(sdk mpesa.SDK) error
- func TransactionStatus(sdk mpesa.SDK) error
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func AccountBalance ¶
AccountBalance gets the account balance from the mpesa api.
func AddCommands ¶
func AddCommands(app *fisk.Application, sdk mpesa.SDK)
AddCommands adds the mpesa commands to the application.
func C2BRegisterURL ¶
C2BRegisterURL registers the confirmation and validation urls.
func C2BSimulate ¶
func STKPushQuery ¶
func TransactionStatus ¶
Types ¶
This section is empty.