API Documentation

Built for Developers, Trusted by Operators

Every ReCapture account ships with full programmatic access. Drop in the tracking script, push leads via REST, or receive real-time webhooks the second a form is abandoned. Production-ready endpoints, no rate limits on Pro and above.

01

Quick Start

The fastest path to recovering abandoned form data. One script tag, deployed once. ReCapture handles capture, scoring, alerts, and recovery emails automatically.

Setup timeUnder 60 seconds
Paste before the closing </body> tag
<script src="https://userecapture.com/tracker.js"
        data-key="YOUR_API_KEY"
        async></script>

Find your API key in Settings → Integrations. The script auto-detects every form on the page — no per-form configuration required.

02

Authentication

All REST requests authenticate with your client API key. Pass it in the request body as api_key. Never expose service-role keys client-side.

Base URLhttps://userecapture.com
Content Typeapplication/json
Rate LimitsNone on Pro and Enterprise
03

Track an Abandoned Lead

Push a lead manually when the tracker script can't see your form — custom-rendered React forms, native mobile apps, or backend captures from third-party tools.

POST/api/track
Request Body
{
  "api_key": "your_api_key",
  "session_id": "unique_session_uuid",
  "name": "Sarah Chen",
  "email": "sarah@example.com",
  "phone": "+12145551234",
  "fields_completed": 3,
  "total_fields": 5,
  "time_on_form": 47,
  "device_type": "desktop",
  "form_data": {
    "service": "Consultation",
    "preferred_date": "2026-05-04"
  }
}
Response — 200 OK
{
  "success": true,
  "lead_id": "9f3b0c12-..."
}

Required: api_key, session_id. All other fields optional. session_id doubles as the dedup key — repeat calls update the same lead instead of creating duplicates.

04

Trigger a Recovery Email

Manually send the branded recovery email to a captured lead. Useful for custom drip sequences, second-touch automation, or recovering leads outside auto-email windows.

POST/api/send-recovery
Request Body
{
  "api_key": "your_api_key",
  "lead_id": "9f3b0c12-..."
}
Response — 200 OK
{
  "success": true,
  "id": "resend_message_id"
}

Server validates that the API key owns the lead. Returns { "skipped": true } if a recovery email has already been delivered for that lead.

05

Outbound Webhook Payload

Configure a Webhook URL in Settings → Integrations and ReCapture POSTs every captured lead to your endpoint in real time. Standard JSON, signed with your API key's session.

Event — lead.abandoned
{
  "event": "lead.abandoned",
  "timestamp": "2026-04-28T18:42:11.207Z",
  "lead": {
    "name": "Sarah Chen",
    "email": "sarah@example.com",
    "phone": "+12145551234",
    "fields_completed": 3,
    "total_fields": 5,
    "time_on_form": 47,
    "device_type": "desktop",
    "score": "hot",
    "estimated_value": 4200,
    "form_data": {
      "service": "Consultation"
    }
  }
}

Score values: hot (3+ fields), warm (2 fields), cold (1 field). Estimated value is calculated from your avg_lead_value setting at capture time.

Need Custom Endpoints?

Enterprise customers get direct engineering support, custom field mapping, and white-label endpoints.

View Enterprise Plans