Overview
Webhooks in Hapana allow real-time communication between our platform and your external systems. They're a powerful tool to automate processes, keep your apps in sync, and respond instantly to key events—like purchases, check-ins, or client profile updates.
This article walks you through what webhooks are, how to subscribe to them, and how each one can be used in your workflow.
What Are Webhooks?
Webhooks are HTTP callbacks triggered by specific events in Hapana. When one of these events occurs, Hapana sends a JSON payload to the endpoint URL you provide. It’s like the system giving your app a friendly tap on the shoulder, saying, "Hey, this just happened—do something with it."
Real-World Examples
-
Scenario 1: Real-Time CRM Sync
When a client updates their profile, your CRM receives the update immediately via the
clientUpdated
webhook. -
Scenario 2: Instant Purchase Recording
Use the
packagePurchased
webhook to instantly log transactions in your finance system. -
Scenario 3: Membership Monitoring
The
clientStatusChange
webhook helps you manage access and send renewal reminders based on membership changes.
How to Subscribe to Hapana Webhooks
-
Contact Support
Email [email protected] to request webhook access.
-
Provide Key Info
- Endpoint URL: The URL where you’ll receive the webhook data.
- Webhook Types: Pick one or more from the list below.
- Authentication Header (optional): Add a security token via header if needed.
Available Webhooks
Each webhook below includes the event it listens for, what data it sends, and how it helps your business.
1. Communication Outbound Webhook
- Event Type:
outboundMessage
- Trigger: When a client receives an SMS or email after a purchase
- Payload: Includes client details, message content, type (SMS or email), and delivery metadata
Use Case: Log communication activity in your CRM or send custom follow-ups.
2. Account Created Webhook
- Event Type:
accountCreated
- Trigger: When a new account is created or linked to a new location
- Payload: Full client profile including name, contact info, emergency contacts, and profile image
Use Case: Auto-onboard new clients into your CRM or welcome automation.
3. Client Updated Webhook
- Event Type:
clientUpdated
- Trigger: When a client updates their information
- Payload: Updated contact info, emergency details, and profile metadata
Use Case: Keep your client records synced in real-time.
4. Client Status Change Webhook
- Event Type:
clientStatusChange
- Trigger: When a client’s status changes (e.g., to active, suspended, inactive)
- Payload: Includes updated status and list of active packages
Use Case: Control access, send renewal prompts, or log membership changes.
5. Package Purchase Webhook
- Event Type:
packagePurchased
- Trigger: When a client buys a membership or session package
- Payload: Includes package name, category, price, and client contact info
Use Case: Update financial records or trigger post-purchase automations.
6. Client Check-In Webhook
- Event Type:
checkIn
- Trigger: When a client checks in for a visit or class
- Payload: Check-in status, session details, instructor name, and timestamp
Use Case: Track attendance, validate access, and inform instructors who’s checked in.
How to Request a Webhook Subscription
Here’s a sample message you can send to the support team:
Subject: Request for Webhook Subscription
Hi Hapana Support Team,
I would like to subscribe to the following webhooks:
1. Webhook Type: "clientStatusChange"
Endpoint URL: <https://yourdomain.com/webhooks/status-change>
Authentication Header:
- Key: Authorization
- Value: Bearer your-auth-token
2. Webhook Type: "packagePurchased"
Endpoint URL: <https://yourdomain.com/webhooks/package-purchase>
Please let me know once the subscription is confirmed.
Thanks!
Expected Outcome
Once your subscription is active, Hapana will send real-time event notifications to your designated endpoints—enabling seamless data syncing, automation, and improved client experiences.
FAQs
Q: How secure are the webhook notifications?
A: You can enable secure headers to authenticate incoming requests.
Q: Can I test webhooks before going live?
A: Yes, we recommend using a test endpoint during setup. Ask the support team to help with sandbox data.
Q: Can I subscribe to multiple webhooks at once?
A: Absolutely! Just include them in your request email with individual endpoint URLs.
Need help? Reach out to our support team via [email protected]