Skip to main content

Webhooks

Written by Aldin Rey
Updated over 2 weeks ago

The Webhooks feature allows you to send real-time entry data from ViralSweep to any URL you choose. This makes it easy to capture, store, and use entrant data in your own systems or custom applications.

Availability: This feature is only available on the Business plan and higher.


How webhooks work

When a user submits an entry:

  • ViralSweep sends a POST request to your specified URL

  • The request contains a JSON payload with all entry data

  • You can process this data using any programming language

This method includes more data than standard integrations, making it a powerful option for advanced workflows.


Data included in the webhook

The webhook payload includes the following fields:

[email]
[first_name]
[last_name]
[address]
[address2]
[city]
[state]
[zip]
[country]
[birthday_month]
[birthday_day]
[birthday_year]
[agree_to_rules]
[newsletter_subscribe]
[ip_address]
[promotion_title]
[time_stamp]
[refer_link]
[promotion_id]
[id]
[refer_source]
[entry_source]
[auto_login_link]
[type]

Custom fields

Any custom fields added to your entry form will also be included in the payload. These appear as unique IDs, for example:

[98614_1462473497]

To find a custom field’s ID:

  1. Open your form in a browser

  2. Right-click the field and select Inspect

  3. Locate the field’s name attribute in the HTML


Processing webhook data

You can use any backend language to receive and process webhook data.

Example (PHP)

<?php 
$request_body = file_get_contents('php://input');
$data = json_decode($request_body);
print_r($data);
?>

Tip: Field names are standardized for built-in fields. Custom fields will use their generated numeric IDs.


Important considerations

  • Single delivery attempt: Webhooks are sent only once.

    • If your endpoint is down or returns an error, the data will not be resent.

  • Endpoint reliability:

    • Make sure your server is available and can handle incoming POST requests

    • Log incoming requests to help with debugging


When should you use webhooks?

Webhooks are ideal if you need to:

  • Send data to a custom database or internal system

  • Trigger workflows outside of supported integrations

  • Capture additional fields not available in native integrations

  • Build advanced automation or real-time processing


Need help?

If you need assistance setting up or troubleshooting webhooks, our team is here to help.
Click the chat icon in the bottom-right corner to start a conversation with support.

Did this answer your question?