customFieldDefinitions
Requires an authenticated session.
Lists the organization's custom fields, optionally for one kind of record, archived ones included when asked. Staff forms render from it. Requires a signed-in staff user.
Errors: a failed call returns a GraphQL errors entry, not a field on the result, and data may be null or partial. Read the entry's extensions.code and message; every shape and code is in the Error reference.
Example:
- GraphQL
- cURL
query CustomFieldDefinitions {
customFieldDefinitions {
id
type
archived
carryForward
defaultValue
editPermission
}
}
curl -X POST "https://<api-host>/graphql" \
-H "Content-Type: application/json" \
-H "Authorization: Bearer $ACCESS_TOKEN" \
--data @- <<'EOF'
{
"query": "query CustomFieldDefinitions {\n customFieldDefinitions {\n id\n type\n archived\n carryForward\n defaultValue\n editPermission\n }\n}"
}
EOF
Response:
{
"data": {
"customFieldDefinitions": [
{
"id": "id",
"type": "string",
"archived": true,
"carryForward": true,
"defaultValue": {},
"editPermission": "string"
}
]
}
}
customFieldDefinitions(
entity: String
includeArchived: Boolean
): [CustomFieldDefinition!]!
Arguments
customFieldDefinitions.entity ● String scalar
Only fields of this kind of record, e.g. address.
customFieldDefinitions.includeArchived ● Boolean scalar
Include archived fields. Default false.
Type
CustomFieldDefinition object
A field the organization added to one kind of record.