Allow Referral Source For Email Campaigns

Currently, the Referral Source field in Offer Management is populated exclusively via document.referrer, which is captured automatically by the widget at load time. This works for organic traffic but provides no way for merchants to pass a custom value when traffic originates from an external campaign.

Requested Changes:

  1. Widget — Add an optional referralSource string parameter to the Reusely({...}) initialization options. If provided, it should override the auto-captured document.referrer value and be stored against the lead/offer record as the referral source.

  2. Collect Leads API — Add an optional referral_source string field to the POST /api/v3/public/offer/leads request body, allowing programmatic lead capture to include a referral source at submission time.

Expected behavior: The value passed via either method populates the Referral Source column in Offer Management identically to how the auto-captured referrer does today.

Use case: When a recovery link containing a ?campaign= URL parameter is clicked, the widget initialization reads new URLSearchParams(window.location.search).get('campaign') and passes it as referralSource, enabling full campaign-level conversion attribution within Reusely's reporting without relying on external tools.

Please authenticate to join the conversation.

Upvoters
Status

Under Review

Board

Suggest a Feature

Date

4 months ago

Subscribe to request

Get notified by email when there are changes.