Index
All Classes and Interfaces|All Packages|Serialized Form
A
- accessToken(String) - Method in class io.github.openpaydev.mpesa.core.models.AccessTokenResponse.AccessTokenResponseBuilder
-
The actual OAuth 2.0 access token used for authorizing API requests.
- AccessTokenResponse - Class in io.github.openpaydev.mpesa.core.models
-
Represents the response object received from the M-Pesa OAuth token generation endpoint.
- AccessTokenResponse.AccessTokenResponseBuilder - Class in io.github.openpaydev.mpesa.core.models
- accountReference(String) - Method in class io.github.openpaydev.mpesa.core.models.StkPushRequest.StkPushRequestBuilder
- amount(String) - Method in class io.github.openpaydev.mpesa.core.models.StkPushRequest.StkPushRequestBuilder
B
- billRefNumber(String) - Method in class io.github.openpaydev.mpesa.core.models.C2bTransaction.C2bTransactionBuilder
- body(StkCallback.Body) - Method in class io.github.openpaydev.mpesa.core.models.StkCallback.StkCallbackBuilder
- build() - Method in class io.github.openpaydev.mpesa.core.models.AccessTokenResponse.AccessTokenResponseBuilder
- build() - Method in class io.github.openpaydev.mpesa.core.models.C2bRegisterUrlRequest.C2bRegisterUrlRequestBuilder
- build() - Method in class io.github.openpaydev.mpesa.core.models.C2bRegisterUrlResponse.C2bRegisterUrlResponseBuilder
- build() - Method in class io.github.openpaydev.mpesa.core.models.C2bTransaction.C2bTransactionBuilder
- build() - Method in class io.github.openpaydev.mpesa.core.models.StkCallback.Body.BodyBuilder
- build() - Method in class io.github.openpaydev.mpesa.core.models.StkCallback.CallbackItem.CallbackItemBuilder
- build() - Method in class io.github.openpaydev.mpesa.core.models.StkCallback.CallbackMetadata.CallbackMetadataBuilder
- build() - Method in class io.github.openpaydev.mpesa.core.models.StkCallback.StkCallbackBuilder
- build() - Method in class io.github.openpaydev.mpesa.core.models.StkCallback.StkCallbackData.StkCallbackDataBuilder
- build() - Method in class io.github.openpaydev.mpesa.core.models.StkPushRequest.StkPushRequestBuilder
- build() - Method in class io.github.openpaydev.mpesa.core.models.StkPushResponse.StkPushResponseBuilder
- build() - Method in class io.github.openpaydev.mpesa.core.models.StkStatusQueryRequest.StkStatusQueryRequestBuilder
- build() - Method in class io.github.openpaydev.mpesa.core.models.StkStatusQueryResponse.StkStatusQueryResponseBuilder
- build() - Method in class io.github.openpaydev.mpesa.core.MpesaConfig.MpesaConfigBuilder
- builder() - Static method in class io.github.openpaydev.mpesa.core.models.AccessTokenResponse
- builder() - Static method in class io.github.openpaydev.mpesa.core.models.C2bRegisterUrlRequest
- builder() - Static method in class io.github.openpaydev.mpesa.core.models.C2bRegisterUrlResponse
- builder() - Static method in class io.github.openpaydev.mpesa.core.models.C2bTransaction
- builder() - Static method in class io.github.openpaydev.mpesa.core.models.StkCallback.Body
- builder() - Static method in class io.github.openpaydev.mpesa.core.models.StkCallback
- builder() - Static method in class io.github.openpaydev.mpesa.core.models.StkCallback.CallbackItem
- builder() - Static method in class io.github.openpaydev.mpesa.core.models.StkCallback.CallbackMetadata
- builder() - Static method in class io.github.openpaydev.mpesa.core.models.StkCallback.StkCallbackData
- builder() - Static method in class io.github.openpaydev.mpesa.core.models.StkPushRequest
- builder() - Static method in class io.github.openpaydev.mpesa.core.models.StkPushResponse
- builder() - Static method in class io.github.openpaydev.mpesa.core.models.StkStatusQueryRequest
- builder() - Static method in class io.github.openpaydev.mpesa.core.models.StkStatusQueryResponse
- builder() - Static method in class io.github.openpaydev.mpesa.core.MpesaConfig
- businessShortCode(String) - Method in class io.github.openpaydev.mpesa.core.models.C2bTransaction.C2bTransactionBuilder
- businessShortCode(String) - Method in class io.github.openpaydev.mpesa.core.models.StkPushRequest.StkPushRequestBuilder
- businessShortCode(String) - Method in class io.github.openpaydev.mpesa.core.models.StkStatusQueryRequest.StkStatusQueryRequestBuilder
-
The organization's short code (Paybill or Till Number) used to identify the business.
- businessShortCode(String) - Method in class io.github.openpaydev.mpesa.core.MpesaConfig.MpesaConfigBuilder
-
The Business Short Code, which is the identifier for your PayBill or Till Number.
C
- C2bRegisterUrlRequest - Class in io.github.openpaydev.mpesa.core.models
-
Represents the request payload for registering the C2B confirmation and validation URLs.
- C2bRegisterUrlRequest.C2bRegisterUrlRequestBuilder - Class in io.github.openpaydev.mpesa.core.models
- C2bRegisterUrlResponse - Class in io.github.openpaydev.mpesa.core.models
-
Represents the response received from M-Pesa after a C2B URL registration request.
- C2bRegisterUrlResponse.C2bRegisterUrlResponseBuilder - Class in io.github.openpaydev.mpesa.core.models
- C2bResponseType - Enum Class in io.github.openpaydev.mpesa.core.models
-
Enum representing the response type for C2B URL registration.
- C2bService - Interface in io.github.openpaydev.mpesa.core.service
- C2bTransaction - Class in io.github.openpaydev.mpesa.core.models
-
Represents the C2B transaction payload sent by M-Pesa to the confirmation and validation URLs.
- C2bTransaction.C2bTransactionBuilder - Class in io.github.openpaydev.mpesa.core.models
- C2bValidationResult - Class in io.github.openpaydev.mpesa.core.models
-
Represents the JSON response your application must send back to M-Pesa from your validation URL.
- C2bValidationResult(int, String) - Constructor for class io.github.openpaydev.mpesa.core.models.C2bValidationResult
- callbackMetadata(StkCallback.CallbackMetadata) - Method in class io.github.openpaydev.mpesa.core.models.StkCallback.StkCallbackData.StkCallbackDataBuilder
- callBackURL(String) - Method in class io.github.openpaydev.mpesa.core.models.StkPushRequest.StkPushRequestBuilder
- Cancelled - Enum constant in enum class io.github.openpaydev.mpesa.core.models.C2bResponseType
-
If the validation URL is unreachable, the transaction will be automatically cancelled.
- checkoutRequestID(String) - Method in class io.github.openpaydev.mpesa.core.models.StkCallback.StkCallbackData.StkCallbackDataBuilder
- checkoutRequestID(String) - Method in class io.github.openpaydev.mpesa.core.models.StkPushResponse.StkPushResponseBuilder
-
A unique identifier for the transaction generated by the M-Pesa system.
- checkoutRequestID(String) - Method in class io.github.openpaydev.mpesa.core.models.StkStatusQueryRequest.StkStatusQueryRequestBuilder
-
The unique ID generated by the M-Pesa system for the original STK Push request, which is to be queried.
- checkoutRequestID(String) - Method in class io.github.openpaydev.mpesa.core.models.StkStatusQueryResponse.StkStatusQueryResponseBuilder
-
The unique identifier for the transaction that was generated by the M-Pesa system.
- Completed - Enum constant in enum class io.github.openpaydev.mpesa.core.models.C2bResponseType
-
If the validation URL is unreachable, the transaction will be automatically completed.
- confirmationUrl(String) - Method in class io.github.openpaydev.mpesa.core.models.C2bRegisterUrlRequest.C2bRegisterUrlRequestBuilder
-
The URL that receives the confirmation of a successful transaction.
- consumerKey(String) - Method in class io.github.openpaydev.mpesa.core.MpesaConfig.MpesaConfigBuilder
-
The Consumer Key obtained from the Safaricom Developer Portal.
- consumerSecret(String) - Method in class io.github.openpaydev.mpesa.core.MpesaConfig.MpesaConfigBuilder
-
The Consumer Secret obtained from the Safaricom Developer Portal.
- conversationID(String) - Method in class io.github.openpaydev.mpesa.core.models.C2bRegisterUrlResponse.C2bRegisterUrlResponseBuilder
-
A unique identifier for the conversation.
- CustomerBuyGoodsOnline - Enum constant in enum class io.github.openpaydev.mpesa.core.models.TransactionType
-
For Buy Goods transactions.
- customerMessage(String) - Method in class io.github.openpaydev.mpesa.core.models.StkPushResponse.StkPushResponseBuilder
-
A message that can be displayed to the end-user.
- CustomerPayBillOnline - Enum constant in enum class io.github.openpaydev.mpesa.core.models.TransactionType
-
For Paybill transactions.
E
- environment(MpesaEnvironment) - Method in class io.github.openpaydev.mpesa.core.MpesaConfig.MpesaConfigBuilder
-
The Mpesa environment to use, either
MpesaEnvironment.SANDBOXorMpesaEnvironment.PRODUCTION. - equals(Object) - Method in class io.github.openpaydev.mpesa.core.models.AccessTokenResponse
- equals(Object) - Method in class io.github.openpaydev.mpesa.core.models.C2bRegisterUrlRequest
- equals(Object) - Method in class io.github.openpaydev.mpesa.core.models.C2bRegisterUrlResponse
- equals(Object) - Method in class io.github.openpaydev.mpesa.core.models.C2bTransaction
- equals(Object) - Method in class io.github.openpaydev.mpesa.core.models.StkCallback.Body
- equals(Object) - Method in class io.github.openpaydev.mpesa.core.models.StkCallback.CallbackItem
- equals(Object) - Method in class io.github.openpaydev.mpesa.core.models.StkCallback.CallbackMetadata
- equals(Object) - Method in class io.github.openpaydev.mpesa.core.models.StkCallback
- equals(Object) - Method in class io.github.openpaydev.mpesa.core.models.StkCallback.StkCallbackData
- equals(Object) - Method in class io.github.openpaydev.mpesa.core.models.StkPushRequest
- equals(Object) - Method in class io.github.openpaydev.mpesa.core.models.StkPushResponse
- equals(Object) - Method in class io.github.openpaydev.mpesa.core.models.StkStatusQueryRequest
- equals(Object) - Method in class io.github.openpaydev.mpesa.core.models.StkStatusQueryResponse
- error(String) - Static method in class io.github.openpaydev.mpesa.core.models.C2bValidationResult
-
Helper to create a standard error response.
- expiresIn(long) - Method in class io.github.openpaydev.mpesa.core.models.AccessTokenResponse.AccessTokenResponseBuilder
-
The duration for which the access token is valid, in seconds.
F
- firstName(String) - Method in class io.github.openpaydev.mpesa.core.models.C2bTransaction.C2bTransactionBuilder
- formatPhoneNumber(String) - Static method in class io.github.openpaydev.mpesa.core.utils.MpesaUtils
- fromEnv() - Static method in class io.github.openpaydev.mpesa.core.MpesaConfig
-
Creates a
MpesaConfiginstance by reading credentials from environment variables.
G
- generatePassword(String, String, String) - Static method in class io.github.openpaydev.mpesa.core.utils.MpesaUtils
- getAccessToken() - Method in class io.github.openpaydev.mpesa.auth.MpesaTokenManager
- getAccessToken() - Method in interface io.github.openpaydev.mpesa.core.auth.TokenManager
-
Returns a valid access token, fetching a new one if necessary.
- getAccessToken() - Method in class io.github.openpaydev.mpesa.core.models.AccessTokenResponse
-
The actual OAuth 2.0 access token used for authorizing API requests.
- getAccountReference() - Method in class io.github.openpaydev.mpesa.core.models.StkPushRequest
- getAmount() - Method in class io.github.openpaydev.mpesa.core.models.StkPushRequest
- getAuthUrl() - Method in enum class io.github.openpaydev.mpesa.core.MpesaEnvironment
-
Returns the full URL for the OAuth token generation endpoint.
- getBillRefNumber() - Method in class io.github.openpaydev.mpesa.core.models.C2bTransaction
- getBody() - Method in class io.github.openpaydev.mpesa.core.models.StkCallback
- getBusinessShortCode() - Method in class io.github.openpaydev.mpesa.core.models.C2bTransaction
- getBusinessShortCode() - Method in class io.github.openpaydev.mpesa.core.models.StkPushRequest
- getBusinessShortCode() - Method in class io.github.openpaydev.mpesa.core.models.StkStatusQueryRequest
-
The organization's short code (Paybill or Till Number) used to identify the business.
- getBusinessShortCode() - Method in class io.github.openpaydev.mpesa.core.MpesaConfig
-
The Business Short Code, which is the identifier for your PayBill or Till Number.
- getC2bRegisterUrl() - Method in enum class io.github.openpaydev.mpesa.core.MpesaEnvironment
-
Returns the full URL for the C2B Register URL endpoint.
- getCallbackMetadata() - Method in class io.github.openpaydev.mpesa.core.models.StkCallback.StkCallbackData
- getCallBackURL() - Method in class io.github.openpaydev.mpesa.core.models.StkPushRequest
- getCheckoutRequestID() - Method in class io.github.openpaydev.mpesa.core.models.StkCallback.StkCallbackData
- getCheckoutRequestID() - Method in class io.github.openpaydev.mpesa.core.models.StkPushResponse
-
A unique identifier for the transaction generated by the M-Pesa system.
- getCheckoutRequestID() - Method in class io.github.openpaydev.mpesa.core.models.StkStatusQueryRequest
-
The unique ID generated by the M-Pesa system for the original STK Push request, which is to be queried.
- getCheckoutRequestID() - Method in class io.github.openpaydev.mpesa.core.models.StkStatusQueryResponse
-
The unique identifier for the transaction that was generated by the M-Pesa system.
- getConfirmationUrl() - Method in class io.github.openpaydev.mpesa.core.models.C2bRegisterUrlRequest
-
The URL that receives the confirmation of a successful transaction.
- getConsumerKey() - Method in class io.github.openpaydev.mpesa.core.MpesaConfig
-
The Consumer Key obtained from the Safaricom Developer Portal.
- getConsumerSecret() - Method in class io.github.openpaydev.mpesa.core.MpesaConfig
-
The Consumer Secret obtained from the Safaricom Developer Portal.
- getConversationID() - Method in class io.github.openpaydev.mpesa.core.models.C2bRegisterUrlResponse
-
A unique identifier for the conversation.
- getCustomerMessage() - Method in class io.github.openpaydev.mpesa.core.models.StkPushResponse
-
A message that can be displayed to the end-user.
- getEnvironment() - Method in class io.github.openpaydev.mpesa.core.MpesaConfig
-
The Mpesa environment to use, either
MpesaEnvironment.SANDBOXorMpesaEnvironment.PRODUCTION. - getExpiresIn() - Method in class io.github.openpaydev.mpesa.core.models.AccessTokenResponse
-
The duration for which the access token is valid, in seconds.
- getFirstName() - Method in class io.github.openpaydev.mpesa.core.models.C2bTransaction
- getInvoiceNumber() - Method in class io.github.openpaydev.mpesa.core.models.C2bTransaction
- getItems() - Method in class io.github.openpaydev.mpesa.core.models.StkCallback.CallbackMetadata
- getLastName() - Method in class io.github.openpaydev.mpesa.core.models.C2bTransaction
- getMerchantRequestID() - Method in class io.github.openpaydev.mpesa.core.models.StkCallback.StkCallbackData
- getMerchantRequestID() - Method in class io.github.openpaydev.mpesa.core.models.StkPushResponse
-
A unique identifier for the transaction that was provided by the merchant's system.
- getMerchantRequestID() - Method in class io.github.openpaydev.mpesa.core.models.StkStatusQueryResponse
-
The unique identifier for the transaction that was sent by the merchant.
- getMiddleName() - Method in class io.github.openpaydev.mpesa.core.models.C2bTransaction
- getMsisdn() - Method in class io.github.openpaydev.mpesa.core.models.C2bTransaction
- getName() - Method in class io.github.openpaydev.mpesa.core.models.StkCallback.CallbackItem
- getOrgAccountBalance() - Method in class io.github.openpaydev.mpesa.core.models.C2bTransaction
- getOriginatorConversationID() - Method in class io.github.openpaydev.mpesa.core.models.C2bRegisterUrlResponse
-
A unique identifier for the transaction request originator.
- getPartyA() - Method in class io.github.openpaydev.mpesa.core.models.StkPushRequest
- getPartyB() - Method in class io.github.openpaydev.mpesa.core.models.StkPushRequest
- getPassKey() - Method in class io.github.openpaydev.mpesa.core.MpesaConfig
-
The Lipa Na M-Pesa Pass Key, used to encrypt the password for STK Push requests.
- getPassword() - Method in class io.github.openpaydev.mpesa.core.models.StkPushRequest
- getPassword() - Method in class io.github.openpaydev.mpesa.core.models.StkStatusQueryRequest
-
The Base64 encoded password, generated from the business short code, passkey, and timestamp.
- getPhoneNumber() - Method in class io.github.openpaydev.mpesa.core.models.StkPushRequest
- getResponseBody() - Method in exception io.github.openpaydev.mpesa.core.exceptions.MpesaApiException
- getResponseCode() - Method in class io.github.openpaydev.mpesa.core.models.StkPushResponse
-
The status code of the request.
- getResponseCode() - Method in class io.github.openpaydev.mpesa.core.models.StkStatusQueryResponse
-
The status code of the initial query request itself.
- getResponseDescription() - Method in class io.github.openpaydev.mpesa.core.models.C2bRegisterUrlResponse
-
A description of the response, e.g., "success".
- getResponseDescription() - Method in class io.github.openpaydev.mpesa.core.models.StkPushResponse
-
A brief description of the response code.
- getResponseDescription() - Method in class io.github.openpaydev.mpesa.core.models.StkStatusQueryResponse
-
A brief description of the status of the query request.
- getResponseType() - Method in class io.github.openpaydev.mpesa.core.models.C2bRegisterUrlRequest
-
The default action to be taken if the validation URL is unreachable.
- getResultCode() - Method in class io.github.openpaydev.mpesa.core.models.C2bValidationResult
- getResultCode() - Method in class io.github.openpaydev.mpesa.core.models.StkCallback.StkCallbackData
- getResultCode() - Method in class io.github.openpaydev.mpesa.core.models.StkStatusQueryResponse
-
The status code indicating the final result of the transaction.
- getResultDesc() - Method in class io.github.openpaydev.mpesa.core.models.C2bValidationResult
- getResultDesc() - Method in class io.github.openpaydev.mpesa.core.models.StkCallback.StkCallbackData
- getResultDesc() - Method in class io.github.openpaydev.mpesa.core.models.StkStatusQueryResponse
-
A detailed description of the transaction's final result.
- getShortCode() - Method in class io.github.openpaydev.mpesa.core.models.C2bRegisterUrlRequest
-
The short code of the organization receiving the payment.
- getStatusCode() - Method in exception io.github.openpaydev.mpesa.core.exceptions.MpesaApiException
- getStkCallback() - Method in class io.github.openpaydev.mpesa.core.models.StkCallback.Body
- getStkPushUrl() - Method in enum class io.github.openpaydev.mpesa.core.MpesaEnvironment
-
Returns the full URL for the STK Push (Lipa Na M-Pesa Online) process request endpoint.
- getStkQueryUrl() - Method in enum class io.github.openpaydev.mpesa.core.MpesaEnvironment
-
Returns the full URL for the STK Push Query (Transaction Status) endpoint.
- getThirdPartyTransID() - Method in class io.github.openpaydev.mpesa.core.models.C2bTransaction
- getTimestamp() - Method in class io.github.openpaydev.mpesa.core.models.StkPushRequest
- getTimestamp() - Method in class io.github.openpaydev.mpesa.core.models.StkStatusQueryRequest
-
The timestamp of the request in the format yyyyMMddHHmmss.
- getTimestamp() - Static method in class io.github.openpaydev.mpesa.core.utils.MpesaUtils
- getTimestamp(ZonedDateTime) - Static method in class io.github.openpaydev.mpesa.core.utils.MpesaUtils
- getTransactionAmount() - Method in class io.github.openpaydev.mpesa.core.models.C2bTransaction
- getTransactionDesc() - Method in class io.github.openpaydev.mpesa.core.models.StkPushRequest
- getTransactionId() - Method in class io.github.openpaydev.mpesa.core.models.C2bTransaction
- getTransactionTime() - Method in class io.github.openpaydev.mpesa.core.models.C2bTransaction
- getTransactionType() - Method in class io.github.openpaydev.mpesa.core.models.C2bTransaction
- getTransactionType() - Method in class io.github.openpaydev.mpesa.core.models.StkPushRequest
- getValidationUrl() - Method in class io.github.openpaydev.mpesa.core.models.C2bRegisterUrlRequest
-
The URL that M-Pesa hits to validate the transaction before processing it.
- getValue() - Method in class io.github.openpaydev.mpesa.core.models.StkCallback.CallbackItem
H
- hashCode() - Method in class io.github.openpaydev.mpesa.core.models.AccessTokenResponse
- hashCode() - Method in class io.github.openpaydev.mpesa.core.models.C2bRegisterUrlRequest
- hashCode() - Method in class io.github.openpaydev.mpesa.core.models.C2bRegisterUrlResponse
- hashCode() - Method in class io.github.openpaydev.mpesa.core.models.C2bTransaction
- hashCode() - Method in class io.github.openpaydev.mpesa.core.models.StkCallback.Body
- hashCode() - Method in class io.github.openpaydev.mpesa.core.models.StkCallback.CallbackItem
- hashCode() - Method in class io.github.openpaydev.mpesa.core.models.StkCallback.CallbackMetadata
- hashCode() - Method in class io.github.openpaydev.mpesa.core.models.StkCallback
- hashCode() - Method in class io.github.openpaydev.mpesa.core.models.StkCallback.StkCallbackData
- hashCode() - Method in class io.github.openpaydev.mpesa.core.models.StkPushRequest
- hashCode() - Method in class io.github.openpaydev.mpesa.core.models.StkPushResponse
- hashCode() - Method in class io.github.openpaydev.mpesa.core.models.StkStatusQueryRequest
- hashCode() - Method in class io.github.openpaydev.mpesa.core.models.StkStatusQueryResponse
I
- invoiceNumber(String) - Method in class io.github.openpaydev.mpesa.core.models.C2bTransaction.C2bTransactionBuilder
- io.github.openpaydev.mpesa - package io.github.openpaydev.mpesa
- io.github.openpaydev.mpesa.auth - package io.github.openpaydev.mpesa.auth
- io.github.openpaydev.mpesa.core - package io.github.openpaydev.mpesa.core
- io.github.openpaydev.mpesa.core.auth - package io.github.openpaydev.mpesa.core.auth
- io.github.openpaydev.mpesa.core.exceptions - package io.github.openpaydev.mpesa.core.exceptions
- io.github.openpaydev.mpesa.core.models - package io.github.openpaydev.mpesa.core.models
- io.github.openpaydev.mpesa.core.service - package io.github.openpaydev.mpesa.core.service
- io.github.openpaydev.mpesa.core.utils - package io.github.openpaydev.mpesa.core.utils
- io.github.openpaydev.mpesa.examples - package io.github.openpaydev.mpesa.examples
- io.github.openpaydev.mpesa.utils - package io.github.openpaydev.mpesa.utils
- items(StkCallback.CallbackItem[]) - Method in class io.github.openpaydev.mpesa.core.models.StkCallback.CallbackMetadata.CallbackMetadataBuilder
L
- lastName(String) - Method in class io.github.openpaydev.mpesa.core.models.C2bTransaction.C2bTransactionBuilder
M
- main(String[]) - Static method in class io.github.openpaydev.mpesa.examples.StkPushExample
- merchantRequestID(String) - Method in class io.github.openpaydev.mpesa.core.models.StkCallback.StkCallbackData.StkCallbackDataBuilder
- merchantRequestID(String) - Method in class io.github.openpaydev.mpesa.core.models.StkPushResponse.StkPushResponseBuilder
-
A unique identifier for the transaction that was provided by the merchant's system.
- merchantRequestID(String) - Method in class io.github.openpaydev.mpesa.core.models.StkStatusQueryResponse.StkStatusQueryResponseBuilder
-
The unique identifier for the transaction that was sent by the merchant.
- middleName(String) - Method in class io.github.openpaydev.mpesa.core.models.C2bTransaction.C2bTransactionBuilder
- MpesaApiException - Exception in io.github.openpaydev.mpesa.core.exceptions
-
Thrown when the M-Pesa API returns a non-successful HTTP response (e.g., 4xx or 5xx).
- MpesaApiException(String, int, String) - Constructor for exception io.github.openpaydev.mpesa.core.exceptions.MpesaApiException
- MpesaAuthException - Exception in io.github.openpaydev.mpesa.core.exceptions
- MpesaAuthException(String, Throwable) - Constructor for exception io.github.openpaydev.mpesa.core.exceptions.MpesaAuthException
- MpesaCallbackParser - Class in io.github.openpaydev.mpesa.utils
-
A utility class for parsing the JSON callback sent by the M-Pesa API.
- MpesaClient - Class in io.github.openpaydev.mpesa
-
The main client for interacting with the Safaricom M-Pesa API.
- MpesaClient(MpesaConfig, TokenManager, OkHttpClient) - Constructor for class io.github.openpaydev.mpesa.MpesaClient
- MpesaConfig - Class in io.github.openpaydev.mpesa.core
-
Configuration object for the Mpesa API client.
- MpesaConfig(String, String, String, String, MpesaEnvironment) - Constructor for class io.github.openpaydev.mpesa.core.MpesaConfig
- MpesaConfig.MpesaConfigBuilder - Class in io.github.openpaydev.mpesa.core
- MpesaEnvironment - Enum Class in io.github.openpaydev.mpesa.core
-
Enum representing the M-Pesa API environments and their corresponding endpoint URLs.
- MpesaException - Exception in io.github.openpaydev.mpesa.core.exceptions
- MpesaException(String) - Constructor for exception io.github.openpaydev.mpesa.core.exceptions.MpesaException
- MpesaException(String, Throwable) - Constructor for exception io.github.openpaydev.mpesa.core.exceptions.MpesaException
- MpesaService - Interface in io.github.openpaydev.mpesa.core.service
- MpesaTokenManager - Class in io.github.openpaydev.mpesa.auth
-
Concrete implementation of the
TokenManagerinterface. - MpesaTokenManager(MpesaConfig, OkHttpClient) - Constructor for class io.github.openpaydev.mpesa.auth.MpesaTokenManager
-
The primary public constructor for the SDK.
- MpesaUtils - Class in io.github.openpaydev.mpesa.core.utils
- msisdn(String) - Method in class io.github.openpaydev.mpesa.core.models.C2bTransaction.C2bTransactionBuilder
N
- name(String) - Method in class io.github.openpaydev.mpesa.core.models.StkCallback.CallbackItem.CallbackItemBuilder
- newPayBillRequest(String, String, String, String, String) - Static method in class io.github.openpaydev.mpesa.core.models.StkPushRequest
-
A convenient static factory method to create a standard PayBill STK Push request object.
O
- orgAccountBalance(String) - Method in class io.github.openpaydev.mpesa.core.models.C2bTransaction.C2bTransactionBuilder
- originatorConversationID(String) - Method in class io.github.openpaydev.mpesa.core.models.C2bRegisterUrlResponse.C2bRegisterUrlResponseBuilder
-
A unique identifier for the transaction request originator.
P
- parse(String) - Static method in class io.github.openpaydev.mpesa.utils.MpesaCallbackParser
-
Parses the JSON string from an M-Pesa callback into a structured
StkCallbackobject. - partyA(String) - Method in class io.github.openpaydev.mpesa.core.models.StkPushRequest.StkPushRequestBuilder
- partyB(String) - Method in class io.github.openpaydev.mpesa.core.models.StkPushRequest.StkPushRequestBuilder
- passKey(String) - Method in class io.github.openpaydev.mpesa.core.MpesaConfig.MpesaConfigBuilder
-
The Lipa Na M-Pesa Pass Key, used to encrypt the password for STK Push requests.
- password(String) - Method in class io.github.openpaydev.mpesa.core.models.StkPushRequest.StkPushRequestBuilder
- password(String) - Method in class io.github.openpaydev.mpesa.core.models.StkStatusQueryRequest.StkStatusQueryRequestBuilder
-
The Base64 encoded password, generated from the business short code, passkey, and timestamp.
- phoneNumber(String) - Method in class io.github.openpaydev.mpesa.core.models.StkPushRequest.StkPushRequestBuilder
- PRODUCTION - Enum constant in enum class io.github.openpaydev.mpesa.core.MpesaEnvironment
-
The Production environment for live, real-money transactions.
Q
- queryStkStatus(String) - Method in interface io.github.openpaydev.mpesa.core.service.StkPushService
-
Queries the status of an STK Push transaction.
- queryStkStatus(String) - Method in class io.github.openpaydev.mpesa.MpesaClient
R
- registerC2bUrl(C2bRegisterUrlRequest) - Method in interface io.github.openpaydev.mpesa.core.service.C2bService
-
Registers the Confirmation and Validation URLs for a C2B shortcode.
- registerC2bUrl(C2bRegisterUrlRequest) - Method in class io.github.openpaydev.mpesa.MpesaClient
-
ADD THIS NEW METHOD IMPLEMENTATION
- responseCode(String) - Method in class io.github.openpaydev.mpesa.core.models.StkPushResponse.StkPushResponseBuilder
-
The status code of the request.
- responseCode(String) - Method in class io.github.openpaydev.mpesa.core.models.StkStatusQueryResponse.StkStatusQueryResponseBuilder
-
The status code of the initial query request itself.
- responseDescription(String) - Method in class io.github.openpaydev.mpesa.core.models.C2bRegisterUrlResponse.C2bRegisterUrlResponseBuilder
-
A description of the response, e.g., "success".
- responseDescription(String) - Method in class io.github.openpaydev.mpesa.core.models.StkPushResponse.StkPushResponseBuilder
-
A brief description of the response code.
- responseDescription(String) - Method in class io.github.openpaydev.mpesa.core.models.StkStatusQueryResponse.StkStatusQueryResponseBuilder
-
A brief description of the status of the query request.
- responseType(C2bResponseType) - Method in class io.github.openpaydev.mpesa.core.models.C2bRegisterUrlRequest.C2bRegisterUrlRequestBuilder
-
The default action to be taken if the validation URL is unreachable.
- resultCode(int) - Method in class io.github.openpaydev.mpesa.core.models.StkCallback.StkCallbackData.StkCallbackDataBuilder
- resultCode(String) - Method in class io.github.openpaydev.mpesa.core.models.StkStatusQueryResponse.StkStatusQueryResponseBuilder
-
The status code indicating the final result of the transaction.
- resultDesc(String) - Method in class io.github.openpaydev.mpesa.core.models.StkCallback.StkCallbackData.StkCallbackDataBuilder
- resultDesc(String) - Method in class io.github.openpaydev.mpesa.core.models.StkStatusQueryResponse.StkStatusQueryResponseBuilder
-
A detailed description of the transaction's final result.
S
- SANDBOX - Enum constant in enum class io.github.openpaydev.mpesa.core.MpesaEnvironment
-
The Sandbox environment for development and testing purposes.
- shortCode(String) - Method in class io.github.openpaydev.mpesa.core.models.C2bRegisterUrlRequest.C2bRegisterUrlRequestBuilder
-
The short code of the organization receiving the payment.
- stkCallback(StkCallback.StkCallbackData) - Method in class io.github.openpaydev.mpesa.core.models.StkCallback.Body.BodyBuilder
- StkCallback - Class in io.github.openpaydev.mpesa.core.models
-
Represents the entire JSON object received from M-Pesa on the callback URL after a transaction.
- StkCallback.Body - Class in io.github.openpaydev.mpesa.core.models
-
The main container for the callback data.
- StkCallback.Body.BodyBuilder - Class in io.github.openpaydev.mpesa.core.models
- StkCallback.CallbackItem - Class in io.github.openpaydev.mpesa.core.models
-
A key-value pair representing a piece of transaction metadata.
- StkCallback.CallbackItem.CallbackItemBuilder - Class in io.github.openpaydev.mpesa.core.models
- StkCallback.CallbackMetadata - Class in io.github.openpaydev.mpesa.core.models
-
A container for the list of metadata items.
- StkCallback.CallbackMetadata.CallbackMetadataBuilder - Class in io.github.openpaydev.mpesa.core.models
- StkCallback.StkCallbackBuilder - Class in io.github.openpaydev.mpesa.core.models
- StkCallback.StkCallbackData - Class in io.github.openpaydev.mpesa.core.models
-
Contains the core details and result of the STK Push transaction.
- StkCallback.StkCallbackData.StkCallbackDataBuilder - Class in io.github.openpaydev.mpesa.core.models
- stkPush(StkPushRequest) - Method in interface io.github.openpaydev.mpesa.core.service.StkPushService
-
Initiates an M-Pesa STK Push request.
- stkPush(StkPushRequest) - Method in class io.github.openpaydev.mpesa.MpesaClient
- StkPushExample - Class in io.github.openpaydev.mpesa.examples
-
A runnable example demonstrating how to use the MpesaClient for an STK Push and Status Query.
- StkPushExample() - Constructor for class io.github.openpaydev.mpesa.examples.StkPushExample
- StkPushRequest - Class in io.github.openpaydev.mpesa.core.models
-
Represents the complete request model for an M-Pesa STK Push API call.
- StkPushRequest.StkPushRequestBuilder - Class in io.github.openpaydev.mpesa.core.models
- StkPushResponse - Class in io.github.openpaydev.mpesa.core.models
-
Represents the synchronous response received from the M-Pesa API immediately after initiating an STK Push.
- StkPushResponse.StkPushResponseBuilder - Class in io.github.openpaydev.mpesa.core.models
- StkPushService - Interface in io.github.openpaydev.mpesa.core.service
- StkStatusQueryRequest - Class in io.github.openpaydev.mpesa.core.models
-
Represents the internal request payload for the M-Pesa STK Push Status Query API.
- StkStatusQueryRequest.StkStatusQueryRequestBuilder - Class in io.github.openpaydev.mpesa.core.models
- StkStatusQueryResponse - Class in io.github.openpaydev.mpesa.core.models
-
Represents the response object received when querying the status of an STK Push transaction.
- StkStatusQueryResponse.StkStatusQueryResponseBuilder - Class in io.github.openpaydev.mpesa.core.models
- success(String) - Static method in class io.github.openpaydev.mpesa.core.models.C2bValidationResult
-
Helper to create a standard success response.
T
- thirdPartyTransID(String) - Method in class io.github.openpaydev.mpesa.core.models.C2bTransaction.C2bTransactionBuilder
- timestamp(String) - Method in class io.github.openpaydev.mpesa.core.models.StkPushRequest.StkPushRequestBuilder
- timestamp(String) - Method in class io.github.openpaydev.mpesa.core.models.StkStatusQueryRequest.StkStatusQueryRequestBuilder
-
The timestamp of the request in the format yyyyMMddHHmmss.
- toBuilder() - Method in class io.github.openpaydev.mpesa.core.models.C2bRegisterUrlRequest
- toBuilder() - Method in class io.github.openpaydev.mpesa.core.models.StkPushRequest
- TokenManager - Interface in io.github.openpaydev.mpesa.core.auth
- toString() - Method in class io.github.openpaydev.mpesa.core.models.AccessTokenResponse.AccessTokenResponseBuilder
- toString() - Method in class io.github.openpaydev.mpesa.core.models.AccessTokenResponse
- toString() - Method in class io.github.openpaydev.mpesa.core.models.C2bRegisterUrlRequest.C2bRegisterUrlRequestBuilder
- toString() - Method in class io.github.openpaydev.mpesa.core.models.C2bRegisterUrlRequest
- toString() - Method in class io.github.openpaydev.mpesa.core.models.C2bRegisterUrlResponse.C2bRegisterUrlResponseBuilder
- toString() - Method in class io.github.openpaydev.mpesa.core.models.C2bRegisterUrlResponse
- toString() - Method in class io.github.openpaydev.mpesa.core.models.C2bTransaction.C2bTransactionBuilder
- toString() - Method in class io.github.openpaydev.mpesa.core.models.C2bTransaction
- toString() - Method in class io.github.openpaydev.mpesa.core.models.StkCallback.Body.BodyBuilder
- toString() - Method in class io.github.openpaydev.mpesa.core.models.StkCallback.Body
- toString() - Method in class io.github.openpaydev.mpesa.core.models.StkCallback.CallbackItem.CallbackItemBuilder
- toString() - Method in class io.github.openpaydev.mpesa.core.models.StkCallback.CallbackItem
- toString() - Method in class io.github.openpaydev.mpesa.core.models.StkCallback.CallbackMetadata.CallbackMetadataBuilder
- toString() - Method in class io.github.openpaydev.mpesa.core.models.StkCallback.CallbackMetadata
- toString() - Method in class io.github.openpaydev.mpesa.core.models.StkCallback.StkCallbackBuilder
- toString() - Method in class io.github.openpaydev.mpesa.core.models.StkCallback.StkCallbackData.StkCallbackDataBuilder
- toString() - Method in class io.github.openpaydev.mpesa.core.models.StkCallback.StkCallbackData
- toString() - Method in class io.github.openpaydev.mpesa.core.models.StkCallback
- toString() - Method in class io.github.openpaydev.mpesa.core.models.StkPushRequest.StkPushRequestBuilder
- toString() - Method in class io.github.openpaydev.mpesa.core.models.StkPushRequest
- toString() - Method in class io.github.openpaydev.mpesa.core.models.StkPushResponse.StkPushResponseBuilder
- toString() - Method in class io.github.openpaydev.mpesa.core.models.StkPushResponse
- toString() - Method in class io.github.openpaydev.mpesa.core.models.StkStatusQueryRequest.StkStatusQueryRequestBuilder
- toString() - Method in class io.github.openpaydev.mpesa.core.models.StkStatusQueryRequest
- toString() - Method in class io.github.openpaydev.mpesa.core.models.StkStatusQueryResponse.StkStatusQueryResponseBuilder
- toString() - Method in class io.github.openpaydev.mpesa.core.models.StkStatusQueryResponse
- toString() - Method in class io.github.openpaydev.mpesa.core.MpesaConfig.MpesaConfigBuilder
- transactionAmount(String) - Method in class io.github.openpaydev.mpesa.core.models.C2bTransaction.C2bTransactionBuilder
- transactionDesc(String) - Method in class io.github.openpaydev.mpesa.core.models.StkPushRequest.StkPushRequestBuilder
- transactionId(String) - Method in class io.github.openpaydev.mpesa.core.models.C2bTransaction.C2bTransactionBuilder
- transactionTime(String) - Method in class io.github.openpaydev.mpesa.core.models.C2bTransaction.C2bTransactionBuilder
- transactionType(String) - Method in class io.github.openpaydev.mpesa.core.models.C2bTransaction.C2bTransactionBuilder
- transactionType(String) - Method in class io.github.openpaydev.mpesa.core.models.StkPushRequest.StkPushRequestBuilder
- TransactionType - Enum Class in io.github.openpaydev.mpesa.core.models
-
Enum representing the M-Pesa transaction types for STK Push.
V
- validationUrl(String) - Method in class io.github.openpaydev.mpesa.core.models.C2bRegisterUrlRequest.C2bRegisterUrlRequestBuilder
-
The URL that M-Pesa hits to validate the transaction before processing it.
- value(Object) - Method in class io.github.openpaydev.mpesa.core.models.StkCallback.CallbackItem.CallbackItemBuilder
- valueOf(String) - Static method in enum class io.github.openpaydev.mpesa.core.models.C2bResponseType
-
Returns the enum constant of this class with the specified name.
- valueOf(String) - Static method in enum class io.github.openpaydev.mpesa.core.models.TransactionType
-
Returns the enum constant of this class with the specified name.
- valueOf(String) - Static method in enum class io.github.openpaydev.mpesa.core.MpesaEnvironment
-
Returns the enum constant of this class with the specified name.
- values() - Static method in enum class io.github.openpaydev.mpesa.core.models.C2bResponseType
-
Returns an array containing the constants of this enum class, in the order they are declared.
- values() - Static method in enum class io.github.openpaydev.mpesa.core.models.TransactionType
-
Returns an array containing the constants of this enum class, in the order they are declared.
- values() - Static method in enum class io.github.openpaydev.mpesa.core.MpesaEnvironment
-
Returns an array containing the constants of this enum class, in the order they are declared.
All Classes and Interfaces|All Packages|Serialized Form