API reference
Custom fields
Workspaces add their own fields to leads, contacts, companies and products. Their values live in each record's custom object, keyed by the field's key.
The field object
json
{
"id": "field_01j8z6a0b2c4d6e8f0g2h4j6k8",
"entity": "lead",
"key": "delivery_date",
"label": { "uz-Latn": "Yetkazish sanasi", "ru": "Дата доставки", "en": "Delivery date" },
"type": "date",
"options": [],
"position": 2,
"required": false,
"group": ""
}List fields
GET
/v1/fieldsNo scope neededEvery field definition of the workspace: {"data": [ … ]}. Add ?entity=lead (or contact, company, product) for one record type. No scope is needed.
Creating, changing and deleting fields is reserved for owners and admins in Kweko (Settings → Fields); these endpoints do not accept API keys yet:
POST
/v1/fieldsKweko app onlyPATCH
/v1/fields/{id}Kweko app onlyDELETE
/v1/fields/{id}Kweko app onlyValues by type
Send custom values in custom when you create or update a record. Only the keys you send change; null clears a value (a required field cannot be cleared). An unknown key or a bad value answers validation_failed with the problem under custom.<key> in fields.
| Type | JSON value | Example |
|---|---|---|
text, long_text | string | "Blue, size M" |
number | number | 12.5 |
money | object with an integer amount in the smallest unit and currency (UZS by default) | {"amount": 5000000, "currency": "UZS"} |
date | YYYY-MM-DD | "2026-10-02" |
datetime | RFC 3339, stored in UTC | "2026-10-02T15:00:00+05:00" |
select | the id of one of the field's options | an id from options |
multiselect | a list of option ids, up to 100 | ids from options |
checkbox | true or false | true |
phone | a phone number, normalized like contact phones | "+998901234567" |
email | an email address, lowercased | "[email protected]" |
url | a URL | "https://example.uz" |
member | a member id | "member_01j8…" |
rating | an integer from 1 to 5 | 4 |
Request
curl -X PATCH https://api.kweko.uz/v1/leads/lead_01j8z7c2d4f6g8h0j2k4m6n8p0 \
-H "Authorization: Bearer $KWEKO_API_KEY" \
-H "Content-Type: application/json" \
-d '{"custom": {"delivery_date": "2026-10-02", "gift_wrap": true}}'