Skip to main content

What Are Webhooks?

Webhooks are automatic notifications that Waffo Pancake sends to your server when something happens — a payment succeeds, a subscription renews, a refund is processed, etc. Why you need them:
  • Automate delivery: Send download links or grant access immediately after payment
  • Keep your system in sync: Update your database when subscription status changes
  • React to events: Handle failed payments, cancellations, and refunds in real time

Step 1: Configure Webhook URL in Dashboard

1

Go to Settings

In your Dashboard, navigate to Settings → Webhooks.
Webhook settings page
2

Set Your Webhook URL

Enter the URL where Waffo Pancake should send event notifications.
  • Test mode URL: Your development/staging server (e.g., https://staging.yoursite.com/webhooks/waffo)
  • Production URL: Your production server (e.g., https://yoursite.com/webhooks/waffo)
You can set different URLs for test and production environments. This keeps test events separate from real ones.
3

Save

Click Save to activate webhook notifications.

Step 2: Understand Event Types

Waffo Pancake sends these webhook events:

Payment Events

EventWhen It FiresCommon Action
payment.succeededPayment completed successfullyDeliver product, grant access
payment.failedPayment attempt failedNotify customer, retry
payment.refundedRefund processedRevoke access, update records

Subscription Events

EventWhen It FiresCommon Action
subscription.createdNew subscription startedCreate account, set limits
subscription.updatedPlan changed or renewedUpdate access level
subscription.canceledSubscription fully endedRevoke access
subscription.expiredSubscription expiredClean up resources

Step 3: Set Up Email Notifications

In addition to webhook events, you can configure email notifications for both you and your customers.

Merchant Notifications

Go to Settings → Notifications to choose which events trigger email alerts to you:
  • New orders
  • New subscriptions
  • Failed payments
  • Refund requests
Notification settings

Customer Notifications

Customers automatically receive emails for:
  • Order confirmation
  • Subscription confirmation
  • Subscription renewal
  • Subscription cancellation
  • Payment failure
You can toggle these in the notification settings.

How Webhooks Work

Event occurs (e.g., payment succeeds)

Waffo Pancake sends POST request to your webhook URL

Your server receives the event

Your server processes it (deliver product, update database, etc.)

Your server responds with 200 OK

Retry Policy

If your server doesn’t respond with a 2xx status code, Waffo Pancake retries:
AttemptDelay
1st retry5 minutes
2nd retry30 minutes
3rd retry2 hours
4th retry8 hours
5th retry24 hours
After 5 failed retries, the event is marked as failed.

For Developers: Code Integration

If you’re integrating webhooks with your server, here’s how the flow works:

1. Create a Webhook Endpoint

Your server needs a POST endpoint to receive events. The specific implementation depends on your tech stack.

2. Verify the Signature

Every webhook request includes a signature header for security. Verify it to ensure the request came from Waffo Pancake, not a malicious third party.

3. Process Events

Parse the event type and data, then take the appropriate action (deliver product, update subscription status, etc.).

4. Respond Quickly

Return a 200 status code as fast as possible. If you need to do heavy processing, do it asynchronously after responding.
For detailed code examples and signature verification, see the API Reference — Webhooks.

Testing Webhooks

1

Set Test Webhook URL

In Dashboard → Settings → Webhooks, enter your test server URL.
2

Make a Test Purchase

Use test mode to create a purchase. This triggers webhook events to your test URL.
3

Verify Receipt

Check your server logs to confirm the webhook was received and processed correctly.
For local development, use tools like ngrok to expose your local server to the internet so Waffo Pancake can reach it.

Best Practices

  1. Respond quickly: Return 200 immediately, process asynchronously
  2. Handle duplicates: Events may be sent more than once — make your processing idempotent
  3. Verify signatures: Always verify the webhook signature before processing
  4. Log everything: Keep logs of received webhooks for debugging
  5. Monitor failures: Check your Dashboard for failed webhook deliveries

Checklist

  • Webhook URLs configured for test and production
  • Email notifications configured for your team
  • Customer notification preferences set
  • Test webhook received and processed successfully
  • Signature verification implemented (if using code integration)

Next Steps

Manage Refunds

Handle refund requests and track refund status

API Reference — Webhooks

Detailed webhook payload format and code examples