API request
Send a lead from your own server, a WordPress plugin or any form tool with one HTTP request.
Use this when you already have a form and want its answers to arrive in the CRM. It is one POST with your key in a header.
curl -X POST 'https://api.crm.thevisionsage.com/v1/capture/leads' \
-H 'Content-Type: application/json' \
-H 'X-Capture-Key: vsk_YOUR_KEY' \
-d '{
"name": "Priya Sharma",
"phone": "9876500001",
"email": "priya@example.com",
"product": "Data Science",
"message": "Interested in the weekend batch",
"utm_source": "google",
"utm_campaign": "diwali"
}'What you can send
| Field | Notes |
|---|---|
| name | Required. |
| phone / email | At least one. A known phone or email adds a repeat enquiry to that lead. |
| source, subSource | Names, matched ignoring capital letters. See how the source is chosen. |
| product, branch | Names, matched ignoring capital letters. Send the course with every enquiry. |
| whatsapp, city, state | Optional details. |
| message | What they wrote. Shown on the enquiry. |
| utm_source, utm_medium, utm_campaign, utm_term, utm_content | Campaign tracking, stored on the enquiry. |
| gclid, fbclid | Ad click ids. |
| landingPage, referrer | The page they landed on and the site that sent them. |
| campaign_token | From a campaign link, to tie the fill to the person emailed. |
| anything else | Up to 20 extra fields (qualification, budget) are kept on the enquiry. |
| _gotcha | A hidden spam trap. Leave it empty; bots that fill it are ignored. |
Answers and limits
- A good request answers with success. A wrong one explains which field to fix.
- Each network address may send 60 requests every 15 minutes: enough for an office testing a form.
- A request body can be up to 64 KB.
- Any website may post: no cookies are involved, only your key.
Something missing or unclear? Tell us and we will fix this page.