Create / Update Field
Create / Update Field
This API allows you to create a new input field inside a section or update an existing field.
Now supports meta in the request body to store extra information. meta has no restrictions or validation rules, so you can add custom data freely.
Endpoint
POST /v2/global/field?key=u2_core
Base URL:
https://prodnode.unizooks.com
Headers
| Key | Value | Required | Description |
|---|---|---|---|
Content-Type | application/json | ✅ | Defines the request body format |
Authorization | Bearer <JWT_TOKEN> | ✅ | Provide a valid JWT token for authentication |
Request Body
Create Field
Send section_id along with field details.
{
"field_label": "field 3",
"field_type": "number",
"description": "qwerty",
"section_id": "8498a26d-8323-11f0-b592-bc2411f4d589",
"dropdown_options": [
{"value": "test12", "color": "567473"},
{"value": "test22", "color": "#bebebe"}
],
"meta": {
"textFormat": {
"textSelectedOption": "URL"
},
"absoluteType": "url",
"numberFormat": {
"symbol": "$",
"separators": false,
"decimalPlaces": 0,
"negativeFormat": ""
},
"dateTimeFormat": {
"timeDisplay": null
}
}
}
Update Field
Send id of the field (no need to send section_id). You can also update meta.
{
"id": "f5837551-f431-4f36-bb07-e9c78d919a42",
"field_label": "Updated Field",
"field_type": "text",
"description": "Updated description",
"dropdown_options": [
{"value": "optionA", "color": "#"}
],
"meta": {
"textFormat": {
"textSelectedOption": "URL"
},
"absoluteType": "url",
"numberFormat": {
"symbol": "$",
"separators": false,
"decimalPlaces": 0,
"negativeFormat": ""
},
"dateTimeFormat": {
"timeDisplay": null
}
}
}
Body Parameters
| Field | Type | Required | Description |
|---|---|---|---|
id | string | ❌ (create) / ✅ (update) | Required only for update (UUID of the field) |
field_label | string | ✅ | Display name of the field |
field_type | string | ✅ (create) / ❌ (update) | Type of input (text, number, dropdown, etc.) |
description | string | ❌ | Optional description of the field |
section_id | string | ✅ (create) / ❌ (update) | Section ID where this field belongs (only needed when creating) |
dropdown_options | array | ✅ (create) / ❌ (update) | List of dropdown options (each option has value and optional color) |
meta | object | ❌ | Extra information (no validation, flexible storage) |
Response
Success (201 Created / 200 Updated)
{
"status": true,
"message": "Field created/updated successfully"
}
Error (400 Bad Request)
{
"success": false,
"message": "Invalid request body. 'field_label' is required"
}
Error (401 Unauthorized)
{
"success": false,
"message": "Invalid or expired token"
}
Example (cURL)
Create Field
curl --location 'https://prodnode.unizooks.com/v2/global/field?key=u2_core' \
--header 'Content-Type: application/json' \
--header 'Authorization: Bearer <JWT_TOKEN>' \
--data '{
"field_label":"field 3",
"field_type":"number",
"description":"qwerty",
"section_id":"8498a26d-8323-11f0-b592-bc2411f4d589",
"dropdown_options":[{"value":"test12","color":"567473"},{"value":"test22","color":"#bebebe"}],
"meta":{"placeholder":"Enter number","is_required":true}
}'
Update Field
curl --location 'https://prodnode.unizooks.com/v2/global/field?key=u2_core' \
--header 'Content-Type: application/json' \
--header 'Authorization: Bearer <JWT_TOKEN>' \
--data '{
"id":"f5837551-f431-4f36-bb07-e9c78d919a42",
"field_label":"Updated Field",
"field_type":"text",
"description":"Updated description",
"meta":{"tooltip":"Enter valid text","customFlag":"X"}
}'
✅ Use this API to add new input fields to a section or update existing fields, now with flexible meta support.