Need dedicated support? Click here
Need dedicated support?
Click here

Custom Fields API - Mask Parameter

Community Server/Control Panel version: Enterprise
Type of installation of Workspace (docker, deb/rpm, exe): Cloud
OS: Arch Linux
Browser version: Firefox 113

When using the custom fields api and calling the api/2.0/crm/{entityType}/customfield/{id} I am able to change the label with no issues when passing an empty string in the mask but when trying to edit the mask for a select box I am getting a 500 error.

Here is the bodyData I am passing.

{ label: "Lead Source", fieldType: 2, mask: "["Test", "Test1"]" }.

I am getting the following error:

Error: HTTP error! status: 500, message: {"status":1,"statusCode":500,"error":{"message":"Error reading JToken from JsonReader. Path '', line 0, position 0.","hresult":-2146233088,"data":{}}}

If I pass this:

{ label: "Lead Source", fieldType: 2, mask: "" }

I don’t get any errors and the label is changed.

Hey @aloreaux

If you have commercial license, better to contact us via Zendesk to get prompt replies.

Using postman I got like this:

“label”: “text”,
“FieldType”: 2,
“mask”: “[“test1”,“test2”,“test3”]”


You can update field if there are no related elements. If such elements exist, only label and mask will be updated. Other parameters will be ignored.

mask → Sent in json format only (optional)

Thanks @Nikolas. That seems to work with a newly created field. But on an existing field I am unable to change the mask.

On the new field created I have made it so opportunities have multiple relativeItemsCount and can still make changes to it. Not sure why an older one can only change the label and not the mask.

wait a sec


It looks like you have already used this field when setting up a person or company and one of multi values is already in use.


check it :upside_down_face:

@Nikolas I’m not sure I follow. If it is used the documentation says that the label and mask can change and everything else will be ignored, unless I am not understanding something. Thank you.

1 Like

I’m clarifying

The situation is as follows:

For this type of custom field: 2 (SelectBox)
You can change the custom field mask, but there is one caveat.

  1. You can change the custom field completely when it was not used for a person or company.

  2. You can add (not change) mask values for custom field if custom field has already been used for a person or company.