Getting started
Three steps to your first request.
For AIDownload .mdAll docs as one Markdown filellms.txt (index)llms-full.txt (all docs)OpenAPI (JSON)
1. Make an API key
Sign in, open Settings > Developers and make a key. Choose only the permissions it needs (for example contacts.read). The key is shown once; keep it somewhere safe. A key works inside its own workspace, as the person who made it, so it can never do more than that person may.
2. Send your first request
Put the key in the Authorization header as a Bearer token:
curl https://hubzone.app/api/open/v1/me \
-H "Authorization: Bearer hzk_your_key_here"3. Read the answer
Every answer is JSON. This one tells you what the key may do and its limits:
{
"keyId": "3f0c8f0e-2b1a-4c55-9a38-0d6c1c9d7e11",
"scopes": ["contacts.read", "contacts.write"],
"limits": { "get": { "label": "Read one record", "perMinute": 600 } },
"allScopes": 14
}Then: list and create records
# the properties (fields) of contacts, with their names and types
curl https://hubzone.app/api/open/v1/properties/contacts -H "Authorization: Bearer $HUBZONE_KEY"
# create a contact
curl -X POST https://hubzone.app/api/open/v1/objects/contacts \
-H "Authorization: Bearer $HUBZONE_KEY" -H "content-type: application/json" \
-d '{"properties":{"first_name":"Ada","last_name":"Lovelace","email":"[email protected]"}}'
# the first 25 contacts that mention "ada"
curl "https://hubzone.app/api/open/v1/objects/contacts?limit=25&q=ada" -H "Authorization: Bearer $HUBZONE_KEY"The kinds of record are: contacts, companies, deals, tickets, products, orders and calls. Properties are always sent and returned under their property names (see "List properties").