Create Referral via Automation
Use the Attribute Referral action in an automation to link a new opportunity to an existing referrer automatically, without manual data entry.
The Attribute Referral action lets you record a referral relationship automatically inside an automation. When a new lead comes in through a form, a webhook, or any other trigger, the action looks up the referrer, creates the referral record, and links it to the new opportunity without any manual data entry.
Where to find it
Open any automation at https://app.trustpager.com/automations and add a new action step. The action is listed as Attribute Referral in the action picker.
Referrer resolution modes
The action needs to know who the referrer is. There are two ways to tell it:
- Email (find or create) — provide an email address. TrustPager finds the contact or creates one using any first/last name values you supply.
- ID (existing only) — provide a contact ID. TrustPager looks up that specific contact and will not create anyone new.
Recommended chain: form → create opportunity → attribute referral → send email
The most common pattern is a four-step automation triggered by a form submission:
- Trigger: Form Submitted — fires when someone submits your referral intake form.
- Create Opportunity — creates the new opportunity and outputs
{{deal.id}}for later steps. - Attribute Referral — links the new opportunity to the referrer using
{{deal.id}}. - Send Email — notifies the referrer or your team.
Token chaining: how {{deal.id}} flows automatically
When Create Opportunity runs before Attribute Referral, {{deal.id}} is available for all later steps automatically. Reference it in the Referred Opportunity ID field.
Category
A workspace-defined label for each referral — e.g. MRI, CT, Google Ads. Set a fixed value in the action config, or pass a dynamic merge token. Configure categories at https://app.trustpager.com/settings/crm.
Configuration reference
| Field | Required | Notes |
|---|---|---|
| Referrer mode | Yes | email (find or create) or id (existing only) |
| Referrer value | Yes | Email address or contact ID |
| Referrer first name | No | Used when mode is email and contact does not yet exist |
| Referrer last name | No | Used when mode is email and contact does not yet exist |
| Referred contact ID | No | Links referral to an existing contact |
| Referred opportunity ID | No | Use {{deal.id}} when chained from Create Opportunity |
| Category | No | Free-text label on this action — e.g. ‘Broker partner’. Supports merge tokens. (The picklist at /settings/crm controls the dropdown shown on the public referral form only.) |
| Notes | No | Internal notes on the referral record |
| Initial status | No | Defaults to pending; also accepted, converted, declined |
Tip: For a full overview of the Referrals tool — leaderboard, drilldown pages, category configuration — see https://trustpager.com/help-center/track-and-manage-referrals.
The only two ways to attribute a referral
Currently there are exactly two paths:
- Automation action — the Attribute Referral step described on this page, triggered automatically as part of any workflow.
- Public referral form — a contact you have already created clicks their unique referral link and submits the form themselves. See https://trustpager.com/help-center/track-and-manage-referrals for how that form works.
No manual attribution yet. There is currently no Add Referrer button directly on the opportunity sidebar. To attribute a referrer to an existing opportunity created outside an automation, build a short one-step automation — using a manual trigger — with just the Attribute Referral action and the opportunity ID and referrer details as fixed values.
Reacting when a referral is attributed: the Referral Attributed trigger
A Referral Attributed trigger is available in the automation builder trigger picker, alongside other CRM events like Deal Created and Deal Updated. It fires whenever a referral record is created and linked to an opportunity — whether that attribution came from another automation running the Attribute Referral action, or from a contact submitting through the public referral form.
Common patterns built on this trigger:
- Thank-you email to referrer — send a personalised acknowledgement the moment a referral lands.
- Follow-up task for the assigned team member — create a task or notification so no referred opportunity sits unworked.
- Leaderboard update — trigger a webhook to an external system whenever a new referral is attributed.