For the complete documentation index, see llms.txt. This page is also available as Markdown.

Pages & Components

Create a page or component

post

Creates a page or component in a module. Page, Container, Tabs, Accordion, Text, Button, FieldComponent, DynamicHTMLComponent, CustomWidget, MetricCardComponent, ChartComponent, TableComponent, KanbanComponent, GanttComponent, CalendarComponent and MapComponent can be created through the public API today. Every kind except Page must nest under an existing component via parentId.

Authorizations
AuthorizationstringRequired

Enter your Workspace API key.

API keys can be generated and managed within the Workspace Integration settings in the Ninox app.

Path parameters
moduleNamestring · min: 1 · max: 100Required

Module name

Example: crmPattern: ^[a-z0-9_]+$
workspaceIdstring · min: 12 · max: 12Required

Workspace ID

Example: 5rdco4s18swuPattern: ^[a-z0-9]+$
Body
afterHidestringOptional

Container directly under Tabs: script run when this tab stops being shown, 400 anywhere else. Needs schema:write plus records:write

aggregationstring · enumOptionalPossible values:
annualRecurringbooleanOptional
arrangementstring · enumOptionalPossible values:
backgroundany ofOptional
stringOptional
or
beforeShowstringOptional

Container directly under Tabs: script run when this tab is shown, 400 anywhere else. Needs schema:write plus records:write

borderany ofOptional
or
calendarTypestringOptional
cardBorderstringOptional
cardFontstringOptional
cardPaddingnumberOptional
cardRadiusnumberOptional
colorany ofOptional
stringOptional
or
colorFieldNamestringOptional
constraintsstringOptional

FieldComponent: script limiting which records a reference can link to, needs schema:manage-permissions

contentany ofOptional
or
dataPointstring · enumOptionalPossible values:
defaultValueany ofOptional

