Skip to content

POST /field

Create Field

POST
/field

Create a new custom field definition.

Inserts a CustomField document after verifying that no existing field
produces the same slug (derived by converting the name to snake_case).
The slug is used as the field identifier in form templates and data exports.

Returns HTTP 409 if the slug already exists.

Emits: (direct transaction — no event class)

Required scope: quality:form:create

Authorizations

OAuth2PasswordBearer
password Flow
Token URL"/api/auth"
Scopes:
  • "admin"User can access and edit users and system settings
  • "library"User can access and edit products
  • "production"User can access and edit production plans
  • "operator"User can access the operator panel and make production declarations

Request Body

application/json
JSON
{
  
"_id": "string",
  
"_key": "string",
  
"_rev": "string",
  
"type": "text",
  
"name": "Surface Colour",
  
"default_label": "Surface Colour",
  
"default_hint": "Select the RAL colour code applied to this part"
}

Responses

Successful Response

application/json
JSON
{
  
"status": 200,
  
"message": "string",
  
"detail": "string"
}

Samples

Powered by VitePress OpenAPI

Released under the Apache 2.0 License.