Add a field to an object
heliyos_fields_createAdds a single custom field (column) to companies, people, deals, or custom objects by specifying object type, label, and type; supports select options and AI prompts.
Instructions
Adds one field (column) to an object: companies, people, deals or a custom object (object_type, plus schema_id for custom). Give it a label and a type; select and multiSelect need options; ai_prompt makes it an AI column. The field key (what record fields and filters use) is derived from the label unless key is given, and must be new on the object. Relationship fields are created in the Heliyos web app. Calling this twice with the same key fails. Returns structuredContent {field:{field_id, key, label, type}}.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| key | No | Field key, for example contract_value. Derived from the label when omitted. | |
| type | Yes | One of text, richText, number, currency, rating, checkbox, date, timestamp, select, multiSelect, url, email, phone, user, image, file. | |
| label | Yes | Display name, for example "Contract value". | |
| hidden | No | Hidden from the web app's tables by default. Default false. | |
| options | No | Allowed values of a select or multiSelect field, unique. | |
| required | No | Records must have a value. Default false. | |
| ai_prompt | No | Makes this an AI column: the workers fill it from this prompt (text, richText, number, date, select, multiSelect or checkbox only). Filling existing records is started from the Heliyos web app and uses credits. | |
| schema_id | No | Object schema id. Required when object_type is "custom"; the error lists the available ones. | |
| visibility | No | "organization" (default): every member sees it; "private": only owners and admins. | organization |
| description | No | What the field holds; shown in the web app and read by the workers. | |
| object_type | Yes | Which object: "company", "person", "deal", or "custom" (custom objects also need schema_id). |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| field | Yes |