← View All Guides
Webhooks logo
Integration Guide

How to Automate Custom Reward Fulfillment with GrowSurf Webhooks

Use the PARTICIPANT_REACHED_A_GOAL webhook event to kick off your own payout or fulfillment workflow when a native reward integration is not the right fit.

Want the full setup walkthrough?

Use these docs for exact setup steps, supported fields, and troubleshooting.

GrowSurf can send reward-ready webhook events straight to your endpoint whenever a participant unlocks a reward, so your own payout, credit, or fulfillment system can take over from there.

This is the right pattern when the reward needs a custom delivery path, a private internal system, or business logic that sits outside GrowSurf's native reward integrations.

Integration Steps

Add your endpoint in GrowSurf and send a test request

GrowSurf Webhooks settings in the Program Editor
Connect your fulfillment endpoint in the Program Editor first, then use the Test button to confirm GrowSurf can reach it.

Open the Webhooks card in the Options step, add the endpoint that should receive reward events, and publish your changes. Use the built-in test request before you wire that endpoint into a real fulfillment flow.

Listen for PARTICIPANT_REACHED_A_GOAL and branch from the payload

This is the key webhook event for custom reward delivery. The payload includes the participant, reward, and campaign objects so your service can decide whether to issue store credit, send an internal job, or create a payout in another system.

  • Use data.reward.approved to wait for the approved reward when manual reward approval is enabled.
  • Use data.reward.isReferrer to tell whether the reward belongs to the referrer or the referred friend in a double-sided reward setup.
  • Use data.reward.metadata when your own system needs extra values like a SKU, amount, or fulfillment tier.

Fulfill from GrowSurf's reward payload instead of a second lookup

The reward event already gives you the participant identity, reward title or description, and campaign context. Keep GrowSurf as the source of truth for reward eligibility, then let your own service handle the delivery method that GrowSurf does not natively cover.

Secure the endpoint before it can issue anything

Advanced Webhooks settings showing event selection and secret field
Add a webhook secret in the advanced settings so your fulfillment service can verify every incoming request before it sends a reward.

Turn on a webhook secret so GrowSurf includes the GrowSurf-Signature header on outgoing requests. Validate that signature before your endpoint creates a payout, ships a reward, or credits a balance.

Use retries and event logs while you harden the workflow

GrowSurf automatically retries failed webhook deliveries with exponential backoff. If something breaks in production, the current app's Webhook Event Logs help you inspect failing deliveries while you repair the endpoint or re-enable a disabled webhook.

Code Snippets

app.post('/growsurf/webhooks', function(req, res) {
  const body = req.body;

  if (body.event === 'PARTICIPANT_REACHED_A_GOAL' && body.data.reward.approved) {
    fulfillReward({
      email: body.data.participant.email,
      rewardTitle: body.data.reward.title,
      isReferrerReward: body.data.reward.isReferrer,
      metadata: body.data.reward.metadata || {}
    });
  }

  res.json({ received: true });
});

Tips

Inspect the payload before you wire the real payout flow

Send GrowSurf's test request to webhook.site or your own staging endpoint first so you can confirm the reward fields your fulfillment service will receive.

Use reward metadata for custom fulfillment rules

If your reward values vary by tier, SKU, or amount, store that data on the reward and read it back from data.reward.metadata inside the webhook payload.

FAQ

Does the reward webhook fire before and after manual approval?

Yes. When manual reward approval is enabled, GrowSurf sends the event once while the reward is pending and again after it is approved. Use data.reward.approved to tell those states apart.

How do I tell whether the reward is for the referrer or the referred friend?

Check data.reward.isReferrer. It is true for the referrer's reward and false for the referred friend's reward.

Can I include my own fulfillment metadata?

Yes. Reward metadata is included on the webhook payload, so you can store extra values there and read them back when the reward is unlocked.

Set up your refer a friend program with customer referral and affiliate program software that lowers your acquisition costs, increases customer loyalty, and saves you gobs of time.

Trusted by marketing and product teams at fast-growing B2C, fintech, and SaaS companies