Search custom fields

distru-search-custom-fieldsRead

Searches the custom fields of the caller's company — extra attributes it adds to an entity type, e.g. a Lab dropdown on packages.

Inputs

Every tool also takes the common inputs.

FieldTypeRequiredDescription
limitintegerNoDefault: 10
cursorstringNonextCursor of the previous call; keep the other arguments unchanged.
idsstring[]No
searchstringNoCase-insensitive substring of name or description. Ranked by similarity.
entityTypeenum
ASSEMBLYBATCHCOMPANYCONTACTINVOICEPACKAGEPRODUCTPURCHASE_ORDERRETURNSALES_ORDERSTOCK_TRANSFERTASK
No
sortByobjectNoDefault UPDATED_AT DESC. Ignored when search is set.
sortBy.directionenum
ASCDESC
Yes
sortBy.fieldenum
INSERTED_ATNAMEUPDATED_AT
Yes

Output

Presence on a nested field assumes its parent exists.

FieldTypePresence
hasMorebooleanAlways
nextCursorstringCan be absent
totalCountintegerCan be absent
itemsobject[]Always
items[].idstringAlways
items[].namestringAlways
items[].descriptionstringCan be null
items[].entityTypeenum
ASSEMBLYBATCHCOMPANYCONTACTINVOICEPACKAGEPRODUCTPURCHASE_ORDERRETURNSALES_ORDERSTOCK_TRANSFERTASK
Can be null
items[].fieldTypeenum
CHECKBOXDATEDROPDOWNTEXT
Always
items[].requiredbooleanAlways
items[].optionsobject[]Always
items[].options[].namestringAlways
items[].options[].disabledbooleanAlways
What the AI reads

Searches the custom fields of the caller's company — extra attributes it adds to an entity type, e.g. a Lab dropdown on packages. Use it to see a field's type and options; to change fields use distru-create-custom-field, distru-update-custom-field or distru-delete-custom-field. options is set only for DROPDOWN and CHECKBOX fields.