diff --git a/packages/nocodb/src/schema/swagger.json b/packages/nocodb/src/schema/swagger.json index 79dbfabace..877e0cbfb2 100644 --- a/packages/nocodb/src/schema/swagger.json +++ b/packages/nocodb/src/schema/swagger.json @@ -7520,1538 +7520,1021 @@ }, "components": { "schemas": { - "User": { - "title": "User Model", - "type": "object", + "ApiToken": { + "description": "Model for API Token", "examples": [ { - "id": "us_8kugj628ebjngs", - "firstName": "Alice", - "lastName": "Smith", - "email": "alice.smith@nocodb.com", - "roles": "org-level-viewer", - "email_verified": true, - "created_at": "2023-03-01 11:36:49", - "updated_at": "2023-03-01 11:36:49" + "created_at": null, + "description": "string", + "fk_user_id": "string", + "id": "string", + "token": "string", + "updated_at": null } ], - "x-internal": false, - "description": "Model for User", "properties": { - "id": { - "type": "string", - "description": "Unique identifier for the given user.", - "example": "us_8kugj628ebjngs" - }, - "firstname": { - "type": "string", - "description": "The first name of the user", - "example": "Alice" - }, - "lastname": { - "type": "string", - "description": "The last name of the user", - "example": "Smith" - }, - "email": { - "type": "string", - "format": "email", - "description": "The email of the user", - "example": "alice.smith@nocodb.com" + "created_at": {}, + "description": { + "type": "string" }, - "roles": { - "type": "string", - "description": "The roles of the user", - "example": "org-level-viewer" + "fk_user_id": { + "type": "string" }, - "email_verified": { - "type": "boolean", - "description": "Set to true if the user's email has been verified." + "id": { + "$ref": "#/components/schemas/Id", + "description": "Unique ID" }, - "created_at": { - "type": "string", - "format": "date-time", - "description": "The date that the user was created.", - "example": "2023-03-01 11:36:49" + "token": { + "type": "string" }, - "updated_at": { - "type": "string", - "format": "date-time", - "description": "The date that the user was created.", - "example": "2023-03-01 11:36:49" - } + "updated_at": {} }, - "required": ["id", "firstname", "lastname", "email", "email_verified"] + "title": "API Token Model", + "type": "object" }, - "UserList": { - "type": "object", - "x-examples": { - "example-1": { - "bases": { - "list": [ - { - "id": "string", - "project_id": "string", - "alias": "string", - "host": "string", - "port": 0, - "username": "string", - "password": "string", - "database": "string", - "url": "string", - "params": "string", - "type": "string", - "ssl": "string" - } - ], - "pageInfo": { - "pageSize": 0, - "totalRows": 0, - "sort": "string", - "isFirstPage": true, - "isLastPage": true - } - } + "ApiTokenReq": { + "description": "Model for API Token Request", + "examples": [ + { + "description": "string" } - }, - "title": "User List Model", - "description": "Model for User List", + ], "properties": { - "users": { - "type": "object", - "required": ["list", "pageInfo"], - "description": "users includes `list` and `pageInfo`", - "properties": { - "list": { - "$ref": "#/components/schemas/User", - "description": "List of User objects" - }, - "pageInfo": { - "$ref": "#/components/schemas/Paginated", - "description": "Pagination info" - } - } + "description": { + "description": "Description of the API token", + "maxLength": 255, + "type": "string" } }, - "required": ["users"], + "title": "API Token Request Model", + "type": "object" + }, + "Attachment": { + "description": "Model for Attachment", "examples": [ { - "users": { - "list": { - "id": "us_8kugj628ebjngs", - "firstName": "Alice", - "lastName": "Smith", - "email": "alice.smith@nocodb.com", - "roles": "org-level-viewer", - "email_verified": true, - "created_at": "2023-03-01 11:36:49", - "updated_at": "2023-03-01 11:36:49" - }, - "pageInfo": { - "pageSize": 10, - "totalRows": 1, - "isFirstPage": true, - "isLastPage": true, - "page": 1 - } - } + "data": null, + "icon": "string", + "mimetype": "string", + "path": "string", + "size": "string", + "title": "string", + "url": "string" } - ] - }, - "ProjectReq": { - "title": "Project Request Model", - "type": "object", + ], "properties": { - "title": { - "type": "string", - "minLength": 1, - "maxLength": 128, - "description": "Project Title", - "example": "My Project" + "data": {}, + "icon": { + "type": "string" }, - "description": { - "type": "string", - "description": "Project Description", - "example": "This is my project description" + "mimetype": { + "type": "string" }, - "color": { - "type": "string", - "maxLength": 50, - "example": "#24716E", - "description": "Primary Theme Color" + "path": { + "type": "string" }, - "bases": { - "type": "array", - "description": "Array of Bases", - "items": { - "$ref": "#/components/schemas/BaseReq" - } + "size": { + "type": "string" + }, + "title": { + "type": "string" + }, + "url": { + "type": "string" } }, - "required": ["title"], - "description": "Model for Project Request", + "title": "Attachment Model", + "type": "object" + }, + "Audit": { + "description": "Model for Audit", "examples": [ { - "title": "My Project", - "description": "This is my project description", - "color": "#24716E", - "bases": [ - { - "alias": "My Base", - "type": "mysql", - "is_meta": true, - "config": null, - "inflection_column": "camelize", - "inflection_table": "camelize" - } - ] + "base_id": "string", + "description": "string", + "details": "string", + "fk_model_id": "string", + "id": "string", + "ip": "string", + "op_sub_type": "string", + "op_type": "string", + "project_id": "string", + "row_id": "string", + "status": "string", + "user": "string" } - ] - }, - "Project": { - "title": "Project Model", - "type": "object", + ], "properties": { - "id": { - "type": "string", - "example": "p_124hhlkbeasewh", - "description": "Unique Project ID" - }, - "title": { - "type": "string", - "description": "Project Title", - "example": "my-project" - }, - "status": { + "base_id": { "type": "string" }, "description": { - "type": "string", - "description": "Project Description", - "example": "This is my project description" + "type": "string" }, - "meta": { - "$ref": "#/components/schemas/Meta", - "description": "Meta Info such as theme colors" + "details": { + "type": "string" }, - "color": { - "type": "string", - "description": "Primary Theme Color", - "example": "#24716E" + "fk_model_id": { + "type": "string" }, - "deleted": { - "$ref": "#/components/schemas/Bool", - "description": "Is the project deleted" + "id": { + "$ref": "#/components/schemas/Id", + "description": "Unique ID" }, - "order": { - "type": "number", - "description": "The order in project list" + "ip": { + "type": "string" }, - "bases": { - "type": "array", - "description": "List of base models", - "items": { - "$ref": "#/components/schemas/Base" - } + "op_sub_type": { + "type": "string" }, - "is_meta": { - "$ref": "#/components/schemas/Bool" + "op_type": { + "type": "string" }, - "prefix": { - "type": "string", - "description": "Project prefix. Used in XCDB only.", - "example": "nc_vm5q__" + "project_id": { + "type": "string" }, - "created_at": { - "description": "The created time of the record", - "type": "string", - "format": "date-time", - "example": "2023-03-01 14:27:36" + "row_id": { + "type": "string" }, - "updated_at": { - "description": "The updated time of the record", - "type": "string", - "format": "date-time", - "example": "2023-03-01 14:27:36" + "status": { + "type": "string" + }, + "user": { + "type": "string" } }, - "description": "Model for Project", + "title": "Audit Model", + "type": "object" + }, + "AuditRowUpdateReq": { + "description": "Model for Audit Row Update Request", "examples": [ { - "id": "p_124hhlkbeasewh", - "title": "my-project", - "status": "string", - "description": "This is my project description", - "meta": {}, - "color": "#24716E", - "deleted": true, - "order": 0, - "bases": [ - { - "id": "string", - "project_id": "string", - "alias": "string", - "type": "mysql2", - "is_meta": true, - "config": null, - "created_at": "2023-03-01 14:27:36", - "updated_at": "2023-03-01 14:27:36", - "inflection_column": "camelize", - "inflection_table": "camelize", - "order": 1, - "enabled": true - } - ], - "is_meta": true, - "prefix": "nc_vm5q__", - "created_at": "2023-03-01 14:27:36", - "updated_at": "2023-03-01 14:27:36" - } - ] - }, - "ProjectList": { - "type": "object", - "x-examples": { - "example-1": { - "bases": { - "list": [ - { - "id": "string", - "project_id": "string", - "alias": "string", - "host": "string", - "port": 0, - "username": "string", - "password": "string", - "database": "string", - "url": "string", - "params": "string", - "type": "string", - "ssl": "string" - } - ], - "pageInfo": { - "pageSize": 0, - "totalRows": 0, - "sort": "string", - "isFirstPage": true, - "isLastPage": true - } - } + "column_name": "string", + "fk_model_id": "string", + "prev_value": null, + "row_id": "string", + "value": null } - }, + ], "properties": { - "list": { - "type": "array", - "uniqueItems": true, - "minItems": 1, - "description": "List of Project Models", - "items": { - "$ref": "#/components/schemas/Project" - } + "column_name": { + "type": "string" }, - "pageInfo": { - "$ref": "#/components/schemas/Paginated", - "description": "Pagination Info" - } + "fk_model_id": { + "type": "string" + }, + "prev_value": {}, + "row_id": { + "type": "string" + }, + "value": {} }, - "title": "Project List Model", - "description": "Model for Project List", - "examples": [ - { - "list": [ - { - "id": "p_124hhlkbeasewh", - "title": "my-project", - "status": "string", - "description": "This is my project description", - "meta": {}, - "color": "#24716E", - "deleted": true, - "order": 0, - "bases": [ - { - "id": "string", - "project_id": "string", - "alias": "string", - "type": "mysql2", - "is_meta": true, - "config": null, - "created_at": "2023-03-01 14:27:36", - "updated_at": "2023-03-01 14:27:36", - "inflection_column": "camelize", - "inflection_table": "camelize", - "order": 1, - "enabled": true - } - ], - "is_meta": true, - "prefix": "nc_vm5q__", - "created_at": "2023-03-01 14:27:36", - "updated_at": "2023-03-01 14:27:36" - } - ], - "pageInfo": { - "pageSize": 10, - "totalRows": 1, - "isFirstPage": true, - "isLastPage": true, - "page": 1 - } - } - ] + "title": "Audit Row Update Request Model", + "type": "object" }, "Base": { - "title": "Base Model", - "type": "object", "description": "Model for Base", + "examples": [ + { + "alias": null, + "config": "", + "created_at": "2023-03-01 16:31:49", + "enabled": 1, + "id": "ds_krsappzu9f8vmo", + "inflection_column": "camelize", + "inflection_table": "camelize", + "is_meta": 1, + "meta": null, + "order": 1, + "project_id": "p_01clqvzik3izk6", + "type": "mysql2", + "updated_at": "2023-03-02 11:28:17" + } + ], "properties": { - "id": { - "type": "string", - "description": "Unique Base ID" - }, - "project_id": { - "type": "string", - "description": "The project ID that this base belongs to" - }, "alias": { "$ref": "#/components/schemas/StringOrNull", "description": "Base Name - Default BASE will be null by default" }, - "type": { - "type": "string", - "description": "DB Type", - "example": "mysql2", - "enum": [ - "mysql2", - "sqlite", - "mysql", - "mssql", - "snowflake", - "oracledb", - "pg" - ] - }, - "is_meta": { - "$ref": "#/components/schemas/Bool", - "description": "Is the data source connected externally" - }, "config": { "description": "Base Configuration" }, "created_at": { "description": "The datatime this base is created at", - "type": "string", + "example": "2023-03-01 14:27:36", "format": "date-time", - "example": "2023-03-01 14:27:36" + "type": "string" }, - "updated_at": { - "description": "The datatime this base is updated at", - "type": "string", - "format": "date-time", - "example": "2023-03-01 14:27:36" + "enabled": { + "$ref": "#/components/schemas/Bool", + "description": "Is this base enabled" + }, + "id": { + "description": "Unique Base ID", + "type": "string" }, "inflection_column": { - "type": "string", "description": "Inflection for columns", - "example": "camelize" + "example": "camelize", + "type": "string" }, "inflection_table": { - "type": "string", "description": "Inflection for tables", - "example": "camelize" + "example": "camelize", + "type": "string" + }, + "is_meta": { + "$ref": "#/components/schemas/Bool", + "description": "Is the data source connected externally" }, "order": { - "type": "number", "description": "The order of the list of bases", - "example": 1 + "example": 1, + "type": "number" }, - "enabled": { - "$ref": "#/components/schemas/Bool", - "description": "Is this base enabled" - } - }, - "examples": [ - { - "id": "ds_krsappzu9f8vmo", - "project_id": "p_01clqvzik3izk6", - "alias": null, - "config": "", - "meta": null, - "is_meta": 1, - "type": "mysql2", - "inflection_column": "camelize", - "inflection_table": "camelize", - "created_at": "2023-03-01 16:31:49", - "updated_at": "2023-03-02 11:28:17", - "enabled": 1, - "order": 1 - } - ] - }, - "BaseReq": { - "title": "Base Request", - "type": "object", - "description": "Model for Base Request", - "properties": { - "alias": { - "type": "string", - "maxLength": 128, - "description": "Base Name - Default BASE will be null by default", - "example": "My Base" + "project_id": { + "description": "The project ID that this base belongs to", + "type": "string" }, "type": { - "type": "string", + "description": "DB Type", "enum": [ + "mssql", "mysql", "mysql2", - "pg", - "sqlite3", - "mssql", "oracledb", - "snowflake" + "pg", + "snowflake", + "sqlite" ], - "description": "DB Type" - }, - "is_meta": { - "type": "boolean", - "description": "Is the data source connected externally" + "example": "mysql2", + "type": "string" }, - "config": { - "description": "Base Configuration" - }, - "inflection_column": { - "type": "string", - "description": "Inflection for columns", - "example": "camelize" - }, - "inflection_table": { - "type": "string", - "description": "Inflection for tables", - "example": "camelize" + "updated_at": { + "description": "The datatime this base is updated at", + "example": "2023-03-01 14:27:36", + "format": "date-time", + "type": "string" } }, - "examples": [ - { - "alias": "My Base", - "type": "mysql", - "is_meta": true, - "config": null, - "inflection_column": "camelize", - "inflection_table": "camelize" - } - ] + "title": "Base Model", + "type": "object" }, "BaseList": { "description": "Model for Base List", - "type": "object", - "x-examples": { - "example-1": { + "examples": [ + { "bases": { "list": [ { - "id": "ds_krsappzu9f8vmo", - "project_id": "p_01clqvzik3izk6", - "alias": null, - "config": "", - "meta": null, - "is_meta": 1, - "type": "mysql2", + "alias": "string", + "config": null, + "created_at": "2023-03-01 14:27:36", + "enabled": true, + "id": "string", "inflection_column": "camelize", "inflection_table": "camelize", - "created_at": "2023-03-01 16:31:49", - "updated_at": "2023-03-02 11:28:17", - "enabled": 1, - "order": 1 - }, - { - "id": "ds_btbdt19zde0gj9", - "project_id": "p_01clqvzik3izk6", - "alias": "sakila", - "config": "", - "meta": null, - "is_meta": null, + "is_meta": true, + "order": 1, + "project_id": "string", "type": "mysql2", - "inflection_column": "camelize", - "inflection_table": "camelize", - "created_at": "2023-03-02 11:28:17", - "updated_at": "2023-03-02 11:28:17", - "enabled": 1, - "order": 2 + "updated_at": "2023-03-01 14:27:36" } ], "pageInfo": { - "totalRows": 2, - "page": 1, - "pageSize": 2, "isFirstPage": true, - "isLastPage": true + "isLastPage": true, + "page": 1, + "pageSize": 10, + "totalRows": 1 } } } - }, + ], "properties": { "bases": { - "type": "object", - "required": ["list", "pageInfo"], "properties": { "list": { - "type": "array", - "uniqueItems": true, - "minItems": 1, "items": { "$ref": "#/components/schemas/Base" - } + }, + "minItems": 1, + "type": "array", + "uniqueItems": true }, "pageInfo": { "$ref": "#/components/schemas/Paginated" } - } + }, + "required": ["list", "pageInfo"], + "type": "object" } }, "required": ["bases"], "title": "Base List Model", - "examples": [ - { + "type": "object", + "x-examples": { + "example-1": { "bases": { "list": [ { - "id": "string", - "project_id": "string", - "alias": "string", + "alias": "sakila", + "config": "", + "created_at": "2023-03-02 11:28:17", + "enabled": 1, + "id": "ds_btbdt19zde0gj9", + "inflection_column": "camelize", + "inflection_table": "camelize", + "is_meta": null, + "meta": null, + "order": 2, + "project_id": "p_01clqvzik3izk6", "type": "mysql2", - "is_meta": true, - "config": null, - "created_at": "2023-03-01 14:27:36", - "updated_at": "2023-03-01 14:27:36", + "updated_at": "2023-03-02 11:28:17" + }, + { + "alias": null, + "config": "", + "created_at": "2023-03-01 16:31:49", + "enabled": 1, + "id": "ds_krsappzu9f8vmo", "inflection_column": "camelize", "inflection_table": "camelize", + "is_meta": 1, + "meta": null, "order": 1, - "enabled": true + "project_id": "p_01clqvzik3izk6", + "type": "mysql2", + "updated_at": "2023-03-02 11:28:17" } ], "pageInfo": { - "pageSize": 10, - "totalRows": 1, "isFirstPage": true, "isLastPage": true, - "page": 1 + "page": 1, + "pageSize": 2, + "totalRows": 2 } } } - ] + } }, - "View": { - "title": "View Model", - "type": "object", + "BaseReq": { + "description": "Model for Base Request", "examples": [ { - "id": "vw_lg052cnc1c26kf", - "base_id": "ds_g4ccx6e77h1dmi", - "project_id": "p_xm3thidrblw4n7", - "fk_model_id": "md_mhs9z4r2ak98x0", - "title": "Sheet-1", - "type": 3, - "is_default": 1, - "show_system_fields": null, - "lock_type": "collaborative", - "uuid": null, - "password": null, - "show": 1, - "order": 1, - "created_at": "2023-03-02 17:46:31", - "updated_at": "2023-03-02 17:46:31", - "meta": {}, - "view": { - "fk_view_id": "vw_lg052cnc1c26kf", - "base_id": "ds_g4ccx6e77h1dmi", - "project_id": "p_xm3thidrblw4n7", - "uuid": null, - "created_at": "2023-03-02 17:46:31", - "updated_at": "2023-03-02 17:46:31", - "meta": null, - "row_height": null - } + "alias": "My Base", + "config": null, + "inflection_column": "camelize", + "inflection_table": "camelize", + "is_meta": true, + "type": "mysql" } ], - "description": "Model for View", "properties": { - "id": { - "$ref": "#/components/schemas/Id", - "description": "Unique ID for View" + "alias": { + "description": "Base Name - Default BASE will be null by default", + "example": "My Base", + "maxLength": 128, + "type": "string" }, - "base_id": { - "$ref": "#/components/schemas/Id", - "description": "Unique Base ID" + "config": { + "description": "Base Configuration" }, - "project_id": { - "$ref": "#/components/schemas/Id", - "description": "Unique Project ID" + "inflection_column": { + "description": "Inflection for columns", + "example": "camelize", + "type": "string" }, - "fk_model_id": { - "$ref": "#/components/schemas/Id", - "description": "Unique Model ID" + "inflection_table": { + "description": "Inflection for tables", + "example": "camelize", + "type": "string" }, - "title": { - "type": "string", - "description": "View Title" + "is_meta": { + "description": "Is the data source connected externally", + "type": "boolean" }, "type": { - "type": "number", - "description": "View Type" - }, - "show": { - "$ref": "#/components/schemas/Bool", - "description": "If this view is shown?" - }, - "order": { - "type": "number", - "description": "The rder of the list of views" - }, - "uuid": { - "type": "string", - "description": "UUID of the view" - }, - "password": { - "type": "string", - "description": "Password for protecting the view" - }, - "meta": { - "$ref": "#/components/schemas/Meta", - "description": "Meta data for this view" - }, - "show_system_fields": { - "$ref": "#/components/schemas/Bool", - "description": "Should show system fields in this view?" - }, - "lock_type": { - "type": "string", - "enum": ["collaborative", "locked", "personal"], - "description": "Lock Type of the view" - }, - "view": { - "anyOf": [ - { - "$ref": "#/components/schemas/Form" - }, - { - "$ref": "#/components/schemas/Grid" - }, - { - "$ref": "#/components/schemas/Gallery" - }, - { - "$ref": "#/components/schemas/Kanban" - }, - { - "$ref": "#/components/schemas/Map" - } + "description": "DB Type", + "enum": [ + "mssql", + "mysql", + "mysql2", + "oracledb", + "pg", + "snowflake", + "sqlite3" ], - "description": "Associated View Model" + "type": "string" } }, - "required": ["fk_model_id", "title", "type", "show"] + "title": "Base Request", + "type": "object" }, - "Table": { - "title": "Table Model", - "type": "object", + "Bool": { + "description": "Model for Bool", + "examples": [true], + "oneOf": [ + { + "description": "0 or 1", + "example": 0, + "type": "integer" + }, + { + "description": "true or false", + "type": "boolean" + }, + { + "type": "null" + } + ], + "title": "Bool Model" + }, + "Column": { + "description": "Model for Column", "examples": [ { - "id": "md_rsu68aqjsbyqtl", - "base_id": "ds_g4ccx6e77h1dmi", - "project_id": "p_xm3thidrblw4n7", - "table_name": "nc_vm5q___Table1", - "title": "Table1", - "type": "table", - "meta": null, - "schema": null, - "enabled": 1, - "mm": 0, - "tags": null, - "pinned": null, + "ai": 0, + "au": 0, + "base_id": "ds_krsappzu9f8vmo", + "cc": "", + "cdf": null, + "clen": "45", + "column_name": "title", + "cop": "2", + "created_at": "2023-03-02 13:14:16", + "csn": "utf8mb4", + "ct": "varchar(45)", "deleted": null, - "order": 1, - "created_at": "2023-03-02 17:04:06", - "updated_at": "2023-03-02 17:04:08", - "columns": [ + "dt": "varchar", + "dtx": "specificType", + "dtxp": "45", + "dtxs": null, + "fk_model_id": "md_yvwvbt2i78rgcm", + "id": "cl_0j9gv0oi8vjy46", + "meta": null, + "np": null, + "ns": null, + "order": 2, + "pk": 0, + "project_id": "p_01clqvzik3izk6", + "pv": 1, + "rqd": 0, + "system": 0, + "title": "Title", + "uidt": "SingleLineText", + "un": 0, + "unique": 0, + "updated_at": "2023-03-02 13:14:16", + "validate": null, + "virtual": null + } + ], + "properties": { + "ai": { + "$ref": "#/components/schemas/Bool", + "description": "Is Auto-Increment?" + }, + "au": { + "$ref": "#/components/schemas/Bool", + "description": "Auto Update Timestamp" + }, + "base_id": { + "description": "Base ID that this column belongs to", + "example": "ds_krsappzu9f8vmo", + "type": "string" + }, + "cc": { + "description": "Column Comment", + "type": "string" + }, + "cdf": { + "description": "Column Default", + "type": "string" + }, + "clen": { + "description": "Character Maximum Length", + "oneOf": [ { - "id": "cl_phvuuwjrzcdo0g", - "base_id": "ds_g4ccx6e77h1dmi", - "project_id": "p_xm3thidrblw4n7", - "fk_model_id": "md_rsu68aqjsbyqtl", - "title": "Id", - "column_name": "id", - "uidt": "ID", - "dt": "int", - "np": "10", - "ns": "0", - "clen": null, - "cop": "1", - "pk": 1, - "pv": null, - "rqd": 1, - "un": 1, - "ct": "int unsigned", - "ai": 1, - "unique": 0, - "cdf": null, - "cc": "", - "csn": null, - "dtx": "specificType", - "dtxp": "", - "dtxs": "0", - "au": 0, - "validate": null, - "virtual": null, - "deleted": null, - "system": 0, - "order": 1, - "created_at": "2023-03-02 17:04:06", - "updated_at": "2023-03-02 17:04:06", - "meta": null + "type": "integer" }, { - "id": "cl_c5knoi4xs4sfpt", - "base_id": "ds_g4ccx6e77h1dmi", - "project_id": "p_xm3thidrblw4n7", - "fk_model_id": "md_rsu68aqjsbyqtl", - "title": "Title", - "column_name": "title", - "uidt": "SingleLineText", - "dt": "varchar", - "np": null, - "ns": null, - "clen": "45", - "cop": "2", - "pk": 0, - "pv": 1, - "rqd": 0, - "un": 0, - "ct": "varchar(45)", - "ai": 0, - "unique": 0, - "cdf": null, - "cc": "", - "csn": "utf8mb4", - "dtx": "specificType", - "dtxp": "45", - "dtxs": null, - "au": 0, - "validate": null, - "virtual": null, - "deleted": null, - "system": 0, - "order": 2, - "created_at": "2023-03-02 17:04:06", - "updated_at": "2023-03-02 17:04:06", - "meta": null + "type": "null" }, { - "id": "cl_jpl0qu4gj4rexq", - "base_id": "ds_g4ccx6e77h1dmi", - "project_id": "p_xm3thidrblw4n7", - "fk_model_id": "md_rsu68aqjsbyqtl", - "title": "CreatedAt", - "column_name": "created_at", - "uidt": "DateTime", - "dt": "timestamp", - "np": null, - "ns": null, - "clen": null, - "cop": "3", - "pk": 0, - "pv": null, - "rqd": 0, - "un": 0, - "ct": "timestamp", - "ai": 0, - "unique": 0, - "cdf": "CURRENT_TIMESTAMP", - "cc": "", - "csn": null, - "dtx": "specificType", - "dtxp": "0", - "dtxs": null, - "au": 0, - "validate": null, - "virtual": null, - "deleted": null, - "system": 0, - "order": 3, - "created_at": "2023-03-02 17:04:06", - "updated_at": "2023-03-02 17:04:06", - "meta": null + "type": "string" + } + ] + }, + "colOptions": { + "anyOf": [ + { + "$ref": "#/components/schemas/Formula" }, { - "id": "cl_m4wkaqgqqjzoeh", - "base_id": "ds_g4ccx6e77h1dmi", - "project_id": "p_xm3thidrblw4n7", - "fk_model_id": "md_rsu68aqjsbyqtl", - "title": "UpdatedAt", - "column_name": "updated_at", - "uidt": "DateTime", - "dt": "timestamp", - "np": null, - "ns": null, - "clen": null, - "cop": "4", - "pk": 0, - "pv": null, - "rqd": 0, - "un": 0, - "ct": "timestamp", - "ai": 0, - "unique": 0, - "cdf": "CURRENT_TIMESTAMP on update CURRENT_TIMESTAMP", - "cc": "", - "csn": null, - "dtx": "specificType", - "dtxp": "0", - "dtxs": null, - "au": 0, - "validate": null, - "virtual": null, - "deleted": null, - "system": 0, - "order": 4, - "created_at": "2023-03-02 17:04:06", - "updated_at": "2023-03-02 17:04:06", - "meta": null - } - ], - "views": [ + "$ref": "#/components/schemas/LinkToAnotherRecord" + }, { - "ptn": "nc_vm5q___Table1", - "_ptn": "Table1", - "ptype": "table", - "tn": "Table1", - "_tn": "Table1", - "table_meta": null, - "id": "vw_p2jcatxz4mvcfw", - "base_id": "ds_g4ccx6e77h1dmi", - "project_id": "p_xm3thidrblw4n7", - "fk_model_id": "md_rsu68aqjsbyqtl", - "title": "Table1", - "type": 3, - "is_default": 1, - "show_system_fields": null, - "lock_type": "collaborative", - "uuid": null, - "password": null, - "show": 1, - "order": 1, - "created_at": "2023-03-02 17:04:06", - "updated_at": "2023-03-02 17:04:06", - "meta": {}, - "view": { - "fk_view_id": "vw_p2jcatxz4mvcfw", - "base_id": "ds_g4ccx6e77h1dmi", - "project_id": "p_xm3thidrblw4n7", - "uuid": null, - "created_at": "2023-03-02 17:04:06", - "updated_at": "2023-03-02 17:04:06", - "meta": null, - "row_height": null - }, - "disabled": { - "owner": false, - "creator": false, - "viewer": false, - "editor": false, - "commenter": false, - "guest": false - } + "$ref": "#/components/schemas/Lookup" + }, + { + "$ref": "#/components/schemas/Rollup" + }, + { + "$ref": "#/components/schemas/SelectOptions" + }, + { + "type": "object" } ], - "columnsById": { - "cl_phvuuwjrzcdo0g": { - "id": "cl_phvuuwjrzcdo0g", - "base_id": "ds_g4ccx6e77h1dmi", - "project_id": "p_xm3thidrblw4n7", - "fk_model_id": "md_rsu68aqjsbyqtl", - "title": "Id", - "column_name": "id", - "uidt": "ID", - "dt": "int", - "np": "10", - "ns": "0", - "clen": null, - "cop": "1", - "pk": 1, - "pv": null, - "rqd": 1, - "un": 1, - "ct": "int unsigned", - "ai": 1, - "unique": 0, - "cdf": null, - "cc": "", - "csn": null, - "dtx": "specificType", - "dtxp": "", - "dtxs": "0", - "au": 0, - "validate": null, - "virtual": null, - "deleted": null, - "system": 0, - "order": 1, - "created_at": "2023-03-02 17:04:06", - "updated_at": "2023-03-02 17:04:06", - "meta": null + "description": "Column Options" + }, + "column_name": { + "description": "Column Name", + "example": "title", + "type": "string" + }, + "cop": { + "description": "Column Ordinal Position", + "type": "string" + }, + "csn": { + "description": "Character Set Name", + "example": "utf8mb4", + "type": "string" + }, + "ct": { + "description": "Column Type", + "example": "varchar(45)", + "type": "string" + }, + "deleted": { + "$ref": "#/components/schemas/Bool", + "description": "Is Deleted?" + }, + "dt": { + "description": "Data Type in DB", + "example": "varchar", + "type": "string" + }, + "dtx": { + "description": "Data Type X", + "example": "specificType", + "type": "string" + }, + "dtxp": { + "description": "Data Type X Precision", + "oneOf": [ + { + "type": "null" }, - "cl_c5knoi4xs4sfpt": { - "id": "cl_c5knoi4xs4sfpt", - "base_id": "ds_g4ccx6e77h1dmi", - "project_id": "p_xm3thidrblw4n7", - "fk_model_id": "md_rsu68aqjsbyqtl", - "title": "Title", - "column_name": "title", - "uidt": "SingleLineText", - "dt": "varchar", - "np": null, - "ns": null, - "clen": "45", - "cop": "2", - "pk": 0, - "pv": 1, - "rqd": 0, - "un": 0, - "ct": "varchar(45)", - "ai": 0, - "unique": 0, - "cdf": null, - "cc": "", - "csn": "utf8mb4", - "dtx": "specificType", - "dtxp": "45", - "dtxs": null, - "au": 0, - "validate": null, - "virtual": null, - "deleted": null, - "system": 0, - "order": 2, - "created_at": "2023-03-02 17:04:06", - "updated_at": "2023-03-02 17:04:06", - "meta": null + { + "type": "number" }, - "cl_jpl0qu4gj4rexq": { - "id": "cl_jpl0qu4gj4rexq", - "base_id": "ds_g4ccx6e77h1dmi", - "project_id": "p_xm3thidrblw4n7", - "fk_model_id": "md_rsu68aqjsbyqtl", - "title": "CreatedAt", - "column_name": "created_at", - "uidt": "DateTime", - "dt": "timestamp", - "np": null, - "ns": null, - "clen": null, - "cop": "3", - "pk": 0, - "pv": null, - "rqd": 0, - "un": 0, - "ct": "timestamp", - "ai": 0, - "unique": 0, - "cdf": "CURRENT_TIMESTAMP", - "cc": "", - "csn": null, - "dtx": "specificType", - "dtxp": "0", - "dtxs": null, - "au": 0, - "validate": null, - "virtual": null, - "deleted": null, - "system": 0, - "order": 3, - "created_at": "2023-03-02 17:04:06", - "updated_at": "2023-03-02 17:04:06", - "meta": null + { + "type": "string" + } + ] + }, + "dtxs": { + "description": "Data Type X Scale", + "oneOf": [ + { + "type": "null" }, - "cl_m4wkaqgqqjzoeh": { - "id": "cl_m4wkaqgqqjzoeh", - "base_id": "ds_g4ccx6e77h1dmi", - "project_id": "p_xm3thidrblw4n7", - "fk_model_id": "md_rsu68aqjsbyqtl", - "title": "UpdatedAt", - "column_name": "updated_at", - "uidt": "DateTime", - "dt": "timestamp", - "np": null, - "ns": null, - "clen": null, - "cop": "4", - "pk": 0, - "pv": null, - "rqd": 0, - "un": 0, - "ct": "timestamp", - "ai": 0, - "unique": 0, - "cdf": "CURRENT_TIMESTAMP on update CURRENT_TIMESTAMP", - "cc": "", - "csn": null, - "dtx": "specificType", - "dtxp": "0", - "dtxs": null, - "au": 0, - "validate": null, - "virtual": null, - "deleted": null, - "system": 0, - "order": 4, - "created_at": "2023-03-02 17:04:06", - "updated_at": "2023-03-02 17:04:06", - "meta": null + { + "type": "number" + }, + { + "type": "string" } - } - } - ], - "description": "Model for Table", - "properties": { + ] + }, + "fk_model_id": { + "description": "Model ID that this column belongs to", + "example": "md_yvwvbt2i78rgcm", + "type": "string" + }, "id": { - "type": "string", - "description": "Unique Table ID" + "$ref": "#/components/schemas/Id", + "description": "Unique ID" }, - "project_id": { - "type": "string", - "description": "Unique Project ID" + "meta": { + "$ref": "#/components/schemas/Meta", + "description": "Meta Info" }, - "base_id": { - "type": "string", - "description": "Unique Base ID" + "np": { + "description": "Numeric Precision", + "oneOf": [ + { + "type": "integer" + }, + { + "type": "null" + }, + { + "type": "string" + } + ] }, - "table_name": { - "type": "string", - "description": "Table Name. Prefix will be added for XCDB projects." + "ns": { + "description": "Numeric Scale", + "oneOf": [ + { + "type": "integer" + }, + { + "type": "null" + }, + { + "type": "string" + } + ] }, - "title": { - "type": "string", - "description": "Table Title" + "order": { + "description": "The order of the list of columns", + "type": "number" }, - "type": { - "type": "string", - "description": "Table Type" + "pk": { + "$ref": "#/components/schemas/Bool", + "description": "Is Primary Key?" }, - "enabled": { + "pv": { "$ref": "#/components/schemas/Bool", - "description": "Is this table enabled?" + "description": "Is Primary Value?" }, - "tags": { - "type": "string", - "description": "Currently not in use" + "rqd": { + "$ref": "#/components/schemas/Bool", + "description": "Is Required?" }, - "pinned": { + "system": { "$ref": "#/components/schemas/Bool", - "description": "Currently not in use" + "description": "Is System Colun?" }, - "deleted": { - "$ref": "#/components/schemas/Bool" + "title": { + "description": "Column Title", + "example": "Title", + "type": "string" }, - "order": { - "type": "number", - "description": "The order of the list of tables" - }, - "columns": { - "type": "array", - "description": "The columns included in this table", - "items": { - "$ref": "#/components/schemas/Column" - } + "uidt": { + "description": "The data type in UI", + "example": "SingleLineText", + "type": "string" }, - "columnsById": { - "type": "object", - "description": "Column Models grouped by IDs" + "un": { + "$ref": "#/components/schemas/Bool", + "description": "Is Unsigned?" }, - "mm": { + "unique": { "$ref": "#/components/schemas/Bool", - "description": "Is this table used for M2M" + "description": "Is unique?" }, - "meta": { - "$ref": "#/components/schemas/Meta", - "description": "Meta Data" + "visible": { + "$ref": "#/components/schemas/Bool", + "description": "Is Visible?" } }, - "required": ["table_name", "title"] + "title": "Column Model", + "type": "object" }, - "TableReq": { - "title": "Table Request Model", - "type": "object", - "description": "Model for Table Request", - "properties": { - "table_name": { - "type": "string", - "description": "Table name", - "example": "my_table", - "minLength": 1, - "maxLength": 255 - }, - "title": { - "type": "string", - "description": "Table title", - "example": "My Table", - "minLength": 1, - "maxLength": 255 - }, - "order": { - "type": "number", - "example": 1, - "description": "The order of table list" - }, - "columns": { - "type": "array", - "description": "The column models in this table", - "items": { - "$ref": "#/components/schemas/NormalColumnRequest" - } - }, - "meta": { - "$ref": "#/components/schemas/Meta", - "description": "the meta data for this table" - } - }, - "required": ["table_name", "title", "columns"], + "ColumnList": { + "description": "Model for Column List", "examples": [ { - "title": "Sheet-1", - "table_name": "Sheet-1", - "columns": [ - { - "column_name": "id", - "title": "Id", - "dt": "int", - "dtx": "integer", - "ct": "int(11)", - "nrqd": false, - "rqd": true, - "ck": false, - "pk": true, - "un": true, - "ai": true, - "cdf": null, - "clen": null, - "np": 11, - "ns": 0, - "dtxp": "11", - "dtxs": "", - "altered": 1, - "uidt": "ID", - "uip": "", - "uicn": "" - }, - { - "column_name": "title", - "title": "Title", - "dt": "varchar", - "dtx": "specificType", - "ct": "varchar(45)", - "nrqd": true, - "rqd": false, - "ck": false, - "pk": false, - "un": false, - "ai": false, - "cdf": null, - "clen": 45, - "np": null, - "ns": null, - "dtxp": "45", - "dtxs": "", - "altered": 1, - "uidt": "SingleLineText", - "uip": "", - "uicn": "" - }, - { - "column_name": "created_at", - "title": "CreatedAt", - "dt": "timestamp", - "dtx": "specificType", - "ct": "varchar(45)", - "nrqd": true, - "rqd": false, - "ck": false, - "pk": false, - "un": false, - "ai": false, - "cdf": "CURRENT_TIMESTAMP", - "clen": 45, - "np": null, - "ns": null, - "dtxp": "", - "dtxs": "", - "altered": 1, - "uidt": "DateTime", - "uip": "", - "uicn": "" - }, - { - "column_name": "updated_at", - "title": "UpdatedAt", - "dt": "timestamp", - "dtx": "specificType", - "ct": "varchar(45)", - "nrqd": true, - "rqd": false, - "ck": false, - "pk": false, - "un": false, - "ai": false, - "cdf": "CURRENT_TIMESTAMP on update CURRENT_TIMESTAMP", - "clen": 45, - "np": null, - "ns": null, - "dtxp": "", - "dtxs": "", - "altered": 1, - "uidt": "DateTime", - "uip": "", - "uicn": "" + "columns": { + "list": [ + { + "ai": 0, + "au": 0, + "base_id": "ds_krsappzu9f8vmo", + "cc": "", + "cdf": null, + "clen": "1", + "colOptions": { + "options": [ + { + "color": "#c2f5e8", + "fk_column_id": "cl_vnrvdzwnk6uuov", + "id": "sl_uabhxfapw4frlg", + "order": 3, + "title": "c" + }, + { + "color": "#cfdffe", + "fk_column_id": "cl_vnrvdzwnk6uuov", + "id": "sl_mb8fkdvgudzu3r", + "order": 1, + "title": "a" + }, + { + "color": "#d0f1fd", + "fk_column_id": "cl_vnrvdzwnk6uuov", + "id": "sl_31uj9j02qacl7c", + "order": 2, + "title": "b" + } + ] + }, + "column_name": "SingleSelect", + "cop": "5", + "created_at": "2023-03-03 11:32:59", + "csn": "utf8mb4", + "ct": "enum('a','b','c')", + "deleted": null, + "dt": "enum", + "dtx": "specificType", + "dtxp": "'a','b','c'", + "dtxs": null, + "fk_model_id": "md_yvwvbt2i78rgcm", + "id": "cl_vnrvdzwnk6uuov", + "meta": {}, + "np": null, + "ns": null, + "order": null, + "pk": 0, + "project_id": "p_01clqvzik3izk6", + "pv": null, + "rqd": 0, + "system": 0, + "title": "SingleSelect", + "uidt": "SingleSelect", + "un": 0, + "unique": 0, + "updated_at": "2023-03-03 11:32:59", + "validate": null, + "virtual": null + } + ] + } + } + ], + "properties": { + "columns": { + "properties": { + "list": { + "items": { + "$ref": "#/components/schemas/Column" + }, + "minItems": 1, + "type": "array", + "uniqueItems": true } - ] + }, + "required": ["list"], + "type": "object" } - ] - }, - "TableList": { - "description": "Model for Table List", + }, + "required": ["columns"], + "title": "Column List Model", "type": "object", "x-examples": { "example-1": { "bases": { "list": [ { - "id": "string", - "project_id": "string", "alias": "string", - "host": "string", - "port": 0, - "username": "string", - "password": "string", "database": "string", - "url": "string", + "host": "string", + "id": "string", "params": "string", + "password": "string", + "port": 0, + "project_id": "string", + "ssl": "string", "type": "string", - "ssl": "string" + "url": "string", + "username": "string" } ], "pageInfo": { + "isFirstPage": true, + "isLastPage": true, "pageSize": 0, - "totalRows": 0, "sort": "string", - "isFirstPage": true, - "isLastPage": true + "totalRows": 0 } } } - }, - "properties": { - "list": { - "type": "array", - "uniqueItems": true, - "minItems": 1, - "items": { - "$ref": "#/components/schemas/Table" - } - }, - "pageInfo": { - "$ref": "#/components/schemas/Paginated" - } - }, - "required": ["tables"], - "title": "Table List Model", - "examples": [ + } + }, + "ColumnReq": { + "allOf": [ { - "list": [ + "anyOf": [ { - "id": "string", - "project_id": "string", - "base_id": "string", - "title": "string", - "alias": "string", - "type": "string", - "enabled": true, - "parent_id": "string", - "show_as": "string", - "tags": "string", - "pinned": true, - "deleted": true, - "order": 0, - "column": [ - { - "id": "string", - "base_id": "string", - "fk_model_id": "string", - "title": "string", - "alias": "string", - "ui_data_type": "string", - "data_type": "string", - "numeric_precision": "string", - "numeric_scale": "string", - "character_maximum_length": "string", - "column_ordinal_position": "string", - "primary_key": true, - "primary_value": true, - "rqd": "string", - "un": "string", - "column_type": "string", - "auto_increment": true, - "unique": true, - "column_default": "string", - "column_comment": "string", - "character_set_name": "string", - "data_type_x": "string", - "data_type_x_precision": "string", - "data_type_x_scale": "string", - "auto_update_timestamp": true, - "deleted": true, - "visible": true, - "order": 0, - "colOptions": { - "id": "string", - "type": "string", - "virtual": true, - "fk_column_id": "string", - "fk_child_column_id": "string", - "fk_parent_column_id": "string", - "fk_mm_model_id": "string", - "fk_mm_child_column_id": "string", - "fk_mm_parent_column_id": "string", - "ur": "string", - "dr": "string", - "fk_index_name": "string", - "deleted": "string", - "order": "string" - } + "$ref": "#/components/schemas/FormulaColumnReq" + }, + { + "$ref": "#/components/schemas/LinkToAnotherColumnReq" + }, + { + "$ref": "#/components/schemas/LookupColumnReq" + }, + { + "$ref": "#/components/schemas/NormalColumnRequest" + }, + { + "$ref": "#/components/schemas/RollupColumnReq" + } + ] + }, + { + "properties": { + "column_name": { + "type": "string" + }, + "column_order": { + "description": "Column order in a specific view", + "properties": { + "order": { + "type": "number" + }, + "view_id": { + "type": "string" } - ], - "columnByIds": {} + }, + "type": "object" + }, + "title": { + "maxLength": 255, + "minLength": 1, + "type": "string" } - ], - "pageInfo": { - "pageSize": 10, - "totalRows": 1, - "isFirstPage": true, - "isLastPage": true, - "page": 1 - } + }, + "required": ["column_name", "title"] } - ] + ], + "description": "Model for Column Request", + "examples": [ + { + "childId": "string", + "column_name": "string", + "column_order": { + "order": 0, + "view_id": "string" + }, + "parentId": "string", + "title": "string", + "type": "hm", + "uidt": "LinkToAnotherRecord", + "virtual": true + } + ], + "title": "Column Request Model", + "type": "object" + }, + "CommentReq": { + "description": "Model for Comment Request", + "examples": [ + { + "description": "string", + "fk_model_id": "string", + "row_id": "string" + } + ], + "properties": { + "description": { + "type": "string" + }, + "fk_model_id": { + "type": "string" + }, + "row_id": { + "type": "string" + } + }, + "required": ["comment", "fk_model_id", "row_id"], + "title": "Comment Request Model", + "type": "object" }, "Filter": { - "type": "object", - "title": "Filter Model", "description": "Model for Filter", "examples": [ { - "id": "fi_xn647tpmdq8fu8", "base_id": "ds_g4ccx6e77h1dmi", - "project_id": "p_xm3thidrblw4n7", - "fk_view_id": "vw_b739e29vqmrxnf", - "fk_hook_id": null, + "comparison_op": "eq", + "comparison_sub_op": null, + "created_at": "2023-03-02 18:18:05", "fk_column_id": "cl_d7ah9n2qfupgys", + "fk_hook_id": null, "fk_parent_id": null, - "logical_op": "and", - "comparison_op": "eq", - "value": "foo", + "fk_view_id": "vw_b739e29vqmrxnf", + "id": "fi_xn647tpmdq8fu8", "is_group": null, + "logical_op": "and", "order": 1, - "created_at": "2023-03-02 18:18:05", + "project_id": "p_xm3thidrblw4n7", "updated_at": "2023-03-02 18:18:05", - "comparison_sub_op": null + "value": "foo" } ], "properties": { - "id": { - "$ref": "#/components/schemas/Id", - "description": "Unique ID" - }, - "fk_model_id": { - "$ref": "#/components/schemas/Id", - "description": "Foreign Key to Model" - }, - "fk_column_id": { - "$ref": "#/components/schemas/Id", - "description": "Foreign Key to Column" + "base_id": { + "description": "Unqiue Base ID", + "readOnly": true, + "type": "string" }, - "logical_op": { - "type": "string", - "enum": ["and", "or", "not"], - "description": "Logical Operator" + "children": { + "description": "Children filters. Available when the filter is grouped.", + "items": { + "$ref": "#/components/schemas/Filter" + }, + "type": "array" }, "comparison_op": { - "type": "string", + "description": "Comparison Operator", "enum": [ - "eq", - "neq", - "not", - "like", - "nlike", - "empty", - "notempty", - "null", - "notnull", - "checked", - "notchecked", - "blank", - "notblank", "allof", "anyof", - "nallof", - "nanyof", + "blank", + "btw", + "checked", + "empty", + "eq", + "ge", "gt", - "lt", "gte", - "lte", - "ge", - "le", "in", - "isnot", "is", "isWithin", - "btw", - "nbtw" + "isnot", + "le", + "like", + "lt", + "lte", + "nallof", + "nanyof", + "nbtw", + "neq", + "nlike", + "not", + "notblank", + "notchecked", + "notempty", + "notnull", + "null" ], - "description": "Comparison Operator" + "type": "string" }, "comparison_sub_op": { - "description": "Comparison Sub-Operator", "anyOf": [ { - "type": "string", "enum": [ - "pastWeek", - "pastMonth", - "pastYear", - "nextWeek", + "daysAgo", + "daysFromNow", + "exactDate", "nextMonth", + "nextNumberOfDays", + "nextWeek", "nextYear", + "oneMonthAgo", + "oneMonthFromNow", + "oneWeekAgo", + "oneWeekFromNow", + "pastMonth", "pastNumberOfDays", - "nextNumberOfDays", + "pastWeek", + "pastYear", "today", "tomorrow", - "yesterday", - "oneWeekAgo", - "oneWeekFromNow", - "oneMonthAgo", - "oneMonthFromNow", - "daysAgo", - "daysFromNow", - "exactDate" - ] + "yesterday" + ], + "type": "string" }, { "type": "null" } - ] + ], + "description": "Comparison Sub-Operator" }, - "value": { - "description": "The filter value. Can be NULL for some operators." + "fk_column_id": { + "$ref": "#/components/schemas/Id", + "description": "Foreign Key to Column" + }, + "fk_hook_id": { + "$ref": "#/components/schemas/StringOrNull", + "description": "Foreign Key to Hook" + }, + "fk_model_id": { + "$ref": "#/components/schemas/Id", + "description": "Foreign Key to Model" + }, + "fk_parent_id": { + "$ref": "#/components/schemas/StringOrNull", + "description": "Foreign Key to parent group." + }, + "fk_view_id": { + "$ref": "#/components/schemas/StringOrNull", + "description": "Foreign Key to View" + }, + "id": { + "$ref": "#/components/schemas/Id", + "description": "Unique ID" }, "is_group": { + "description": "Is this filter grouped?", "oneOf": [ { "type": "boolean" @@ -9062,3720 +8545,4237 @@ { "type": "null" } - ], - "description": "Is this filter grouped?" + ] }, - "children": { - "type": "array", - "description": "Children filters. Available when the filter is grouped.", - "items": { - "$ref": "#/components/schemas/Filter" - } + "logical_op": { + "description": "Logical Operator", + "enum": ["and", "not", "or"], + "type": "string" }, "project_id": { - "type": "string", "description": "Unique Project ID", - "readOnly": true - }, - "base_id": { - "type": "string", - "description": "Unqiue Base ID", - "readOnly": true - }, - "fk_parent_id": { - "$ref": "#/components/schemas/StringOrNull", - "description": "Foreign Key to parent group." - }, - "fk_view_id": { - "$ref": "#/components/schemas/StringOrNull", - "description": "Foreign Key to View" + "readOnly": true, + "type": "string" }, - "fk_hook_id": { - "$ref": "#/components/schemas/StringOrNull", - "description": "Foreign Key to Hook" + "value": { + "description": "The filter value. Can be NULL for some operators." } }, - "readOnly": true + "readOnly": true, + "title": "Filter Model", + "type": "object" }, - "FilterReq": { + "FilterList": { + "description": "Model for Filter List", + "examples": [ + { + "filters": { + "list": [ + { + "base_id": "ds_g4ccx6e77h1dmi", + "comparison_op": "eq", + "comparison_sub_op": null, + "created_at": "2023-03-02 18:18:05", + "fk_column_id": "cl_d7ah9n2qfupgys", + "fk_hook_id": null, + "fk_parent_id": null, + "fk_view_id": "vw_b739e29vqmrxnf", + "id": "fi_xn647tpmdq8fu8", + "is_group": null, + "logical_op": "and", + "order": 1, + "project_id": "p_xm3thidrblw4n7", + "updated_at": "2023-03-02 18:18:05", + "value": "foo" + }, + { + "base_id": "ds_g4ccx6e77h1dmi", + "comparison_op": "nlike", + "comparison_sub_op": null, + "created_at": "2023-03-02 18:21:52", + "fk_column_id": "cl_d7ah9n2qfupgys", + "fk_hook_id": null, + "fk_parent_id": null, + "fk_view_id": "vw_b739e29vqmrxnf", + "id": "fi_wl91o3rf6rs0fq", + "is_group": null, + "logical_op": "and", + "order": 2, + "project_id": "p_xm3thidrblw4n7", + "updated_at": "2023-03-02 18:21:52", + "value": "bar" + } + ] + } + } + ], + "properties": { + "filters": { + "properties": { + "list": { + "items": { + "$ref": "#/components/schemas/Filter" + }, + "minItems": 1, + "type": "array", + "uniqueItems": true + } + }, + "required": ["list"], + "type": "object" + } + }, + "required": ["filters"], + "title": "Filter List Model", "type": "object", - "title": "Filter Request Model", + "x-examples": { + "example-1": { + "bases": { + "list": [ + { + "alias": "string", + "database": "string", + "host": "string", + "id": "string", + "params": "string", + "password": "string", + "port": 0, + "project_id": "string", + "ssl": "string", + "type": "string", + "url": "string", + "username": "string" + } + ], + "pageInfo": { + "isFirstPage": true, + "isLastPage": true, + "pageSize": 0, + "sort": "string", + "totalRows": 0 + } + } + } + } + }, + "FilterReq": { "description": "Model for Filter Request", + "examples": [ + { + "comparison_op": "eq", + "comparison_sub_op": null, + "fk_column_id": "cl_d7ah9n2qfupgys", + "is_group": false, + "logical_op": "and", + "value": "foo" + } + ], "properties": { - "fk_column_id": { - "$ref": "#/components/schemas/Id", - "description": "Foreign Key to Column" - }, - "logical_op": { - "type": "string", - "enum": ["and", "or", "not"], - "description": "Logical Operator" - }, "comparison_op": { - "type": "string", + "description": "Comparison Operator", "enum": [ - "eq", - "neq", - "not", - "like", - "nlike", - "empty", - "notempty", - "null", - "notnull", - "checked", - "notchecked", - "blank", - "notblank", "allof", "anyof", - "nallof", - "nanyof", + "blank", + "btw", + "checked", + "empty", + "eq", + "ge", "gt", - "lt", "gte", - "lte", - "ge", - "le", "in", - "isnot", "is", "isWithin", - "btw", - "nbtw" + "isnot", + "le", + "like", + "lt", + "lte", + "nallof", + "nanyof", + "nbtw", + "neq", + "nlike", + "not", + "notblank", + "notchecked", + "notempty", + "notnull", + "null" ], - "description": "Comparison Operator" + "type": "string" }, "comparison_sub_op": { - "description": "Comparison Sub-Operator", "anyOf": [ { - "type": "string", "enum": [ - "pastWeek", - "pastMonth", - "pastYear", - "nextWeek", + "daysAgo", + "daysFromNow", + "exactDate", "nextMonth", + "nextNumberOfDays", + "nextWeek", "nextYear", + "oneMonthAgo", + "oneMonthFromNow", + "oneWeekAgo", + "oneWeekFromNow", + "pastMonth", "pastNumberOfDays", - "nextNumberOfDays", + "pastWeek", + "pastYear", "today", "tomorrow", - "yesterday", - "oneWeekAgo", - "oneWeekFromNow", - "oneMonthAgo", - "oneMonthFromNow", - "daysAgo", - "daysFromNow", - "exactDate" - ] + "yesterday" + ], + "type": "string" }, { "type": "null" } - ] + ], + "description": "Comparison Sub-Operator" }, - "value": { - "description": "The filter value. Can be NULL for some operators." + "fk_column_id": { + "$ref": "#/components/schemas/Id", + "description": "Foreign Key to Column" + }, + "fk_parent_id": { + "$ref": "#/components/schemas/Id", + "description": "Belong to which filter ID" }, "is_group": { "$ref": "#/components/schemas/Bool", "description": "Is this filter grouped?" }, - "fk_parent_id": { - "$ref": "#/components/schemas/Id", - "description": "Belong to which filter ID" + "logical_op": { + "description": "Logical Operator", + "enum": ["and", "not", "or"], + "type": "string" + }, + "value": { + "description": "The filter value. Can be NULL for some operators." } }, "readOnly": true, + "title": "Filter Request Model", + "type": "object" + }, + "Form": { + "description": "Model for Form", "examples": [ { - "fk_column_id": "cl_d7ah9n2qfupgys", - "logical_op": "and", - "comparison_op": "eq", - "comparison_sub_op": null, - "value": "foo", - "is_group": false - } - ] - }, - "FilterList": { - "description": "Model for Filter List", - "type": "object", - "x-examples": { - "example-1": { - "bases": { - "list": [ - { - "id": "string", - "project_id": "string", - "alias": "string", - "host": "string", - "port": 0, - "username": "string", - "password": "string", - "database": "string", - "url": "string", - "params": "string", - "type": "string", - "ssl": "string" - } - ], - "pageInfo": { - "pageSize": 0, - "totalRows": 0, - "sort": "string", - "isFirstPage": true, - "isLastPage": true - } - } - } - }, - "properties": { - "filters": { - "type": "object", - "required": ["list"], - "properties": { - "list": { - "type": "array", - "uniqueItems": true, - "minItems": 1, - "items": { - "$ref": "#/components/schemas/Filter" - } + "banner_image_url": "string", + "columns": [ + { + "created_at": "string", + "description": "string", + "fk_column_id": "string", + "fk_view_id": "string", + "help": null, + "id": "string", + "label": "string", + "meta": {}, + "order": 0, + "required": true, + "show": true, + "updated_at": "string", + "uuid": null } - } - } - }, - "required": ["filters"], - "title": "Filter List Model", - "examples": [ - { - "filters": { - "list": [ - { - "id": "fi_wl91o3rf6rs0fq", - "base_id": "ds_g4ccx6e77h1dmi", - "project_id": "p_xm3thidrblw4n7", - "fk_view_id": "vw_b739e29vqmrxnf", - "fk_hook_id": null, - "fk_column_id": "cl_d7ah9n2qfupgys", - "fk_parent_id": null, - "logical_op": "and", - "comparison_op": "nlike", - "value": "bar", - "is_group": null, - "order": 2, - "created_at": "2023-03-02 18:21:52", - "updated_at": "2023-03-02 18:21:52", - "comparison_sub_op": null - }, - { - "id": "fi_xn647tpmdq8fu8", - "base_id": "ds_g4ccx6e77h1dmi", - "project_id": "p_xm3thidrblw4n7", - "fk_view_id": "vw_b739e29vqmrxnf", - "fk_hook_id": null, - "fk_column_id": "cl_d7ah9n2qfupgys", - "fk_parent_id": null, - "logical_op": "and", - "comparison_op": "eq", - "value": "foo", - "is_group": null, - "order": 1, - "created_at": "2023-03-02 18:18:05", - "updated_at": "2023-03-02 18:18:05", - "comparison_sub_op": null - } - ] - } + ], + "email": "string", + "fk_model_id": "string", + "heading": "string", + "id": "string", + "lock_type": "collaborative", + "logo_url": "string", + "meta": {}, + "redirect_after_secs": "string", + "redirect_url": "string", + "show_blank_form": true, + "subheading": "string", + "submit_another_form": true, + "success_msg": "string", + "title": "string" } - ] - }, - "Sort": { - "title": "Sort Model", - "type": "object", + ], "properties": { + "banner_image_url": { + "$ref": "#/components/schemas/StringOrNull" + }, + "columns": { + "items": { + "$ref": "#/components/schemas/FormColumn" + }, + "type": "array" + }, + "email": { + "$ref": "#/components/schemas/StringOrNull" + }, + "fk_model_id": { + "type": "string" + }, + "heading": { + "type": "string" + }, "id": { "$ref": "#/components/schemas/Id", "description": "Unique ID" }, - "fk_model_id": { - "$ref": "#/components/schemas/Id" + "lock_type": { + "enum": ["collaborative", "locked", "personal"], + "type": "string" }, - "fk_column_id": { - "$ref": "#/components/schemas/Id" + "logo_url": { + "$ref": "#/components/schemas/StringOrNull" }, - "direction": { + "meta": { + "$ref": "#/components/schemas/Meta" + }, + "redirect_after_secs": { + "$ref": "#/components/schemas/StringOrNull" + }, + "redirect_url": { + "$ref": "#/components/schemas/StringOrNull" + }, + "show_blank_form": { + "$ref": "#/components/schemas/Bool" + }, + "subheading": { "type": "string" }, - "order": { - "type": "number" + "submit_another_form": { + "$ref": "#/components/schemas/Bool" }, - "project_id": { - "type": "string", - "readOnly": true + "success_msg": { + "type": "string" }, - "base_id": { - "type": "string", - "readOnly": true + "title": { + "type": "string" } }, - "description": "Model for Sort", + "title": "Form Model", + "type": "object" + }, + "FormColumn": { + "description": "Model for Form Column", "examples": [ { - "id": "string", - "fk_model_id": "string", + "created_at": "string", + "description": "string", "fk_column_id": "string", - "direction": "string", + "fk_view_id": "string", + "help": null, + "id": "string", + "label": "string", + "meta": {}, "order": 0, - "project_id": "string", - "base_id": "string" + "required": true, + "show": true, + "updated_at": "string", + "uuid": null } - ] - }, - "SortReq": { - "title": "Sort Request Model", - "type": "object", - "minProperties": 1, - "description": "Model for Sort Request", + ], "properties": { + "created_at": { + "minLength": 1, + "type": "string" + }, + "description": { + "minLength": 1, + "type": "string" + }, "fk_column_id": { "$ref": "#/components/schemas/Id", - "description": "Foreign Key to Column" + "description": "Foreign Key to Column", + "minLength": 1 }, - "direction": { - "type": "string", - "enum": ["asc", "desc"], - "description": "Sort direction" - } + "fk_view_id": { + "minLength": 1, + "type": "string" + }, + "help": {}, + "id": { + "minLength": 1, + "type": "string" + }, + "label": { + "minLength": 1, + "type": "string" + }, + "meta": { + "$ref": "#/components/schemas/Meta" + }, + "order": { + "type": "number" + }, + "required": { + "$ref": "#/components/schemas/Bool" + }, + "show": { + "$ref": "#/components/schemas/Bool" + }, + "updated_at": { + "minLength": 1, + "type": "string" + }, + "uuid": {} }, - "examples": [ - { - "fk_column_id": "string", - "direction": "asc" - } - ] - }, - "SortList": { - "description": "Model for Sort List", + "title": "Form Column Model", "type": "object", "x-examples": { "example-1": { - "bases": { - "list": [ - { - "id": "string", - "project_id": "string", - "alias": "string", - "host": "string", - "port": 0, - "username": "string", - "password": "string", - "database": "string", - "url": "string", - "params": "string", - "type": "string", - "ssl": "string" - } - ], - "pageInfo": { - "pageSize": 0, - "totalRows": 0, - "sort": "string", - "isFirstPage": true, - "isLastPage": true - } - } + "_cn": "first_name", + "alias": "first_name", + "created_at": "2022-02-15 12:39:04", + "description": "dsdsdsdsd", + "fk_column_id": "cl_yvyhsl9u81tokc", + "fk_view_id": "vw_s1pf4umdnikoyn", + "help": null, + "id": "fvc_8z1i7t8aswkqxx", + "label": "dsdsds", + "order": 1, + "required": false, + "show": 1, + "updated_at": "2022-02-15 12:39:16", + "uuid": null } - }, + } + }, + "FormColumnReq": { + "description": "Model for Form Column Request", + "examples": [ + { + "description": "string", + "help": "string", + "label": "string", + "meta": {}, + "order": 0, + "required": true, + "show": true + } + ], "properties": { - "sorts": { - "type": "object", - "required": ["list"], - "properties": { - "list": { - "type": "array", - "uniqueItems": true, - "minItems": 1, - "items": { - "$ref": "#/components/schemas/SharedView" - } - } - } + "description": { + "maxLength": 255, + "type": "string" + }, + "help": { + "maxLength": 255 + }, + "label": { + "maxLength": 255, + "minLength": 1, + "type": "string" + }, + "meta": { + "$ref": "#/components/schemas/Meta" + }, + "order": { + "type": "number" + }, + "required": { + "$ref": "#/components/schemas/Bool" + }, + "show": { + "$ref": "#/components/schemas/Bool" } }, - "required": ["sorts"], - "title": "Sort List Model", + "title": "Form Column Request Model", + "type": "object", + "x-examples": { + "example-1": { + "_cn": "first_name", + "alias": "first_name", + "created_at": "2022-02-15 12:39:04", + "description": "dsdsdsdsd", + "fk_column_id": "cl_yvyhsl9u81tokc", + "fk_view_id": "vw_s1pf4umdnikoyn", + "help": null, + "id": "fvc_8z1i7t8aswkqxx", + "label": "dsdsds", + "order": 1, + "required": false, + "show": 1, + "updated_at": "2022-02-15 12:39:16", + "uuid": null + } + } + }, + "FormCreateReq": { + "allOf": [ + { + "$ref": "#/components/schemas/FormReq" + }, + { + "required": ["title"] + } + ], + "description": "Model for Form Create", "examples": [ { - "sorts": { - "list": [ - { - "id": "string", - "fk_view_id": "string", - "password": "string", - "deleted": "string" - } - ] - } + "banner_image_url": "string", + "email": "string", + "heading": "My Form", + "lock_type": "collaborative", + "logo_url": "string", + "meta": {}, + "redirect_after_secs": "string", + "redirect_url": "string", + "show_blank_form": true, + "subheading": "My Form Subheading", + "submit_another_form": true, + "success_msg": "string", + "title": "My Form" } - ] + ], + "title": "Form Create Model" }, - "Column": { - "title": "Column Model", - "type": "object", - "description": "Model for Column", + "FormReq": { + "description": "Model for Form Request", "examples": [ { - "id": "cl_0j9gv0oi8vjy46", - "base_id": "ds_krsappzu9f8vmo", - "project_id": "p_01clqvzik3izk6", - "fk_model_id": "md_yvwvbt2i78rgcm", - "title": "Title", - "column_name": "title", - "uidt": "SingleLineText", - "dt": "varchar", - "np": null, - "ns": null, - "clen": "45", - "cop": "2", - "pk": 0, - "pv": 1, - "rqd": 0, - "un": 0, - "ct": "varchar(45)", - "ai": 0, - "unique": 0, - "cdf": null, - "cc": "", - "csn": "utf8mb4", - "dtx": "specificType", - "dtxp": "45", - "dtxs": null, - "au": 0, - "validate": null, - "virtual": null, - "deleted": null, - "system": 0, - "order": 2, - "created_at": "2023-03-02 13:14:16", - "updated_at": "2023-03-02 13:14:16", - "meta": null + "banner_image_url": "string", + "email": "string", + "heading": "My Form", + "lock_type": "collaborative", + "logo_url": "string", + "meta": {}, + "redirect_after_secs": "string", + "redirect_url": "string", + "show_blank_form": true, + "subheading": "My Form Subheading", + "submit_another_form": true, + "success_msg": "string", + "title": "My Form" } ], "properties": { - "id": { - "$ref": "#/components/schemas/Id", - "description": "Unique ID" + "banner_image_url": { + "$ref": "#/components/schemas/StringOrNull", + "description": "Banner Image URL. Not in use currently." }, - "base_id": { - "type": "string", - "description": "Base ID that this column belongs to", - "example": "ds_krsappzu9f8vmo" + "email": { + "$ref": "#/components/schemas/StringOrNull" }, - "fk_model_id": { - "type": "string", - "description": "Model ID that this column belongs to", - "example": "md_yvwvbt2i78rgcm" + "heading": { + "description": "The heading of the form", + "example": "My Form", + "maxLength": 255, + "type": "string" }, - "title": { - "type": "string", - "description": "Column Title", - "example": "Title" + "lock_type": { + "enum": ["collaborative", "locked", "personal"], + "type": "string" }, - "uidt": { - "type": "string", - "description": "The data type in UI", - "example": "SingleLineText" + "logo_url": { + "$ref": "#/components/schemas/StringOrNull", + "description": "Logo URL. Not in use currently." }, - "dt": { - "type": "string", - "description": "Data Type in DB", - "example": "varchar" + "meta": { + "$ref": "#/components/schemas/Meta", + "description": "Meta Info for this view" }, - "np": { - "oneOf": [ - { - "type": "string" - }, - { - "type": "integer" - }, - { - "type": "null" - } - ], - "description": "Numeric Precision" + "redirect_after_secs": { + "$ref": "#/components/schemas/StringOrNull", + "description": "The numbers of seconds to redirect after form submission" }, - "ns": { - "oneOf": [ - { - "type": "string" - }, - { - "type": "integer" - }, - { - "type": "null" - } - ], - "description": "Numeric Scale" + "redirect_url": { + "$ref": "#/components/schemas/StringOrNull", + "description": "URL to redirect after submission" }, - "clen": { - "oneOf": [ - { - "type": "string" - }, - { - "type": "integer" - }, - { - "type": "null" - } - ], - "description": "Character Maximum Length" - }, - "cop": { - "type": "string", - "description": "Column Ordinal Position" - }, - "pk": { + "show_blank_form": { "$ref": "#/components/schemas/Bool", - "description": "Is Primary Key?" + "description": "Show `Blank Form` after 5 seconds" }, - "pv": { - "$ref": "#/components/schemas/Bool", - "description": "Is Primary Value?" + "subheading": { + "description": "The subheading of the form", + "example": "My Form Subheading", + "maxLength": 255, + "type": "string" }, - "rqd": { + "submit_another_form": { "$ref": "#/components/schemas/Bool", - "description": "Is Required?" + "description": "Show `Submit Another Form` button" }, - "column_name": { + "success_msg": { + "$ref": "#/components/schemas/StringOrNull", + "description": "Custom message after the form is successfully submitted" + }, + "title": { + "description": "The title of the form", + "example": "My Form", + "maxLength": 255, + "minLength": 1, + "type": "string" + } + }, + "title": "Form Request Model", + "type": "object" + }, + "Formula": { + "description": "Model for Formula", + "examples": [ + { + "deleted": "string", + "fk_column_id": "string", + "formula": "string", + "formula_raw": "string", + "id": "string", + "order": "string", "type": "string", - "description": "Column Name", - "example": "title" + "virtual": true + } + ], + "properties": { + "deleted": { + "type": "string" }, - "un": { - "$ref": "#/components/schemas/Bool", - "description": "Is Unsigned?" + "fk_column_id": { + "$ref": "#/components/schemas/Id", + "description": "Foreign Key to Column" }, - "ct": { - "type": "string", - "description": "Column Type", - "example": "varchar(45)" + "formula": { + "type": "string" }, - "ai": { - "$ref": "#/components/schemas/Bool", - "description": "Is Auto-Increment?" + "formula_raw": { + "type": "string" }, - "unique": { - "$ref": "#/components/schemas/Bool", - "description": "Is unique?" + "id": { + "$ref": "#/components/schemas/Id", + "description": "Unique ID" }, - "cdf": { - "type": "string", - "description": "Column Default" + "order": { + "type": "string" }, - "cc": { - "type": "string", - "description": "Column Comment" + "type": { + "type": "string" }, - "csn": { - "type": "string", - "description": "Character Set Name", - "example": "utf8mb4" + "virtual": { + "$ref": "#/components/schemas/Bool" + } + }, + "title": "Formula Model", + "type": "object" + }, + "FormulaColumnReq": { + "description": "Model for Formula Column Request", + "examples": [ + { + "formula": "string", + "formula_raw": "string", + "title": "string", + "uidt": "Formula" + } + ], + "properties": { + "formula": { + "type": "string" }, - "dtx": { - "type": "string", - "description": "Data Type X", - "example": "specificType" + "formula_raw": { + "type": "string" }, - "dtxp": { - "oneOf": [ - { - "type": "string" - }, - { - "type": "number" - }, - { - "type": "null" - } - ], - "description": "Data Type X Precision" + "title": { + "maxLength": 255, + "minLength": 1, + "type": "string" }, - "dtxs": { - "oneOf": [ - { - "type": "string" - }, - { - "type": "number" - }, + "uidt": { + "enum": ["Formula"], + "type": "string" + } + }, + "title": "Formula Column Request Model", + "type": "object" + }, + "Gallery": { + "description": "Model for Gallery", + "examples": [ + { + "alias": "string", + "columns": [ { - "type": "null" + "fk_col_id": "string", + "fk_gallery_id": "string", + "help": "string", + "id": "string", + "label": "string" } ], - "description": "Data Type X Scale" + "cover_image": "string", + "cover_image_idx": 0, + "deleted": true, + "fk_cover_image_col_id": "string", + "fk_model_id": "string", + "fk_view_id": "string", + "lock_type": "collaborative", + "next_enabled": true, + "order": 0, + "prev_enabled": true, + "restrict_number": "string", + "restrict_size": "string", + "restrict_types": "string", + "title": "string" + } + ], + "properties": { + "alias": { + "type": "string" }, - "au": { - "$ref": "#/components/schemas/Bool", - "description": "Auto Update Timestamp" + "columns": { + "items": { + "$ref": "#/components/schemas/GalleryColumn" + }, + "type": "array" + }, + "cover_image": { + "type": "string" + }, + "cover_image_idx": { + "type": "integer" }, "deleted": { - "$ref": "#/components/schemas/Bool", - "description": "Is Deleted?" + "$ref": "#/components/schemas/Bool" }, - "visible": { - "$ref": "#/components/schemas/Bool", - "description": "Is Visible?" + "fk_cover_image_col_id": { + "type": "string" + }, + "fk_model_id": { + "type": "string" + }, + "fk_view_id": { + "type": "string" + }, + "lock_type": { + "enum": ["collaborative", "locked", "personal"], + "type": "string" + }, + "next_enabled": { + "$ref": "#/components/schemas/Bool" }, "order": { - "type": "number", - "description": "The order of the list of columns" + "type": "number" }, - "system": { - "$ref": "#/components/schemas/Bool", - "description": "Is System Colun?" + "prev_enabled": { + "$ref": "#/components/schemas/Bool" }, - "meta": { - "$ref": "#/components/schemas/Meta", - "description": "Meta Info" + "restrict_number": { + "type": "string" }, - "colOptions": { - "anyOf": [ - { - "$ref": "#/components/schemas/LinkToAnotherRecord" - }, - { - "$ref": "#/components/schemas/Formula" - }, - { - "$ref": "#/components/schemas/Rollup" - }, - { - "$ref": "#/components/schemas/Lookup" - }, - { - "$ref": "#/components/schemas/SelectOptions" - }, - { - "type": "object" - } - ], - "description": "Column Options" + "restrict_size": { + "type": "string" + }, + "restrict_types": { + "type": "string" + }, + "title": { + "type": "string" } - } + }, + "title": "Gallery Model", + "type": "object" }, - "ColumnList": { - "description": "Model for Column List", - "type": "object", - "x-examples": { - "example-1": { - "bases": { - "list": [ - { - "id": "string", - "project_id": "string", - "alias": "string", - "host": "string", - "port": 0, - "username": "string", - "password": "string", - "database": "string", - "url": "string", - "params": "string", - "type": "string", - "ssl": "string" - } - ], - "pageInfo": { - "pageSize": 0, - "totalRows": 0, - "sort": "string", - "isFirstPage": true, - "isLastPage": true - } - } - } - }, - "properties": { - "columns": { - "type": "object", - "required": ["list"], - "properties": { - "list": { - "type": "array", - "uniqueItems": true, - "minItems": 1, - "items": { - "$ref": "#/components/schemas/Column" - } - } - } - } - }, - "required": ["columns"], - "title": "Column List Model", - "examples": [ - { - "columns": { - "list": [ - { - "id": "cl_vnrvdzwnk6uuov", - "base_id": "ds_krsappzu9f8vmo", - "project_id": "p_01clqvzik3izk6", - "fk_model_id": "md_yvwvbt2i78rgcm", - "title": "SingleSelect", - "column_name": "SingleSelect", - "uidt": "SingleSelect", - "dt": "enum", - "np": null, - "ns": null, - "clen": "1", - "cop": "5", - "pk": 0, - "pv": null, - "rqd": 0, - "un": 0, - "ct": "enum('a','b','c')", - "ai": 0, - "unique": 0, - "cdf": null, - "cc": "", - "csn": "utf8mb4", - "dtx": "specificType", - "dtxp": "'a','b','c'", - "dtxs": null, - "au": 0, - "validate": null, - "virtual": null, - "deleted": null, - "system": 0, - "order": null, - "created_at": "2023-03-03 11:32:59", - "updated_at": "2023-03-03 11:32:59", - "meta": {}, - "colOptions": { - "options": [ - { - "id": "sl_mb8fkdvgudzu3r", - "fk_column_id": "cl_vnrvdzwnk6uuov", - "title": "a", - "color": "#cfdffe", - "order": 1 - }, - { - "id": "sl_31uj9j02qacl7c", - "fk_column_id": "cl_vnrvdzwnk6uuov", - "title": "b", - "color": "#d0f1fd", - "order": 2 - }, - { - "id": "sl_uabhxfapw4frlg", - "fk_column_id": "cl_vnrvdzwnk6uuov", - "title": "c", - "color": "#c2f5e8", - "order": 3 - } - ] - } - } - ] - } - } - ] - }, - "ColumnReq": { - "allOf": [ - { - "anyOf": [ - { - "$ref": "#/components/schemas/LinkToAnotherColumnReq" - }, - { - "$ref": "#/components/schemas/RollupColumnReq" - }, - { - "$ref": "#/components/schemas/FormulaColumnReq" - }, - { - "$ref": "#/components/schemas/LookupColumnReq" - }, - { - "$ref": "#/components/schemas/NormalColumnRequest" - } - ] - }, - { - "properties": { - "column_name": { - "type": "string" - }, - "title": { - "type": "string", - "maxLength": 255, - "minLength": 1 - }, - "column_order": { - "type": "object", - "description": "Column order in a specific view", - "properties": { - "view_id": { - "type": "string" - }, - "order": { - "type": "number" - } - } - } - }, - "required": ["column_name", "title"] - } - ], - "description": "Model for Column Request", - "title": "Column Request Model", + "GalleryColumn": { + "description": "Model for Gallery Column", "examples": [ { - "uidt": "LinkToAnotherRecord", - "title": "string", - "virtual": true, - "parentId": "string", - "childId": "string", - "type": "hm", - "column_name": "string", - "column_order": { - "view_id": "string", - "order": 0 - } + "fk_col_id": "string", + "fk_gallery_id": "string", + "help": "string", + "id": "string", + "label": "string" } ], - "type": "object" - }, - "LinkToAnotherRecord": { - "title": "LinkToAnotherRecord Model", - "type": "object", "properties": { - "id": { - "$ref": "#/components/schemas/Id", - "description": "Unique ID" + "fk_col_id": { + "type": "string" }, - "type": { + "fk_gallery_id": { "type": "string" }, - "virtual": { - "$ref": "#/components/schemas/Bool" + "help": { + "type": "string" }, - "fk_column_id": { + "id": { "$ref": "#/components/schemas/Id", - "description": "Foreign Key to Column" + "description": "Unique ID" }, - "fk_child_column_id": { + "label": { "type": "string" - }, - "fk_parent_column_id": { + } + }, + "title": "Gallery Column Model", + "type": "object" + }, + "GalleryReq": { + "description": "Model for Gallery Request", + "examples": [ + { + "cover_image": "string", + "cover_image_idx": 0, + "fk_cover_image_col_id": "string", + "lock_type": "collaborative", + "next_enabled": true, + "prev_enabled": true, + "restrict_number": "string", + "restrict_size": "string", + "restrict_types": "string", + "title": "My Gallery" + } + ], + "properties": { + "cover_image": { "type": "string" }, - "fk_mm_model_id": { - "type": "string" + "cover_image_idx": { + "minimum": 0, + "type": "integer" }, - "fk_related_model_id": { + "fk_cover_image_col_id": { + "description": "The id of the column that contains the cover image", + "maxLength": 20, "type": "string" }, - "fk_mm_child_column_id": { + "lock_type": { + "description": "The lock type of gallery", + "enum": ["collaborative", "locked", "personal"], "type": "string" }, - "fk_mm_parent_column_id": { - "type": "string" + "next_enabled": { + "$ref": "#/components/schemas/Bool" }, - "ur": { - "type": "string" + "prev_enabled": { + "$ref": "#/components/schemas/Bool" }, - "dr": { + "restrict_number": { "type": "string" }, - "fk_index_name": { + "restrict_size": { "type": "string" }, - "deleted": { + "restrict_types": { "type": "string" }, - "order": { + "title": { + "description": "The title of the gallery", + "example": "My Gallery", + "maxLength": 255, + "minLength": 1, "type": "string" } }, - "description": "Model for LinkToAnotherRecord", + "required": ["title"], + "title": "Gallery Request Model", + "type": "object" + }, + "GeoLocation": { + "description": "Model for Geo Location", "examples": [ { - "id": "string", - "type": "string", - "virtual": true, - "fk_column_id": "string", - "fk_child_column_id": "string", - "fk_parent_column_id": "string", - "fk_mm_model_id": "string", - "fk_related_model_id": "string", - "fk_mm_child_column_id": "string", - "fk_mm_parent_column_id": "string", - "ur": "string", - "dr": "string", - "fk_index_name": "string", - "deleted": "string", - "order": "string" + "latitude": 18.52139, + "longitude": 179.87295 } - ] - }, - "Lookup": { - "title": "Lookup Model", - "type": "object", + ], "properties": { - "id": { - "$ref": "#/components/schemas/Id", - "description": "Unique ID" - }, - "type": { - "type": "string" - }, - "virtual": { - "$ref": "#/components/schemas/Bool" - }, - "fk_column_id": { - "$ref": "#/components/schemas/Id", - "description": "Foreign Key to Column" - }, - "fk_relation_column_id": { - "type": "string" - }, - "fk_lookup_column_id": { - "type": "string" - }, - "deleted": { - "type": "string" + "latitude": { + "description": "The latitude of the location", + "example": 18.52139, + "exclusiveMaximum": 90, + "exclusiveMinimum": -90, + "format": "double", + "type": "number" }, - "order": { - "type": "string" + "longitude": { + "description": "The longitude of the location", + "example": 179.87295, + "exclusiveMaximum": 180, + "exclusiveMinimum": -180, + "format": "double", + "type": "number" } }, - "description": "Model for Lookup", + "title": "Geo Location Model", + "type": "object" + }, + "Grid": { + "description": "Model for Grid", "examples": [ { + "alias": "string", + "deleted": true, "id": "string", - "type": "string", - "virtual": true, - "fk_column_id": "string", - "fk_relation_column_id": "string", - "fk_lookup_column_id": "string", - "deleted": "string", - "order": "string" + "lock_type": "collaborative", + "order": 0, + "row_height": 0, + "title": "string" } - ] - }, - "Rollup": { - "title": "Rollup Model", - "type": "object", + ], "properties": { - "id": { - "$ref": "#/components/schemas/Id", - "description": "Unique ID" - }, - "type": { + "alias": { "type": "string" }, - "virtual": { + "deleted": { "$ref": "#/components/schemas/Bool" }, - "fk_column_id": { + "id": { "$ref": "#/components/schemas/Id", - "description": "Foreign Key to Column" - }, - "fk_relation_column_id": { - "type": "string" + "description": "Unique ID" }, - "fk_rollup_column_id": { + "lock_type": { + "enum": ["collaborative", "locked", "personal"], "type": "string" }, - "rollup_function": { - "type": "string" + "order": { + "type": "number" }, - "deleted": { - "type": "string" + "row_height": { + "type": "number" }, - "order": { + "title": { "type": "string" } }, - "description": "Model for Rollup", + "title": "Grid Model", + "type": "object" + }, + "GridColumn": { + "description": "Model for Grid Column", "examples": [ { - "id": "string", - "type": "string", - "virtual": true, "fk_column_id": "string", - "fk_relation_column_id": "string", - "fk_rollup_column_id": "string", - "rollup_function": "string", - "deleted": "string", - "order": "string" + "help": "string", + "id": "string", + "label": "string", + "width": "string" } - ] - }, - "Formula": { - "title": "Formula Model", - "type": "object", + ], "properties": { - "id": { - "$ref": "#/components/schemas/Id", - "description": "Unique ID" - }, - "type": { - "type": "string" - }, - "virtual": { - "$ref": "#/components/schemas/Bool" - }, "fk_column_id": { "$ref": "#/components/schemas/Id", "description": "Foreign Key to Column" }, - "formula": { + "help": { "type": "string" }, - "formula_raw": { + "id": { + "description": "Unique ID of Grid Column", "type": "string" }, - "deleted": { + "label": { "type": "string" }, - "order": { + "width": { "type": "string" } }, - "description": "Model for Formula", - "examples": [ - { - "id": "string", - "type": "string", - "virtual": true, - "fk_column_id": "string", - "formula": "string", - "formula_raw": "string", - "deleted": "string", - "order": "string" - } - ] + "title": "Grid Column Model", + "type": "object" }, - "SelectOptions": { - "title": "SelectOptions Model", - "type": "object", - "properties": { - "options": { - "type": "array", - "items": { - "$ref": "#/components/schemas/SelectOption" - } - } - }, - "required": ["options"], + "GridColumnReq": { + "description": "Model for Grid Column Request", "examples": [ { - "options": [ - { - "id": "string", - "fk_column_id": "string", - "title": "string", - "color": "string", - "order": 1 - } - ] + "fk_column_id": "string", + "help": "string", + "label": "My Column", + "width": "200px" } ], - "description": "Model for SelectOptions" - }, - "SelectOption": { - "title": "SelectOption Model", - "type": "object", "properties": { - "id": { - "$ref": "#/components/schemas/Id", - "description": "Unique ID" - }, "fk_column_id": { "$ref": "#/components/schemas/Id", "description": "Foreign Key to Column" }, - "title": { + "help": { + "maxLength": 255, "type": "string" }, - "color": { + "label": { + "description": "The label of the column", + "example": "My Column", + "maxLength": 255, "type": "string" }, - "order": { - "type": "number" + "width": { + "description": "The width of the column", + "example": "200px", + "maxLength": 255, + "pattern": "^[0-9]+(px|%)$", + "type": "string" } }, + "title": "Grid Column Request Model", + "type": "object" + }, + "GridReq": { + "description": "Model for Grid Request", "examples": [ { - "id": "string", - "fk_column_id": "string", - "title": "string", - "color": "string", - "order": 1 + "lock_type": "collaborative", + "order": 1, + "row_height": 1, + "title": "My Grid" } ], - "description": "Model for SelectOption" - }, - "Grid": { - "title": "Grid Model", - "type": "object", "properties": { - "id": { - "$ref": "#/components/schemas/Id", - "description": "Unique ID" - }, - "title": { - "type": "string" - }, - "alias": { + "lock_type": { + "description": "The lock type of the grid", + "enum": ["collaborative", "locked", "personal"], "type": "string" }, - "deleted": { - "$ref": "#/components/schemas/Bool" - }, "order": { + "description": "The order of the grid", + "example": 1, "type": "number" }, - "lock_type": { - "type": "string", - "enum": ["collaborative", "locked", "personal"] - }, "row_height": { + "description": "The height of the grid rows", + "example": 1, + "minimum": 1, "type": "number" + }, + "title": { + "description": "The title of the grid", + "example": "My Grid", + "maxLength": 255, + "minLength": 1, + "type": "string" } }, - "description": "Model for Grid", + "required": ["title"], + "title": "Grid Request Model", + "type": "object" + }, + "Hook": { + "description": "Model for Hook", "examples": [ { + "active": true, + "async": true, + "description": "string", + "env": "string", + "event": "after", + "fk_model_id": "string", "id": "string", - "title": "string", - "alias": "string", - "deleted": true, - "order": 0, - "lock_type": "collaborative", - "row_height": 0 + "notification": "string", + "operation": "insert", + "retries": 0, + "retry_interval": 0, + "timeout": 0, + "title": "string", + "type": "string" } - ] - }, - "GridReq": { - "title": "Grid Request Model", - "type": "object", - "description": "Model for Grid Request", + ], "properties": { - "title": { - "type": "string", - "description": "The title of the grid", - "example": "My Grid", - "minLength": 1, - "maxLength": 255 - }, - "order": { - "type": "number", - "description": "The order of the grid", - "example": 1 + "active": { + "$ref": "#/components/schemas/Bool" }, - "lock_type": { - "type": "string", - "enum": ["collaborative", "locked", "personal"], - "description": "The lock type of the grid" + "async": { + "$ref": "#/components/schemas/Bool" }, - "row_height": { - "type": "number", - "description": "The height of the grid rows", - "example": 1, - "minimum": 1 - } - }, - "required": ["title"], - "examples": [ - { - "title": "My Grid", - "order": 1, - "lock_type": "collaborative", - "row_height": 1 - } - ] - }, - "Gallery": { - "title": "Gallery Model", - "type": "object", - "description": "Model for Gallery", - "properties": { - "fk_view_id": { + "description": { "type": "string" }, - "title": { + "env": { "type": "string" }, - "alias": { + "event": { + "enum": ["after", "before"], "type": "string" }, - "deleted": { - "$ref": "#/components/schemas/Bool" - }, - "order": { - "type": "number" - }, - "next_enabled": { - "$ref": "#/components/schemas/Bool" - }, - "prev_enabled": { - "$ref": "#/components/schemas/Bool" + "fk_model_id": { + "type": "string" }, - "cover_image_idx": { - "type": "integer" + "id": { + "$ref": "#/components/schemas/Id", + "description": "Unique ID" }, - "cover_image": { + "notification": { "type": "string" }, - "restrict_types": { + "operation": { + "enum": ["delete", "insert", "update"], "type": "string" }, - "restrict_size": { - "type": "string" + "retries": { + "type": "number" }, - "restrict_number": { - "type": "string" + "retry_interval": { + "type": "number" }, - "columns": { - "type": "array", - "items": { - "$ref": "#/components/schemas/GalleryColumn" - } + "timeout": { + "type": "number" }, - "fk_model_id": { + "title": { "type": "string" }, - "fk_cover_image_col_id": { + "type": { "type": "string" - }, - "lock_type": { - "type": "string", - "enum": ["collaborative", "locked", "personal"] } }, + "title": "Hook Model", + "type": "object" + }, + "HookList": { + "description": "Model for Hook List", "examples": [ { - "fk_view_id": "string", - "title": "string", - "alias": "string", - "deleted": true, - "order": 0, - "next_enabled": true, - "prev_enabled": true, - "cover_image_idx": 0, - "cover_image": "string", - "restrict_types": "string", - "restrict_size": "string", - "restrict_number": "string", - "columns": [ - { - "id": "string", - "label": "string", - "help": "string", - "fk_col_id": "string", - "fk_gallery_id": "string" + "list": [{}], + "pageInfo": { + "isFirstPage": true, + "isLastPage": true, + "page": 1, + "pageSize": 10, + "totalRows": 1 + } + } + ], + "properties": { + "list": { + "items": { + "type": "object" + }, + "minItems": 1, + "type": "array", + "uniqueItems": true + }, + "pageInfo": { + "$ref": "#/components/schemas/Paginated" + } + }, + "title": "Hook List Model", + "type": "object", + "x-examples": { + "example-1": { + "bases": { + "list": [ + { + "alias": "string", + "database": "string", + "host": "string", + "id": "string", + "params": "string", + "password": "string", + "port": 0, + "project_id": "string", + "ssl": "string", + "type": "string", + "url": "string", + "username": "string" + } + ], + "pageInfo": { + "isFirstPage": true, + "isLastPage": true, + "pageSize": 0, + "sort": "string", + "totalRows": 0 } - ], - "fk_model_id": "string", - "fk_cover_image_col_id": "string", - "lock_type": "collaborative" + } } - ] + } }, - "GalleryReq": { - "title": "Gallery Request Model", - "type": "object", - "description": "Model for Gallery Request", - "properties": { - "title": { + "HookLog": { + "description": "Model for Hook Log", + "examples": [ + { + "base_id": "string", + "conditions": "string", + "created_at": "string", + "error": "string", + "error_code": "string", + "error_message": "string", + "event": "string", + "execution_time": "string", + "fk_hook_id": "string", + "id": "string", + "notifications": "string", + "operation": "string", + "payload": null, + "project_id": "string", + "response": "string", + "test_call": true, + "triggered_by": "string", "type": "string", - "description": "The title of the gallery", - "example": "My Gallery", - "minLength": 1, - "maxLength": 255 + "updated_at": "string" + } + ], + "properties": { + "base_id": { + "type": "string" }, - "next_enabled": { - "$ref": "#/components/schemas/Bool" + "conditions": { + "type": "string" }, - "prev_enabled": { - "$ref": "#/components/schemas/Bool" + "created_at": { + "type": "string" }, - "cover_image_idx": { - "type": "integer", - "minimum": 0 + "error": { + "type": "string" }, - "cover_image": { + "error_code": { "type": "string" }, - "restrict_types": { + "error_message": { "type": "string" }, - "restrict_size": { + "event": { "type": "string" }, - "restrict_number": { + "execution_time": { "type": "string" }, - "fk_cover_image_col_id": { - "type": "string", - "description": "The id of the column that contains the cover image", - "maxLength": 20 + "fk_hook_id": { + "$ref": "#/components/schemas/StringOrNull" }, - "lock_type": { - "type": "string", - "enum": ["collaborative", "locked", "personal"], - "description": "The lock type of gallery" - } - }, - "required": ["title"], - "examples": [ - { - "title": "My Gallery", - "next_enabled": true, - "prev_enabled": true, - "cover_image_idx": 0, - "cover_image": "string", - "restrict_types": "string", - "restrict_size": "string", - "restrict_number": "string", - "fk_cover_image_col_id": "string", - "lock_type": "collaborative" - } - ] - }, - "GalleryColumn": { - "title": "Gallery Column Model", - "type": "object", - "description": "Model for Gallery Column", - "properties": { "id": { "$ref": "#/components/schemas/Id", "description": "Unique ID" }, - "label": { + "notifications": { "type": "string" }, - "help": { + "operation": { "type": "string" }, - "fk_col_id": { + "payload": {}, + "project_id": { "type": "string" }, - "fk_gallery_id": { + "response": { "type": "string" - } - }, - "examples": [ - { - "id": "string", - "label": "string", - "help": "string", - "fk_col_id": "string", - "fk_gallery_id": "string" - } - ] - }, - "GridColumnReq": { - "title": "Grid Column Request Model", - "type": "object", - "description": "Model for Grid Column Request", - "properties": { - "label": { - "type": "string", - "description": "The label of the column", - "example": "My Column", - "maxLength": 255 }, - "help": { - "type": "string", - "maxLength": 255 + "test_call": { + "$ref": "#/components/schemas/Bool" }, - "fk_column_id": { - "$ref": "#/components/schemas/Id", - "description": "Foreign Key to Column" + "triggered_by": { + "type": "string" }, - "width": { - "type": "string", - "description": "The width of the column", - "example": "200px", - "maxLength": 255, - "pattern": "^[0-9]+(px|%)$" + "type": { + "type": "string" + }, + "updated_at": { + "type": "string" } }, + "title": "Hook Log Model", + "type": "object" + }, + "HookReq": { + "description": "Model for Hook Request", "examples": [ { - "label": "My Column", - "help": "string", - "fk_column_id": "string", - "width": "200px" + "active": true, + "async": true, + "description": "string", + "env": "string", + "event": "after", + "fk_model_id": "string", + "notification": null, + "operation": "insert", + "retries": 0, + "retry_interval": 0, + "timeout": 1, + "title": "string" } - ] - }, - "GridColumn": { - "title": "Grid Column Model", - "type": "object", - "description": "Model for Grid Column", + ], "properties": { - "id": { - "type": "string", - "description": "Unique ID of Grid Column" + "active": { + "$ref": "#/components/schemas/Bool" }, - "label": { - "type": "string" + "async": { + "$ref": "#/components/schemas/Bool" }, - "help": { - "type": "string" + "description": { + "$ref": "#/components/schemas/StringOrNull" }, - "fk_column_id": { - "$ref": "#/components/schemas/Id", - "description": "Foreign Key to Column" + "env": { + "maxLength": 255, + "type": "string" }, - "width": { + "event": { + "enum": ["after", "before"], "type": "string" - } - }, - "examples": [ - { - "id": "string", - "label": "string", - "help": "string", - "fk_column_id": "string", - "width": "string" - } - ] - }, - "KanbanColumn": { - "title": "Kanban Column Model", - "type": "object", - "description": "Model for Kanban Column", - "properties": { - "id": { - "$ref": "#/components/schemas/Id", - "description": "Unique ID" }, - "label": { + "fk_model_id": { "type": "string" }, - "help": { + "notification": {}, + "operation": { + "enum": ["delete", "insert", "update"], "type": "string" }, - "fk_column_id": { - "$ref": "#/components/schemas/Id", - "description": "Foreign Key to Column" + "retries": { + "oneOf": [ + { + "minimum": 0, + "type": "integer" + }, + { + "type": "null" + } + ] }, - "fk_kanban_id": { + "retry_interval": { + "oneOf": [ + { + "minimum": 0, + "type": "number" + }, + { + "type": "null" + } + ] + }, + "timeout": { + "oneOf": [ + { + "minimum": 1, + "type": "number" + }, + { + "type": "null" + } + ] + }, + "title": { + "maxLength": 255, + "minLength": 1, "type": "string" } }, + "required": ["event", "notification", "operation", "title"], + "title": "Hook Request Model", + "type": "object" + }, + "HookTestReq": { + "description": "Model for Hook Test Request", "examples": [ { - "id": "string", - "label": "string", - "help": "string", - "fk_column_id": "string", - "fk_kanban_id": "string" + "hook": { + "active": true, + "async": true, + "description": "string", + "env": "string", + "event": "after", + "fk_model_id": "string", + "notification": null, + "operation": "insert", + "retries": 0, + "retry_interval": 0, + "timeout": 1, + "title": "string" + }, + "payload": null } - ] + ], + "properties": { + "hook": { + "$ref": "#/components/schemas/HookReq" + }, + "payload": {} + }, + "required": ["hook", "payload"], + "title": "Hook Test Request Model", + "type": "object" + }, + "Id": { + "description": "Model for ID", + "examples": ["string"], + "maxLength": 20, + "minLength": 1, + "title": "ID Model", + "type": "string" }, "Kanban": { - "title": "Kanban Model", - "type": "object", "description": "Model for Kanban", + "examples": [ + { + "alias": "string", + "columns": [ + { + "fk_column_id": "string", + "fk_kanban_id": "string", + "help": "string", + "id": "string", + "label": "string" + } + ], + "fk_cover_image_col_id": "string", + "fk_grp_col_id": "string", + "fk_model_id": "string", + "id": "string", + "meta": {}, + "title": "string" + } + ], "properties": { - "id": { - "$ref": "#/components/schemas/Id", - "description": "Unique ID" - }, - "title": { - "type": "string" - }, "alias": { "type": "string" }, "columns": { - "type": "array", "items": { "$ref": "#/components/schemas/KanbanColumn" - } + }, + "type": "array" }, - "fk_model_id": { + "fk_cover_image_col_id": { "type": "string" }, "fk_grp_col_id": { "$ref": "#/components/schemas/StringOrNull" }, - "fk_cover_image_col_id": { + "fk_model_id": { "type": "string" }, + "id": { + "$ref": "#/components/schemas/Id", + "description": "Unique ID" + }, "meta": { "$ref": "#/components/schemas/Meta" + }, + "title": { + "type": "string" } }, + "title": "Kanban Model", + "type": "object" + }, + "KanbanColumn": { + "description": "Model for Kanban Column", "examples": [ { + "fk_column_id": "string", + "fk_kanban_id": "string", + "help": "string", "id": "string", - "title": "string", - "alias": "string", - "columns": [ - { - "id": "string", - "label": "string", - "help": "string", - "fk_column_id": "string", - "fk_kanban_id": "string" - } - ], - "fk_model_id": "string", - "fk_grp_col_id": "string", - "fk_cover_image_col_id": "string", - "meta": {} - } - ] - }, - "GeoLocation": { - "title": "Geo Location Model", - "type": "object", - "description": "Model for Geo Location", - "properties": { - "latitude": { - "type": "number", - "format": "double", - "description": "The latitude of the location", - "exclusiveMaximum": 90, - "exclusiveMinimum": -90, - "example": 18.52139 - }, - "longitude": { - "type": "number", - "format": "double", - "description": "The longitude of the location", - "example": 179.87295, - "exclusiveMinimum": -180, - "exclusiveMaximum": 180 - } - }, - "examples": [ - { - "latitude": 18.52139, - "longitude": 179.87295 + "label": "string" } - ] - }, - "Map": { - "title": "Map Model", - "type": "object", - "description": "Model for Map", + ], "properties": { - "fk_view_id": { - "type": "string", - "description": "Unique ID for Map", - "example": "vw_qjt7klod1p9kyv" - }, - "title": { - "type": "string", - "example": "My Map", - "description": "Title of Map View" - }, - "project_id": { - "type": "string", - "example": "p_xm3thidrblw4n7", - "description": "The ID of the project that this view belongs to" - }, - "base_id": { - "type": "string", - "example": "ds_g4ccx6e77h1dmi", - "description": "The ID of the base that this view belongs to" - }, - "fk_geo_data_col_id": { - "description": "Foreign Key to GeoData Column", - "type": "string", - "example": "cl_8iw2o4ejzvdyna" - }, - "columns": { - "type": "array", - "description": "Columns in this view", - "items": { - "$ref": "#/components/schemas/MapColumn" - } + "fk_column_id": { + "$ref": "#/components/schemas/Id", + "description": "Foreign Key to Column" }, - "meta": { - "$ref": "#/components/schemas/Meta", - "description": "Meta data for this view" + "fk_kanban_id": { + "type": "string" }, - "show": { - "description": "To show this Map or not", - "type": "boolean" + "help": { + "type": "string" }, - "order": { - "description": "The order of the map list", - "type": "number" - } - }, - "examples": [ - { - "fk_view_id": "vw_qjt7klod1p9kyv", - "title": "My Map", - "project_id": "p_xm3thidrblw4n7", - "base_id": "ds_g4ccx6e77h1dmi", - "fk_geo_data_col_id": "cl_8iw2o4ejzvdyna", - "columns": [ - { - "id": "nc_46xcacqn4rc9xf", - "show": 1, - "order": 1, - "fk_view_id": "vw_qjt7klod1p9kyv", - "fk_column_id": "cl_8iw2o4ejzvdyna", - "project_id": "p_xm3thidrblw4n7", - "base_id": "ds_g4ccx6e77h1dmi" - } - ], - "meta": {}, - "show": true, - "order": 0 - } - ] - }, - "MapColumn": { - "title": "Map Column Model", - "type": "object", - "description": "Model for Map Column", - "properties": { "id": { - "type": "string", - "description": "Unique ID of Map Column", - "example": "nc_46xcacqn4rc9xf" - }, - "show": { - "type": "number", - "description": "Whether to show this column or not", - "example": 1 - }, - "order": { - "type": "number", - "description": "the order in the list of map columns", - "example": 1 - }, - "fk_view_id": { - "type": "string", - "description": "Foreign Key to View", - "example": "vw_qjt7klod1p9kyv" - }, - "fk_column_id": { - "type": "string", - "description": "Foreign Key to Column", - "example": "cl_8iw2o4ejzvdyna" - }, - "project_id": { - "type": "string", - "description": "The ID of the project that this map column belongs to", - "example": "p_xm3thidrblw4n7" + "$ref": "#/components/schemas/Id", + "description": "Unique ID" }, - "base_id": { - "type": "string", - "description": "The ID of the base that this map column belongs to", - "example": "ds_g4ccx6e77h1dmi" + "label": { + "type": "string" } }, - "examples": [ - { - "id": "nc_46xcacqn4rc9xf", - "show": 1, - "order": 1, - "fk_view_id": "vw_qjt7klod1p9kyv", - "fk_column_id": "cl_8iw2o4ejzvdyna", - "project_id": "p_xm3thidrblw4n7", - "base_id": "ds_g4ccx6e77h1dmi" - } - ] + "title": "Kanban Column Model", + "type": "object" }, - "LicenseReq": { - "title": "License Key Request Model", - "type": "object", + "KanbanReq": { "description": "Model for Kanban Request", - "properties": { - "key": { - "type": "string", - "description": "The license key", - "example": "1234567890", - "minLength": 10, - "maxLength": 255 - } - }, "examples": [ { - "key": "1234567890" + "fk_grp_col_id": "string", + "title": "My Kanban" } - ] - }, - "KanbanReq": { - "title": "Kanban Request Model", - "type": "object", - "description": "Model for Kanban Request", + ], "properties": { + "fk_grp_col_id": { + "$ref": "#/components/schemas/StringOrNull" + }, "title": { - "type": "string", "description": "The title of the kanban", "example": "My Kanban", + "maxLength": 255, "minLength": 1, - "maxLength": 255 - }, - "fk_grp_col_id": { - "$ref": "#/components/schemas/StringOrNull" + "type": "string" } }, "required": ["title"], + "title": "Kanban Request Model", + "type": "object" + }, + "KanbanUpdateReq": { + "description": "Model for Kanban Update Request", "examples": [ { - "title": "My Kanban", "fk_grp_col_id": "string" } - ] - }, - "KanbanUpdateReq": { - "title": "Kanban Update Request Model", - "type": "object", - "description": "Model for Kanban Update Request", + ], "properties": { "fk_grp_col_id": { "$ref": "#/components/schemas/StringOrNull" } }, + "title": "Kanban Update Request Model", + "type": "object" + }, + "LicenseReq": { + "description": "Model for Kanban Request", "examples": [ { - "fk_grp_col_id": "string" + "key": "1234567890" } - ] + ], + "properties": { + "key": { + "description": "The license key", + "example": "1234567890", + "maxLength": 255, + "minLength": 10, + "type": "string" + } + }, + "title": "License Key Request Model", + "type": "object" }, - "Form": { - "title": "Form Model", - "type": "object", - "description": "Model for Form", + "LinkToAnotherColumnReq": { + "description": "Model for LinkToAnotherColumn Request", + "examples": [ + { + "childId": "string", + "parentId": "string", + "title": "string", + "type": "hm", + "uidt": "LinkToAnotherRecord", + "virtual": true + } + ], "properties": { - "id": { - "$ref": "#/components/schemas/Id", - "description": "Unique ID" + "childId": { + "$ref": "#/components/schemas/Id" }, - "title": { - "type": "string" + "parentId": { + "$ref": "#/components/schemas/Id" }, - "heading": { + "title": { + "maxLength": 255, + "minLength": 1, "type": "string" }, - "subheading": { + "type": { + "enum": ["bt", "hm", "mm"], "type": "string" }, - "success_msg": { + "uidt": { + "enum": ["LinkToAnotherRecord"], "type": "string" }, - "redirect_url": { - "$ref": "#/components/schemas/StringOrNull" - }, - "redirect_after_secs": { - "$ref": "#/components/schemas/StringOrNull" - }, - "email": { - "$ref": "#/components/schemas/StringOrNull" - }, - "banner_image_url": { - "$ref": "#/components/schemas/StringOrNull" - }, - "logo_url": { - "$ref": "#/components/schemas/StringOrNull" - }, - "submit_another_form": { + "virtual": { "$ref": "#/components/schemas/Bool" - }, - "show_blank_form": { - "$ref": "#/components/schemas/Bool" - }, - "columns": { - "type": "array", - "items": { - "$ref": "#/components/schemas/FormColumn" - } - }, - "fk_model_id": { - "type": "string" - }, - "lock_type": { - "type": "string", - "enum": ["collaborative", "locked", "personal"] - }, - "meta": { - "$ref": "#/components/schemas/Meta" } }, + "required": ["childId", "parentId", "title", "type", "uidt"], + "title": "LinkToAnotherColumn Request Model", + "type": "object" + }, + "LinkToAnotherRecord": { + "description": "Model for LinkToAnotherRecord", "examples": [ { + "deleted": "string", + "dr": "string", + "fk_child_column_id": "string", + "fk_column_id": "string", + "fk_index_name": "string", + "fk_mm_child_column_id": "string", + "fk_mm_model_id": "string", + "fk_mm_parent_column_id": "string", + "fk_parent_column_id": "string", + "fk_related_model_id": "string", "id": "string", - "title": "string", - "heading": "string", - "subheading": "string", - "success_msg": "string", - "redirect_url": "string", - "redirect_after_secs": "string", - "email": "string", - "banner_image_url": "string", - "logo_url": "string", - "submit_another_form": true, - "show_blank_form": true, - "columns": [ - { - "fk_column_id": "string", - "id": "string", - "fk_view_id": "string", - "uuid": null, - "label": "string", - "help": null, - "required": true, - "show": true, - "order": 0, - "created_at": "string", - "updated_at": "string", - "description": "string", - "meta": {} - } - ], - "fk_model_id": "string", - "lock_type": "collaborative", - "meta": {} + "order": "string", + "type": "string", + "ur": "string", + "virtual": true } - ] - }, - "FormReq": { - "title": "Form Request Model", - "type": "object", - "description": "Model for Form Request", + ], "properties": { - "title": { - "type": "string", - "description": "The title of the form", - "example": "My Form", - "minLength": 1, - "maxLength": 255 + "deleted": { + "type": "string" }, - "heading": { - "type": "string", - "description": "The heading of the form", - "example": "My Form", - "maxLength": 255 + "dr": { + "type": "string" }, - "subheading": { - "type": "string", - "description": "The subheading of the form", - "example": "My Form Subheading", - "maxLength": 255 + "fk_child_column_id": { + "type": "string" }, - "success_msg": { - "$ref": "#/components/schemas/StringOrNull", - "description": "Custom message after the form is successfully submitted" + "fk_column_id": { + "$ref": "#/components/schemas/Id", + "description": "Foreign Key to Column" }, - "redirect_url": { - "$ref": "#/components/schemas/StringOrNull", - "description": "URL to redirect after submission" + "fk_index_name": { + "type": "string" }, - "redirect_after_secs": { - "$ref": "#/components/schemas/StringOrNull", - "description": "The numbers of seconds to redirect after form submission" + "fk_mm_child_column_id": { + "type": "string" }, - "email": { - "$ref": "#/components/schemas/StringOrNull" + "fk_mm_model_id": { + "type": "string" }, - "banner_image_url": { - "$ref": "#/components/schemas/StringOrNull", - "description": "Banner Image URL. Not in use currently." + "fk_mm_parent_column_id": { + "type": "string" }, - "logo_url": { - "$ref": "#/components/schemas/StringOrNull", - "description": "Logo URL. Not in use currently." + "fk_parent_column_id": { + "type": "string" }, - "submit_another_form": { - "$ref": "#/components/schemas/Bool", - "description": "Show `Submit Another Form` button" + "fk_related_model_id": { + "type": "string" }, - "show_blank_form": { - "$ref": "#/components/schemas/Bool", - "description": "Show `Blank Form` after 5 seconds" + "id": { + "$ref": "#/components/schemas/Id", + "description": "Unique ID" }, - "lock_type": { - "type": "string", - "enum": ["collaborative", "locked", "personal"] + "order": { + "type": "string" }, - "meta": { - "$ref": "#/components/schemas/Meta", - "description": "Meta Info for this view" + "type": { + "type": "string" + }, + "ur": { + "type": "string" + }, + "virtual": { + "$ref": "#/components/schemas/Bool" } }, - "examples": [ - { - "title": "My Form", - "heading": "My Form", - "subheading": "My Form Subheading", - "success_msg": "string", - "redirect_url": "string", - "redirect_after_secs": "string", - "email": "string", - "banner_image_url": "string", - "logo_url": "string", - "submit_another_form": true, - "show_blank_form": true, - "lock_type": "collaborative", - "meta": {} - } - ] + "title": "LinkToAnotherRecord Model", + "type": "object" }, - "FormCreateReq": { - "allOf": [ - { - "$ref": "#/components/schemas/FormReq" - }, - { - "required": ["title"] - } - ], - "title": "Form Create Model", - "description": "Model for Form Create", + "Lookup": { + "description": "Model for Lookup", "examples": [ { - "title": "My Form", - "heading": "My Form", - "subheading": "My Form Subheading", - "success_msg": "string", - "redirect_url": "string", - "redirect_after_secs": "string", - "email": "string", - "banner_image_url": "string", - "logo_url": "string", - "submit_another_form": true, - "show_blank_form": true, - "lock_type": "collaborative", - "meta": {} - } - ] - }, - "FormColumn": { - "description": "Model for Form Column", - "type": "object", - "x-examples": { - "example-1": { - "_cn": "first_name", - "alias": "first_name", - "fk_column_id": "cl_yvyhsl9u81tokc", - "id": "fvc_8z1i7t8aswkqxx", - "fk_view_id": "vw_s1pf4umdnikoyn", - "uuid": null, - "label": "dsdsds", - "help": null, - "required": false, - "show": 1, - "order": 1, - "created_at": "2022-02-15 12:39:04", - "updated_at": "2022-02-15 12:39:16", - "description": "dsdsdsdsd" + "deleted": "string", + "fk_column_id": "string", + "fk_lookup_column_id": "string", + "fk_relation_column_id": "string", + "id": "string", + "order": "string", + "type": "string", + "virtual": true } - }, + ], "properties": { + "deleted": { + "type": "string" + }, "fk_column_id": { "$ref": "#/components/schemas/Id", - "description": "Foreign Key to Column", - "minLength": 1 - }, - "id": { - "type": "string", - "minLength": 1 - }, - "fk_view_id": { - "type": "string", - "minLength": 1 + "description": "Foreign Key to Column" }, - "uuid": {}, - "label": { - "type": "string", - "minLength": 1 + "fk_lookup_column_id": { + "type": "string" }, - "help": {}, - "required": { - "$ref": "#/components/schemas/Bool" + "fk_relation_column_id": { + "type": "string" }, - "show": { - "$ref": "#/components/schemas/Bool" + "id": { + "$ref": "#/components/schemas/Id", + "description": "Unique ID" }, "order": { - "type": "number" + "type": "string" }, - "created_at": { - "type": "string", - "minLength": 1 + "type": { + "type": "string" }, - "updated_at": { - "type": "string", - "minLength": 1 + "virtual": { + "$ref": "#/components/schemas/Bool" + } + }, + "title": "Lookup Model", + "type": "object" + }, + "LookupColumnReq": { + "description": "Model for Lookup Column Request", + "examples": [ + { + "fk_lookup_column_id": "string", + "fk_relation_column_id": "string", + "title": "string", + "uidt": "Lookup" + } + ], + "properties": { + "fk_lookup_column_id": { + "$ref": "#/components/schemas/Id" }, - "description": { - "type": "string", - "minLength": 1 + "fk_relation_column_id": { + "$ref": "#/components/schemas/Id" }, - "meta": { - "$ref": "#/components/schemas/Meta" + "title": { + "maxLength": 255, + "type": "string" + }, + "uidt": { + "enum": ["Lookup"], + "type": "string" } }, - "title": "Form Column Model", + "required": [ + "fk_lookup_column_id", + "fk_relation_column_id", + "title", + "uidt" + ], + "title": "Lookup Column Request Model", + "type": "object" + }, + "Map": { + "description": "Model for Map", "examples": [ { - "fk_column_id": "string", - "id": "string", - "fk_view_id": "string", - "uuid": null, - "label": "string", - "help": null, - "required": true, - "show": true, + "base_id": "ds_g4ccx6e77h1dmi", + "columns": [ + { + "base_id": "ds_g4ccx6e77h1dmi", + "fk_column_id": "cl_8iw2o4ejzvdyna", + "fk_view_id": "vw_qjt7klod1p9kyv", + "id": "nc_46xcacqn4rc9xf", + "order": 1, + "project_id": "p_xm3thidrblw4n7", + "show": 1 + } + ], + "fk_geo_data_col_id": "cl_8iw2o4ejzvdyna", + "fk_view_id": "vw_qjt7klod1p9kyv", + "meta": {}, "order": 0, - "created_at": "string", - "updated_at": "string", - "description": "string", - "meta": {} - } - ] - }, - "FormColumnReq": { - "description": "Model for Form Column Request", - "type": "object", - "x-examples": { - "example-1": { - "_cn": "first_name", - "alias": "first_name", - "fk_column_id": "cl_yvyhsl9u81tokc", - "id": "fvc_8z1i7t8aswkqxx", - "fk_view_id": "vw_s1pf4umdnikoyn", - "uuid": null, - "label": "dsdsds", - "help": null, - "required": false, - "show": 1, - "order": 1, - "created_at": "2022-02-15 12:39:04", - "updated_at": "2022-02-15 12:39:16", - "description": "dsdsdsdsd" + "project_id": "p_xm3thidrblw4n7", + "show": true, + "title": "My Map" } - }, + ], "properties": { - "label": { - "type": "string", - "minLength": 1, - "maxLength": 255 + "base_id": { + "description": "The ID of the base that this view belongs to", + "example": "ds_g4ccx6e77h1dmi", + "type": "string" }, - "help": { - "maxLength": 255 + "columns": { + "description": "Columns in this view", + "items": { + "$ref": "#/components/schemas/MapColumn" + }, + "type": "array" }, - "required": { - "$ref": "#/components/schemas/Bool" + "fk_geo_data_col_id": { + "description": "Foreign Key to GeoData Column", + "example": "cl_8iw2o4ejzvdyna", + "type": "string" }, - "show": { - "$ref": "#/components/schemas/Bool" + "fk_view_id": { + "description": "Unique ID for Map", + "example": "vw_qjt7klod1p9kyv", + "type": "string" + }, + "meta": { + "$ref": "#/components/schemas/Meta", + "description": "Meta data for this view" }, "order": { + "description": "The order of the map list", "type": "number" }, - "description": { - "type": "string", - "maxLength": 255 + "project_id": { + "description": "The ID of the project that this view belongs to", + "example": "p_xm3thidrblw4n7", + "type": "string" }, - "meta": { - "$ref": "#/components/schemas/Meta" + "show": { + "description": "To show this Map or not", + "type": "boolean" + }, + "title": { + "description": "Title of Map View", + "example": "My Map", + "type": "string" } }, - "title": "Form Column Request Model", + "title": "Map Model", + "type": "object" + }, + "MapColumn": { + "description": "Model for Map Column", "examples": [ { - "label": "string", - "help": "string", - "required": true, - "show": true, - "order": 0, - "description": "string", - "meta": {} + "base_id": "ds_g4ccx6e77h1dmi", + "fk_column_id": "cl_8iw2o4ejzvdyna", + "fk_view_id": "vw_qjt7klod1p9kyv", + "id": "nc_46xcacqn4rc9xf", + "order": 1, + "project_id": "p_xm3thidrblw4n7", + "show": 1 } - ] - }, - "Paginated": { - "title": "Paginated Model", - "type": "object", - "description": "Model for Paginated", + ], "properties": { - "pageSize": { - "type": "number", - "description": "The number of pages", - "example": 10 + "base_id": { + "description": "The ID of the base that this map column belongs to", + "example": "ds_g4ccx6e77h1dmi", + "type": "string" }, - "totalRows": { - "type": "number", - "description": "The number of rows in the given result", - "example": 1 + "fk_column_id": { + "description": "Foreign Key to Column", + "example": "cl_8iw2o4ejzvdyna", + "type": "string" }, - "isFirstPage": { - "type": "boolean", - "description": "Is the current page the first page" + "fk_view_id": { + "description": "Foreign Key to View", + "example": "vw_qjt7klod1p9kyv", + "type": "string" }, - "isLastPage": { - "type": "boolean", - "description": "Is the current page the last page" + "id": { + "description": "Unique ID of Map Column", + "example": "nc_46xcacqn4rc9xf", + "type": "string" }, - "page": { - "type": "number", - "description": "The current page", - "example": 1 + "order": { + "description": "the order in the list of map columns", + "example": 1, + "type": "number" + }, + "project_id": { + "description": "The ID of the project that this map column belongs to", + "example": "p_xm3thidrblw4n7", + "type": "string" + }, + "show": { + "description": "Whether to show this column or not", + "example": 1, + "type": "number" } }, - "examples": [ + "title": "Map Column Model", + "type": "object" + }, + "Meta": { + "description": "Model for Meta", + "examples": [{}], + "oneOf": [ { - "pageSize": 10, - "totalRows": 1, - "isFirstPage": true, - "isLastPage": true, - "page": 1 + "type": "null" + }, + { + "type": "object" + }, + { + "type": "string" } - ] + ], + "title": "Meta Model" }, - "HookList": { - "description": "Model for Hook List", - "type": "object", - "x-examples": { - "example-1": { - "bases": { - "list": [ - { - "id": "string", - "project_id": "string", - "alias": "string", - "host": "string", - "port": 0, - "username": "string", - "password": "string", - "database": "string", - "url": "string", - "params": "string", - "type": "string", - "ssl": "string" - } - ], - "pageInfo": { - "pageSize": 0, - "totalRows": 0, - "sort": "string", - "isFirstPage": true, - "isLastPage": true - } - } + "ModelRoleVisibility": { + "description": "Model for ModelRoleVisibility", + "examples": [ + { + "base_id": "string", + "disabled": true, + "fk_model_id": "string", + "fk_view_id": "string", + "id": "string", + "project_id": "string", + "role": "string" } - }, + ], "properties": { - "list": { - "type": "array", - "uniqueItems": true, - "minItems": 1, - "items": { - "type": "object" - } + "base_id": { + "type": "string" }, - "pageInfo": { - "$ref": "#/components/schemas/Paginated" + "disabled": { + "$ref": "#/components/schemas/Bool" + }, + "fk_model_id": { + "type": "string" + }, + "fk_view_id": { + "type": "string" + }, + "id": { + "$ref": "#/components/schemas/Id", + "description": "Unique ID" + }, + "project_id": { + "type": "string" + }, + "role": { + "type": "string" } }, - "title": "Hook List Model", + "title": "ModelRoleVisibility Model", + "type": "object" + }, + "NormalColumnRequest": { + "description": "Model for Normal Column Request", "examples": [ { - "list": [{}], - "pageInfo": { - "pageSize": 10, - "totalRows": 1, - "isFirstPage": true, - "isLastPage": true, - "page": 1 - } + "ai": true, + "au": true, + "cc": "string", + "cdf": "string", + "column_name": "string", + "csn": "string", + "dt": "string", + "dtx": "string", + "dtxp": 0, + "dtxs": 0, + "np": 0, + "ns": 0, + "pk": true, + "pv": true, + "rqd": true, + "title": "string", + "uidt": "ID", + "un": true, + "unique": true } - ] - }, - "SharedView": { - "title": "Shared View Model", - "type": "object", + ], "properties": { - "id": { - "$ref": "#/components/schemas/Id", - "description": "Unique ID" + "ai": { + "$ref": "#/components/schemas/Bool" }, - "fk_view_id": { + "au": { + "$ref": "#/components/schemas/Bool" + }, + "cc": { + "$ref": "#/components/schemas/StringOrNull" + }, + "cdf": { + "$ref": "#/components/schemas/StringOrNull" + }, + "column_name": { + "maxLength": 255, + "minLength": 1, "type": "string" }, - "password": { + "csn": { + "$ref": "#/components/schemas/StringOrNull" + }, + "dt": { "type": "string" }, - "deleted": { + "dtx": { + "$ref": "#/components/schemas/StringOrNull" + }, + "dtxp": { + "oneOf": [ + { + "$ref": "#/components/schemas/StringOrNull" + }, + { + "type": "number" + } + ] + }, + "dtxs": { + "oneOf": [ + { + "$ref": "#/components/schemas/StringOrNull" + }, + { + "type": "number" + } + ] + }, + "np": { + "oneOf": [ + { + "$ref": "#/components/schemas/StringOrNull" + }, + { + "type": "integer" + } + ] + }, + "ns": { + "oneOf": [ + { + "$ref": "#/components/schemas/StringOrNull" + }, + { + "type": "integer" + } + ] + }, + "pk": { + "$ref": "#/components/schemas/Bool" + }, + "pv": { + "$ref": "#/components/schemas/Bool" + }, + "rqd": { + "$ref": "#/components/schemas/Bool" + }, + "title": { + "maxLength": 255, + "type": "string" + }, + "uidt": { + "enum": [ + "Attachment", + "AutoNumber", + "Barcode", + "Button", + "Checkbox", + "Collaborator", + "Count", + "CreateTime", + "Currency", + "Date", + "DateTime", + "Decimal", + "Duration", + "Email", + "GeoData", + "Geometry", + "ID", + "JSON", + "LastModifiedTime", + "LongText", + "MultiSelect", + "Number", + "Percent", + "PhoneNumber", + "Rating", + "SingleLineText", + "SingleSelect", + "SpecificDBType", + "Time", + "URL", + "Year" + ], "type": "string" + }, + "un": { + "$ref": "#/components/schemas/Bool" + }, + "unique": { + "$ref": "#/components/schemas/Bool" } }, - "description": "Model for Shared View", + "title": "Normal Column Request Model", + "type": "object" + }, + "OrgUserReq": { + "description": "Model for Organisation User Update Request", "examples": [ { - "id": "string", - "fk_view_id": "string", - "password": "string", - "deleted": "string" - } - ] - }, - "SharedViewList": { - "description": "Model for Shared View List", - "type": "object", - "x-examples": { - "example-1": { - "bases": { - "list": [ - { - "id": "string", - "project_id": "string", - "alias": "string", - "host": "string", - "port": 0, - "username": "string", - "password": "string", - "database": "string", - "url": "string", - "params": "string", - "type": "string", - "ssl": "string" - } - ], - "pageInfo": { - "pageSize": 0, - "totalRows": 0, - "sort": "string", - "isFirstPage": true, - "isLastPage": true - } - } + "email": "user@example.com", + "roles": "org-level-creator" } - }, + ], "properties": { - "list": { - "type": "array", - "uniqueItems": true, - "minItems": 1, - "items": { - "$ref": "#/components/schemas/SharedView" - } + "email": { + "format": "email", + "type": "string" }, - "pageInfo": { - "$ref": "#/components/schemas/Paginated" + "roles": { + "enum": ["org-level-creator", "org-level-viewer"], + "type": "string" } }, - "title": "Shared View List Model", + "title": "Organisation User Request Model", + "type": "object" + }, + "Paginated": { + "description": "Model for Paginated", "examples": [ { - "list": [ - { - "id": "string", - "fk_view_id": "string", - "password": "string", - "deleted": "string" - } - ], - "pageInfo": { - "pageSize": 10, - "totalRows": 1, - "isFirstPage": true, - "isLastPage": true, - "page": 1 - } + "isFirstPage": true, + "isLastPage": true, + "page": 1, + "pageSize": 10, + "totalRows": 1 } - ] - }, - "ViewList": { - "description": "Model for View List", - "type": "object", - "x-examples": { - "example-1": { - "bases": { - "list": [ - { - "id": "string", - "project_id": "string", - "alias": "string", - "host": "string", - "port": 0, - "username": "string", - "password": "string", - "database": "string", - "url": "string", - "params": "string", - "type": "string", - "ssl": "string" - } - ], - "pageInfo": { - "pageSize": 0, - "totalRows": 0, - "sort": "string", - "isFirstPage": true, - "isLastPage": true - } - } - } - }, + ], "properties": { - "list": { - "type": "array", - "items": { - "$ref": "#/components/schemas/View" - } + "isFirstPage": { + "description": "Is the current page the first page", + "type": "boolean" }, - "pageInfo": { - "$ref": "#/components/schemas/Paginated" + "isLastPage": { + "description": "Is the current page the last page", + "type": "boolean" + }, + "page": { + "description": "The current page", + "example": 1, + "type": "number" + }, + "pageSize": { + "description": "The number of pages", + "example": 10, + "type": "number" + }, + "totalRows": { + "description": "The number of rows in the given result", + "example": 1, + "type": "number" } }, - "required": ["views"], - "title": "View List Model", + "title": "Paginated Model", + "type": "object" + }, + "Password": { + "description": "Model for Password", + "example": "password123456789", + "examples": ["password123456789"], + "minLength": 8, + "title": "Password Model", + "type": "string" + }, + "PasswordChangeReq": { + "description": "Model for Password Change Request", "examples": [ { - "list": [ - { - "id": "string", - "fk_project_id": "string", - "fk_base_id": "string", - "title": "string", - "alias": "string", - "type": "string", - "enabled": true, - "parent_id": "string", - "show_as": "string", - "tags": "string", - "pinned": true, - "deleted": true, - "order": 0, - "column": [ - { - "id": "string", - "base_id": "string", - "fk_model_id": "string", - "title": "string", - "alias": "string", - "ui_data_type": "string", - "data_type": "string", - "numeric_precision": "string", - "numeric_scale": "string", - "character_maximum_length": "string", - "column_ordinal_position": "string", - "primary_key": true, - "primary_value": true, - "rqd": "string", - "un": "string", - "column_type": "string", - "auto_increment": true, - "unique": true, - "column_default": "string", - "column_comment": "string", - "character_set_name": "string", - "data_type_x": "string", - "data_type_x_precision": "string", - "data_type_x_scale": "string", - "auto_update_timestamp": true, - "deleted": true, - "visible": true, - "order": 0, - "colOptions": { - "id": "string", - "type": "string", - "virtual": true, - "fk_column_id": "string", - "fk_child_column_id": "string", - "fk_parent_column_id": "string", - "fk_mm_model_id": "string", - "fk_mm_child_column_id": "string", - "fk_mm_parent_column_id": "string", - "ur": "string", - "dr": "string", - "fk_index_name": "string", - "deleted": "string", - "order": "string" - } - } - ], - "columnByIds": {} - } - ], - "pageInfo": { - "pageSize": 10, - "totalRows": 1, - "isFirstPage": true, - "isLastPage": true, - "page": 1 - } + "currentPassword": "string", + "newPassword": "stringst" } - ] - }, - "Attachment": { - "title": "Attachment Model", - "type": "object", + ], "properties": { - "url": { - "type": "string" - }, - "title": { - "type": "string" - }, - "mimetype": { - "type": "string" - }, - "size": { - "type": "string" - }, - "icon": { + "currentPassword": { "type": "string" }, - "path": { + "newPassword": { + "minLength": 8, "type": "string" - }, - "data": {} + } }, - "description": "Model for Attachment", + "required": ["currentPassword", "newPassword"], + "title": "Password Change Request Model", + "type": "object" + }, + "PasswordForgotReq": { + "description": "Model for Password Forgot Request", "examples": [ { - "url": "string", - "title": "string", - "mimetype": "string", - "size": "string", - "icon": "string", - "path": "string", - "data": null + "email": "user@example.com" } - ] - }, - "Webhook": { - "title": "Webhook Model", - "type": "object", + ], "properties": { - "id": { - "$ref": "#/components/schemas/Id", - "description": "Unique ID" - }, - "title": { + "email": { + "description": "Email address of the user", + "format": "email", "type": "string" - }, - "type": { + } + }, + "required": ["email"], + "title": "Password Forgot Request Model", + "type": "object" + }, + "PasswordResetReq": { + "description": "Model for Password Reset Request", + "examples": [ + { + "password": "newpassword" + } + ], + "properties": { + "password": { + "description": "New password", + "example": "newpassword", + "minLength": 8, "type": "string" } }, - "description": "Model for Webhook", + "required": ["password"], + "title": "Password Reset Request Model", + "type": "object" + }, + "Plugin": { + "description": "Model for Plugin", "examples": [ { + "active": true, + "category": "string", + "creator": "string", + "creator_website": "string", + "description": "string", + "docs": "string", + "icon": "string", "id": "string", + "input": 0, + "input_schema": "string", + "logo": "string", + "price": "string", + "rating": 0, + "status": "string", + "status_details": "string", + "tags": "string", "title": "string", - "type": "string" + "version": "string" } - ] - }, - "Audit": { - "title": "Audit Model", - "type": "object", + ], "properties": { - "id": { - "$ref": "#/components/schemas/Id", - "description": "Unique ID" + "active": { + "$ref": "#/components/schemas/Bool" }, - "user": { + "category": { "type": "string" }, - "ip": { + "creator": { "type": "string" }, - "base_id": { + "creator_website": { "type": "string" }, - "project_id": { + "description": { "type": "string" }, - "fk_model_id": { + "docs": { "type": "string" }, - "row_id": { + "icon": { "type": "string" }, - "op_type": { - "type": "string" + "id": { + "$ref": "#/components/schemas/Id", + "description": "Unique ID" }, - "op_sub_type": { - "type": "string" + "input": { + "oneOf": [ + { + "$ref": "#/components/schemas/StringOrNull" + }, + { + "type": "integer" + } + ] }, - "status": { + "input_schema": { "type": "string" }, - "description": { + "logo": { "type": "string" }, - "details": { + "price": { "type": "string" - } - }, - "description": "Model for Audit", - "examples": [ - { - "id": "string", - "user": "string", - "ip": "string", - "base_id": "string", - "project_id": "string", - "fk_model_id": "string", - "row_id": "string", - "op_type": "string", - "op_sub_type": "string", - "status": "string", - "description": "string", - "details": "string" - } - ] - }, - "Hook": { - "title": "Hook Model", - "type": "object", - "properties": { - "id": { - "$ref": "#/components/schemas/Id", - "description": "Unique ID" }, - "fk_model_id": { - "type": "string" + "rating": { + "type": "number" }, - "title": { + "status": { "type": "string" }, - "description": { + "status_details": { "type": "string" }, - "env": { + "tags": { "type": "string" }, - "type": { + "title": { "type": "string" }, - "event": { - "type": "string", - "enum": ["after", "before"] - }, - "operation": { - "type": "string", - "enum": ["insert", "delete", "update"] - }, - "async": { - "$ref": "#/components/schemas/Bool" - }, - "notification": { + "version": { "type": "string" - }, - "retries": { - "type": "number" - }, - "retry_interval": { - "type": "number" - }, - "timeout": { - "type": "number" - }, + } + }, + "title": "Plugin Model", + "type": "object" + }, + "PluginReq": { + "description": "Model for Plugin Request", + "examples": [ + { + "active": true, + "input": null + } + ], + "properties": { "active": { "$ref": "#/components/schemas/Bool" - } + }, + "input": {} }, - "description": "Model for Hook", + "title": "Plugin Reqeust", + "type": "object" + }, + "PluginTestReq": { + "description": "Model for Plugin Test Request", "examples": [ { - "id": "string", - "fk_model_id": "string", - "title": "string", - "description": "string", - "env": "string", - "type": "string", - "event": "after", - "operation": "insert", - "async": true, - "notification": "string", - "retries": 0, - "retry_interval": 0, - "timeout": 0, - "active": true + "input": null, + "title": "string" } - ] + ], + "properties": { + "input": {}, + "title": { + "maxLength": 45, + "type": "string" + } + }, + "required": ["input", "title"], + "title": "Plugin Test Request Model", + "type": "object" }, - "HookReq": { - "title": "Hook Request Model", - "type": "object", + "Project": { + "description": "Model for Project", + "examples": [ + { + "bases": [ + { + "alias": "string", + "config": null, + "created_at": "2023-03-01 14:27:36", + "enabled": true, + "id": "string", + "inflection_column": "camelize", + "inflection_table": "camelize", + "is_meta": true, + "order": 1, + "project_id": "string", + "type": "mysql2", + "updated_at": "2023-03-01 14:27:36" + } + ], + "color": "#24716E", + "created_at": "2023-03-01 14:27:36", + "deleted": true, + "description": "This is my project description", + "id": "p_124hhlkbeasewh", + "is_meta": true, + "meta": {}, + "order": 0, + "prefix": "nc_vm5q__", + "status": "string", + "title": "my-project", + "updated_at": "2023-03-01 14:27:36" + } + ], "properties": { - "fk_model_id": { + "bases": { + "description": "List of base models", + "items": { + "$ref": "#/components/schemas/Base" + }, + "type": "array" + }, + "color": { + "description": "Primary Theme Color", + "example": "#24716E", "type": "string" }, - "title": { - "type": "string", - "minLength": 1, - "maxLength": 255 + "created_at": { + "description": "The created time of the record", + "example": "2023-03-01 14:27:36", + "format": "date-time", + "type": "string" + }, + "deleted": { + "$ref": "#/components/schemas/Bool", + "description": "Is the project deleted" }, "description": { - "$ref": "#/components/schemas/StringOrNull" + "description": "Project Description", + "example": "This is my project description", + "type": "string" }, - "env": { - "type": "string", - "maxLength": 255 + "id": { + "description": "Unique Project ID", + "example": "p_124hhlkbeasewh", + "type": "string" }, - "event": { - "type": "string", - "enum": ["after", "before"] + "is_meta": { + "$ref": "#/components/schemas/Bool" }, - "operation": { - "type": "string", - "enum": ["insert", "delete", "update"] + "meta": { + "$ref": "#/components/schemas/Meta", + "description": "Meta Info such as theme colors" }, - "async": { - "$ref": "#/components/schemas/Bool" + "order": { + "description": "The order in project list", + "type": "number" }, - "notification": {}, - "retries": { - "oneOf": [ - { - "type": "integer", - "minimum": 0 - }, - { - "type": "null" - } - ] + "prefix": { + "description": "Project prefix. Used in XCDB only.", + "example": "nc_vm5q__", + "type": "string" }, - "retry_interval": { - "oneOf": [ - { - "type": "number", - "minimum": 0 - }, - { - "type": "null" - } - ] + "status": { + "type": "string" }, - "timeout": { - "oneOf": [ - { - "type": "number", - "minimum": 1 - }, - { - "type": "null" - } - ] + "title": { + "description": "Project Title", + "example": "my-project", + "type": "string" }, - "active": { - "$ref": "#/components/schemas/Bool" + "updated_at": { + "description": "The updated time of the record", + "example": "2023-03-01 14:27:36", + "format": "date-time", + "type": "string" } }, - "required": ["title", "event", "notification", "operation"], - "description": "Model for Hook Request", + "title": "Project Model", + "type": "object" + }, + "ProjectList": { + "description": "Model for Project List", "examples": [ { - "fk_model_id": "string", - "title": "string", - "description": "string", - "env": "string", - "event": "after", - "operation": "insert", - "async": true, - "notification": null, - "retries": 0, - "retry_interval": 0, - "timeout": 1, - "active": true + "list": [ + { + "bases": [ + { + "alias": "string", + "config": null, + "created_at": "2023-03-01 14:27:36", + "enabled": true, + "id": "string", + "inflection_column": "camelize", + "inflection_table": "camelize", + "is_meta": true, + "order": 1, + "project_id": "string", + "type": "mysql2", + "updated_at": "2023-03-01 14:27:36" + } + ], + "color": "#24716E", + "created_at": "2023-03-01 14:27:36", + "deleted": true, + "description": "This is my project description", + "id": "p_124hhlkbeasewh", + "is_meta": true, + "meta": {}, + "order": 0, + "prefix": "nc_vm5q__", + "status": "string", + "title": "my-project", + "updated_at": "2023-03-01 14:27:36" + } + ], + "pageInfo": { + "isFirstPage": true, + "isLastPage": true, + "page": 1, + "pageSize": 10, + "totalRows": 1 + } } - ] - }, - "HookTestReq": { - "title": "Hook Test Request Model", - "type": "object", + ], "properties": { - "payload": {}, - "hook": { - "$ref": "#/components/schemas/HookReq" + "list": { + "description": "List of Project Models", + "items": { + "$ref": "#/components/schemas/Project" + }, + "minItems": 1, + "type": "array", + "uniqueItems": true + }, + "pageInfo": { + "$ref": "#/components/schemas/Paginated", + "description": "Pagination Info" } }, - "required": ["payload", "hook"], - "description": "Model for Hook Test Request", - "examples": [ - { - "payload": null, - "hook": { - "fk_model_id": "string", - "title": "string", - "description": "string", - "env": "string", - "event": "after", - "operation": "insert", - "async": true, - "notification": null, - "retries": 0, - "retry_interval": 0, - "timeout": 1, - "active": true + "title": "Project List Model", + "type": "object", + "x-examples": { + "example-1": { + "bases": { + "list": [ + { + "alias": "string", + "database": "string", + "host": "string", + "id": "string", + "params": "string", + "password": "string", + "port": 0, + "project_id": "string", + "ssl": "string", + "type": "string", + "url": "string", + "username": "string" + } + ], + "pageInfo": { + "isFirstPage": true, + "isLastPage": true, + "pageSize": 0, + "sort": "string", + "totalRows": 0 + } } } - ] + } }, - "SignUpReq": { - "type": "object", - "title": "Signup Request Model", - "description": "Model for Signup Request", - "properties": { - "email": { - "type": "string", - "format": "email", - "description": "Email address of the user", - "example": "user@example.com" - }, - "password": { - "type": "string", - "minLength": 8, - "description": "Password of the user", - "example": "password123456789" - } - }, - "required": ["email", "password"], + "ProjectReq": { + "description": "Model for Project Request", "examples": [ { - "email": "user@example.com", - "password": "password123456789" + "bases": [ + { + "alias": "My Base", + "config": null, + "inflection_column": "camelize", + "inflection_table": "camelize", + "is_meta": true, + "type": "mysql" + } + ], + "color": "#24716E", + "description": "This is my project description", + "title": "My Project" } - ] - }, - "SignInReq": { - "type": "object", + ], "properties": { - "email": { - "type": "string", - "format": "email", - "description": "Email address of the user" + "bases": { + "description": "Array of Bases", + "items": { + "$ref": "#/components/schemas/BaseReq" + }, + "type": "array" }, - "password": { - "type": "string", - "description": "Password of the user" + "color": { + "description": "Primary Theme Color", + "example": "#24716E", + "maxLength": 50, + "type": "string" + }, + "description": { + "description": "Project Description", + "example": "This is my project description", + "type": "string" + }, + "title": { + "description": "Project Title", + "example": "My Project", + "maxLength": 128, + "minLength": 1, + "type": "string" } }, - "required": ["email", "password"], - "title": "Signin Request Model", - "description": "Model for Signin Request", + "required": ["title"], + "title": "Project Request Model", + "type": "object" + }, + "ProjectUserReq": { + "description": "Model for Project User Request", "examples": [ { "email": "user@example.com", - "password": "string" + "roles": "owner" } - ] - }, - "PasswordForgotReq": { - "type": "object", + ], "properties": { "email": { - "type": "string", "format": "email", - "description": "Email address of the user" + "type": "string" + }, + "roles": { + "enum": ["commenter", "editor", "guest", "owner", "viewer"], + "type": "string" } }, - "required": ["email"], - "title": "Password Forgot Request Model", - "description": "Model for Password Forgot Request", + "required": ["email", "roles"], + "title": "Project User Request Model", + "type": "object" + }, + "Rollup": { + "description": "Model for Rollup", "examples": [ { - "email": "user@example.com" + "deleted": "string", + "fk_column_id": "string", + "fk_relation_column_id": "string", + "fk_rollup_column_id": "string", + "id": "string", + "order": "string", + "rollup_function": "string", + "type": "string", + "virtual": true } - ] - }, - "PasswordResetReq": { - "type": "object", + ], "properties": { - "password": { - "type": "string", - "minLength": 8, - "example": "newpassword", - "description": "New password" + "deleted": { + "type": "string" + }, + "fk_column_id": { + "$ref": "#/components/schemas/Id", + "description": "Foreign Key to Column" + }, + "fk_relation_column_id": { + "type": "string" + }, + "fk_rollup_column_id": { + "type": "string" + }, + "id": { + "$ref": "#/components/schemas/Id", + "description": "Unique ID" + }, + "order": { + "type": "string" + }, + "rollup_function": { + "type": "string" + }, + "type": { + "type": "string" + }, + "virtual": { + "$ref": "#/components/schemas/Bool" } }, - "required": ["password"], - "title": "Password Reset Request Model", - "description": "Model for Password Reset Request", + "title": "Rollup Model", + "type": "object" + }, + "RollupColumnReq": { + "description": "Model for Rollup Column Request", "examples": [ { - "password": "newpassword" + "fk_relation_column_id": "string", + "fk_rollup_column_id": "string", + "rollup_function": "count", + "title": "string", + "uidt": "Rollup" } - ] - }, - "PasswordChangeReq": { - "type": "object", + ], "properties": { - "currentPassword": { - "type": "string" + "fk_relation_column_id": { + "$ref": "#/components/schemas/Id" }, - "newPassword": { - "type": "string", - "minLength": 8 - } - }, - "required": ["currentPassword", "newPassword"], - "title": "Password Change Request Model", - "description": "Model for Password Change Request", - "examples": [ - { - "currentPassword": "string", - "newPassword": "stringst" - } - ] - }, - "ApiTokenReq": { - "title": "API Token Request Model", - "type": "object", - "properties": { - "description": { - "type": "string", + "fk_rollup_column_id": { + "$ref": "#/components/schemas/Id" + }, + "rollup_function": { + "enum": [ + "avg", + "avgDistinct", + "count", + "countDistinct", + "max", + "min", + "sum", + "sumDistinct" + ], + "type": "string" + }, + "title": { "maxLength": 255, - "description": "Description of the API token" + "type": "string" + }, + "uidt": { + "enum": ["Rollup"], + "type": "string" } }, - "description": "Model for API Token Request", + "required": [ + "fk_relation_column_id", + "fk_rollup_column_id", + "rollup_function", + "title", + "uidt" + ], + "title": "Rollup Column Request Model", + "type": "object" + }, + "SelectOption": { + "description": "Model for SelectOption", "examples": [ { - "description": "string" + "color": "string", + "fk_column_id": "string", + "id": "string", + "order": 1, + "title": "string" } - ] - }, - "Plugin": { - "title": "Plugin Model", - "type": "object", + ], "properties": { - "id": { - "$ref": "#/components/schemas/Id", - "description": "Unique ID" - }, - "title": { + "color": { "type": "string" }, - "description": { - "type": "string" + "fk_column_id": { + "$ref": "#/components/schemas/Id", + "description": "Foreign Key to Column" }, - "active": { - "$ref": "#/components/schemas/Bool" + "id": { + "$ref": "#/components/schemas/Id", + "description": "Unique ID" }, - "rating": { + "order": { "type": "number" }, - "version": { - "type": "string" - }, - "docs": { - "type": "string" - }, - "status": { - "type": "string" - }, - "status_details": { - "type": "string" - }, - "logo": { - "type": "string" - }, - "icon": { - "type": "string" - }, - "tags": { - "type": "string" - }, - "category": { - "type": "string" - }, - "input_schema": { + "title": { "type": "string" - }, - "input": { - "oneOf": [ - { - "type": "integer" - }, + } + }, + "title": "SelectOption Model", + "type": "object" + }, + "SelectOptions": { + "description": "Model for SelectOptions", + "examples": [ + { + "options": [ { - "$ref": "#/components/schemas/StringOrNull" + "color": "string", + "fk_column_id": "string", + "id": "string", + "order": 1, + "title": "string" } ] - }, - "creator": { - "type": "string" - }, - "creator_website": { - "type": "string" - }, - "price": { - "type": "string" + } + ], + "properties": { + "options": { + "items": { + "$ref": "#/components/schemas/SelectOption" + }, + "type": "array" } }, - "description": "Model for Plugin", + "required": ["options"], + "title": "SelectOptions Model", + "type": "object" + }, + "SharedBaseReq": { + "description": "Model for Shared Base Request", "examples": [ { - "id": "string", - "title": "string", - "description": "string", - "active": true, - "rating": 0, - "version": "string", - "docs": "string", - "status": "string", - "status_details": "string", - "logo": "string", - "icon": "string", - "tags": "string", - "category": "string", - "input_schema": "string", - "input": 0, - "creator": "string", - "creator_website": "string", - "price": "string" + "password": "stringst", + "roles": "editor" } - ] - }, - "ModelRoleVisibility": { - "title": "ModelRoleVisibility Model", - "type": "object", + ], "properties": { - "id": { - "$ref": "#/components/schemas/Id", - "description": "Unique ID" - }, - "project_id": { - "type": "string" - }, - "base_id": { - "type": "string" - }, - "fk_model_id": { - "type": "string" - }, - "fk_view_id": { + "password": { + "minLength": 8, "type": "string" }, - "role": { + "roles": { + "enum": ["commenter", "editor", "viewer"], "type": "string" - }, - "disabled": { - "$ref": "#/components/schemas/Bool" } }, - "description": "Model for ModelRoleVisibility", + "title": "Shared Base Request Model", + "type": "object" + }, + "SharedView": { + "description": "Model for Shared View", "examples": [ { - "id": "string", - "project_id": "string", - "base_id": "string", - "fk_model_id": "string", + "deleted": "string", "fk_view_id": "string", - "role": "string", - "disabled": true + "id": "string", + "password": "string" } - ] - }, - "ApiToken": { - "title": "API Token Model", - "type": "object", + ], "properties": { - "id": { - "$ref": "#/components/schemas/Id", - "description": "Unique ID" - }, - "token": { - "type": "string" - }, - "description": { + "deleted": { "type": "string" }, - "fk_user_id": { + "fk_view_id": { "type": "string" }, - "created_at": {}, - "updated_at": {} - }, - "description": "Model for API Token", - "examples": [ - { - "id": "string", - "token": "string", - "description": "string", - "fk_user_id": "string", - "created_at": null, - "updated_at": null - } - ] - }, - "HookLog": { - "title": "Hook Log Model", - "type": "object", - "properties": { "id": { "$ref": "#/components/schemas/Id", "description": "Unique ID" }, - "base_id": { - "type": "string" - }, - "project_id": { - "type": "string" - }, - "fk_hook_id": { - "$ref": "#/components/schemas/StringOrNull" - }, - "type": { - "type": "string" - }, - "event": { - "type": "string" - }, - "operation": { + "password": { "type": "string" + } + }, + "title": "Shared View Model", + "type": "object" + }, + "SharedViewList": { + "description": "Model for Shared View List", + "examples": [ + { + "list": [ + { + "deleted": "string", + "fk_view_id": "string", + "id": "string", + "password": "string" + } + ], + "pageInfo": { + "isFirstPage": true, + "isLastPage": true, + "page": 1, + "pageSize": 10, + "totalRows": 1 + } + } + ], + "properties": { + "list": { + "items": { + "$ref": "#/components/schemas/SharedView" + }, + "minItems": 1, + "type": "array", + "uniqueItems": true }, - "test_call": { - "$ref": "#/components/schemas/Bool" + "pageInfo": { + "$ref": "#/components/schemas/Paginated" + } + }, + "title": "Shared View List Model", + "type": "object", + "x-examples": { + "example-1": { + "bases": { + "list": [ + { + "alias": "string", + "database": "string", + "host": "string", + "id": "string", + "params": "string", + "password": "string", + "port": 0, + "project_id": "string", + "ssl": "string", + "type": "string", + "url": "string", + "username": "string" + } + ], + "pageInfo": { + "isFirstPage": true, + "isLastPage": true, + "pageSize": 0, + "sort": "string", + "totalRows": 0 + } + } + } + } + }, + "SharedViewReq": { + "description": "Model for Shared View Request", + "examples": [ + { + "meta": {}, + "password": "123456789" + } + ], + "properties": { + "meta": { + "$ref": "#/components/schemas/Meta", + "description": "Meta data passing to Shared View such as if download is allowed or not." }, - "payload": {}, - "conditions": { + "password": { + "description": "Password to restrict access", + "example": "123456789", + "minLength": 8, "type": "string" - }, - "notifications": { + } + }, + "title": "Shared View Request Model", + "type": "object" + }, + "SignInReq": { + "description": "Model for Signin Request", + "examples": [ + { + "email": "user@example.com", + "password": "string" + } + ], + "properties": { + "email": { + "description": "Email address of the user", + "format": "email", "type": "string" }, - "error_code": { + "password": { + "description": "Password of the user", "type": "string" - }, - "error_message": { + } + }, + "required": ["email", "password"], + "title": "Signin Request Model", + "type": "object" + }, + "SignUpReq": { + "description": "Model for Signup Request", + "examples": [ + { + "email": "user@example.com", + "password": "password123456789" + } + ], + "properties": { + "email": { + "description": "Email address of the user", + "example": "user@example.com", + "format": "email", "type": "string" }, - "error": { + "password": { + "description": "Password of the user", + "example": "password123456789", + "minLength": 8, "type": "string" - }, - "execution_time": { + } + }, + "required": ["email", "password"], + "title": "Signup Request Model", + "type": "object" + }, + "Sort": { + "description": "Model for Sort", + "examples": [ + { + "base_id": "string", + "direction": "string", + "fk_column_id": "string", + "fk_model_id": "string", + "id": "string", + "order": 0, + "project_id": "string" + } + ], + "properties": { + "base_id": { + "readOnly": true, "type": "string" }, - "response": { + "direction": { "type": "string" }, - "triggered_by": { - "type": "string" + "fk_column_id": { + "$ref": "#/components/schemas/Id" }, - "created_at": { - "type": "string" + "fk_model_id": { + "$ref": "#/components/schemas/Id" }, - "updated_at": { + "id": { + "$ref": "#/components/schemas/Id", + "description": "Unique ID" + }, + "order": { + "type": "number" + }, + "project_id": { + "readOnly": true, "type": "string" } }, - "description": "Model for Hook Log", - "examples": [ - { - "id": "string", - "base_id": "string", - "project_id": "string", - "fk_hook_id": "string", - "type": "string", - "event": "string", - "operation": "string", - "test_call": true, - "payload": null, - "conditions": "string", - "notifications": "string", - "error_code": "string", - "error_message": "string", - "error": "string", - "execution_time": "string", - "response": "string", - "triggered_by": "string", - "created_at": "string", - "updated_at": "string" - } - ] + "title": "Sort Model", + "type": "object" }, - "NormalColumnRequest": { - "description": "Model for Normal Column Request", - "title": "Normal Column Request Model", + "SortList": { + "description": "Model for Sort List", "examples": [ { - "uidt": "ID", - "title": "string", - "dt": "string", - "np": 0, - "ns": 0, - "pk": true, - "pv": true, - "rqd": true, - "column_name": "string", - "un": true, - "ai": true, - "unique": true, - "cdf": "string", - "cc": "string", - "csn": "string", - "dtx": "string", - "dtxp": 0, - "dtxs": 0, - "au": true + "sorts": { + "list": [ + { + "deleted": "string", + "fk_view_id": "string", + "id": "string", + "password": "string" + } + ] + } } ], - "type": "object", "properties": { - "uidt": { - "type": "string", - "enum": [ - "ID", - "SingleLineText", - "LongText", - "Attachment", - "Checkbox", - "MultiSelect", - "SingleSelect", - "Collaborator", - "Date", - "Year", - "GeoData", - "Time", - "PhoneNumber", - "Email", - "URL", - "Number", - "Decimal", - "Currency", - "Percent", - "Duration", - "Rating", - "Count", - "DateTime", - "CreateTime", - "LastModifiedTime", - "AutoNumber", - "Geometry", - "JSON", - "SpecificDBType", - "Barcode", - "Button" - ] - }, - "title": { - "type": "string", - "maxLength": 255 + "sorts": { + "properties": { + "list": { + "items": { + "$ref": "#/components/schemas/SharedView" + }, + "minItems": 1, + "type": "array", + "uniqueItems": true + } + }, + "required": ["list"], + "type": "object" + } + }, + "required": ["sorts"], + "title": "Sort List Model", + "type": "object", + "x-examples": { + "example-1": { + "bases": { + "list": [ + { + "alias": "string", + "database": "string", + "host": "string", + "id": "string", + "params": "string", + "password": "string", + "port": 0, + "project_id": "string", + "ssl": "string", + "type": "string", + "url": "string", + "username": "string" + } + ], + "pageInfo": { + "isFirstPage": true, + "isLastPage": true, + "pageSize": 0, + "sort": "string", + "totalRows": 0 + } + } + } + } + }, + "SortReq": { + "description": "Model for Sort Request", + "examples": [ + { + "direction": "asc", + "fk_column_id": "string" + } + ], + "minProperties": 1, + "properties": { + "direction": { + "description": "Sort direction", + "enum": ["asc", "desc"], + "type": "string" }, - "dt": { + "fk_column_id": { + "$ref": "#/components/schemas/Id", + "description": "Foreign Key to Column" + } + }, + "title": "Sort Request Model", + "type": "object" + }, + "StringOrNull": { + "description": "Model for StringOrNull", + "examples": ["string"], + "oneOf": [ + { + "maxLength": 255, "type": "string" }, - "np": { - "oneOf": [ + { + "type": "null" + } + ], + "title": "StringOrNull Model" + }, + "Table": { + "description": "Model for Table", + "examples": [ + { + "base_id": "ds_g4ccx6e77h1dmi", + "columns": [ { - "type": "integer" + "ai": 0, + "au": 0, + "base_id": "ds_g4ccx6e77h1dmi", + "cc": "", + "cdf": "CURRENT_TIMESTAMP on update CURRENT_TIMESTAMP", + "clen": null, + "column_name": "updated_at", + "cop": "4", + "created_at": "2023-03-02 17:04:06", + "csn": null, + "ct": "timestamp", + "deleted": null, + "dt": "timestamp", + "dtx": "specificType", + "dtxp": "0", + "dtxs": null, + "fk_model_id": "md_rsu68aqjsbyqtl", + "id": "cl_m4wkaqgqqjzoeh", + "meta": null, + "np": null, + "ns": null, + "order": 4, + "pk": 0, + "project_id": "p_xm3thidrblw4n7", + "pv": null, + "rqd": 0, + "system": 0, + "title": "UpdatedAt", + "uidt": "DateTime", + "un": 0, + "unique": 0, + "updated_at": "2023-03-02 17:04:06", + "validate": null, + "virtual": null }, { - "$ref": "#/components/schemas/StringOrNull" - } - ] - }, - "ns": { - "oneOf": [ - { - "type": "integer" + "ai": 0, + "au": 0, + "base_id": "ds_g4ccx6e77h1dmi", + "cc": "", + "cdf": "CURRENT_TIMESTAMP", + "clen": null, + "column_name": "created_at", + "cop": "3", + "created_at": "2023-03-02 17:04:06", + "csn": null, + "ct": "timestamp", + "deleted": null, + "dt": "timestamp", + "dtx": "specificType", + "dtxp": "0", + "dtxs": null, + "fk_model_id": "md_rsu68aqjsbyqtl", + "id": "cl_jpl0qu4gj4rexq", + "meta": null, + "np": null, + "ns": null, + "order": 3, + "pk": 0, + "project_id": "p_xm3thidrblw4n7", + "pv": null, + "rqd": 0, + "system": 0, + "title": "CreatedAt", + "uidt": "DateTime", + "un": 0, + "unique": 0, + "updated_at": "2023-03-02 17:04:06", + "validate": null, + "virtual": null }, { - "$ref": "#/components/schemas/StringOrNull" - } - ] - }, - "pk": { - "$ref": "#/components/schemas/Bool" - }, - "pv": { - "$ref": "#/components/schemas/Bool" - }, - "rqd": { - "$ref": "#/components/schemas/Bool" - }, - "column_name": { - "type": "string", - "maxLength": 255, - "minLength": 1 - }, - "un": { - "$ref": "#/components/schemas/Bool" - }, - "ai": { - "$ref": "#/components/schemas/Bool" - }, - "unique": { - "$ref": "#/components/schemas/Bool" - }, - "cdf": { - "$ref": "#/components/schemas/StringOrNull" - }, - "cc": { - "$ref": "#/components/schemas/StringOrNull" - }, - "csn": { - "$ref": "#/components/schemas/StringOrNull" - }, - "dtx": { - "$ref": "#/components/schemas/StringOrNull" - }, - "dtxp": { - "oneOf": [ - { - "type": "number" + "ai": 0, + "au": 0, + "base_id": "ds_g4ccx6e77h1dmi", + "cc": "", + "cdf": null, + "clen": "45", + "column_name": "title", + "cop": "2", + "created_at": "2023-03-02 17:04:06", + "csn": "utf8mb4", + "ct": "varchar(45)", + "deleted": null, + "dt": "varchar", + "dtx": "specificType", + "dtxp": "45", + "dtxs": null, + "fk_model_id": "md_rsu68aqjsbyqtl", + "id": "cl_c5knoi4xs4sfpt", + "meta": null, + "np": null, + "ns": null, + "order": 2, + "pk": 0, + "project_id": "p_xm3thidrblw4n7", + "pv": 1, + "rqd": 0, + "system": 0, + "title": "Title", + "uidt": "SingleLineText", + "un": 0, + "unique": 0, + "updated_at": "2023-03-02 17:04:06", + "validate": null, + "virtual": null }, { - "$ref": "#/components/schemas/StringOrNull" + "ai": 1, + "au": 0, + "base_id": "ds_g4ccx6e77h1dmi", + "cc": "", + "cdf": null, + "clen": null, + "column_name": "id", + "cop": "1", + "created_at": "2023-03-02 17:04:06", + "csn": null, + "ct": "int unsigned", + "deleted": null, + "dt": "int", + "dtx": "specificType", + "dtxp": "", + "dtxs": "0", + "fk_model_id": "md_rsu68aqjsbyqtl", + "id": "cl_phvuuwjrzcdo0g", + "meta": null, + "np": "10", + "ns": "0", + "order": 1, + "pk": 1, + "project_id": "p_xm3thidrblw4n7", + "pv": null, + "rqd": 1, + "system": 0, + "title": "Id", + "uidt": "ID", + "un": 1, + "unique": 0, + "updated_at": "2023-03-02 17:04:06", + "validate": null, + "virtual": null } - ] - }, - "dtxs": { - "oneOf": [ - { - "type": "number" + ], + "columnsById": { + "cl_c5knoi4xs4sfpt": { + "ai": 0, + "au": 0, + "base_id": "ds_g4ccx6e77h1dmi", + "cc": "", + "cdf": null, + "clen": "45", + "column_name": "title", + "cop": "2", + "created_at": "2023-03-02 17:04:06", + "csn": "utf8mb4", + "ct": "varchar(45)", + "deleted": null, + "dt": "varchar", + "dtx": "specificType", + "dtxp": "45", + "dtxs": null, + "fk_model_id": "md_rsu68aqjsbyqtl", + "id": "cl_c5knoi4xs4sfpt", + "meta": null, + "np": null, + "ns": null, + "order": 2, + "pk": 0, + "project_id": "p_xm3thidrblw4n7", + "pv": 1, + "rqd": 0, + "system": 0, + "title": "Title", + "uidt": "SingleLineText", + "un": 0, + "unique": 0, + "updated_at": "2023-03-02 17:04:06", + "validate": null, + "virtual": null + }, + "cl_jpl0qu4gj4rexq": { + "ai": 0, + "au": 0, + "base_id": "ds_g4ccx6e77h1dmi", + "cc": "", + "cdf": "CURRENT_TIMESTAMP", + "clen": null, + "column_name": "created_at", + "cop": "3", + "created_at": "2023-03-02 17:04:06", + "csn": null, + "ct": "timestamp", + "deleted": null, + "dt": "timestamp", + "dtx": "specificType", + "dtxp": "0", + "dtxs": null, + "fk_model_id": "md_rsu68aqjsbyqtl", + "id": "cl_jpl0qu4gj4rexq", + "meta": null, + "np": null, + "ns": null, + "order": 3, + "pk": 0, + "project_id": "p_xm3thidrblw4n7", + "pv": null, + "rqd": 0, + "system": 0, + "title": "CreatedAt", + "uidt": "DateTime", + "un": 0, + "unique": 0, + "updated_at": "2023-03-02 17:04:06", + "validate": null, + "virtual": null }, + "cl_m4wkaqgqqjzoeh": { + "ai": 0, + "au": 0, + "base_id": "ds_g4ccx6e77h1dmi", + "cc": "", + "cdf": "CURRENT_TIMESTAMP on update CURRENT_TIMESTAMP", + "clen": null, + "column_name": "updated_at", + "cop": "4", + "created_at": "2023-03-02 17:04:06", + "csn": null, + "ct": "timestamp", + "deleted": null, + "dt": "timestamp", + "dtx": "specificType", + "dtxp": "0", + "dtxs": null, + "fk_model_id": "md_rsu68aqjsbyqtl", + "id": "cl_m4wkaqgqqjzoeh", + "meta": null, + "np": null, + "ns": null, + "order": 4, + "pk": 0, + "project_id": "p_xm3thidrblw4n7", + "pv": null, + "rqd": 0, + "system": 0, + "title": "UpdatedAt", + "uidt": "DateTime", + "un": 0, + "unique": 0, + "updated_at": "2023-03-02 17:04:06", + "validate": null, + "virtual": null + }, + "cl_phvuuwjrzcdo0g": { + "ai": 1, + "au": 0, + "base_id": "ds_g4ccx6e77h1dmi", + "cc": "", + "cdf": null, + "clen": null, + "column_name": "id", + "cop": "1", + "created_at": "2023-03-02 17:04:06", + "csn": null, + "ct": "int unsigned", + "deleted": null, + "dt": "int", + "dtx": "specificType", + "dtxp": "", + "dtxs": "0", + "fk_model_id": "md_rsu68aqjsbyqtl", + "id": "cl_phvuuwjrzcdo0g", + "meta": null, + "np": "10", + "ns": "0", + "order": 1, + "pk": 1, + "project_id": "p_xm3thidrblw4n7", + "pv": null, + "rqd": 1, + "system": 0, + "title": "Id", + "uidt": "ID", + "un": 1, + "unique": 0, + "updated_at": "2023-03-02 17:04:06", + "validate": null, + "virtual": null + } + }, + "created_at": "2023-03-02 17:04:06", + "deleted": null, + "enabled": 1, + "id": "md_rsu68aqjsbyqtl", + "meta": null, + "mm": 0, + "order": 1, + "pinned": null, + "project_id": "p_xm3thidrblw4n7", + "schema": null, + "table_name": "nc_vm5q___Table1", + "tags": null, + "title": "Table1", + "type": "table", + "updated_at": "2023-03-02 17:04:08", + "views": [ { - "$ref": "#/components/schemas/StringOrNull" + "_ptn": "Table1", + "_tn": "Table1", + "base_id": "ds_g4ccx6e77h1dmi", + "created_at": "2023-03-02 17:04:06", + "disabled": { + "commenter": false, + "creator": false, + "editor": false, + "guest": false, + "owner": false, + "viewer": false + }, + "fk_model_id": "md_rsu68aqjsbyqtl", + "id": "vw_p2jcatxz4mvcfw", + "is_default": 1, + "lock_type": "collaborative", + "meta": {}, + "order": 1, + "password": null, + "project_id": "p_xm3thidrblw4n7", + "ptn": "nc_vm5q___Table1", + "ptype": "table", + "show": 1, + "show_system_fields": null, + "table_meta": null, + "title": "Table1", + "tn": "Table1", + "type": 3, + "updated_at": "2023-03-02 17:04:06", + "uuid": null, + "view": { + "base_id": "ds_g4ccx6e77h1dmi", + "created_at": "2023-03-02 17:04:06", + "fk_view_id": "vw_p2jcatxz4mvcfw", + "meta": null, + "project_id": "p_xm3thidrblw4n7", + "row_height": null, + "updated_at": "2023-03-02 17:04:06", + "uuid": null + } } ] - }, - "au": { - "$ref": "#/components/schemas/Bool" } - } - }, - "LinkToAnotherColumnReq": { - "type": "object", + ], "properties": { - "uidt": { - "type": "string", - "enum": ["LinkToAnotherRecord"] + "base_id": { + "description": "Unique Base ID", + "type": "string" }, - "title": { - "type": "string", - "maxLength": 255, - "minLength": 1 + "columns": { + "description": "The columns included in this table", + "items": { + "$ref": "#/components/schemas/Column" + }, + "type": "array" }, - "virtual": { + "columnsById": { + "description": "Column Models grouped by IDs", + "type": "object" + }, + "deleted": { "$ref": "#/components/schemas/Bool" }, - "parentId": { - "$ref": "#/components/schemas/Id" + "enabled": { + "$ref": "#/components/schemas/Bool", + "description": "Is this table enabled?" }, - "childId": { - "$ref": "#/components/schemas/Id" + "id": { + "description": "Unique Table ID", + "type": "string" }, - "type": { - "type": "string", - "enum": ["hm", "bt", "mm"] - } - }, - "required": ["uidt", "title", "parentId", "childId", "type"], - "title": "LinkToAnotherColumn Request Model", - "description": "Model for LinkToAnotherColumn Request", - "examples": [ - { - "uidt": "LinkToAnotherRecord", - "title": "string", - "virtual": true, - "parentId": "string", - "childId": "string", - "type": "hm" - } - ] - }, - "RollupColumnReq": { - "type": "object", - "properties": { - "uidt": { - "type": "string", - "enum": ["Rollup"] + "meta": { + "$ref": "#/components/schemas/Meta", + "description": "Meta Data" }, - "title": { - "type": "string", - "maxLength": 255 + "mm": { + "$ref": "#/components/schemas/Bool", + "description": "Is this table used for M2M" }, - "fk_relation_column_id": { - "$ref": "#/components/schemas/Id" + "order": { + "description": "The order of the list of tables", + "type": "number" }, - "fk_rollup_column_id": { - "$ref": "#/components/schemas/Id" + "pinned": { + "$ref": "#/components/schemas/Bool", + "description": "Currently not in use" }, - "rollup_function": { - "type": "string", - "enum": [ - "count", - "min", - "max", - "avg", - "sum", - "countDistinct", - "sumDistinct", - "avgDistinct" - ] + "project_id": { + "description": "Unique Project ID", + "type": "string" + }, + "table_name": { + "description": "Table Name. Prefix will be added for XCDB projects.", + "type": "string" + }, + "tags": { + "description": "Currently not in use", + "type": "string" + }, + "title": { + "description": "Table Title", + "type": "string" + }, + "type": { + "description": "Table Type", + "type": "string" } }, - "required": [ - "uidt", - "title", - "fk_relation_column_id", - "fk_rollup_column_id", - "rollup_function" - ], - "title": "Rollup Column Request Model", - "description": "Model for Rollup Column Request", - "examples": [ - { - "uidt": "Rollup", - "title": "string", - "fk_relation_column_id": "string", - "fk_rollup_column_id": "string", - "rollup_function": "count" - } - ] + "required": ["table_name", "title"], + "title": "Table Model", + "type": "object" }, - "LookupColumnReq": { - "title": "Lookup Column Request Model", - "description": "Model for Lookup Column Request", + "TableList": { + "description": "Model for Table List", "examples": [ { - "uidt": "Lookup", - "title": "string", - "fk_relation_column_id": "string", - "fk_lookup_column_id": "string" + "list": [ + { + "alias": "string", + "base_id": "string", + "column": [ + { + "alias": "string", + "auto_increment": true, + "auto_update_timestamp": true, + "base_id": "string", + "character_maximum_length": "string", + "character_set_name": "string", + "colOptions": { + "deleted": "string", + "dr": "string", + "fk_child_column_id": "string", + "fk_column_id": "string", + "fk_index_name": "string", + "fk_mm_child_column_id": "string", + "fk_mm_model_id": "string", + "fk_mm_parent_column_id": "string", + "fk_parent_column_id": "string", + "id": "string", + "order": "string", + "type": "string", + "ur": "string", + "virtual": true + }, + "column_comment": "string", + "column_default": "string", + "column_ordinal_position": "string", + "column_type": "string", + "data_type": "string", + "data_type_x": "string", + "data_type_x_precision": "string", + "data_type_x_scale": "string", + "deleted": true, + "fk_model_id": "string", + "id": "string", + "numeric_precision": "string", + "numeric_scale": "string", + "order": 0, + "primary_key": true, + "primary_value": true, + "rqd": "string", + "title": "string", + "ui_data_type": "string", + "un": "string", + "unique": true, + "visible": true + } + ], + "columnByIds": {}, + "deleted": true, + "enabled": true, + "id": "string", + "order": 0, + "parent_id": "string", + "pinned": true, + "project_id": "string", + "show_as": "string", + "tags": "string", + "title": "string", + "type": "string" + } + ], + "pageInfo": { + "isFirstPage": true, + "isLastPage": true, + "page": 1, + "pageSize": 10, + "totalRows": 1 + } } ], - "type": "object", "properties": { - "uidt": { - "type": "string", - "enum": ["Lookup"] - }, - "title": { - "type": "string", - "maxLength": 255 - }, - "fk_relation_column_id": { - "$ref": "#/components/schemas/Id" + "list": { + "items": { + "$ref": "#/components/schemas/Table" + }, + "minItems": 1, + "type": "array", + "uniqueItems": true }, - "fk_lookup_column_id": { - "$ref": "#/components/schemas/Id" + "pageInfo": { + "$ref": "#/components/schemas/Paginated" } }, - "required": [ - "uidt", - "title", - "fk_relation_column_id", - "fk_lookup_column_id" - ] + "required": ["tables"], + "title": "Table List Model", + "type": "object", + "x-examples": { + "example-1": { + "bases": { + "list": [ + { + "alias": "string", + "database": "string", + "host": "string", + "id": "string", + "params": "string", + "password": "string", + "port": 0, + "project_id": "string", + "ssl": "string", + "type": "string", + "url": "string", + "username": "string" + } + ], + "pageInfo": { + "isFirstPage": true, + "isLastPage": true, + "pageSize": 0, + "sort": "string", + "totalRows": 0 + } + } + } + } }, - "FormulaColumnReq": { - "title": "Formula Column Request Model", - "description": "Model for Formula Column Request", + "TableReq": { + "description": "Model for Table Request", "examples": [ { - "uidt": "Formula", - "formula_raw": "string", - "formula": "string", - "title": "string" + "columns": [ + { + "ai": false, + "altered": 1, + "cdf": "CURRENT_TIMESTAMP on update CURRENT_TIMESTAMP", + "ck": false, + "clen": 45, + "column_name": "updated_at", + "ct": "varchar(45)", + "dt": "timestamp", + "dtx": "specificType", + "dtxp": "", + "dtxs": "", + "np": null, + "nrqd": true, + "ns": null, + "pk": false, + "rqd": false, + "title": "UpdatedAt", + "uicn": "", + "uidt": "DateTime", + "uip": "", + "un": false + }, + { + "ai": false, + "altered": 1, + "cdf": "CURRENT_TIMESTAMP", + "ck": false, + "clen": 45, + "column_name": "created_at", + "ct": "varchar(45)", + "dt": "timestamp", + "dtx": "specificType", + "dtxp": "", + "dtxs": "", + "np": null, + "nrqd": true, + "ns": null, + "pk": false, + "rqd": false, + "title": "CreatedAt", + "uicn": "", + "uidt": "DateTime", + "uip": "", + "un": false + }, + { + "ai": false, + "altered": 1, + "cdf": null, + "ck": false, + "clen": 45, + "column_name": "title", + "ct": "varchar(45)", + "dt": "varchar", + "dtx": "specificType", + "dtxp": "45", + "dtxs": "", + "np": null, + "nrqd": true, + "ns": null, + "pk": false, + "rqd": false, + "title": "Title", + "uicn": "", + "uidt": "SingleLineText", + "uip": "", + "un": false + }, + { + "ai": true, + "altered": 1, + "cdf": null, + "ck": false, + "clen": null, + "column_name": "id", + "ct": "int(11)", + "dt": "int", + "dtx": "integer", + "dtxp": "11", + "dtxs": "", + "np": 11, + "nrqd": false, + "ns": 0, + "pk": true, + "rqd": true, + "title": "Id", + "uicn": "", + "uidt": "ID", + "uip": "", + "un": true + } + ], + "table_name": "Sheet-1", + "title": "Sheet-1" } ], - "type": "object", "properties": { - "uidt": { - "type": "string", - "enum": ["Formula"] + "columns": { + "description": "The column models in this table", + "items": { + "$ref": "#/components/schemas/NormalColumnRequest" + }, + "type": "array" }, - "formula_raw": { - "type": "string" + "meta": { + "$ref": "#/components/schemas/Meta", + "description": "the meta data for this table" }, - "formula": { + "order": { + "description": "The order of table list", + "example": 1, + "type": "number" + }, + "table_name": { + "description": "Table name", + "example": "my_table", + "maxLength": 255, + "minLength": 1, "type": "string" }, "title": { - "type": "string", + "description": "Table title", + "example": "My Table", + "maxLength": 255, "minLength": 1, - "maxLength": 255 - } - } - }, - "UserInfo": { - "title": "User Info Model", - "type": "object", - "description": "Model for User Info", - "properties": { - "id": { - "type": "string", - "description": "User ID" - }, - "email": { - "type": "string", - "description": "User Email", - "format": "email" - }, - "email_verified": { - "type": "boolean", - "description": "Set to true if the user's email has been verified." - }, - "firstname": { - "type": "string", - "description": "The firstname of the user" - }, - "lastname": { - "type": "string", - "description": "The lastname of the user" - }, - "roles": { - "description": "The roles of the user" + "type": "string" } }, - "examples": [ - { - "id": "string", - "email": "user@example.com", - "email_verified": true, - "firstname": "string", - "lastname": "string", - "roles": null - } - ] + "required": ["columns", "table_name", "title"], + "title": "Table Request Model", + "type": "object" }, - "VisibilityRuleReq": { - "title": "Visibility Rule Request Model", - "type": "array", - "items": { - "type": "object", - "properties": { - "disabled": { - "type": "object", - "properties": { - "commenter": { - "$ref": "#/components/schemas/Bool" - }, - "creator": { - "$ref": "#/components/schemas/Bool" - }, - "editor": { - "$ref": "#/components/schemas/Bool" - }, - "guest": { - "$ref": "#/components/schemas/Bool" - }, - "owner": { - "$ref": "#/components/schemas/Bool" - }, - "viewer": { - "$ref": "#/components/schemas/Bool" - } - } - } - } - }, - "description": "Model for Visibility Rule Request", + "User": { + "description": "Model for User", "examples": [ - [ - { - "disabled": { - "commenter": true, - "creator": true, - "editor": true, - "guest": true, - "owner": true, - "viewer": true - } - } - ] - ] - }, - "Bool": { - "oneOf": [ - { - "type": "boolean", - "description": "true or false" - }, - { - "type": "integer", - "description": "0 or 1", - "example": 0 - }, { - "type": "null" + "created_at": "2023-03-01 11:36:49", + "email": "alice.smith@nocodb.com", + "email_verified": true, + "firstName": "Alice", + "id": "us_8kugj628ebjngs", + "lastName": "Smith", + "roles": "org-level-viewer", + "updated_at": "2023-03-01 11:36:49" } ], - "title": "Bool Model", - "description": "Model for Bool", - "examples": [true] - }, - "Id": { - "type": "string", - "minLength": 1, - "maxLength": 20, - "title": "ID Model", - "description": "Model for ID", - "examples": ["string"] - }, - "Password": { - "type": "string", - "minLength": 8, - "title": "Password Model", - "description": "Model for Password", - "example": "password123456789", - "examples": ["password123456789"] - }, - "StringOrNull": { - "oneOf": [ - { - "type": "string", - "maxLength": 255 + "properties": { + "created_at": { + "description": "The date that the user was created.", + "example": "2023-03-01 11:36:49", + "format": "date-time", + "type": "string" }, - { - "type": "null" - } - ], - "title": "StringOrNull Model", - "description": "Model for StringOrNull", - "examples": ["string"] - }, - "Meta": { - "oneOf": [ - { - "type": "object" + "email": { + "description": "The email of the user", + "example": "alice.smith@nocodb.com", + "format": "email", + "type": "string" }, - { + "email_verified": { + "description": "Set to true if the user's email has been verified.", + "type": "boolean" + }, + "firstname": { + "description": "The first name of the user", + "example": "Alice", "type": "string" }, - { - "type": "null" - } - ], - "title": "Meta Model", - "description": "Model for Meta", - "examples": [{}] - }, - "CommentReq": { - "type": "object", - "properties": { - "row_id": { + "id": { + "description": "Unique identifier for the given user.", + "example": "us_8kugj628ebjngs", "type": "string" }, - "fk_model_id": { + "lastname": { + "description": "The last name of the user", + "example": "Smith", "type": "string" }, - "description": { + "roles": { + "description": "The roles of the user", + "example": "org-level-viewer", + "type": "string" + }, + "updated_at": { + "description": "The date that the user was created.", + "example": "2023-03-01 11:36:49", + "format": "date-time", "type": "string" } }, - "required": ["row_id", "fk_model_id", "comment"], - "title": "Comment Request Model", - "description": "Model for Comment Request", + "required": ["email", "email_verified", "firstname", "id", "lastname"], + "title": "User Model", + "type": "object", + "x-internal": false + }, + "UserInfo": { + "description": "Model for User Info", "examples": [ { - "row_id": "string", - "fk_model_id": "string", - "description": "string" + "email": "user@example.com", + "email_verified": true, + "firstname": "string", + "id": "string", + "lastname": "string", + "roles": null } - ] - }, - "AuditRowUpdateReq": { - "type": "object", + ], "properties": { - "fk_model_id": { + "email": { + "description": "User Email", + "format": "email", "type": "string" }, - "column_name": { + "email_verified": { + "description": "Set to true if the user's email has been verified.", + "type": "boolean" + }, + "firstname": { + "description": "The firstname of the user", "type": "string" }, - "row_id": { + "id": { + "description": "User ID", "type": "string" }, - "value": {}, - "prev_value": {} - }, - "title": "Audit Row Update Request Model", - "description": "Model for Audit Row Update Request", - "examples": [ - { - "fk_model_id": "string", - "column_name": "string", - "row_id": "string", - "value": null, - "prev_value": null - } - ] - }, - "OrgUserReq": { - "type": "object", - "properties": { - "email": { - "type": "string", - "format": "email" + "lastname": { + "description": "The lastname of the user", + "type": "string" }, "roles": { - "type": "string", - "enum": ["org-level-creator", "org-level-viewer"] + "description": "The roles of the user" } }, - "title": "Organisation User Request Model", - "description": "Model for Organisation User Update Request", + "title": "User Info Model", + "type": "object" + }, + "UserList": { + "description": "Model for User List", "examples": [ { - "email": "user@example.com", - "roles": "org-level-creator" + "users": { + "list": { + "created_at": "2023-03-01 11:36:49", + "email": "alice.smith@nocodb.com", + "email_verified": true, + "firstName": "Alice", + "id": "us_8kugj628ebjngs", + "lastName": "Smith", + "roles": "org-level-viewer", + "updated_at": "2023-03-01 11:36:49" + }, + "pageInfo": { + "isFirstPage": true, + "isLastPage": true, + "page": 1, + "pageSize": 10, + "totalRows": 1 + } + } } - ] - }, - "ProjectUserReq": { - "type": "object", + ], "properties": { - "email": { - "type": "string", - "format": "email" - }, - "roles": { - "type": "string", - "enum": ["owner", "editor", "viewer", "commenter", "guest"] + "users": { + "description": "users includes `list` and `pageInfo`", + "properties": { + "list": { + "$ref": "#/components/schemas/User", + "description": "List of User objects" + }, + "pageInfo": { + "$ref": "#/components/schemas/Paginated", + "description": "Pagination info" + } + }, + "required": ["list", "pageInfo"], + "type": "object" } }, - "required": ["email", "roles"], - "title": "Project User Request Model", - "description": "Model for Project User Request", + "required": ["users"], + "title": "User List Model", + "type": "object", + "x-examples": { + "example-1": { + "bases": { + "list": [ + { + "alias": "string", + "database": "string", + "host": "string", + "id": "string", + "params": "string", + "password": "string", + "port": 0, + "project_id": "string", + "ssl": "string", + "type": "string", + "url": "string", + "username": "string" + } + ], + "pageInfo": { + "isFirstPage": true, + "isLastPage": true, + "pageSize": 0, + "sort": "string", + "totalRows": 0 + } + } + } + } + }, + "View": { + "description": "Model for View", "examples": [ { - "email": "user@example.com", - "roles": "owner" + "base_id": "ds_g4ccx6e77h1dmi", + "created_at": "2023-03-02 17:46:31", + "fk_model_id": "md_mhs9z4r2ak98x0", + "id": "vw_lg052cnc1c26kf", + "is_default": 1, + "lock_type": "collaborative", + "meta": {}, + "order": 1, + "password": null, + "project_id": "p_xm3thidrblw4n7", + "show": 1, + "show_system_fields": null, + "title": "Sheet-1", + "type": 3, + "updated_at": "2023-03-02 17:46:31", + "uuid": null, + "view": { + "base_id": "ds_g4ccx6e77h1dmi", + "created_at": "2023-03-02 17:46:31", + "fk_view_id": "vw_lg052cnc1c26kf", + "meta": null, + "project_id": "p_xm3thidrblw4n7", + "row_height": null, + "updated_at": "2023-03-02 17:46:31", + "uuid": null + } } - ] - }, - "SharedBaseReq": { - "type": "object", + ], "properties": { - "roles": { - "type": "string", - "enum": ["editor", "viewer", "commenter"] + "base_id": { + "$ref": "#/components/schemas/Id", + "description": "Unique Base ID" + }, + "fk_model_id": { + "$ref": "#/components/schemas/Id", + "description": "Unique Model ID" + }, + "id": { + "$ref": "#/components/schemas/Id", + "description": "Unique ID for View" + }, + "lock_type": { + "description": "Lock Type of the view", + "enum": ["collaborative", "locked", "personal"], + "type": "string" + }, + "meta": { + "$ref": "#/components/schemas/Meta", + "description": "Meta data for this view" + }, + "order": { + "description": "The rder of the list of views", + "type": "number" }, "password": { - "type": "string", - "minLength": 8 + "description": "Password for protecting the view", + "type": "string" + }, + "project_id": { + "$ref": "#/components/schemas/Id", + "description": "Unique Project ID" + }, + "show": { + "$ref": "#/components/schemas/Bool", + "description": "If this view is shown?" + }, + "show_system_fields": { + "$ref": "#/components/schemas/Bool", + "description": "Should show system fields in this view?" + }, + "title": { + "description": "View Title", + "type": "string" + }, + "type": { + "description": "View Type", + "type": "number" + }, + "uuid": { + "description": "UUID of the view", + "type": "string" + }, + "view": { + "anyOf": [ + { + "$ref": "#/components/schemas/Form" + }, + { + "$ref": "#/components/schemas/Gallery" + }, + { + "$ref": "#/components/schemas/Grid" + }, + { + "$ref": "#/components/schemas/Kanban" + }, + { + "$ref": "#/components/schemas/Map" + } + ], + "description": "Associated View Model" } }, - "title": "Shared Base Request Model", - "description": "Model for Shared Base Request", + "required": ["fk_model_id", "show", "title", "type"], + "title": "View Model", + "type": "object" + }, + "ViewList": { + "description": "Model for View List", "examples": [ { - "roles": "editor", - "password": "stringst" + "list": [ + { + "alias": "string", + "column": [ + { + "alias": "string", + "auto_increment": true, + "auto_update_timestamp": true, + "base_id": "string", + "character_maximum_length": "string", + "character_set_name": "string", + "colOptions": { + "deleted": "string", + "dr": "string", + "fk_child_column_id": "string", + "fk_column_id": "string", + "fk_index_name": "string", + "fk_mm_child_column_id": "string", + "fk_mm_model_id": "string", + "fk_mm_parent_column_id": "string", + "fk_parent_column_id": "string", + "id": "string", + "order": "string", + "type": "string", + "ur": "string", + "virtual": true + }, + "column_comment": "string", + "column_default": "string", + "column_ordinal_position": "string", + "column_type": "string", + "data_type": "string", + "data_type_x": "string", + "data_type_x_precision": "string", + "data_type_x_scale": "string", + "deleted": true, + "fk_model_id": "string", + "id": "string", + "numeric_precision": "string", + "numeric_scale": "string", + "order": 0, + "primary_key": true, + "primary_value": true, + "rqd": "string", + "title": "string", + "ui_data_type": "string", + "un": "string", + "unique": true, + "visible": true + } + ], + "columnByIds": {}, + "deleted": true, + "enabled": true, + "fk_base_id": "string", + "fk_project_id": "string", + "id": "string", + "order": 0, + "parent_id": "string", + "pinned": true, + "show_as": "string", + "tags": "string", + "title": "string", + "type": "string" + } + ], + "pageInfo": { + "isFirstPage": true, + "isLastPage": true, + "page": 1, + "pageSize": 10, + "totalRows": 1 + } } - ] - }, - "PluginTestReq": { - "type": "object", + ], "properties": { - "title": { - "type": "string", - "maxLength": 45 + "list": { + "items": { + "$ref": "#/components/schemas/View" + }, + "type": "array" }, - "input": {} + "pageInfo": { + "$ref": "#/components/schemas/Paginated" + } }, - "required": ["title", "input"], - "title": "Plugin Test Request Model", - "description": "Model for Plugin Test Request", - "examples": [ - { - "title": "string", - "input": null + "required": ["views"], + "title": "View List Model", + "type": "object", + "x-examples": { + "example-1": { + "bases": { + "list": [ + { + "alias": "string", + "database": "string", + "host": "string", + "id": "string", + "params": "string", + "password": "string", + "port": 0, + "project_id": "string", + "ssl": "string", + "type": "string", + "url": "string", + "username": "string" + } + ], + "pageInfo": { + "isFirstPage": true, + "isLastPage": true, + "pageSize": 0, + "sort": "string", + "totalRows": 0 + } + } } - ] + } }, - "PluginReq": { - "type": "object", - "properties": { - "active": { - "$ref": "#/components/schemas/Bool" - }, - "input": {} - }, - "title": "Plugin Reqeust", - "description": "Model for Plugin Request", + "ViewReq": { + "description": "Model for View Request", "examples": [ { - "active": true, - "input": null + "lock_type": "collaborative", + "meta": {}, + "order": 0, + "show_system_fields": true, + "title": "string" } - ] - }, - "ViewReq": { - "type": "object", + ], "properties": { - "order": { - "type": "number", - "minimum": 0, - "exclusiveMinimum": true + "lock_type": { + "enum": ["collaborative", "locked", "personal"], + "type": "string" }, "meta": { "$ref": "#/components/schemas/Meta" }, - "title": { - "type": "string", - "maxLength": 255 + "order": { + "exclusiveMinimum": true, + "minimum": 0, + "type": "number" }, "show_system_fields": { "$ref": "#/components/schemas/Bool" }, - "lock_type": { - "type": "string", - "enum": ["collaborative", "locked", "personal"] + "title": { + "maxLength": 255, + "type": "string" } }, "title": "View Request Model", - "description": "Model for View Request", + "type": "object" + }, + "VisibilityRuleReq": { + "description": "Model for Visibility Rule Request", + "examples": [ + [ + { + "disabled": { + "commenter": true, + "creator": true, + "editor": true, + "guest": true, + "owner": true, + "viewer": true + } + } + ] + ], + "items": { + "properties": { + "disabled": { + "properties": { + "commenter": { + "$ref": "#/components/schemas/Bool" + }, + "creator": { + "$ref": "#/components/schemas/Bool" + }, + "editor": { + "$ref": "#/components/schemas/Bool" + }, + "guest": { + "$ref": "#/components/schemas/Bool" + }, + "owner": { + "$ref": "#/components/schemas/Bool" + }, + "viewer": { + "$ref": "#/components/schemas/Bool" + } + }, + "type": "object" + } + }, + "type": "object" + }, + "title": "Visibility Rule Request Model", + "type": "array" + }, + "Webhook": { + "description": "Model for Webhook", "examples": [ { - "order": 0, - "meta": {}, + "id": "string", "title": "string", - "show_system_fields": true, - "lock_type": "collaborative" + "type": "string" } - ] - }, - "SharedViewReq": { - "type": "object", - "title": "Shared View Request Model", - "description": "Model for Shared View Request", + ], "properties": { - "password": { - "type": "string", - "minLength": 8, - "example": "123456789", - "description": "Password to restrict access" + "id": { + "$ref": "#/components/schemas/Id", + "description": "Unique ID" }, - "meta": { - "$ref": "#/components/schemas/Meta", - "description": "Meta data passing to Shared View such as if download is allowed or not." + "title": { + "type": "string" + }, + "type": { + "type": "string" } }, - "examples": [ - { - "password": "123456789", - "meta": {} - } - ] + "title": "Webhook Model", + "type": "object" } }, "responses": {