Update a custom field
SDK platic.customFields.update()
Change a field’s description, how AI fills it or the options of a select field. Send at least one field you want to update; other fields keep their values.
Example
curl -X PATCH https://api.platic.ai/v1/custom-fields/$FIELD_ID \
-H "Authorization: Bearer $PLATIC_API_KEY" \
-H "Content-Type: application/json" \
-d '{ "description": "The plan the customer pays for" }' await platic.customFields.update("plan", { description: "The plan the customer pays for" }); If your credential covers several workspaces, add ?workspace=<id> to say which one you work in (list workspaces); without it the answer is 400. A single-workspace credential never needs it.
URL parameters
| Parameter | Type | Description | Required |
|---|---|---|---|
fieldId | string | Unique identifier of the custom field | ✓ |
Request body
{
"description": "Current membership type of the customer",
"automatic": true,
"overwritable": false
} Body parameters
All parameters are optional, but the request must include at least one.
| Parameter | Type | Description |
|---|---|---|
description | string | Field description (max 500 characters) |
automatic | boolean | Whether the AI should fill the field automatically from the conversation |
overwritable | boolean | Whether the AI can overwrite the field's existing value |
options | array | select only. Fully replaces the option catalog. At least one active (non-archived) option must remain. Up to 50 options. |
ordered | boolean | select only. Whether the options are an ordered sequence (stages/steps). |
Editing a select field's options
Send the full option catalog in options. Keep the id of existing options so you don't break values already stored on customers; options without an id are treated as new.
{
"ordered": true,
"options": [
{ "id": "new", "label": "New" },
{ "id": "contacted", "label": "Contacted" },
{ "id": "closed", "label": "Closed", "archived": true },
{ "label": "Won" }
]
} Response
{
"status": "success",
"message": "Custom field updated successfully",
"data": {
"id": "membership_level"
}
} Errors
| Status | details.code | When it happens |
|---|---|---|
400 | INVALID_REQUEST | The body is empty, description is longer than 500 characters, or a value does not have the expected type. details.issues says which field |
400 | INVALID_REQUEST | The options of a select are not valid (repeated ids, no active option…). details.message says what happened |
400 | INVALID_REQUEST | Your credential covers several workspaces and you did not send ?workspace=, or you sent one it does not cover. details.available lists the ones you can use |
401 | UNAUTHENTICATED | The credential is missing or invalid |
403 | FORBIDDEN | The credential does not have the Contacts module (Missing contacts permission), or it is an OAuth token without the platica:write scope |
404 | CUSTOM_FIELD_NOT_FOUND | The field does not exist in the workspace or was deleted |
{
"code": 400,
"error": "Bad Request - The request has validation errors",
"details": {
"code": "INVALID_REQUEST",
"message": "The request has validation errors",
"issues": [
{
"code": "custom",
"path": [],
"message": "At least one of description, automatic, overwritable, options, or ordered must be provided"
}
]
}
} The general error format is in Errors.
Notes
- You cannot change
nameortypeafter creating the field. To change them, delete the field and create it again. - In a
selectfield, to "remove" an option mark it asarchived: trueinstead of dropping it from the array: this preserves historical values on customers while hiding the option from new assignments. optionsandorderedonly apply toselectfields; they are ignored for other types.- If the field does not exist or has been deleted, the API returns
404.