InputComponent: initial value, or { $nx:

booleanOptional
or
numberOptional
or
stringOptional
or
disabledany ofOptional
booleanOptional
or
displayAsstring · enumOptional

FieldComponent: how a yes/no field is shown

Possible values:
expressionstringOptional

DynamicHTMLComponent: script returning the HTML to render. Needs schema:write plus records:write

fieldIdDataPointstring · enumOptionalPossible values:
fieldIdValuestringOptional

MetricCardComponent: script computing the value. Needs schema:write plus records:write

fieldNamestringOptional
flexany ofOptional
stringOptional
or
gapany ofOptional
stringOptional
or
globalFilterBindingstring[]Optional
gridPresetany ofOptional
stringOptional
or
groupByFieldNamestringOptional
heightnumberOptional
iconLeftany ofOptional
or
iconRightany ofOptional
or
isCompactbooleanOptional
isHiddenbooleanOptional

Page: hide from navigation

isMarkdownEnabledbooleanOptional
isSpreadsheetModebooleanOptional
labelPositionstring · enumOptionalPossible values:
mapTypeIdstringOptional
marginany ofOptional
stringOptional
or
namestring · min: 1 · max: 100Required

Component name

Pattern: ^[a-z0-9_]+$
onChangestringOptional

Tabs/FieldComponent: script run when the value changes. Needs schema:write plus records:write

onClickstringOptional

Button: script run on click. Needs schema:write plus records:write

overflowany ofOptional
stringOptional
or
paddingany ofOptional
stringOptional
or
parentIdstring · min: 12 · max: 12Optional

Parent component id, required unless type is 'Page' (a Page's parent may also be its table's object id)

Pattern: ^[a-z0-9]+$
placeholderany ofOptional
or
stringOptional
or
quickStyleany ofOptional
string · enumOptionalPossible values:
or
radiusany ofOptional
stringOptional
or
rememberstring · enumOptional

InputComponent: how long the value is kept, defaults to memory

Possible values:
shadowany ofOptional
stringOptional
or
shadowDombooleanOptional
showAsstringOptional
showBulkActionsbooleanOptional
showCalendarTypebooleanOptional
showCreateButtonbooleanOptional
showCreateRowbooleanOptional
showDataAsstringOptional

FieldComponent: script formatting a linked record. Needs schema:write plus records:write

showEmptyLanebooleanOptional
showLinkExistingRecordbooleanOptional
showMetadatabooleanOptional
showOutlinesbooleanOptional

Page: show layout outlines in the editor

showSearchFieldbooleanOptional
showTimeScaleSelectorbooleanOptional
showTitlebooleanOptional
sizeany ofOptional
string · enumOptionalPossible values:
or
tableNamestringOptional

Table this component reads from

textAlignstring · enumOptionalPossible values:
titleFieldNamestringOptional
tooltipstringOptional
typestring · enumRequired

Component type

Possible values:
valuestringOptional

Script used instead of table/filter/… when dataPoint is conditional. Needs schema:write plus records:write

valueSpecone ofOptional

InputComponent: the type of the value, shaped like a field type, e.g. { type: "choice", options: [...] }

or
or
or
or
or
or
or
or
valueTypestring · enumOptional

InputComponent: legacy value type, valueSpec wins where both are given

Possible values:
variantany ofOptional
string · enumOptionalPossible values:
or
visibleany ofOptional
booleanOptional
or
visibleRolesstring[]Optional

Page: roles allowed to view this page

widgetNamestringOptional

CustomWidget: folder name under the module widgets directory. A CustomWidget needs schema:write plus records:write

widthnumber[]Optional
Responses
201

Component created successfully

application/json
post/api/v1/workspace/{workspaceId}/modules/{moduleName}/components
POST /api/v1/workspace/{workspaceId}/modules/{moduleName}/components HTTP/1.1
Authorization: Bearer YOUR_SECRET_TOKEN
Content-Type: application/json
Accept: */*
Content-Length: 3893

{
  "afterHide": "text",
  "aggregation": "avg",
  "annualRecurring": true,
  "arrangement": "grid",
  "background": "text",
  "beforeShow": "text",
  "border": {
    "color": "text",
    "style": "dashed",
    "width": "text"
  },
  "calendarType": "text",
  "cardBorder": "text",
  "cardFont": "text",
  "cardPadding": 1,
  "cardRadius": 1,
  "chartConfig": {
    "chartType": "bar",
    "dataSets": [
      {
        "aggregation": "average",
        "color": "text",
        "fieldName": "text",
        "labels": {
          "ANY_ADDITIONAL_PROPERTY": "text"
        }
      }
    ],
    "donut": true,
    "labelPosition": "bottom",
    "legend": {
      "show": true
    },
    "limit": 1,
    "orientation": "horizontal",
    "showDataTable": true,
    "showLabels": true,
    "showPoints": true,
    "showTitle": true,
    "smooth": true,
    "stacked": true,
    "style": "default",
    "tooltips": {
      "show": true
    },
    "xAxis": {
      "fieldName": null,
      "groupBy": "daily",
      "show": true
    },
    "yAxis": {
      "show": true
    }
  },
  "color": "text",
  "colorFieldName": "text",
  "constraints": "text",
  "content": {
    "ANY_ADDITIONAL_PROPERTY": "text"
  },
  "customStyle": {
    "ANY_ADDITIONAL_PROPERTY": "anything"
  },
  "dataPoint": "conditional",
  "defaultValue": true,
  "disabled": true,
  "display": {
    "color": "text",
    "format": "compact",
    "icon": "text",
    "trend": {
      "customPeriodEnd": "text",
      "customPeriodStart": "text",
      "format": "absolute",
      "isShown": true,
      "period": "custom",
      "positiveDirection": "down"
    }
  },
  "displayAs": "checkbox",
  "expression": "text",
  "fieldIdDataPoint": "conditional",
  "fieldIdValue": "text",
  "fieldName": "text",
  "filter": [
    {
      "field": "text",
      "id": "text",
      "operator": "text",
      "value": "text"
    }
  ],
  "flex": "text",
  "ganttConfig": {
    "baselineEndFieldName": null,
    "baselineStartFieldName": null,
    "dependencyDirection": "predecessor",
    "dependencyFieldName": null,
    "disableDragAndDrop": true,
    "endFieldName": null,
    "hideTitleColumn": true,
    "hideWeekends": true,
    "milestoneFieldName": null,
    "progressFieldName": null,
    "showCriticalPath": true,
    "showWeekends": true,
    "startFieldName": null,
    "timeScale": "day",
    "titleColumnFieldName": null,
    "titleColumnWidth": 1
  },
  "gap": "text",
  "globalFilterBinding": [
    "text"
  ],
  "gridPreset": "text",
  "groupByFieldName": "text",
  "height": 1,
  "icon": {
    "color": "text",
    "filling": 0,
    "icon": "text"
  },
  "iconLeft": {
    "color": "text",
    "filling": 0,
    "icon": "text"
  },
  "iconRight": {
    "color": "text",
    "filling": 0,
    "icon": "text"
  },
  "imagePosition": {
    "position": "text",
    "size": "text"
  },
  "isCompact": true,
  "isHidden": true,
  "isMarkdownEnabled": true,
  "isSpreadsheetMode": true,
  "labelPosition": "hidden",
  "labels": {
    "ANY_ADDITIONAL_PROPERTY": "text"
  },
  "mapTypeId": "text",
  "margin": "text",
  "name": "text",
  "onChange": "text",
  "onClick": "text",
  "overflow": "text",
  "padding": "text",
  "parentId": "text",
  "placeholder": {
    "ANY_ADDITIONAL_PROPERTY": "text"
  },
  "quickStyle": "body-md",
  "radius": "text",
  "remember": "localStorage",
  "shadow": "text",
  "shadowDom": true,
  "showAs": "text",
  "showBulkActions": true,
  "showCalendarType": true,
  "showCreateButton": true,
  "showCreateRow": true,
  "showDataAs": "text",
  "showEmptyLane": true,
  "showLinkExistingRecord": true,
  "showMetadata": true,
  "showOutlines": true,
  "showSearchField": true,
  "showTimeScaleSelector": true,
  "showTitle": true,
  "size": "lg",
  "tableName": "text",
  "textAlign": "text-center",
  "titleFieldName": "text",
  "tooltip": "text",
  "type": "Accordion",
  "value": "text",
  "valueSpec": {
    "refTableName": "text",
    "type": "reference"
  },
  "valueType": "any",
  "variant": "",
  "view": {
    "columns": [
      {
        "agg": "text",
        "conditionalStyling": [
          {
            "background": "text",
            "cell": "text",
            "color": "text",
            "icon": "text",
            "operand": "text",
            "value": "text"
          }
        ],
        "field": "text",
        "hidden": true,
        "labels": {
          "ANY_ADDITIONAL_PROPERTY": "text"
        },
        "order": 1,
        "role": "text",
        "width": 1
      }
    ],
    "conditionalFormatting": [
      {
        "backgroundColor": "text",
        "bold": true,
        "comparator": "contains",
        "expression": "text",
        "fieldName": "text",
        "highlightColor": "text",
        "icon": {
          "color": "text",
          "filling": 0,
          "icon": "text"
        },
        "id": "text",
        "italic": true,
        "order": 1,
        "strikethrough": true,
        "target": "cell",
        "textColor": "text",
        "value": null
      }
    ],
    "filter": [
      {
        "field": "text",
        "id": "text",
        "operator": "text",
        "value": "text"
      }
    ],
    "groupBy": [
      {
        "direction": "asc",
        "fieldName": "text"
      }
    ],
    "sort": {
      "direction": "asc",
      "fieldName": "text"
    }
  },
  "visible": true,
  "visibleRoles": [
    "text"
  ],
  "widgetName": "text",
  "widgetProps": {
    "ANY_ADDITIONAL_PROPERTY": true
  },
  "width": [
    1
  ]
}
{
  "data": {
    "afterHide": "text",
    "aggregation": "avg",
    "annualRecurring": true,
    "arrangement": "grid",
    "background": "text",
    "beforeShow": "text",
    "border": {
      "color": "text",
      "style": "dashed",
      "width": "text"
    },
    "calendarType": "text",
    "cardBorder": "text",
    "cardFont": "text",
    "cardPadding": 1,
    "cardRadius": 1,
    "chartConfig": {
      "chartType": "bar",
      "dataSets": [
        {
          "aggregation": "average",
          "color": "text",
          "fieldName": "text",
          "labels": {
            "ANY_ADDITIONAL_PROPERTY": "text"
          }
        }
      ],
      "donut": true,
      "labelPosition": "bottom",
      "legend": {
        "show": true
      },
      "limit": 1,
      "orientation": "horizontal",
      "showDataTable": true,
      "showLabels": true,
      "showPoints": true,
      "showTitle": true,
      "smooth": true,
      "stacked": true,
      "style": "default",
      "tooltips": {
        "show": true
      },
      "xAxis": {
        "fieldName": null,
        "groupBy": "daily",
        "show": true
      },
      "yAxis": {
        "show": true
      }
    },
    "color": "text",
    "colorFieldName": "text",
    "constraints": "text",
    "content": {
      "ANY_ADDITIONAL_PROPERTY": "text"
    },
    "customStyle": {
      "ANY_ADDITIONAL_PROPERTY": "anything"
    },
    "dataPoint": "conditional",
    "defaultValue": true,
    "disabled": true,
    "display": {
      "color": "text",
      "format": "compact",
      "icon": "text",
      "trend": {
        "customPeriodEnd": "text",
        "customPeriodStart": "text",
        "format": "absolute",
        "isShown": true,
        "period": "custom",
        "positiveDirection": "down"
      }
    },
    "displayAs": "text",
    "expression": "text",
    "fieldIdDataPoint": "conditional",
    "fieldIdValue": "text",
    "fieldName": "text",
    "filter": [
      {
        "field": "text",
        "id": "text",
        "operator": "text",
        "value": "text"
      }
    ],
    "flex": "text",
    "ganttConfig": {
      "baselineEndFieldName": null,
      "baselineStartFieldName": null,
      "dependencyDirection": "predecessor",
      "dependencyFieldName": null,
      "disableDragAndDrop": true,
      "endFieldName": null,
      "hideTitleColumn": true,
      "hideWeekends": true,
      "milestoneFieldName": null,
      "progressFieldName": null,
      "showCriticalPath": true,
      "showWeekends": true,
      "startFieldName": null,
      "timeScale": "day",
      "titleColumnFieldName": null,
      "titleColumnWidth": 1
    },
    "gap": "text",
    "globalFilterBinding": [
      "text"
    ],
    "gridPreset": "text",
    "groupByFieldName": "text",
    "height": 1,
    "icon": {
      "color": "text",
      "filling": 0,
      "icon": "text"
    },
    "iconLeft": {
      "color": "text",
      "filling": 0,
      "icon": "text"
    },
    "iconRight": {
      "color": "text",
      "filling": 0,
      "icon": "text"
    },
    "id": "text",
    "imagePosition": {
      "position": "text",
      "size": "text"
    },
    "isCompact": true,
    "isHidden": true,
    "isMarkdownEnabled": true,
    "isSpreadsheetMode": true,
    "labelPosition": "text",
    "labels": {
      "ANY_ADDITIONAL_PROPERTY": "text"
    },
    "mapTypeId": "text",
    "margin": "text",
    "name": "text",
    "onChange": "text",
    "onClick": "text",
    "order": 1,
    "overflow": "text",
    "padding": "text",
    "parentId": "text",
    "placeholder": {
      "ANY_ADDITIONAL_PROPERTY": "text"
    },
    "quickStyle": "body-md",
    "radius": "text",
    "remember": "localStorage",
    "shadow": "text",
    "shadowDom": true,
    "showAs": "text",
    "showBulkActions": true,
    "showCalendarType": true,
    "showCreateButton": true,
    "showCreateRow": true,
    "showDataAs": "text",
    "showEmptyLane": true,
    "showLinkExistingRecord": true,
    "showMetadata": true,
    "showOutlines": true,
    "showSearchField": true,
    "showTimeScaleSelector": true,
    "showTitle": true,
    "size": "text",
    "tableName": "text",
    "textAlign": "text-center",
    "titleFieldName": "text",
    "tooltip": "text",
    "type": "text",
    "value": "text",
    "valueSpec": {
      "type": "text",
      "ANY_ADDITIONAL_PROPERTY": "anything"
    },
    "valueType": "text",
    "variant": "text",
    "view": {
      "columns": [
        {
          "agg": "text",
          "conditionalStyling": [
            {
              "background": "text",
              "cell": "text",
              "color": "text",
              "icon": "text",
              "operand": "text",
              "value": "text"
            }
          ],
          "field": "text",
          "hidden": true,
          "labels": {
            "ANY_ADDITIONAL_PROPERTY": "text"
          },
          "order": 1,
          "role": "text",
          "width": 1
        }
      ],
      "conditionalFormatting": [
        {
          "backgroundColor": "text",
          "bold": true,
          "comparator": "contains",
          "expression": "text",
          "fieldName": "text",
          "highlightColor": "text",
          "icon": {
            "color": "text",
            "filling": 0,
            "icon": "text"
          },
          "id": "text",
          "italic": true,
          "order": 1,
          "strikethrough": true,
          "target": "cell",
          "textColor": "text",
          "value": null
        }
      ],
      "filter": [
        {
          "field": "text",
          "id": "text",
          "operator": "text",
          "value": "text"
        }
      ],
      "groupBy": [
        {
          "direction": "asc",
          "fieldName": "text"
        }
      ],
      "sort": {
        "direction": "asc",
        "fieldName": "text"
      }
    },
    "visible": true,
    "visibleRoles": [
      "text"
    ],
    "widgetName": "text",
    "widgetProps": {
      "ANY_ADDITIONAL_PROPERTY": true
    },
    "width": 1
  }
}

Get a specific page or component

get

Retrieves a specific page or component by id

Authorizations
AuthorizationstringRequired

Enter your Workspace API key.

API keys can be generated and managed within the Workspace Integration settings in the Ninox app.

Path parameters
componentIdstring · min: 12 · max: 12Required

Component ID

Example: a1b2c3d4e5f6Pattern: ^[a-z0-9]+$
workspaceIdstring · min: 12 · max: 12Required

Workspace ID

Example: 5rdco4s18swuPattern: ^[a-z0-9]+$
Responses
200

Component details retrieved successfully

application/json
get/api/v1/workspace/{workspaceId}/components/{componentId}
GET /api/v1/workspace/{workspaceId}/components/{componentId} HTTP/1.1
Authorization: Bearer YOUR_SECRET_TOKEN
Accept: */*
{
  "data": {
    "afterHide": "text",
    "aggregation": "avg",
    "annualRecurring": true,
    "arrangement": "grid",
    "background": "text",
    "beforeShow": "text",
    "border": {
      "color": "text",
      "style": "dashed",
      "width": "text"
    },
    "calendarType": "text",
    "cardBorder": "text",
    "cardFont": "text",
    "cardPadding": 1,
    "cardRadius": 1,
    "chartConfig": {
      "chartType": "bar",
      "dataSets": [
        {
          "aggregation": "average",
          "color": "text",
          "fieldName": "text",
          "labels": {
            "ANY_ADDITIONAL_PROPERTY": "text"
          }
        }
      ],
      "donut": true,
      "labelPosition": "bottom",
      "legend": {
        "show": true
      },
      "limit": 1,
      "orientation": "horizontal",
      "showDataTable": true,
      "showLabels": true,
      "showPoints": true,
      "showTitle": true,
      "smooth": true,
      "stacked": true,
      "style": "default",
      "tooltips": {
        "show": true
      },
      "xAxis": {
        "fieldName": null,
        "groupBy": "daily",
        "show": true
      },
      "yAxis": {
        "show": true
      }
    },
    "color": "text",
    "colorFieldName": "text",
    "constraints": "text",
    "content": {
      "ANY_ADDITIONAL_PROPERTY": "text"
    },
    "customStyle": {
      "ANY_ADDITIONAL_PROPERTY": "anything"
    },
    "dataPoint": "conditional",
    "defaultValue": true,
    "disabled": true,
    "display": {
      "color": "text",
      "format": "compact",
      "icon": "text",
      "trend": {
        "customPeriodEnd": "text",
        "customPeriodStart": "text",
        "format": "absolute",
        "isShown": true,
        "period": "custom",
        "positiveDirection": "down"
      }
    },
    "displayAs": "text",
    "expression": "text",
    "fieldIdDataPoint": "conditional",
    "fieldIdValue": "text",
    "fieldName": "text",
    "filter": [
      {
        "field": "text",
        "id": "text",
        "operator": "text",
        "value": "text"
      }
    ],
    "flex": "text",
    "ganttConfig": {
      "baselineEndFieldName": null,
      "baselineStartFieldName": null,
      "dependencyDirection": "predecessor",
      "dependencyFieldName": null,
      "disableDragAndDrop": true,
      "endFieldName": null,
      "hideTitleColumn": true,
      "hideWeekends": true,
      "milestoneFieldName": null,
      "progressFieldName": null,
      "showCriticalPath": true,
      "showWeekends": true,
      "startFieldName": null,
      "timeScale": "day",
      "titleColumnFieldName": null,
      "titleColumnWidth": 1
    },
    "gap": "text",
    "globalFilterBinding": [
      "text"
    ],
    "gridPreset": "text",
    "groupByFieldName": "text",
    "height": 1,
    "icon": {
      "color": "text",
      "filling": 0,
      "icon": "text"
    },
    "iconLeft": {
      "color": "text",
      "filling": 0,
      "icon": "text"
    },
    "iconRight": {
      "color": "text",
      "filling": 0,
      "icon": "text"
    },
    "id": "text",
    "imagePosition": {
      "position": "text",
      "size": "text"
    },
    "isCompact": true,
    "isHidden": true,
    "isMarkdownEnabled": true,
    "isSpreadsheetMode": true,
    "labelPosition": "text",
    "labels": {
      "ANY_ADDITIONAL_PROPERTY": "text"
    },
    "mapTypeId": "text",
    "margin": "text",
    "name": "text",
    "onChange": "text",
    "onClick": "text",
    "order": 1,
    "overflow": "text",
    "padding": "text",
    "parentId": "text",
    "placeholder": {
      "ANY_ADDITIONAL_PROPERTY": "text"
    },
    "quickStyle": "body-md",
    "radius": "text",
    "remember": "localStorage",
    "shadow": "text",
    "shadowDom": true,
    "showAs": "text",
    "showBulkActions": true,
    "showCalendarType": true,
    "showCreateButton": true,
    "showCreateRow": true,
    "showDataAs": "text",
    "showEmptyLane": true,
    "showLinkExistingRecord": true,
    "showMetadata": true,
    "showOutlines": true,
    "showSearchField": true,
    "showTimeScaleSelector": true,
    "showTitle": true,
    "size": "text",
    "tableName": "text",
    "textAlign": "text-center",
    "titleFieldName": "text",
    "tooltip": "text",
    "type": "text",
    "value": "text",
    "valueSpec": {
      "type": "text",
      "ANY_ADDITIONAL_PROPERTY": "anything"
    },
    "valueType": "text",
    "variant": "text",
    "view": {
      "columns": [
        {
          "agg": "text",
          "conditionalStyling": [
            {
              "background": "text",
              "cell": "text",
              "color": "text",
              "icon": "text",
              "operand": "text",
              "value": "text"
            }
          ],
          "field": "text",
          "hidden": true,
          "labels": {
            "ANY_ADDITIONAL_PROPERTY": "text"
          },
          "order": 1,
          "role": "text",
          "width": 1
        }
      ],
      "conditionalFormatting": [
        {
          "backgroundColor": "text",
          "bold": true,
          "comparator": "contains",
          "expression": "text",
          "fieldName": "text",
          "highlightColor": "text",
          "icon": {
            "color": "text",
            "filling": 0,
            "icon": "text"
          },
          "id": "text",
          "italic": true,
          "order": 1,
          "strikethrough": true,
          "target": "cell",
          "textColor": "text",
          "value": null
        }
      ],
      "filter": [
        {
          "field": "text",
          "id": "text",
          "operator": "text",
          "value": "text"
        }
      ],
      "groupBy": [
        {
          "direction": "asc",
          "fieldName": "text"
        }
      ],
      "sort": {
        "direction": "asc",
        "fieldName": "text"
      }
    },
    "visible": true,
    "visibleRoles": [
      "text"
    ],
    "widgetName": "text",
    "widgetProps": {
      "ANY_ADDITIONAL_PROPERTY": true
    },
    "width": 1
  }
}

Delete a page or component

delete

Deletes a page or component, and every component nested under it

Authorizations
AuthorizationstringRequired

Enter your Workspace API key.

API keys can be generated and managed within the Workspace Integration settings in the Ninox app.

Path parameters
componentIdstring · min: 12 · max: 12Required

Component ID

Example: a1b2c3d4e5f6Pattern: ^[a-z0-9]+$
workspaceIdstring · min: 12 · max: 12Required

Workspace ID

Example: 5rdco4s18swuPattern: ^[a-z0-9]+$
Responses
200

Component deleted successfully

application/json
delete/api/v1/workspace/{workspaceId}/components/{componentId}
DELETE /api/v1/workspace/{workspaceId}/components/{componentId} HTTP/1.1
Authorization: Bearer YOUR_SECRET_TOKEN
Accept: */*
{
  "data": {
    "id": "text"
  }
}

Update a page or component

patch

Updates a page or component. Only the kinds listed on create can be written through the public API today; changing an existing component's type to anything else is refused, and so is a stored component whose type is already unsupported.

Authorizations
AuthorizationstringRequired

Enter your Workspace API key.

API keys can be generated and managed within the Workspace Integration settings in the Ninox app.

Path parameters
componentIdstring · min: 12 · max: 12Required

Component ID

Example: a1b2c3d4e5f6Pattern: ^[a-z0-9]+$
workspaceIdstring · min: 12 · max: 12Required

Workspace ID

Example: 5rdco4s18swuPattern: ^[a-z0-9]+$
Body
afterHidestring[]Optional

Container directly under Tabs: script run when this tab stops being shown, null removes it, 400 anywhere else. Needs schema:write plus records:write

aggregationstring · enumOptionalPossible values:
annualRecurringbooleanOptional
arrangementstring · enumOptionalPossible values:
backgroundany ofOptional
stringOptional
or
beforeShowstring[]Optional

Container directly under Tabs: script run when this tab is shown, null removes it, 400 anywhere else. Needs schema:write plus records:write

borderany ofOptional
or
calendarTypestringOptional
cardBorderstringOptional
cardFontstringOptional
cardPaddingnumberOptional
cardRadiusnumberOptional
colorany ofOptional
stringOptional
or
colorFieldNamestringOptional
constraintsstring[]Optional

FieldComponent: reference guard, null removes it

contentany ofOptional
or
dataPointstring · enumOptionalPossible values:
defaultValueany ofOptional

InputComponent: initial value, or { $nx:

booleanOptional
or
numberOptional
or
stringOptional
or
disabledany ofOptional
booleanOptional
or
displayAsstring · enumOptional

FieldComponent: how a yes/no field is shown

Possible values:
expressionstring[]Optional

DynamicHTMLComponent: HTML script, null removes it. Needs schema:write plus records:write

fieldIdDataPointstring · enumOptionalPossible values:
fieldIdValuestringOptional

MetricCardComponent: script computing the value. Needs schema:write plus records:write

fieldNamestringOptional
flexany ofOptional
stringOptional
or
gapany ofOptional
stringOptional
or
globalFilterBindingstring[]Optional
gridPresetany ofOptional
stringOptional
or
groupByFieldNamestringOptional
heightnumberOptional
iconLeftany ofOptional
or
iconRightany ofOptional
or
isCompactbooleanOptional
isHiddenbooleanOptional

Page: hide from navigation

isMarkdownEnabledbooleanOptional
isSpreadsheetModebooleanOptional
labelPositionstring · enumOptionalPossible values:
mapTypeIdstringOptional
marginany ofOptional
stringOptional
or
namestring · min: 1 · max: 100Optional

Component name

Pattern: ^[a-z0-9_]+$
onChangestring[]Optional

Tabs/FieldComponent: change script, null removes it. Needs schema:write plus records:write

onClickstring[]Optional

Button: click script, null removes it. Needs schema:write plus records:write

overflowany ofOptional
stringOptional
or
paddingany ofOptional
stringOptional
or
parentIdstring · min: 12 · max: 12Optional

Parent component id, required unless type is 'Page' (a Page's parent may also be its table's object id)

Pattern: ^[a-z0-9]+$
placeholderany ofOptional
or
stringOptional
or
quickStyleany ofOptional
string · enumOptionalPossible values:
or
radiusany ofOptional
stringOptional
or
rememberstring · enumOptional

InputComponent: how long the value is kept, defaults to memory

Possible values:
shadowany ofOptional
stringOptional
or
shadowDombooleanOptional
showAsstringOptional
showBulkActionsbooleanOptional
showCalendarTypebooleanOptional
showCreateButtonbooleanOptional
showCreateRowbooleanOptional
showDataAsstring[]Optional

FieldComponent: display script, null removes it. Needs schema:write plus records:write

showEmptyLanebooleanOptional
showLinkExistingRecordbooleanOptional
showMetadatabooleanOptional
showOutlinesbooleanOptional

Page: show layout outlines in the editor

showSearchFieldbooleanOptional
showTimeScaleSelectorbooleanOptional
showTitlebooleanOptional
sizeany ofOptional
string · enumOptionalPossible values:
or
tableNamestringOptional

Table this component reads from

textAlignstring · enumOptionalPossible values:
titleFieldNamestringOptional
tooltipstringOptional
typestring · enumOptional

Component type

Possible values:
valuestringOptional

Script used instead of table/filter/… when dataPoint is conditional. Needs schema:write plus records:write

valueSpecone ofOptional

InputComponent: the type of the value, shaped like a field type, e.g. { type: "choice", options: [...] }

or
or
or
or
or
or
or
or
valueTypestring · enumOptional

InputComponent: legacy value type, valueSpec wins where both are given

Possible values:
variantany ofOptional
string · enumOptionalPossible values:
or
visibleany ofOptional
booleanOptional
or
visibleRolesstring[] · nullableOptional

Page: roles allowed to view this page, null removes the restriction

widgetNamestringOptional

CustomWidget: folder name under the module widgets directory. A CustomWidget needs schema:write plus records:write

widthnumber[]Optional
Responses
200

Component updated successfully

application/json
patch/api/v1/workspace/{workspaceId}/components/{componentId}
PATCH /api/v1/workspace/{workspaceId}/components/{componentId} HTTP/1.1
Authorization: Bearer YOUR_SECRET_TOKEN
Content-Type: application/json
Accept: */*
Content-Length: 3907

{
  "afterHide": [
    "text"
  ],
  "aggregation": "avg",
  "annualRecurring": true,
  "arrangement": "grid",
  "background": "text",
  "beforeShow": [
    "text"
  ],
  "border": {
    "color": "text",
    "style": "dashed",
    "width": "text"
  },
  "calendarType": "text",
  "cardBorder": "text",
  "cardFont": "text",
  "cardPadding": 1,
  "cardRadius": 1,
  "chartConfig": {
    "chartType": "bar",
    "dataSets": [
      {
        "aggregation": "average",
        "color": "text",
        "fieldName": "text",
        "labels": {
          "ANY_ADDITIONAL_PROPERTY": "text"
        }
      }
    ],
    "donut": true,
    "labelPosition": "bottom",
    "legend": {
      "show": true
    },
    "limit": 1,
    "orientation": "horizontal",
    "showDataTable": true,
    "showLabels": true,
    "showPoints": true,
    "showTitle": true,
    "smooth": true,
    "stacked": true,
    "style": "default",
    "tooltips": {
      "show": true
    },
    "xAxis": {
      "fieldName": null,
      "groupBy": "daily",
      "show": true
    },
    "yAxis": {
      "show": true
    }
  },
  "color": "text",
  "colorFieldName": "text",
  "constraints": [
    "text"
  ],
  "content": {
    "ANY_ADDITIONAL_PROPERTY": "text"
  },
  "customStyle": {
    "ANY_ADDITIONAL_PROPERTY": "anything"
  },
  "dataPoint": "conditional",
  "defaultValue": true,
  "disabled": true,
  "display": {
    "color": "text",
    "format": "compact",
    "icon": "text",
    "trend": {
      "customPeriodEnd": "text",
      "customPeriodStart": "text",
      "format": "absolute",
      "isShown": true,
      "period": "custom",
      "positiveDirection": "down"
    }
  },
  "displayAs": "checkbox",
  "expression": [
    "text"
  ],
  "fieldIdDataPoint": "conditional",
  "fieldIdValue": "text",
  "fieldName": "text",
  "filter": [
    {
      "field": "text",
      "id": "text",
      "operator": "text",
      "value": "text"
    }
  ],
  "flex": "text",
  "ganttConfig": {
    "baselineEndFieldName": null,
    "baselineStartFieldName": null,
    "dependencyDirection": "predecessor",
    "dependencyFieldName": null,
    "disableDragAndDrop": true,
    "endFieldName": null,
    "hideTitleColumn": true,
    "hideWeekends": true,
    "milestoneFieldName": null,
    "progressFieldName": null,
    "showCriticalPath": true,
    "showWeekends": true,
    "startFieldName": null,
    "timeScale": "day",
    "titleColumnFieldName": null,
    "titleColumnWidth": 1
  },
  "gap": "text",
  "globalFilterBinding": [
    "text"
  ],
  "gridPreset": "text",
  "groupByFieldName": "text",
  "height": 1,
  "icon": {
    "color": "text",
    "filling": 0,
    "icon": "text"
  },
  "iconLeft": {
    "color": "text",
    "filling": 0,
    "icon": "text"
  },
  "iconRight": {
    "color": "text",
    "filling": 0,
    "icon": "text"
  },
  "imagePosition": {
    "position": "text",
    "size": "text"
  },
  "isCompact": true,
  "isHidden": true,
  "isMarkdownEnabled": true,
  "isSpreadsheetMode": true,
  "labelPosition": "hidden",
  "labels": {
    "ANY_ADDITIONAL_PROPERTY": "text"
  },
  "mapTypeId": "text",
  "margin": "text",
  "name": "text",
  "onChange": [
    "text"
  ],
  "onClick": [
    "text"
  ],
  "overflow": "text",
  "padding": "text",
  "parentId": "text",
  "placeholder": {
    "ANY_ADDITIONAL_PROPERTY": "text"
  },
  "quickStyle": "body-md",
  "radius": "text",
  "remember": "localStorage",
  "shadow": "text",
  "shadowDom": true,
  "showAs": "text",
  "showBulkActions": true,
  "showCalendarType": true,
  "showCreateButton": true,
  "showCreateRow": true,
  "showDataAs": [
    "text"
  ],
  "showEmptyLane": true,
  "showLinkExistingRecord": true,
  "showMetadata": true,
  "showOutlines": true,
  "showSearchField": true,
  "showTimeScaleSelector": true,
  "showTitle": true,
  "size": "lg",
  "tableName": "text",
  "textAlign": "text-center",
  "titleFieldName": "text",
  "tooltip": "text",
  "type": "Accordion",
  "value": "text",
  "valueSpec": {
    "refTableName": "text",
    "type": "reference"
  },
  "valueType": "any",
  "variant": "",
  "view": {
    "columns": [
      {
        "agg": "text",
        "conditionalStyling": [
          {
            "background": "text",
            "cell": "text",
            "color": "text",
            "icon": "text",
            "operand": "text",
            "value": "text"
          }
        ],
        "field": "text",
        "hidden": true,
        "labels": {
          "ANY_ADDITIONAL_PROPERTY": "text"
        },
        "order": 1,
        "role": "text",
        "width": 1
      }
    ],
    "conditionalFormatting": [
      {
        "backgroundColor": "text",
        "bold": true,
        "comparator": "contains",
        "expression": "text",
        "fieldName": "text",
        "highlightColor": "text",
        "icon": {
          "color": "text",
          "filling": 0,
          "icon": "text"
        },
        "id": "text",
        "italic": true,
        "order": 1,
        "strikethrough": true,
        "target": "cell",
        "textColor": "text",
        "value": null
      }
    ],
    "filter": [
      {
        "field": "text",
        "id": "text",
        "operator": "text",
        "value": "text"
      }
    ],
    "groupBy": [
      {
        "direction": "asc",
        "fieldName": "text"
      }
    ],
    "sort": {
      "direction": "asc",
      "fieldName": "text"
    }
  },
  "visible": true,
  "visibleRoles": [
    "text"
  ],
  "widgetName": "text",
  "widgetProps": {
    "ANY_ADDITIONAL_PROPERTY": true
  },
  "width": [
    1
  ]
}
{
  "data": {
    "afterHide": "text",
    "aggregation": "avg",
    "annualRecurring": true,
    "arrangement": "grid",
    "background": "text",
    "beforeShow": "text",
    "border": {
      "color": "text",
      "style": "dashed",
      "width": "text"
    },
    "calendarType": "text",
    "cardBorder": "text",
    "cardFont": "text",
    "cardPadding": 1,
    "cardRadius": 1,
    "chartConfig": {
      "chartType": "bar",
      "dataSets": [
        {
          "aggregation": "average",
          "color": "text",
          "fieldName": "text",
          "labels": {
            "ANY_ADDITIONAL_PROPERTY": "text"
          }
        }
      ],
      "donut": true,
      "labelPosition": "bottom",
      "legend": {
        "show": true
      },
      "limit": 1,
      "orientation": "horizontal",
      "showDataTable": true,
      "showLabels": true,
      "showPoints": true,
      "showTitle": true,
      "smooth": true,
      "stacked": true,
      "style": "default",
      "tooltips": {
        "show": true
      },
      "xAxis": {
        "fieldName": null,
        "groupBy": "daily",
        "show": true
      },
      "yAxis": {
        "show": true
      }
    },
    "color": "text",
    "colorFieldName": "text",
    "constraints": "text",
    "content": {
      "ANY_ADDITIONAL_PROPERTY": "text"
    },
    "customStyle": {
      "ANY_ADDITIONAL_PROPERTY": "anything"
    },
    "dataPoint": "conditional",
    "defaultValue": true,
    "disabled": true,
    "display": {
      "color": "text",
      "format": "compact",
      "icon": "text",
      "trend": {
        "customPeriodEnd": "text",
        "customPeriodStart": "text",
        "format": "absolute",
        "isShown": true,
        "period": "custom",
        "positiveDirection": "down"
      }
    },
    "displayAs": "text",
    "expression": "text",
    "fieldIdDataPoint": "conditional",
    "fieldIdValue": "text",
    "fieldName": "text",
    "filter": [
      {
        "field": "text",
        "id": "text",
        "operator": "text",
        "value": "text"
      }
    ],
    "flex": "text",
    "ganttConfig": {
      "baselineEndFieldName": null,
      "baselineStartFieldName": null,
      "dependencyDirection": "predecessor",
      "dependencyFieldName": null,
      "disableDragAndDrop": true,
      "endFieldName": null,
      "hideTitleColumn": true,
      "hideWeekends": true,
      "milestoneFieldName": null,
      "progressFieldName": null,
      "showCriticalPath": true,
      "showWeekends": true,
      "startFieldName": null,
      "timeScale": "day",
      "titleColumnFieldName": null,
      "titleColumnWidth": 1
    },
    "gap": "text",
    "globalFilterBinding": [
      "text"
    ],
    "gridPreset": "text",
    "groupByFieldName": "text",
    "height": 1,
    "icon": {
      "color": "text",
      "filling": 0,
      "icon": "text"
    },
    "iconLeft": {
      "color": "text",
      "filling": 0,
      "icon": "text"
    },
    "iconRight": {
      "color": "text",
      "filling": 0,
      "icon": "text"
    },
    "id": "text",
    "imagePosition": {
      "position": "text",
      "size": "text"
    },
    "isCompact": true,
    "isHidden": true,
    "isMarkdownEnabled": true,
    "isSpreadsheetMode": true,
    "labelPosition": "text",
    "labels": {
      "ANY_ADDITIONAL_PROPERTY": "text"
    },
    "mapTypeId": "text",
    "margin": "text",
    "name": "text",
    "onChange": "text",
    "onClick": "text",
    "order": 1,
    "overflow": "text",
    "padding": "text",
    "parentId": "text",
    "placeholder": {
      "ANY_ADDITIONAL_PROPERTY": "text"
    },
    "quickStyle": "body-md",
    "radius": "text",
    "remember": "localStorage",
    "shadow": "text",
    "shadowDom": true,
    "showAs": "text",
    "showBulkActions": true,
    "showCalendarType": true,
    "showCreateButton": true,
    "showCreateRow": true,
    "showDataAs": "text",
    "showEmptyLane": true,
    "showLinkExistingRecord": true,
    "showMetadata": true,
    "showOutlines": true,
    "showSearchField": true,
    "showTimeScaleSelector": true,
    "showTitle": true,
    "size": "text",
    "tableName": "text",
    "textAlign": "text-center",
    "titleFieldName": "text",
    "tooltip": "text",
    "type": "text",
    "value": "text",
    "valueSpec": {
      "type": "text",
      "ANY_ADDITIONAL_PROPERTY": "anything"
    },
    "valueType": "text",
    "variant": "text",
    "view": {
      "columns": [
        {
          "agg": "text",
          "conditionalStyling": [
            {
              "background": "text",
              "cell": "text",
              "color": "text",
              "icon": "text",
              "operand": "text",
              "value": "text"
            }
          ],
          "field": "text",
          "hidden": true,
          "labels": {
            "ANY_ADDITIONAL_PROPERTY": "text"
          },
          "order": 1,
          "role": "text",
          "width": 1
        }
      ],
      "conditionalFormatting": [
        {
          "backgroundColor": "text",
          "bold": true,
          "comparator": "contains",
          "expression": "text",
          "fieldName": "text",
          "highlightColor": "text",
          "icon": {
            "color": "text",
            "filling": 0,
            "icon": "text"
          },
          "id": "text",
          "italic": true,
          "order": 1,
          "strikethrough": true,
          "target": "cell",
          "textColor": "text",
          "value": null
        }
      ],
      "filter": [
        {
          "field": "text",
          "id": "text",
          "operator": "text",
          "value": "text"
        }
      ],
      "groupBy": [
        {
          "direction": "asc",
          "fieldName": "text"
        }
      ],
      "sort": {
        "direction": "asc",
        "fieldName": "text"
      }
    },
    "visible": true,
    "visibleRoles": [
      "text"
    ],
    "widgetName": "text",
    "widgetProps": {
      "ANY_ADDITIONAL_PROPERTY": true
    },
    "width": 1
  }
}

Last updated

Was this helpful?