Skip to main content

What are Webhooks?

Webhooks allow your application to receive real-time notifications when specific events occur within the Nudj platform. Instead of constantly polling our API for updates, webhooks push data to your application immediately when something happens. When an event occurs (such as a user completing a challenge or earning a reward), Nudj sends an HTTP request to your configured webhook endpoint with event details.
Interactive Testing Available: You can configure and test webhooks directly from this documentation using our interactive API playground. No need to write code to get started!

Key Features

Real-time Notifications

Receive instant notifications when events occur, eliminating the need for polling

Reliable Delivery

Built-in retry logic with configurable attempts ensures your webhook receives the data

Flexible Configuration

Choose which events to receive and customize HTTP methods and headers

Secure Authentication

Custom headers support for secure webhook authentication

How Webhooks Work

  1. Event Occurs: A user action or system event triggers within your Nudj community
  2. Webhook Triggered: Nudj finds the first webhook that subscribes to the event, counting any Nudj-managed system webhooks, which come before yours. If that webhook is switched on (and its entity filter lets the event through), Nudj calls it; a second webhook on the same event is not called
  3. HTTP Request Sent: A request (POST for webhooks created in the admin) is sent to your webhook URL with a JSON payload
  4. Response Processed: Your application processes the webhook data
  5. Retry if Needed: If your endpoint is busy, failing or slow, Nudj retries the delivery (see How Webhooks Are Delivered)

Webhook Configuration

Webhooks are configured at the organisation level, meaning all communities within an organisation share the same webhook configuration. You can manage webhooks from the Admin Panel under Settings → Developer → Webhooks.

Basic Configuration

Webhooks created in the admin use the POST HTTP method with a JSON payload. Through the API you can choose POST, PUT or GET; a GET request carries no body.

Custom Headers (Advanced)

You can configure custom HTTP headers for webhooks that require authentication. This is useful when your webhook endpoint requires:
  • API Keys: x-api-key: YOUR_SECRET_KEY
  • Bearer Tokens: Authorization: Bearer YOUR_TOKEN
  • Custom Authentication: Any header your endpoint expects
Headers are configured in the Advanced Settings section when creating a webhook. Each header is a key-value pair that will be sent with every webhook request.
Example Header Configuration:

Event Filtering

Each webhook subscribes to individual event types: achievement-completion, action-completion, challenge-started, challenge-completion, post-like, post-comment, reward-claim, reward-distribution, reward-redemption, shop-purchase, streak-extended and streak-milestone-reached (plus Shopify store events and invite-admin-user through the API). Community visits, profile changes, variable captures, custom events and referrals do not send webhooks. To narrow a webhook to particular challenges or rewards, use its entity filter.

Quick Start

1

Configure Your Webhook

Use the interactive API playground to configure your webhook:
2

Test with Live Endpoints

Try the configuration directly in our testing guide with webhook.site or ngrok
3

Handle Incoming Webhooks

Create an endpoint to receive webhook payloads with proper authentication
4

Verify Delivery

Trigger test events and monitor webhook delivery in real-time

Security Considerations

Always validate webhook requests in production to ensure they’re coming from Nudj
  • Custom Headers: Use authentication headers to verify request authenticity
  • HTTPS Only: Always use HTTPS endpoints for webhook URLs
  • No IP allowlist: Nudj does not publish fixed IP ranges, so rely on your custom auth header rather than an IP allowlist
  • Request Validation: Verify the request structure matches expected webhook format

How Webhooks Are Delivered

What You Need to Know

  • Success: Return any 2xx status code (200, 201, 204, etc.)
  • Retries: If your endpoint answers 429, 500, 502, 503 or 504, does not answer within 15 seconds (logged as 504), or cannot be reached (logged as 500), Nudj queues the delivery and tries again up to maxRetries more times (3 by default). Nudj sets no delay of its own; the gaps follow the queue’s default retry backoff. Any other answer to the first attempt is not retried
  • Timeout: Nudj waits up to 15 seconds for your answer
  • Order: Order is not guaranteed: a retried delivery can arrive after later events, so make your handler order-independent
  • Dedupe: Every payload has a top-level id that stays the same across retries of one event

Supported Events

Nudj supports webhook notifications for key platform events. See our Event Catalog for the complete list of available events and their payload structures.

Event Categories

  • Challenge Events: challenge-started, challenge-completion
  • Achievement Events: achievement-completion
  • Action Events: action-completion
  • Reward Events: reward-claim, reward-redemption, reward-distribution, shop-purchase
  • Post Events: post-like, post-comment
  • Streak Events: streak-extended, streak-milestone-reached
There are no webhooks for profile updates, community joins, shares or custom events.

Where to Start

Test Webhooks

Configure and test webhooks interactively

Browse Events

See all available events with examples

Code Examples

Ready-to-use integrations for popular platforms

Build Your Handler

Step-by-step implementation guide

Need Help?

If you need assistance setting up webhooks or have questions about specific events, please contact our support team at support@nudj.cx.