Adds a new custom attribute to an existing CRM object. Works on both standard objects (people, companies) and custom objects.
The attribute key (slug) is auto-generated from the label. To get the generated key, inspect the key field in the response.
Required scope: crm:write
Type-specific required fields:
select, multiselect, status → options array requiredrelation → relationType, relatedObjectSlug, relatedObjectLabel requiredtext, phone_number, number → isUnique requiredcurrency → currency, currencyDisplay, currencyDecimal, currencyGrouping requiredcurl --request POST \
--url https://api.zeeg.me/v2/crm/objects/{slug}/attributes \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"type": "select",
"label": "Customer Status",
"isRequired": false,
"isUnique": false,
"validation": [],
"options": [
{
"value": "Active",
"color": "success",
"id": 1
}
],
"relationType": "many_to_one",
"relatedObjectSlug": "companies",
"relatedObjectLabel": "Contacts",
"currency": "EUR",
"currencyDisplay": "symbol",
"currencyDecimal": true,
"currencyGrouping": true
}
'{
"success": true,
"status": 201,
"attribute": {
"key": "customer_status",
"label": "Customer Status",
"type": "select",
"isRequired": false,
"isStandard": false,
"isUnique": false,
"isArchived": false,
"options": [
{
"id": 1,
"value": "Lead",
"color": "warning"
},
{
"id": 2,
"value": "Active",
"color": "success"
}
],
"createdAt": "2025-06-15T10:00:00+00:00",
"updatedAt": "2025-06-15T10:00:00+00:00"
}
}Documentation Index
Fetch the complete documentation index at: https://developer.zeeg.me/llms.txt
Use this file to discover all available pages before exploring further.
key — the server derives it from label by converting to snake_case (e.g. "Product Name" → "product_name"). The generated key is returned in the 201 response. Use this key to reference the attribute in subsequent PATCH calls and when writing record values.
If another attribute with the same derived key already exists, the server appends a suffix (e.g. product_name_2).
label, type, isRequired, and isArchived.
The sections below list the extra fields each type needs and what values it stores.
text| Field | Required | Description |
|---|---|---|
isUnique | yes | Reject duplicate values across records. |
validation | no | Array of format validators: "email", "url", or both. |
{
"label": "Work Email",
"type": "text",
"isRequired": false,
"isUnique": true,
"isArchived": false,
"validation": ["email"]
}
number| Field | Required | Description |
|---|---|---|
isUnique | yes | Reject duplicate values across records. |
phone_number| Field | Required | Description |
|---|---|---|
isUnique | yes | Reject duplicate values across records. |
datedatetimecheckboxtrue / false).
No extra fields.
select| Field | Required | Description |
|---|---|---|
options | yes | Array of 1–20 option objects. Each option: value (string), color (named color — see below). Do not include id on create. |
gray primary warning success cyan sky violet fuchsia rose blue green red pink black yellow orange
Example request
{
"label": "Category",
"type": "select",
"isRequired": false,
"isArchived": false,
"options": [
{ "value": "Electronics", "color": "primary" },
{ "value": "Clothing", "color": "success" },
{ "value": "Clearance", "color": "warning" }
]
}
multiselectselect.
Extra fields
Same as select — options array required.
statusselect but rendered as a status badge. Change history is logged for auditing. Same fields as select.
Extra fields
Same as select — options array required.
ratingrelation| Field | Required | Description |
|---|---|---|
relationType | yes | Cardinality: one_to_one, many_to_one, one_to_many, or many_to_many. |
relatedObjectSlug | yes | Slug of the target object (people, companies, or a custom object slug). Immutable after creation. |
relatedObjectLabel | yes | Display label shown for the relation in the UI (e.g. "Person", "Company"). |
one_to_one / many_to_one → the field accepts a single linked record.one_to_many / many_to_many → the field accepts multiple linked records.
Example request
{
"label": "Assigned Person",
"type": "relation",
"isRequired": false,
"isArchived": false,
"relationType": "many_to_one",
"relatedObjectSlug": "people",
"relatedObjectLabel": "Person"
}
currency| Field | Required | Description |
|---|---|---|
currency | yes | ISO 4217 currency code (e.g. EUR, USD, GBP). Immutable after creation. |
currencyDisplay | yes | How the currency is shown: code (EUR 12.00), name (Euro 12.00), or symbol (€12.00). |
currencyDecimal | yes | true to show decimal places. |
currencyGrouping | yes | true to use a thousands separator (1,000.00 vs 1000.00). |
currencyDisplay, currencyDecimal, and currencyGrouping can be changed later via PATCH.
The currency code is immutable after creation.
Supported currency codes
USD, EUR, GBP, JPY, CHF, CAD, AUD, NZD, SEK, DKK, NOK, CZK, PLN, HUF, RON, BRL, MXN,
CNY, SGD, THB, PHP, IDR, INR, ZAR, MYR, VND, KRW, TND, OMR, QAR, SAR, AED, BHD, KWD, JOD, LYD, IRR, TRY.
Example request
{
"label": "Price",
"type": "currency",
"isRequired": false,
"isArchived": false,
"currency": "EUR",
"currencyDisplay": "symbol",
"currencyDecimal": true,
"currencyGrouping": true
}
userThe object slug to add the attribute to.
"people"
Attribute data type. Cannot be changed after creation.
text, number, phone_number, date, datetime, checkbox, select, multiselect, rating, relation, status, user, currency "select"
Human-readable label. The attribute key is auto-generated from this value.
255"Customer Status"
Whether a value is required when creating a record.
false
Whether values must be unique across records. Applies to text, phone, and number types.
false
Validation constraints for text type attributes.
email, url Required for select, multiselect, and status types. Max 20 options.
Hide child attributes
The option label shown in the UI and stored as the attribute value.
512"Active"
Color name for the option. Allowed values: gray, primary, warning, success, cyan, sky, violet, fuchsia, rose, blue, green, red, pink, black, yellow, orange.
"success"
Server-assigned option ID. Omit when adding a new option; include when updating an existing one to preserve it.
1
Required for relation type.
one_to_one, many_to_one, one_to_many, many_to_many "many_to_one"
Required for relation type. Slug of the object to link to.
"companies"
Required for relation type. Label shown on the related object's record.
"Contacts"
Required for currency type. ISO 4217 currency code.
"EUR"
Required for currency type.
code, name, symbol "symbol"
Required for currency type. Show decimal places.
true
Required for currency type. Use thousands separator.
true
Created
true
201
Definition of a single attribute on a CRM object.
Hide child attributes
Attribute key used when reading or writing record values.
"job_title"
Human-readable label shown in the UI.
"Job Title"
Attribute data type. Cannot be changed after creation.
text, number, phone_number, date, datetime, checkbox, select, multiselect, rating, relation, status, user, currency "text"
Whether a value is required when creating a record.
false
true for built-in attributes, false for custom attributes added by your workspace.
false
Whether values must be unique across all records. Applies to text, phone, and number types.
false
Whether the attribute is archived. Archived attributes are hidden from the UI but their data is preserved.
false
ISO 8601 timestamp when the attribute was created.
"2025-06-01T10:00:00+00:00"
ISO 8601 timestamp when the attribute was last updated.
"2025-06-01T10:00:00+00:00"
Available options. Present only for select, multiselect, and status attributes.
Hide child attributes
The option label shown in the UI and stored as the attribute value.
512"Active"
Color name for the option. Allowed values: gray, primary, warning, success, cyan, sky, violet, fuchsia, rose, blue, green, red, pink, black, yellow, orange.
"success"
Server-assigned option ID. Omit when adding a new option; include when updating an existing one to preserve it.
1
Slug of the related object. Present only for relation attributes. Immutable after creation.
"companies"
Display label for the relation. Present only for relation attributes. Can be updated via PATCH.
"Company"
Cardinality of the relation. Present only for relation attributes.
one_to_one, many_to_one, one_to_many, many_to_many "many_to_one"
true when relationType is one_to_many or many_to_many. Present only for relation attributes.
false
ISO 4217 currency code. Present only for currency attributes. Immutable after creation.
"EUR"
How the currency value is displayed. Present only for currency attributes.
code, name, symbol "symbol"
Whether decimal places are shown. Present only for currency attributes.
true
Whether a thousands separator is used. Present only for currency attributes.
true
curl --request POST \
--url https://api.zeeg.me/v2/crm/objects/{slug}/attributes \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"type": "select",
"label": "Customer Status",
"isRequired": false,
"isUnique": false,
"validation": [],
"options": [
{
"value": "Active",
"color": "success",
"id": 1
}
],
"relationType": "many_to_one",
"relatedObjectSlug": "companies",
"relatedObjectLabel": "Contacts",
"currency": "EUR",
"currencyDisplay": "symbol",
"currencyDecimal": true,
"currencyGrouping": true
}
'{
"success": true,
"status": 201,
"attribute": {
"key": "customer_status",
"label": "Customer Status",
"type": "select",
"isRequired": false,
"isStandard": false,
"isUnique": false,
"isArchived": false,
"options": [
{
"id": 1,
"value": "Lead",
"color": "warning"
},
{
"id": 2,
"value": "Active",
"color": "success"
}
],
"createdAt": "2025-06-15T10:00:00+00:00",
"updatedAt": "2025-06-15T10:00:00+00:00"
}
}