Skip to main content

Update Custom Field

Update a custom field. Only the name can be updated - type and field_key are immutable.

Request

PATCH /custom-fields/{uuid}

Path Parameters

ParameterTypeDescription
uuidstringField's UUID

Request Body

ParameterTypeRequiredDescription
namestringYesNew display name (max 255 characters)

Note: The type and field_key fields cannot be updated after creation.

Example Request

curl -X PATCH "https://email.easy.tools/api/v1/custom-fields/field-uuid-123" \
-H "Authorization: Bearer YOUR_API_TOKEN" \
-H "Content-Type: application/json" \
-H "Accept: application/json" \
-d '{
"name": "Company Name"
}'

Response

Success Response (200 OK)

{
"data": {
"uuid": "field-uuid-123",
"field_key": "company",
"name": "Company Name",
"type": "text",
"options": null,
"created_at": "2025-01-15T10:30:00Z"
}
}

Response Fields

FieldTypeDescription
uuidstringField's unique identifier
field_keystringUnique key for the field (immutable)
namestringDisplay name
typestringField type (immutable)
optionsarray|nullOptions for select fields, null for other types
created_atstringISO 8601 timestamp (UTC)

Error Responses

Not Found Error (404)

{
"error": {
"code": "RESOURCE_NOT_FOUND",
"message": "Custom field not found"
}
}

Validation Error (422 Unprocessable Entity)

{
"error": {
"code": "VALIDATION_ERROR",
"message": "The given data was invalid",
"details": {
"name": ["The name field is required."]
}
}
}