Leads
Lead management and email validation
Endpoints (10)
/api/leadsList Leads
Get all leads with optional filtering
/api/leadsCreate Lead
Create a lead manually
/api/leads/[id]Get Lead
Get lead details with job and source info
/api/leads/[id]Update Lead
Update a lead's information
/api/leads/[id]Delete Lead
Delete a lead
/api/leads/[id]/validate-emailValidate Lead Email
Trigger email validation for a specific lead
/api/leads/bulkBulk Delete Leads
Soft-delete multiple leads at once (max 1000), by id list or by filter
/api/search/webSearch the Web
Google results for a query, through the deployment's SerpAPI key (Serper as fallback). Provider keys stay on the server; the caller is billed CREDIT_COSTS.WEB_SEARCH credits per search, and a search that returns nothing is refunded and still answers 200 with count 0. Errors answer a bare { error } body: 400 for invalid JSON or input, 429 when rate limited, 503 when neither SERPAPI_API_KEY nor SERPER_API_KEY is set (checked before charging).
/api/leads/bulkBulk Update Leads
Update multiple leads at once
/api/leads/validate-bulkBulk Validate Emails
Queue email validation for multiple leads (max 1000)