Skip to main content
PATCH
/
custom_field_definitions
/
{id}
Update a custom field definition
curl --request PATCH \
  --url https://api.terminal49.com/v2/custom_field_definitions/{id} \
  --header 'Authorization: <api-key>' \
  --header 'Content-Type: application/json' \
  --data '
{
  "data": {
    "type": "custom_field_definition",
    "attributes": {
      "display_name": "<string>",
      "description": "<string>",
      "validation": {},
      "default_format": "<string>",
      "default_value": "<string>"
    }
  }
}
'
{
  "data": {
    "id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
    "type": "custom_field_definition",
    "attributes": {
      "entity_type": "Shipment",
      "api_slug": "<string>",
      "display_name": "<string>",
      "data_type": "short_text",
      "description": "<string>",
      "reference_type": "<string>",
      "validation": {},
      "default_format": "<string>",
      "default_value": "<string>"
    }
  },
  "links": {
    "self": "<string>"
  }
}
Update an existing custom field definition.

Path parameters

ParameterDescription
idThe unique identifier of the custom field definition

Request body

Provide the fields you want to update, such as display_name, description, validation, or default_format.

Notes

You cannot change api_slug, entity_type, or data_type after creation.

Authorizations

Authorization
string
header
required

Token YOUR_API_TOKEN

The APIs require authentication to be done using header-based API Key and Secret Authentication.

API key and secret are sent va the Authorization request header.

You send your API key and secret in the following way:

Authorization: Token YOUR_API_KEY

Path Parameters

id
string
required

Custom field definition ID

Body

application/json
data
object

Response

200 - application/json

OK

data
Custom field definition · object