Browse Source

chore(swagger): type correction

Signed-off-by: Pranav C <pranavxc@gmail.com>
pull/3188/head
Pranav C 2 years ago
parent
commit
9c74e5285c
  1. 36
      packages/nocodb-sdk/src/lib/Api.ts
  2. 104
      scripts/sdk/swagger.json

36
packages/nocodb-sdk/src/lib/Api.ts

@ -3062,32 +3062,40 @@ export class Api<
}),
/**
* No description
* @description Read project details
*
* @tags Public
* @name SharedViewMetaGet
* @request GET:/api/v1/db/public/shared-view/{sharedViewUuid}/meta
* @response `200` `object` OK
* @name SharedBaseGet
* @request GET:/api/v1/db/public/shared-base/{sharedBaseUuid}/meta
* @response `200` `{ project_id?: string }` OK
*/
sharedViewMetaGet: (sharedViewUuid: string, params: RequestParams = {}) =>
this.request<object, any>({
path: `/api/v1/db/public/shared-view/${sharedViewUuid}/meta`,
sharedBaseGet: (sharedBaseUuid: string, params: RequestParams = {}) =>
this.request<{ project_id?: string }, any>({
path: `/api/v1/db/public/shared-base/${sharedBaseUuid}/meta`,
method: 'GET',
format: 'json',
...params,
}),
/**
* @description Read project details
* No description
*
* @tags Public
* @name SharedBaseGet
* @request GET:/api/v1/db/public/shared-base/{sharedBaseUuid}/meta
* @response `200` `{ project_id?: string }` OK
* @name SharedViewMetaGet
* @request GET:/api/v1/db/public/shared-view/{sharedViewUuid}/meta
* @response `200` `(ViewType & { relatedMetas?: any, client?: string, columns?: (GridColumnType | FormColumnType | GalleryColumnType), model?: TableType } & { view?: (FormType | GridType | GalleryType) })` OK
*/
sharedBaseGet: (sharedBaseUuid: string, params: RequestParams = {}) =>
this.request<{ project_id?: string }, any>({
path: `/api/v1/db/public/shared-base/${sharedBaseUuid}/meta`,
sharedViewMetaGet: (sharedViewUuid: string, params: RequestParams = {}) =>
this.request<
ViewType & {
relatedMetas?: any;
client?: string;
columns?: GridColumnType | FormColumnType | GalleryColumnType;
model?: TableType;
} & { view?: FormType | GridType | GalleryType },
any
>({
path: `/api/v1/db/public/shared-view/${sharedViewUuid}/meta`,
method: 'GET',
format: 'json',
...params,

104
scripts/sdk/swagger.json

@ -4363,28 +4363,22 @@
"description": ""
}
},
"/api/v1/db/public/shared-view/{sharedViewUuid}/meta": {
"/api/v1/db/public/shared-base/{sharedBaseUuid}/meta": {
"parameters": [
{
"schema": {
"type": "string"
},
"name": "sharedViewUuid",
"name": "sharedBaseUuid",
"in": "path",
"required": true
},
{
"schema": {
"type": "string"
},
"in": "header",
"name": "xc-password",
"description": "Shared view password"
}
],
"get": {
"summary": "",
"operationId": "public-shared-view-meta-get",
"operationId": "public-shared-base-get",
"description": "Read project details",
"parameters": [],
"responses": {
"200": {
"description": "OK",
@ -4392,58 +4386,110 @@
"application/json": {
"schema": {
"type": "object",
"properties": {}
"properties": {
"project_id": {
"type": "string"
}
}
}
},
"application/xml": {
"schema": {}
}
}
}
},
"tags": [
"Public"
],
"description": "",
"parameters": []
]
}
},
"/api/v1/db/public/shared-base/{sharedBaseUuid}/meta": {
"/api/v1/db/public/shared-view/{sharedViewUuid}/meta": {
"parameters": [
{
"schema": {
"type": "string"
},
"name": "sharedBaseUuid",
"name": "sharedViewUuid",
"in": "path",
"required": true
},
{
"schema": {
"type": "string"
},
"in": "header",
"name": "xc-password",
"description": "Shared view password"
}
],
"get": {
"summary": "",
"operationId": "public-shared-base-get",
"description": "Read project details",
"parameters": [],
"operationId": "public-shared-view-meta-get",
"responses": {
"200": {
"description": "OK",
"content": {
"application/json": {
"schema": {
"type": "object",
"properties": {
"project_id": {
"type": "string"
"allOf": [
{
"$ref": "#/components/schemas/View"
},
{
"type": "object",
"properties": {
"relatedMetas": {},
"client": {
"type": "string"
},
"columns": {
"oneOf": [
{
"$ref": "#/components/schemas/GridColumn"
},
{
"$ref": "#/components/schemas/FormColumn"
},
{
"$ref": "#/components/schemas/GalleryColumn"
}
]
},
"model": {
"$ref": "#/components/schemas/Table"
}
}
},
{
"properties": {
"view": {
"oneOf": [
{
"$ref": "#/components/schemas/Form"
},
{
"$ref": "#/components/schemas/Grid"
},
{
"$ref": "#/components/schemas/Gallery"
}
]
}
},
"type": "object"
}
}
]
}
},
"application/xml": {
"schema": {}
}
}
}
},
"tags": [
"Public"
]
],
"description": "",
"parameters": []
}
},
"/api/v1/db/meta/audits/comments": {

Loading…
Cancel
Save