Overview
RETM Webhooks: Stay Informed with Real-Time Event Notifications
Webhooks enable your application to receive real-time updates about critical events occurring within the RETM platform. Here's a comprehensive guide to effectively utilizing them:
Key Concepts
- Subscription: A registration linking a notification URL (your application's endpoint) with specific events you want to be notified about.
- Event: A significant occurrence within the RETM platform, triggered by merchant actions in the dashboard, POS, or API calls.
- Notification URL: The endpoint within your application that receives and processes event notifications from RETM.
How Webhooks Work
- Subscription: You create a webhook subscription, specifying events of interest and your notification URL.
- Event Occurrence: An event matching your subscription triggers RETM to collect event data and generate a notification.
- Notification Delivery: RETM sends a POST request with the event details in JSON format to your notification URL.
- Acknowledgment: Your application must respond with a 2xx HTTP status code within 10 seconds to confirm receipt.
Prerequisites
- Notification URL: A reachable endpoint within your application prepared to handle incoming webhook notifications.
- API Version: Knowledge of the RETM API version supporting the events you want to subscribe to.
Requirements and Limitations
- Response Time: Your notification URL must acknowledge receipt with a 2xx HTTP status code within 10 seconds.
- Secure Connection: The endpoint must enforce HTTPS for secure communication.
- Delivery Expectations:
- Notifications typically arrive within 30 seconds of the event.
- Delivery order is not guaranteed.
Notification Retries
- RETM retries delivery up to 3 times if no 2xx status code is received within 10 seconds.
- After 3 failed attempts, the notification is discarded.
Next Steps
- Refer to the RETM API documentation for detailed instructions on creating and managing webhook subscriptions.
- Implement robust error handling and logging mechanisms within your notification URL to ensure reliable processing of event notifications.
By effectively utilizing webhooks, you'll create dynamic and responsive applications that stay synchronized with real-time events within the RETM platform.
Modified at 9 months ago