Skip to content

Transaction Status ​

ts
await mpesa.transactionStatus.query({
  originalConversationId: 'the ID returned by b2c.pay',
  partyA: 600999,
  resultUrl: 'https://example.com/payments/status/result',
  queueTimeoutUrl: 'https://example.com/payments/status/timeout',
});
FieldDaraja fieldNotes
transactionIdTransactionIDThe M-Pesa receipt number. Give this, originalConversationId, or both.
originalConversationIdOriginalConversationIDThe OriginatorConversationID of the request to check.
partyAPartyAThe shortcode or phone number involved.
identifierTypeIdentifierTypeOptional. 'shortcode' (default), 'till' or 'msisdn'.
resultUrlResultURLReceives the status.
queueTimeoutUrlQueueTimeOutURLReceives a notice if the request times out in the queue.
remarksRemarksOptional. Up to 100 characters.
occasionOccasionOptional. Up to 100 characters.

Released under the MIT License.