A REST API and signed webhooks to connect Grocito CRM with your website, app, ERP or billing system — JSON over HTTPS, keys you control, Indian mobile numbers handled for you.
The Grocito CRM API lets your own software work with your CRM over HTTPS: add leads from your website or app, keep another system in step, or pull leads, deals, quotations, invoices and store orders into your own reports. Webhooks tell your server as soon as something changes.
Leads — list, find by mobile or email, create (with duplicate handling), update, archive and restore.
Notes, deals and reminders on a lead; mark reminders done.
Read call logs, team members and your CRM settings (statuses, sources, custom fields, deal stages).
Read quotations and invoices (Quotation Manager plugin) and online-store orders and customers (E-commerce plugin).
Webhooks for 14 events — signed, retried, with a delivery log in the CRM.
Who can use it
API & Webhooks is a plugin on paid plans — when your plan includes it, organisation admins see API & Webhooks in the CRM menu. Using the API costs nothing extra; each plan has a daily allowance:
API allowance by plan
Plan
API calls a day
Webhooks
Starter
2,000
1
Growth
10,000
5
Pro / Business
50,000
10
Free trial
500 (read-only)
None
These are the standard limits; a plan or an organisation can be set up with different ones. GET /me shows the limits that apply to your key. See Pricing for the plans.
Get an API key
Open API & Webhooks → Keys in the CRM, signed in as the organisation owner or an admin. Creating a key needs a sign-in within the last 10 minutes, and two-step verification applies if you use it.
Choose what the key may do: a name, the team member it acts as, its scopes, when it expires (30, 90 or 365 days, or never) and, if you like, the IP addresses it may be used from. You can also choose how leads created with the key are assigned (round robin).
Copy the key — it is shown once. Keep it in your server’s secret settings, never in a web page, mobile app or code repository.
Rotate or revoke any time. Rotating gives a new secret and the old one stops working immediately — unless you tick Keep the old key working for 24 hours to switch over gently. Revoking stops the key at once. If a key has leaked, revoke it and create a new one.
An organisation can have up to 10 keys (2 on a trial).
Revoking or rotating a key takes effect within a few seconds. Blocking a member, changing their role, or suspending the organisation takes effect within 1 minute.
Authentication
Send the key in the Authorization header of every request, over HTTPS:
HTTP header
Authorization: Bearer YOUR_API_KEY
Keys look like grc_live_<key id>_<secret>. Only the Authorization: Bearer header is accepted.
A key sent in the URL (for example ?api_key=…) is refused with 400 key_in_query. Revoke that key and create a new one — addresses end up in logs.
A missing, wrong, expired or revoked key, or one used from an address outside its IP allow-list, gets the same 401 invalid_key.
More than 30 failed authentications in a minute from one IP address get 429 for a minute.
The API is for servers. It sends no CORS headers, so browsers cannot call it directly — which also keeps your key out of web pages.
Check your key
GET /me returns the organisation, the team member the key acts as, its scopes and its limits.
// Check the key: organisation, member and scopes (Node.js 18+)
const res = await fetch('https://asia-south2-sales-crm-grc.cloudfunctions.net/publicApi/v1/me', {
headers: { Authorization: 'Bearer YOUR_API_KEY' },
});
const body = await res.json();
if (!res.ok) throw new Error(body.error?.message || res.statusText);
console.log(body.data);
<?php
// Check the key: organisation, member and scopes
$ch = curl_init('https://asia-south2-sales-crm-grc.cloudfunctions.net/publicApi/v1/me');
curl_setopt_array($ch, [
CURLOPT_RETURNTRANSFER => true,
CURLOPT_HTTPHEADER => ['Authorization: Bearer YOUR_API_KEY'],
]);
$body = json_decode(curl_exec($ch), true);
$status = curl_getinfo($ch, CURLINFO_HTTP_CODE);
curl_close($ch);
if ($status >= 400) { throw new Exception($body['error']['message'] ?? 'Request failed'); }
print_r($body['data']);
# Check the key: organisation, member and scopes
import requests
res = requests.get(
"https://asia-south2-sales-crm-grc.cloudfunctions.net/publicApi/v1/me",
headers={"Authorization": "Bearer YOUR_API_KEY"},
timeout=30,
)
body = res.json()
if not res.ok:
raise RuntimeError(body["error"]["message"])
print(body["data"])
Keys act as a team member
Each key acts as one team member you choose when you create it (by default, the admin creating it).
It sees and changes only what that member can in the CRM: their data scope (their own leads, their team’s, or all) and the rights of their role. A scope on the key never adds a right the member does not have.
Records the key creates or changes are created or changed by that member; the lead’s activity shows the key’s name with “(API)”.
List endpoints also need the member’s export right in the CRM (admins always have it).
If the member is blocked or leaves the organisation, the key stops working (403 acts_as_inactive) — create a new one.
A key also stops working (401 invalid_key) when the admin who created it is no longer an active admin. A current admin can rotate it to take it over, or revoke it.
The platform can lock an organisation’s API & Webhooks (for example after a security problem). While it is locked, admins cannot create keys or webhooks, rotate keys or turn webhooks back on.
API writes behave like edits in the CRM. Automations run and the assignee is notified, just as when someone saves the lead. Zapier and Microsoft Teams relays are not triggered by API writes — use webhooks if another system needs to hear about them. During a free trial the API is read-only.
Requests and responses
Base URLhttps://asia-south2-sales-crm-grc.cloudfunctions.net/publicApi/v1
JSON with snake_case field names. Times are ISO-8601 in UTC (2026-11-02T06:45:12.000Z); a date or time you send without a zone is read as India time.
Bodies are Content-Type: application/json, at most 256 KB. A field the endpoint does not take is refused (422 unknown_field), and so is an unknown query parameter (400 unknown_parameter) — typos never pass silently.
One record comes back as {"data": {…}}; a list as {"data": […], "next_cursor": "…"}.
Every answer carries X-Request-Id (quote it when you contact support) and RateLimit-Limit, RateLimit-Remaining, RateLimit-Reset. Retry-After (seconds) comes with 429 and 503.
{
"error": {
"code": "invalid_mobile",
"message": "mobile must be an Indian mobile number (10 digits, optionally with +91 / 0).",
"field": "mobile",
"request_id": "req_5d1c0f7a9b2e4c6d8a0b1c2d"
}
}
Indian mobile numbers
Send mobile in any common Indian form. It is stored as the 10 digits, the same way the CRM’s own import stores it, so duplicates are found whichever form was used.
Accepted mobile formats
You send
Stored as
9876543210
9876543210
+91 98765 43210
9876543210
0 98765 43210
9876543210
91-98765-43210
9876543210
Anything that does not come to 10 digits is refused with 422 invalid_mobile.
For a number outside India, leave mobile out and send phone_international with + and the country code (for example +44 7911 123456).
A new lead needs a name and at least one of mobile, phone_international or email.
GET /leads?mobile=… accepts the same forms and returns every lead with that number.
Duplicates
When you create a lead, Grocito first looks for a lead with the same mobile, then one with the same email. on_duplicate decides what happens:
on_duplicate values
on_duplicate
What happens
error
Default. 409 duplicate_lead, with existing_lead_id when the key may see that lead.
return
Nothing is created; 200 with the existing lead.
merge
Only the existing lead’s empty fields are filled — nothing is overwritten; 200 with the lead.
Pagination
Lists take limit from 1 to 100 (default 25). Leads come newest first (sort=updated_at for the most recently changed).
When there is more, the answer has a next_cursor. Send it back as cursor with the same filters for the next page; null means the end. Cursors are opaque and signed — they only work for the same key, list and filters.
A page can hold fewer items than limit while next_cursor is still set. Keep going until next_cursor is null.
The mobile and email filters return every match at once, without a cursor.
Idempotency
Network errors happen. Send an Idempotency-Key header (any unique text up to 255 characters, such as a UUID) with a POST, and you can safely send it again:
The same key with the same body within 24 hours gets the first answer again, with Idempotent-Replayed: true. Nothing is created twice.
The same key with a different body gets 422 idempotency_mismatch.
While the first request is still running, a repeat gets 409 idempotency_in_progress — retry a moment later.
Limits
Request limits
Limit
Standard value
Requests per key
120 a minute
Requests per organisation
300 a minute
Calls per organisation per day
By plan — see Who can use it. The day resets at midnight India time.
Failed authentications per IP address
30 a minute
Request body
256 KB
Over a limit you get 429 (rate_limited or daily_quota_exceeded) with Retry-After in seconds. Read RateLimit-Remaining to slow down before you reach it.
Errors
Errors use the HTTP status and a JSON body: {"error": {"code", "message", "field", "request_id"}}. field is there when one field is at fault. Branch on code; show message to people.
HTTP statuses
Status
Meaning
400
Bad request (invalid JSON / parameter / cursor, key in the URL).
401
Invalid or missing API key (one message for every reason — unknown, wrong, revoked, expired, IP not allowed, or its creator is no longer an active admin).
403
Scope missing, member lacks the right, read-only trial, plugin off, organisation inactive, acts-as member inactive.
404
Not found — or not visible to this key (other organisation / outside the member's data scope).
409
Duplicate lead / Idempotency-Key still in progress.
Rate limit / daily quota / too many failed authentications. See Retry-After.
503
API switched off or temporarily unavailable. See Retry-After.
Error codes
Error codes
Status
Code
What it means
400
invalid_json
The body is not a valid JSON object.
400
invalid_parameter
A query parameter has a wrong value (see field).
400
unknown_parameter
A query parameter this endpoint does not take.
400
invalid_cursor
The cursor is not one this API gave out, or belongs to another list or key.
400
invalid_idempotency_key
The Idempotency-Key header is empty or too long (255 characters at most).
400
key_in_query
A key was sent in the URL. The request is refused — revoke that key and create a new one, since URLs end up in logs.
401
invalid_key
The key is missing, wrong, expired, revoked or not allowed from this IP address, or the admin who created it is no longer an active admin (one message for every reason).
402
wallet_empty
Only if per-call pricing is ever switched on (it is free today): the organisation’s wallet is empty.
403
insufficient_scope
The key does not have the scope this endpoint needs — or the member it acts as does not have that right in the CRM.
403
not_allowed
Only a reminder’s creator, its assignee or an admin key can complete it.
403
export_not_allowed
Lists need the member’s export right in the CRM (admins always have it).
403
read_only
The organisation is on a trial — the API is read-only.
403
plugin_disabled
API & Webhooks, or the plugin an endpoint needs (Quotation Manager, E-commerce), is not on the plan.
403
organisation_inactive
The organisation’s subscription is not active.
403
acts_as_inactive
The member the key acts as is blocked or removed. Create a new key.
403
lead_limit_reached
The plan’s lead limit is reached.
404
not_found
No such record — or the key may not see it (another organisation, or outside the member’s data scope).
405
method_not_allowed
The path exists but not with this method.
409
duplicate_lead
A lead with this mobile (or email) exists. existing_lead_id is included when the key can see it.
409
idempotency_in_progress
A request with the same Idempotency-Key is still running. Retry shortly.
413
payload_too_large
The body is over 256 KB.
413
lead_too_large
The lead would grow past the size a record can hold.
415
unsupported_media_type
Send the body with Content-Type: application/json.
422
unknown_field
The body has a field this endpoint does not take (field names it).
422
missing_field
A required field is missing.
422
invalid_mobile
The mobile is not a valid Indian mobile. Use phone_international for other countries.
422
invalid_phone
phone_international needs + and the country code, 8 to 15 digits.
All paths are relative to the base URL https://asia-south2-sales-crm-grc.cloudfunctions.net/publicApi/v1. Replace YOUR_API_KEY and the …_ID placeholders in the samples.
Your key
Check a key: its organisation, the team member it acts as, its scopes and limits.
// Check the key: organisation, member and scopes (Node.js 18+)
const res = await fetch('https://asia-south2-sales-crm-grc.cloudfunctions.net/publicApi/v1/me', {
headers: { Authorization: 'Bearer YOUR_API_KEY' },
});
const body = await res.json();
if (!res.ok) throw new Error(body.error?.message || res.statusText);
console.log(body.data);
<?php
// Check the key: organisation, member and scopes
$ch = curl_init('https://asia-south2-sales-crm-grc.cloudfunctions.net/publicApi/v1/me');
curl_setopt_array($ch, [
CURLOPT_RETURNTRANSFER => true,
CURLOPT_HTTPHEADER => ['Authorization: Bearer YOUR_API_KEY'],
]);
$body = json_decode(curl_exec($ch), true);
$status = curl_getinfo($ch, CURLINFO_HTTP_CODE);
curl_close($ch);
if ($status >= 400) { throw new Exception($body['error']['message'] ?? 'Request failed'); }
print_r($body['data']);
# Check the key: organisation, member and scopes
import requests
res = requests.get(
"https://asia-south2-sales-crm-grc.cloudfunctions.net/publicApi/v1/me",
headers={"Authorization": "Bearer YOUR_API_KEY"},
timeout=30,
)
body = res.json()
if not res.ok:
raise RuntimeError(body["error"]["message"])
print(body["data"])
Leads
List, read, create, update, archive and restore leads.
# List the 20 newest leads
import requests
res = requests.get(
"https://asia-south2-sales-crm-grc.cloudfunctions.net/publicApi/v1/leads?limit=20",
headers={"Authorization": "Bearer YOUR_API_KEY"},
timeout=30,
)
body = res.json()
if not res.ok:
raise RuntimeError(body["error"]["message"])
print(body["data"])
Repeat a POST safely: the same key + same body within 24 h returns the first answer (Idempotent-Replayed: true). More
Body application/json
namestringrequired
Required. Up to 200 characters.
mobilestring
Indian mobile in any common form: 9876543210, +91 98765 43210, 098765 43210. Stored as 10 digits.
phone_internationalstring
A non-Indian number with its country code (e.g. +44 7911 123456). Use instead of mobile.
emailstring
—
statusstring
One of GET /v1/config statuses (case-insensitive). Default: the first status.
sourcestring
One of GET /v1/config sources. Default: API.
prioritystring
One of GET /v1/config priorities. Default: Medium.
assigned_tostring
User id of an active member. Default: the key's round robin, else unassigned.
remarkstring
Up to 5000 characters.
companystring
—
received_atstring
ISO-8601 date or date-time (India time when no zone).
custom_fieldsobject
By custom field id or label.
on_duplicatestring
What to do when a lead with the same mobile (or email) exists: error (409, default), return (200 with the existing lead), merge (fill its empty fields). One of: error, return, merge
Returns
200on_duplicate=return / merge: the existing lead: data = Lead
curl -X POST https://asia-south2-sales-crm-grc.cloudfunctions.net/publicApi/v1/leads \
-H "Authorization: Bearer YOUR_API_KEY" \
-H "Content-Type: application/json" \
-H "Idempotency-Key: 7f9c2a4e-5b1d-4c3e-9a8f-2d6b0e1c4f7a" \
-d '{"name":"Asha Verma","mobile":"+91 98765 43210","email":"asha@example.com","source":"Website","remark":"Asked for a demo"}'
// Create a lead (Node.js 18+). Re-sending with the same Idempotency-Key never creates a second lead.
const res = await fetch('https://asia-south2-sales-crm-grc.cloudfunctions.net/publicApi/v1/leads', {
method: 'POST',
headers: {
Authorization: 'Bearer YOUR_API_KEY',
'Content-Type': 'application/json',
'Idempotency-Key': '7f9c2a4e-5b1d-4c3e-9a8f-2d6b0e1c4f7a',
},
body: JSON.stringify({
"name": "Asha Verma",
"mobile": "+91 98765 43210",
"email": "asha@example.com",
"source": "Website",
"remark": "Asked for a demo"
}),
});
const body = await res.json();
if (!res.ok) throw new Error(body.error?.message || res.statusText);
console.log(body.data.id);
<?php
// Create a lead. Re-sending with the same Idempotency-Key never creates a second lead.
$lead = [
'name' => 'Asha Verma',
'mobile' => '+91 98765 43210',
'email' => 'asha@example.com',
'source' => 'Website',
'remark' => 'Asked for a demo',
];
$ch = curl_init('https://asia-south2-sales-crm-grc.cloudfunctions.net/publicApi/v1/leads');
curl_setopt_array($ch, [
CURLOPT_RETURNTRANSFER => true,
CURLOPT_POST => true,
CURLOPT_POSTFIELDS => json_encode($lead),
CURLOPT_HTTPHEADER => [
'Authorization: Bearer YOUR_API_KEY',
'Content-Type: application/json',
'Idempotency-Key: 7f9c2a4e-5b1d-4c3e-9a8f-2d6b0e1c4f7a',
],
]);
$body = json_decode(curl_exec($ch), true);
$status = curl_getinfo($ch, CURLINFO_HTTP_CODE);
curl_close($ch);
if ($status >= 400) { throw new Exception($body['error']['message'] ?? 'Request failed'); }
echo $body['data']['id'];
# Create a lead. Re-sending with the same Idempotency-Key never creates a second lead.
import requests
lead = {
"name": "Asha Verma",
"mobile": "+91 98765 43210",
"email": "asha@example.com",
"source": "Website",
"remark": "Asked for a demo",
}
res = requests.post(
"https://asia-south2-sales-crm-grc.cloudfunctions.net/publicApi/v1/leads",
json=lead,
headers={
"Authorization": "Bearer YOUR_API_KEY",
"Idempotency-Key": "7f9c2a4e-5b1d-4c3e-9a8f-2d6b0e1c4f7a",
},
timeout=30,
)
body = res.json()
if not res.ok:
raise RuntimeError(body["error"]["message"])
print(body["data"]["id"])
// Get one lead (Node.js 18+)
const res = await fetch('https://asia-south2-sales-crm-grc.cloudfunctions.net/publicApi/v1/leads/LEAD_ID', {
headers: { Authorization: 'Bearer YOUR_API_KEY' },
});
const body = await res.json();
if (!res.ok) throw new Error(body.error?.message || res.statusText);
console.log(body.data);
<?php
// Get one lead
$ch = curl_init('https://asia-south2-sales-crm-grc.cloudfunctions.net/publicApi/v1/leads/LEAD_ID');
curl_setopt_array($ch, [
CURLOPT_RETURNTRANSFER => true,
CURLOPT_HTTPHEADER => ['Authorization: Bearer YOUR_API_KEY'],
]);
$body = json_decode(curl_exec($ch), true);
$status = curl_getinfo($ch, CURLINFO_HTTP_CODE);
curl_close($ch);
if ($status >= 400) { throw new Exception($body['error']['message'] ?? 'Request failed'); }
print_r($body['data']);
# Get one lead
import requests
res = requests.get(
"https://asia-south2-sales-crm-grc.cloudfunctions.net/publicApi/v1/leads/LEAD_ID",
headers={"Authorization": "Bearer YOUR_API_KEY"},
timeout=30,
)
body = res.json()
if not res.ok:
raise RuntimeError(body["error"]["message"])
print(body["data"])
curl -X PATCH https://asia-south2-sales-crm-grc.cloudfunctions.net/publicApi/v1/leads/LEAD_ID \
-H "Authorization: Bearer YOUR_API_KEY" \
-H "Content-Type: application/json" \
-d '{"priority":"High","remark":"Wants pricing for 25 users; call back on Monday"}'
// Update a lead — only the fields you send change (Node.js 18+)
const res = await fetch('https://asia-south2-sales-crm-grc.cloudfunctions.net/publicApi/v1/leads/LEAD_ID', {
method: 'PATCH',
headers: {
Authorization: 'Bearer YOUR_API_KEY',
'Content-Type': 'application/json',
},
body: JSON.stringify({
"priority": "High",
"remark": "Wants pricing for 25 users; call back on Monday"
}),
});
const body = await res.json();
if (!res.ok) throw new Error(body.error?.message || res.statusText);
console.log(body.data);
<?php
// Update a lead — only the fields you send change
$data = [
'priority' => 'High',
'remark' => 'Wants pricing for 25 users; call back on Monday',
];
$ch = curl_init('https://asia-south2-sales-crm-grc.cloudfunctions.net/publicApi/v1/leads/LEAD_ID');
curl_setopt_array($ch, [
CURLOPT_RETURNTRANSFER => true,
CURLOPT_CUSTOMREQUEST => 'PATCH',
CURLOPT_POSTFIELDS => json_encode($data),
CURLOPT_HTTPHEADER => [
'Authorization: Bearer YOUR_API_KEY',
'Content-Type: application/json',
],
]);
$body = json_decode(curl_exec($ch), true);
$status = curl_getinfo($ch, CURLINFO_HTTP_CODE);
curl_close($ch);
if ($status >= 400) { throw new Exception($body['error']['message'] ?? 'Request failed'); }
print_r($body['data']);
# Update a lead — only the fields you send change
import requests
data = {
"priority": "High",
"remark": "Wants pricing for 25 users; call back on Monday",
}
res = requests.patch(
"https://asia-south2-sales-crm-grc.cloudfunctions.net/publicApi/v1/leads/LEAD_ID",
json=data,
headers={"Authorization": "Bearer YOUR_API_KEY"},
timeout=30,
)
body = res.json()
if not res.ok:
raise RuntimeError(body["error"]["message"])
print(body["data"])
# Archive a lead
import requests
data = {
"reason": "Not interested right now",
}
res = requests.post(
"https://asia-south2-sales-crm-grc.cloudfunctions.net/publicApi/v1/leads/LEAD_ID/archive",
json=data,
headers={"Authorization": "Bearer YOUR_API_KEY"},
timeout=30,
)
body = res.json()
if not res.ok:
raise RuntimeError(body["error"]["message"])
print(body["data"])
# Restore an archived lead
import requests
res = requests.post(
"https://asia-south2-sales-crm-grc.cloudfunctions.net/publicApi/v1/leads/LEAD_ID/unarchive",
headers={"Authorization": "Bearer YOUR_API_KEY"},
timeout=30,
)
body = res.json()
if not res.ok:
raise RuntimeError(body["error"]["message"])
print(body["data"])
Notes
The notes on a lead (shown in the lead’s activity in the CRM).
# List a lead’s notes
import requests
res = requests.get(
"https://asia-south2-sales-crm-grc.cloudfunctions.net/publicApi/v1/leads/LEAD_ID/notes",
headers={"Authorization": "Bearer YOUR_API_KEY"},
timeout=30,
)
body = res.json()
if not res.ok:
raise RuntimeError(body["error"]["message"])
print(body["data"])
curl -X POST https://asia-south2-sales-crm-grc.cloudfunctions.net/publicApi/v1/leads/LEAD_ID/notes \
-H "Authorization: Bearer YOUR_API_KEY" \
-H "Content-Type: application/json" \
-d '{"text":"Spoke on the phone — wants a demo on Friday at 4 pm."}'
// Add a note to a lead (Node.js 18+)
const res = await fetch('https://asia-south2-sales-crm-grc.cloudfunctions.net/publicApi/v1/leads/LEAD_ID/notes', {
method: 'POST',
headers: {
Authorization: 'Bearer YOUR_API_KEY',
'Content-Type': 'application/json',
},
body: JSON.stringify({
"text": "Spoke on the phone — wants a demo on Friday at 4 pm."
}),
});
const body = await res.json();
if (!res.ok) throw new Error(body.error?.message || res.statusText);
console.log(body.data);
<?php
// Add a note to a lead
$data = [
'text' => 'Spoke on the phone — wants a demo on Friday at 4 pm.',
];
$ch = curl_init('https://asia-south2-sales-crm-grc.cloudfunctions.net/publicApi/v1/leads/LEAD_ID/notes');
curl_setopt_array($ch, [
CURLOPT_RETURNTRANSFER => true,
CURLOPT_CUSTOMREQUEST => 'POST',
CURLOPT_POSTFIELDS => json_encode($data),
CURLOPT_HTTPHEADER => [
'Authorization: Bearer YOUR_API_KEY',
'Content-Type: application/json',
],
]);
$body = json_decode(curl_exec($ch), true);
$status = curl_getinfo($ch, CURLINFO_HTTP_CODE);
curl_close($ch);
if ($status >= 400) { throw new Exception($body['error']['message'] ?? 'Request failed'); }
print_r($body['data']);
# Add a note to a lead
import requests
data = {
"text": "Spoke on the phone — wants a demo on Friday at 4 pm.",
}
res = requests.post(
"https://asia-south2-sales-crm-grc.cloudfunctions.net/publicApi/v1/leads/LEAD_ID/notes",
json=data,
headers={"Authorization": "Bearer YOUR_API_KEY"},
timeout=30,
)
body = res.json()
if not res.ok:
raise RuntimeError(body["error"]["message"])
print(body["data"])
Deals
Deals sit on a lead. Stage keys come from GET /config.
# List a lead’s deals
import requests
res = requests.get(
"https://asia-south2-sales-crm-grc.cloudfunctions.net/publicApi/v1/leads/LEAD_ID/deals",
headers={"Authorization": "Bearer YOUR_API_KEY"},
timeout=30,
)
body = res.json()
if not res.ok:
raise RuntimeError(body["error"]["message"])
print(body["data"])
# Add a deal to a lead
import requests
data = {
"title": "Annual plan — 25 users",
"value": 45000,
"expected_close_date": "2026-12-15",
}
res = requests.post(
"https://asia-south2-sales-crm-grc.cloudfunctions.net/publicApi/v1/leads/LEAD_ID/deals",
json=data,
headers={"Authorization": "Bearer YOUR_API_KEY"},
timeout=30,
)
body = res.json()
if not res.ok:
raise RuntimeError(body["error"]["message"])
print(body["data"])
# Get one deal
import requests
res = requests.get(
"https://asia-south2-sales-crm-grc.cloudfunctions.net/publicApi/v1/leads/LEAD_ID/deals/DEAL_ID",
headers={"Authorization": "Bearer YOUR_API_KEY"},
timeout=30,
)
body = res.json()
if not res.ok:
raise RuntimeError(body["error"]["message"])
print(body["data"])
PATCH/leads/{id}/deals/{dealId}
Update a deal (stage / value / title / close date …)
curl -X POST https://asia-south2-sales-crm-grc.cloudfunctions.net/publicApi/v1/leads/LEAD_ID/reminders \
-H "Authorization: Bearer YOUR_API_KEY" \
-H "Content-Type: application/json" \
-d '{"date_time":"2026-11-10T11:00:00+05:30","remark":"Call back about the quotation"}'
// Add a reminder (India time when the zone is left out) (Node.js 18+)
const res = await fetch('https://asia-south2-sales-crm-grc.cloudfunctions.net/publicApi/v1/leads/LEAD_ID/reminders', {
method: 'POST',
headers: {
Authorization: 'Bearer YOUR_API_KEY',
'Content-Type': 'application/json',
},
body: JSON.stringify({
"date_time": "2026-11-10T11:00:00+05:30",
"remark": "Call back about the quotation"
}),
});
const body = await res.json();
if (!res.ok) throw new Error(body.error?.message || res.statusText);
console.log(body.data);
<?php
// Add a reminder (India time when the zone is left out)
$data = [
'date_time' => '2026-11-10T11:00:00+05:30',
'remark' => 'Call back about the quotation',
];
$ch = curl_init('https://asia-south2-sales-crm-grc.cloudfunctions.net/publicApi/v1/leads/LEAD_ID/reminders');
curl_setopt_array($ch, [
CURLOPT_RETURNTRANSFER => true,
CURLOPT_CUSTOMREQUEST => 'POST',
CURLOPT_POSTFIELDS => json_encode($data),
CURLOPT_HTTPHEADER => [
'Authorization: Bearer YOUR_API_KEY',
'Content-Type: application/json',
],
]);
$body = json_decode(curl_exec($ch), true);
$status = curl_getinfo($ch, CURLINFO_HTTP_CODE);
curl_close($ch);
if ($status >= 400) { throw new Exception($body['error']['message'] ?? 'Request failed'); }
print_r($body['data']);
# Add a reminder (India time when the zone is left out)
import requests
data = {
"date_time": "2026-11-10T11:00:00+05:30",
"remark": "Call back about the quotation",
}
res = requests.post(
"https://asia-south2-sales-crm-grc.cloudfunctions.net/publicApi/v1/leads/LEAD_ID/reminders",
json=data,
headers={"Authorization": "Bearer YOUR_API_KEY"},
timeout=30,
)
body = res.json()
if not res.ok:
raise RuntimeError(body["error"]["message"])
print(body["data"])
// List reminders (by due time, latest first) — 20 per page (Node.js 18+)
const res = await fetch('https://asia-south2-sales-crm-grc.cloudfunctions.net/publicApi/v1/reminders?limit=20', {
headers: { Authorization: 'Bearer YOUR_API_KEY' },
});
const body = await res.json();
if (!res.ok) throw new Error(body.error?.message || res.statusText);
console.log(body.data);
<?php
// List reminders (by due time, latest first) — 20 per page
$ch = curl_init('https://asia-south2-sales-crm-grc.cloudfunctions.net/publicApi/v1/reminders?limit=20');
curl_setopt_array($ch, [
CURLOPT_RETURNTRANSFER => true,
CURLOPT_HTTPHEADER => ['Authorization: Bearer YOUR_API_KEY'],
]);
$body = json_decode(curl_exec($ch), true);
$status = curl_getinfo($ch, CURLINFO_HTTP_CODE);
curl_close($ch);
if ($status >= 400) { throw new Exception($body['error']['message'] ?? 'Request failed'); }
print_r($body['data']);
# List reminders (by due time, latest first) — 20 per page
import requests
res = requests.get(
"https://asia-south2-sales-crm-grc.cloudfunctions.net/publicApi/v1/reminders?limit=20",
headers={"Authorization": "Bearer YOUR_API_KEY"},
timeout=30,
)
body = res.json()
if not res.ok:
raise RuntimeError(body["error"]["message"])
print(body["data"])
# Get a reminder
import requests
res = requests.get(
"https://asia-south2-sales-crm-grc.cloudfunctions.net/publicApi/v1/reminders/REMINDER_ID",
headers={"Authorization": "Bearer YOUR_API_KEY"},
timeout=30,
)
body = res.json()
if not res.ok:
raise RuntimeError(body["error"]["message"])
print(body["data"])
POST/reminders/{id}/complete
Mark a reminder done (its creator, its assignee or an admin key)
# Mark a reminder done
import requests
res = requests.post(
"https://asia-south2-sales-crm-grc.cloudfunctions.net/publicApi/v1/reminders/REMINDER_ID/complete",
headers={"Authorization": "Bearer YOUR_API_KEY"},
timeout=30,
)
body = res.json()
if not res.ok:
raise RuntimeError(body["error"]["message"])
print(body["data"])
# List call logs (newest first) — 20 per page
import requests
res = requests.get(
"https://asia-south2-sales-crm-grc.cloudfunctions.net/publicApi/v1/calls?limit=20",
headers={"Authorization": "Bearer YOUR_API_KEY"},
timeout=30,
)
body = res.json()
if not res.ok:
raise RuntimeError(body["error"]["message"])
print(body["data"])
# Get a call log
import requests
res = requests.get(
"https://asia-south2-sales-crm-grc.cloudfunctions.net/publicApi/v1/calls/CALL_ID",
headers={"Authorization": "Bearer YOUR_API_KEY"},
timeout=30,
)
body = res.json()
if not res.ok:
raise RuntimeError(body["error"]["message"])
print(body["data"])
Team members
Your organisation’s members (read only) — use their ids for assigned_to.
// List team members (Node.js 18+)
const res = await fetch('https://asia-south2-sales-crm-grc.cloudfunctions.net/publicApi/v1/users', {
headers: { Authorization: 'Bearer YOUR_API_KEY' },
});
const body = await res.json();
if (!res.ok) throw new Error(body.error?.message || res.statusText);
console.log(body.data);
<?php
// List team members
$ch = curl_init('https://asia-south2-sales-crm-grc.cloudfunctions.net/publicApi/v1/users');
curl_setopt_array($ch, [
CURLOPT_RETURNTRANSFER => true,
CURLOPT_HTTPHEADER => ['Authorization: Bearer YOUR_API_KEY'],
]);
$body = json_decode(curl_exec($ch), true);
$status = curl_getinfo($ch, CURLINFO_HTTP_CODE);
curl_close($ch);
if ($status >= 400) { throw new Exception($body['error']['message'] ?? 'Request failed'); }
print_r($body['data']);
# List team members
import requests
res = requests.get(
"https://asia-south2-sales-crm-grc.cloudfunctions.net/publicApi/v1/users",
headers={"Authorization": "Bearer YOUR_API_KEY"},
timeout=30,
)
body = res.json()
if not res.ok:
raise RuntimeError(body["error"]["message"])
print(body["data"])
// Get a team member (Node.js 18+)
const res = await fetch('https://asia-south2-sales-crm-grc.cloudfunctions.net/publicApi/v1/users/USER_ID', {
headers: { Authorization: 'Bearer YOUR_API_KEY' },
});
const body = await res.json();
if (!res.ok) throw new Error(body.error?.message || res.statusText);
console.log(body.data);
<?php
// Get a team member
$ch = curl_init('https://asia-south2-sales-crm-grc.cloudfunctions.net/publicApi/v1/users/USER_ID');
curl_setopt_array($ch, [
CURLOPT_RETURNTRANSFER => true,
CURLOPT_HTTPHEADER => ['Authorization: Bearer YOUR_API_KEY'],
]);
$body = json_decode(curl_exec($ch), true);
$status = curl_getinfo($ch, CURLINFO_HTTP_CODE);
curl_close($ch);
if ($status >= 400) { throw new Exception($body['error']['message'] ?? 'Request failed'); }
print_r($body['data']);
# Get a team member
import requests
res = requests.get(
"https://asia-south2-sales-crm-grc.cloudfunctions.net/publicApi/v1/users/USER_ID",
headers={"Authorization": "Bearer YOUR_API_KEY"},
timeout=30,
)
body = res.json()
if not res.ok:
raise RuntimeError(body["error"]["message"])
print(body["data"])
CRM settings
Statuses, sources, priorities, custom fields and deal stages, as set up in your CRM.
# List quotations (Quotation Manager plugin) — 20 per page
import requests
res = requests.get(
"https://asia-south2-sales-crm-grc.cloudfunctions.net/publicApi/v1/quotations?limit=20",
headers={"Authorization": "Bearer YOUR_API_KEY"},
timeout=30,
)
body = res.json()
if not res.ok:
raise RuntimeError(body["error"]["message"])
print(body["data"])
# Get a quotation
import requests
res = requests.get(
"https://asia-south2-sales-crm-grc.cloudfunctions.net/publicApi/v1/quotations/QUOTATION_ID",
headers={"Authorization": "Bearer YOUR_API_KEY"},
timeout=30,
)
body = res.json()
if not res.ok:
raise RuntimeError(body["error"]["message"])
print(body["data"])
Invoices
Read only. Needs the Quotation Manager plugin on your plan.
# List invoices (Quotation Manager plugin) — 20 per page
import requests
res = requests.get(
"https://asia-south2-sales-crm-grc.cloudfunctions.net/publicApi/v1/invoices?limit=20",
headers={"Authorization": "Bearer YOUR_API_KEY"},
timeout=30,
)
body = res.json()
if not res.ok:
raise RuntimeError(body["error"]["message"])
print(body["data"])
# Get an invoice
import requests
res = requests.get(
"https://asia-south2-sales-crm-grc.cloudfunctions.net/publicApi/v1/invoices/INVOICE_ID",
headers={"Authorization": "Bearer YOUR_API_KEY"},
timeout=30,
)
body = res.json()
if not res.ok:
raise RuntimeError(body["error"]["message"])
print(body["data"])
Store orders
Read only. Needs the E-commerce (online store) plugin on your plan.
// List online store orders (E-commerce plugin) — 20 per page (Node.js 18+)
const res = await fetch('https://asia-south2-sales-crm-grc.cloudfunctions.net/publicApi/v1/orders?limit=20', {
headers: { Authorization: 'Bearer YOUR_API_KEY' },
});
const body = await res.json();
if (!res.ok) throw new Error(body.error?.message || res.statusText);
console.log(body.data);
<?php
// List online store orders (E-commerce plugin) — 20 per page
$ch = curl_init('https://asia-south2-sales-crm-grc.cloudfunctions.net/publicApi/v1/orders?limit=20');
curl_setopt_array($ch, [
CURLOPT_RETURNTRANSFER => true,
CURLOPT_HTTPHEADER => ['Authorization: Bearer YOUR_API_KEY'],
]);
$body = json_decode(curl_exec($ch), true);
$status = curl_getinfo($ch, CURLINFO_HTTP_CODE);
curl_close($ch);
if ($status >= 400) { throw new Exception($body['error']['message'] ?? 'Request failed'); }
print_r($body['data']);
# List online store orders (E-commerce plugin) — 20 per page
import requests
res = requests.get(
"https://asia-south2-sales-crm-grc.cloudfunctions.net/publicApi/v1/orders?limit=20",
headers={"Authorization": "Bearer YOUR_API_KEY"},
timeout=30,
)
body = res.json()
if not res.ok:
raise RuntimeError(body["error"]["message"])
print(body["data"])
// Get a store order (Node.js 18+)
const res = await fetch('https://asia-south2-sales-crm-grc.cloudfunctions.net/publicApi/v1/orders/ORDER_ID', {
headers: { Authorization: 'Bearer YOUR_API_KEY' },
});
const body = await res.json();
if (!res.ok) throw new Error(body.error?.message || res.statusText);
console.log(body.data);
<?php
// Get a store order
$ch = curl_init('https://asia-south2-sales-crm-grc.cloudfunctions.net/publicApi/v1/orders/ORDER_ID');
curl_setopt_array($ch, [
CURLOPT_RETURNTRANSFER => true,
CURLOPT_HTTPHEADER => ['Authorization: Bearer YOUR_API_KEY'],
]);
$body = json_decode(curl_exec($ch), true);
$status = curl_getinfo($ch, CURLINFO_HTTP_CODE);
curl_close($ch);
if ($status >= 400) { throw new Exception($body['error']['message'] ?? 'Request failed'); }
print_r($body['data']);
# Get a store order
import requests
res = requests.get(
"https://asia-south2-sales-crm-grc.cloudfunctions.net/publicApi/v1/orders/ORDER_ID",
headers={"Authorization": "Bearer YOUR_API_KEY"},
timeout=30,
)
body = res.json()
if not res.ok:
raise RuntimeError(body["error"]["message"])
print(body["data"])
Store customers
Read only. Needs the E-commerce (online store) plugin on your plan.
// List online store customers (E-commerce plugin) — 20 per page (Node.js 18+)
const res = await fetch('https://asia-south2-sales-crm-grc.cloudfunctions.net/publicApi/v1/customers?limit=20', {
headers: { Authorization: 'Bearer YOUR_API_KEY' },
});
const body = await res.json();
if (!res.ok) throw new Error(body.error?.message || res.statusText);
console.log(body.data);
<?php
// List online store customers (E-commerce plugin) — 20 per page
$ch = curl_init('https://asia-south2-sales-crm-grc.cloudfunctions.net/publicApi/v1/customers?limit=20');
curl_setopt_array($ch, [
CURLOPT_RETURNTRANSFER => true,
CURLOPT_HTTPHEADER => ['Authorization: Bearer YOUR_API_KEY'],
]);
$body = json_decode(curl_exec($ch), true);
$status = curl_getinfo($ch, CURLINFO_HTTP_CODE);
curl_close($ch);
if ($status >= 400) { throw new Exception($body['error']['message'] ?? 'Request failed'); }
print_r($body['data']);
# List online store customers (E-commerce plugin) — 20 per page
import requests
res = requests.get(
"https://asia-south2-sales-crm-grc.cloudfunctions.net/publicApi/v1/customers?limit=20",
headers={"Authorization": "Bearer YOUR_API_KEY"},
timeout=30,
)
body = res.json()
if not res.ok:
raise RuntimeError(body["error"]["message"])
print(body["data"])
// Get a store customer (Node.js 18+)
const res = await fetch('https://asia-south2-sales-crm-grc.cloudfunctions.net/publicApi/v1/customers/CUSTOMER_ID', {
headers: { Authorization: 'Bearer YOUR_API_KEY' },
});
const body = await res.json();
if (!res.ok) throw new Error(body.error?.message || res.statusText);
console.log(body.data);
<?php
// Get a store customer
$ch = curl_init('https://asia-south2-sales-crm-grc.cloudfunctions.net/publicApi/v1/customers/CUSTOMER_ID');
curl_setopt_array($ch, [
CURLOPT_RETURNTRANSFER => true,
CURLOPT_HTTPHEADER => ['Authorization: Bearer YOUR_API_KEY'],
]);
$body = json_decode(curl_exec($ch), true);
$status = curl_getinfo($ch, CURLINFO_HTTP_CODE);
curl_close($ch);
if ($status >= 400) { throw new Exception($body['error']['message'] ?? 'Request failed'); }
print_r($body['data']);
# Get a store customer
import requests
res = requests.get(
"https://asia-south2-sales-crm-grc.cloudfunctions.net/publicApi/v1/customers/CUSTOMER_ID",
headers={"Authorization": "Bearer YOUR_API_KEY"},
timeout=30,
)
body = res.json()
if not res.ok:
raise RuntimeError(body["error"]["message"])
print(body["data"])
Objects
What the API sends back. Webhooks carry the same objects.
Me
objectstring
—
organizationobject
—
organization.idstring
—
organization.namestring
—
keyobject
—
key.idstring
—
key.prefixstring
—
key.namestring
—
key.scopesarray of string
—
key.expires_atstring (date-time)can be null
—
acts_asobject
—
acts_as.idstring
—
acts_as.namestring
—
acts_as.rolestring
—
acts_as.data_scopestring
One of: all, team, own
read_onlyboolean
—
limitsobject
—
limits.per_key_per_minuteinteger
—
limits.per_org_per_minuteinteger
—
limits.per_org_per_dayinteger
—
Lead
idstring
—
objectstring
One of: lead
namestring
—
mobilestringcan be null
Indian mobile, 10 digits.
phonestringcan be null
Same as mobile, or an international number with + and country code.
emailstringcan be null
—
statusstringcan be null
—
sourcestringcan be null
—
prioritystringcan be null
—
assigned_tostringcan be null
User id of the owner; null = unassigned.
remarkstringcan be null
—
companystringcan be null
—
archivedboolean
—
archived_atstring (date-time)can be null
—
archived_reasonstringcan be null
—
decline_reasonstringcan be null
—
custom_fieldsobject
Custom field values by field id (see GET /v1/config).
deal_valuenumbercan be null
Value of the primary deal.
primary_deal_idstringcan be null
—
deals_countinteger
—
received_atstring (date-time)can be null
—
created_atstring (date-time)can be null
—
updated_atstring (date-time)can be null
—
created_bystringcan be null
User id (or integration name) that created the lead.
Webhooks send a signed JSON POST to your HTTPS address when leads, notes, deals, reminders, calls or store orders change — 14 events in all. They are set up in the CRM under API & Webhooks → Webhooks.