ADO.NET Provider for Zendesk

Build 26.0.9655

CustomObjectFields

Returns the fields available for a custom object, including field type, validation, and relationship details.

Table-Specific Information

Custom objects are configured using the CustomObjects and CustomObjectFields tables. The CustomObjects table essentially allows you to list and create custom objects, while the CustomObjectFields table allows you to query and modify the fields of the custom objects. Records within these custom objects are then queried and modified via tables with the "CustomObject_" prefix (see Working with Custom Object Records in CustomObjects).

Select

The ParentKey column is required to query the fields for a custom object.
SELECT * FROM CustomObjectFields WHERE ParentKey='Devices'

Insert

You must specify the ParentKey, Key, Title, and Type columns for each field inserted into a custom object.
Insert INTO CustomObjectFields (ParentKey, Key, Title, Type) values ('Devices', 'DeviceType', 'DeviceType', 'text')

Data Types for Inserting Custom Object Fields

Data types supported by the Custom Objects API include Text, TextArea, Checkbox, Date, Decimal, Dropdown, Integer, Lookup, Multiselect, and Regexp. Some data types require additional information, including Regexp, Dropdown, Lookup, and Multiselect.
Insert INTO CustomObjectFields (ParentKey, Key, Title, Description, Type) values ('Devices', 'TextType', 'TextType', 'Text type', 'Text')
Insert INTO CustomObjectFields (ParentKey, Key, Title, Description, Type) values ('Devices', 'TextareaType', 'TextareaType', 'Textarea type', 'Textarea')
Insert INTO CustomObjectFields (ParentKey, Key, Title, Description, Type) values ('Devices', 'CheckboxType', 'CheckboxType', 'Checkbox type', 'Checkbox')
Insert INTO CustomObjectFields (ParentKey, Key, Title, Description, Type) values ('Devices', 'DateType', 'DateType', 'Date type', 'Date')
Insert INTO CustomObjectFields (ParentKey, Key, Title, Description, Type) values ('Devices', 'IntegerType', 'IntegerType', 'Integer type', 'Integer')
Insert INTO CustomObjectFields (ParentKey, Key, Title, Description, Type) values ('Devices', 'DecimalType', 'DecimalType', 'Decimal type', 'Decimal')
Insert INTO CustomObjectFields (ParentKey, Key, Title, Description, Type, RegexpForValidation) values ('Devices', 'RegexpType', 'RegexpType', 'Regexp type', 'Regexp', '\b[0-9]{3}-[0-9]{2}-[0-9]{4}\b')
Insert INTO CustomObjectFields (ParentKey, Key, Title, Description, Type, CustomFieldOptions) values ('Devices', 'DropdownType', 'DropdownType', 'Dropdown type', 'Dropdown', '[{\"name\": \"options-1\", \"value\": \"option-1\"}]')
Insert INTO CustomObjectFields (ParentKey, Key, Title, Description, Type, RelationshipTargetType) values ('Devices', 'LookupType', 'LookupType', 'Lookup type', 'Lookup', 'zen:user')
Insert INTO CustomObjectFields (ParentKey, Key, Title, Description, Type, CustomFieldOptions) values ('Devices', 'MultiselectType', 'MultiselectType', 'Multiselect type', 'Multiselect', '[{\"name\\\": \"options-1\", \"value\": \"option-1\"}]')

Update

You must specify the ParentKey and Key columns to update a custom object field.
Update CustomObjectFields SET description='Updated description' WHERE ParentKey='Devices' AND Key='OSType'

Delete

You must specify the ParentKey and Key columns to delete a custom object field.
Delete FROM CustomObjectFields WHERE ParentKey='Devices' AND Key='OSType'

Columns

Name Type ReadOnly References Description
Id [KEY] Long False

The Id of the custom object field, automatically assigned upon creation.

Key [KEY] String False

A unique key that identifies this custom field. This is used for updating the field and referencing in placeholders. The key must consist of only letters, numbers, and underscores. It can't be only numbers.

Active Boolean False

Indicates whether this field is available for use.

ParentKey String False

The key of the custom object to which this field belongs.

Description String False

The user-defined description of this field's purpose.

RawDescription String False

The dynamic content placeholder, if present, or the description value, if not.

Title String False

The title of the custom field.

RawTitle String False

The dynamic content placeholder, if present, or the title value, if not.

Type String False

The custom field type: checkbox, date, decimal, dropdown, integer, lookup, multiselect, regexp, text, or textarea.

CreatedAt String False

The date and time when the custom object field was created.

Position Long False

The ordering of the field relative to other fields.

Properties String False

A set of properties which describe the standard::name field's autonumbering and uniqueness behavior. Autonumbering and uniqueness can't be used together.

RegexpForValidation String False

Regular expression field only. The validation pattern for a field value to be deemed valid.

RelationshipFilter String False

A filter definition that narrows autocomplete results.

RelationshipTargetType String False

A representation of what type of object the field references. Options are zen:user, zen:organization, zen:ticket, zen:article, and zen:custom_object:{key} where key is a custom object key.

System Boolean False

Indicates whether only the active and position values of this field can be changed.

Tag String False

Optional for custom field of type checkbox; not applicable otherwise.

CustomFieldOptions String False

Required and presented for a custom field of type dropdown. Each option is represented by an object with a name and value property.

UpdatedAt String False

The date and time when the custom object field was last updated.

Url String False

The URL of this resource.

Copyright (c) 2026 CData Software, Inc. - All rights reserved.
Build 26.0.9655