Skip to content
Docs

Webhooks for won deals and leads

RankUpside takes won deals at POST /api/hooks/revenue and calls or form leads at POST /api/hooks/leads, both authenticated with the client's revenue key as a bearer token. Send one JSON object or an array of up to 500. Re-sending an item with the same ID updates it, and each bad item gets its own error.

What it doesn't do: The webhooks don't pull from your CRM. Something has to send each deal or lead: a CRM workflow, Zapier, Make or the call tracker's own webhook.

Updated

Client settings, Leads and revenue: the form snippet, the CSV upload for won deals and the webhook request with its key.
Client › Settings › Leads & revenue · Sample data

The site key

Each client site has one revenue key, shown in Client › Settings › Leads & revenue. Both webhooks use it as a bearer token:

Authorization: Bearer rk_…

Call trackers that can only post to a URL, such as CallRail and WhatConverts, put the key in the address instead: ?key=rk_…. The settings page shows those two providers that URL form with the key masked; paste in the site's full key before you save it in the call tracker. Treat that URL like a password.

New key creates a replacement and the old key stops working right away. The new key is shown once: “Save this one now; it won't be shown again.” Update it wherever it's used, such as Zapier, Make or the CRM. Keys are stored as hashes.

Revenue webhook

POST https://rankupside.com/api/hooks/revenue

Send one deal as a JSON object, or up to 500 as an array.

Revenue webhook fields
FieldAlso acceptedWhat it takes
idexternal_idThe CRM's deal ID. Re-sending the same ID updates the deal.
dateYYYY-MM-DD, M/D/YYYY or a written date like "Oct 14, 2026". Missing means today.
landing_pagelandingPage, urlThe page the customer first landed on: a path or a full URL. Missing means the deal shows as unmatched.
amountvalueA non-negative number, up to 10,000,000. Dollar signs and commas are fine.
statuswon, open or lost, plus CRM words such as "closed won", "paid" or "cancelled". Lost words win over won words. Missing means won.
sourceWhere the lead came from, such as organic. Deals whose source names ads, social, a directory or the Business Profile are left out of search revenue.
phone, emailOptional. Used only to match the deal to a call or form lead, and stored as a salted hash.
POST /api/hooks/revenue
Authorization: Bearer rk_••••••••

{
  "id": "D-1042",
  "date": "2026-10-14",
  "landing_page": "https://copperlinegutters.example/",
  "amount": 4200,
  "status": "won",
  "source": "organic"
}
One key per client site. Send one deal or a list of up to 500. The deal above is a sample.

How each deal is then split across searches: How revenue is allocated.

Leads webhook

POST https://rankupside.com/api/hooks/leads?provider=callrail|whatconverts|generic|quo

Calls and form leads use the same site key. Pick the provider that sent the payload; generic is the default. Each lead needs an ID, a date and a type (call or form).

Lead fields by provider
ProviderID and dateTypeLanding page and sourceDuration and contact
CallRail (post-call)id, start_timeAlways a calllanding_page_url; source + mediumduration, customer_phone_number, first_call, keywords
WhatConvertslead_id, date_createdlead_type: "Phone Call" or "Web Form"landing_url; lead_source + lead_mediumcall_duration_seconds, phone_number, email_address
Genericid, datetype: call or formlanding_page; sourceduration in seconds, phone, email
Quo (call.completed)The call's ID and completed timeAlways a callNone: business-line calls count toward totals without a pageDuration and caller number. Outbound calls are counted as skipped, not errors.
curl -X POST https://rankupside.com/api/hooks/leads?provider=generic \
  -H "Authorization: Bearer rk_…" \
  -H "Content-Type: application/json" \
  -d '{"id":"TEST-example","date":"2026-10-20T12:00:00Z","type":"call",
       "landing_page":"https://copperlinegutters.example/services/gutter-repair",
       "source":"organic","duration":30,"phone":"+1 202-555-0142"}'
A fictional test lead, like the one the settings page sends with Send test lead.

Calls whose source is Google Maps or the Business Profile are kept apart as Business Profile calls, not organic leads.

Responses

Status codes for both webhooks
StatusWhen
200At least one item was saved, or there was nothing to save. Failed items are listed in errors.
400Every item failed, the body isn't JSON, or the provider isn't one of the four.
401No key in the header or the URL, or the key is unknown.
413More than 500 items in one request.

The revenue webhook returns {ok, inserted, updated, errors}. The leads webhook adds skipped. ok is false whenever any item failed. Each error names its item, counting from 0:

{
  "ok": false,
  "inserted": 2,
  "updated": 1,
  "errors": ["Item 3: unreadable date."]
}

Recipes

  • GoHighLevel: a workflow step posts each won opportunity.
  • HubSpot: a workflow webhook on closed-won deals, or a CSV export.
  • Zapier: Webhooks by Zapier, for CRMs without a webhook of their own.
  • CallRail and WhatConverts: their own webhooks, pointed at the leads URL.

No webhook at all? Upload a file instead: CSV format for won deals.

Test it

  1. Copy the webhook request from Client › Settings › Leads & revenue. It already has the client's address and key ending.
  2. Run it with the full key, or use Send test lead under Call tracking.
  3. Check Recent deals or Recent leads on the same page. Test items use fictional data; give your own tests IDs starting with TEST- so they're easy to spot.

Something missing or out of date? Email hello@rankupside.com.

Questions.

Can one request send many deals?
Yes. Send a JSON array of up to 500 deals or leads. Valid items are saved even if others fail, and the response lists an error for each failed item.
What happens if the same deal is sent twice?
If it has the same id, the second send updates the first. Send a stable deal ID from the CRM so updates, such as a status change from open to won, land on the same deal.
Does a deal need a landing page?
To be tied to searches, yes. Without one it's saved but shows as unmatched in the report. The form snippet adds the landing page to every lead so the CRM can send it back.
Is the caller's phone number stored?
No. Phone and email are stored only as salted hashes for matching, plus the last two digits of the phone number for display. No recordings or transcripts are stored, and webhook bodies aren't logged.