Send leads from your app
1Add or update a lead
POST /leadsadds a person, or fills in the empty fields of the lead with the same email (then the same phone). Nothing already there is overwritten:201means new,200means it existed. Send what they agreed to inconsent, such as the checkbox text they saw. It's a retry-safe request, so a retry never makes a second lead.curl -X POST "https://cuil.si/api/v1/leads" -H "Authorization: Bearer $CUILSI_API_KEY" \ -H "Content-Type: application/json" \ -H "Idempotency-Key: $(uuidgen)" \ -d '{ "email": "[email protected]", "first_name": "Asha", "company": { "name": "Chai Co", "domain": "chai.example" }, "tags": ["website"], "source": "api", "consent": { "channel": "email", "purpose": "enquiry", "basis": "asked_to_be_contacted", "text": "Yes, please contact me about my enquiry." } }' # 201 { "lead": { "id": "...", ... }, "is_new": true, "changed": [...], "warnings": [] } # 200 when a lead with that email (or phone) already existed: only its empty fields were filled in.2Send many at once
POST /leads/batchtakes up to 100 leads and answers with one result for each, in the same order. One bad lead doesn't stop the others.curl -X POST "https://cuil.si/api/v1/leads/batch" -H "Authorization: Bearer $CUILSI_API_KEY" \ -H "Content-Type: application/json" \ -d '{"items": [{"email": "[email protected]", "first_name": "Ravi"}, {"phone": "+919812345678"}]}' # { "items": [ { "index": 0, "ok": true, "lead_id": "...", "is_new": true, ... }, # { "index": 1, "ok": true, ... } ] } One result per lead, in the same order.3Respect the do-not-contact list
Before you email or call people from your own system, check them with
POST /suppressions/check. When someone opts out on your side, add them withPOST /suppressionsso cuil.si never contacts them either. We keep only a fingerprint of the address, not the address itself.# Before your own emails or calls: is anyone on the do-not-contact list? curl -X POST "https://cuil.si/api/v1/suppressions/check" -H "Authorization: Bearer $CUILSI_API_KEY" \ -H "Content-Type: application/json" \ -d '{"emails": ["[email protected]"], "phones": ["+919812345678"]}' # { "items": [ { "kind": "email", "value": "[email protected]", "valid": true, "do_not_contact": false, ... } ] } # Someone unsubscribed in your own system: add them so cuil.si never contacts them either. curl -X POST "https://cuil.si/api/v1/suppressions" -H "Authorization: Bearer $CUILSI_API_KEY" \ -H "Content-Type: application/json" \ -d '{"kind": "email", "value": "[email protected]", "reason": "unsubscribed", "source": "my-crm"}'4Move them along the pipeline
PATCH /leads/{lead_id}with astagemoves the lead and its deal. Add a webhook forlead.created,lead.stage_changed,deal.wonanddeal.lostto hear about changes made in the app. A CSV import sends onelead.importedinstead of an event for every row.curl -X PATCH "https://cuil.si/api/v1/leads/LEAD_ID" -H "Authorization: Bearer $CUILSI_API_KEY" \ -H "Content-Type: application/json" \ -d '{"stage": "qualified", "deal_value_minor": 2500000}' # The lead (and its deal) moves to "qualified"; 2500000 paise is Rs 25,000. # Stage keys come from GET https://cuil.si/api/v1/pipelines.5Change many at once, and hand out tasks
POST /leads/bulk-actionsmoves, tags, lists or gives up to 500 leads to a teammate in one request, and says which ones it skipped and why.POST /lead-tasksmakes a to-do for your team, such as a call; it is refused for people who said no to that kind of contact.curl -X POST "https://cuil.si/api/v1/leads/bulk-actions" -H "Authorization: Bearer $CUILSI_API_KEY" \ -H "Content-Type: application/json" \ -H "Idempotency-Key: $(uuidgen)" \ -d '{"lead_ids": ["LEAD_ID_1", "LEAD_ID_2"], "action": "add_tag", "tag": "trade fair"}' # { "done": 1, "skipped": [ { "lead_id": "LEAD_ID_2", "reason": "We couldn't find this lead." } ] } curl -X POST "https://cuil.si/api/v1/lead-tasks" -H "Authorization: Bearer $CUILSI_API_KEY" \ -H "Content-Type: application/json" \ -d '{"lead_id": "LEAD_ID_1", "kind": "call", "title": "Call about the quote", "due_at": "2026-11-02T10:00:00+05:30"}' # 201 { "id": "...", "kind": "call", "status": "open", ..., "warning": null }