Update Custom Field
PATCH/custom-field/:id
Update a Custom Field by Custom Field UUID
Updating Custom Field Name
- When you update the name of a custom field, the key is automatically updated to reflect the new name.
- The key is generated based on the custom field name, so any changes to the name will result in a new key being generated.
- This ensures that the key remains unique and consistent with the custom field name.
- The old key will no longer be valid after the update.
- Any references to the old key of the custom field will be automatically updated to the new key.
Example
In the Custom Field definition:
| Old Name | Old Key | New Name | New Key | 
|---|---|---|---|
| Shipment ID | shipment_id | Shipment No | shipment_no | 
| Invoice No | invoice_no | Invoice ID | invoice_id | 
In the Entity using the Custom Field:
- Before Update:
{
  "custom_fields": {
    "shipment_id": "12345",
    "invoice_no": "67890"
  }
}
- After Update:
{
  "custom_fields": {
    "shipment_no": "12345",
    "invoice_id": "67890"
  }
}
Updating Custom Field Is Active
- When you update the is_activefield of a custom field, it determines whether the custom field is shown in the entity or not.
- If is_activeis set tofalse, the custom field will be hidden in the entity and will not be available for use.
- If is_activeis set totrue, the custom field will be shown in the entity and will be available for use.
- The custom field will still exist in the system, but it will not be visible or usable in the entity until is_activeis set totrueagain.
- This allows you to temporarily hide custom fields without deleting them, making it easy to manage the visibility of custom fields in the entity.
Example
In the Custom Field definition:
| Name | Key | Is Active | 
|---|---|---|
| Shipment ID | shipment_id | false | 
| Invoice No | invoice_no | true | 
In the Entity using the Custom Field:
{
  "custom_fields": {
    "invoice_no": "67890"
  }
}
- The shipment_idcustom field is not available in the entity.
- The invoice_nocustom field remains available for use in the entity.
Note
You can only update the
nameoris_activefield of a custom field.
Request
Responses
- 200
- 400
- 401
- 403
- 404
OK
Bad Request
Unauthorized
Forbidden
Not Found