Operation CategoriesUpdate a category field

Update a category field

label/required/options (add)/unit/helpText/sensitive/order/archived. key and type are immutable.

curl -X PATCH "https://policy-engine-rest.ezig.workers.dev/api/v1/vaults/demo_vault/operation-categories/example_string/fields/example_string" \
  -H "Content-Type: application/json" \
  -H "Authorization: Bearer YOUR_API_TOKEN" \
  -d '{
  "label": "example_string",
  "required": true,
  "optionsJson": [
    {
      "value": "example_string",
      "label": "example_string"
    }
  ],
  "unit": "example_string",
  "helpText": "example_string",
  "sensitive": true,
  "orderIndex": 42,
  "archived": true
}'
{
  "id": "cmr3f41z20001psp7phmyapw3",
  "categoryId": "example_string",
  "key": "example_string",
  "label": "example_string",
  "type": "text",
  "required": true,
  "optionsJson": [
    {
      "value": "example_string",
      "label": "example_string"
    }
  ],
  "scale": 42,
  "currencyFieldKey": "example_string",
  "unit": "example_string",
  "defaultJson": "null",
  "helpText": "example_string",
  "sensitive": true,
  "orderIndex": 42,
  "archived": true,
  "createdAt": "2026-07-02T11:25:15.134000Z",
  "updatedAt": "2026-07-02T11:25:15.134000Z"
}
PATCH
/api/v1/vaults/{code}/operation-categories/{id}/fields/{fid}
PATCH
Base URLstring

Target server for requests. Edit to use your own host.

Bearer Token
Bearer Tokenstring
Required

Session token. Mobile/services. The web uses a cookie.

Session token. Mobile/services. The web uses a cookie.
API Key (cookie: session_token)
session_tokenstring
Required

API key (sent in cookie)

Content-Typestring
Required

The media type of the request body

Options: application/json
labelstring
Min length: 1 • Max length: 200
optionsJsonarray

For select: options can be ADDED (full new list)

orderIndexinteger
Min: -9007199254740991 • Max: 9007199254740991
Request Preview
Response

Response will appear here after sending the request

Authentication

header
Authorizationstring
Required

Bearer token. Session token. Mobile/services. The web uses a cookie.

path
parameterstring
Required

API Key for authentication. Provide your API key in the cookie.

Path Parameters

codestring
Required

Unique Vault code (slug)

Example:
demo_vault

Body

application/json
optionsJsonarray

For select: options can be ADDED (full new list)

Responses

idstring
Required

cuid

categoryIdstring
Required
keystring
Required
labelstring
Required
typestring
Required
Allowed values:textnumberselectdatedatetimebooleanurlcurrency
requiredboolean
Required
optionsJsonstring
Required

select only

scalestring
Required

Decimal places (0..18). number and currency; defaults to 2 for currency

currencyFieldKeystring
Required

currency only: the key of a field in THIS category that holds the amount's currency (usually a select with tickers). When set, reports on this amount are automatically broken down by ticker, and a mixed total across different currencies isn't returned

unitstring
Required
defaultJsonstring
Required
helpTextstring
Required
sensitiveboolean
Required
orderIndexinteger
Required
archivedboolean
Required
createdAtstring
Required
updatedAtstring
Required