Webhooks

When an action occurs within the Mentium system on a resource, an Event object is created to record a change to the state of the resource. All created Webhook Events follow the same format and include

Security

For security reasons, we provide a HTTP header X-Request-Signature-SHA-256 that contains a HMAC SHA256 hash based on the webhook payload and a key which is the webhook secret you provided when you created your webhook subscription. The webhook signature should be processed and validated prior to parsing the webhook payload.

Events

We currently support 4 events (more to come soon).

Events payload

For each event type, the data payload contains a different payload.

payment_link events

Status:

  • PENDING: The customer hasn't attempted to pay yet

  • PAYMENT_PENDING The customer has made a payment

  • PAYMENT_SUCCEED The customer payment is successful

  • PAYMENT_FAILED The customer payment has failed

payment events

Status:

  • PENDING: The payment hasn't been received yet

  • PROCESSED The payment has been received

  • FAILED The payment failed

  • CANCELLED The paymnet was cancelled

Last updated