> For the complete documentation index, see [llms.txt](https://docs.ninox.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.ninox.com/ninox-api/api-reference/api-endpoints/models.md).

# Models

## The CreateComponentBody object

```json
{"openapi":"3.0.0","info":{"title":"Ninox Public API","version":"1.0.0"},"components":{"schemas":{"CreateComponentBody":{"type":"object","properties":{"afterHide":{"description":"Container directly under Tabs: script run when this tab stops being shown, 400 anywhere else. Needs schema:write plus records:write","type":"string"},"aggregation":{"type":"string","enum":["avg","count","max","median","min","sum"]},"annualRecurring":{"type":"boolean"},"arrangement":{"type":"string","enum":["grid","ltr","row","ttb"]},"background":{"anyOf":[{"type":"string"},{"type":"object","properties":{"$nx":{"type":"string","description":"Script expression. Writing one needs records:write as well as schema:write"}},"required":["$nx"]}]},"beforeShow":{"description":"Container directly under Tabs: script run when this tab is shown, 400 anywhere else. Needs schema:write plus records:write","type":"string"},"border":{"anyOf":[{"type":"object","properties":{"color":{"type":"string"},"style":{"type":"string","enum":["dashed","dotted","double","none","solid"]},"width":{"type":"string"}},"required":["style","width"]},{"type":"object","properties":{"$nx":{"type":"string","description":"Script expression. Writing one needs records:write as well as schema:write"}},"required":["$nx"]}]},"calendarType":{"type":"string"},"cardBorder":{"type":"string"},"cardFont":{"type":"string"},"cardPadding":{"type":"number"},"cardRadius":{"type":"number"},"chartConfig":{"type":"object","properties":{"chartType":{"type":"string","enum":["bar","line","pie","funnel","ranking","board"]},"dataSets":{"type":"array","items":{"type":"object","properties":{"aggregation":{"type":"string","enum":["average","count","max","median","min","none","sum"]},"color":{"description":"Series color (hex string)","type":"string"},"fieldName":{"description":"Field name this series reads from","type":"string"},"labels":{"description":"Series labels (localized)","type":"object","additionalProperties":{"type":"string"}}}}},"donut":{"type":"boolean"},"labelPosition":{"type":"string","enum":["bottom","center","inside","outside","top"]},"legend":{"type":"object","properties":{"show":{"type":"boolean"}}},"limit":{"description":"ranking only: how many categories it shows","type":"integer","minimum":1,"maximum":20},"orientation":{"type":"string","enum":["horizontal","vertical"]},"showDataTable":{"type":"boolean"},"showLabels":{"type":"boolean"},"showPoints":{"type":"boolean"},"showTitle":{"type":"boolean"},"smooth":{"type":"boolean"},"stacked":{"type":"boolean"},"style":{"type":"string","enum":["default","half_donut","pad_angle","rounded_corner"]},"tooltips":{"type":"object","properties":{"show":{"type":"boolean"}}},"xAxis":{"type":"object","properties":{"fieldName":{"description":"X-axis field name, null removes it","type":["string","null"]},"groupBy":{"type":"string","enum":["daily","monthly","none","quarterly","weekly","yearly"]},"show":{"type":"boolean"}}},"yAxis":{"type":"object","properties":{"show":{"type":"boolean"}}}}},"color":{"anyOf":[{"type":"string"},{"type":"object","properties":{"$nx":{"type":"string","description":"Script expression. Writing one needs records:write as well as schema:write"}},"required":["$nx"]}]},"colorFieldName":{"type":"string"},"constraints":{"description":"FieldComponent: script limiting which records a reference can link to, needs schema:manage-permissions","type":"string"},"content":{"anyOf":[{"type":"object","additionalProperties":{"type":"string","minLength":1,"maxLength":100}},{"type":"object","properties":{"$nx":{"type":"string","description":"Script expression. Writing one needs records:write as well as schema:write"}},"required":["$nx"]}]},"customStyle":{"type":"object","additionalProperties":{}},"dataPoint":{"type":"string","enum":["conditional","normal"]},"defaultValue":{"description":"InputComponent: initial value, or { $nx: <script> } which needs schema:write plus records:write","anyOf":[{"type":"boolean"},{"type":"number"},{"type":"string"},{"type":"object","properties":{"$nx":{"type":"string","description":"Script expression. Writing one needs records:write as well as schema:write"}},"required":["$nx"]}]},"disabled":{"anyOf":[{"type":"boolean"},{"type":"object","properties":{"$nx":{"type":"string","description":"Script expression. Writing one needs records:write as well as schema:write"}},"required":["$nx"]}]},"display":{"type":"object","properties":{"color":{"type":"string"},"format":{"type":"string","enum":["compact","currency","number","percentage"]},"icon":{"type":"string"},"trend":{"type":"object","properties":{"customPeriodEnd":{"type":"string"},"customPeriodStart":{"type":"string"},"format":{"type":"string","enum":["absolute","percentage"]},"isShown":{"type":"boolean"},"period":{"type":"string","enum":["custom","last_month","last_week","last_year","previous_period","yesterday"]},"positiveDirection":{"type":"string","enum":["down","up"]}},"required":["format","isShown"]}}},"displayAs":{"description":"FieldComponent: how a yes/no field is shown","type":"string","enum":["checkbox","dropdown","switch","tabs"]},"expression":{"description":"DynamicHTMLComponent: script returning the HTML to render. Needs schema:write plus records:write","type":"string"},"fieldIdDataPoint":{"type":"string","enum":["conditional","normal"]},"fieldIdValue":{"description":"MetricCardComponent: script computing the value. Needs schema:write plus records:write","type":"string"},"fieldName":{"type":"string"},"filter":{"type":"array","items":{"type":"object","properties":{"field":{"type":"string"},"id":{"type":"string"},"operator":{"type":"string"},"value":{"type":"string"}},"required":["id"]}},"flex":{"anyOf":[{"type":"string"},{"type":"object","properties":{"$nx":{"type":"string","description":"Script expression. Writing one needs records:write as well as schema:write"}},"required":["$nx"]}]},"ganttConfig":{"type":"object","properties":{"baselineEndFieldName":{"description":"Planned end field, rendered as a ghost bar","type":["string","null"]},"baselineStartFieldName":{"description":"Planned start field, rendered as a ghost bar","type":["string","null"]},"dependencyDirection":{"type":"string","enum":["predecessor","successor"]},"dependencyFieldName":{"description":"A reference field pointing back at this table","type":["string","null"]},"disableDragAndDrop":{"type":"boolean"},"endFieldName":{"type":["string","null"]},"hideTitleColumn":{"type":"boolean"},"hideWeekends":{"type":"boolean"},"milestoneFieldName":{"type":["string","null"]},"progressFieldName":{"type":["string","null"]},"showCriticalPath":{"type":"boolean"},"showWeekends":{"type":"boolean"},"startFieldName":{"type":["string","null"]},"timeScale":{"type":"string","enum":["day","month","quarter","week"]},"titleColumnFieldName":{"type":["string","null"]},"titleColumnWidth":{"type":"number"}}},"gap":{"anyOf":[{"type":"string"},{"type":"object","properties":{"$nx":{"type":"string","description":"Script expression. Writing one needs records:write as well as schema:write"}},"required":["$nx"]}]},"globalFilterBinding":{"type":"array","items":{"type":"string"}},"gridPreset":{"anyOf":[{"type":"string"},{"type":"object","properties":{"$nx":{"type":"string","description":"Script expression. Writing one needs records:write as well as schema:write"}},"required":["$nx"]}]},"groupByFieldName":{"type":"string"},"height":{"type":"number"},"icon":{"description":"Page icon","type":"object","properties":{"color":{"type":"string"},"filling":{"anyOf":[{"type":"number","enum":[0]},{"type":"number","enum":[1]}]},"icon":{"type":"string","minLength":1}}},"iconLeft":{"anyOf":[{"type":"object","properties":{"color":{"type":"string"},"filling":{"anyOf":[{"type":"number","enum":[0]},{"type":"number","enum":[1]}]},"icon":{"type":"string","minLength":1}},"required":["icon"]},{"type":"object","properties":{"$nx":{"type":"string","description":"Script expression. Writing one needs records:write as well as schema:write"}},"required":["$nx"]}]},"iconRight":{"anyOf":[{"type":"object","properties":{"color":{"type":"string"},"filling":{"anyOf":[{"type":"number","enum":[0]},{"type":"number","enum":[1]}]},"icon":{"type":"string","minLength":1}},"required":["icon"]},{"type":"object","properties":{"$nx":{"type":"string","description":"Script expression. Writing one needs records:write as well as schema:write"}},"required":["$nx"]}]},"imagePosition":{"type":"object","properties":{"position":{"type":"string"},"size":{"type":"string"}}},"isCompact":{"type":"boolean"},"isHidden":{"description":"Page: hide from navigation","type":"boolean"},"isMarkdownEnabled":{"type":"boolean"},"isSpreadsheetMode":{"type":"boolean"},"labelPosition":{"type":"string","enum":["hidden","inside","left","top"]},"labels":{"description":"Component labels (localized)","type":"object","additionalProperties":{"type":"string","minLength":1,"maxLength":100}},"mapTypeId":{"type":"string"},"margin":{"anyOf":[{"type":"string"},{"type":"object","properties":{"$nx":{"type":"string","description":"Script expression. Writing one needs records:write as well as schema:write"}},"required":["$nx"]}]},"name":{"type":"string","minLength":1,"maxLength":100,"pattern":"^[a-z0-9_]+$","description":"Component name"},"onChange":{"description":"Tabs/FieldComponent: script run when the value changes. Needs schema:write plus records:write","type":"string"},"onClick":{"description":"Button: script run on click. Needs schema:write plus records:write","type":"string"},"overflow":{"anyOf":[{"type":"string"},{"type":"object","properties":{"$nx":{"type":"string","description":"Script expression. Writing one needs records:write as well as schema:write"}},"required":["$nx"]}]},"padding":{"anyOf":[{"type":"string"},{"type":"object","properties":{"$nx":{"type":"string","description":"Script expression. Writing one needs records:write as well as schema:write"}},"required":["$nx"]}]},"parentId":{"description":"Parent component id, required unless type is 'Page' (a Page's parent may also be its table's object id)","type":"string","minLength":12,"maxLength":12,"pattern":"^[a-z0-9]+$"},"placeholder":{"anyOf":[{"type":"object","additionalProperties":{"type":"string","minLength":1,"maxLength":100}},{"type":"string"},{"type":"object","properties":{"$nx":{"type":"string","description":"Script expression. Writing one needs records:write as well as schema:write"}},"required":["$nx"]}]},"quickStyle":{"anyOf":[{"type":"string","enum":["body-md","body-sm","custom","title-lg","title-md","title-sm"]},{"type":"object","properties":{"$nx":{"type":"string","description":"Script expression. Writing one needs records:write as well as schema:write"}},"required":["$nx"]}]},"radius":{"anyOf":[{"type":"string"},{"type":"object","properties":{"$nx":{"type":"string","description":"Script expression. Writing one needs records:write as well as schema:write"}},"required":["$nx"]}]},"remember":{"description":"InputComponent: how long the value is kept, defaults to memory","type":"string","enum":["localStorage","memory","url"]},"shadow":{"anyOf":[{"type":"string"},{"type":"object","properties":{"$nx":{"type":"string","description":"Script expression. Writing one needs records:write as well as schema:write"}},"required":["$nx"]}]},"shadowDom":{"type":"boolean"},"showAs":{"type":"string"},"showBulkActions":{"type":"boolean"},"showCalendarType":{"type":"boolean"},"showCreateButton":{"type":"boolean"},"showCreateRow":{"type":"boolean"},"showDataAs":{"description":"FieldComponent: script formatting a linked record. Needs schema:write plus records:write","type":"string"},"showEmptyLane":{"type":"boolean"},"showLinkExistingRecord":{"type":"boolean"},"showMetadata":{"type":"boolean"},"showOutlines":{"description":"Page: show layout outlines in the editor","type":"boolean"},"showSearchField":{"type":"boolean"},"showTimeScaleSelector":{"type":"boolean"},"showTitle":{"type":"boolean"},"size":{"anyOf":[{"type":"string","enum":["lg","md","sm"]},{"type":"object","properties":{"$nx":{"type":"string","description":"Script expression. Writing one needs records:write as well as schema:write"}},"required":["$nx"]}]},"tableName":{"description":"Table this component reads from","type":"string"},"textAlign":{"type":"string","enum":["text-center","text-left","text-right"]},"titleFieldName":{"type":"string"},"tooltip":{"type":"string"},"type":{"type":"string","enum":["Accordion","Button","CalendarComponent","ChartComponent","Container","CustomWidget","DynamicHTMLComponent","FieldComponent","GanttComponent","InputComponent","KanbanComponent","MapComponent","MetricCardComponent","Page","TableComponent","Tabs","Text"],"description":"Component type"},"value":{"description":"Script used instead of table/filter/… when dataPoint is conditional. Needs schema:write plus records:write","type":"string"},"valueSpec":{"oneOf":[{"type":"object","properties":{"refTableName":{"type":"string","minLength":1},"type":{"type":"string","enum":["reference"]}},"required":["refTableName","type"],"additionalProperties":false},{"type":"object","properties":{"emailBody":{"type":"string"},"emailSubject":{"type":"string"},"maxLength":{"type":"number"},"minLength":{"type":"number"},"type":{"type":"string","enum":["string"]},"variant":{"type":"string","enum":["email","location","multiline-text","phone","text","url"]}},"required":["type"],"additionalProperties":false},{"type":"object","properties":{"max":{"type":"number"},"min":{"type":"number"},"numberFormat":{"type":"object","additionalProperties":{}},"type":{"type":"string","enum":["number"]}},"required":["type"],"additionalProperties":false},{"type":"object","properties":{"options":{"type":"array","items":{"type":"object","properties":{"color":{"type":"string"},"icon":{"type":"object","properties":{"color":{"type":"string"},"filling":{"type":"number","enum":[0,1]},"icon":{"type":"string"}},"required":["icon"],"additionalProperties":false},"id":{"type":"string"},"order":{"type":"number"},"textColor":{"type":"string"},"label":{"type":"string"},"labels":{"type":"object","additionalProperties":{"type":"string"}}},"required":["id"],"additionalProperties":false}},"type":{"type":"string","enum":["choice","multi"]}},"required":["options","type"],"additionalProperties":false},{"type":"object","properties":{"optionColor":{"type":"string"},"optionIcon":{"type":"string"},"optionName":{"type":"string"},"options":{"type":"string"},"type":{"type":"string","enum":["dchoice","dmulti"]}},"required":["options","type"],"additionalProperties":false},{"type":"object","properties":{"timeintervalFormat":{"type":"string"},"type":{"type":"string","enum":["timeinterval"]}},"required":["type"],"additionalProperties":false},{"type":"object","properties":{"timeFormat":{"type":"string"},"type":{"type":"string","enum":["time"]}},"required":["type"],"additionalProperties":false},{"type":"object","properties":{"type":{"type":"string","enum":["file"]},"variant":{"type":"string","enum":["signature"]}},"required":["type"],"additionalProperties":false},{"type":"object","properties":{"type":{"type":"string","enum":["appointment","boolean","color","date","html","icon","timestamp","user"]}},"required":["type"],"additionalProperties":false}],"description":"InputComponent: the type of the value, shaped like a field type, e.g. { type: \"choice\", options: [...] }"},"valueType":{"description":"InputComponent: legacy value type, valueSpec wins where both are given","type":"string","enum":["any","appointment","boolean","color","date","html","icon","number","string","time","timeinterval","timestamp"]},"variant":{"anyOf":[{"type":"string","enum":["","email","location","multiline-text","phone","slider","switch","text","url","bordered","default","faded","flat","ghost","light","shadow","solid","splitted","underlined"]},{"type":"object","properties":{"$nx":{"type":"string","description":"Script expression. Writing one needs records:write as well as schema:write"}},"required":["$nx"]}]},"view":{"type":"object","properties":{"columns":{"description":"View columns","type":"array","items":{"type":"object","properties":{"agg":{"description":"Aggregation function applied to the column","type":"string"},"conditionalStyling":{"description":"Legacy per-column conditional styling rules","type":"array","items":{"type":"object","properties":{"background":{"description":"Background color (hex string)","type":"string"},"cell":{"description":"Target cell","type":"string"},"color":{"description":"Icon color (hex string)","type":"string"},"icon":{"description":"Icon name","type":"string"},"operand":{"type":"string","description":"Comparator"},"value":{"type":"string","description":"Value compared against"}},"required":["operand","value"]}},"field":{"type":"string","description":"Field name, or a script expression for a calculated column"},"hidden":{"description":"Column retained but hidden from the grid","type":"boolean"},"id":{"description":"Stable identity of a calculated column; send it back unchanged when updating the view","type":"string"},"labels":{"description":"Column labels (localized)","type":"object","additionalProperties":{"type":"string"}},"order":{"type":"number","description":"Column display order"},"role":{"description":"Column role (e.g. title, date, image, location, color)","type":"string"},"width":{"description":"Column width","type":"number"}},"required":["field","order"]}},"conditionalFormatting":{"description":"Conditional formatting rules","type":"array","items":{"type":"object","properties":{"backgroundColor":{"description":"Background color (hex string)","type":"string"},"bold":{"description":"Bold text","type":"boolean"},"comparator":{"type":"string","enum":["contains","does_not_contain","ends_with","gt","gte","is","is_empty","is_not","is_not_empty","logic","lt","lte","starts_with"],"description":"Comparator"},"expression":{"description":"Script expression, used only when comparator is 'logic'","type":"string"},"fieldName":{"type":"string","description":"Target field name"},"highlightColor":{"description":"Highlight color (hex string)","type":"string"},"icon":{"description":"Icon","type":"object","properties":{"color":{"description":"Icon color (hex string)","type":"string"},"filling":{"description":"Icon filling","anyOf":[{"type":"number","enum":[0]},{"type":"number","enum":[1]}]},"icon":{"type":"string","description":"Icon name"}},"required":["icon"]},"id":{"type":"string","description":"Stable rule id"},"italic":{"description":"Italic text","type":"boolean"},"order":{"type":"number","description":"Rule evaluation order"},"strikethrough":{"description":"Strikethrough text","type":"boolean"},"target":{"type":"string","enum":["cell","row"],"description":"Whether the rule styles a single cell or the whole row"},"textColor":{"description":"Text color (hex string)","type":"string"},"value":{"description":"Value compared against"}},"required":["comparator","fieldName","id","order","target"]}},"filter":{"description":"Stored filter conditions","type":"array","items":{"type":"object","properties":{"field":{"description":"Field name","type":"string"},"id":{"type":"string","description":"Stable condition id"},"operator":{"description":"Filter operator","type":"string"},"value":{"description":"Value compared against","type":"string"}},"required":["id"]}},"groupBy":{"description":"Grouping configuration","type":"array","items":{"type":"object","properties":{"direction":{"description":"Group order direction, defaults to ascending","type":"string","enum":["asc","desc"]},"fieldName":{"type":"string","description":"Field name"}},"required":["fieldName"]}},"sort":{"description":"Sort configuration","type":"object","properties":{"direction":{"type":"string","enum":["asc","desc"],"description":"Sort direction"},"fieldName":{"type":"string","description":"Field name"}},"required":["direction","fieldName"]}}},"visible":{"anyOf":[{"type":"boolean"},{"type":"object","properties":{"$nx":{"type":"string","description":"Script expression. Writing one needs records:write as well as schema:write"}},"required":["$nx"]}]},"visibleRoles":{"description":"Page: roles allowed to view this page","type":"array","items":{"type":"string"}},"widgetName":{"description":"CustomWidget: folder name under the module widgets directory. A CustomWidget needs schema:write plus records:write","type":"string"},"widgetProps":{"description":"CustomWidget: property values, a PATCH replaces the whole object. A $nx value needs schema:write plus records:write","type":"object","additionalProperties":{"anyOf":[{"type":"boolean"},{"type":"number"},{"type":"string"},{"type":"object","properties":{"$nx":{"type":"string","description":"Script expression. Writing one needs records:write as well as schema:write"}},"required":["$nx"]}]}},"width":{"type":"array","items":{"type":"number"}}},"required":["name","type"],"additionalProperties":false}}}}
```

## The ComponentResponse object

```json
{"openapi":"3.0.0","info":{"title":"Ninox Public API","version":"1.0.0"},"components":{"schemas":{"ComponentResponse":{"type":"object","properties":{"data":{"type":"object","properties":{"afterHide":{"description":"Container directly under Tabs: script run when this tab stops being shown","type":"string"},"aggregation":{"description":"MetricCard: aggregation function","type":"string","enum":["avg","count","max","median","min","sum"]},"annualRecurring":{"description":"Calendar: render every record on the same day/month every year","type":"boolean"},"arrangement":{"description":"Page/Container: layout direction","type":"string","enum":["grid","ltr","row","ttb"]},"background":{"description":"Container/Page/Text: background","anyOf":[{"type":"string"},{"type":"object","properties":{"$nx":{"type":"string","description":"Script expression. Writing one needs records:write as well as schema:write"}},"required":["$nx"]}]},"beforeShow":{"description":"Container directly under Tabs: script run when this tab is shown","type":"string"},"border":{"description":"Container: border","anyOf":[{"type":"object","properties":{"color":{"type":"string"},"style":{"type":"string","enum":["dashed","dotted","double","none","solid"]},"width":{"type":"string"}},"required":["style","width"]},{"type":"object","properties":{"$nx":{"type":"string","description":"Script expression. Writing one needs records:write as well as schema:write"}},"required":["$nx"]}]},"calendarType":{"description":"Calendar: display type","type":"string"},"cardBorder":{"description":"Kanban: card border CSS shorthand, Normal mode only","type":"string"},"cardFont":{"description":"Kanban: card font style tokens, Normal mode only","type":"string"},"cardPadding":{"description":"Kanban: card padding in px, Normal mode only","type":"number"},"cardRadius":{"description":"Kanban: card corner radius in px, Normal mode only","type":"number"},"chartConfig":{"description":"Chart: chart type, axes and data series","type":"object","properties":{"chartType":{"type":"string","enum":["bar","line","pie","funnel","ranking","board"]},"dataSets":{"type":"array","items":{"type":"object","properties":{"aggregation":{"type":"string","enum":["average","count","max","median","min","none","sum"]},"color":{"description":"Series color (hex string)","type":"string"},"fieldName":{"description":"Field name this series reads from","type":"string"},"labels":{"description":"Series labels (localized)","type":"object","additionalProperties":{"type":"string"}}}}},"donut":{"type":"boolean"},"labelPosition":{"type":"string","enum":["bottom","center","inside","outside","top"]},"legend":{"type":"object","properties":{"show":{"type":"boolean"}}},"limit":{"description":"ranking only: how many categories it shows","type":"integer","minimum":1,"maximum":20},"orientation":{"type":"string","enum":["horizontal","vertical"]},"showDataTable":{"type":"boolean"},"showLabels":{"type":"boolean"},"showPoints":{"type":"boolean"},"showTitle":{"type":"boolean"},"smooth":{"type":"boolean"},"stacked":{"type":"boolean"},"style":{"type":"string","enum":["default","half_donut","pad_angle","rounded_corner"]},"tooltips":{"type":"object","properties":{"show":{"type":"boolean"}}},"xAxis":{"type":"object","properties":{"fieldName":{"description":"X-axis field name, null removes it","type":["string","null"]},"groupBy":{"type":"string","enum":["daily","monthly","none","quarterly","weekly","yearly"]},"show":{"type":"boolean"}}},"yAxis":{"type":"object","properties":{"show":{"type":"boolean"}}}},"required":["chartType","dataSets","xAxis"]},"color":{"description":"Text: text color (hex string). Button: theme color name","anyOf":[{"type":"string"},{"type":"object","properties":{"$nx":{"type":"string","description":"Script expression. Writing one needs records:write as well as schema:write"}},"required":["$nx"]}]},"colorFieldName":{"description":"Map: marker color field name","type":"string"},"constraints":{"description":"FieldComponent: script limiting which records a reference can link to, needs schema:manage-permissions","type":"string"},"content":{"description":"Text: content, localized or a script expression","anyOf":[{"type":"object","additionalProperties":{"type":"string"}},{"type":"object","properties":{"$nx":{"type":"string","description":"Script expression. Writing one needs records:write as well as schema:write"}},"required":["$nx"]}]},"customStyle":{"description":"Text: full custom style config, opaque, used only when quickStyle is \"custom\"","type":"object","additionalProperties":{}},"dataPoint":{"description":"'conditional' replaces table/filter/… with the `value` script","type":"string","enum":["conditional","normal"]},"defaultValue":{"description":"InputComponent: initial value, or { $nx: <script> }","anyOf":[{"type":"boolean"},{"type":"number"},{"type":"string"},{"type":"object","properties":{"$nx":{"type":"string","description":"Script expression. Writing one needs records:write as well as schema:write"}},"required":["$nx"]}]},"disabled":{"description":"Button/FieldComponent: disable the control, a boolean or a script","anyOf":[{"type":"boolean"},{"type":"object","properties":{"$nx":{"type":"string","description":"Script expression. Writing one needs records:write as well as schema:write"}},"required":["$nx"]}]},"display":{"description":"MetricCard: display formatting and trend configuration","type":"object","properties":{"color":{"type":"string"},"format":{"type":"string","enum":["compact","currency","number","percentage"]},"icon":{"type":"string"},"trend":{"type":"object","properties":{"customPeriodEnd":{"description":"ISO date (YYYY-MM-DD), for period \"custom\"","type":"string"},"customPeriodStart":{"description":"ISO date (YYYY-MM-DD), for period \"custom\"","type":"string"},"format":{"type":"string","enum":["absolute","percentage"]},"isShown":{"type":"boolean"},"period":{"type":"string","enum":["custom","last_month","last_week","last_year","previous_period","yesterday"]},"positiveDirection":{"type":"string","enum":["down","up"]}},"required":["format","isShown"]}},"required":["color","format","trend"]},"displayAs":{"description":"FieldComponent: how a yes/no field is shown","type":"string"},"expression":{"description":"DynamicHTMLComponent: script returning the HTML to render","type":"string"},"fieldIdDataPoint":{"description":"MetricCard: 'conditional' replaces table/filter/fieldName/aggregation with fieldIdValue","type":"string","enum":["conditional","normal"]},"fieldIdValue":{"description":"MetricCard: whole-dataset script producing the final number when fieldIdDataPoint is conditional","type":"string"},"fieldName":{"description":"MetricCard/Calendar/Map: primary bound field name","type":"string"},"filter":{"description":"MetricCard/Chart: stored filter conditions","type":"array","items":{"type":"object","properties":{"field":{"description":"Field name","type":"string"},"id":{"type":"string","description":"Stable condition id"},"operator":{"description":"Filter operator","type":"string"},"value":{"description":"Value compared against","type":"string"}},"required":["id"]}},"flex":{"description":"Container: flex sizing","anyOf":[{"type":"string"},{"type":"object","properties":{"$nx":{"type":"string","description":"Script expression. Writing one needs records:write as well as schema:write"}},"required":["$nx"]}]},"ganttConfig":{"description":"Gantt: which fields the bars/milestones/dependencies read from","type":"object","properties":{"baselineEndFieldName":{"description":"Planned end field, rendered as a ghost bar","type":["string","null"]},"baselineStartFieldName":{"description":"Planned start field, rendered as a ghost bar","type":["string","null"]},"dependencyDirection":{"type":"string","enum":["predecessor","successor"]},"dependencyFieldName":{"description":"A reference field pointing back at this table","type":["string","null"]},"disableDragAndDrop":{"type":"boolean"},"endFieldName":{"type":["string","null"]},"hideTitleColumn":{"type":"boolean"},"hideWeekends":{"type":"boolean"},"milestoneFieldName":{"type":["string","null"]},"progressFieldName":{"type":["string","null"]},"showCriticalPath":{"type":"boolean"},"showWeekends":{"type":"boolean"},"startFieldName":{"type":["string","null"]},"timeScale":{"type":"string","enum":["day","month","quarter","week"]},"titleColumnFieldName":{"type":["string","null"]},"titleColumnWidth":{"type":"number"}}},"gap":{"description":"Page/Container: gap between children","anyOf":[{"type":"string"},{"type":"object","properties":{"$nx":{"type":"string","description":"Script expression. Writing one needs records:write as well as schema:write"}},"required":["$nx"]}]},"globalFilterBinding":{"description":"MetricCard: field names this card reacts to for global page filters","type":"array","items":{"type":"string"}},"gridPreset":{"description":"Container: grid layout preset","anyOf":[{"type":"string"},{"type":"object","properties":{"$nx":{"type":"string","description":"Script expression. Writing one needs records:write as well as schema:write"}},"required":["$nx"]}]},"groupByFieldName":{"description":"Kanban: lane grouping field name","type":"string"},"height":{"description":"Component height","type":"number"},"icon":{"description":"Page: icon","type":"object","properties":{"color":{"description":"Icon color (hex string)","type":"string"},"filling":{"description":"Icon filling","anyOf":[{"type":"number","enum":[0]},{"type":"number","enum":[1]}]},"icon":{"type":"string","description":"Icon name"}},"required":["icon"]},"iconLeft":{"description":"Button/FieldComponent: icon before the label","anyOf":[{"type":"object","properties":{"color":{"description":"Icon color (hex string)","type":"string"},"filling":{"description":"Icon filling","anyOf":[{"type":"number","enum":[0]},{"type":"number","enum":[1]}]},"icon":{"type":"string","description":"Icon name"}},"required":["icon"]},{"type":"object","properties":{"$nx":{"type":"string","description":"Script expression. Writing one needs records:write as well as schema:write"}},"required":["$nx"]}]},"iconRight":{"description":"Button/FieldComponent: icon after the label","anyOf":[{"type":"object","properties":{"color":{"description":"Icon color (hex string)","type":"string"},"filling":{"description":"Icon filling","anyOf":[{"type":"number","enum":[0]},{"type":"number","enum":[1]}]},"icon":{"type":"string","description":"Icon name"}},"required":["icon"]},{"type":"object","properties":{"$nx":{"type":"string","description":"Script expression. Writing one needs records:write as well as schema:write"}},"required":["$nx"]}]},"id":{"type":"string","description":"Component id"},"imagePosition":{"description":"Kanban: card image crop/anchor, Normal mode only","type":"object","properties":{"position":{"type":"string"},"size":{"type":"string"}}},"isCompact":{"description":"Accordion: compact sections","type":"boolean"},"isHidden":{"description":"Page: hide from navigation","type":"boolean"},"isMarkdownEnabled":{"description":"FieldComponent: render a rich text field as markdown","type":"boolean"},"isSpreadsheetMode":{"description":"Table/FieldComponent: spreadsheet-style editing","type":"boolean"},"kind":{"type":"string","deprecated":true,"description":"Deprecated, use type. Same value, kept so existing integrations keep working"},"labelPosition":{"description":"FieldComponent: top, left, inside or hidden","type":"string"},"labels":{"description":"Component labels (localized)","type":"object","additionalProperties":{"type":"string"}},"mapTypeId":{"description":"Map: base layer type","type":"string"},"margin":{"description":"Container: margin","anyOf":[{"type":"string"},{"type":"object","properties":{"$nx":{"type":"string","description":"Script expression. Writing one needs records:write as well as schema:write"}},"required":["$nx"]}]},"name":{"description":"Component name","type":"string"},"onChange":{"description":"Tabs/FieldComponent: script run when the value changes","type":"string"},"onClick":{"description":"Button: script run on click","type":"string"},"order":{"description":"Component display order","type":"number"},"overflow":{"description":"Container: overflow behavior","anyOf":[{"type":"string"},{"type":"object","properties":{"$nx":{"type":"string","description":"Script expression. Writing one needs records:write as well as schema:write"}},"required":["$nx"]}]},"padding":{"description":"Page/Container: padding","anyOf":[{"type":"string"},{"type":"object","properties":{"$nx":{"type":"string","description":"Script expression. Writing one needs records:write as well as schema:write"}},"required":["$nx"]}]},"parentId":{"description":"Parent component id (forms the component tree)","type":"string"},"placeholder":{"description":"FieldComponent: placeholder, localized, plain or a script","anyOf":[{"type":"object","additionalProperties":{"type":"string"}},{"type":"string"},{"type":"object","properties":{"$nx":{"type":"string","description":"Script expression. Writing one needs records:write as well as schema:write"}},"required":["$nx"]}]},"quickStyle":{"description":"Text: style preset","anyOf":[{"type":"string","enum":["body-md","body-sm","custom","title-lg","title-md","title-sm"]},{"type":"object","properties":{"$nx":{"type":"string","description":"Script expression. Writing one needs records:write as well as schema:write"}},"required":["$nx"]}]},"radius":{"description":"Container/Text: corner radius","anyOf":[{"type":"string"},{"type":"object","properties":{"$nx":{"type":"string","description":"Script expression. Writing one needs records:write as well as schema:write"}},"required":["$nx"]}]},"remember":{"description":"InputComponent: how long the value is kept","type":"string","enum":["localStorage","memory","url"]},"shadow":{"description":"Container: shadow","anyOf":[{"type":"string"},{"type":"object","properties":{"$nx":{"type":"string","description":"Script expression. Writing one needs records:write as well as schema:write"}},"required":["$nx"]}]},"shadowDom":{"description":"DynamicHTMLComponent: render inside a shadow DOM","type":"boolean"},"showAs":{"description":"FieldComponent: how the value is shown (e.g. popup, combobox)","type":"string"},"showBulkActions":{"description":"Table/FieldComponent: show bulk actions","type":"boolean"},"showCalendarType":{"description":"Calendar: show the calendar type switcher","type":"boolean"},"showCreateButton":{"description":"Table: show the create-record button","type":"boolean"},"showCreateRow":{"description":"Table: show the inline create row","type":"boolean"},"showDataAs":{"description":"FieldComponent: script formatting a linked record","type":"string"},"showEmptyLane":{"description":"Kanban: show lanes with no cards","type":"boolean"},"showLinkExistingRecord":{"description":"FieldComponent: offer linking an existing record","type":"boolean"},"showMetadata":{"description":"FieldComponent: show file metadata","type":"boolean"},"showOutlines":{"description":"Page: show layout outlines in the editor","type":"boolean"},"showSearchField":{"description":"Table/Kanban/Gantt/Calendar/Map: show the search field","type":"boolean"},"showTimeScaleSelector":{"description":"Gantt: let the viewer switch time scale","type":"boolean"},"showTitle":{"description":"Table: show the table title","type":"boolean"},"size":{"description":"Button: sm, md or lg","anyOf":[{"type":"string"},{"type":"object","properties":{"$nx":{"type":"string","description":"Script expression. Writing one needs records:write as well as schema:write"}},"required":["$nx"]}]},"tableName":{"description":"Table this component reads from (Chart/Table/Kanban/Gantt/Calendar/Map/MetricCard)","type":"string"},"textAlign":{"description":"Text: alignment","type":"string","enum":["text-center","text-left","text-right"]},"titleFieldName":{"description":"Map: marker title field name","type":"string"},"tooltip":{"description":"FieldComponent: tooltip text","type":"string"},"type":{"type":"string","description":"Component type (e.g. Container, Button, Text, Page), the property the create and update routes and the module definition take"},"value":{"description":"Script used instead of table/filter/… when dataPoint is conditional","type":"string"},"valueSpec":{"description":"InputComponent: the type of the value, shaped like a field type, a reference has refTableName","type":"object","properties":{"type":{"type":"string"}},"required":["type"],"additionalProperties":{}},"valueType":{"description":"InputComponent: legacy value type, valueSpec wins where both are set","type":"string"},"variant":{"description":"Button/Accordion/Tabs: visual variant, InputComponent: text, email, phone, url, ...","anyOf":[{"type":"string"},{"type":"object","properties":{"$nx":{"type":"string","description":"Script expression. Writing one needs records:write as well as schema:write"}},"required":["$nx"]}]},"view":{"description":"Table/MetricCard/Kanban/Gantt/Calendar/Map: columns/filter/groupBy/sort configuration","type":"object","properties":{"columns":{"description":"View columns","type":"array","items":{"type":"object","properties":{"agg":{"description":"Aggregation function applied to the column","type":"string"},"conditionalStyling":{"description":"Legacy per-column conditional styling rules","type":"array","items":{"type":"object","properties":{"background":{"description":"Background color (hex string)","type":"string"},"cell":{"description":"Target cell","type":"string"},"color":{"description":"Icon color (hex string)","type":"string"},"icon":{"description":"Icon name","type":"string"},"operand":{"type":"string","description":"Comparator"},"value":{"type":"string","description":"Value compared against"}},"required":["operand","value"]}},"field":{"type":"string","description":"Field name, or a script expression for a calculated column"},"hidden":{"description":"Column retained but hidden from the grid","type":"boolean"},"id":{"description":"Stable identity of a calculated column; send it back unchanged when updating the view","type":"string"},"labels":{"description":"Column labels (localized)","type":"object","additionalProperties":{"type":"string"}},"order":{"type":"number","description":"Column display order"},"role":{"description":"Column role (e.g. title, date, image, location, color)","type":"string"},"width":{"description":"Column width","type":"number"}},"required":["field","order"]}},"conditionalFormatting":{"description":"Conditional formatting rules","type":"array","items":{"type":"object","properties":{"backgroundColor":{"description":"Background color (hex string)","type":"string"},"bold":{"description":"Bold text","type":"boolean"},"comparator":{"type":"string","enum":["contains","does_not_contain","ends_with","gt","gte","is","is_empty","is_not","is_not_empty","logic","lt","lte","starts_with"],"description":"Comparator"},"expression":{"description":"Script expression, used only when comparator is 'logic'","type":"string"},"fieldName":{"type":"string","description":"Target field name"},"highlightColor":{"description":"Highlight color (hex string)","type":"string"},"icon":{"description":"Icon","type":"object","properties":{"color":{"description":"Icon color (hex string)","type":"string"},"filling":{"description":"Icon filling","anyOf":[{"type":"number","enum":[0]},{"type":"number","enum":[1]}]},"icon":{"type":"string","description":"Icon name"}},"required":["icon"]},"id":{"type":"string","description":"Stable rule id"},"italic":{"description":"Italic text","type":"boolean"},"order":{"type":"number","description":"Rule evaluation order"},"strikethrough":{"description":"Strikethrough text","type":"boolean"},"target":{"type":"string","enum":["cell","row"],"description":"Whether the rule styles a single cell or the whole row"},"textColor":{"description":"Text color (hex string)","type":"string"},"value":{"description":"Value compared against"}},"required":["comparator","fieldName","id","order","target"]}},"filter":{"description":"Stored filter conditions","type":"array","items":{"type":"object","properties":{"field":{"description":"Field name","type":"string"},"id":{"type":"string","description":"Stable condition id"},"operator":{"description":"Filter operator","type":"string"},"value":{"description":"Value compared against","type":"string"}},"required":["id"]}},"groupBy":{"description":"Grouping configuration","type":"array","items":{"type":"object","properties":{"direction":{"description":"Group order direction, defaults to ascending","type":"string","enum":["asc","desc"]},"fieldName":{"type":"string","description":"Field name"}},"required":["fieldName"]}},"sort":{"description":"Sort configuration","type":"object","properties":{"direction":{"type":"string","enum":["asc","desc"],"description":"Sort direction"},"fieldName":{"type":"string","description":"Field name"}},"required":["direction","fieldName"]}}},"visible":{"description":"Conditional visibility logic: a boolean, or a script expression (as { $nx: <script> }) evaluated at render time","anyOf":[{"type":"boolean"},{"type":"object","properties":{"$nx":{"type":"string","description":"Script expression. Writing one needs records:write as well as schema:write"}},"required":["$nx"]}]},"visibleRoles":{"description":"Page: roles allowed to view this page","type":"array","items":{"type":"string"}},"widgetName":{"description":"CustomWidget: folder name under the workspace widgets directory","type":"string"},"widgetProps":{"description":"CustomWidget: property values, each static or a script expression (as { $nx: <script> })","type":"object","additionalProperties":{"anyOf":[{"type":"boolean"},{"type":"number"},{"type":"string"},{"type":"object","properties":{"$nx":{"type":"string","description":"Script expression. Writing one needs records:write as well as schema:write"}},"required":["$nx"]}]}},"width":{"description":"Component width: number = legacy px, string = percentage e.g. \"50%\"","type":["number","string"]}},"description":"Component details"}},"required":["data"]}}}}
```

## The ErrorResponse object

```json
{"openapi":"3.0.0","info":{"title":"Ninox Public API","version":"1.0.0"},"components":{"schemas":{"ErrorResponse":{"type":"object","properties":{"error":{"type":"object","properties":{"message":{"type":"string","description":"Error message"}}}},"required":["error"]}}}}
```

## The DeleteComponentResponse object

```json
{"openapi":"3.0.0","info":{"title":"Ninox Public API","version":"1.0.0"},"components":{"schemas":{"DeleteComponentResponse":{"type":"object","properties":{"data":{"type":"object","properties":{"id":{"type":"string","description":"Deleted component id"}}}},"required":["data"]}}}}
```

## The UpdateComponentBody object

```json
{"openapi":"3.0.0","info":{"title":"Ninox Public API","version":"1.0.0"},"components":{"schemas":{"UpdateComponentBody":{"type":"object","properties":{"afterHide":{"description":"Container directly under Tabs: script run when this tab stops being shown, null removes it, 400 anywhere else. Needs schema:write plus records:write","type":"array","items":{"type":"string"}},"aggregation":{"type":"string","enum":["avg","count","max","median","min","sum"]},"annualRecurring":{"type":"boolean"},"arrangement":{"type":"string","enum":["grid","ltr","row","ttb"]},"background":{"anyOf":[{"type":"string"},{"type":"object","properties":{"$nx":{"type":"string","description":"Script expression. Writing one needs records:write as well as schema:write"}},"required":["$nx"]}]},"beforeShow":{"description":"Container directly under Tabs: script run when this tab is shown, null removes it, 400 anywhere else. Needs schema:write plus records:write","type":"array","items":{"type":"string"}},"border":{"anyOf":[{"type":"object","properties":{"color":{"type":"string"},"style":{"type":"string","enum":["dashed","dotted","double","none","solid"]},"width":{"type":"string"}},"required":["style","width"]},{"type":"object","properties":{"$nx":{"type":"string","description":"Script expression. Writing one needs records:write as well as schema:write"}},"required":["$nx"]}]},"calendarType":{"type":"string"},"cardBorder":{"type":"string"},"cardFont":{"type":"string"},"cardPadding":{"type":"number"},"cardRadius":{"type":"number"},"chartConfig":{"type":"object","properties":{"chartType":{"type":"string","enum":["bar","line","pie","funnel","ranking","board"]},"dataSets":{"type":"array","items":{"type":"object","properties":{"aggregation":{"type":"string","enum":["average","count","max","median","min","none","sum"]},"color":{"description":"Series color (hex string)","type":"string"},"fieldName":{"description":"Field name this series reads from","type":"string"},"labels":{"description":"Series labels (localized)","type":"object","additionalProperties":{"type":"string"}}}}},"donut":{"type":"boolean"},"labelPosition":{"type":"string","enum":["bottom","center","inside","outside","top"]},"legend":{"type":"object","properties":{"show":{"type":"boolean"}}},"limit":{"description":"ranking only: how many categories it shows","type":"integer","minimum":1,"maximum":20},"orientation":{"type":"string","enum":["horizontal","vertical"]},"showDataTable":{"type":"boolean"},"showLabels":{"type":"boolean"},"showPoints":{"type":"boolean"},"showTitle":{"type":"boolean"},"smooth":{"type":"boolean"},"stacked":{"type":"boolean"},"style":{"type":"string","enum":["default","half_donut","pad_angle","rounded_corner"]},"tooltips":{"type":"object","properties":{"show":{"type":"boolean"}}},"xAxis":{"type":"object","properties":{"fieldName":{"description":"X-axis field name, null removes it","type":["string","null"]},"groupBy":{"type":"string","enum":["daily","monthly","none","quarterly","weekly","yearly"]},"show":{"type":"boolean"}}},"yAxis":{"type":"object","properties":{"show":{"type":"boolean"}}}}},"color":{"anyOf":[{"type":"string"},{"type":"object","properties":{"$nx":{"type":"string","description":"Script expression. Writing one needs records:write as well as schema:write"}},"required":["$nx"]}]},"colorFieldName":{"type":"string"},"constraints":{"description":"FieldComponent: reference guard, null removes it","type":"array","items":{"type":"string"}},"content":{"anyOf":[{"type":"object","additionalProperties":{"type":"string","minLength":1,"maxLength":100}},{"type":"object","properties":{"$nx":{"type":"string","description":"Script expression. Writing one needs records:write as well as schema:write"}},"required":["$nx"]}]},"customStyle":{"type":"object","additionalProperties":{}},"dataPoint":{"type":"string","enum":["conditional","normal"]},"defaultValue":{"description":"InputComponent: initial value, or { $nx: <script> } which needs schema:write plus records:write","anyOf":[{"type":"boolean"},{"type":"number"},{"type":"string"},{"type":"object","properties":{"$nx":{"type":"string","description":"Script expression. Writing one needs records:write as well as schema:write"}},"required":["$nx"]}]},"disabled":{"anyOf":[{"type":"boolean"},{"type":"object","properties":{"$nx":{"type":"string","description":"Script expression. Writing one needs records:write as well as schema:write"}},"required":["$nx"]}]},"display":{"type":"object","properties":{"color":{"type":"string"},"format":{"type":"string","enum":["compact","currency","number","percentage"]},"icon":{"type":"string"},"trend":{"type":"object","properties":{"customPeriodEnd":{"type":"string"},"customPeriodStart":{"type":"string"},"format":{"type":"string","enum":["absolute","percentage"]},"isShown":{"type":"boolean"},"period":{"type":"string","enum":["custom","last_month","last_week","last_year","previous_period","yesterday"]},"positiveDirection":{"type":"string","enum":["down","up"]}},"required":["format","isShown"]}}},"displayAs":{"description":"FieldComponent: how a yes/no field is shown","type":"string","enum":["checkbox","dropdown","switch","tabs"]},"expression":{"description":"DynamicHTMLComponent: HTML script, null removes it. Needs schema:write plus records:write","type":"array","items":{"type":"string"}},"fieldIdDataPoint":{"type":"string","enum":["conditional","normal"]},"fieldIdValue":{"description":"MetricCardComponent: script computing the value. Needs schema:write plus records:write","type":"string"},"fieldName":{"type":"string"},"filter":{"type":"array","items":{"type":"object","properties":{"field":{"type":"string"},"id":{"type":"string"},"operator":{"type":"string"},"value":{"type":"string"}},"required":["id"]}},"flex":{"anyOf":[{"type":"string"},{"type":"object","properties":{"$nx":{"type":"string","description":"Script expression. Writing one needs records:write as well as schema:write"}},"required":["$nx"]}]},"ganttConfig":{"type":"object","properties":{"baselineEndFieldName":{"description":"Planned end field, rendered as a ghost bar","type":["string","null"]},"baselineStartFieldName":{"description":"Planned start field, rendered as a ghost bar","type":["string","null"]},"dependencyDirection":{"type":"string","enum":["predecessor","successor"]},"dependencyFieldName":{"description":"A reference field pointing back at this table","type":["string","null"]},"disableDragAndDrop":{"type":"boolean"},"endFieldName":{"type":["string","null"]},"hideTitleColumn":{"type":"boolean"},"hideWeekends":{"type":"boolean"},"milestoneFieldName":{"type":["string","null"]},"progressFieldName":{"type":["string","null"]},"showCriticalPath":{"type":"boolean"},"showWeekends":{"type":"boolean"},"startFieldName":{"type":["string","null"]},"timeScale":{"type":"string","enum":["day","month","quarter","week"]},"titleColumnFieldName":{"type":["string","null"]},"titleColumnWidth":{"type":"number"}}},"gap":{"anyOf":[{"type":"string"},{"type":"object","properties":{"$nx":{"type":"string","description":"Script expression. Writing one needs records:write as well as schema:write"}},"required":["$nx"]}]},"globalFilterBinding":{"type":"array","items":{"type":"string"}},"gridPreset":{"anyOf":[{"type":"string"},{"type":"object","properties":{"$nx":{"type":"string","description":"Script expression. Writing one needs records:write as well as schema:write"}},"required":["$nx"]}]},"groupByFieldName":{"type":"string"},"height":{"type":"number"},"icon":{"description":"Page icon","type":"object","properties":{"color":{"type":"string"},"filling":{"anyOf":[{"type":"number","enum":[0]},{"type":"number","enum":[1]}]},"icon":{"type":"string","minLength":1}}},"iconLeft":{"anyOf":[{"type":"object","properties":{"color":{"type":"string"},"filling":{"anyOf":[{"type":"number","enum":[0]},{"type":"number","enum":[1]}]},"icon":{"type":"string","minLength":1}},"required":["icon"]},{"type":"object","properties":{"$nx":{"type":"string","description":"Script expression. Writing one needs records:write as well as schema:write"}},"required":["$nx"]}]},"iconRight":{"anyOf":[{"type":"object","properties":{"color":{"type":"string"},"filling":{"anyOf":[{"type":"number","enum":[0]},{"type":"number","enum":[1]}]},"icon":{"type":"string","minLength":1}},"required":["icon"]},{"type":"object","properties":{"$nx":{"type":"string","description":"Script expression. Writing one needs records:write as well as schema:write"}},"required":["$nx"]}]},"imagePosition":{"type":"object","properties":{"position":{"type":"string"},"size":{"type":"string"}}},"isCompact":{"type":"boolean"},"isHidden":{"description":"Page: hide from navigation","type":"boolean"},"isMarkdownEnabled":{"type":"boolean"},"isSpreadsheetMode":{"type":"boolean"},"labelPosition":{"type":"string","enum":["hidden","inside","left","top"]},"labels":{"description":"Component labels (localized)","type":"object","additionalProperties":{"type":"string","minLength":1,"maxLength":100}},"mapTypeId":{"type":"string"},"margin":{"anyOf":[{"type":"string"},{"type":"object","properties":{"$nx":{"type":"string","description":"Script expression. Writing one needs records:write as well as schema:write"}},"required":["$nx"]}]},"name":{"type":"string","minLength":1,"maxLength":100,"pattern":"^[a-z0-9_]+$","description":"Component name"},"onChange":{"description":"Tabs/FieldComponent: change script, null removes it. Needs schema:write plus records:write","type":"array","items":{"type":"string"}},"onClick":{"description":"Button: click script, null removes it. Needs schema:write plus records:write","type":"array","items":{"type":"string"}},"overflow":{"anyOf":[{"type":"string"},{"type":"object","properties":{"$nx":{"type":"string","description":"Script expression. Writing one needs records:write as well as schema:write"}},"required":["$nx"]}]},"padding":{"anyOf":[{"type":"string"},{"type":"object","properties":{"$nx":{"type":"string","description":"Script expression. Writing one needs records:write as well as schema:write"}},"required":["$nx"]}]},"parentId":{"description":"Parent component id, required unless type is 'Page' (a Page's parent may also be its table's object id)","type":"string","minLength":12,"maxLength":12,"pattern":"^[a-z0-9]+$"},"placeholder":{"anyOf":[{"type":"object","additionalProperties":{"type":"string","minLength":1,"maxLength":100}},{"type":"string"},{"type":"object","properties":{"$nx":{"type":"string","description":"Script expression. Writing one needs records:write as well as schema:write"}},"required":["$nx"]}]},"quickStyle":{"anyOf":[{"type":"string","enum":["body-md","body-sm","custom","title-lg","title-md","title-sm"]},{"type":"object","properties":{"$nx":{"type":"string","description":"Script expression. Writing one needs records:write as well as schema:write"}},"required":["$nx"]}]},"radius":{"anyOf":[{"type":"string"},{"type":"object","properties":{"$nx":{"type":"string","description":"Script expression. Writing one needs records:write as well as schema:write"}},"required":["$nx"]}]},"remember":{"description":"InputComponent: how long the value is kept, defaults to memory","type":"string","enum":["localStorage","memory","url"]},"shadow":{"anyOf":[{"type":"string"},{"type":"object","properties":{"$nx":{"type":"string","description":"Script expression. Writing one needs records:write as well as schema:write"}},"required":["$nx"]}]},"shadowDom":{"type":"boolean"},"showAs":{"type":"string"},"showBulkActions":{"type":"boolean"},"showCalendarType":{"type":"boolean"},"showCreateButton":{"type":"boolean"},"showCreateRow":{"type":"boolean"},"showDataAs":{"description":"FieldComponent: display script, null removes it. Needs schema:write plus records:write","type":"array","items":{"type":"string"}},"showEmptyLane":{"type":"boolean"},"showLinkExistingRecord":{"type":"boolean"},"showMetadata":{"type":"boolean"},"showOutlines":{"description":"Page: show layout outlines in the editor","type":"boolean"},"showSearchField":{"type":"boolean"},"showTimeScaleSelector":{"type":"boolean"},"showTitle":{"type":"boolean"},"size":{"anyOf":[{"type":"string","enum":["lg","md","sm"]},{"type":"object","properties":{"$nx":{"type":"string","description":"Script expression. Writing one needs records:write as well as schema:write"}},"required":["$nx"]}]},"tableName":{"description":"Table this component reads from","type":"string"},"textAlign":{"type":"string","enum":["text-center","text-left","text-right"]},"titleFieldName":{"type":"string"},"tooltip":{"type":"string"},"type":{"type":"string","enum":["Accordion","Button","CalendarComponent","ChartComponent","Container","CustomWidget","DynamicHTMLComponent","FieldComponent","GanttComponent","InputComponent","KanbanComponent","MapComponent","MetricCardComponent","Page","TableComponent","Tabs","Text"],"description":"Component type"},"value":{"description":"Script used instead of table/filter/… when dataPoint is conditional. Needs schema:write plus records:write","type":"string"},"valueSpec":{"oneOf":[{"type":"object","properties":{"refTableName":{"type":"string","minLength":1},"type":{"type":"string","enum":["reference"]}},"required":["refTableName","type"],"additionalProperties":false},{"type":"object","properties":{"emailBody":{"type":"string"},"emailSubject":{"type":"string"},"maxLength":{"type":"number"},"minLength":{"type":"number"},"type":{"type":"string","enum":["string"]},"variant":{"type":"string","enum":["email","location","multiline-text","phone","text","url"]}},"required":["type"],"additionalProperties":false},{"type":"object","properties":{"max":{"type":"number"},"min":{"type":"number"},"numberFormat":{"type":"object","additionalProperties":{}},"type":{"type":"string","enum":["number"]}},"required":["type"],"additionalProperties":false},{"type":"object","properties":{"options":{"type":"array","items":{"type":"object","properties":{"color":{"type":"string"},"icon":{"type":"object","properties":{"color":{"type":"string"},"filling":{"type":"number","enum":[0,1]},"icon":{"type":"string"}},"required":["icon"],"additionalProperties":false},"id":{"type":"string"},"order":{"type":"number"},"textColor":{"type":"string"},"label":{"type":"string"},"labels":{"type":"object","additionalProperties":{"type":"string"}}},"required":["id"],"additionalProperties":false}},"type":{"type":"string","enum":["choice","multi"]}},"required":["options","type"],"additionalProperties":false},{"type":"object","properties":{"optionColor":{"type":"string"},"optionIcon":{"type":"string"},"optionName":{"type":"string"},"options":{"type":"string"},"type":{"type":"string","enum":["dchoice","dmulti"]}},"required":["options","type"],"additionalProperties":false},{"type":"object","properties":{"timeintervalFormat":{"type":"string"},"type":{"type":"string","enum":["timeinterval"]}},"required":["type"],"additionalProperties":false},{"type":"object","properties":{"timeFormat":{"type":"string"},"type":{"type":"string","enum":["time"]}},"required":["type"],"additionalProperties":false},{"type":"object","properties":{"type":{"type":"string","enum":["file"]},"variant":{"type":"string","enum":["signature"]}},"required":["type"],"additionalProperties":false},{"type":"object","properties":{"type":{"type":"string","enum":["appointment","boolean","color","date","html","icon","timestamp","user"]}},"required":["type"],"additionalProperties":false}],"description":"InputComponent: the type of the value, shaped like a field type, e.g. { type: \"choice\", options: [...] }"},"valueType":{"description":"InputComponent: legacy value type, valueSpec wins where both are given","type":"string","enum":["any","appointment","boolean","color","date","html","icon","number","string","time","timeinterval","timestamp"]},"variant":{"anyOf":[{"type":"string","enum":["","email","location","multiline-text","phone","slider","switch","text","url","bordered","default","faded","flat","ghost","light","shadow","solid","splitted","underlined"]},{"type":"object","properties":{"$nx":{"type":"string","description":"Script expression. Writing one needs records:write as well as schema:write"}},"required":["$nx"]}]},"view":{"type":"object","properties":{"columns":{"description":"View columns","type":"array","items":{"type":"object","properties":{"agg":{"description":"Aggregation function applied to the column","type":"string"},"conditionalStyling":{"description":"Legacy per-column conditional styling rules","type":"array","items":{"type":"object","properties":{"background":{"description":"Background color (hex string)","type":"string"},"cell":{"description":"Target cell","type":"string"},"color":{"description":"Icon color (hex string)","type":"string"},"icon":{"description":"Icon name","type":"string"},"operand":{"type":"string","description":"Comparator"},"value":{"type":"string","description":"Value compared against"}},"required":["operand","value"]}},"field":{"type":"string","description":"Field name, or a script expression for a calculated column"},"hidden":{"description":"Column retained but hidden from the grid","type":"boolean"},"id":{"description":"Stable identity of a calculated column; send it back unchanged when updating the view","type":"string"},"labels":{"description":"Column labels (localized)","type":"object","additionalProperties":{"type":"string"}},"order":{"type":"number","description":"Column display order"},"role":{"description":"Column role (e.g. title, date, image, location, color)","type":"string"},"width":{"description":"Column width","type":"number"}},"required":["field","order"]}},"conditionalFormatting":{"description":"Conditional formatting rules","type":"array","items":{"type":"object","properties":{"backgroundColor":{"description":"Background color (hex string)","type":"string"},"bold":{"description":"Bold text","type":"boolean"},"comparator":{"type":"string","enum":["contains","does_not_contain","ends_with","gt","gte","is","is_empty","is_not","is_not_empty","logic","lt","lte","starts_with"],"description":"Comparator"},"expression":{"description":"Script expression, used only when comparator is 'logic'","type":"string"},"fieldName":{"type":"string","description":"Target field name"},"highlightColor":{"description":"Highlight color (hex string)","type":"string"},"icon":{"description":"Icon","type":"object","properties":{"color":{"description":"Icon color (hex string)","type":"string"},"filling":{"description":"Icon filling","anyOf":[{"type":"number","enum":[0]},{"type":"number","enum":[1]}]},"icon":{"type":"string","description":"Icon name"}},"required":["icon"]},"id":{"type":"string","description":"Stable rule id"},"italic":{"description":"Italic text","type":"boolean"},"order":{"type":"number","description":"Rule evaluation order"},"strikethrough":{"description":"Strikethrough text","type":"boolean"},"target":{"type":"string","enum":["cell","row"],"description":"Whether the rule styles a single cell or the whole row"},"textColor":{"description":"Text color (hex string)","type":"string"},"value":{"description":"Value compared against"}},"required":["comparator","fieldName","id","order","target"]}},"filter":{"description":"Stored filter conditions","type":"array","items":{"type":"object","properties":{"field":{"description":"Field name","type":"string"},"id":{"type":"string","description":"Stable condition id"},"operator":{"description":"Filter operator","type":"string"},"value":{"description":"Value compared against","type":"string"}},"required":["id"]}},"groupBy":{"description":"Grouping configuration","type":"array","items":{"type":"object","properties":{"direction":{"description":"Group order direction, defaults to ascending","type":"string","enum":["asc","desc"]},"fieldName":{"type":"string","description":"Field name"}},"required":["fieldName"]}},"sort":{"description":"Sort configuration","type":"object","properties":{"direction":{"type":"string","enum":["asc","desc"],"description":"Sort direction"},"fieldName":{"type":"string","description":"Field name"}},"required":["direction","fieldName"]}}},"visible":{"anyOf":[{"type":"boolean"},{"type":"object","properties":{"$nx":{"type":"string","description":"Script expression. Writing one needs records:write as well as schema:write"}},"required":["$nx"]}]},"visibleRoles":{"type":"array","items":{"type":"string"},"description":"Page: roles allowed to view this page, null removes the restriction","nullable":true},"widgetName":{"description":"CustomWidget: folder name under the module widgets directory. A CustomWidget needs schema:write plus records:write","type":"string"},"widgetProps":{"description":"CustomWidget: property values, a PATCH replaces the whole object. A $nx value needs schema:write plus records:write","type":"object","additionalProperties":{"anyOf":[{"type":"boolean"},{"type":"number"},{"type":"string"},{"type":"object","properties":{"$nx":{"type":"string","description":"Script expression. Writing one needs records:write as well as schema:write"}},"required":["$nx"]}]}},"width":{"type":"array","items":{"type":"number"}}},"additionalProperties":false}}}}
```

## The CreateFieldBody object

```json
{"openapi":"3.0.0","info":{"title":"Ninox Public API","version":"1.0.0"},"components":{"schemas":{"CreateFieldBody":{"type":"object","properties":{"canRead":{"description":"Script expression that must allow reading this field's value","type":"string","minLength":1},"canWrite":{"description":"Script expression that must allow writing this field's value","type":"string","minLength":1},"expression":{"description":"Expression (for function type)","type":"string"},"labels":{"type":"object","additionalProperties":{"type":"string","minLength":1,"maxLength":100},"description":"Field labels (localized)"},"name":{"type":"string","minLength":1,"maxLength":100,"pattern":"^[a-z0-9_]+$","description":"Field name"},"optionColor":{"description":"Color expression (for dchoice/dmulti types)","type":"string"},"optionIcon":{"description":"Icon expression (for dchoice/dmulti types)","type":"string"},"optionName":{"description":"Display name expression (for dchoice/dmulti types)","type":"string"},"options":{"description":"Options array (for choice/multi types) or selection expression (for dchoice/dmulti types)","anyOf":[{"type":"array","items":{"type":"object","properties":{"color":{"description":"Option color (hex string)","type":"string"},"icon":{"description":"Option icon name","type":"string"},"id":{"description":"Option id (omit for new options; system assigns id)","type":"string"},"label":{"type":"string","minLength":1,"description":"Option text in the default language"},"labels":{"description":"Option text per language","type":"object","additionalProperties":{"type":"string"}},"order":{"description":"Option display order","type":"integer","minimum":0,"maximum":9007199254740991},"previousId":{"description":"Current id of an existing option to give the new id in `id`. Records holding the old id follow.","type":"string"},"textColor":{"description":"Option text color (hex string)","type":"string"}},"required":["label"],"additionalProperties":false}},{"type":"string"}]},"refTableName":{"type":"string","minLength":1,"maxLength":100,"pattern":"^[a-z0-9_]+$","default":null,"description":"Reference table name (for reference/reverse types)","nullable":true},"showInTable":{"description":"Show this field as a column in the table's default view (default: true)","type":"boolean"},"type":{"type":"string","enum":["string","html","number","boolean","choice","dchoice","multi","dmulti","file","date","timestamp","time","timeinterval","appointment","icon","color","user","reference","reverse","function"],"description":"Field type"},"variant":{"description":"Field variant (for string type)","type":"string","enum":["multiline-text","text","phone","email","url","location","signature"]},"defaultValue":{"description":"Default value applied when a record is created: a literal value (an array of option ids for multi/dmulti), or a script expression (as { $nx: <script> }) evaluated at creation time","anyOf":[{"type":"object","properties":{"$nx":{"type":"string","description":"Script expression"}},"required":["$nx"]},{"type":"array","items":{"type":"string"}},{"type":"boolean"},{"type":"number"},{"type":"string"}],"nullable":true},"index":{"description":"Field is indexed","type":"boolean"},"onUpdate":{"description":"Script expression run as a row trigger when the field value changes","type":"string"},"readRoles":{"description":"Roles allowed to read the field (\"user\" is a deprecated alias for \"editor\")","minItems":1,"maxItems":3,"type":"array","items":{"type":"string","enum":["admin","editor","user"]}},"required":{"description":"Field is required","type":"boolean"},"search":{"description":"Field is searchable","type":"boolean"},"unique":{"description":"Field is unique","type":"boolean"},"writeRoles":{"description":"Roles allowed to write to the field (\"user\" is a deprecated alias for \"editor\")","minItems":1,"maxItems":3,"type":"array","items":{"type":"string","enum":["admin","editor","user"]}}},"required":["labels","name","type"],"additionalProperties":false}}}}
```

## The FieldResponse object

```json
{"openapi":"3.0.0","info":{"title":"Ninox Public API","version":"1.0.0"},"components":{"schemas":{"FieldResponse":{"type":"object","properties":{"data":{"type":"object","properties":{"binding":{"description":"Read-only: internal binding reference, format not yet specified","type":"string"},"canRead":{"description":"Script expression gating field-level read access","type":"string"},"canWrite":{"description":"Script expression gating field-level write access","type":"string"},"defaultValue":{"description":"Default value applied when a record is created: a literal value (an array of option ids for multi/dmulti), or a script expression (as { $nx: <script> }) evaluated at creation time","anyOf":[{"type":"object","properties":{"$nx":{"type":"string","description":"Script expression. Writing one needs records:write as well as schema:write"}},"required":["$nx"]},{"type":["boolean","null","number","string"]},{"type":"array","items":{"type":"string"}}]},"expression":{"description":"Expression (for function type)","type":"string"},"index":{"description":"Field is indexed","type":"boolean"},"labels":{"description":"Field labels (localized)","type":"object","additionalProperties":{"type":"string"}},"name":{"type":"string","description":"Field name"},"onUpdate":{"description":"Script expression run as a row trigger when the field value changes","type":"string"},"optionColor":{"description":"Color expression for dchoice/dmulti fields","type":"string"},"optionIcon":{"description":"Icon expression for dchoice/dmulti fields","type":"string"},"optionName":{"description":"Display name expression for dchoice/dmulti fields","type":"string"},"options":{"description":"Options array for choice/multi fields, or selection expression for dchoice/dmulti fields","anyOf":[{"type":"array","items":{"type":"object","properties":{"color":{"description":"Option color (hex string)","type":"string"},"icon":{"description":"Option icon name","type":"string"},"id":{"type":"string","description":"Option id, a string the caller can set and change"},"label":{"type":"string","description":"Option text in the default language"},"labels":{"description":"Option text per language","type":"object","additionalProperties":{"type":"string"}},"order":{"type":"number","description":"Option display order"},"textColor":{"description":"Option text color (hex string)","type":"string"}},"required":["id","label","order"]}},{"type":"string"}]},"readRoles":{"description":"Roles allowed to read the field","type":"array","items":{"type":"string"}},"refTableName":{"description":"Reference table name","type":"string"},"required":{"description":"Field is required","type":"boolean"},"search":{"description":"Field is searchable","type":"boolean"},"syncedFrom":{"description":"Source column this field syncs from. Read-only unless the table has two-way sync with updates enabled, in which case every synced field except the key column is writable.","type":"string"},"type":{"type":"string","enum":["any","appointment","boolean","choice","color","date","dchoice","dmulti","file","function","html","icon","lambda","multi","number","react","reference","reverse","rowId","string","styled","time","timeinterval","timestamp","unknown","user","void"],"description":"Field type"},"unique":{"description":"Field is unique","type":"boolean"},"variant":{"description":"Field variant (for string type)","type":"string"},"writeRoles":{"description":"Roles allowed to write to the field","type":"array","items":{"type":"string"}}},"description":"Field details"}},"required":["data"]}}}}
```

## The CreateFieldsBatchBody object

```json
{"openapi":"3.0.0","info":{"title":"Ninox Public API","version":"1.0.0"},"components":{"schemas":{"CreateFieldsBatchBody":{"minItems":1,"type":"array","items":{"type":"object","properties":{"canRead":{"description":"Script expression that must allow reading this field's value","type":"string","minLength":1},"canWrite":{"description":"Script expression that must allow writing this field's value","type":"string","minLength":1},"expression":{"description":"Expression (for function type)","type":"string"},"labels":{"type":"object","additionalProperties":{"type":"string","minLength":1,"maxLength":100},"description":"Field labels (localized)"},"name":{"type":"string","minLength":1,"maxLength":100,"pattern":"^[a-z0-9_]+$","description":"Field name"},"optionColor":{"description":"Color expression (for dchoice/dmulti types)","type":"string"},"optionIcon":{"description":"Icon expression (for dchoice/dmulti types)","type":"string"},"optionName":{"description":"Display name expression (for dchoice/dmulti types)","type":"string"},"options":{"description":"Options array (for choice/multi types) or selection expression (for dchoice/dmulti types)","anyOf":[{"type":"array","items":{"type":"object","properties":{"color":{"description":"Option color (hex string)","type":"string"},"icon":{"description":"Option icon name","type":"string"},"id":{"description":"Option id (omit for new options; system assigns id)","type":"string"},"label":{"type":"string","minLength":1,"description":"Option text in the default language"},"labels":{"description":"Option text per language","type":"object","additionalProperties":{"type":"string"}},"order":{"description":"Option display order","type":"integer","minimum":0,"maximum":9007199254740991},"previousId":{"description":"Current id of an existing option to give the new id in `id`. Records holding the old id follow.","type":"string"},"textColor":{"description":"Option text color (hex string)","type":"string"}},"required":["label"],"additionalProperties":false}},{"type":"string"}]},"refTableName":{"type":"string","minLength":1,"maxLength":100,"pattern":"^[a-z0-9_]+$","default":null,"description":"Reference table name (for reference/reverse types)","nullable":true},"showInTable":{"description":"Show this field as a column in the table's default view (default: true)","type":"boolean"},"type":{"type":"string","enum":["string","html","number","boolean","choice","dchoice","multi","dmulti","file","date","timestamp","time","timeinterval","appointment","icon","color","user","reference","reverse","function"],"description":"Field type"},"variant":{"description":"Field variant (for string type)","type":"string","enum":["multiline-text","text","phone","email","url","location","signature"]},"defaultValue":{"description":"Default value applied when a record is created: a literal value (an array of option ids for multi/dmulti), or a script expression (as { $nx: <script> }) evaluated at creation time","anyOf":[{"type":"object","properties":{"$nx":{"type":"string","description":"Script expression"}},"required":["$nx"]},{"type":"array","items":{"type":"string"}},{"type":"boolean"},{"type":"number"},{"type":"string"}],"nullable":true},"index":{"description":"Field is indexed","type":"boolean"},"onUpdate":{"description":"Script expression run as a row trigger when the field value changes","type":"string"},"readRoles":{"description":"Roles allowed to read the field (\"user\" is a deprecated alias for \"editor\")","minItems":1,"maxItems":3,"type":"array","items":{"type":"string","enum":["admin","editor","user"]}},"required":{"description":"Field is required","type":"boolean"},"search":{"description":"Field is searchable","type":"boolean"},"unique":{"description":"Field is unique","type":"boolean"},"writeRoles":{"description":"Roles allowed to write to the field (\"user\" is a deprecated alias for \"editor\")","minItems":1,"maxItems":3,"type":"array","items":{"type":"string","enum":["admin","editor","user"]}}},"required":["labels","name","type"],"additionalProperties":false}}}}}
```

## The FieldsResponse object

```json
{"openapi":"3.0.0","info":{"title":"Ninox Public API","version":"1.0.0"},"components":{"schemas":{"FieldsResponse":{"type":"object","properties":{"data":{"type":"array","items":{"type":"object","properties":{"binding":{"description":"Read-only: internal binding reference, format not yet specified","type":"string"},"canRead":{"description":"Script expression gating field-level read access","type":"string"},"canWrite":{"description":"Script expression gating field-level write access","type":"string"},"defaultValue":{"description":"Default value applied when a record is created: a literal value (an array of option ids for multi/dmulti), or a script expression (as { $nx: <script> }) evaluated at creation time","anyOf":[{"type":"object","properties":{"$nx":{"type":"string","description":"Script expression. Writing one needs records:write as well as schema:write"}},"required":["$nx"]},{"type":["boolean","null","number","string"]},{"type":"array","items":{"type":"string"}}]},"expression":{"description":"Expression (for function type)","type":"string"},"index":{"description":"Field is indexed","type":"boolean"},"labels":{"description":"Field labels (localized)","type":"object","additionalProperties":{"type":"string"}},"name":{"type":"string","description":"Field name"},"onUpdate":{"description":"Script expression run as a row trigger when the field value changes","type":"string"},"optionColor":{"description":"Color expression for dchoice/dmulti fields","type":"string"},"optionIcon":{"description":"Icon expression for dchoice/dmulti fields","type":"string"},"optionName":{"description":"Display name expression for dchoice/dmulti fields","type":"string"},"options":{"description":"Options array for choice/multi fields, or selection expression for dchoice/dmulti fields","anyOf":[{"type":"array","items":{"type":"object","properties":{"color":{"description":"Option color (hex string)","type":"string"},"icon":{"description":"Option icon name","type":"string"},"id":{"type":"string","description":"Option id, a string the caller can set and change"},"label":{"type":"string","description":"Option text in the default language"},"labels":{"description":"Option text per language","type":"object","additionalProperties":{"type":"string"}},"order":{"type":"number","description":"Option display order"},"textColor":{"description":"Option text color (hex string)","type":"string"}},"required":["id","label","order"]}},{"type":"string"}]},"readRoles":{"description":"Roles allowed to read the field","type":"array","items":{"type":"string"}},"refTableName":{"description":"Reference table name","type":"string"},"required":{"description":"Field is required","type":"boolean"},"search":{"description":"Field is searchable","type":"boolean"},"syncedFrom":{"description":"Source column this field syncs from. Read-only unless the table has two-way sync with updates enabled, in which case every synced field except the key column is writable.","type":"string"},"type":{"type":"string","enum":["any","appointment","boolean","choice","color","date","dchoice","dmulti","file","function","html","icon","lambda","multi","number","react","reference","reverse","rowId","string","styled","time","timeinterval","timestamp","unknown","user","void"],"description":"Field type"},"unique":{"description":"Field is unique","type":"boolean"},"variant":{"description":"Field variant (for string type)","type":"string"},"writeRoles":{"description":"Roles allowed to write to the field","type":"array","items":{"type":"string"}}},"required":["name","type"]},"description":"List of fields"}},"required":["data"]}}}}
```

## The DeleteFieldsBatchBody object

```json
{"openapi":"3.0.0","info":{"title":"Ninox Public API","version":"1.0.0"},"components":{"schemas":{"DeleteFieldsBatchBody":{"type":"object","properties":{"fieldNames":{"minItems":1,"type":"array","items":{"type":"string","minLength":1,"maxLength":100,"pattern":"^[a-z0-9_]+$","description":"Field name"}}},"required":["fieldNames"],"additionalProperties":false}}}}
```

## The FieldsListResponse object

```json
{"openapi":"3.0.0","info":{"title":"Ninox Public API","version":"1.0.0"},"components":{"schemas":{"FieldsListResponse":{"type":"object","properties":{"data":{"type":"array","items":{"type":"object","properties":{"binding":{"description":"Read-only: internal binding reference, format not yet specified","type":"string"},"canRead":{"description":"Script expression gating field-level read access","type":"string"},"canWrite":{"description":"Script expression gating field-level write access","type":"string"},"defaultValue":{"description":"Default value applied when a record is created: a literal value (an array of option ids for multi/dmulti), or a script expression (as { $nx: <script> }) evaluated at creation time","anyOf":[{"type":"object","properties":{"$nx":{"type":"string","description":"Script expression. Writing one needs records:write as well as schema:write"}},"required":["$nx"]},{"type":["boolean","null","number","string"]},{"type":"array","items":{"type":"string"}}]},"expression":{"description":"Expression (for function type)","type":"string"},"index":{"description":"Field is indexed","type":"boolean"},"labels":{"description":"Field labels (localized)","type":"object","additionalProperties":{"type":"string"}},"name":{"type":"string","description":"Field name"},"onUpdate":{"description":"Script expression run as a row trigger when the field value changes","type":"string"},"optionColor":{"description":"Color expression for dchoice/dmulti fields","type":"string"},"optionIcon":{"description":"Icon expression for dchoice/dmulti fields","type":"string"},"optionName":{"description":"Display name expression for dchoice/dmulti fields","type":"string"},"options":{"description":"Options array for choice/multi fields, or selection expression for dchoice/dmulti fields","anyOf":[{"type":"array","items":{"type":"object","properties":{"color":{"description":"Option color (hex string)","type":"string"},"icon":{"description":"Option icon name","type":"string"},"id":{"type":"string","description":"Option id, a string the caller can set and change"},"label":{"type":"string","description":"Option text in the default language"},"labels":{"description":"Option text per language","type":"object","additionalProperties":{"type":"string"}},"order":{"type":"number","description":"Option display order"},"textColor":{"description":"Option text color (hex string)","type":"string"}},"required":["id","label","order"]}},{"type":"string"}]},"readRoles":{"description":"Roles allowed to read the field","type":"array","items":{"type":"string"}},"refTableName":{"description":"Reference table name","type":"string"},"required":{"description":"Field is required","type":"boolean"},"search":{"description":"Field is searchable","type":"boolean"},"syncedFrom":{"description":"Source column this field syncs from. Read-only unless the table has two-way sync with updates enabled, in which case every synced field except the key column is writable.","type":"string"},"type":{"type":"string","enum":["any","appointment","boolean","choice","color","date","dchoice","dmulti","file","function","html","icon","lambda","multi","number","react","reference","reverse","rowId","string","styled","time","timeinterval","timestamp","unknown","user","void"],"description":"Field type"},"unique":{"description":"Field is unique","type":"boolean"},"variant":{"description":"Field variant (for string type)","type":"string"},"writeRoles":{"description":"Roles allowed to write to the field","type":"array","items":{"type":"string"}}},"required":["name","type"]},"description":"List of fields"},"page_info":{"type":"object","properties":{"has_more":{"type":"boolean","description":"Whether more results are available"},"limit":{"type":"number","description":"Maximum results per page"},"offset":{"type":"number","description":"Current offset"}},"description":"Pagination information"}},"required":["data","page_info"]}}}}
```

## The UpdateFieldsBatchBody object

```json
{"openapi":"3.0.0","info":{"title":"Ninox Public API","version":"1.0.0"},"components":{"schemas":{"UpdateFieldsBatchBody":{"minItems":1,"type":"array","items":{"type":"object","properties":{"canRead":{"type":"string","minLength":1,"description":"Script expression that must allow reading this field's value; null removes the guard","nullable":true},"canWrite":{"type":"string","minLength":1,"description":"Script expression that must allow writing this field's value; null removes the guard","nullable":true},"expression":{"description":"Expression (for function type)","type":"string"},"labels":{"description":"Field labels (localized)","type":"object","additionalProperties":{"type":"string","minLength":1,"maxLength":100}},"name":{"description":"Field name","type":"string","minLength":1,"maxLength":100,"pattern":"^[a-z0-9_]+$"},"optionColor":{"description":"Color expression (for dchoice/dmulti types)","type":"string"},"optionIcon":{"description":"Icon expression (for dchoice/dmulti types)","type":"string"},"optionName":{"description":"Display name expression (for dchoice/dmulti types)","type":"string"},"options":{"description":"Options array (for choice/multi types) or selection expression (for dchoice/dmulti types)","anyOf":[{"type":"array","items":{"type":"object","properties":{"color":{"description":"Option color (hex string)","type":"string"},"icon":{"description":"Option icon name","type":"string"},"id":{"description":"Option id (omit for new options; system assigns id)","type":"string"},"label":{"type":"string","minLength":1,"description":"Option text in the default language"},"labels":{"description":"Option text per language","type":"object","additionalProperties":{"type":"string"}},"order":{"description":"Option display order","type":"integer","minimum":0,"maximum":9007199254740991},"previousId":{"description":"Current id of an existing option to give the new id in `id`. Records holding the old id follow.","type":"string"},"textColor":{"description":"Option text color (hex string)","type":"string"}},"required":["label"],"additionalProperties":false}},{"type":"string"}]},"defaultValue":{"description":"Default value applied when a record is created: a literal value (an array of option ids for multi/dmulti), or a script expression (as { $nx: <script> }) evaluated at creation time","anyOf":[{"type":"object","properties":{"$nx":{"type":"string","description":"Script expression"}},"required":["$nx"]},{"type":"array","items":{"type":"string"}},{"type":"boolean"},{"type":"number"},{"type":"string"}],"nullable":true},"index":{"description":"Field is indexed","type":"boolean"},"onUpdate":{"description":"Script expression run as a row trigger when the field value changes","type":"string"},"readRoles":{"description":"Roles allowed to read the field (\"user\" is a deprecated alias for \"editor\")","minItems":1,"maxItems":3,"type":"array","items":{"type":"string","enum":["admin","editor","user"]}},"required":{"description":"Field is required","type":"boolean"},"search":{"description":"Field is searchable","type":"boolean"},"unique":{"description":"Field is unique","type":"boolean"},"writeRoles":{"description":"Roles allowed to write to the field (\"user\" is a deprecated alias for \"editor\")","minItems":1,"maxItems":3,"type":"array","items":{"type":"string","enum":["admin","editor","user"]}},"fieldName":{"type":"string","minLength":1,"maxLength":100,"pattern":"^[a-z0-9_]+$","description":"Name of the field to update"}},"required":["fieldName"],"additionalProperties":false}}}}}
```

## The UpdateFieldBody object

```json
{"openapi":"3.0.0","info":{"title":"Ninox Public API","version":"1.0.0"},"components":{"schemas":{"UpdateFieldBody":{"type":"object","properties":{"canRead":{"type":"string","minLength":1,"description":"Script expression that must allow reading this field's value; null removes the guard","nullable":true},"canWrite":{"type":"string","minLength":1,"description":"Script expression that must allow writing this field's value; null removes the guard","nullable":true},"expression":{"description":"Expression (for function type)","type":"string"},"labels":{"description":"Field labels (localized)","type":"object","additionalProperties":{"type":"string","minLength":1,"maxLength":100}},"name":{"description":"Field name","type":"string","minLength":1,"maxLength":100,"pattern":"^[a-z0-9_]+$"},"optionColor":{"description":"Color expression (for dchoice/dmulti types)","type":"string"},"optionIcon":{"description":"Icon expression (for dchoice/dmulti types)","type":"string"},"optionName":{"description":"Display name expression (for dchoice/dmulti types)","type":"string"},"options":{"description":"Options array (for choice/multi types) or selection expression (for dchoice/dmulti types)","anyOf":[{"type":"array","items":{"type":"object","properties":{"color":{"description":"Option color (hex string)","type":"string"},"icon":{"description":"Option icon name","type":"string"},"id":{"description":"Option id (omit for new options; system assigns id)","type":"string"},"label":{"type":"string","minLength":1,"description":"Option text in the default language"},"labels":{"description":"Option text per language","type":"object","additionalProperties":{"type":"string"}},"order":{"description":"Option display order","type":"integer","minimum":0,"maximum":9007199254740991},"previousId":{"description":"Current id of an existing option to give the new id in `id`. Records holding the old id follow.","type":"string"},"textColor":{"description":"Option text color (hex string)","type":"string"}},"required":["label"],"additionalProperties":false}},{"type":"string"}]},"defaultValue":{"description":"Default value applied when a record is created: a literal value (an array of option ids for multi/dmulti), or a script expression (as { $nx: <script> }) evaluated at creation time","anyOf":[{"type":"object","properties":{"$nx":{"type":"string","description":"Script expression"}},"required":["$nx"]},{"type":"array","items":{"type":"string"}},{"type":"boolean"},{"type":"number"},{"type":"string"}],"nullable":true},"index":{"description":"Field is indexed","type":"boolean"},"onUpdate":{"description":"Script expression run as a row trigger when the field value changes","type":"string"},"readRoles":{"description":"Roles allowed to read the field (\"user\" is a deprecated alias for \"editor\")","minItems":1,"maxItems":3,"type":"array","items":{"type":"string","enum":["admin","editor","user"]}},"required":{"description":"Field is required","type":"boolean"},"search":{"description":"Field is searchable","type":"boolean"},"unique":{"description":"Field is unique","type":"boolean"},"writeRoles":{"description":"Roles allowed to write to the field (\"user\" is a deprecated alias for \"editor\")","minItems":1,"maxItems":3,"type":"array","items":{"type":"string","enum":["admin","editor","user"]}}},"additionalProperties":false}}}}
```

## The CompleteFileUploadBody object

```json
{"openapi":"3.0.0","info":{"title":"Ninox Public API","version":"1.0.0"},"components":{"schemas":{"CompleteFileUploadBody":{"type":"object","properties":{"contentType":{"type":"string","minLength":1,"description":"MIME type of the uploaded file"},"documentId":{"description":"`documentId` returned by the generate-upload-url step","type":"string","minLength":12,"maxLength":12,"pattern":"^[a-z0-9]+$"},"documentVersionId":{"description":"`documentVersionId` returned by the generate-upload-url step","type":"string","minLength":12,"maxLength":12,"pattern":"^[a-z0-9]+$"},"etags":{"minItems":1,"type":"array","items":{"type":"string","minLength":1},"description":"ETag returned by S3 for each uploaded part, in order"},"fileName":{"type":"string","minLength":1,"description":"Original file name"},"fileSize":{"type":"integer","minimum":0,"maximum":9007199254740991,"description":"File size in bytes"},"uploadId":{"type":"string","minLength":1,"description":"`uploadId` returned by the generate-upload-url step"}},"required":["contentType","documentId","documentVersionId","etags","fileName","fileSize","uploadId"],"additionalProperties":false}}}}
```

## The CompleteFileUploadResponse object

```json
{"openapi":"3.0.0","info":{"title":"Ninox Public API","version":"1.0.0"},"components":{"schemas":{"CompleteFileUploadResponse":{"type":"object","properties":{"data":{"type":"object","properties":{"documentId":{"type":"string","description":"Document id — store this as part of the field value"},"documentVersionId":{"type":"string","description":"Document version id — store this as part of the field value"},"fileName":{"type":"string","description":"Original file name"},"fileSize":{"type":"number","description":"File size in bytes"},"fileType":{"type":"string","description":"MIME type"}},"description":"The complete file-type field value — pass this object as-is when creating/updating a record"}},"required":["data"]}}}}
```

## The GenerateFileUploadUrlBody object

```json
{"openapi":"3.0.0","info":{"title":"Ninox Public API","version":"1.0.0"},"components":{"schemas":{"GenerateFileUploadUrlBody":{"type":"object","properties":{"contentType":{"type":"string","minLength":1,"description":"MIME type of the file being uploaded"},"parts":{"type":"integer","minimum":1,"maximum":10000,"description":"Number of multipart upload parts (1 for a single-part upload, max 10,000 per S3 limits)"}},"required":["contentType","parts"],"additionalProperties":false}}}}
```

## The GenerateFileUploadUrlResponse object

```json
{"openapi":"3.0.0","info":{"title":"Ninox Public API","version":"1.0.0"},"components":{"schemas":{"GenerateFileUploadUrlResponse":{"type":"object","properties":{"data":{"type":"object","properties":{"documentId":{"type":"string","description":"Document id — pass back at the complete step"},"documentVersionId":{"type":"string","description":"Document version id — pass back at the complete step"},"preSignedUrls":{"type":"array","items":{"type":"string"},"description":"One presigned PUT URL per upload part, in order"},"uploadId":{"type":"string","description":"Multipart upload id — pass back at the complete step"}}}},"required":["data"]}}}}
```

## The UploadRecordFileResponse object

```json
{"openapi":"3.0.0","info":{"title":"Ninox Public API","version":"1.0.0"},"components":{"schemas":{"UploadRecordFileResponse":{"type":"object","properties":{"data":{"type":"object","properties":{"documentId":{"type":"string","description":"Document id — store this as part of the field value"},"documentVersionId":{"type":"string","description":"Document version id — store this as part of the field value"},"fileName":{"type":"string","description":"Original file name"},"fileSize":{"type":"number","description":"File size in bytes"},"fileType":{"type":"string","description":"MIME type"}},"description":"The file now attached to the record. The same object can also be stored in a file-type field"}},"required":["data"]}}}}
```

## The ApplyModuleDefinitionBody object

```json
{"openapi":"3.0.0","info":{"title":"Ninox Public API","version":"1.0.0"},"components":{"schemas":{"ApplyModuleDefinitionBody":{"type":"object","properties":{"capabilities":{"maxItems":20,"type":"array","items":{"type":"string"}},"checksum":{"type":"string"},"documentation":{"type":"object","additionalProperties":{"type":"string"}},"formatVersion":{"type":"number","enum":[1]},"gettingStartedComponentId":{"type":"string"},"objects":{"minItems":1,"maxItems":5000,"type":"array","items":{"type":"object","properties":{"id":{"type":"string","minLength":1,"maxLength":100},"kind":{"type":"string","minLength":1,"maxLength":50}},"required":["id","kind"],"additionalProperties":{}}},"requiredConnections":{"maxItems":100,"type":"array","items":{"type":"string"}},"roles":{"default":[],"maxItems":200,"type":"array","items":{"type":"object","properties":{"alias":{"type":"string","minLength":1,"maxLength":100},"name":{"type":"string","minLength":1,"maxLength":100}},"required":["alias","name"],"additionalProperties":{}}}},"required":["formatVersion","objects"],"additionalProperties":false}}}}
```

## The ApplyModuleDefinitionResponse object

```json
{"openapi":"3.0.0","info":{"title":"Ninox Public API","version":"1.0.0"},"components":{"schemas":{"ApplyModuleDefinitionResponse":{"type":"object","properties":{"data":{"type":"object","properties":{"created":{"type":"number","description":"Objects created"},"skipped":{"type":"object","additionalProperties":{"type":"number"},"description":"Objects left out on a module that was not empty, counted by kind (flows, data-model diagram)"},"updated":{"type":"number","description":"Existing objects that changed"}}}},"required":["data"]}}}}
```

## The ModuleDefinitionResponse object

```json
{"openapi":"3.0.0","info":{"title":"Ninox Public API","version":"1.0.0"},"components":{"schemas":{"ModuleDefinitionResponse":{"type":"object","properties":{"data":{"type":"object","properties":{"capabilities":{"type":"array","items":{"type":"string","enum":["ai","connections","cross-module-access","custom-widget","dynamic-html","email","http","scripts"]},"description":"Features the module uses"},"checksum":{"type":"string","description":"Hash of the definition as exported. Not checked on apply"},"formatVersion":{"type":"number","enum":[1]},"objects":{"type":"array","items":{"type":"object","properties":{"id":{"type":"string"},"kind":{"type":"string"}},"required":["id","kind"],"additionalProperties":{}},"description":"Every object of the module, with the module id replaced by a placeholder"},"requiredConnections":{"type":"array","items":{"type":"string"},"description":"Connection names the scripts expect"},"roles":{"type":"array","items":{"type":"object","properties":{"alias":{"type":"string"},"name":{"type":"string"}},"required":["alias","name"],"additionalProperties":{}},"description":"Custom roles the objects reference as @role:<name>"}},"additionalProperties":{}}},"required":["data"]}}}}
```

## The CreateModuleBody object

```json
{"openapi":"3.0.0","info":{"title":"Ninox Public API","version":"1.0.0"},"components":{"schemas":{"CreateModuleBody":{"type":"object","properties":{"afterOpen":{"description":"Script expression run in the browser each time the app is opened. Needs schema:write plus records:write","type":"string"},"name":{"type":"string","minLength":1,"maxLength":100,"pattern":"^[a-z0-9_]+$","description":"Module name"},"hideNavigation":{"description":"Hide module from navigation","type":"boolean"},"icon":{"description":"Module icon","type":"object","properties":{"color":{"type":"string"},"filling":{"anyOf":[{"type":"number","enum":[0]},{"type":"number","enum":[1]}]},"icon":{"type":"string","minLength":1}}},"isHidden":{"description":"Hide module","type":"boolean"},"labels":{"description":"Module labels (localized)","type":"object","additionalProperties":{"type":"string","minLength":1,"maxLength":100}},"openRoles":{"description":"Module open roles","minItems":1,"maxItems":2,"type":"array","items":{"type":"string","enum":["admin","editor"]}}},"required":["name"],"description":"Create Module request body"}}}}
```

## The ModuleResponse object

```json
{"openapi":"3.0.0","info":{"title":"Ninox Public API","version":"1.0.0"},"components":{"schemas":{"ModuleResponse":{"type":"object","properties":{"data":{"type":"object","properties":{"afterOpen":{"description":"Script expression run in the browser each time the app is opened","type":"string"},"components":{"description":"Module components (pages, containers, widgets)","type":"array","items":{"type":"object","properties":{"afterHide":{"description":"Container directly under Tabs: script run when this tab stops being shown","type":"string"},"aggregation":{"description":"MetricCard: aggregation function","type":"string","enum":["avg","count","max","median","min","sum"]},"annualRecurring":{"description":"Calendar: render every record on the same day/month every year","type":"boolean"},"arrangement":{"description":"Page/Container: layout direction","type":"string","enum":["grid","ltr","row","ttb"]},"background":{"description":"Container/Page/Text: background","anyOf":[{"type":"string"},{"type":"object","properties":{"$nx":{"type":"string","description":"Script expression. Writing one needs records:write as well as schema:write"}},"required":["$nx"]}]},"beforeShow":{"description":"Container directly under Tabs: script run when this tab is shown","type":"string"},"border":{"description":"Container: border","anyOf":[{"type":"object","properties":{"color":{"type":"string"},"style":{"type":"string","enum":["dashed","dotted","double","none","solid"]},"width":{"type":"string"}},"required":["style","width"]},{"type":"object","properties":{"$nx":{"type":"string","description":"Script expression. Writing one needs records:write as well as schema:write"}},"required":["$nx"]}]},"calendarType":{"description":"Calendar: display type","type":"string"},"cardBorder":{"description":"Kanban: card border CSS shorthand, Normal mode only","type":"string"},"cardFont":{"description":"Kanban: card font style tokens, Normal mode only","type":"string"},"cardPadding":{"description":"Kanban: card padding in px, Normal mode only","type":"number"},"cardRadius":{"description":"Kanban: card corner radius in px, Normal mode only","type":"number"},"chartConfig":{"description":"Chart: chart type, axes and data series","type":"object","properties":{"chartType":{"type":"string","enum":["bar","line","pie","funnel","ranking","board"]},"dataSets":{"type":"array","items":{"type":"object","properties":{"aggregation":{"type":"string","enum":["average","count","max","median","min","none","sum"]},"color":{"description":"Series color (hex string)","type":"string"},"fieldName":{"description":"Field name this series reads from","type":"string"},"labels":{"description":"Series labels (localized)","type":"object","additionalProperties":{"type":"string"}}}}},"donut":{"type":"boolean"},"labelPosition":{"type":"string","enum":["bottom","center","inside","outside","top"]},"legend":{"type":"object","properties":{"show":{"type":"boolean"}}},"limit":{"description":"ranking only: how many categories it shows","type":"integer","minimum":1,"maximum":20},"orientation":{"type":"string","enum":["horizontal","vertical"]},"showDataTable":{"type":"boolean"},"showLabels":{"type":"boolean"},"showPoints":{"type":"boolean"},"showTitle":{"type":"boolean"},"smooth":{"type":"boolean"},"stacked":{"type":"boolean"},"style":{"type":"string","enum":["default","half_donut","pad_angle","rounded_corner"]},"tooltips":{"type":"object","properties":{"show":{"type":"boolean"}}},"xAxis":{"type":"object","properties":{"fieldName":{"description":"X-axis field name, null removes it","type":["string","null"]},"groupBy":{"type":"string","enum":["daily","monthly","none","quarterly","weekly","yearly"]},"show":{"type":"boolean"}}},"yAxis":{"type":"object","properties":{"show":{"type":"boolean"}}}},"required":["chartType","dataSets","xAxis"]},"color":{"description":"Text: text color (hex string). Button: theme color name","anyOf":[{"type":"string"},{"type":"object","properties":{"$nx":{"type":"string","description":"Script expression. Writing one needs records:write as well as schema:write"}},"required":["$nx"]}]},"colorFieldName":{"description":"Map: marker color field name","type":"string"},"constraints":{"description":"FieldComponent: script limiting which records a reference can link to, needs schema:manage-permissions","type":"string"},"content":{"description":"Text: content, localized or a script expression","anyOf":[{"type":"object","additionalProperties":{"type":"string"}},{"type":"object","properties":{"$nx":{"type":"string","description":"Script expression. Writing one needs records:write as well as schema:write"}},"required":["$nx"]}]},"customStyle":{"description":"Text: full custom style config, opaque, used only when quickStyle is \"custom\"","type":"object","additionalProperties":{}},"dataPoint":{"description":"'conditional' replaces table/filter/… with the `value` script","type":"string","enum":["conditional","normal"]},"defaultValue":{"description":"InputComponent: initial value, or { $nx: <script> }","anyOf":[{"type":"boolean"},{"type":"number"},{"type":"string"},{"type":"object","properties":{"$nx":{"type":"string","description":"Script expression. Writing one needs records:write as well as schema:write"}},"required":["$nx"]}]},"disabled":{"description":"Button/FieldComponent: disable the control, a boolean or a script","anyOf":[{"type":"boolean"},{"type":"object","properties":{"$nx":{"type":"string","description":"Script expression. Writing one needs records:write as well as schema:write"}},"required":["$nx"]}]},"display":{"description":"MetricCard: display formatting and trend configuration","type":"object","properties":{"color":{"type":"string"},"format":{"type":"string","enum":["compact","currency","number","percentage"]},"icon":{"type":"string"},"trend":{"type":"object","properties":{"customPeriodEnd":{"description":"ISO date (YYYY-MM-DD), for period \"custom\"","type":"string"},"customPeriodStart":{"description":"ISO date (YYYY-MM-DD), for period \"custom\"","type":"string"},"format":{"type":"string","enum":["absolute","percentage"]},"isShown":{"type":"boolean"},"period":{"type":"string","enum":["custom","last_month","last_week","last_year","previous_period","yesterday"]},"positiveDirection":{"type":"string","enum":["down","up"]}},"required":["format","isShown"]}},"required":["color","format","trend"]},"displayAs":{"description":"FieldComponent: how a yes/no field is shown","type":"string"},"expression":{"description":"DynamicHTMLComponent: script returning the HTML to render","type":"string"},"fieldIdDataPoint":{"description":"MetricCard: 'conditional' replaces table/filter/fieldName/aggregation with fieldIdValue","type":"string","enum":["conditional","normal"]},"fieldIdValue":{"description":"MetricCard: whole-dataset script producing the final number when fieldIdDataPoint is conditional","type":"string"},"fieldName":{"description":"MetricCard/Calendar/Map: primary bound field name","type":"string"},"filter":{"description":"MetricCard/Chart: stored filter conditions","type":"array","items":{"type":"object","properties":{"field":{"description":"Field name","type":"string"},"id":{"type":"string","description":"Stable condition id"},"operator":{"description":"Filter operator","type":"string"},"value":{"description":"Value compared against","type":"string"}},"required":["id"]}},"flex":{"description":"Container: flex sizing","anyOf":[{"type":"string"},{"type":"object","properties":{"$nx":{"type":"string","description":"Script expression. Writing one needs records:write as well as schema:write"}},"required":["$nx"]}]},"ganttConfig":{"description":"Gantt: which fields the bars/milestones/dependencies read from","type":"object","properties":{"baselineEndFieldName":{"description":"Planned end field, rendered as a ghost bar","type":["string","null"]},"baselineStartFieldName":{"description":"Planned start field, rendered as a ghost bar","type":["string","null"]},"dependencyDirection":{"type":"string","enum":["predecessor","successor"]},"dependencyFieldName":{"description":"A reference field pointing back at this table","type":["string","null"]},"disableDragAndDrop":{"type":"boolean"},"endFieldName":{"type":["string","null"]},"hideTitleColumn":{"type":"boolean"},"hideWeekends":{"type":"boolean"},"milestoneFieldName":{"type":["string","null"]},"progressFieldName":{"type":["string","null"]},"showCriticalPath":{"type":"boolean"},"showWeekends":{"type":"boolean"},"startFieldName":{"type":["string","null"]},"timeScale":{"type":"string","enum":["day","month","quarter","week"]},"titleColumnFieldName":{"type":["string","null"]},"titleColumnWidth":{"type":"number"}}},"gap":{"description":"Page/Container: gap between children","anyOf":[{"type":"string"},{"type":"object","properties":{"$nx":{"type":"string","description":"Script expression. Writing one needs records:write as well as schema:write"}},"required":["$nx"]}]},"globalFilterBinding":{"description":"MetricCard: field names this card reacts to for global page filters","type":"array","items":{"type":"string"}},"gridPreset":{"description":"Container: grid layout preset","anyOf":[{"type":"string"},{"type":"object","properties":{"$nx":{"type":"string","description":"Script expression. Writing one needs records:write as well as schema:write"}},"required":["$nx"]}]},"groupByFieldName":{"description":"Kanban: lane grouping field name","type":"string"},"height":{"description":"Component height","type":"number"},"icon":{"description":"Page: icon","type":"object","properties":{"color":{"description":"Icon color (hex string)","type":"string"},"filling":{"description":"Icon filling","anyOf":[{"type":"number","enum":[0]},{"type":"number","enum":[1]}]},"icon":{"type":"string","description":"Icon name"}},"required":["icon"]},"iconLeft":{"description":"Button/FieldComponent: icon before the label","anyOf":[{"type":"object","properties":{"color":{"description":"Icon color (hex string)","type":"string"},"filling":{"description":"Icon filling","anyOf":[{"type":"number","enum":[0]},{"type":"number","enum":[1]}]},"icon":{"type":"string","description":"Icon name"}},"required":["icon"]},{"type":"object","properties":{"$nx":{"type":"string","description":"Script expression. Writing one needs records:write as well as schema:write"}},"required":["$nx"]}]},"iconRight":{"description":"Button/FieldComponent: icon after the label","anyOf":[{"type":"object","properties":{"color":{"description":"Icon color (hex string)","type":"string"},"filling":{"description":"Icon filling","anyOf":[{"type":"number","enum":[0]},{"type":"number","enum":[1]}]},"icon":{"type":"string","description":"Icon name"}},"required":["icon"]},{"type":"object","properties":{"$nx":{"type":"string","description":"Script expression. Writing one needs records:write as well as schema:write"}},"required":["$nx"]}]},"id":{"type":"string","description":"Component id"},"imagePosition":{"description":"Kanban: card image crop/anchor, Normal mode only","type":"object","properties":{"position":{"type":"string"},"size":{"type":"string"}}},"isCompact":{"description":"Accordion: compact sections","type":"boolean"},"isHidden":{"description":"Page: hide from navigation","type":"boolean"},"isMarkdownEnabled":{"description":"FieldComponent: render a rich text field as markdown","type":"boolean"},"isSpreadsheetMode":{"description":"Table/FieldComponent: spreadsheet-style editing","type":"boolean"},"kind":{"type":"string","deprecated":true,"description":"Deprecated, use type. Same value, kept so existing integrations keep working"},"labelPosition":{"description":"FieldComponent: top, left, inside or hidden","type":"string"},"labels":{"description":"Component labels (localized)","type":"object","additionalProperties":{"type":"string"}},"mapTypeId":{"description":"Map: base layer type","type":"string"},"margin":{"description":"Container: margin","anyOf":[{"type":"string"},{"type":"object","properties":{"$nx":{"type":"string","description":"Script expression. Writing one needs records:write as well as schema:write"}},"required":["$nx"]}]},"name":{"description":"Component name","type":"string"},"onChange":{"description":"Tabs/FieldComponent: script run when the value changes","type":"string"},"onClick":{"description":"Button: script run on click","type":"string"},"order":{"description":"Component display order","type":"number"},"overflow":{"description":"Container: overflow behavior","anyOf":[{"type":"string"},{"type":"object","properties":{"$nx":{"type":"string","description":"Script expression. Writing one needs records:write as well as schema:write"}},"required":["$nx"]}]},"padding":{"description":"Page/Container: padding","anyOf":[{"type":"string"},{"type":"object","properties":{"$nx":{"type":"string","description":"Script expression. Writing one needs records:write as well as schema:write"}},"required":["$nx"]}]},"parentId":{"description":"Parent component id (forms the component tree)","type":"string"},"placeholder":{"description":"FieldComponent: placeholder, localized, plain or a script","anyOf":[{"type":"object","additionalProperties":{"type":"string"}},{"type":"string"},{"type":"object","properties":{"$nx":{"type":"string","description":"Script expression. Writing one needs records:write as well as schema:write"}},"required":["$nx"]}]},"quickStyle":{"description":"Text: style preset","anyOf":[{"type":"string","enum":["body-md","body-sm","custom","title-lg","title-md","title-sm"]},{"type":"object","properties":{"$nx":{"type":"string","description":"Script expression. Writing one needs records:write as well as schema:write"}},"required":["$nx"]}]},"radius":{"description":"Container/Text: corner radius","anyOf":[{"type":"string"},{"type":"object","properties":{"$nx":{"type":"string","description":"Script expression. Writing one needs records:write as well as schema:write"}},"required":["$nx"]}]},"remember":{"description":"InputComponent: how long the value is kept","type":"string","enum":["localStorage","memory","url"]},"shadow":{"description":"Container: shadow","anyOf":[{"type":"string"},{"type":"object","properties":{"$nx":{"type":"string","description":"Script expression. Writing one needs records:write as well as schema:write"}},"required":["$nx"]}]},"shadowDom":{"description":"DynamicHTMLComponent: render inside a shadow DOM","type":"boolean"},"showAs":{"description":"FieldComponent: how the value is shown (e.g. popup, combobox)","type":"string"},"showBulkActions":{"description":"Table/FieldComponent: show bulk actions","type":"boolean"},"showCalendarType":{"description":"Calendar: show the calendar type switcher","type":"boolean"},"showCreateButton":{"description":"Table: show the create-record button","type":"boolean"},"showCreateRow":{"description":"Table: show the inline create row","type":"boolean"},"showDataAs":{"description":"FieldComponent: script formatting a linked record","type":"string"},"showEmptyLane":{"description":"Kanban: show lanes with no cards","type":"boolean"},"showLinkExistingRecord":{"description":"FieldComponent: offer linking an existing record","type":"boolean"},"showMetadata":{"description":"FieldComponent: show file metadata","type":"boolean"},"showOutlines":{"description":"Page: show layout outlines in the editor","type":"boolean"},"showSearchField":{"description":"Table/Kanban/Gantt/Calendar/Map: show the search field","type":"boolean"},"showTimeScaleSelector":{"description":"Gantt: let the viewer switch time scale","type":"boolean"},"showTitle":{"description":"Table: show the table title","type":"boolean"},"size":{"description":"Button: sm, md or lg","anyOf":[{"type":"string"},{"type":"object","properties":{"$nx":{"type":"string","description":"Script expression. Writing one needs records:write as well as schema:write"}},"required":["$nx"]}]},"tableName":{"description":"Table this component reads from (Chart/Table/Kanban/Gantt/Calendar/Map/MetricCard)","type":"string"},"textAlign":{"description":"Text: alignment","type":"string","enum":["text-center","text-left","text-right"]},"titleFieldName":{"description":"Map: marker title field name","type":"string"},"tooltip":{"description":"FieldComponent: tooltip text","type":"string"},"type":{"type":"string","description":"Component type (e.g. Container, Button, Text, Page), the property the create and update routes and the module definition take"},"value":{"description":"Script used instead of table/filter/… when dataPoint is conditional","type":"string"},"valueSpec":{"description":"InputComponent: the type of the value, shaped like a field type, a reference has refTableName","type":"object","properties":{"type":{"type":"string"}},"required":["type"],"additionalProperties":{}},"valueType":{"description":"InputComponent: legacy value type, valueSpec wins where both are set","type":"string"},"variant":{"description":"Button/Accordion/Tabs: visual variant, InputComponent: text, email, phone, url, ...","anyOf":[{"type":"string"},{"type":"object","properties":{"$nx":{"type":"string","description":"Script expression. Writing one needs records:write as well as schema:write"}},"required":["$nx"]}]},"view":{"description":"Table/MetricCard/Kanban/Gantt/Calendar/Map: columns/filter/groupBy/sort configuration","type":"object","properties":{"columns":{"description":"View columns","type":"array","items":{"type":"object","properties":{"agg":{"description":"Aggregation function applied to the column","type":"string"},"conditionalStyling":{"description":"Legacy per-column conditional styling rules","type":"array","items":{"type":"object","properties":{"background":{"description":"Background color (hex string)","type":"string"},"cell":{"description":"Target cell","type":"string"},"color":{"description":"Icon color (hex string)","type":"string"},"icon":{"description":"Icon name","type":"string"},"operand":{"type":"string","description":"Comparator"},"value":{"type":"string","description":"Value compared against"}},"required":["operand","value"]}},"field":{"type":"string","description":"Field name, or a script expression for a calculated column"},"hidden":{"description":"Column retained but hidden from the grid","type":"boolean"},"id":{"description":"Stable identity of a calculated column; send it back unchanged when updating the view","type":"string"},"labels":{"description":"Column labels (localized)","type":"object","additionalProperties":{"type":"string"}},"order":{"type":"number","description":"Column display order"},"role":{"description":"Column role (e.g. title, date, image, location, color)","type":"string"},"width":{"description":"Column width","type":"number"}},"required":["field","order"]}},"conditionalFormatting":{"description":"Conditional formatting rules","type":"array","items":{"type":"object","properties":{"backgroundColor":{"description":"Background color (hex string)","type":"string"},"bold":{"description":"Bold text","type":"boolean"},"comparator":{"type":"string","enum":["contains","does_not_contain","ends_with","gt","gte","is","is_empty","is_not","is_not_empty","logic","lt","lte","starts_with"],"description":"Comparator"},"expression":{"description":"Script expression, used only when comparator is 'logic'","type":"string"},"fieldName":{"type":"string","description":"Target field name"},"highlightColor":{"description":"Highlight color (hex string)","type":"string"},"icon":{"description":"Icon","type":"object","properties":{"color":{"description":"Icon color (hex string)","type":"string"},"filling":{"description":"Icon filling","anyOf":[{"type":"number","enum":[0]},{"type":"number","enum":[1]}]},"icon":{"type":"string","description":"Icon name"}},"required":["icon"]},"id":{"type":"string","description":"Stable rule id"},"italic":{"description":"Italic text","type":"boolean"},"order":{"type":"number","description":"Rule evaluation order"},"strikethrough":{"description":"Strikethrough text","type":"boolean"},"target":{"type":"string","enum":["cell","row"],"description":"Whether the rule styles a single cell or the whole row"},"textColor":{"description":"Text color (hex string)","type":"string"},"value":{"description":"Value compared against"}},"required":["comparator","fieldName","id","order","target"]}},"filter":{"description":"Stored filter conditions","type":"array","items":{"type":"object","properties":{"field":{"description":"Field name","type":"string"},"id":{"type":"string","description":"Stable condition id"},"operator":{"description":"Filter operator","type":"string"},"value":{"description":"Value compared against","type":"string"}},"required":["id"]}},"groupBy":{"description":"Grouping configuration","type":"array","items":{"type":"object","properties":{"direction":{"description":"Group order direction, defaults to ascending","type":"string","enum":["asc","desc"]},"fieldName":{"type":"string","description":"Field name"}},"required":["fieldName"]}},"sort":{"description":"Sort configuration","type":"object","properties":{"direction":{"type":"string","enum":["asc","desc"],"description":"Sort direction"},"fieldName":{"type":"string","description":"Field name"}},"required":["direction","fieldName"]}}},"visible":{"description":"Conditional visibility logic: a boolean, or a script expression (as { $nx: <script> }) evaluated at render time","anyOf":[{"type":"boolean"},{"type":"object","properties":{"$nx":{"type":"string","description":"Script expression. Writing one needs records:write as well as schema:write"}},"required":["$nx"]}]},"visibleRoles":{"description":"Page: roles allowed to view this page","type":"array","items":{"type":"string"}},"widgetName":{"description":"CustomWidget: folder name under the workspace widgets directory","type":"string"},"widgetProps":{"description":"CustomWidget: property values, each static or a script expression (as { $nx: <script> })","type":"object","additionalProperties":{"anyOf":[{"type":"boolean"},{"type":"number"},{"type":"string"},{"type":"object","properties":{"$nx":{"type":"string","description":"Script expression. Writing one needs records:write as well as schema:write"}},"required":["$nx"]}]}},"width":{"description":"Component width: number = legacy px, string = percentage e.g. \"50%\"","type":["number","string"]}},"required":["id","kind","type"]}},"hideNavigation":{"description":"Hide module from navigation","type":"boolean"},"icon":{"description":"Module icon","type":"object","properties":{"color":{"description":"Icon color (hex string)","type":"string"},"filling":{"description":"Icon filling","anyOf":[{"type":"number","enum":[0]},{"type":"number","enum":[1]}]},"icon":{"type":"string","description":"Icon name"}},"required":["icon"]},"isHidden":{"description":"Hide module","type":"boolean"},"labels":{"description":"Module labels (localized)","type":"object","additionalProperties":{"type":"string"}},"name":{"type":"string"},"openRoles":{"description":"Module open roles","type":"array","items":{"type":"string"}},"tables":{"type":"array","items":{"type":"object","properties":{"canCreate":{"description":"Script expression gating record creation","type":"string"},"canDelete":{"description":"Script expression gating record deletion","type":"string"},"canRead":{"description":"Script expression gating record read access","type":"string"},"canWrite":{"description":"Script expression gating record write access","type":"string"},"createRoles":{"description":"Roles allowed to create records","type":"array","items":{"type":"string"}},"deleteRoles":{"description":"Roles allowed to delete records","type":"array","items":{"type":"string"}},"fields":{"type":"array","items":{"type":"object","properties":{"binding":{"description":"Read-only: internal binding reference, format not yet specified","type":"string"},"canRead":{"description":"Script expression gating field-level read access","type":"string"},"canWrite":{"description":"Script expression gating field-level write access","type":"string"},"defaultValue":{"description":"Default value applied when a record is created: a literal value (an array of option ids for multi/dmulti), or a script expression (as { $nx: <script> }) evaluated at creation time","anyOf":[{"type":"object","properties":{"$nx":{"type":"string","description":"Script expression. Writing one needs records:write as well as schema:write"}},"required":["$nx"]},{"type":["boolean","null","number","string"]},{"type":"array","items":{"type":"string"}}]},"expression":{"description":"Expression (for function type)","type":"string"},"index":{"description":"Field is indexed","type":"boolean"},"labels":{"description":"Field labels (localized)","type":"object","additionalProperties":{"type":"string"}},"name":{"type":"string","description":"Field name"},"onUpdate":{"description":"Script expression run as a row trigger when the field value changes","type":"string"},"optionColor":{"description":"Color expression for dchoice/dmulti fields","type":"string"},"optionIcon":{"description":"Icon expression for dchoice/dmulti fields","type":"string"},"optionName":{"description":"Display name expression for dchoice/dmulti fields","type":"string"},"options":{"description":"Options array for choice/multi fields, or selection expression for dchoice/dmulti fields","anyOf":[{"type":"array","items":{"type":"object","properties":{"color":{"description":"Option color (hex string)","type":"string"},"icon":{"description":"Option icon name","type":"string"},"id":{"type":"string","description":"Option id, a string the caller can set and change"},"label":{"type":"string","description":"Option text in the default language"},"labels":{"description":"Option text per language","type":"object","additionalProperties":{"type":"string"}},"order":{"type":"number","description":"Option display order"},"textColor":{"description":"Option text color (hex string)","type":"string"}},"required":["id","label","order"]}},{"type":"string"}]},"readRoles":{"description":"Roles allowed to read the field","type":"array","items":{"type":"string"}},"refTableName":{"description":"Reference table name","type":"string"},"required":{"description":"Field is required","type":"boolean"},"search":{"description":"Field is searchable","type":"boolean"},"syncedFrom":{"description":"Source column this field syncs from. Read-only unless the table has two-way sync with updates enabled, in which case every synced field except the key column is writable.","type":"string"},"type":{"type":"string","enum":["any","appointment","boolean","choice","color","date","dchoice","dmulti","file","function","html","icon","lambda","multi","number","react","reference","reverse","rowId","string","styled","time","timeinterval","timestamp","unknown","user","void"],"description":"Field type"},"unique":{"description":"Field is unique","type":"boolean"},"variant":{"description":"Field variant (for string type)","type":"string"},"writeRoles":{"description":"Roles allowed to write to the field","type":"array","items":{"type":"string"}}},"required":["name","type"]}},"hasFiles":{"description":"Enable files for the table","type":"boolean"},"hasGlobalSearch":{"description":"Enable global search for the table","type":"boolean"},"hasHistory":{"description":"Enable history for the table","type":"boolean"},"icon":{"description":"Table icon","type":"object","properties":{"color":{"description":"Icon color (hex string)","type":"string"},"filling":{"description":"Icon filling","anyOf":[{"type":"number","enum":[0]},{"type":"number","enum":[1]}]},"icon":{"type":"string","description":"Icon name"}},"required":["icon"]},"isEmailLinkingEnabled":{"description":"Enable email linking for the table","type":"boolean"},"isHidden":{"description":"Hide the table","type":"boolean"},"labels":{"description":"Table labels (localized)","type":"object","additionalProperties":{"type":"string"}},"name":{"type":"string"},"onCreate":{"description":"Script expression run as a trigger after a record is created","type":"string"},"onDelete":{"description":"Script expression run as a trigger when a record is deleted","type":"string"},"onUpdate":{"description":"Script expression run as a trigger after a record is updated","type":"string"},"readRoles":{"description":"Roles allowed to read records","type":"array","items":{"type":"string"}},"writeRoles":{"description":"Roles allowed to update records","type":"array","items":{"type":"string"}}},"required":["name"]}}},"description":"Module details"}},"required":["data"]}}}}
```

## The DeleteModuleResponse object

```json
{"openapi":"3.0.0","info":{"title":"Ninox Public API","version":"1.0.0"},"components":{"schemas":{"DeleteModuleResponse":{"type":"object","properties":{"data":{"type":"object","properties":{"id":{"type":"string","description":"Deleted module id"}}}},"required":["data"]}}}}
```

## The ModulesResponse object

```json
{"openapi":"3.0.0","info":{"title":"Ninox Public API","version":"1.0.0"},"components":{"schemas":{"ModulesResponse":{"type":"object","properties":{"data":{"type":"array","items":{"type":"object","properties":{"afterOpen":{"description":"Script expression run in the browser each time the app is opened","type":"string"},"components":{"description":"Module components (pages, containers, widgets)","type":"array","items":{"type":"object","properties":{"afterHide":{"description":"Container directly under Tabs: script run when this tab stops being shown","type":"string"},"aggregation":{"description":"MetricCard: aggregation function","type":"string","enum":["avg","count","max","median","min","sum"]},"annualRecurring":{"description":"Calendar: render every record on the same day/month every year","type":"boolean"},"arrangement":{"description":"Page/Container: layout direction","type":"string","enum":["grid","ltr","row","ttb"]},"background":{"description":"Container/Page/Text: background","anyOf":[{"type":"string"},{"type":"object","properties":{"$nx":{"type":"string","description":"Script expression. Writing one needs records:write as well as schema:write"}},"required":["$nx"]}]},"beforeShow":{"description":"Container directly under Tabs: script run when this tab is shown","type":"string"},"border":{"description":"Container: border","anyOf":[{"type":"object","properties":{"color":{"type":"string"},"style":{"type":"string","enum":["dashed","dotted","double","none","solid"]},"width":{"type":"string"}},"required":["style","width"]},{"type":"object","properties":{"$nx":{"type":"string","description":"Script expression. Writing one needs records:write as well as schema:write"}},"required":["$nx"]}]},"calendarType":{"description":"Calendar: display type","type":"string"},"cardBorder":{"description":"Kanban: card border CSS shorthand, Normal mode only","type":"string"},"cardFont":{"description":"Kanban: card font style tokens, Normal mode only","type":"string"},"cardPadding":{"description":"Kanban: card padding in px, Normal mode only","type":"number"},"cardRadius":{"description":"Kanban: card corner radius in px, Normal mode only","type":"number"},"chartConfig":{"description":"Chart: chart type, axes and data series","type":"object","properties":{"chartType":{"type":"string","enum":["bar","line","pie","funnel","ranking","board"]},"dataSets":{"type":"array","items":{"type":"object","properties":{"aggregation":{"type":"string","enum":["average","count","max","median","min","none","sum"]},"color":{"description":"Series color (hex string)","type":"string"},"fieldName":{"description":"Field name this series reads from","type":"string"},"labels":{"description":"Series labels (localized)","type":"object","additionalProperties":{"type":"string"}}}}},"donut":{"type":"boolean"},"labelPosition":{"type":"string","enum":["bottom","center","inside","outside","top"]},"legend":{"type":"object","properties":{"show":{"type":"boolean"}}},"limit":{"description":"ranking only: how many categories it shows","type":"integer","minimum":1,"maximum":20},"orientation":{"type":"string","enum":["horizontal","vertical"]},"showDataTable":{"type":"boolean"},"showLabels":{"type":"boolean"},"showPoints":{"type":"boolean"},"showTitle":{"type":"boolean"},"smooth":{"type":"boolean"},"stacked":{"type":"boolean"},"style":{"type":"string","enum":["default","half_donut","pad_angle","rounded_corner"]},"tooltips":{"type":"object","properties":{"show":{"type":"boolean"}}},"xAxis":{"type":"object","properties":{"fieldName":{"description":"X-axis field name, null removes it","type":["string","null"]},"groupBy":{"type":"string","enum":["daily","monthly","none","quarterly","weekly","yearly"]},"show":{"type":"boolean"}}},"yAxis":{"type":"object","properties":{"show":{"type":"boolean"}}}},"required":["chartType","dataSets","xAxis"]},"color":{"description":"Text: text color (hex string). Button: theme color name","anyOf":[{"type":"string"},{"type":"object","properties":{"$nx":{"type":"string","description":"Script expression. Writing one needs records:write as well as schema:write"}},"required":["$nx"]}]},"colorFieldName":{"description":"Map: marker color field name","type":"string"},"constraints":{"description":"FieldComponent: script limiting which records a reference can link to, needs schema:manage-permissions","type":"string"},"content":{"description":"Text: content, localized or a script expression","anyOf":[{"type":"object","additionalProperties":{"type":"string"}},{"type":"object","properties":{"$nx":{"type":"string","description":"Script expression. Writing one needs records:write as well as schema:write"}},"required":["$nx"]}]},"customStyle":{"description":"Text: full custom style config, opaque, used only when quickStyle is \"custom\"","type":"object","additionalProperties":{}},"dataPoint":{"description":"'conditional' replaces table/filter/… with the `value` script","type":"string","enum":["conditional","normal"]},"defaultValue":{"description":"InputComponent: initial value, or { $nx: <script> }","anyOf":[{"type":"boolean"},{"type":"number"},{"type":"string"},{"type":"object","properties":{"$nx":{"type":"string","description":"Script expression. Writing one needs records:write as well as schema:write"}},"required":["$nx"]}]},"disabled":{"description":"Button/FieldComponent: disable the control, a boolean or a script","anyOf":[{"type":"boolean"},{"type":"object","properties":{"$nx":{"type":"string","description":"Script expression. Writing one needs records:write as well as schema:write"}},"required":["$nx"]}]},"display":{"description":"MetricCard: display formatting and trend configuration","type":"object","properties":{"color":{"type":"string"},"format":{"type":"string","enum":["compact","currency","number","percentage"]},"icon":{"type":"string"},"trend":{"type":"object","properties":{"customPeriodEnd":{"description":"ISO date (YYYY-MM-DD), for period \"custom\"","type":"string"},"customPeriodStart":{"description":"ISO date (YYYY-MM-DD), for period \"custom\"","type":"string"},"format":{"type":"string","enum":["absolute","percentage"]},"isShown":{"type":"boolean"},"period":{"type":"string","enum":["custom","last_month","last_week","last_year","previous_period","yesterday"]},"positiveDirection":{"type":"string","enum":["down","up"]}},"required":["format","isShown"]}},"required":["color","format","trend"]},"displayAs":{"description":"FieldComponent: how a yes/no field is shown","type":"string"},"expression":{"description":"DynamicHTMLComponent: script returning the HTML to render","type":"string"},"fieldIdDataPoint":{"description":"MetricCard: 'conditional' replaces table/filter/fieldName/aggregation with fieldIdValue","type":"string","enum":["conditional","normal"]},"fieldIdValue":{"description":"MetricCard: whole-dataset script producing the final number when fieldIdDataPoint is conditional","type":"string"},"fieldName":{"description":"MetricCard/Calendar/Map: primary bound field name","type":"string"},"filter":{"description":"MetricCard/Chart: stored filter conditions","type":"array","items":{"type":"object","properties":{"field":{"description":"Field name","type":"string"},"id":{"type":"string","description":"Stable condition id"},"operator":{"description":"Filter operator","type":"string"},"value":{"description":"Value compared against","type":"string"}},"required":["id"]}},"flex":{"description":"Container: flex sizing","anyOf":[{"type":"string"},{"type":"object","properties":{"$nx":{"type":"string","description":"Script expression. Writing one needs records:write as well as schema:write"}},"required":["$nx"]}]},"ganttConfig":{"description":"Gantt: which fields the bars/milestones/dependencies read from","type":"object","properties":{"baselineEndFieldName":{"description":"Planned end field, rendered as a ghost bar","type":["string","null"]},"baselineStartFieldName":{"description":"Planned start field, rendered as a ghost bar","type":["string","null"]},"dependencyDirection":{"type":"string","enum":["predecessor","successor"]},"dependencyFieldName":{"description":"A reference field pointing back at this table","type":["string","null"]},"disableDragAndDrop":{"type":"boolean"},"endFieldName":{"type":["string","null"]},"hideTitleColumn":{"type":"boolean"},"hideWeekends":{"type":"boolean"},"milestoneFieldName":{"type":["string","null"]},"progressFieldName":{"type":["string","null"]},"showCriticalPath":{"type":"boolean"},"showWeekends":{"type":"boolean"},"startFieldName":{"type":["string","null"]},"timeScale":{"type":"string","enum":["day","month","quarter","week"]},"titleColumnFieldName":{"type":["string","null"]},"titleColumnWidth":{"type":"number"}}},"gap":{"description":"Page/Container: gap between children","anyOf":[{"type":"string"},{"type":"object","properties":{"$nx":{"type":"string","description":"Script expression. Writing one needs records:write as well as schema:write"}},"required":["$nx"]}]},"globalFilterBinding":{"description":"MetricCard: field names this card reacts to for global page filters","type":"array","items":{"type":"string"}},"gridPreset":{"description":"Container: grid layout preset","anyOf":[{"type":"string"},{"type":"object","properties":{"$nx":{"type":"string","description":"Script expression. Writing one needs records:write as well as schema:write"}},"required":["$nx"]}]},"groupByFieldName":{"description":"Kanban: lane grouping field name","type":"string"},"height":{"description":"Component height","type":"number"},"icon":{"description":"Page: icon","type":"object","properties":{"color":{"description":"Icon color (hex string)","type":"string"},"filling":{"description":"Icon filling","anyOf":[{"type":"number","enum":[0]},{"type":"number","enum":[1]}]},"icon":{"type":"string","description":"Icon name"}},"required":["icon"]},"iconLeft":{"description":"Button/FieldComponent: icon before the label","anyOf":[{"type":"object","properties":{"color":{"description":"Icon color (hex string)","type":"string"},"filling":{"description":"Icon filling","anyOf":[{"type":"number","enum":[0]},{"type":"number","enum":[1]}]},"icon":{"type":"string","description":"Icon name"}},"required":["icon"]},{"type":"object","properties":{"$nx":{"type":"string","description":"Script expression. Writing one needs records:write as well as schema:write"}},"required":["$nx"]}]},"iconRight":{"description":"Button/FieldComponent: icon after the label","anyOf":[{"type":"object","properties":{"color":{"description":"Icon color (hex string)","type":"string"},"filling":{"description":"Icon filling","anyOf":[{"type":"number","enum":[0]},{"type":"number","enum":[1]}]},"icon":{"type":"string","description":"Icon name"}},"required":["icon"]},{"type":"object","properties":{"$nx":{"type":"string","description":"Script expression. Writing one needs records:write as well as schema:write"}},"required":["$nx"]}]},"id":{"type":"string","description":"Component id"},"imagePosition":{"description":"Kanban: card image crop/anchor, Normal mode only","type":"object","properties":{"position":{"type":"string"},"size":{"type":"string"}}},"isCompact":{"description":"Accordion: compact sections","type":"boolean"},"isHidden":{"description":"Page: hide from navigation","type":"boolean"},"isMarkdownEnabled":{"description":"FieldComponent: render a rich text field as markdown","type":"boolean"},"isSpreadsheetMode":{"description":"Table/FieldComponent: spreadsheet-style editing","type":"boolean"},"kind":{"type":"string","deprecated":true,"description":"Deprecated, use type. Same value, kept so existing integrations keep working"},"labelPosition":{"description":"FieldComponent: top, left, inside or hidden","type":"string"},"labels":{"description":"Component labels (localized)","type":"object","additionalProperties":{"type":"string"}},"mapTypeId":{"description":"Map: base layer type","type":"string"},"margin":{"description":"Container: margin","anyOf":[{"type":"string"},{"type":"object","properties":{"$nx":{"type":"string","description":"Script expression. Writing one needs records:write as well as schema:write"}},"required":["$nx"]}]},"name":{"description":"Component name","type":"string"},"onChange":{"description":"Tabs/FieldComponent: script run when the value changes","type":"string"},"onClick":{"description":"Button: script run on click","type":"string"},"order":{"description":"Component display order","type":"number"},"overflow":{"description":"Container: overflow behavior","anyOf":[{"type":"string"},{"type":"object","properties":{"$nx":{"type":"string","description":"Script expression. Writing one needs records:write as well as schema:write"}},"required":["$nx"]}]},"padding":{"description":"Page/Container: padding","anyOf":[{"type":"string"},{"type":"object","properties":{"$nx":{"type":"string","description":"Script expression. Writing one needs records:write as well as schema:write"}},"required":["$nx"]}]},"parentId":{"description":"Parent component id (forms the component tree)","type":"string"},"placeholder":{"description":"FieldComponent: placeholder, localized, plain or a script","anyOf":[{"type":"object","additionalProperties":{"type":"string"}},{"type":"string"},{"type":"object","properties":{"$nx":{"type":"string","description":"Script expression. Writing one needs records:write as well as schema:write"}},"required":["$nx"]}]},"quickStyle":{"description":"Text: style preset","anyOf":[{"type":"string","enum":["body-md","body-sm","custom","title-lg","title-md","title-sm"]},{"type":"object","properties":{"$nx":{"type":"string","description":"Script expression. Writing one needs records:write as well as schema:write"}},"required":["$nx"]}]},"radius":{"description":"Container/Text: corner radius","anyOf":[{"type":"string"},{"type":"object","properties":{"$nx":{"type":"string","description":"Script expression. Writing one needs records:write as well as schema:write"}},"required":["$nx"]}]},"remember":{"description":"InputComponent: how long the value is kept","type":"string","enum":["localStorage","memory","url"]},"shadow":{"description":"Container: shadow","anyOf":[{"type":"string"},{"type":"object","properties":{"$nx":{"type":"string","description":"Script expression. Writing one needs records:write as well as schema:write"}},"required":["$nx"]}]},"shadowDom":{"description":"DynamicHTMLComponent: render inside a shadow DOM","type":"boolean"},"showAs":{"description":"FieldComponent: how the value is shown (e.g. popup, combobox)","type":"string"},"showBulkActions":{"description":"Table/FieldComponent: show bulk actions","type":"boolean"},"showCalendarType":{"description":"Calendar: show the calendar type switcher","type":"boolean"},"showCreateButton":{"description":"Table: show the create-record button","type":"boolean"},"showCreateRow":{"description":"Table: show the inline create row","type":"boolean"},"showDataAs":{"description":"FieldComponent: script formatting a linked record","type":"string"},"showEmptyLane":{"description":"Kanban: show lanes with no cards","type":"boolean"},"showLinkExistingRecord":{"description":"FieldComponent: offer linking an existing record","type":"boolean"},"showMetadata":{"description":"FieldComponent: show file metadata","type":"boolean"},"showOutlines":{"description":"Page: show layout outlines in the editor","type":"boolean"},"showSearchField":{"description":"Table/Kanban/Gantt/Calendar/Map: show the search field","type":"boolean"},"showTimeScaleSelector":{"description":"Gantt: let the viewer switch time scale","type":"boolean"},"showTitle":{"description":"Table: show the table title","type":"boolean"},"size":{"description":"Button: sm, md or lg","anyOf":[{"type":"string"},{"type":"object","properties":{"$nx":{"type":"string","description":"Script expression. Writing one needs records:write as well as schema:write"}},"required":["$nx"]}]},"tableName":{"description":"Table this component reads from (Chart/Table/Kanban/Gantt/Calendar/Map/MetricCard)","type":"string"},"textAlign":{"description":"Text: alignment","type":"string","enum":["text-center","text-left","text-right"]},"titleFieldName":{"description":"Map: marker title field name","type":"string"},"tooltip":{"description":"FieldComponent: tooltip text","type":"string"},"type":{"type":"string","description":"Component type (e.g. Container, Button, Text, Page), the property the create and update routes and the module definition take"},"value":{"description":"Script used instead of table/filter/… when dataPoint is conditional","type":"string"},"valueSpec":{"description":"InputComponent: the type of the value, shaped like a field type, a reference has refTableName","type":"object","properties":{"type":{"type":"string"}},"required":["type"],"additionalProperties":{}},"valueType":{"description":"InputComponent: legacy value type, valueSpec wins where both are set","type":"string"},"variant":{"description":"Button/Accordion/Tabs: visual variant, InputComponent: text, email, phone, url, ...","anyOf":[{"type":"string"},{"type":"object","properties":{"$nx":{"type":"string","description":"Script expression. Writing one needs records:write as well as schema:write"}},"required":["$nx"]}]},"view":{"description":"Table/MetricCard/Kanban/Gantt/Calendar/Map: columns/filter/groupBy/sort configuration","type":"object","properties":{"columns":{"description":"View columns","type":"array","items":{"type":"object","properties":{"agg":{"description":"Aggregation function applied to the column","type":"string"},"conditionalStyling":{"description":"Legacy per-column conditional styling rules","type":"array","items":{"type":"object","properties":{"background":{"description":"Background color (hex string)","type":"string"},"cell":{"description":"Target cell","type":"string"},"color":{"description":"Icon color (hex string)","type":"string"},"icon":{"description":"Icon name","type":"string"},"operand":{"type":"string","description":"Comparator"},"value":{"type":"string","description":"Value compared against"}},"required":["operand","value"]}},"field":{"type":"string","description":"Field name, or a script expression for a calculated column"},"hidden":{"description":"Column retained but hidden from the grid","type":"boolean"},"id":{"description":"Stable identity of a calculated column; send it back unchanged when updating the view","type":"string"},"labels":{"description":"Column labels (localized)","type":"object","additionalProperties":{"type":"string"}},"order":{"type":"number","description":"Column display order"},"role":{"description":"Column role (e.g. title, date, image, location, color)","type":"string"},"width":{"description":"Column width","type":"number"}},"required":["field","order"]}},"conditionalFormatting":{"description":"Conditional formatting rules","type":"array","items":{"type":"object","properties":{"backgroundColor":{"description":"Background color (hex string)","type":"string"},"bold":{"description":"Bold text","type":"boolean"},"comparator":{"type":"string","enum":["contains","does_not_contain","ends_with","gt","gte","is","is_empty","is_not","is_not_empty","logic","lt","lte","starts_with"],"description":"Comparator"},"expression":{"description":"Script expression, used only when comparator is 'logic'","type":"string"},"fieldName":{"type":"string","description":"Target field name"},"highlightColor":{"description":"Highlight color (hex string)","type":"string"},"icon":{"description":"Icon","type":"object","properties":{"color":{"description":"Icon color (hex string)","type":"string"},"filling":{"description":"Icon filling","anyOf":[{"type":"number","enum":[0]},{"type":"number","enum":[1]}]},"icon":{"type":"string","description":"Icon name"}},"required":["icon"]},"id":{"type":"string","description":"Stable rule id"},"italic":{"description":"Italic text","type":"boolean"},"order":{"type":"number","description":"Rule evaluation order"},"strikethrough":{"description":"Strikethrough text","type":"boolean"},"target":{"type":"string","enum":["cell","row"],"description":"Whether the rule styles a single cell or the whole row"},"textColor":{"description":"Text color (hex string)","type":"string"},"value":{"description":"Value compared against"}},"required":["comparator","fieldName","id","order","target"]}},"filter":{"description":"Stored filter conditions","type":"array","items":{"type":"object","properties":{"field":{"description":"Field name","type":"string"},"id":{"type":"string","description":"Stable condition id"},"operator":{"description":"Filter operator","type":"string"},"value":{"description":"Value compared against","type":"string"}},"required":["id"]}},"groupBy":{"description":"Grouping configuration","type":"array","items":{"type":"object","properties":{"direction":{"description":"Group order direction, defaults to ascending","type":"string","enum":["asc","desc"]},"fieldName":{"type":"string","description":"Field name"}},"required":["fieldName"]}},"sort":{"description":"Sort configuration","type":"object","properties":{"direction":{"type":"string","enum":["asc","desc"],"description":"Sort direction"},"fieldName":{"type":"string","description":"Field name"}},"required":["direction","fieldName"]}}},"visible":{"description":"Conditional visibility logic: a boolean, or a script expression (as { $nx: <script> }) evaluated at render time","anyOf":[{"type":"boolean"},{"type":"object","properties":{"$nx":{"type":"string","description":"Script expression. Writing one needs records:write as well as schema:write"}},"required":["$nx"]}]},"visibleRoles":{"description":"Page: roles allowed to view this page","type":"array","items":{"type":"string"}},"widgetName":{"description":"CustomWidget: folder name under the workspace widgets directory","type":"string"},"widgetProps":{"description":"CustomWidget: property values, each static or a script expression (as { $nx: <script> })","type":"object","additionalProperties":{"anyOf":[{"type":"boolean"},{"type":"number"},{"type":"string"},{"type":"object","properties":{"$nx":{"type":"string","description":"Script expression. Writing one needs records:write as well as schema:write"}},"required":["$nx"]}]}},"width":{"description":"Component width: number = legacy px, string = percentage e.g. \"50%\"","type":["number","string"]}},"required":["id","kind","type"]}},"hideNavigation":{"description":"Hide module from navigation","type":"boolean"},"icon":{"description":"Module icon","type":"object","properties":{"color":{"description":"Icon color (hex string)","type":"string"},"filling":{"description":"Icon filling","anyOf":[{"type":"number","enum":[0]},{"type":"number","enum":[1]}]},"icon":{"type":"string","description":"Icon name"}},"required":["icon"]},"isHidden":{"description":"Hide module","type":"boolean"},"labels":{"description":"Module labels (localized)","type":"object","additionalProperties":{"type":"string"}},"name":{"type":"string"},"openRoles":{"description":"Module open roles","type":"array","items":{"type":"string"}},"tables":{"type":"array","items":{"type":"object","properties":{"canCreate":{"description":"Script expression gating record creation","type":"string"},"canDelete":{"description":"Script expression gating record deletion","type":"string"},"canRead":{"description":"Script expression gating record read access","type":"string"},"canWrite":{"description":"Script expression gating record write access","type":"string"},"createRoles":{"description":"Roles allowed to create records","type":"array","items":{"type":"string"}},"deleteRoles":{"description":"Roles allowed to delete records","type":"array","items":{"type":"string"}},"fields":{"type":"array","items":{"type":"object","properties":{"binding":{"description":"Read-only: internal binding reference, format not yet specified","type":"string"},"canRead":{"description":"Script expression gating field-level read access","type":"string"},"canWrite":{"description":"Script expression gating field-level write access","type":"string"},"defaultValue":{"description":"Default value applied when a record is created: a literal value (an array of option ids for multi/dmulti), or a script expression (as { $nx: <script> }) evaluated at creation time","anyOf":[{"type":"object","properties":{"$nx":{"type":"string","description":"Script expression. Writing one needs records:write as well as schema:write"}},"required":["$nx"]},{"type":["boolean","null","number","string"]},{"type":"array","items":{"type":"string"}}]},"expression":{"description":"Expression (for function type)","type":"string"},"index":{"description":"Field is indexed","type":"boolean"},"labels":{"description":"Field labels (localized)","type":"object","additionalProperties":{"type":"string"}},"name":{"type":"string","description":"Field name"},"onUpdate":{"description":"Script expression run as a row trigger when the field value changes","type":"string"},"optionColor":{"description":"Color expression for dchoice/dmulti fields","type":"string"},"optionIcon":{"description":"Icon expression for dchoice/dmulti fields","type":"string"},"optionName":{"description":"Display name expression for dchoice/dmulti fields","type":"string"},"options":{"description":"Options array for choice/multi fields, or selection expression for dchoice/dmulti fields","anyOf":[{"type":"array","items":{"type":"object","properties":{"color":{"description":"Option color (hex string)","type":"string"},"icon":{"description":"Option icon name","type":"string"},"id":{"type":"string","description":"Option id, a string the caller can set and change"},"label":{"type":"string","description":"Option text in the default language"},"labels":{"description":"Option text per language","type":"object","additionalProperties":{"type":"string"}},"order":{"type":"number","description":"Option display order"},"textColor":{"description":"Option text color (hex string)","type":"string"}},"required":["id","label","order"]}},{"type":"string"}]},"readRoles":{"description":"Roles allowed to read the field","type":"array","items":{"type":"string"}},"refTableName":{"description":"Reference table name","type":"string"},"required":{"description":"Field is required","type":"boolean"},"search":{"description":"Field is searchable","type":"boolean"},"syncedFrom":{"description":"Source column this field syncs from. Read-only unless the table has two-way sync with updates enabled, in which case every synced field except the key column is writable.","type":"string"},"type":{"type":"string","enum":["any","appointment","boolean","choice","color","date","dchoice","dmulti","file","function","html","icon","lambda","multi","number","react","reference","reverse","rowId","string","styled","time","timeinterval","timestamp","unknown","user","void"],"description":"Field type"},"unique":{"description":"Field is unique","type":"boolean"},"variant":{"description":"Field variant (for string type)","type":"string"},"writeRoles":{"description":"Roles allowed to write to the field","type":"array","items":{"type":"string"}}},"required":["name","type"]}},"hasFiles":{"description":"Enable files for the table","type":"boolean"},"hasGlobalSearch":{"description":"Enable global search for the table","type":"boolean"},"hasHistory":{"description":"Enable history for the table","type":"boolean"},"icon":{"description":"Table icon","type":"object","properties":{"color":{"description":"Icon color (hex string)","type":"string"},"filling":{"description":"Icon filling","anyOf":[{"type":"number","enum":[0]},{"type":"number","enum":[1]}]},"icon":{"type":"string","description":"Icon name"}},"required":["icon"]},"isEmailLinkingEnabled":{"description":"Enable email linking for the table","type":"boolean"},"isHidden":{"description":"Hide the table","type":"boolean"},"labels":{"description":"Table labels (localized)","type":"object","additionalProperties":{"type":"string"}},"name":{"type":"string"},"onCreate":{"description":"Script expression run as a trigger after a record is created","type":"string"},"onDelete":{"description":"Script expression run as a trigger when a record is deleted","type":"string"},"onUpdate":{"description":"Script expression run as a trigger after a record is updated","type":"string"},"readRoles":{"description":"Roles allowed to read records","type":"array","items":{"type":"string"}},"writeRoles":{"description":"Roles allowed to update records","type":"array","items":{"type":"string"}}},"required":["name"]}}},"required":["name"]},"description":"List of modules"},"page_info":{"type":"object","properties":{"has_more":{"type":"boolean","description":"Whether more results are available"},"limit":{"type":"number","description":"Maximum results per page"},"offset":{"type":"number","description":"Current offset"}},"description":"Pagination information"}},"required":["data","page_info"]}}}}
```

## The UpdateModuleBody object

```json
{"openapi":"3.0.0","info":{"title":"Ninox Public API","version":"1.0.0"},"components":{"schemas":{"UpdateModuleBody":{"type":"object","properties":{"afterOpen":{"description":"Script expression run in the browser each time the app is opened. Needs schema:write plus records:write; null removes the script and is accepted","type":"array","items":{"type":"string"}},"name":{"description":"Module name","type":"string","minLength":1,"maxLength":100,"pattern":"^[a-z0-9_]+$"},"hideNavigation":{"description":"Hide module from navigation","type":"boolean"},"icon":{"description":"Module icon","type":"object","properties":{"color":{"type":"string"},"filling":{"anyOf":[{"type":"number","enum":[0]},{"type":"number","enum":[1]}]},"icon":{"type":"string","minLength":1}}},"isHidden":{"description":"Hide module","type":"boolean"},"labels":{"description":"Module labels (localized)","type":"object","additionalProperties":{"type":"string","minLength":1,"maxLength":100}},"openRoles":{"description":"Module open roles","minItems":1,"maxItems":2,"type":"array","items":{"type":"string","enum":["admin","editor"]}}},"description":"Update Module request body"}}}}
```

## The UpdateModuleLabelsBody object

```json
{"openapi":"3.0.0","info":{"title":"Ninox Public API","version":"1.0.0"},"components":{"schemas":{"UpdateModuleLabelsBody":{"type":"object","properties":{"labels":{"type":"object","additionalProperties":{"type":"string","minLength":1,"maxLength":100}},"tables":{"type":"object","additionalProperties":{"type":"object","properties":{"fields":{"type":"object","additionalProperties":{"type":"object","properties":{"labels":{"type":"object","additionalProperties":{"type":"string","minLength":1,"maxLength":100}},"options":{"description":"Choice/multi option labels — every id must already exist on the field","type":"array","items":{"type":"object","properties":{"id":{"type":"string","minLength":1,"description":"Existing option id — must already exist on the field"},"labels":{"type":"object","additionalProperties":{"type":"string","minLength":1,"maxLength":100}}},"required":["id","labels"],"additionalProperties":false}}},"additionalProperties":false}},"labels":{"type":"object","additionalProperties":{"type":"string","minLength":1,"maxLength":100}}},"additionalProperties":false}}},"additionalProperties":false}}}}
```

## The ModuleLabelsResponse object

```json
{"openapi":"3.0.0","info":{"title":"Ninox Public API","version":"1.0.0"},"components":{"schemas":{"ModuleLabelsResponse":{"type":"object","properties":{"data":{"type":"object","properties":{"fields":{"type":"array","items":{"type":"object","properties":{"binding":{"description":"Read-only: internal binding reference, format not yet specified","type":"string"},"canRead":{"description":"Script expression gating field-level read access","type":"string"},"canWrite":{"description":"Script expression gating field-level write access","type":"string"},"defaultValue":{"description":"Default value applied when a record is created: a literal value (an array of option ids for multi/dmulti), or a script expression (as { $nx: <script> }) evaluated at creation time","anyOf":[{"type":"object","properties":{"$nx":{"type":"string","description":"Script expression. Writing one needs records:write as well as schema:write"}},"required":["$nx"]},{"type":["boolean","null","number","string"]},{"type":"array","items":{"type":"string"}}]},"expression":{"description":"Expression (for function type)","type":"string"},"index":{"description":"Field is indexed","type":"boolean"},"labels":{"description":"Field labels (localized)","type":"object","additionalProperties":{"type":"string"}},"name":{"type":"string","description":"Field name"},"onUpdate":{"description":"Script expression run as a row trigger when the field value changes","type":"string"},"optionColor":{"description":"Color expression for dchoice/dmulti fields","type":"string"},"optionIcon":{"description":"Icon expression for dchoice/dmulti fields","type":"string"},"optionName":{"description":"Display name expression for dchoice/dmulti fields","type":"string"},"options":{"description":"Options array for choice/multi fields, or selection expression for dchoice/dmulti fields","anyOf":[{"type":"array","items":{"type":"object","properties":{"color":{"description":"Option color (hex string)","type":"string"},"icon":{"description":"Option icon name","type":"string"},"id":{"type":"string","description":"Option id, a string the caller can set and change"},"label":{"type":"string","description":"Option text in the default language"},"labels":{"description":"Option text per language","type":"object","additionalProperties":{"type":"string"}},"order":{"type":"number","description":"Option display order"},"textColor":{"description":"Option text color (hex string)","type":"string"}},"required":["id","label","order"]}},{"type":"string"}]},"readRoles":{"description":"Roles allowed to read the field","type":"array","items":{"type":"string"}},"refTableName":{"description":"Reference table name","type":"string"},"required":{"description":"Field is required","type":"boolean"},"search":{"description":"Field is searchable","type":"boolean"},"syncedFrom":{"description":"Source column this field syncs from. Read-only unless the table has two-way sync with updates enabled, in which case every synced field except the key column is writable.","type":"string"},"type":{"type":"string","enum":["any","appointment","boolean","choice","color","date","dchoice","dmulti","file","function","html","icon","lambda","multi","number","react","reference","reverse","rowId","string","styled","time","timeinterval","timestamp","unknown","user","void"],"description":"Field type"},"unique":{"description":"Field is unique","type":"boolean"},"variant":{"description":"Field variant (for string type)","type":"string"},"writeRoles":{"description":"Roles allowed to write to the field","type":"array","items":{"type":"string"}}},"required":["name","type"]},"description":"Fields whose labels were updated"},"module":{"type":"object","properties":{"afterOpen":{"description":"Script expression run in the browser each time the app is opened","type":"string"},"components":{"description":"Module components (pages, containers, widgets)","type":"array","items":{"type":"object","properties":{"afterHide":{"description":"Container directly under Tabs: script run when this tab stops being shown","type":"string"},"aggregation":{"description":"MetricCard: aggregation function","type":"string","enum":["avg","count","max","median","min","sum"]},"annualRecurring":{"description":"Calendar: render every record on the same day/month every year","type":"boolean"},"arrangement":{"description":"Page/Container: layout direction","type":"string","enum":["grid","ltr","row","ttb"]},"background":{"description":"Container/Page/Text: background","anyOf":[{"type":"string"},{"type":"object","properties":{"$nx":{"type":"string","description":"Script expression. Writing one needs records:write as well as schema:write"}},"required":["$nx"]}]},"beforeShow":{"description":"Container directly under Tabs: script run when this tab is shown","type":"string"},"border":{"description":"Container: border","anyOf":[{"type":"object","properties":{"color":{"type":"string"},"style":{"type":"string","enum":["dashed","dotted","double","none","solid"]},"width":{"type":"string"}},"required":["style","width"]},{"type":"object","properties":{"$nx":{"type":"string","description":"Script expression. Writing one needs records:write as well as schema:write"}},"required":["$nx"]}]},"calendarType":{"description":"Calendar: display type","type":"string"},"cardBorder":{"description":"Kanban: card border CSS shorthand, Normal mode only","type":"string"},"cardFont":{"description":"Kanban: card font style tokens, Normal mode only","type":"string"},"cardPadding":{"description":"Kanban: card padding in px, Normal mode only","type":"number"},"cardRadius":{"description":"Kanban: card corner radius in px, Normal mode only","type":"number"},"chartConfig":{"description":"Chart: chart type, axes and data series","type":"object","properties":{"chartType":{"type":"string","enum":["bar","line","pie","funnel","ranking","board"]},"dataSets":{"type":"array","items":{"type":"object","properties":{"aggregation":{"type":"string","enum":["average","count","max","median","min","none","sum"]},"color":{"description":"Series color (hex string)","type":"string"},"fieldName":{"description":"Field name this series reads from","type":"string"},"labels":{"description":"Series labels (localized)","type":"object","additionalProperties":{"type":"string"}}}}},"donut":{"type":"boolean"},"labelPosition":{"type":"string","enum":["bottom","center","inside","outside","top"]},"legend":{"type":"object","properties":{"show":{"type":"boolean"}}},"limit":{"description":"ranking only: how many categories it shows","type":"integer","minimum":1,"maximum":20},"orientation":{"type":"string","enum":["horizontal","vertical"]},"showDataTable":{"type":"boolean"},"showLabels":{"type":"boolean"},"showPoints":{"type":"boolean"},"showTitle":{"type":"boolean"},"smooth":{"type":"boolean"},"stacked":{"type":"boolean"},"style":{"type":"string","enum":["default","half_donut","pad_angle","rounded_corner"]},"tooltips":{"type":"object","properties":{"show":{"type":"boolean"}}},"xAxis":{"type":"object","properties":{"fieldName":{"description":"X-axis field name, null removes it","type":["string","null"]},"groupBy":{"type":"string","enum":["daily","monthly","none","quarterly","weekly","yearly"]},"show":{"type":"boolean"}}},"yAxis":{"type":"object","properties":{"show":{"type":"boolean"}}}},"required":["chartType","dataSets","xAxis"]},"color":{"description":"Text: text color (hex string). Button: theme color name","anyOf":[{"type":"string"},{"type":"object","properties":{"$nx":{"type":"string","description":"Script expression. Writing one needs records:write as well as schema:write"}},"required":["$nx"]}]},"colorFieldName":{"description":"Map: marker color field name","type":"string"},"constraints":{"description":"FieldComponent: script limiting which records a reference can link to, needs schema:manage-permissions","type":"string"},"content":{"description":"Text: content, localized or a script expression","anyOf":[{"type":"object","additionalProperties":{"type":"string"}},{"type":"object","properties":{"$nx":{"type":"string","description":"Script expression. Writing one needs records:write as well as schema:write"}},"required":["$nx"]}]},"customStyle":{"description":"Text: full custom style config, opaque, used only when quickStyle is \"custom\"","type":"object","additionalProperties":{}},"dataPoint":{"description":"'conditional' replaces table/filter/… with the `value` script","type":"string","enum":["conditional","normal"]},"defaultValue":{"description":"InputComponent: initial value, or { $nx: <script> }","anyOf":[{"type":"boolean"},{"type":"number"},{"type":"string"},{"type":"object","properties":{"$nx":{"type":"string","description":"Script expression. Writing one needs records:write as well as schema:write"}},"required":["$nx"]}]},"disabled":{"description":"Button/FieldComponent: disable the control, a boolean or a script","anyOf":[{"type":"boolean"},{"type":"object","properties":{"$nx":{"type":"string","description":"Script expression. Writing one needs records:write as well as schema:write"}},"required":["$nx"]}]},"display":{"description":"MetricCard: display formatting and trend configuration","type":"object","properties":{"color":{"type":"string"},"format":{"type":"string","enum":["compact","currency","number","percentage"]},"icon":{"type":"string"},"trend":{"type":"object","properties":{"customPeriodEnd":{"description":"ISO date (YYYY-MM-DD), for period \"custom\"","type":"string"},"customPeriodStart":{"description":"ISO date (YYYY-MM-DD), for period \"custom\"","type":"string"},"format":{"type":"string","enum":["absolute","percentage"]},"isShown":{"type":"boolean"},"period":{"type":"string","enum":["custom","last_month","last_week","last_year","previous_period","yesterday"]},"positiveDirection":{"type":"string","enum":["down","up"]}},"required":["format","isShown"]}},"required":["color","format","trend"]},"displayAs":{"description":"FieldComponent: how a yes/no field is shown","type":"string"},"expression":{"description":"DynamicHTMLComponent: script returning the HTML to render","type":"string"},"fieldIdDataPoint":{"description":"MetricCard: 'conditional' replaces table/filter/fieldName/aggregation with fieldIdValue","type":"string","enum":["conditional","normal"]},"fieldIdValue":{"description":"MetricCard: whole-dataset script producing the final number when fieldIdDataPoint is conditional","type":"string"},"fieldName":{"description":"MetricCard/Calendar/Map: primary bound field name","type":"string"},"filter":{"description":"MetricCard/Chart: stored filter conditions","type":"array","items":{"type":"object","properties":{"field":{"description":"Field name","type":"string"},"id":{"type":"string","description":"Stable condition id"},"operator":{"description":"Filter operator","type":"string"},"value":{"description":"Value compared against","type":"string"}},"required":["id"]}},"flex":{"description":"Container: flex sizing","anyOf":[{"type":"string"},{"type":"object","properties":{"$nx":{"type":"string","description":"Script expression. Writing one needs records:write as well as schema:write"}},"required":["$nx"]}]},"ganttConfig":{"description":"Gantt: which fields the bars/milestones/dependencies read from","type":"object","properties":{"baselineEndFieldName":{"description":"Planned end field, rendered as a ghost bar","type":["string","null"]},"baselineStartFieldName":{"description":"Planned start field, rendered as a ghost bar","type":["string","null"]},"dependencyDirection":{"type":"string","enum":["predecessor","successor"]},"dependencyFieldName":{"description":"A reference field pointing back at this table","type":["string","null"]},"disableDragAndDrop":{"type":"boolean"},"endFieldName":{"type":["string","null"]},"hideTitleColumn":{"type":"boolean"},"hideWeekends":{"type":"boolean"},"milestoneFieldName":{"type":["string","null"]},"progressFieldName":{"type":["string","null"]},"showCriticalPath":{"type":"boolean"},"showWeekends":{"type":"boolean"},"startFieldName":{"type":["string","null"]},"timeScale":{"type":"string","enum":["day","month","quarter","week"]},"titleColumnFieldName":{"type":["string","null"]},"titleColumnWidth":{"type":"number"}}},"gap":{"description":"Page/Container: gap between children","anyOf":[{"type":"string"},{"type":"object","properties":{"$nx":{"type":"string","description":"Script expression. Writing one needs records:write as well as schema:write"}},"required":["$nx"]}]},"globalFilterBinding":{"description":"MetricCard: field names this card reacts to for global page filters","type":"array","items":{"type":"string"}},"gridPreset":{"description":"Container: grid layout preset","anyOf":[{"type":"string"},{"type":"object","properties":{"$nx":{"type":"string","description":"Script expression. Writing one needs records:write as well as schema:write"}},"required":["$nx"]}]},"groupByFieldName":{"description":"Kanban: lane grouping field name","type":"string"},"height":{"description":"Component height","type":"number"},"icon":{"description":"Page: icon","type":"object","properties":{"color":{"description":"Icon color (hex string)","type":"string"},"filling":{"description":"Icon filling","anyOf":[{"type":"number","enum":[0]},{"type":"number","enum":[1]}]},"icon":{"type":"string","description":"Icon name"}},"required":["icon"]},"iconLeft":{"description":"Button/FieldComponent: icon before the label","anyOf":[{"type":"object","properties":{"color":{"description":"Icon color (hex string)","type":"string"},"filling":{"description":"Icon filling","anyOf":[{"type":"number","enum":[0]},{"type":"number","enum":[1]}]},"icon":{"type":"string","description":"Icon name"}},"required":["icon"]},{"type":"object","properties":{"$nx":{"type":"string","description":"Script expression. Writing one needs records:write as well as schema:write"}},"required":["$nx"]}]},"iconRight":{"description":"Button/FieldComponent: icon after the label","anyOf":[{"type":"object","properties":{"color":{"description":"Icon color (hex string)","type":"string"},"filling":{"description":"Icon filling","anyOf":[{"type":"number","enum":[0]},{"type":"number","enum":[1]}]},"icon":{"type":"string","description":"Icon name"}},"required":["icon"]},{"type":"object","properties":{"$nx":{"type":"string","description":"Script expression. Writing one needs records:write as well as schema:write"}},"required":["$nx"]}]},"id":{"type":"string","description":"Component id"},"imagePosition":{"description":"Kanban: card image crop/anchor, Normal mode only","type":"object","properties":{"position":{"type":"string"},"size":{"type":"string"}}},"isCompact":{"description":"Accordion: compact sections","type":"boolean"},"isHidden":{"description":"Page: hide from navigation","type":"boolean"},"isMarkdownEnabled":{"description":"FieldComponent: render a rich text field as markdown","type":"boolean"},"isSpreadsheetMode":{"description":"Table/FieldComponent: spreadsheet-style editing","type":"boolean"},"kind":{"type":"string","deprecated":true,"description":"Deprecated, use type. Same value, kept so existing integrations keep working"},"labelPosition":{"description":"FieldComponent: top, left, inside or hidden","type":"string"},"labels":{"description":"Component labels (localized)","type":"object","additionalProperties":{"type":"string"}},"mapTypeId":{"description":"Map: base layer type","type":"string"},"margin":{"description":"Container: margin","anyOf":[{"type":"string"},{"type":"object","properties":{"$nx":{"type":"string","description":"Script expression. Writing one needs records:write as well as schema:write"}},"required":["$nx"]}]},"name":{"description":"Component name","type":"string"},"onChange":{"description":"Tabs/FieldComponent: script run when the value changes","type":"string"},"onClick":{"description":"Button: script run on click","type":"string"},"order":{"description":"Component display order","type":"number"},"overflow":{"description":"Container: overflow behavior","anyOf":[{"type":"string"},{"type":"object","properties":{"$nx":{"type":"string","description":"Script expression. Writing one needs records:write as well as schema:write"}},"required":["$nx"]}]},"padding":{"description":"Page/Container: padding","anyOf":[{"type":"string"},{"type":"object","properties":{"$nx":{"type":"string","description":"Script expression. Writing one needs records:write as well as schema:write"}},"required":["$nx"]}]},"parentId":{"description":"Parent component id (forms the component tree)","type":"string"},"placeholder":{"description":"FieldComponent: placeholder, localized, plain or a script","anyOf":[{"type":"object","additionalProperties":{"type":"string"}},{"type":"string"},{"type":"object","properties":{"$nx":{"type":"string","description":"Script expression. Writing one needs records:write as well as schema:write"}},"required":["$nx"]}]},"quickStyle":{"description":"Text: style preset","anyOf":[{"type":"string","enum":["body-md","body-sm","custom","title-lg","title-md","title-sm"]},{"type":"object","properties":{"$nx":{"type":"string","description":"Script expression. Writing one needs records:write as well as schema:write"}},"required":["$nx"]}]},"radius":{"description":"Container/Text: corner radius","anyOf":[{"type":"string"},{"type":"object","properties":{"$nx":{"type":"string","description":"Script expression. Writing one needs records:write as well as schema:write"}},"required":["$nx"]}]},"remember":{"description":"InputComponent: how long the value is kept","type":"string","enum":["localStorage","memory","url"]},"shadow":{"description":"Container: shadow","anyOf":[{"type":"string"},{"type":"object","properties":{"$nx":{"type":"string","description":"Script expression. Writing one needs records:write as well as schema:write"}},"required":["$nx"]}]},"shadowDom":{"description":"DynamicHTMLComponent: render inside a shadow DOM","type":"boolean"},"showAs":{"description":"FieldComponent: how the value is shown (e.g. popup, combobox)","type":"string"},"showBulkActions":{"description":"Table/FieldComponent: show bulk actions","type":"boolean"},"showCalendarType":{"description":"Calendar: show the calendar type switcher","type":"boolean"},"showCreateButton":{"description":"Table: show the create-record button","type":"boolean"},"showCreateRow":{"description":"Table: show the inline create row","type":"boolean"},"showDataAs":{"description":"FieldComponent: script formatting a linked record","type":"string"},"showEmptyLane":{"description":"Kanban: show lanes with no cards","type":"boolean"},"showLinkExistingRecord":{"description":"FieldComponent: offer linking an existing record","type":"boolean"},"showMetadata":{"description":"FieldComponent: show file metadata","type":"boolean"},"showOutlines":{"description":"Page: show layout outlines in the editor","type":"boolean"},"showSearchField":{"description":"Table/Kanban/Gantt/Calendar/Map: show the search field","type":"boolean"},"showTimeScaleSelector":{"description":"Gantt: let the viewer switch time scale","type":"boolean"},"showTitle":{"description":"Table: show the table title","type":"boolean"},"size":{"description":"Button: sm, md or lg","anyOf":[{"type":"string"},{"type":"object","properties":{"$nx":{"type":"string","description":"Script expression. Writing one needs records:write as well as schema:write"}},"required":["$nx"]}]},"tableName":{"description":"Table this component reads from (Chart/Table/Kanban/Gantt/Calendar/Map/MetricCard)","type":"string"},"textAlign":{"description":"Text: alignment","type":"string","enum":["text-center","text-left","text-right"]},"titleFieldName":{"description":"Map: marker title field name","type":"string"},"tooltip":{"description":"FieldComponent: tooltip text","type":"string"},"type":{"type":"string","description":"Component type (e.g. Container, Button, Text, Page), the property the create and update routes and the module definition take"},"value":{"description":"Script used instead of table/filter/… when dataPoint is conditional","type":"string"},"valueSpec":{"description":"InputComponent: the type of the value, shaped like a field type, a reference has refTableName","type":"object","properties":{"type":{"type":"string"}},"required":["type"],"additionalProperties":{}},"valueType":{"description":"InputComponent: legacy value type, valueSpec wins where both are set","type":"string"},"variant":{"description":"Button/Accordion/Tabs: visual variant, InputComponent: text, email, phone, url, ...","anyOf":[{"type":"string"},{"type":"object","properties":{"$nx":{"type":"string","description":"Script expression. Writing one needs records:write as well as schema:write"}},"required":["$nx"]}]},"view":{"description":"Table/MetricCard/Kanban/Gantt/Calendar/Map: columns/filter/groupBy/sort configuration","type":"object","properties":{"columns":{"description":"View columns","type":"array","items":{"type":"object","properties":{"agg":{"description":"Aggregation function applied to the column","type":"string"},"conditionalStyling":{"description":"Legacy per-column conditional styling rules","type":"array","items":{"type":"object","properties":{"background":{"description":"Background color (hex string)","type":"string"},"cell":{"description":"Target cell","type":"string"},"color":{"description":"Icon color (hex string)","type":"string"},"icon":{"description":"Icon name","type":"string"},"operand":{"type":"string","description":"Comparator"},"value":{"type":"string","description":"Value compared against"}},"required":["operand","value"]}},"field":{"type":"string","description":"Field name, or a script expression for a calculated column"},"hidden":{"description":"Column retained but hidden from the grid","type":"boolean"},"id":{"description":"Stable identity of a calculated column; send it back unchanged when updating the view","type":"string"},"labels":{"description":"Column labels (localized)","type":"object","additionalProperties":{"type":"string"}},"order":{"type":"number","description":"Column display order"},"role":{"description":"Column role (e.g. title, date, image, location, color)","type":"string"},"width":{"description":"Column width","type":"number"}},"required":["field","order"]}},"conditionalFormatting":{"description":"Conditional formatting rules","type":"array","items":{"type":"object","properties":{"backgroundColor":{"description":"Background color (hex string)","type":"string"},"bold":{"description":"Bold text","type":"boolean"},"comparator":{"type":"string","enum":["contains","does_not_contain","ends_with","gt","gte","is","is_empty","is_not","is_not_empty","logic","lt","lte","starts_with"],"description":"Comparator"},"expression":{"description":"Script expression, used only when comparator is 'logic'","type":"string"},"fieldName":{"type":"string","description":"Target field name"},"highlightColor":{"description":"Highlight color (hex string)","type":"string"},"icon":{"description":"Icon","type":"object","properties":{"color":{"description":"Icon color (hex string)","type":"string"},"filling":{"description":"Icon filling","anyOf":[{"type":"number","enum":[0]},{"type":"number","enum":[1]}]},"icon":{"type":"string","description":"Icon name"}},"required":["icon"]},"id":{"type":"string","description":"Stable rule id"},"italic":{"description":"Italic text","type":"boolean"},"order":{"type":"number","description":"Rule evaluation order"},"strikethrough":{"description":"Strikethrough text","type":"boolean"},"target":{"type":"string","enum":["cell","row"],"description":"Whether the rule styles a single cell or the whole row"},"textColor":{"description":"Text color (hex string)","type":"string"},"value":{"description":"Value compared against"}},"required":["comparator","fieldName","id","order","target"]}},"filter":{"description":"Stored filter conditions","type":"array","items":{"type":"object","properties":{"field":{"description":"Field name","type":"string"},"id":{"type":"string","description":"Stable condition id"},"operator":{"description":"Filter operator","type":"string"},"value":{"description":"Value compared against","type":"string"}},"required":["id"]}},"groupBy":{"description":"Grouping configuration","type":"array","items":{"type":"object","properties":{"direction":{"description":"Group order direction, defaults to ascending","type":"string","enum":["asc","desc"]},"fieldName":{"type":"string","description":"Field name"}},"required":["fieldName"]}},"sort":{"description":"Sort configuration","type":"object","properties":{"direction":{"type":"string","enum":["asc","desc"],"description":"Sort direction"},"fieldName":{"type":"string","description":"Field name"}},"required":["direction","fieldName"]}}},"visible":{"description":"Conditional visibility logic: a boolean, or a script expression (as { $nx: <script> }) evaluated at render time","anyOf":[{"type":"boolean"},{"type":"object","properties":{"$nx":{"type":"string","description":"Script expression. Writing one needs records:write as well as schema:write"}},"required":["$nx"]}]},"visibleRoles":{"description":"Page: roles allowed to view this page","type":"array","items":{"type":"string"}},"widgetName":{"description":"CustomWidget: folder name under the workspace widgets directory","type":"string"},"widgetProps":{"description":"CustomWidget: property values, each static or a script expression (as { $nx: <script> })","type":"object","additionalProperties":{"anyOf":[{"type":"boolean"},{"type":"number"},{"type":"string"},{"type":"object","properties":{"$nx":{"type":"string","description":"Script expression. Writing one needs records:write as well as schema:write"}},"required":["$nx"]}]}},"width":{"description":"Component width: number = legacy px, string = percentage e.g. \"50%\"","type":["number","string"]}},"required":["id","kind","type"]}},"hideNavigation":{"description":"Hide module from navigation","type":"boolean"},"icon":{"description":"Module icon","type":"object","properties":{"color":{"description":"Icon color (hex string)","type":"string"},"filling":{"description":"Icon filling","anyOf":[{"type":"number","enum":[0]},{"type":"number","enum":[1]}]},"icon":{"type":"string","description":"Icon name"}},"required":["icon"]},"isHidden":{"description":"Hide module","type":"boolean"},"labels":{"description":"Module labels (localized)","type":"object","additionalProperties":{"type":"string"}},"name":{"type":"string"},"openRoles":{"description":"Module open roles","type":"array","items":{"type":"string"}},"tables":{"type":"array","items":{"type":"object","properties":{"canCreate":{"description":"Script expression gating record creation","type":"string"},"canDelete":{"description":"Script expression gating record deletion","type":"string"},"canRead":{"description":"Script expression gating record read access","type":"string"},"canWrite":{"description":"Script expression gating record write access","type":"string"},"createRoles":{"description":"Roles allowed to create records","type":"array","items":{"type":"string"}},"deleteRoles":{"description":"Roles allowed to delete records","type":"array","items":{"type":"string"}},"fields":{"type":"array","items":{"type":"object","properties":{"binding":{"description":"Read-only: internal binding reference, format not yet specified","type":"string"},"canRead":{"description":"Script expression gating field-level read access","type":"string"},"canWrite":{"description":"Script expression gating field-level write access","type":"string"},"defaultValue":{"description":"Default value applied when a record is created: a literal value (an array of option ids for multi/dmulti), or a script expression (as { $nx: <script> }) evaluated at creation time","anyOf":[{"type":"object","properties":{"$nx":{"type":"string","description":"Script expression. Writing one needs records:write as well as schema:write"}},"required":["$nx"]},{"type":["boolean","null","number","string"]},{"type":"array","items":{"type":"string"}}]},"expression":{"description":"Expression (for function type)","type":"string"},"index":{"description":"Field is indexed","type":"boolean"},"labels":{"description":"Field labels (localized)","type":"object","additionalProperties":{"type":"string"}},"name":{"type":"string","description":"Field name"},"onUpdate":{"description":"Script expression run as a row trigger when the field value changes","type":"string"},"optionColor":{"description":"Color expression for dchoice/dmulti fields","type":"string"},"optionIcon":{"description":"Icon expression for dchoice/dmulti fields","type":"string"},"optionName":{"description":"Display name expression for dchoice/dmulti fields","type":"string"},"options":{"description":"Options array for choice/multi fields, or selection expression for dchoice/dmulti fields","anyOf":[{"type":"array","items":{"type":"object","properties":{"color":{"description":"Option color (hex string)","type":"string"},"icon":{"description":"Option icon name","type":"string"},"id":{"type":"string","description":"Option id, a string the caller can set and change"},"label":{"type":"string","description":"Option text in the default language"},"labels":{"description":"Option text per language","type":"object","additionalProperties":{"type":"string"}},"order":{"type":"number","description":"Option display order"},"textColor":{"description":"Option text color (hex string)","type":"string"}},"required":["id","label","order"]}},{"type":"string"}]},"readRoles":{"description":"Roles allowed to read the field","type":"array","items":{"type":"string"}},"refTableName":{"description":"Reference table name","type":"string"},"required":{"description":"Field is required","type":"boolean"},"search":{"description":"Field is searchable","type":"boolean"},"syncedFrom":{"description":"Source column this field syncs from. Read-only unless the table has two-way sync with updates enabled, in which case every synced field except the key column is writable.","type":"string"},"type":{"type":"string","enum":["any","appointment","boolean","choice","color","date","dchoice","dmulti","file","function","html","icon","lambda","multi","number","react","reference","reverse","rowId","string","styled","time","timeinterval","timestamp","unknown","user","void"],"description":"Field type"},"unique":{"description":"Field is unique","type":"boolean"},"variant":{"description":"Field variant (for string type)","type":"string"},"writeRoles":{"description":"Roles allowed to write to the field","type":"array","items":{"type":"string"}}},"required":["name","type"]}},"hasFiles":{"description":"Enable files for the table","type":"boolean"},"hasGlobalSearch":{"description":"Enable global search for the table","type":"boolean"},"hasHistory":{"description":"Enable history for the table","type":"boolean"},"icon":{"description":"Table icon","type":"object","properties":{"color":{"description":"Icon color (hex string)","type":"string"},"filling":{"description":"Icon filling","anyOf":[{"type":"number","enum":[0]},{"type":"number","enum":[1]}]},"icon":{"type":"string","description":"Icon name"}},"required":["icon"]},"isEmailLinkingEnabled":{"description":"Enable email linking for the table","type":"boolean"},"isHidden":{"description":"Hide the table","type":"boolean"},"labels":{"description":"Table labels (localized)","type":"object","additionalProperties":{"type":"string"}},"name":{"type":"string"},"onCreate":{"description":"Script expression run as a trigger after a record is created","type":"string"},"onDelete":{"description":"Script expression run as a trigger when a record is deleted","type":"string"},"onUpdate":{"description":"Script expression run as a trigger after a record is updated","type":"string"},"readRoles":{"description":"Roles allowed to read records","type":"array","items":{"type":"string"}},"writeRoles":{"description":"Roles allowed to update records","type":"array","items":{"type":"string"}}},"required":["name"]}}},"required":["name"],"description":"The module, with its updated labels if any"},"tables":{"type":"array","items":{"type":"object","properties":{"canCreate":{"description":"Script expression gating record creation","type":"string"},"canDelete":{"description":"Script expression gating record deletion","type":"string"},"canRead":{"description":"Script expression gating record read access","type":"string"},"canWrite":{"description":"Script expression gating record write access","type":"string"},"createRoles":{"description":"Roles allowed to create records","type":"array","items":{"type":"string"}},"deleteRoles":{"description":"Roles allowed to delete records","type":"array","items":{"type":"string"}},"fields":{"type":"array","items":{"type":"object","properties":{"binding":{"description":"Read-only: internal binding reference, format not yet specified","type":"string"},"canRead":{"description":"Script expression gating field-level read access","type":"string"},"canWrite":{"description":"Script expression gating field-level write access","type":"string"},"defaultValue":{"description":"Default value applied when a record is created: a literal value (an array of option ids for multi/dmulti), or a script expression (as { $nx: <script> }) evaluated at creation time","anyOf":[{"type":"object","properties":{"$nx":{"type":"string","description":"Script expression. Writing one needs records:write as well as schema:write"}},"required":["$nx"]},{"type":["boolean","null","number","string"]},{"type":"array","items":{"type":"string"}}]},"expression":{"description":"Expression (for function type)","type":"string"},"index":{"description":"Field is indexed","type":"boolean"},"labels":{"description":"Field labels (localized)","type":"object","additionalProperties":{"type":"string"}},"name":{"type":"string","description":"Field name"},"onUpdate":{"description":"Script expression run as a row trigger when the field value changes","type":"string"},"optionColor":{"description":"Color expression for dchoice/dmulti fields","type":"string"},"optionIcon":{"description":"Icon expression for dchoice/dmulti fields","type":"string"},"optionName":{"description":"Display name expression for dchoice/dmulti fields","type":"string"},"options":{"description":"Options array for choice/multi fields, or selection expression for dchoice/dmulti fields","anyOf":[{"type":"array","items":{"type":"object","properties":{"color":{"description":"Option color (hex string)","type":"string"},"icon":{"description":"Option icon name","type":"string"},"id":{"type":"string","description":"Option id, a string the caller can set and change"},"label":{"type":"string","description":"Option text in the default language"},"labels":{"description":"Option text per language","type":"object","additionalProperties":{"type":"string"}},"order":{"type":"number","description":"Option display order"},"textColor":{"description":"Option text color (hex string)","type":"string"}},"required":["id","label","order"]}},{"type":"string"}]},"readRoles":{"description":"Roles allowed to read the field","type":"array","items":{"type":"string"}},"refTableName":{"description":"Reference table name","type":"string"},"required":{"description":"Field is required","type":"boolean"},"search":{"description":"Field is searchable","type":"boolean"},"syncedFrom":{"description":"Source column this field syncs from. Read-only unless the table has two-way sync with updates enabled, in which case every synced field except the key column is writable.","type":"string"},"type":{"type":"string","enum":["any","appointment","boolean","choice","color","date","dchoice","dmulti","file","function","html","icon","lambda","multi","number","react","reference","reverse","rowId","string","styled","time","timeinterval","timestamp","unknown","user","void"],"description":"Field type"},"unique":{"description":"Field is unique","type":"boolean"},"variant":{"description":"Field variant (for string type)","type":"string"},"writeRoles":{"description":"Roles allowed to write to the field","type":"array","items":{"type":"string"}}},"required":["name","type"]}},"hasFiles":{"description":"Enable files for the table","type":"boolean"},"hasGlobalSearch":{"description":"Enable global search for the table","type":"boolean"},"hasHistory":{"description":"Enable history for the table","type":"boolean"},"icon":{"description":"Table icon","type":"object","properties":{"color":{"description":"Icon color (hex string)","type":"string"},"filling":{"description":"Icon filling","anyOf":[{"type":"number","enum":[0]},{"type":"number","enum":[1]}]},"icon":{"type":"string","description":"Icon name"}},"required":["icon"]},"isEmailLinkingEnabled":{"description":"Enable email linking for the table","type":"boolean"},"isHidden":{"description":"Hide the table","type":"boolean"},"labels":{"description":"Table labels (localized)","type":"object","additionalProperties":{"type":"string"}},"name":{"type":"string"},"onCreate":{"description":"Script expression run as a trigger after a record is created","type":"string"},"onDelete":{"description":"Script expression run as a trigger when a record is deleted","type":"string"},"onUpdate":{"description":"Script expression run as a trigger after a record is updated","type":"string"},"readRoles":{"description":"Roles allowed to read records","type":"array","items":{"type":"string"}},"writeRoles":{"description":"Roles allowed to update records","type":"array","items":{"type":"string"}}},"required":["name"]},"description":"Tables whose labels were updated"}}}},"required":["data"]}}}}
```

## The CreateModuleScriptBody object

```json
{"openapi":"3.0.0","info":{"title":"Ninox Public API","version":"1.0.0"},"components":{"schemas":{"CreateModuleScriptBody":{"type":"object","properties":{"code":{"type":"string","description":"Function definitions only, callable from every script of the module. Needs schema:write plus records:write"},"name":{"type":"string","minLength":1,"maxLength":100,"description":"Script name, scripts compile in name order"}},"required":["code","name"],"additionalProperties":false}}}}
```

## The ModuleScriptResponse object

```json
{"openapi":"3.0.0","info":{"title":"Ninox Public API","version":"1.0.0"},"components":{"schemas":{"ModuleScriptResponse":{"type":"object","properties":{"data":{"type":"object","properties":{"code":{"type":"string","description":"Script of function definitions, callable from every script of the module"},"id":{"type":"string","description":"Global function script id"},"moduleName":{"type":"string","description":"Module name"},"name":{"type":"string","description":"Global function script name, scripts compile in name order"}},"description":"Global function script"}},"required":["data"]}}}}
```

## The DeleteModuleScriptResponse object

```json
{"openapi":"3.0.0","info":{"title":"Ninox Public API","version":"1.0.0"},"components":{"schemas":{"DeleteModuleScriptResponse":{"type":"object","properties":{"data":{"type":"object","properties":{"id":{"type":"string","description":"Deleted script id"}}}},"required":["data"]}}}}
```

## The ModuleScriptsResponse object

```json
{"openapi":"3.0.0","info":{"title":"Ninox Public API","version":"1.0.0"},"components":{"schemas":{"ModuleScriptsResponse":{"type":"object","properties":{"data":{"type":"array","items":{"type":"object","properties":{"code":{"type":"string","description":"Script of function definitions, callable from every script of the module"},"id":{"type":"string","description":"Global function script id"},"moduleName":{"type":"string","description":"Module name"},"name":{"type":"string","description":"Global function script name, scripts compile in name order"}},"required":["code","id","moduleName","name"]},"description":"Global function scripts of the module, in name order"}},"required":["data"]}}}}
```

## The UpdateModuleScriptBody object

```json
{"openapi":"3.0.0","info":{"title":"Ninox Public API","version":"1.0.0"},"components":{"schemas":{"UpdateModuleScriptBody":{"type":"object","properties":{"code":{"type":"string","description":"Function definitions only, callable from every script of the module. Needs schema:write plus records:write"},"name":{"type":"string","minLength":1,"maxLength":100,"description":"Script name, scripts compile in name order"}},"additionalProperties":false}}}}
```

## The CreateReportBody object

```json
{"openapi":"3.0.0","info":{"title":"Ninox Public API","version":"1.0.0"},"components":{"schemas":{"CreateReportBody":{"type":"object","properties":{"fontFamily":{"description":"Default font family","type":"string"},"fontSize":{"description":"Default font size","type":"number"},"footHeight":{"default":20,"description":"Footer height","type":"number"},"headHeight":{"default":20,"description":"Header height","type":"number"},"inlineStyle":{"description":"Inline CSS applied to the report","type":"string"},"labels":{"description":"Report labels (localized)","type":"object","additionalProperties":{"type":"string","minLength":1,"maxLength":100}},"marginB":{"default":20,"description":"Bottom page margin","type":"number"},"marginL":{"default":20,"description":"Left page margin","type":"number"},"marginR":{"default":20,"description":"Right page margin","type":"number"},"marginT":{"default":20,"description":"Top page margin","type":"number"},"name":{"type":"string","minLength":1,"maxLength":100,"description":"Report name"},"objects":{"description":"Report layout objects. Omit to auto-generate a layout from the table’s current fields.","type":"array","items":{"type":"object","properties":{"backgroundColor":{"description":"Background color (hex string)","type":"string"},"base":{"type":"string","enum":["html","image","imagefield","rev","text"],"description":"Report object kind"},"borderColor":{"description":"Border color (hex string)","type":"string"},"borderRadius":{"description":"Border radius","type":"number"},"borderStyle":{"description":"Border style","type":"string"},"borderWidth":{"description":"Border width","type":"number"},"expression":{"description":"Reverse field name this object displays, for rev objects","type":"string"},"fid":{"description":"Field name, for imagefield objects","type":"string"},"file":{"description":"File id, for image objects","type":"string"},"fn":{"description":"Bound expression producing HTML, for html objects","type":"string"},"fontFamily":{"description":"Font family","type":"string"},"fontSize":{"description":"Font size","type":"number"},"fontStyle":{"description":"Font style","type":"string","enum":["italic"]},"fontWeight":{"description":"Font weight","type":"string","enum":["bold"]},"h":{"type":"number","description":"Height"},"id":{"description":"Stable identity of the object; send it back unchanged when updating the report","type":"string"},"isAutoHeight":{"description":"Auto-size height to content, for html objects","type":"boolean"},"lineHeight":{"description":"Line height, for text objects","type":"number"},"paddingB":{"description":"Bottom padding, for html/rev/text objects","type":"number"},"paddingL":{"description":"Left padding, for html/rev/text objects","type":"number"},"paddingR":{"description":"Right padding, for html/rev/text objects","type":"number"},"paddingT":{"description":"Top padding, for html/rev/text objects","type":"number"},"position":{"type":"string","enum":["foot","head","page"],"description":"Report section this object belongs to"},"showFoot":{"description":"Show table footer, for rev objects","type":"boolean"},"showHead":{"description":"Show table header, for rev objects","type":"boolean"},"tableBorderStyle":{"description":"Table border style, for rev objects","anyOf":[{"type":"number","enum":[0]},{"type":"number","enum":[1]},{"type":"number","enum":[2]},{"type":"number","enum":[3]},{"type":"number","enum":[4]},{"type":"number","enum":[5]},{"type":"number","enum":[6]}]},"text":{"description":"Literal text, for text objects","type":"string"},"textAlign":{"description":"Text alignment","type":"string","enum":["center","left","right"]},"textColor":{"description":"Text color (hex string)","type":"string"},"textDecoration":{"description":"Text decoration","type":"string","enum":["underline"]},"verticalAlign":{"description":"Vertical alignment, for html/text objects","type":"string"},"viewConfig":{"description":"Columns/filter/sort for the underlying table, for rev objects","type":"object","properties":{"columns":{"type":"array","items":{"type":"object","properties":{"agg":{"description":"Aggregation function applied to the column","type":"string"},"conditionalStyling":{"description":"Legacy per-column conditional styling rules","type":"array","items":{"type":"object","properties":{"background":{"description":"Background color (hex string)","type":"string"},"cell":{"description":"Target cell","type":"string"},"color":{"description":"Icon color (hex string)","type":"string"},"icon":{"description":"Icon name","type":"string"},"operand":{"type":"string","description":"Comparator"},"value":{"type":"string","description":"Value compared against"}},"required":["operand","value"]}},"field":{"type":"string","description":"Field name, or a script expression for a calculated column"},"hidden":{"description":"Column retained but hidden from the grid","type":"boolean"},"id":{"description":"Stable identity of a calculated column; send it back unchanged when updating the view","type":"string"},"labels":{"description":"Column labels (localized)","type":"object","additionalProperties":{"type":"string"}},"order":{"type":"number","description":"Column display order"},"role":{"description":"Column role (e.g. title, date, image, location, color)","type":"string"},"width":{"description":"Column width","type":"number"}},"required":["field","order"]},"description":"Sub-table columns"},"conditionalFormatting":{"description":"Conditional formatting rules","type":"array","items":{"type":"object","properties":{"backgroundColor":{"description":"Background color (hex string)","type":"string"},"bold":{"description":"Bold text","type":"boolean"},"comparator":{"type":"string","enum":["contains","does_not_contain","ends_with","gt","gte","is","is_empty","is_not","is_not_empty","logic","lt","lte","starts_with"],"description":"Comparator"},"expression":{"description":"Script expression, used only when comparator is 'logic'","type":"string"},"fieldName":{"type":"string","description":"Target field name"},"highlightColor":{"description":"Highlight color (hex string)","type":"string"},"icon":{"description":"Icon","type":"object","properties":{"color":{"description":"Icon color (hex string)","type":"string"},"filling":{"description":"Icon filling","anyOf":[{"type":"number","enum":[0]},{"type":"number","enum":[1]}]},"icon":{"type":"string","description":"Icon name"}},"required":["icon"]},"id":{"type":"string","description":"Stable rule id"},"italic":{"description":"Italic text","type":"boolean"},"order":{"type":"number","description":"Rule evaluation order"},"strikethrough":{"description":"Strikethrough text","type":"boolean"},"target":{"type":"string","enum":["cell","row"],"description":"Whether the rule styles a single cell or the whole row"},"textColor":{"description":"Text color (hex string)","type":"string"},"value":{"description":"Value compared against"}},"required":["comparator","fieldName","id","order","target"]}},"filter":{"description":"Stored filter conditions","type":"array","items":{"type":"object","properties":{"field":{"description":"Field name","type":"string"},"id":{"type":"string","description":"Stable condition id"},"operator":{"description":"Filter operator","type":"string"},"value":{"description":"Value compared against","type":"string"}},"required":["id"]}},"groupBy":{"description":"Grouping configuration","type":"array","items":{"type":"object","properties":{"direction":{"description":"Group order direction, defaults to ascending","type":"string","enum":["asc","desc"]},"fieldName":{"type":"string","description":"Field name"}},"required":["fieldName"]}},"search":{"description":"Stored search term","type":"string"},"sort":{"description":"Sort configuration","type":"object","properties":{"direction":{"type":"string","enum":["asc","desc"],"description":"Sort direction"},"fieldName":{"type":"string","description":"Field name"}},"required":["direction","fieldName"]},"viewType":{"type":"string","enum":["Calendar","Chart","Gallery","Gantt","Kanban","List","Maps","Pivot","Table"],"description":"Sub-table view type"}},"required":["columns","viewType"]},"w":{"type":"number","description":"Width"},"x":{"type":"number","description":"X position"},"y":{"type":"number","description":"Y position"}},"required":["base","h","position","w","x","y"]}},"paperHeight":{"default":297,"description":"Paper height","type":"number"},"paperWidth":{"default":210,"description":"Paper width","type":"number"},"printAttachments":{"description":"Include row attachments when printing","type":"boolean"}},"required":["name"],"additionalProperties":false}}}}
```

## The ReportResponse object

```json
{"openapi":"3.0.0","info":{"title":"Ninox Public API","version":"1.0.0"},"components":{"schemas":{"ReportResponse":{"type":"object","properties":{"data":{"type":"object","properties":{"fontFamily":{"description":"Default font family","type":"string"},"fontSize":{"description":"Default font size","type":"number"},"footHeight":{"type":"number","description":"Footer height"},"headHeight":{"type":"number","description":"Header height"},"id":{"type":"string","description":"Report id"},"inlineStyle":{"description":"Inline CSS applied to the report","type":"string"},"labels":{"description":"Report labels (localized)","type":"object","additionalProperties":{"type":"string"}},"marginB":{"type":"number","description":"Bottom page margin"},"marginL":{"type":"number","description":"Left page margin"},"marginR":{"type":"number","description":"Right page margin"},"marginT":{"type":"number","description":"Top page margin"},"moduleName":{"type":"string","description":"Module name"},"name":{"type":"string","description":"Report name"},"objects":{"type":"array","items":{"type":"object","properties":{"backgroundColor":{"description":"Background color (hex string)","type":"string"},"base":{"type":"string","enum":["html","image","imagefield","rev","text"],"description":"Report object kind"},"borderColor":{"description":"Border color (hex string)","type":"string"},"borderRadius":{"description":"Border radius","type":"number"},"borderStyle":{"description":"Border style","type":"string"},"borderWidth":{"description":"Border width","type":"number"},"expression":{"description":"Reverse field name this object displays, for rev objects","type":"string"},"fid":{"description":"Field name, for imagefield objects","type":"string"},"file":{"description":"File id, for image objects","type":"string"},"fn":{"description":"Bound expression producing HTML, for html objects","type":"string"},"fontFamily":{"description":"Font family","type":"string"},"fontSize":{"description":"Font size","type":"number"},"fontStyle":{"description":"Font style","type":"string","enum":["italic"]},"fontWeight":{"description":"Font weight","type":"string","enum":["bold"]},"h":{"type":"number","description":"Height"},"id":{"description":"Stable identity of the object; send it back unchanged when updating the report","type":"string"},"isAutoHeight":{"description":"Auto-size height to content, for html objects","type":"boolean"},"lineHeight":{"description":"Line height, for text objects","type":"number"},"paddingB":{"description":"Bottom padding, for html/rev/text objects","type":"number"},"paddingL":{"description":"Left padding, for html/rev/text objects","type":"number"},"paddingR":{"description":"Right padding, for html/rev/text objects","type":"number"},"paddingT":{"description":"Top padding, for html/rev/text objects","type":"number"},"position":{"type":"string","enum":["foot","head","page"],"description":"Report section this object belongs to"},"showFoot":{"description":"Show table footer, for rev objects","type":"boolean"},"showHead":{"description":"Show table header, for rev objects","type":"boolean"},"tableBorderStyle":{"description":"Table border style, for rev objects","anyOf":[{"type":"number","enum":[0]},{"type":"number","enum":[1]},{"type":"number","enum":[2]},{"type":"number","enum":[3]},{"type":"number","enum":[4]},{"type":"number","enum":[5]},{"type":"number","enum":[6]}]},"text":{"description":"Literal text, for text objects","type":"string"},"textAlign":{"description":"Text alignment","type":"string","enum":["center","left","right"]},"textColor":{"description":"Text color (hex string)","type":"string"},"textDecoration":{"description":"Text decoration","type":"string","enum":["underline"]},"verticalAlign":{"description":"Vertical alignment, for html/text objects","type":"string"},"viewConfig":{"description":"Columns/filter/sort for the underlying table, for rev objects","type":"object","properties":{"columns":{"type":"array","items":{"type":"object","properties":{"agg":{"description":"Aggregation function applied to the column","type":"string"},"conditionalStyling":{"description":"Legacy per-column conditional styling rules","type":"array","items":{"type":"object","properties":{"background":{"description":"Background color (hex string)","type":"string"},"cell":{"description":"Target cell","type":"string"},"color":{"description":"Icon color (hex string)","type":"string"},"icon":{"description":"Icon name","type":"string"},"operand":{"type":"string","description":"Comparator"},"value":{"type":"string","description":"Value compared against"}},"required":["operand","value"]}},"field":{"type":"string","description":"Field name, or a script expression for a calculated column"},"hidden":{"description":"Column retained but hidden from the grid","type":"boolean"},"id":{"description":"Stable identity of a calculated column; send it back unchanged when updating the view","type":"string"},"labels":{"description":"Column labels (localized)","type":"object","additionalProperties":{"type":"string"}},"order":{"type":"number","description":"Column display order"},"role":{"description":"Column role (e.g. title, date, image, location, color)","type":"string"},"width":{"description":"Column width","type":"number"}},"required":["field","order"]},"description":"Sub-table columns"},"conditionalFormatting":{"description":"Conditional formatting rules","type":"array","items":{"type":"object","properties":{"backgroundColor":{"description":"Background color (hex string)","type":"string"},"bold":{"description":"Bold text","type":"boolean"},"comparator":{"type":"string","enum":["contains","does_not_contain","ends_with","gt","gte","is","is_empty","is_not","is_not_empty","logic","lt","lte","starts_with"],"description":"Comparator"},"expression":{"description":"Script expression, used only when comparator is 'logic'","type":"string"},"fieldName":{"type":"string","description":"Target field name"},"highlightColor":{"description":"Highlight color (hex string)","type":"string"},"icon":{"description":"Icon","type":"object","properties":{"color":{"description":"Icon color (hex string)","type":"string"},"filling":{"description":"Icon filling","anyOf":[{"type":"number","enum":[0]},{"type":"number","enum":[1]}]},"icon":{"type":"string","description":"Icon name"}},"required":["icon"]},"id":{"type":"string","description":"Stable rule id"},"italic":{"description":"Italic text","type":"boolean"},"order":{"type":"number","description":"Rule evaluation order"},"strikethrough":{"description":"Strikethrough text","type":"boolean"},"target":{"type":"string","enum":["cell","row"],"description":"Whether the rule styles a single cell or the whole row"},"textColor":{"description":"Text color (hex string)","type":"string"},"value":{"description":"Value compared against"}},"required":["comparator","fieldName","id","order","target"]}},"filter":{"description":"Stored filter conditions","type":"array","items":{"type":"object","properties":{"field":{"description":"Field name","type":"string"},"id":{"type":"string","description":"Stable condition id"},"operator":{"description":"Filter operator","type":"string"},"value":{"description":"Value compared against","type":"string"}},"required":["id"]}},"groupBy":{"description":"Grouping configuration","type":"array","items":{"type":"object","properties":{"direction":{"description":"Group order direction, defaults to ascending","type":"string","enum":["asc","desc"]},"fieldName":{"type":"string","description":"Field name"}},"required":["fieldName"]}},"search":{"description":"Stored search term","type":"string"},"sort":{"description":"Sort configuration","type":"object","properties":{"direction":{"type":"string","enum":["asc","desc"],"description":"Sort direction"},"fieldName":{"type":"string","description":"Field name"}},"required":["direction","fieldName"]},"viewType":{"type":"string","enum":["Calendar","Chart","Gallery","Gantt","Kanban","List","Maps","Pivot","Table"],"description":"Sub-table view type"}},"required":["columns","viewType"]},"w":{"type":"number","description":"Width"},"x":{"type":"number","description":"X position"},"y":{"type":"number","description":"Y position"}},"required":["base","h","position","w","x","y"]},"description":"Report layout objects"},"paperHeight":{"type":"number","description":"Paper height"},"paperWidth":{"type":"number","description":"Paper width"},"printAttachments":{"description":"Include row attachments when printing","type":"boolean"},"tableName":{"type":"string","description":"Table name"}},"description":"Report details"}},"required":["data"]}}}}
```

## The ReportsResponse object

```json
{"openapi":"3.0.0","info":{"title":"Ninox Public API","version":"1.0.0"},"components":{"schemas":{"ReportsResponse":{"type":"object","properties":{"data":{"type":"array","items":{"type":"object","properties":{"fontFamily":{"description":"Default font family","type":"string"},"fontSize":{"description":"Default font size","type":"number"},"footHeight":{"type":"number","description":"Footer height"},"headHeight":{"type":"number","description":"Header height"},"id":{"type":"string","description":"Report id"},"inlineStyle":{"description":"Inline CSS applied to the report","type":"string"},"labels":{"description":"Report labels (localized)","type":"object","additionalProperties":{"type":"string"}},"marginB":{"type":"number","description":"Bottom page margin"},"marginL":{"type":"number","description":"Left page margin"},"marginR":{"type":"number","description":"Right page margin"},"marginT":{"type":"number","description":"Top page margin"},"moduleName":{"type":"string","description":"Module name"},"name":{"type":"string","description":"Report name"},"objects":{"type":"array","items":{"type":"object","properties":{"backgroundColor":{"description":"Background color (hex string)","type":"string"},"base":{"type":"string","enum":["html","image","imagefield","rev","text"],"description":"Report object kind"},"borderColor":{"description":"Border color (hex string)","type":"string"},"borderRadius":{"description":"Border radius","type":"number"},"borderStyle":{"description":"Border style","type":"string"},"borderWidth":{"description":"Border width","type":"number"},"expression":{"description":"Reverse field name this object displays, for rev objects","type":"string"},"fid":{"description":"Field name, for imagefield objects","type":"string"},"file":{"description":"File id, for image objects","type":"string"},"fn":{"description":"Bound expression producing HTML, for html objects","type":"string"},"fontFamily":{"description":"Font family","type":"string"},"fontSize":{"description":"Font size","type":"number"},"fontStyle":{"description":"Font style","type":"string","enum":["italic"]},"fontWeight":{"description":"Font weight","type":"string","enum":["bold"]},"h":{"type":"number","description":"Height"},"id":{"description":"Stable identity of the object; send it back unchanged when updating the report","type":"string"},"isAutoHeight":{"description":"Auto-size height to content, for html objects","type":"boolean"},"lineHeight":{"description":"Line height, for text objects","type":"number"},"paddingB":{"description":"Bottom padding, for html/rev/text objects","type":"number"},"paddingL":{"description":"Left padding, for html/rev/text objects","type":"number"},"paddingR":{"description":"Right padding, for html/rev/text objects","type":"number"},"paddingT":{"description":"Top padding, for html/rev/text objects","type":"number"},"position":{"type":"string","enum":["foot","head","page"],"description":"Report section this object belongs to"},"showFoot":{"description":"Show table footer, for rev objects","type":"boolean"},"showHead":{"description":"Show table header, for rev objects","type":"boolean"},"tableBorderStyle":{"description":"Table border style, for rev objects","anyOf":[{"type":"number","enum":[0]},{"type":"number","enum":[1]},{"type":"number","enum":[2]},{"type":"number","enum":[3]},{"type":"number","enum":[4]},{"type":"number","enum":[5]},{"type":"number","enum":[6]}]},"text":{"description":"Literal text, for text objects","type":"string"},"textAlign":{"description":"Text alignment","type":"string","enum":["center","left","right"]},"textColor":{"description":"Text color (hex string)","type":"string"},"textDecoration":{"description":"Text decoration","type":"string","enum":["underline"]},"verticalAlign":{"description":"Vertical alignment, for html/text objects","type":"string"},"viewConfig":{"description":"Columns/filter/sort for the underlying table, for rev objects","type":"object","properties":{"columns":{"type":"array","items":{"type":"object","properties":{"agg":{"description":"Aggregation function applied to the column","type":"string"},"conditionalStyling":{"description":"Legacy per-column conditional styling rules","type":"array","items":{"type":"object","properties":{"background":{"description":"Background color (hex string)","type":"string"},"cell":{"description":"Target cell","type":"string"},"color":{"description":"Icon color (hex string)","type":"string"},"icon":{"description":"Icon name","type":"string"},"operand":{"type":"string","description":"Comparator"},"value":{"type":"string","description":"Value compared against"}},"required":["operand","value"]}},"field":{"type":"string","description":"Field name, or a script expression for a calculated column"},"hidden":{"description":"Column retained but hidden from the grid","type":"boolean"},"id":{"description":"Stable identity of a calculated column; send it back unchanged when updating the view","type":"string"},"labels":{"description":"Column labels (localized)","type":"object","additionalProperties":{"type":"string"}},"order":{"type":"number","description":"Column display order"},"role":{"description":"Column role (e.g. title, date, image, location, color)","type":"string"},"width":{"description":"Column width","type":"number"}},"required":["field","order"]},"description":"Sub-table columns"},"conditionalFormatting":{"description":"Conditional formatting rules","type":"array","items":{"type":"object","properties":{"backgroundColor":{"description":"Background color (hex string)","type":"string"},"bold":{"description":"Bold text","type":"boolean"},"comparator":{"type":"string","enum":["contains","does_not_contain","ends_with","gt","gte","is","is_empty","is_not","is_not_empty","logic","lt","lte","starts_with"],"description":"Comparator"},"expression":{"description":"Script expression, used only when comparator is 'logic'","type":"string"},"fieldName":{"type":"string","description":"Target field name"},"highlightColor":{"description":"Highlight color (hex string)","type":"string"},"icon":{"description":"Icon","type":"object","properties":{"color":{"description":"Icon color (hex string)","type":"string"},"filling":{"description":"Icon filling","anyOf":[{"type":"number","enum":[0]},{"type":"number","enum":[1]}]},"icon":{"type":"string","description":"Icon name"}},"required":["icon"]},"id":{"type":"string","description":"Stable rule id"},"italic":{"description":"Italic text","type":"boolean"},"order":{"type":"number","description":"Rule evaluation order"},"strikethrough":{"description":"Strikethrough text","type":"boolean"},"target":{"type":"string","enum":["cell","row"],"description":"Whether the rule styles a single cell or the whole row"},"textColor":{"description":"Text color (hex string)","type":"string"},"value":{"description":"Value compared against"}},"required":["comparator","fieldName","id","order","target"]}},"filter":{"description":"Stored filter conditions","type":"array","items":{"type":"object","properties":{"field":{"description":"Field name","type":"string"},"id":{"type":"string","description":"Stable condition id"},"operator":{"description":"Filter operator","type":"string"},"value":{"description":"Value compared against","type":"string"}},"required":["id"]}},"groupBy":{"description":"Grouping configuration","type":"array","items":{"type":"object","properties":{"direction":{"description":"Group order direction, defaults to ascending","type":"string","enum":["asc","desc"]},"fieldName":{"type":"string","description":"Field name"}},"required":["fieldName"]}},"search":{"description":"Stored search term","type":"string"},"sort":{"description":"Sort configuration","type":"object","properties":{"direction":{"type":"string","enum":["asc","desc"],"description":"Sort direction"},"fieldName":{"type":"string","description":"Field name"}},"required":["direction","fieldName"]},"viewType":{"type":"string","enum":["Calendar","Chart","Gallery","Gantt","Kanban","List","Maps","Pivot","Table"],"description":"Sub-table view type"}},"required":["columns","viewType"]},"w":{"type":"number","description":"Width"},"x":{"type":"number","description":"X position"},"y":{"type":"number","description":"Y position"}},"required":["base","h","position","w","x","y"]},"description":"Report layout objects"},"paperHeight":{"type":"number","description":"Paper height"},"paperWidth":{"type":"number","description":"Paper width"},"printAttachments":{"description":"Include row attachments when printing","type":"boolean"},"tableName":{"type":"string","description":"Table name"}},"required":["footHeight","headHeight","id","marginB","marginL","marginR","marginT","moduleName","name","objects","paperHeight","paperWidth","tableName"]},"description":"List of reports"}},"required":["data"]}}}}
```

## The PrintReportBody object

```json
{"openapi":"3.0.0","info":{"title":"Ninox Public API","version":"1.0.0"},"components":{"schemas":{"PrintReportBody":{"type":"object","properties":{"rowId":{"description":"Record to render the report for","type":"integer","minimum":1,"maximum":9007199254740991},"rowIds":{"description":"Additional records to render into the same document (a merged print run). rowId is always included alongside these, so rowId plus rowIds together may not exceed 250 records.","maxItems":249,"type":"array","items":{"type":"integer","minimum":1,"maximum":9007199254740991}}},"required":["rowId"]}}}}
```

## The PrintReportResponseDto object

```json
{"openapi":"3.0.0","info":{"title":"Ninox Public API","version":"1.0.0"},"components":{"schemas":{"PrintReportResponseDto":{"type":"object","properties":{"data":{"type":"object","properties":{"fileName":{"type":"string","description":"Rendered file name"},"mimeType":{"type":"string","description":"Rendered file MIME type"},"url":{"type":"string","description":"Presigned URL to download the rendered document"}}}},"required":["data"]}}}}
```

## The AddRowsBody object

```json
{"openapi":"3.0.0","info":{"title":"Ninox Public API","version":"1.0.0"},"components":{"schemas":{"AddRowsBody":{"type":"object","properties":{"records":{"minItems":1,"type":"array","items":{"type":"object","additionalProperties":{}},"description":"Array of records to add to the target table"}},"required":["records"],"additionalProperties":false}}}}
```

## The CreateRowsResponse object

```json
{"openapi":"3.0.0","info":{"title":"Ninox Public API","version":"1.0.0"},"components":{"schemas":{"CreateRowsResponse":{"type":"object","properties":{"data":{"type":"object","properties":{"ids":{"type":"array","items":{"type":"string"},"description":"Created row ids"}}}},"required":["data"]}}}}
```

## The DeleteRowsBody object

```json
{"openapi":"3.0.0","info":{"title":"Ninox Public API","version":"1.0.0"},"components":{"schemas":{"DeleteRowsBody":{"type":"object","properties":{"records":{"minItems":1,"type":"array","items":{"type":"integer","exclusiveMinimum":true,"maximum":9007199254740991,"minimum":0},"description":"Array of record ids to delete"}},"required":["records"],"additionalProperties":false}}}}
```

## The DeleteRowsResponse object

```json
{"openapi":"3.0.0","info":{"title":"Ninox Public API","version":"1.0.0"},"components":{"schemas":{"DeleteRowsResponse":{"type":"object","properties":{"data":{"type":"object","properties":{"deletedIds":{"type":"array","items":{"type":"string"},"description":"Deleted row ids"}}}},"required":["data"]}}}}
```

## The RowResponse object

```json
{"openapi":"3.0.0","info":{"title":"Ninox Public API","version":"1.0.0"},"components":{"schemas":{"RowResponse":{"type":"object","properties":{"data":{"type":"object","properties":{"id":{"type":"string"},"values":{"type":"object","additionalProperties":{"type":["boolean","null","number","string"]}}},"description":"The requested row"}},"required":["data"]}}}}
```

## The RowChangesResponse object

```json
{"openapi":"3.0.0","info":{"title":"Ninox Public API","version":"1.0.0"},"components":{"schemas":{"RowChangesResponse":{"type":"object","properties":{"data":{"type":"array","items":{"type":"object","properties":{"changedAt":{"type":"string","description":"When the change happened (ISO 8601)"},"changeType":{"type":"string","enum":["create","delete","update"],"description":"Kind of change"},"id":{"type":"string","description":"Row id"}},"required":["changedAt","changeType","id"]},"description":"List of row changes"},"meta":{"type":"object","properties":{"asOf":{"type":"string","description":"Server timestamp to pass as `since` on the next poll"}}},"page_info":{"type":"object","properties":{"has_more":{"type":"boolean","description":"Whether more results are available"},"limit":{"type":"number","description":"Maximum results per page"},"offset":{"type":"number","description":"Current offset"}},"description":"Pagination information"}},"required":["data","meta","page_info"]}}}}
```

## The RowsResponse object

```json
{"openapi":"3.0.0","info":{"title":"Ninox Public API","version":"1.0.0"},"components":{"schemas":{"RowsResponse":{"type":"object","properties":{"data":{"type":"array","items":{"type":"object","properties":{"id":{"type":"string"},"values":{"type":"object","additionalProperties":{"type":["boolean","null","number","string"]}}},"required":["id","values"]},"description":"List of rows"},"meta":{"type":"object","properties":{"filter":{"type":"object","additionalProperties":{"type":["boolean","null","number","string"]},"description":"Applied filter conditions"},"sort":{"type":"string","description":"Applied sort field"}}},"page_info":{"type":"object","properties":{"has_more":{"type":"boolean","description":"Whether more results are available"},"limit":{"type":"number","description":"Maximum results per page"},"offset":{"type":"number","description":"Current offset"}},"description":"Pagination information"}},"required":["data","page_info"]}}}}
```

## The ImportCSVResponse object

```json
{"openapi":"3.0.0","info":{"title":"Ninox Public API","version":"1.0.0"},"components":{"schemas":{"ImportCSVResponse":{"type":"object","properties":{"data":{"type":"object","properties":{"rowsImported":{"type":"number","description":"Number of rows successfully imported"},"rowsSkipped":{"type":"number","description":"Number of rows skipped (for update mode when no match is found)"},"rowsUpdated":{"type":"number","description":"Number of existing rows updated"}}}},"required":["data"]}}}}
```

## The UpdateRowsBody object

```json
{"openapi":"3.0.0","info":{"title":"Ninox Public API","version":"1.0.0"},"components":{"schemas":{"UpdateRowsBody":{"type":"object","properties":{"records":{"minItems":1,"type":"array","items":{"type":"object","properties":{"id":{"type":"integer","exclusiveMinimum":true,"maximum":9007199254740991,"minimum":0}},"required":["id"],"additionalProperties":{}},"description":"Array of records to update (each must include an id field as a positive integer)"}},"required":["records"],"additionalProperties":false}}}}
```

## The UpdateRowsResponse object

```json
{"openapi":"3.0.0","info":{"title":"Ninox Public API","version":"1.0.0"},"components":{"schemas":{"UpdateRowsResponse":{"type":"object","properties":{"data":{"type":"object","properties":{"updatedIds":{"type":"array","items":{"type":"string"},"description":"Updated row ids"}}}},"required":["data"]}}}}
```

## The UpsertRowsBody object

```json
{"openapi":"3.0.0","info":{"title":"Ninox Public API","version":"1.0.0"},"components":{"schemas":{"UpsertRowsBody":{"type":"object","properties":{"matchField":{"type":"string","minLength":1,"description":"Name of the unique field used to match existing records"},"records":{"minItems":1,"type":"array","items":{"type":"object","additionalProperties":{}},"description":"Array of records to upsert — each must include a value for matchField"}},"required":["matchField","records"],"additionalProperties":false}}}}
```

## The UpsertRowsResponse object

```json
{"openapi":"3.0.0","info":{"title":"Ninox Public API","version":"1.0.0"},"components":{"schemas":{"UpsertRowsResponse":{"type":"object","properties":{"data":{"type":"object","properties":{"createdIds":{"type":"array","items":{"type":"string"},"description":"Row ids created by this upsert"},"updatedIds":{"type":"array","items":{"type":"string"},"description":"Row ids matched and updated by this upsert"}}}},"required":["data"]}}}}
```

## The ExecScriptBody object

```json
{"openapi":"3.0.0","info":{"title":"Ninox Public API","version":"1.0.0"},"components":{"schemas":{"ExecScriptBody":{"type":"object","properties":{"moduleName":{"type":"string","minLength":1,"maxLength":100,"pattern":"^[a-z0-9_]+$","description":"Module name — `do as database` is confined to this module"},"rowId":{"description":"Record the script evaluates against","type":"integer","minimum":1,"maximum":9007199254740991},"script":{"type":"string","description":"Script to execute (system format)"},"tableName":{"description":"Table name","type":"string","minLength":1,"maxLength":100,"pattern":"^[a-z0-9_]+$"}},"required":["moduleName","script"]}}}}
```

## The ExecResponseDto object

```json
{"openapi":"3.0.0","info":{"title":"Ninox Public API","version":"1.0.0"},"components":{"schemas":{"ExecResponseDto":{"type":"object","properties":{"data":{"description":"The script expression's result"}},"required":["data"]}}}}
```

## The CreateTableBody object

```json
{"openapi":"3.0.0","info":{"title":"Ninox Public API","version":"1.0.0"},"components":{"schemas":{"CreateTableBody":{"type":"object","properties":{"icon":{"description":"Table icon","type":"object","properties":{"color":{"type":"string"},"filling":{"anyOf":[{"type":"number","enum":[0]},{"type":"number","enum":[1]}]},"icon":{"type":"string","minLength":1}}},"labels":{"type":"object","additionalProperties":{"type":"string","minLength":1,"maxLength":100},"description":"Table labels (localized)"},"name":{"type":"string","minLength":1,"maxLength":100,"pattern":"^[a-z0-9_]+$","description":"Table name"},"canCreate":{"description":"Script expression that must allow creating a record","type":"string","minLength":1},"canDelete":{"description":"Script expression that must allow deleting a record","type":"string","minLength":1},"canRead":{"description":"Script expression that must allow reading a record","type":"string","minLength":1},"canWrite":{"description":"Script expression that must allow updating a record","type":"string","minLength":1},"createRoles":{"description":"Roles allowed to create records","minItems":1,"maxItems":2,"type":"array","items":{"type":"string","enum":["admin","editor"]}},"deleteRoles":{"description":"Roles allowed to delete records","minItems":1,"maxItems":2,"type":"array","items":{"type":"string","enum":["admin","editor"]}},"hasFiles":{"description":"Enable files for the table","type":"boolean"},"hasGlobalSearch":{"description":"Enable global search for the table","type":"boolean"},"hasHistory":{"description":"Enable history for the table","type":"boolean"},"isEmailLinkingEnabled":{"description":"Enable email linking for the table","type":"boolean"},"isHidden":{"description":"Hide the table","type":"boolean"},"onCreate":{"description":"Script expression run as a trigger after a record is created","type":"string"},"onDelete":{"description":"Script expression run as a trigger when a record is deleted","type":"string"},"onUpdate":{"description":"Script expression run as a trigger after a record is updated","type":"string"},"readRoles":{"description":"Roles allowed to read records","minItems":1,"maxItems":2,"type":"array","items":{"type":"string","enum":["admin","editor"]}},"writeRoles":{"description":"Roles allowed to update records","minItems":1,"maxItems":2,"type":"array","items":{"type":"string","enum":["admin","editor"]}}},"required":["labels","name"]}}}}
```

## The TableResponse object

```json
{"openapi":"3.0.0","info":{"title":"Ninox Public API","version":"1.0.0"},"components":{"schemas":{"TableResponse":{"type":"object","properties":{"data":{"type":"object","properties":{"canCreate":{"description":"Script expression gating record creation","type":"string"},"canDelete":{"description":"Script expression gating record deletion","type":"string"},"canRead":{"description":"Script expression gating record read access","type":"string"},"canWrite":{"description":"Script expression gating record write access","type":"string"},"createRoles":{"description":"Roles allowed to create records","type":"array","items":{"type":"string"}},"deleteRoles":{"description":"Roles allowed to delete records","type":"array","items":{"type":"string"}},"fields":{"type":"array","items":{"type":"object","properties":{"binding":{"description":"Read-only: internal binding reference, format not yet specified","type":"string"},"canRead":{"description":"Script expression gating field-level read access","type":"string"},"canWrite":{"description":"Script expression gating field-level write access","type":"string"},"defaultValue":{"description":"Default value applied when a record is created: a literal value (an array of option ids for multi/dmulti), or a script expression (as { $nx: <script> }) evaluated at creation time","anyOf":[{"type":"object","properties":{"$nx":{"type":"string","description":"Script expression. Writing one needs records:write as well as schema:write"}},"required":["$nx"]},{"type":["boolean","null","number","string"]},{"type":"array","items":{"type":"string"}}]},"expression":{"description":"Expression (for function type)","type":"string"},"index":{"description":"Field is indexed","type":"boolean"},"labels":{"description":"Field labels (localized)","type":"object","additionalProperties":{"type":"string"}},"name":{"type":"string","description":"Field name"},"onUpdate":{"description":"Script expression run as a row trigger when the field value changes","type":"string"},"optionColor":{"description":"Color expression for dchoice/dmulti fields","type":"string"},"optionIcon":{"description":"Icon expression for dchoice/dmulti fields","type":"string"},"optionName":{"description":"Display name expression for dchoice/dmulti fields","type":"string"},"options":{"description":"Options array for choice/multi fields, or selection expression for dchoice/dmulti fields","anyOf":[{"type":"array","items":{"type":"object","properties":{"color":{"description":"Option color (hex string)","type":"string"},"icon":{"description":"Option icon name","type":"string"},"id":{"type":"string","description":"Option id, a string the caller can set and change"},"label":{"type":"string","description":"Option text in the default language"},"labels":{"description":"Option text per language","type":"object","additionalProperties":{"type":"string"}},"order":{"type":"number","description":"Option display order"},"textColor":{"description":"Option text color (hex string)","type":"string"}},"required":["id","label","order"]}},{"type":"string"}]},"readRoles":{"description":"Roles allowed to read the field","type":"array","items":{"type":"string"}},"refTableName":{"description":"Reference table name","type":"string"},"required":{"description":"Field is required","type":"boolean"},"search":{"description":"Field is searchable","type":"boolean"},"syncedFrom":{"description":"Source column this field syncs from. Read-only unless the table has two-way sync with updates enabled, in which case every synced field except the key column is writable.","type":"string"},"type":{"type":"string","enum":["any","appointment","boolean","choice","color","date","dchoice","dmulti","file","function","html","icon","lambda","multi","number","react","reference","reverse","rowId","string","styled","time","timeinterval","timestamp","unknown","user","void"],"description":"Field type"},"unique":{"description":"Field is unique","type":"boolean"},"variant":{"description":"Field variant (for string type)","type":"string"},"writeRoles":{"description":"Roles allowed to write to the field","type":"array","items":{"type":"string"}}},"required":["name","type"]}},"hasFiles":{"description":"Enable files for the table","type":"boolean"},"hasGlobalSearch":{"description":"Enable global search for the table","type":"boolean"},"hasHistory":{"description":"Enable history for the table","type":"boolean"},"icon":{"description":"Table icon","type":"object","properties":{"color":{"description":"Icon color (hex string)","type":"string"},"filling":{"description":"Icon filling","anyOf":[{"type":"number","enum":[0]},{"type":"number","enum":[1]}]},"icon":{"type":"string","description":"Icon name"}},"required":["icon"]},"isEmailLinkingEnabled":{"description":"Enable email linking for the table","type":"boolean"},"isHidden":{"description":"Hide the table","type":"boolean"},"labels":{"description":"Table labels (localized)","type":"object","additionalProperties":{"type":"string"}},"name":{"type":"string"},"onCreate":{"description":"Script expression run as a trigger after a record is created","type":"string"},"onDelete":{"description":"Script expression run as a trigger when a record is deleted","type":"string"},"onUpdate":{"description":"Script expression run as a trigger after a record is updated","type":"string"},"readRoles":{"description":"Roles allowed to read records","type":"array","items":{"type":"string"}},"writeRoles":{"description":"Roles allowed to update records","type":"array","items":{"type":"string"}}},"description":"Table details"}},"required":["data"]}}}}
```

## The DeleteTableResponse object

```json
{"openapi":"3.0.0","info":{"title":"Ninox Public API","version":"1.0.0"},"components":{"schemas":{"DeleteTableResponse":{"type":"object","properties":{"data":{"type":"object","properties":{"id":{"type":"string","description":"Deleted table id"}}}},"required":["data"]}}}}
```

## The TablesResponse object

```json
{"openapi":"3.0.0","info":{"title":"Ninox Public API","version":"1.0.0"},"components":{"schemas":{"TablesResponse":{"type":"object","properties":{"data":{"type":"array","items":{"type":"object","properties":{"canCreate":{"description":"Script expression gating record creation","type":"string"},"canDelete":{"description":"Script expression gating record deletion","type":"string"},"canRead":{"description":"Script expression gating record read access","type":"string"},"canWrite":{"description":"Script expression gating record write access","type":"string"},"createRoles":{"description":"Roles allowed to create records","type":"array","items":{"type":"string"}},"deleteRoles":{"description":"Roles allowed to delete records","type":"array","items":{"type":"string"}},"fields":{"type":"array","items":{"type":"object","properties":{"binding":{"description":"Read-only: internal binding reference, format not yet specified","type":"string"},"canRead":{"description":"Script expression gating field-level read access","type":"string"},"canWrite":{"description":"Script expression gating field-level write access","type":"string"},"defaultValue":{"description":"Default value applied when a record is created: a literal value (an array of option ids for multi/dmulti), or a script expression (as { $nx: <script> }) evaluated at creation time","anyOf":[{"type":"object","properties":{"$nx":{"type":"string","description":"Script expression. Writing one needs records:write as well as schema:write"}},"required":["$nx"]},{"type":["boolean","null","number","string"]},{"type":"array","items":{"type":"string"}}]},"expression":{"description":"Expression (for function type)","type":"string"},"index":{"description":"Field is indexed","type":"boolean"},"labels":{"description":"Field labels (localized)","type":"object","additionalProperties":{"type":"string"}},"name":{"type":"string","description":"Field name"},"onUpdate":{"description":"Script expression run as a row trigger when the field value changes","type":"string"},"optionColor":{"description":"Color expression for dchoice/dmulti fields","type":"string"},"optionIcon":{"description":"Icon expression for dchoice/dmulti fields","type":"string"},"optionName":{"description":"Display name expression for dchoice/dmulti fields","type":"string"},"options":{"description":"Options array for choice/multi fields, or selection expression for dchoice/dmulti fields","anyOf":[{"type":"array","items":{"type":"object","properties":{"color":{"description":"Option color (hex string)","type":"string"},"icon":{"description":"Option icon name","type":"string"},"id":{"type":"string","description":"Option id, a string the caller can set and change"},"label":{"type":"string","description":"Option text in the default language"},"labels":{"description":"Option text per language","type":"object","additionalProperties":{"type":"string"}},"order":{"type":"number","description":"Option display order"},"textColor":{"description":"Option text color (hex string)","type":"string"}},"required":["id","label","order"]}},{"type":"string"}]},"readRoles":{"description":"Roles allowed to read the field","type":"array","items":{"type":"string"}},"refTableName":{"description":"Reference table name","type":"string"},"required":{"description":"Field is required","type":"boolean"},"search":{"description":"Field is searchable","type":"boolean"},"syncedFrom":{"description":"Source column this field syncs from. Read-only unless the table has two-way sync with updates enabled, in which case every synced field except the key column is writable.","type":"string"},"type":{"type":"string","enum":["any","appointment","boolean","choice","color","date","dchoice","dmulti","file","function","html","icon","lambda","multi","number","react","reference","reverse","rowId","string","styled","time","timeinterval","timestamp","unknown","user","void"],"description":"Field type"},"unique":{"description":"Field is unique","type":"boolean"},"variant":{"description":"Field variant (for string type)","type":"string"},"writeRoles":{"description":"Roles allowed to write to the field","type":"array","items":{"type":"string"}}},"required":["name","type"]}},"hasFiles":{"description":"Enable files for the table","type":"boolean"},"hasGlobalSearch":{"description":"Enable global search for the table","type":"boolean"},"hasHistory":{"description":"Enable history for the table","type":"boolean"},"icon":{"description":"Table icon","type":"object","properties":{"color":{"description":"Icon color (hex string)","type":"string"},"filling":{"description":"Icon filling","anyOf":[{"type":"number","enum":[0]},{"type":"number","enum":[1]}]},"icon":{"type":"string","description":"Icon name"}},"required":["icon"]},"isEmailLinkingEnabled":{"description":"Enable email linking for the table","type":"boolean"},"isHidden":{"description":"Hide the table","type":"boolean"},"labels":{"description":"Table labels (localized)","type":"object","additionalProperties":{"type":"string"}},"name":{"type":"string"},"onCreate":{"description":"Script expression run as a trigger after a record is created","type":"string"},"onDelete":{"description":"Script expression run as a trigger when a record is deleted","type":"string"},"onUpdate":{"description":"Script expression run as a trigger after a record is updated","type":"string"},"readRoles":{"description":"Roles allowed to read records","type":"array","items":{"type":"string"}},"writeRoles":{"description":"Roles allowed to update records","type":"array","items":{"type":"string"}}},"required":["name"]},"description":"List of tables"},"page_info":{"type":"object","properties":{"has_more":{"type":"boolean","description":"Whether more results are available"},"limit":{"type":"number","description":"Maximum results per page"},"offset":{"type":"number","description":"Current offset"}},"description":"Pagination information"}},"required":["data","page_info"]}}}}
```

## The UpdateTableBody object

```json
{"openapi":"3.0.0","info":{"title":"Ninox Public API","version":"1.0.0"},"components":{"schemas":{"UpdateTableBody":{"type":"object","properties":{"icon":{"description":"Table icon","type":"object","properties":{"color":{"type":"string"},"filling":{"anyOf":[{"type":"number","enum":[0]},{"type":"number","enum":[1]}]},"icon":{"type":"string","minLength":1}}},"labels":{"type":"object","additionalProperties":{"type":"string","minLength":1,"maxLength":100},"description":"Table labels (localized)"},"name":{"type":"string","minLength":1,"maxLength":100,"pattern":"^[a-z0-9_]+$","description":"Table name"},"canCreate":{"type":"string","minLength":1,"description":"Script expression that must allow creating a record; null removes the guard","nullable":true},"canDelete":{"type":"string","minLength":1,"description":"Script expression that must allow deleting a record; null removes the guard","nullable":true},"canRead":{"type":"string","minLength":1,"description":"Script expression that must allow reading a record; null removes the guard","nullable":true},"canWrite":{"type":"string","minLength":1,"description":"Script expression that must allow updating a record; null removes the guard","nullable":true},"createRoles":{"description":"Roles allowed to create records","minItems":1,"maxItems":2,"type":"array","items":{"type":"string","enum":["admin","editor"]}},"deleteRoles":{"description":"Roles allowed to delete records","minItems":1,"maxItems":2,"type":"array","items":{"type":"string","enum":["admin","editor"]}},"hasFiles":{"description":"Enable files for the table","type":"boolean"},"hasGlobalSearch":{"description":"Enable global search for the table","type":"boolean"},"hasHistory":{"description":"Enable history for the table","type":"boolean"},"isEmailLinkingEnabled":{"description":"Enable email linking for the table","type":"boolean"},"isHidden":{"description":"Hide the table","type":"boolean"},"onCreate":{"description":"Script expression run as a trigger after a record is created","type":"string"},"onDelete":{"description":"Script expression run as a trigger when a record is deleted","type":"string"},"onUpdate":{"description":"Script expression run as a trigger after a record is updated","type":"string"},"readRoles":{"description":"Roles allowed to read records","minItems":1,"maxItems":2,"type":"array","items":{"type":"string","enum":["admin","editor"]}},"writeRoles":{"description":"Roles allowed to update records","minItems":1,"maxItems":2,"type":"array","items":{"type":"string","enum":["admin","editor"]}}}}}}}
```

## The CreateViewBody object

```json
{"openapi":"3.0.0","info":{"title":"Ninox Public API","version":"1.0.0"},"components":{"schemas":{"CreateViewBody":{"type":"object","properties":{"annualRecurring":{"description":"Calendar views only: render every record on the same day/month every year","type":"boolean"},"chartConfig":{"description":"Chart views: chart type, axes and data series","type":"object","properties":{"chartType":{"type":"string","enum":["bar","line","pie","funnel","ranking","board"]},"dataSets":{"type":"array","items":{"type":"object","properties":{"aggregation":{"type":"string","enum":["average","count","max","median","min","none","sum"]},"color":{"description":"Series color (hex string)","type":"string"},"fieldName":{"description":"Field name this series reads from","type":"string"},"labels":{"description":"Series labels (localized)","type":"object","additionalProperties":{"type":"string"}}}}},"donut":{"type":"boolean"},"labelPosition":{"type":"string","enum":["bottom","center","inside","outside","top"]},"legend":{"type":"object","properties":{"show":{"type":"boolean"}}},"limit":{"description":"ranking only: how many categories it shows","type":"integer","minimum":1,"maximum":20},"orientation":{"type":"string","enum":["horizontal","vertical"]},"showDataTable":{"type":"boolean"},"showLabels":{"type":"boolean"},"showPoints":{"type":"boolean"},"showTitle":{"type":"boolean"},"smooth":{"type":"boolean"},"stacked":{"type":"boolean"},"style":{"type":"string","enum":["default","half_donut","pad_angle","rounded_corner"]},"tooltips":{"type":"object","properties":{"show":{"type":"boolean"}}},"xAxis":{"type":"object","properties":{"fieldName":{"description":"X-axis field name, null removes it","type":["string","null"]},"groupBy":{"type":"string","enum":["daily","monthly","none","quarterly","weekly","yearly"]},"show":{"type":"boolean"}}},"yAxis":{"type":"object","properties":{"show":{"type":"boolean"}}}}},"columns":{"minItems":1,"type":"array","items":{"type":"object","properties":{"agg":{"description":"Aggregation function applied to the column","type":"string"},"conditionalStyling":{"description":"Legacy per-column conditional styling rules","type":"array","items":{"type":"object","properties":{"background":{"description":"Background color (hex string)","type":"string"},"cell":{"description":"Target cell","type":"string"},"color":{"description":"Icon color (hex string)","type":"string"},"icon":{"description":"Icon name","type":"string"},"operand":{"type":"string","description":"Comparator"},"value":{"type":"string","description":"Value compared against"}},"required":["operand","value"]}},"field":{"type":"string","description":"Field name, or a script expression for a calculated column"},"hidden":{"description":"Column retained but hidden from the grid","type":"boolean"},"id":{"description":"Stable identity of a calculated column; send it back unchanged when updating the view","type":"string"},"labels":{"description":"Column labels (localized)","type":"object","additionalProperties":{"type":"string"}},"order":{"type":"number","description":"Column display order"},"role":{"description":"Column role (e.g. title, date, image, location, color)","type":"string"},"width":{"description":"Column width","type":"number"}},"required":["field","order"]},"description":"View columns"},"conditionalFormatting":{"description":"Conditional formatting rules","type":"array","items":{"type":"object","properties":{"backgroundColor":{"description":"Background color (hex string)","type":"string"},"bold":{"description":"Bold text","type":"boolean"},"comparator":{"type":"string","enum":["contains","does_not_contain","ends_with","gt","gte","is","is_empty","is_not","is_not_empty","logic","lt","lte","starts_with"],"description":"Comparator"},"expression":{"description":"Script expression, used only when comparator is 'logic'","type":"string"},"fieldName":{"type":"string","description":"Target field name"},"highlightColor":{"description":"Highlight color (hex string)","type":"string"},"icon":{"description":"Icon","type":"object","properties":{"color":{"description":"Icon color (hex string)","type":"string"},"filling":{"description":"Icon filling","anyOf":[{"type":"number","enum":[0]},{"type":"number","enum":[1]}]},"icon":{"type":"string","description":"Icon name"}},"required":["icon"]},"id":{"type":"string","description":"Stable rule id"},"italic":{"description":"Italic text","type":"boolean"},"order":{"type":"number","description":"Rule evaluation order"},"strikethrough":{"description":"Strikethrough text","type":"boolean"},"target":{"type":"string","enum":["cell","row"],"description":"Whether the rule styles a single cell or the whole row"},"textColor":{"description":"Text color (hex string)","type":"string"},"value":{"description":"Value compared against"}},"required":["comparator","fieldName","id","order","target"]}},"filter":{"description":"Stored filter conditions","type":"array","items":{"type":"object","properties":{"field":{"description":"Field name","type":"string"},"id":{"type":"string","description":"Stable condition id"},"operator":{"description":"Filter operator","type":"string"},"value":{"description":"Value compared against","type":"string"}},"required":["id"]}},"ganttConfig":{"description":"Gantt views: which fields the bars are read from","type":"object","properties":{"baselineEndFieldName":{"description":"Planned end field, rendered as a ghost bar","type":["string","null"]},"baselineStartFieldName":{"description":"Planned start field, rendered as a ghost bar","type":["string","null"]},"dependencyDirection":{"type":"string","enum":["predecessor","successor"]},"dependencyFieldName":{"description":"A reference field pointing back at this table","type":["string","null"]},"disableDragAndDrop":{"type":"boolean"},"endFieldName":{"type":["string","null"]},"hideTitleColumn":{"type":"boolean"},"hideWeekends":{"type":"boolean"},"milestoneFieldName":{"type":["string","null"]},"progressFieldName":{"type":["string","null"]},"showCriticalPath":{"type":"boolean"},"showWeekends":{"type":"boolean"},"startFieldName":{"type":["string","null"]},"timeScale":{"type":"string","enum":["day","month","quarter","week"]},"titleColumnFieldName":{"type":["string","null"]},"titleColumnWidth":{"type":"number"}}},"groupBy":{"description":"Grouping configuration","type":"array","items":{"type":"object","properties":{"direction":{"description":"Group order direction, defaults to ascending","type":"string","enum":["asc","desc"]},"fieldName":{"type":"string","description":"Field name"}},"required":["fieldName"]}},"icon":{"description":"View icon","type":"object","properties":{"color":{"type":"string"},"filling":{"anyOf":[{"type":"number","enum":[0]},{"type":"number","enum":[1]}]},"icon":{"type":"string","minLength":1}}},"labels":{"description":"View labels (localized)","type":"object","additionalProperties":{"type":"string","minLength":1,"maxLength":100}},"name":{"type":"string","minLength":1,"maxLength":100,"pattern":"^[a-z0-9_]+$","description":"View name"},"pivot":{"description":"Pivot views: row, column and value axes","type":"object","properties":{"columns":{"type":"array","items":{"type":"object","properties":{"dateGrouping":{"description":"Date bucket, for date fields","type":"string","enum":["day","month","quarter","week","year"]},"fieldName":{"type":"string","description":"Field name"},"sort":{"type":"string","enum":["asc","desc"]}},"required":["fieldName"]},"description":"Column axis fields"},"columnWidths":{"description":"Column widths set in the pivot","type":"object","properties":{"rowHeader":{"description":"Row header width in px","type":"number"},"values":{"description":"Value column widths in px, keyed by `<fieldName>-<agg>`","type":"object","additionalProperties":{"type":"number"}}}},"rows":{"type":"array","items":{"type":"object","properties":{"dateGrouping":{"description":"Date bucket, for date fields","type":"string","enum":["day","month","quarter","week","year"]},"fieldName":{"type":"string","description":"Field name"},"sort":{"type":"string","enum":["asc","desc"]}},"required":["fieldName"]},"description":"Row axis fields"},"values":{"type":"array","items":{"type":"object","properties":{"agg":{"type":"string","enum":["avg","count","max","min","sum","unique"],"description":"Aggregation"},"fieldName":{"type":"string","description":"Field name"}},"required":["agg","fieldName"]},"description":"Aggregated value fields"}}},"search":{"description":"Stored search term","type":"string"},"sort":{"description":"Sort configuration","type":"object","properties":{"direction":{"type":"string","enum":["asc","desc"],"description":"Sort direction"},"fieldName":{"type":"string","description":"Field name"}}},"type":{"type":"string","enum":["Calendar","Chart","Gallery","Gantt","Kanban","List","Maps","Pivot","Table"],"description":"View type"}},"required":["columns","name","type"],"additionalProperties":false}}}}
```

## The ViewResponse object

```json
{"openapi":"3.0.0","info":{"title":"Ninox Public API","version":"1.0.0"},"components":{"schemas":{"ViewResponse":{"type":"object","properties":{"data":{"type":"object","properties":{"annualRecurring":{"description":"Calendar views only: render every record on the same day/month every year","type":"boolean"},"chartConfig":{"description":"Chart configuration (chart type, axes, datasets), for Chart views","type":"object","properties":{"chartType":{"type":"string","enum":["bar","line","pie","funnel","ranking","board"]},"dataSets":{"type":"array","items":{"type":"object","properties":{"aggregation":{"type":"string","enum":["average","count","max","median","min","none","sum"]},"color":{"description":"Series color (hex string)","type":"string"},"fieldName":{"description":"Field name this series reads from","type":"string"},"labels":{"description":"Series labels (localized)","type":"object","additionalProperties":{"type":"string"}}}}},"donut":{"type":"boolean"},"labelPosition":{"type":"string","enum":["bottom","center","inside","outside","top"]},"legend":{"type":"object","properties":{"show":{"type":"boolean"}}},"limit":{"description":"ranking only: how many categories it shows","type":"integer","minimum":1,"maximum":20},"orientation":{"type":"string","enum":["horizontal","vertical"]},"showDataTable":{"type":"boolean"},"showLabels":{"type":"boolean"},"showPoints":{"type":"boolean"},"showTitle":{"type":"boolean"},"smooth":{"type":"boolean"},"stacked":{"type":"boolean"},"style":{"type":"string","enum":["default","half_donut","pad_angle","rounded_corner"]},"tooltips":{"type":"object","properties":{"show":{"type":"boolean"}}},"xAxis":{"type":"object","properties":{"fieldName":{"description":"X-axis field name, null removes it","type":["string","null"]},"groupBy":{"type":"string","enum":["daily","monthly","none","quarterly","weekly","yearly"]},"show":{"type":"boolean"}}},"yAxis":{"type":"object","properties":{"show":{"type":"boolean"}}}},"required":["chartType","dataSets","xAxis"]},"columns":{"type":"array","items":{"type":"object","properties":{"agg":{"description":"Aggregation function applied to the column","type":"string"},"conditionalStyling":{"description":"Legacy per-column conditional styling rules","type":"array","items":{"type":"object","properties":{"background":{"description":"Background color (hex string)","type":"string"},"cell":{"description":"Target cell","type":"string"},"color":{"description":"Icon color (hex string)","type":"string"},"icon":{"description":"Icon name","type":"string"},"operand":{"type":"string","description":"Comparator"},"value":{"type":"string","description":"Value compared against"}},"required":["operand","value"]}},"field":{"type":"string","description":"Field name, or a script expression for a calculated column"},"hidden":{"description":"Column retained but hidden from the grid","type":"boolean"},"id":{"description":"Stable identity of a calculated column; send it back unchanged when updating the view","type":"string"},"labels":{"description":"Column labels (localized)","type":"object","additionalProperties":{"type":"string"}},"order":{"type":"number","description":"Column display order"},"role":{"description":"Column role (e.g. title, date, image, location, color)","type":"string"},"width":{"description":"Column width","type":"number"}},"required":["field","order"]},"description":"View columns"},"conditionalFormatting":{"description":"Conditional formatting rules","type":"array","items":{"type":"object","properties":{"backgroundColor":{"description":"Background color (hex string)","type":"string"},"bold":{"description":"Bold text","type":"boolean"},"comparator":{"type":"string","enum":["contains","does_not_contain","ends_with","gt","gte","is","is_empty","is_not","is_not_empty","logic","lt","lte","starts_with"],"description":"Comparator"},"expression":{"description":"Script expression, used only when comparator is 'logic'","type":"string"},"fieldName":{"type":"string","description":"Target field name"},"highlightColor":{"description":"Highlight color (hex string)","type":"string"},"icon":{"description":"Icon","type":"object","properties":{"color":{"description":"Icon color (hex string)","type":"string"},"filling":{"description":"Icon filling","anyOf":[{"type":"number","enum":[0]},{"type":"number","enum":[1]}]},"icon":{"type":"string","description":"Icon name"}},"required":["icon"]},"id":{"type":"string","description":"Stable rule id"},"italic":{"description":"Italic text","type":"boolean"},"order":{"type":"number","description":"Rule evaluation order"},"strikethrough":{"description":"Strikethrough text","type":"boolean"},"target":{"type":"string","enum":["cell","row"],"description":"Whether the rule styles a single cell or the whole row"},"textColor":{"description":"Text color (hex string)","type":"string"},"value":{"description":"Value compared against"}},"required":["comparator","fieldName","id","order","target"]}},"filter":{"description":"Stored filter conditions","type":"array","items":{"type":"object","properties":{"field":{"description":"Field name","type":"string"},"id":{"type":"string","description":"Stable condition id"},"operator":{"description":"Filter operator","type":"string"},"value":{"description":"Value compared against","type":"string"}},"required":["id"]}},"ganttConfig":{"description":"Which fields the bars/milestones/dependencies are read from, for Gantt views","type":"object","properties":{"baselineEndFieldName":{"description":"Planned end field, rendered as a ghost bar","type":["string","null"]},"baselineStartFieldName":{"description":"Planned start field, rendered as a ghost bar","type":["string","null"]},"dependencyDirection":{"type":"string","enum":["predecessor","successor"]},"dependencyFieldName":{"description":"A reference field pointing back at this table","type":["string","null"]},"disableDragAndDrop":{"type":"boolean"},"endFieldName":{"type":["string","null"]},"hideTitleColumn":{"type":"boolean"},"hideWeekends":{"type":"boolean"},"milestoneFieldName":{"type":["string","null"]},"progressFieldName":{"type":["string","null"]},"showCriticalPath":{"type":"boolean"},"showWeekends":{"type":"boolean"},"startFieldName":{"type":["string","null"]},"timeScale":{"type":"string","enum":["day","month","quarter","week"]},"titleColumnFieldName":{"type":["string","null"]},"titleColumnWidth":{"type":"number"}}},"groupBy":{"description":"Grouping configuration","type":"array","items":{"type":"object","properties":{"direction":{"description":"Group order direction, defaults to ascending","type":"string","enum":["asc","desc"]},"fieldName":{"type":"string","description":"Field name"}},"required":["fieldName"]}},"icon":{"description":"View icon","type":"object","properties":{"color":{"description":"Icon color (hex string)","type":"string"},"filling":{"description":"Icon filling","anyOf":[{"type":"number","enum":[0]},{"type":"number","enum":[1]}]},"icon":{"type":"string","description":"Icon name"}},"required":["icon"]},"id":{"type":"string","description":"View id"},"labels":{"description":"View labels (localized)","type":"object","additionalProperties":{"type":"string"}},"moduleName":{"type":"string","description":"Module name"},"name":{"type":"string","description":"View name"},"order":{"type":"number","description":"View display order"},"pivot":{"description":"Pivot configuration (row/column/value axes), for Pivot views","type":"object","properties":{"columns":{"type":"array","items":{"type":"object","properties":{"dateGrouping":{"description":"Date bucket, for date fields","type":"string","enum":["day","month","quarter","week","year"]},"fieldName":{"type":"string","description":"Field name"},"sort":{"type":"string","enum":["asc","desc"]}},"required":["fieldName"]},"description":"Column axis fields"},"columnWidths":{"description":"Column widths set in the pivot","type":"object","properties":{"rowHeader":{"description":"Row header width in px","type":"number"},"values":{"description":"Value column widths in px, keyed by `<fieldName>-<agg>`","type":"object","additionalProperties":{"type":"number"}}}},"rows":{"type":"array","items":{"type":"object","properties":{"dateGrouping":{"description":"Date bucket, for date fields","type":"string","enum":["day","month","quarter","week","year"]},"fieldName":{"type":"string","description":"Field name"},"sort":{"type":"string","enum":["asc","desc"]}},"required":["fieldName"]},"description":"Row axis fields"},"values":{"type":"array","items":{"type":"object","properties":{"agg":{"type":"string","enum":["avg","count","max","min","sum","unique"],"description":"Aggregation"},"fieldName":{"type":"string","description":"Field name"}},"required":["agg","fieldName"]},"description":"Aggregated value fields"}},"required":["columns","rows","values"]},"search":{"description":"Stored search term","type":"string"},"sort":{"description":"Sort configuration","type":"object","properties":{"direction":{"type":"string","enum":["asc","desc"],"description":"Sort direction"},"fieldName":{"type":"string","description":"Field name"}},"required":["direction","fieldName"]},"tableName":{"type":"string","description":"Table name"},"type":{"type":"string","enum":["Calendar","Chart","Gallery","Gantt","Kanban","List","Maps","Pivot","Table"],"description":"View type"}},"description":"View details"}},"required":["data"]}}}}
```

## The DeleteViewResponse object

```json
{"openapi":"3.0.0","info":{"title":"Ninox Public API","version":"1.0.0"},"components":{"schemas":{"DeleteViewResponse":{"type":"object","properties":{"data":{"type":"object","properties":{"id":{"type":"string","description":"Deleted view id"}}}},"required":["data"]}}}}
```

## The ViewsResponse object

```json
{"openapi":"3.0.0","info":{"title":"Ninox Public API","version":"1.0.0"},"components":{"schemas":{"ViewsResponse":{"type":"object","properties":{"data":{"type":"array","items":{"type":"object","properties":{"annualRecurring":{"description":"Calendar views only: render every record on the same day/month every year","type":"boolean"},"chartConfig":{"description":"Chart configuration (chart type, axes, datasets), for Chart views","type":"object","properties":{"chartType":{"type":"string","enum":["bar","line","pie","funnel","ranking","board"]},"dataSets":{"type":"array","items":{"type":"object","properties":{"aggregation":{"type":"string","enum":["average","count","max","median","min","none","sum"]},"color":{"description":"Series color (hex string)","type":"string"},"fieldName":{"description":"Field name this series reads from","type":"string"},"labels":{"description":"Series labels (localized)","type":"object","additionalProperties":{"type":"string"}}}}},"donut":{"type":"boolean"},"labelPosition":{"type":"string","enum":["bottom","center","inside","outside","top"]},"legend":{"type":"object","properties":{"show":{"type":"boolean"}}},"limit":{"description":"ranking only: how many categories it shows","type":"integer","minimum":1,"maximum":20},"orientation":{"type":"string","enum":["horizontal","vertical"]},"showDataTable":{"type":"boolean"},"showLabels":{"type":"boolean"},"showPoints":{"type":"boolean"},"showTitle":{"type":"boolean"},"smooth":{"type":"boolean"},"stacked":{"type":"boolean"},"style":{"type":"string","enum":["default","half_donut","pad_angle","rounded_corner"]},"tooltips":{"type":"object","properties":{"show":{"type":"boolean"}}},"xAxis":{"type":"object","properties":{"fieldName":{"description":"X-axis field name, null removes it","type":["string","null"]},"groupBy":{"type":"string","enum":["daily","monthly","none","quarterly","weekly","yearly"]},"show":{"type":"boolean"}}},"yAxis":{"type":"object","properties":{"show":{"type":"boolean"}}}},"required":["chartType","dataSets","xAxis"]},"columns":{"type":"array","items":{"type":"object","properties":{"agg":{"description":"Aggregation function applied to the column","type":"string"},"conditionalStyling":{"description":"Legacy per-column conditional styling rules","type":"array","items":{"type":"object","properties":{"background":{"description":"Background color (hex string)","type":"string"},"cell":{"description":"Target cell","type":"string"},"color":{"description":"Icon color (hex string)","type":"string"},"icon":{"description":"Icon name","type":"string"},"operand":{"type":"string","description":"Comparator"},"value":{"type":"string","description":"Value compared against"}},"required":["operand","value"]}},"field":{"type":"string","description":"Field name, or a script expression for a calculated column"},"hidden":{"description":"Column retained but hidden from the grid","type":"boolean"},"id":{"description":"Stable identity of a calculated column; send it back unchanged when updating the view","type":"string"},"labels":{"description":"Column labels (localized)","type":"object","additionalProperties":{"type":"string"}},"order":{"type":"number","description":"Column display order"},"role":{"description":"Column role (e.g. title, date, image, location, color)","type":"string"},"width":{"description":"Column width","type":"number"}},"required":["field","order"]},"description":"View columns"},"conditionalFormatting":{"description":"Conditional formatting rules","type":"array","items":{"type":"object","properties":{"backgroundColor":{"description":"Background color (hex string)","type":"string"},"bold":{"description":"Bold text","type":"boolean"},"comparator":{"type":"string","enum":["contains","does_not_contain","ends_with","gt","gte","is","is_empty","is_not","is_not_empty","logic","lt","lte","starts_with"],"description":"Comparator"},"expression":{"description":"Script expression, used only when comparator is 'logic'","type":"string"},"fieldName":{"type":"string","description":"Target field name"},"highlightColor":{"description":"Highlight color (hex string)","type":"string"},"icon":{"description":"Icon","type":"object","properties":{"color":{"description":"Icon color (hex string)","type":"string"},"filling":{"description":"Icon filling","anyOf":[{"type":"number","enum":[0]},{"type":"number","enum":[1]}]},"icon":{"type":"string","description":"Icon name"}},"required":["icon"]},"id":{"type":"string","description":"Stable rule id"},"italic":{"description":"Italic text","type":"boolean"},"order":{"type":"number","description":"Rule evaluation order"},"strikethrough":{"description":"Strikethrough text","type":"boolean"},"target":{"type":"string","enum":["cell","row"],"description":"Whether the rule styles a single cell or the whole row"},"textColor":{"description":"Text color (hex string)","type":"string"},"value":{"description":"Value compared against"}},"required":["comparator","fieldName","id","order","target"]}},"filter":{"description":"Stored filter conditions","type":"array","items":{"type":"object","properties":{"field":{"description":"Field name","type":"string"},"id":{"type":"string","description":"Stable condition id"},"operator":{"description":"Filter operator","type":"string"},"value":{"description":"Value compared against","type":"string"}},"required":["id"]}},"ganttConfig":{"description":"Which fields the bars/milestones/dependencies are read from, for Gantt views","type":"object","properties":{"baselineEndFieldName":{"description":"Planned end field, rendered as a ghost bar","type":["string","null"]},"baselineStartFieldName":{"description":"Planned start field, rendered as a ghost bar","type":["string","null"]},"dependencyDirection":{"type":"string","enum":["predecessor","successor"]},"dependencyFieldName":{"description":"A reference field pointing back at this table","type":["string","null"]},"disableDragAndDrop":{"type":"boolean"},"endFieldName":{"type":["string","null"]},"hideTitleColumn":{"type":"boolean"},"hideWeekends":{"type":"boolean"},"milestoneFieldName":{"type":["string","null"]},"progressFieldName":{"type":["string","null"]},"showCriticalPath":{"type":"boolean"},"showWeekends":{"type":"boolean"},"startFieldName":{"type":["string","null"]},"timeScale":{"type":"string","enum":["day","month","quarter","week"]},"titleColumnFieldName":{"type":["string","null"]},"titleColumnWidth":{"type":"number"}}},"groupBy":{"description":"Grouping configuration","type":"array","items":{"type":"object","properties":{"direction":{"description":"Group order direction, defaults to ascending","type":"string","enum":["asc","desc"]},"fieldName":{"type":"string","description":"Field name"}},"required":["fieldName"]}},"icon":{"description":"View icon","type":"object","properties":{"color":{"description":"Icon color (hex string)","type":"string"},"filling":{"description":"Icon filling","anyOf":[{"type":"number","enum":[0]},{"type":"number","enum":[1]}]},"icon":{"type":"string","description":"Icon name"}},"required":["icon"]},"id":{"type":"string","description":"View id"},"labels":{"description":"View labels (localized)","type":"object","additionalProperties":{"type":"string"}},"moduleName":{"type":"string","description":"Module name"},"name":{"type":"string","description":"View name"},"order":{"type":"number","description":"View display order"},"pivot":{"description":"Pivot configuration (row/column/value axes), for Pivot views","type":"object","properties":{"columns":{"type":"array","items":{"type":"object","properties":{"dateGrouping":{"description":"Date bucket, for date fields","type":"string","enum":["day","month","quarter","week","year"]},"fieldName":{"type":"string","description":"Field name"},"sort":{"type":"string","enum":["asc","desc"]}},"required":["fieldName"]},"description":"Column axis fields"},"columnWidths":{"description":"Column widths set in the pivot","type":"object","properties":{"rowHeader":{"description":"Row header width in px","type":"number"},"values":{"description":"Value column widths in px, keyed by `<fieldName>-<agg>`","type":"object","additionalProperties":{"type":"number"}}}},"rows":{"type":"array","items":{"type":"object","properties":{"dateGrouping":{"description":"Date bucket, for date fields","type":"string","enum":["day","month","quarter","week","year"]},"fieldName":{"type":"string","description":"Field name"},"sort":{"type":"string","enum":["asc","desc"]}},"required":["fieldName"]},"description":"Row axis fields"},"values":{"type":"array","items":{"type":"object","properties":{"agg":{"type":"string","enum":["avg","count","max","min","sum","unique"],"description":"Aggregation"},"fieldName":{"type":"string","description":"Field name"}},"required":["agg","fieldName"]},"description":"Aggregated value fields"}},"required":["columns","rows","values"]},"search":{"description":"Stored search term","type":"string"},"sort":{"description":"Sort configuration","type":"object","properties":{"direction":{"type":"string","enum":["asc","desc"],"description":"Sort direction"},"fieldName":{"type":"string","description":"Field name"}},"required":["direction","fieldName"]},"tableName":{"type":"string","description":"Table name"},"type":{"type":"string","enum":["Calendar","Chart","Gallery","Gantt","Kanban","List","Maps","Pivot","Table"],"description":"View type"}},"required":["columns","id","moduleName","name","order","tableName","type"]},"description":"List of views"}},"required":["data"]}}}}
```

## The UpdateViewBody object

```json
{"openapi":"3.0.0","info":{"title":"Ninox Public API","version":"1.0.0"},"components":{"schemas":{"UpdateViewBody":{"type":"object","properties":{"annualRecurring":{"description":"Calendar views only: render every record on the same day/month every year","type":"boolean"},"chartConfig":{"type":"object","properties":{"chartType":{"type":"string","enum":["bar","line","pie","funnel","ranking","board"]},"dataSets":{"type":"array","items":{"type":"object","properties":{"aggregation":{"type":"string","enum":["average","count","max","median","min","none","sum"]},"color":{"description":"Series color (hex string)","type":"string"},"fieldName":{"description":"Field name this series reads from","type":"string"},"labels":{"description":"Series labels (localized)","type":"object","additionalProperties":{"type":"string"}}}}},"donut":{"type":"boolean"},"labelPosition":{"type":"string","enum":["bottom","center","inside","outside","top"]},"legend":{"type":"object","properties":{"show":{"type":"boolean"}}},"limit":{"description":"ranking only: how many categories it shows","type":"integer","minimum":1,"maximum":20},"orientation":{"type":"string","enum":["horizontal","vertical"]},"showDataTable":{"type":"boolean"},"showLabels":{"type":"boolean"},"showPoints":{"type":"boolean"},"showTitle":{"type":"boolean"},"smooth":{"type":"boolean"},"stacked":{"type":"boolean"},"style":{"type":"string","enum":["default","half_donut","pad_angle","rounded_corner"]},"tooltips":{"type":"object","properties":{"show":{"type":"boolean"}}},"xAxis":{"type":"object","properties":{"fieldName":{"description":"X-axis field name, null removes it","type":["string","null"]},"groupBy":{"type":"string","enum":["daily","monthly","none","quarterly","weekly","yearly"]},"show":{"type":"boolean"}}},"yAxis":{"type":"object","properties":{"show":{"type":"boolean"}}}}},"columns":{"minItems":1,"type":"array","items":{"type":"object","properties":{"agg":{"description":"Aggregation function applied to the column","type":"string"},"conditionalStyling":{"description":"Legacy per-column conditional styling rules","type":"array","items":{"type":"object","properties":{"background":{"description":"Background color (hex string)","type":"string"},"cell":{"description":"Target cell","type":"string"},"color":{"description":"Icon color (hex string)","type":"string"},"icon":{"description":"Icon name","type":"string"},"operand":{"type":"string","description":"Comparator"},"value":{"type":"string","description":"Value compared against"}},"required":["operand","value"]}},"field":{"type":"string","description":"Field name, or a script expression for a calculated column"},"hidden":{"description":"Column retained but hidden from the grid","type":"boolean"},"id":{"description":"Stable identity of a calculated column; send it back unchanged when updating the view","type":"string"},"labels":{"description":"Column labels (localized)","type":"object","additionalProperties":{"type":"string"}},"order":{"type":"number","description":"Column display order"},"role":{"description":"Column role (e.g. title, date, image, location, color)","type":"string"},"width":{"description":"Column width","type":"number"}},"required":["field","order"]},"description":"View columns"},"conditionalFormatting":{"description":"Conditional formatting rules","type":"array","items":{"type":"object","properties":{"backgroundColor":{"description":"Background color (hex string)","type":"string"},"bold":{"description":"Bold text","type":"boolean"},"comparator":{"type":"string","enum":["contains","does_not_contain","ends_with","gt","gte","is","is_empty","is_not","is_not_empty","logic","lt","lte","starts_with"],"description":"Comparator"},"expression":{"description":"Script expression, used only when comparator is 'logic'","type":"string"},"fieldName":{"type":"string","description":"Target field name"},"highlightColor":{"description":"Highlight color (hex string)","type":"string"},"icon":{"description":"Icon","type":"object","properties":{"color":{"description":"Icon color (hex string)","type":"string"},"filling":{"description":"Icon filling","anyOf":[{"type":"number","enum":[0]},{"type":"number","enum":[1]}]},"icon":{"type":"string","description":"Icon name"}},"required":["icon"]},"id":{"type":"string","description":"Stable rule id"},"italic":{"description":"Italic text","type":"boolean"},"order":{"type":"number","description":"Rule evaluation order"},"strikethrough":{"description":"Strikethrough text","type":"boolean"},"target":{"type":"string","enum":["cell","row"],"description":"Whether the rule styles a single cell or the whole row"},"textColor":{"description":"Text color (hex string)","type":"string"},"value":{"description":"Value compared against"}},"required":["comparator","fieldName","id","order","target"]}},"filter":{"description":"Stored filter conditions","type":"array","items":{"type":"object","properties":{"field":{"description":"Field name","type":"string"},"id":{"type":"string","description":"Stable condition id"},"operator":{"description":"Filter operator","type":"string"},"value":{"description":"Value compared against","type":"string"}},"required":["id"]}},"ganttConfig":{"description":"Gantt views: which fields the bars are read from","type":"object","properties":{"baselineEndFieldName":{"description":"Planned end field, rendered as a ghost bar","type":["string","null"]},"baselineStartFieldName":{"description":"Planned start field, rendered as a ghost bar","type":["string","null"]},"dependencyDirection":{"type":"string","enum":["predecessor","successor"]},"dependencyFieldName":{"description":"A reference field pointing back at this table","type":["string","null"]},"disableDragAndDrop":{"type":"boolean"},"endFieldName":{"type":["string","null"]},"hideTitleColumn":{"type":"boolean"},"hideWeekends":{"type":"boolean"},"milestoneFieldName":{"type":["string","null"]},"progressFieldName":{"type":["string","null"]},"showCriticalPath":{"type":"boolean"},"showWeekends":{"type":"boolean"},"startFieldName":{"type":["string","null"]},"timeScale":{"type":"string","enum":["day","month","quarter","week"]},"titleColumnFieldName":{"type":["string","null"]},"titleColumnWidth":{"type":"number"}}},"groupBy":{"description":"Grouping configuration","type":"array","items":{"type":"object","properties":{"direction":{"description":"Group order direction, defaults to ascending","type":"string","enum":["asc","desc"]},"fieldName":{"type":"string","description":"Field name"}},"required":["fieldName"]}},"icon":{"description":"View icon","type":"object","properties":{"color":{"type":"string"},"filling":{"anyOf":[{"type":"number","enum":[0]},{"type":"number","enum":[1]}]},"icon":{"type":"string","minLength":1}}},"labels":{"description":"View labels (localized)","type":"object","additionalProperties":{"type":"string","minLength":1,"maxLength":100}},"name":{"type":"string","minLength":1,"maxLength":100,"pattern":"^[a-z0-9_]+$","description":"View name"},"pivot":{"description":"Pivot views: axes to change, omitted axes are kept","type":"object","properties":{"columns":{"type":"array","items":{"type":"object","properties":{"dateGrouping":{"description":"Date bucket, for date fields","type":"string","enum":["day","month","quarter","week","year"]},"fieldName":{"type":"string","description":"Field name"},"sort":{"type":"string","enum":["asc","desc"]}},"required":["fieldName"]},"description":"Column axis fields"},"columnWidths":{"type":"object","properties":{"rowHeader":{"description":"Row header width in px, null removes it","type":["number","null"]},"values":{"description":"Value column widths in px, keyed by `<fieldName>-<agg>`, null removes one","type":"object","additionalProperties":{"type":["number","null"]}}}},"rows":{"type":"array","items":{"type":"object","properties":{"dateGrouping":{"description":"Date bucket, for date fields","type":"string","enum":["day","month","quarter","week","year"]},"fieldName":{"type":"string","description":"Field name"},"sort":{"type":"string","enum":["asc","desc"]}},"required":["fieldName"]},"description":"Row axis fields"},"values":{"type":"array","items":{"type":"object","properties":{"agg":{"type":"string","enum":["avg","count","max","min","sum","unique"],"description":"Aggregation"},"fieldName":{"type":"string","description":"Field name"}},"required":["agg","fieldName"]},"description":"Aggregated value fields"}}},"search":{"description":"Stored search term","type":"string"},"sort":{"description":"Sort configuration","type":"object","properties":{"direction":{"type":"string","enum":["asc","desc"],"description":"Sort direction"},"fieldName":{"type":"string","description":"Field name"}}},"type":{"type":"string","enum":["Calendar","Chart","Gallery","Gantt","Kanban","List","Maps","Pivot","Table"],"description":"View type"}},"additionalProperties":false}}}}
```

## The SchemaChangesResponse object

```json
{"openapi":"3.0.0","info":{"title":"Ninox Public API","version":"1.0.0"},"components":{"schemas":{"SchemaChangesResponse":{"type":"object","properties":{"data":{"type":"array","items":{"type":"object","properties":{"action":{"type":"string","enum":["created","deleted","restored","updated"],"description":"What happened to the object"},"changedAt":{"type":"string","description":"When the change happened (ISO 8601)"},"id":{"type":"string","description":"Object id"},"kind":{"type":"string","enum":["Field","Module","Table"],"description":"Kind of schema object"}},"required":["action","changedAt","id","kind"]},"description":"One entry per recorded change, oldest first"},"meta":{"type":"object","properties":{"asOf":{"type":"string","description":"Server timestamp to pass as `since` on the next poll"},"retentionCutoff":{"description":"Oldest change still readable under the workspace plan (ISO 8601), or null for unlimited retention. A `since` older than this has gaps — do a full schema fetch instead","type":["string","null"]}}},"page_info":{"type":"object","properties":{"has_more":{"type":"boolean","description":"Whether more results are available"},"limit":{"type":"number","description":"Maximum results per page"},"offset":{"type":"number","description":"Current offset"}},"description":"Pagination information"}},"required":["data","meta","page_info"]}}}}
```

## The WorkspaceResponse object

```json
{"openapi":"3.0.0","info":{"title":"Ninox Public API","version":"1.0.0"},"components":{"schemas":{"WorkspaceResponse":{"type":"object","properties":{"data":{"type":"object","properties":{"modules":{"type":"array","items":{"type":"object","properties":{"afterOpen":{"description":"Script expression run in the browser each time the app is opened","type":"string"},"components":{"description":"Module components (pages, containers, widgets)","type":"array","items":{"type":"object","properties":{"afterHide":{"description":"Container directly under Tabs: script run when this tab stops being shown","type":"string"},"aggregation":{"description":"MetricCard: aggregation function","type":"string","enum":["avg","count","max","median","min","sum"]},"annualRecurring":{"description":"Calendar: render every record on the same day/month every year","type":"boolean"},"arrangement":{"description":"Page/Container: layout direction","type":"string","enum":["grid","ltr","row","ttb"]},"background":{"description":"Container/Page/Text: background","anyOf":[{"type":"string"},{"type":"object","properties":{"$nx":{"type":"string","description":"Script expression. Writing one needs records:write as well as schema:write"}},"required":["$nx"]}]},"beforeShow":{"description":"Container directly under Tabs: script run when this tab is shown","type":"string"},"border":{"description":"Container: border","anyOf":[{"type":"object","properties":{"color":{"type":"string"},"style":{"type":"string","enum":["dashed","dotted","double","none","solid"]},"width":{"type":"string"}},"required":["style","width"]},{"type":"object","properties":{"$nx":{"type":"string","description":"Script expression. Writing one needs records:write as well as schema:write"}},"required":["$nx"]}]},"calendarType":{"description":"Calendar: display type","type":"string"},"cardBorder":{"description":"Kanban: card border CSS shorthand, Normal mode only","type":"string"},"cardFont":{"description":"Kanban: card font style tokens, Normal mode only","type":"string"},"cardPadding":{"description":"Kanban: card padding in px, Normal mode only","type":"number"},"cardRadius":{"description":"Kanban: card corner radius in px, Normal mode only","type":"number"},"chartConfig":{"description":"Chart: chart type, axes and data series","type":"object","properties":{"chartType":{"type":"string","enum":["bar","line","pie","funnel","ranking","board"]},"dataSets":{"type":"array","items":{"type":"object","properties":{"aggregation":{"type":"string","enum":["average","count","max","median","min","none","sum"]},"color":{"description":"Series color (hex string)","type":"string"},"fieldName":{"description":"Field name this series reads from","type":"string"},"labels":{"description":"Series labels (localized)","type":"object","additionalProperties":{"type":"string"}}}}},"donut":{"type":"boolean"},"labelPosition":{"type":"string","enum":["bottom","center","inside","outside","top"]},"legend":{"type":"object","properties":{"show":{"type":"boolean"}}},"limit":{"description":"ranking only: how many categories it shows","type":"integer","minimum":1,"maximum":20},"orientation":{"type":"string","enum":["horizontal","vertical"]},"showDataTable":{"type":"boolean"},"showLabels":{"type":"boolean"},"showPoints":{"type":"boolean"},"showTitle":{"type":"boolean"},"smooth":{"type":"boolean"},"stacked":{"type":"boolean"},"style":{"type":"string","enum":["default","half_donut","pad_angle","rounded_corner"]},"tooltips":{"type":"object","properties":{"show":{"type":"boolean"}}},"xAxis":{"type":"object","properties":{"fieldName":{"description":"X-axis field name, null removes it","type":["string","null"]},"groupBy":{"type":"string","enum":["daily","monthly","none","quarterly","weekly","yearly"]},"show":{"type":"boolean"}}},"yAxis":{"type":"object","properties":{"show":{"type":"boolean"}}}},"required":["chartType","dataSets","xAxis"]},"color":{"description":"Text: text color (hex string). Button: theme color name","anyOf":[{"type":"string"},{"type":"object","properties":{"$nx":{"type":"string","description":"Script expression. Writing one needs records:write as well as schema:write"}},"required":["$nx"]}]},"colorFieldName":{"description":"Map: marker color field name","type":"string"},"constraints":{"description":"FieldComponent: script limiting which records a reference can link to, needs schema:manage-permissions","type":"string"},"content":{"description":"Text: content, localized or a script expression","anyOf":[{"type":"object","additionalProperties":{"type":"string"}},{"type":"object","properties":{"$nx":{"type":"string","description":"Script expression. Writing one needs records:write as well as schema:write"}},"required":["$nx"]}]},"customStyle":{"description":"Text: full custom style config, opaque, used only when quickStyle is \"custom\"","type":"object","additionalProperties":{}},"dataPoint":{"description":"'conditional' replaces table/filter/… with the `value` script","type":"string","enum":["conditional","normal"]},"defaultValue":{"description":"InputComponent: initial value, or { $nx: <script> }","anyOf":[{"type":"boolean"},{"type":"number"},{"type":"string"},{"type":"object","properties":{"$nx":{"type":"string","description":"Script expression. Writing one needs records:write as well as schema:write"}},"required":["$nx"]}]},"disabled":{"description":"Button/FieldComponent: disable the control, a boolean or a script","anyOf":[{"type":"boolean"},{"type":"object","properties":{"$nx":{"type":"string","description":"Script expression. Writing one needs records:write as well as schema:write"}},"required":["$nx"]}]},"display":{"description":"MetricCard: display formatting and trend configuration","type":"object","properties":{"color":{"type":"string"},"format":{"type":"string","enum":["compact","currency","number","percentage"]},"icon":{"type":"string"},"trend":{"type":"object","properties":{"customPeriodEnd":{"description":"ISO date (YYYY-MM-DD), for period \"custom\"","type":"string"},"customPeriodStart":{"description":"ISO date (YYYY-MM-DD), for period \"custom\"","type":"string"},"format":{"type":"string","enum":["absolute","percentage"]},"isShown":{"type":"boolean"},"period":{"type":"string","enum":["custom","last_month","last_week","last_year","previous_period","yesterday"]},"positiveDirection":{"type":"string","enum":["down","up"]}},"required":["format","isShown"]}},"required":["color","format","trend"]},"displayAs":{"description":"FieldComponent: how a yes/no field is shown","type":"string"},"expression":{"description":"DynamicHTMLComponent: script returning the HTML to render","type":"string"},"fieldIdDataPoint":{"description":"MetricCard: 'conditional' replaces table/filter/fieldName/aggregation with fieldIdValue","type":"string","enum":["conditional","normal"]},"fieldIdValue":{"description":"MetricCard: whole-dataset script producing the final number when fieldIdDataPoint is conditional","type":"string"},"fieldName":{"description":"MetricCard/Calendar/Map: primary bound field name","type":"string"},"filter":{"description":"MetricCard/Chart: stored filter conditions","type":"array","items":{"type":"object","properties":{"field":{"description":"Field name","type":"string"},"id":{"type":"string","description":"Stable condition id"},"operator":{"description":"Filter operator","type":"string"},"value":{"description":"Value compared against","type":"string"}},"required":["id"]}},"flex":{"description":"Container: flex sizing","anyOf":[{"type":"string"},{"type":"object","properties":{"$nx":{"type":"string","description":"Script expression. Writing one needs records:write as well as schema:write"}},"required":["$nx"]}]},"ganttConfig":{"description":"Gantt: which fields the bars/milestones/dependencies read from","type":"object","properties":{"baselineEndFieldName":{"description":"Planned end field, rendered as a ghost bar","type":["string","null"]},"baselineStartFieldName":{"description":"Planned start field, rendered as a ghost bar","type":["string","null"]},"dependencyDirection":{"type":"string","enum":["predecessor","successor"]},"dependencyFieldName":{"description":"A reference field pointing back at this table","type":["string","null"]},"disableDragAndDrop":{"type":"boolean"},"endFieldName":{"type":["string","null"]},"hideTitleColumn":{"type":"boolean"},"hideWeekends":{"type":"boolean"},"milestoneFieldName":{"type":["string","null"]},"progressFieldName":{"type":["string","null"]},"showCriticalPath":{"type":"boolean"},"showWeekends":{"type":"boolean"},"startFieldName":{"type":["string","null"]},"timeScale":{"type":"string","enum":["day","month","quarter","week"]},"titleColumnFieldName":{"type":["string","null"]},"titleColumnWidth":{"type":"number"}}},"gap":{"description":"Page/Container: gap between children","anyOf":[{"type":"string"},{"type":"object","properties":{"$nx":{"type":"string","description":"Script expression. Writing one needs records:write as well as schema:write"}},"required":["$nx"]}]},"globalFilterBinding":{"description":"MetricCard: field names this card reacts to for global page filters","type":"array","items":{"type":"string"}},"gridPreset":{"description":"Container: grid layout preset","anyOf":[{"type":"string"},{"type":"object","properties":{"$nx":{"type":"string","description":"Script expression. Writing one needs records:write as well as schema:write"}},"required":["$nx"]}]},"groupByFieldName":{"description":"Kanban: lane grouping field name","type":"string"},"height":{"description":"Component height","type":"number"},"icon":{"description":"Page: icon","type":"object","properties":{"color":{"description":"Icon color (hex string)","type":"string"},"filling":{"description":"Icon filling","anyOf":[{"type":"number","enum":[0]},{"type":"number","enum":[1]}]},"icon":{"type":"string","description":"Icon name"}},"required":["icon"]},"iconLeft":{"description":"Button/FieldComponent: icon before the label","anyOf":[{"type":"object","properties":{"color":{"description":"Icon color (hex string)","type":"string"},"filling":{"description":"Icon filling","anyOf":[{"type":"number","enum":[0]},{"type":"number","enum":[1]}]},"icon":{"type":"string","description":"Icon name"}},"required":["icon"]},{"type":"object","properties":{"$nx":{"type":"string","description":"Script expression. Writing one needs records:write as well as schema:write"}},"required":["$nx"]}]},"iconRight":{"description":"Button/FieldComponent: icon after the label","anyOf":[{"type":"object","properties":{"color":{"description":"Icon color (hex string)","type":"string"},"filling":{"description":"Icon filling","anyOf":[{"type":"number","enum":[0]},{"type":"number","enum":[1]}]},"icon":{"type":"string","description":"Icon name"}},"required":["icon"]},{"type":"object","properties":{"$nx":{"type":"string","description":"Script expression. Writing one needs records:write as well as schema:write"}},"required":["$nx"]}]},"id":{"type":"string","description":"Component id"},"imagePosition":{"description":"Kanban: card image crop/anchor, Normal mode only","type":"object","properties":{"position":{"type":"string"},"size":{"type":"string"}}},"isCompact":{"description":"Accordion: compact sections","type":"boolean"},"isHidden":{"description":"Page: hide from navigation","type":"boolean"},"isMarkdownEnabled":{"description":"FieldComponent: render a rich text field as markdown","type":"boolean"},"isSpreadsheetMode":{"description":"Table/FieldComponent: spreadsheet-style editing","type":"boolean"},"kind":{"type":"string","deprecated":true,"description":"Deprecated, use type. Same value, kept so existing integrations keep working"},"labelPosition":{"description":"FieldComponent: top, left, inside or hidden","type":"string"},"labels":{"description":"Component labels (localized)","type":"object","additionalProperties":{"type":"string"}},"mapTypeId":{"description":"Map: base layer type","type":"string"},"margin":{"description":"Container: margin","anyOf":[{"type":"string"},{"type":"object","properties":{"$nx":{"type":"string","description":"Script expression. Writing one needs records:write as well as schema:write"}},"required":["$nx"]}]},"name":{"description":"Component name","type":"string"},"onChange":{"description":"Tabs/FieldComponent: script run when the value changes","type":"string"},"onClick":{"description":"Button: script run on click","type":"string"},"order":{"description":"Component display order","type":"number"},"overflow":{"description":"Container: overflow behavior","anyOf":[{"type":"string"},{"type":"object","properties":{"$nx":{"type":"string","description":"Script expression. Writing one needs records:write as well as schema:write"}},"required":["$nx"]}]},"padding":{"description":"Page/Container: padding","anyOf":[{"type":"string"},{"type":"object","properties":{"$nx":{"type":"string","description":"Script expression. Writing one needs records:write as well as schema:write"}},"required":["$nx"]}]},"parentId":{"description":"Parent component id (forms the component tree)","type":"string"},"placeholder":{"description":"FieldComponent: placeholder, localized, plain or a script","anyOf":[{"type":"object","additionalProperties":{"type":"string"}},{"type":"string"},{"type":"object","properties":{"$nx":{"type":"string","description":"Script expression. Writing one needs records:write as well as schema:write"}},"required":["$nx"]}]},"quickStyle":{"description":"Text: style preset","anyOf":[{"type":"string","enum":["body-md","body-sm","custom","title-lg","title-md","title-sm"]},{"type":"object","properties":{"$nx":{"type":"string","description":"Script expression. Writing one needs records:write as well as schema:write"}},"required":["$nx"]}]},"radius":{"description":"Container/Text: corner radius","anyOf":[{"type":"string"},{"type":"object","properties":{"$nx":{"type":"string","description":"Script expression. Writing one needs records:write as well as schema:write"}},"required":["$nx"]}]},"remember":{"description":"InputComponent: how long the value is kept","type":"string","enum":["localStorage","memory","url"]},"shadow":{"description":"Container: shadow","anyOf":[{"type":"string"},{"type":"object","properties":{"$nx":{"type":"string","description":"Script expression. Writing one needs records:write as well as schema:write"}},"required":["$nx"]}]},"shadowDom":{"description":"DynamicHTMLComponent: render inside a shadow DOM","type":"boolean"},"showAs":{"description":"FieldComponent: how the value is shown (e.g. popup, combobox)","type":"string"},"showBulkActions":{"description":"Table/FieldComponent: show bulk actions","type":"boolean"},"showCalendarType":{"description":"Calendar: show the calendar type switcher","type":"boolean"},"showCreateButton":{"description":"Table: show the create-record button","type":"boolean"},"showCreateRow":{"description":"Table: show the inline create row","type":"boolean"},"showDataAs":{"description":"FieldComponent: script formatting a linked record","type":"string"},"showEmptyLane":{"description":"Kanban: show lanes with no cards","type":"boolean"},"showLinkExistingRecord":{"description":"FieldComponent: offer linking an existing record","type":"boolean"},"showMetadata":{"description":"FieldComponent: show file metadata","type":"boolean"},"showOutlines":{"description":"Page: show layout outlines in the editor","type":"boolean"},"showSearchField":{"description":"Table/Kanban/Gantt/Calendar/Map: show the search field","type":"boolean"},"showTimeScaleSelector":{"description":"Gantt: let the viewer switch time scale","type":"boolean"},"showTitle":{"description":"Table: show the table title","type":"boolean"},"size":{"description":"Button: sm, md or lg","anyOf":[{"type":"string"},{"type":"object","properties":{"$nx":{"type":"string","description":"Script expression. Writing one needs records:write as well as schema:write"}},"required":["$nx"]}]},"tableName":{"description":"Table this component reads from (Chart/Table/Kanban/Gantt/Calendar/Map/MetricCard)","type":"string"},"textAlign":{"description":"Text: alignment","type":"string","enum":["text-center","text-left","text-right"]},"titleFieldName":{"description":"Map: marker title field name","type":"string"},"tooltip":{"description":"FieldComponent: tooltip text","type":"string"},"type":{"type":"string","description":"Component type (e.g. Container, Button, Text, Page), the property the create and update routes and the module definition take"},"value":{"description":"Script used instead of table/filter/… when dataPoint is conditional","type":"string"},"valueSpec":{"description":"InputComponent: the type of the value, shaped like a field type, a reference has refTableName","type":"object","properties":{"type":{"type":"string"}},"required":["type"],"additionalProperties":{}},"valueType":{"description":"InputComponent: legacy value type, valueSpec wins where both are set","type":"string"},"variant":{"description":"Button/Accordion/Tabs: visual variant, InputComponent: text, email, phone, url, ...","anyOf":[{"type":"string"},{"type":"object","properties":{"$nx":{"type":"string","description":"Script expression. Writing one needs records:write as well as schema:write"}},"required":["$nx"]}]},"view":{"description":"Table/MetricCard/Kanban/Gantt/Calendar/Map: columns/filter/groupBy/sort configuration","type":"object","properties":{"columns":{"description":"View columns","type":"array","items":{"type":"object","properties":{"agg":{"description":"Aggregation function applied to the column","type":"string"},"conditionalStyling":{"description":"Legacy per-column conditional styling rules","type":"array","items":{"type":"object","properties":{"background":{"description":"Background color (hex string)","type":"string"},"cell":{"description":"Target cell","type":"string"},"color":{"description":"Icon color (hex string)","type":"string"},"icon":{"description":"Icon name","type":"string"},"operand":{"type":"string","description":"Comparator"},"value":{"type":"string","description":"Value compared against"}},"required":["operand","value"]}},"field":{"type":"string","description":"Field name, or a script expression for a calculated column"},"hidden":{"description":"Column retained but hidden from the grid","type":"boolean"},"id":{"description":"Stable identity of a calculated column; send it back unchanged when updating the view","type":"string"},"labels":{"description":"Column labels (localized)","type":"object","additionalProperties":{"type":"string"}},"order":{"type":"number","description":"Column display order"},"role":{"description":"Column role (e.g. title, date, image, location, color)","type":"string"},"width":{"description":"Column width","type":"number"}},"required":["field","order"]}},"conditionalFormatting":{"description":"Conditional formatting rules","type":"array","items":{"type":"object","properties":{"backgroundColor":{"description":"Background color (hex string)","type":"string"},"bold":{"description":"Bold text","type":"boolean"},"comparator":{"type":"string","enum":["contains","does_not_contain","ends_with","gt","gte","is","is_empty","is_not","is_not_empty","logic","lt","lte","starts_with"],"description":"Comparator"},"expression":{"description":"Script expression, used only when comparator is 'logic'","type":"string"},"fieldName":{"type":"string","description":"Target field name"},"highlightColor":{"description":"Highlight color (hex string)","type":"string"},"icon":{"description":"Icon","type":"object","properties":{"color":{"description":"Icon color (hex string)","type":"string"},"filling":{"description":"Icon filling","anyOf":[{"type":"number","enum":[0]},{"type":"number","enum":[1]}]},"icon":{"type":"string","description":"Icon name"}},"required":["icon"]},"id":{"type":"string","description":"Stable rule id"},"italic":{"description":"Italic text","type":"boolean"},"order":{"type":"number","description":"Rule evaluation order"},"strikethrough":{"description":"Strikethrough text","type":"boolean"},"target":{"type":"string","enum":["cell","row"],"description":"Whether the rule styles a single cell or the whole row"},"textColor":{"description":"Text color (hex string)","type":"string"},"value":{"description":"Value compared against"}},"required":["comparator","fieldName","id","order","target"]}},"filter":{"description":"Stored filter conditions","type":"array","items":{"type":"object","properties":{"field":{"description":"Field name","type":"string"},"id":{"type":"string","description":"Stable condition id"},"operator":{"description":"Filter operator","type":"string"},"value":{"description":"Value compared against","type":"string"}},"required":["id"]}},"groupBy":{"description":"Grouping configuration","type":"array","items":{"type":"object","properties":{"direction":{"description":"Group order direction, defaults to ascending","type":"string","enum":["asc","desc"]},"fieldName":{"type":"string","description":"Field name"}},"required":["fieldName"]}},"sort":{"description":"Sort configuration","type":"object","properties":{"direction":{"type":"string","enum":["asc","desc"],"description":"Sort direction"},"fieldName":{"type":"string","description":"Field name"}},"required":["direction","fieldName"]}}},"visible":{"description":"Conditional visibility logic: a boolean, or a script expression (as { $nx: <script> }) evaluated at render time","anyOf":[{"type":"boolean"},{"type":"object","properties":{"$nx":{"type":"string","description":"Script expression. Writing one needs records:write as well as schema:write"}},"required":["$nx"]}]},"visibleRoles":{"description":"Page: roles allowed to view this page","type":"array","items":{"type":"string"}},"widgetName":{"description":"CustomWidget: folder name under the workspace widgets directory","type":"string"},"widgetProps":{"description":"CustomWidget: property values, each static or a script expression (as { $nx: <script> })","type":"object","additionalProperties":{"anyOf":[{"type":"boolean"},{"type":"number"},{"type":"string"},{"type":"object","properties":{"$nx":{"type":"string","description":"Script expression. Writing one needs records:write as well as schema:write"}},"required":["$nx"]}]}},"width":{"description":"Component width: number = legacy px, string = percentage e.g. \"50%\"","type":["number","string"]}},"required":["id","kind","type"]}},"hideNavigation":{"description":"Hide module from navigation","type":"boolean"},"icon":{"description":"Module icon","type":"object","properties":{"color":{"description":"Icon color (hex string)","type":"string"},"filling":{"description":"Icon filling","anyOf":[{"type":"number","enum":[0]},{"type":"number","enum":[1]}]},"icon":{"type":"string","description":"Icon name"}},"required":["icon"]},"isHidden":{"description":"Hide module","type":"boolean"},"labels":{"description":"Module labels (localized)","type":"object","additionalProperties":{"type":"string"}},"name":{"type":"string"},"openRoles":{"description":"Module open roles","type":"array","items":{"type":"string"}},"tables":{"type":"array","items":{"type":"object","properties":{"canCreate":{"description":"Script expression gating record creation","type":"string"},"canDelete":{"description":"Script expression gating record deletion","type":"string"},"canRead":{"description":"Script expression gating record read access","type":"string"},"canWrite":{"description":"Script expression gating record write access","type":"string"},"createRoles":{"description":"Roles allowed to create records","type":"array","items":{"type":"string"}},"deleteRoles":{"description":"Roles allowed to delete records","type":"array","items":{"type":"string"}},"fields":{"type":"array","items":{"type":"object","properties":{"binding":{"description":"Read-only: internal binding reference, format not yet specified","type":"string"},"canRead":{"description":"Script expression gating field-level read access","type":"string"},"canWrite":{"description":"Script expression gating field-level write access","type":"string"},"defaultValue":{"description":"Default value applied when a record is created: a literal value (an array of option ids for multi/dmulti), or a script expression (as { $nx: <script> }) evaluated at creation time","anyOf":[{"type":"object","properties":{"$nx":{"type":"string","description":"Script expression. Writing one needs records:write as well as schema:write"}},"required":["$nx"]},{"type":["boolean","null","number","string"]},{"type":"array","items":{"type":"string"}}]},"expression":{"description":"Expression (for function type)","type":"string"},"index":{"description":"Field is indexed","type":"boolean"},"labels":{"description":"Field labels (localized)","type":"object","additionalProperties":{"type":"string"}},"name":{"type":"string","description":"Field name"},"onUpdate":{"description":"Script expression run as a row trigger when the field value changes","type":"string"},"optionColor":{"description":"Color expression for dchoice/dmulti fields","type":"string"},"optionIcon":{"description":"Icon expression for dchoice/dmulti fields","type":"string"},"optionName":{"description":"Display name expression for dchoice/dmulti fields","type":"string"},"options":{"description":"Options array for choice/multi fields, or selection expression for dchoice/dmulti fields","anyOf":[{"type":"array","items":{"type":"object","properties":{"color":{"description":"Option color (hex string)","type":"string"},"icon":{"description":"Option icon name","type":"string"},"id":{"type":"string","description":"Option id, a string the caller can set and change"},"label":{"type":"string","description":"Option text in the default language"},"labels":{"description":"Option text per language","type":"object","additionalProperties":{"type":"string"}},"order":{"type":"number","description":"Option display order"},"textColor":{"description":"Option text color (hex string)","type":"string"}},"required":["id","label","order"]}},{"type":"string"}]},"readRoles":{"description":"Roles allowed to read the field","type":"array","items":{"type":"string"}},"refTableName":{"description":"Reference table name","type":"string"},"required":{"description":"Field is required","type":"boolean"},"search":{"description":"Field is searchable","type":"boolean"},"syncedFrom":{"description":"Source column this field syncs from. Read-only unless the table has two-way sync with updates enabled, in which case every synced field except the key column is writable.","type":"string"},"type":{"type":"string","enum":["any","appointment","boolean","choice","color","date","dchoice","dmulti","file","function","html","icon","lambda","multi","number","react","reference","reverse","rowId","string","styled","time","timeinterval","timestamp","unknown","user","void"],"description":"Field type"},"unique":{"description":"Field is unique","type":"boolean"},"variant":{"description":"Field variant (for string type)","type":"string"},"writeRoles":{"description":"Roles allowed to write to the field","type":"array","items":{"type":"string"}}},"required":["name","type"]}},"hasFiles":{"description":"Enable files for the table","type":"boolean"},"hasGlobalSearch":{"description":"Enable global search for the table","type":"boolean"},"hasHistory":{"description":"Enable history for the table","type":"boolean"},"icon":{"description":"Table icon","type":"object","properties":{"color":{"description":"Icon color (hex string)","type":"string"},"filling":{"description":"Icon filling","anyOf":[{"type":"number","enum":[0]},{"type":"number","enum":[1]}]},"icon":{"type":"string","description":"Icon name"}},"required":["icon"]},"isEmailLinkingEnabled":{"description":"Enable email linking for the table","type":"boolean"},"isHidden":{"description":"Hide the table","type":"boolean"},"labels":{"description":"Table labels (localized)","type":"object","additionalProperties":{"type":"string"}},"name":{"type":"string"},"onCreate":{"description":"Script expression run as a trigger after a record is created","type":"string"},"onDelete":{"description":"Script expression run as a trigger when a record is deleted","type":"string"},"onUpdate":{"description":"Script expression run as a trigger after a record is updated","type":"string"},"readRoles":{"description":"Roles allowed to read records","type":"array","items":{"type":"string"}},"writeRoles":{"description":"Roles allowed to update records","type":"array","items":{"type":"string"}}},"required":["name"]}}},"required":["name"]}},"name":{"type":"string"}},"description":"Workspace details"}},"required":["data"]}}}}
```


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation by asking a question.

Perform an HTTP GET request on the following URL with the `ask` and `goal` query parameters:

```
GET https://docs.ninox.com/ninox-api/api-reference/api-endpoints/models.md?ask=<question>&goal=<user_goal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is what the user is ultimately trying to achieve, the reason they need the answer. Sharing it helps GitBook give you a better, more relevant answer. A goal is most helpful when it describes the outcome the user wants rather than restating the question. For example, with `ask=how do I create an API token`, a goal like `automate deployments from our CI pipeline` lets GitBook tailor the answer to that use case.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
