@fusebase/fusebase-gate-sdk 1.0.2-sdk.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +52 -0
- package/dist/apis/CustomDashboardRowsApi.d.ts +113 -0
- package/dist/apis/CustomDashboardRowsApi.js +122 -0
- package/dist/apis/DashboardDataApi.d.ts +98 -0
- package/dist/apis/DashboardDataApi.js +91 -0
- package/dist/apis/DashboardRelationsApi.d.ts +92 -0
- package/dist/apis/DashboardRelationsApi.js +117 -0
- package/dist/apis/DashboardsApi.d.ts +405 -0
- package/dist/apis/DashboardsApi.js +507 -0
- package/dist/apis/DatabasesApi.d.ts +134 -0
- package/dist/apis/DatabasesApi.js +162 -0
- package/dist/apis/HealthApi.d.ts +19 -0
- package/dist/apis/HealthApi.js +28 -0
- package/dist/apis/OrgUsersApi.d.ts +22 -0
- package/dist/apis/OrgUsersApi.js +29 -0
- package/dist/apis/ResolveApi.d.ts +20 -0
- package/dist/apis/ResolveApi.js +29 -0
- package/dist/apis/TemplatesApi.d.ts +100 -0
- package/dist/apis/TemplatesApi.js +124 -0
- package/dist/apis/TokensApi.d.ts +71 -0
- package/dist/apis/TokensApi.js +95 -0
- package/dist/extras/fetchWithRetry.d.ts +30 -0
- package/dist/extras/fetchWithRetry.js +53 -0
- package/dist/extras/messaging.d.ts +81 -0
- package/dist/extras/messaging.js +16 -0
- package/dist/index.d.ts +11 -0
- package/dist/index.js +31 -0
- package/dist/runtime/index.d.ts +5 -0
- package/dist/runtime/index.js +21 -0
- package/dist/runtime/transport.d.ts +28 -0
- package/dist/runtime/transport.js +237 -0
- package/dist/runtime/types.d.ts +52 -0
- package/dist/runtime/types.js +23 -0
- package/dist/types/common/portal-form.d.ts +14 -0
- package/dist/types/common/portal-form.js +8 -0
- package/dist/types/dashboard/custom-item.d.ts +53 -0
- package/dist/types/dashboard/custom-item.js +22 -0
- package/dist/types/dashboard/dashboard.d.ts +421 -0
- package/dist/types/dashboard/dashboard.js +8 -0
- package/dist/types/dashboard/dashboards.d.ts +19 -0
- package/dist/types/dashboard/dashboards.js +8 -0
- package/dist/types/dashboard/data.d.ts +10 -0
- package/dist/types/dashboard/data.js +8 -0
- package/dist/types/dashboard/export.d.ts +11 -0
- package/dist/types/dashboard/export.js +8 -0
- package/dist/types/dashboard/index.d.ts +215 -0
- package/dist/types/dashboard/index.js +34 -0
- package/dist/types/dashboard/intent.d.ts +243 -0
- package/dist/types/dashboard/intent.js +8 -0
- package/dist/types/dashboard/items.d.ts +14 -0
- package/dist/types/dashboard/items.js +8 -0
- package/dist/types/dashboard/metadata.d.ts +12 -0
- package/dist/types/dashboard/metadata.js +8 -0
- package/dist/types/dashboard/render.d.ts +188 -0
- package/dist/types/dashboard/render.js +51 -0
- package/dist/types/dashboard/rows.d.ts +77 -0
- package/dist/types/dashboard/rows.js +14 -0
- package/dist/types/dashboard/schema.d.ts +172 -0
- package/dist/types/dashboard/schema.js +17 -0
- package/dist/types/dashboard/values.d.ts +187 -0
- package/dist/types/dashboard/values.js +8 -0
- package/dist/types/dashboard/view.d.ts +249 -0
- package/dist/types/dashboard/view.js +8 -0
- package/dist/types/database/database.d.ts +203 -0
- package/dist/types/database/database.js +8 -0
- package/dist/types/database/export.d.ts +11 -0
- package/dist/types/database/export.js +8 -0
- package/dist/types/index.d.ts +31 -0
- package/dist/types/index.js +30 -0
- package/dist/types/org-user/org-user.d.ts +19 -0
- package/dist/types/org-user/org-user.js +6 -0
- package/dist/types/relations/relations.d.ts +138 -0
- package/dist/types/relations/relations.js +14 -0
- package/dist/types/resolve/resolve.d.ts +86 -0
- package/dist/types/resolve/resolve.js +20 -0
- package/dist/types/shared/common.d.ts +122 -0
- package/dist/types/shared/common.js +24 -0
- package/dist/types/shared/enums.d.ts +64 -0
- package/dist/types/shared/enums.js +52 -0
- package/dist/types/shared/health.d.ts +12 -0
- package/dist/types/shared/health.js +8 -0
- package/dist/types/shared/parameters.d.ts +95 -0
- package/dist/types/shared/parameters.js +2 -0
- package/dist/types/template/template.d.ts +74 -0
- package/dist/types/template/template.js +8 -0
- package/dist/types/token/token.d.ts +184 -0
- package/dist/types/token/token.js +8 -0
- package/package.json +16 -0
|
@@ -0,0 +1,188 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Render Schemas
|
|
3
|
+
*
|
|
4
|
+
* Generated from OpenAPI specification
|
|
5
|
+
* Source: schemas/dashboard/render.yaml
|
|
6
|
+
*/
|
|
7
|
+
export interface CustomLabelContract {
|
|
8
|
+
nanoid: string;
|
|
9
|
+
name: string;
|
|
10
|
+
color: string;
|
|
11
|
+
}
|
|
12
|
+
export interface RenderAssigneesContract extends RenderBaseContract {
|
|
13
|
+
_type_assignee: true;
|
|
14
|
+
type: "assignee";
|
|
15
|
+
multi_select: boolean;
|
|
16
|
+
required: boolean;
|
|
17
|
+
}
|
|
18
|
+
export interface RenderAutoContract extends RenderBaseContract {
|
|
19
|
+
_type_auto: true;
|
|
20
|
+
type: "auto";
|
|
21
|
+
}
|
|
22
|
+
export interface RenderBaseContract {
|
|
23
|
+
is_lookup: boolean;
|
|
24
|
+
type: SchemaItemRenderTypeContract;
|
|
25
|
+
edit_type: SchemaItemRenderEditTypeContract;
|
|
26
|
+
}
|
|
27
|
+
export interface RenderBooleanContract extends RenderBaseContract {
|
|
28
|
+
_type_boolean: true;
|
|
29
|
+
type: "boolean";
|
|
30
|
+
default_value: boolean;
|
|
31
|
+
}
|
|
32
|
+
export interface RenderChildTableLinkContract extends RenderBaseContract {
|
|
33
|
+
_type_child_table_link: true;
|
|
34
|
+
type: "child-table-link";
|
|
35
|
+
required: boolean;
|
|
36
|
+
}
|
|
37
|
+
export interface RenderCurrencyContract extends RenderBaseContract, RenderNumberBasePropsContract {
|
|
38
|
+
_type_currency: true;
|
|
39
|
+
type: "currency";
|
|
40
|
+
currency_code: string;
|
|
41
|
+
currency_symbol: string;
|
|
42
|
+
}
|
|
43
|
+
export interface RenderDateContract extends RenderBaseContract {
|
|
44
|
+
_type_date: true;
|
|
45
|
+
type: "date";
|
|
46
|
+
date_render: "auto" | "DD/MM/YYYY HH:mm:ss" | "MM/DD/YYYY HH:mm:ss";
|
|
47
|
+
date_format: "date" | "date-time" | "time";
|
|
48
|
+
time_format: "12h" | "24h";
|
|
49
|
+
time_zone: string;
|
|
50
|
+
/**
|
|
51
|
+
* @format date-time
|
|
52
|
+
*/
|
|
53
|
+
minDate?: Date;
|
|
54
|
+
/**
|
|
55
|
+
* @format date-time
|
|
56
|
+
*/
|
|
57
|
+
maxDate?: Date;
|
|
58
|
+
}
|
|
59
|
+
export interface RenderEmailContract extends RenderBaseContract {
|
|
60
|
+
_type_email: true;
|
|
61
|
+
type: "email";
|
|
62
|
+
}
|
|
63
|
+
export interface RenderFilesContract extends RenderBaseContract {
|
|
64
|
+
_type_files: true;
|
|
65
|
+
type: "files";
|
|
66
|
+
/**
|
|
67
|
+
* @minimum 1
|
|
68
|
+
*/
|
|
69
|
+
max_files_length?: number;
|
|
70
|
+
}
|
|
71
|
+
export interface RenderLabelContract extends RenderBaseContract {
|
|
72
|
+
_type_label: true;
|
|
73
|
+
type: "label";
|
|
74
|
+
multi_select: boolean;
|
|
75
|
+
labels: CustomLabelContract[];
|
|
76
|
+
}
|
|
77
|
+
export interface RenderLinkContract extends RenderBaseContract {
|
|
78
|
+
_type_link: true;
|
|
79
|
+
type: "link";
|
|
80
|
+
target: "self" | "blank";
|
|
81
|
+
}
|
|
82
|
+
export interface RenderNumberContract extends RenderBaseContract, RenderNumberBasePropsContract {
|
|
83
|
+
_type_number: true;
|
|
84
|
+
type: "number";
|
|
85
|
+
unit?: string;
|
|
86
|
+
}
|
|
87
|
+
export interface RenderNumberBasePropsContract {
|
|
88
|
+
/**
|
|
89
|
+
* @minimum 0
|
|
90
|
+
*/
|
|
91
|
+
precision: number;
|
|
92
|
+
thousand_separator: "space" | "period" | "comma";
|
|
93
|
+
decimal_separator: "period" | "comma";
|
|
94
|
+
unit_position: "prefix" | "suffix";
|
|
95
|
+
min?: number;
|
|
96
|
+
max?: number;
|
|
97
|
+
}
|
|
98
|
+
export interface RenderPhoneContract extends RenderBaseContract {
|
|
99
|
+
_type_phone: true;
|
|
100
|
+
type: "phone";
|
|
101
|
+
}
|
|
102
|
+
export interface RenderPortalContract extends RenderBaseContract {
|
|
103
|
+
_type_portal: true;
|
|
104
|
+
type: "portal";
|
|
105
|
+
}
|
|
106
|
+
export interface RenderPortalFormDataContract extends RenderBaseContract {
|
|
107
|
+
_type_portal_form_data: true;
|
|
108
|
+
type: "portal-form-data";
|
|
109
|
+
}
|
|
110
|
+
export interface RenderPortalListContract extends RenderBaseContract {
|
|
111
|
+
_type_portal_list: true;
|
|
112
|
+
type: "portal-list";
|
|
113
|
+
}
|
|
114
|
+
export interface RenderStringContract extends RenderBaseContract {
|
|
115
|
+
_type_string: true;
|
|
116
|
+
type: "string";
|
|
117
|
+
text_wrap: "wrap" | "truncate";
|
|
118
|
+
multi_line: boolean;
|
|
119
|
+
}
|
|
120
|
+
export interface RenderTimeContract extends RenderBaseContract {
|
|
121
|
+
_type_time: true;
|
|
122
|
+
type: "time";
|
|
123
|
+
}
|
|
124
|
+
export interface RenderUserContract extends RenderBaseContract {
|
|
125
|
+
_type_user: true;
|
|
126
|
+
type: "user";
|
|
127
|
+
}
|
|
128
|
+
export interface RenderUserListContract extends RenderBaseContract {
|
|
129
|
+
_type_user_list: true;
|
|
130
|
+
type: "user-list";
|
|
131
|
+
}
|
|
132
|
+
export interface RenderWorkspaceContract extends RenderBaseContract {
|
|
133
|
+
_type_workspace: true;
|
|
134
|
+
type: "workspace";
|
|
135
|
+
}
|
|
136
|
+
/**
|
|
137
|
+
* @openapi-union-type oneOf
|
|
138
|
+
*/
|
|
139
|
+
export type SchemaItemRender = RenderAutoContract | RenderWorkspaceContract | RenderPortalContract | RenderPortalListContract | RenderUserListContract | RenderUserContract | RenderNumberContract | RenderStringContract | RenderBooleanContract | RenderLinkContract | RenderEmailContract | RenderPhoneContract | RenderDateContract | RenderCurrencyContract | RenderLabelContract | RenderFilesContract | RenderPortalFormDataContract | RenderTimeContract | RenderAssigneesContract | RenderChildTableLinkContract;
|
|
140
|
+
/**
|
|
141
|
+
* Subset of SchemaItemRender used for intent ops (createDashboardIntent, updateViewIntent).
|
|
142
|
+
* Only label and auto (lookup/relation) are used in practice; narrow union keeps MCP describe small.
|
|
143
|
+
*/
|
|
144
|
+
export type SchemaItemRenderIntentContract = RenderLabelContract | RenderAutoContract;
|
|
145
|
+
export type SchemaItemRenderEditTypeContract = "auto" | "number" | "string-single-line" | "string-multi-line" | "boolean" | "link" | "email" | "phone" | "date" | "currency" | "label" | "files" | "time" | "relation" | "lookup" | "assignee" | "child-table-link";
|
|
146
|
+
export type SchemaItemRenderTypeContract = "auto" | "workspace" | "portal" | "user-list" | "portal-list" | "portal-form-data" | "user" | "number" | "string" | "boolean" | "link" | "email" | "phone" | "date" | "currency" | "label" | "files" | "time" | "assignee" | "child-table-link" | "lookup";
|
|
147
|
+
export declare const SchemaItemRenderEditTypeContract: {
|
|
148
|
+
readonly Auto: "auto";
|
|
149
|
+
readonly Number: "number";
|
|
150
|
+
readonly StringSingleLine: "string-single-line";
|
|
151
|
+
readonly StringMultiLine: "string-multi-line";
|
|
152
|
+
readonly Boolean: "boolean";
|
|
153
|
+
readonly Link: "link";
|
|
154
|
+
readonly Email: "email";
|
|
155
|
+
readonly Phone: "phone";
|
|
156
|
+
readonly Date: "date";
|
|
157
|
+
readonly Currency: "currency";
|
|
158
|
+
readonly Label: "label";
|
|
159
|
+
readonly Files: "files";
|
|
160
|
+
readonly Time: "time";
|
|
161
|
+
readonly Relation: "relation";
|
|
162
|
+
readonly Lookup: "lookup";
|
|
163
|
+
readonly Assignee: "assignee";
|
|
164
|
+
readonly ChildTableLink: "child-table-link";
|
|
165
|
+
};
|
|
166
|
+
export declare const SchemaItemRenderTypeContract: {
|
|
167
|
+
readonly Auto: "auto";
|
|
168
|
+
readonly Workspace: "workspace";
|
|
169
|
+
readonly Portal: "portal";
|
|
170
|
+
readonly UserList: "user-list";
|
|
171
|
+
readonly PortalList: "portal-list";
|
|
172
|
+
readonly PortalFormData: "portal-form-data";
|
|
173
|
+
readonly User: "user";
|
|
174
|
+
readonly Number: "number";
|
|
175
|
+
readonly String: "string";
|
|
176
|
+
readonly Boolean: "boolean";
|
|
177
|
+
readonly Link: "link";
|
|
178
|
+
readonly Email: "email";
|
|
179
|
+
readonly Phone: "phone";
|
|
180
|
+
readonly Date: "date";
|
|
181
|
+
readonly Currency: "currency";
|
|
182
|
+
readonly Label: "label";
|
|
183
|
+
readonly Files: "files";
|
|
184
|
+
readonly Time: "time";
|
|
185
|
+
readonly Assignee: "assignee";
|
|
186
|
+
readonly ChildTableLink: "child-table-link";
|
|
187
|
+
readonly Lookup: "lookup";
|
|
188
|
+
};
|
|
@@ -0,0 +1,51 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
/**
|
|
3
|
+
* Render Schemas
|
|
4
|
+
*
|
|
5
|
+
* Generated from OpenAPI specification
|
|
6
|
+
* Source: schemas/dashboard/render.yaml
|
|
7
|
+
*/
|
|
8
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
9
|
+
exports.SchemaItemRenderTypeContract = exports.SchemaItemRenderEditTypeContract = void 0;
|
|
10
|
+
exports.SchemaItemRenderEditTypeContract = {
|
|
11
|
+
Auto: "auto",
|
|
12
|
+
Number: "number",
|
|
13
|
+
StringSingleLine: "string-single-line",
|
|
14
|
+
StringMultiLine: "string-multi-line",
|
|
15
|
+
Boolean: "boolean",
|
|
16
|
+
Link: "link",
|
|
17
|
+
Email: "email",
|
|
18
|
+
Phone: "phone",
|
|
19
|
+
Date: "date",
|
|
20
|
+
Currency: "currency",
|
|
21
|
+
Label: "label",
|
|
22
|
+
Files: "files",
|
|
23
|
+
Time: "time",
|
|
24
|
+
Relation: "relation",
|
|
25
|
+
Lookup: "lookup",
|
|
26
|
+
Assignee: "assignee",
|
|
27
|
+
ChildTableLink: "child-table-link"
|
|
28
|
+
};
|
|
29
|
+
exports.SchemaItemRenderTypeContract = {
|
|
30
|
+
Auto: "auto",
|
|
31
|
+
Workspace: "workspace",
|
|
32
|
+
Portal: "portal",
|
|
33
|
+
UserList: "user-list",
|
|
34
|
+
PortalList: "portal-list",
|
|
35
|
+
PortalFormData: "portal-form-data",
|
|
36
|
+
User: "user",
|
|
37
|
+
Number: "number",
|
|
38
|
+
String: "string",
|
|
39
|
+
Boolean: "boolean",
|
|
40
|
+
Link: "link",
|
|
41
|
+
Email: "email",
|
|
42
|
+
Phone: "phone",
|
|
43
|
+
Date: "date",
|
|
44
|
+
Currency: "currency",
|
|
45
|
+
Label: "label",
|
|
46
|
+
Files: "files",
|
|
47
|
+
Time: "time",
|
|
48
|
+
Assignee: "assignee",
|
|
49
|
+
ChildTableLink: "child-table-link",
|
|
50
|
+
Lookup: "lookup"
|
|
51
|
+
};
|
|
@@ -0,0 +1,77 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Rows Schemas
|
|
3
|
+
*
|
|
4
|
+
* Generated from OpenAPI specification
|
|
5
|
+
* Source: schemas/dashboard/rows.yaml
|
|
6
|
+
*/
|
|
7
|
+
export interface CreateDashboardRowRequestContract {
|
|
8
|
+
row_uuids: string[];
|
|
9
|
+
}
|
|
10
|
+
export interface DashboardRowContract {
|
|
11
|
+
/**
|
|
12
|
+
* Reference to dashboard global_id
|
|
13
|
+
*
|
|
14
|
+
* @format uuid
|
|
15
|
+
*/
|
|
16
|
+
dashboard_id: string;
|
|
17
|
+
/**
|
|
18
|
+
* Unique UUID identifier for the row
|
|
19
|
+
*
|
|
20
|
+
* @format uuid
|
|
21
|
+
*/
|
|
22
|
+
row_uuid: string;
|
|
23
|
+
/**
|
|
24
|
+
* Timestamp when the row was created
|
|
25
|
+
*
|
|
26
|
+
* @format date-time
|
|
27
|
+
*/
|
|
28
|
+
created_at: Date;
|
|
29
|
+
/**
|
|
30
|
+
* Timestamp when the row was last updated
|
|
31
|
+
*
|
|
32
|
+
* @format date-time
|
|
33
|
+
*/
|
|
34
|
+
updated_at: Date;
|
|
35
|
+
}
|
|
36
|
+
export interface DashboardRowResponseContract {
|
|
37
|
+
/**
|
|
38
|
+
* Whether the operation was successful
|
|
39
|
+
*/
|
|
40
|
+
success: boolean;
|
|
41
|
+
/**
|
|
42
|
+
* Response message
|
|
43
|
+
*/
|
|
44
|
+
message: string;
|
|
45
|
+
data: DashboardRowContract[];
|
|
46
|
+
}
|
|
47
|
+
export interface RowOrderItemContract {
|
|
48
|
+
/**
|
|
49
|
+
* UUID of the dashboard row
|
|
50
|
+
*
|
|
51
|
+
* @format uuid
|
|
52
|
+
*/
|
|
53
|
+
row_uuid: string;
|
|
54
|
+
/**
|
|
55
|
+
* Sort order position (1-based)
|
|
56
|
+
*
|
|
57
|
+
* @minimum 1
|
|
58
|
+
*/
|
|
59
|
+
sort_order: number;
|
|
60
|
+
}
|
|
61
|
+
/**
|
|
62
|
+
* Type of section for row ordering
|
|
63
|
+
*
|
|
64
|
+
* @enum "view", "section", "item"
|
|
65
|
+
*/
|
|
66
|
+
export type SectionTypeContract = "view" | "section" | "item";
|
|
67
|
+
export interface UpdateRowOrderRequestContract {
|
|
68
|
+
/**
|
|
69
|
+
* Array of row orders to update
|
|
70
|
+
*/
|
|
71
|
+
row_orders: RowOrderItemContract[];
|
|
72
|
+
}
|
|
73
|
+
export declare const SectionTypeContract: {
|
|
74
|
+
readonly View: "view";
|
|
75
|
+
readonly Section: "section";
|
|
76
|
+
readonly Item: "item";
|
|
77
|
+
};
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
/**
|
|
3
|
+
* Rows Schemas
|
|
4
|
+
*
|
|
5
|
+
* Generated from OpenAPI specification
|
|
6
|
+
* Source: schemas/dashboard/rows.yaml
|
|
7
|
+
*/
|
|
8
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
9
|
+
exports.SectionTypeContract = void 0;
|
|
10
|
+
exports.SectionTypeContract = {
|
|
11
|
+
View: "view",
|
|
12
|
+
Section: "section",
|
|
13
|
+
Item: "item"
|
|
14
|
+
};
|
|
@@ -0,0 +1,172 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Schema Schemas
|
|
3
|
+
*
|
|
4
|
+
* Generated from OpenAPI specification
|
|
5
|
+
* Source: schemas/dashboard/schema.yaml
|
|
6
|
+
*/
|
|
7
|
+
import type { RelationTypeContract } from "../relations/relations";
|
|
8
|
+
import type { AliasContract } from "../shared/common";
|
|
9
|
+
import type { RootEntityContract } from "../shared/enums";
|
|
10
|
+
import type { SchemaItemSourceCustomContract } from "./custom-item";
|
|
11
|
+
import type { IndexConfigContract } from "./index";
|
|
12
|
+
import type { SchemaItemRender } from "./render";
|
|
13
|
+
import type { SectionTypeContract } from "./rows";
|
|
14
|
+
export interface DashboardSchemaContract {
|
|
15
|
+
root_entity: RootEntityContract;
|
|
16
|
+
root_index_key: string;
|
|
17
|
+
items: SchemaItemContract[];
|
|
18
|
+
sections: SchemaItemsSectionContract[];
|
|
19
|
+
data_sections: SchemaItemDataSectionsContract;
|
|
20
|
+
metadata: SchemaMetadataContract;
|
|
21
|
+
/**
|
|
22
|
+
* When true, the dashboard is in readonly/view mode and data cannot be modified
|
|
23
|
+
*/
|
|
24
|
+
readonly: boolean;
|
|
25
|
+
}
|
|
26
|
+
export interface LookupRelationContract {
|
|
27
|
+
relation_id: string;
|
|
28
|
+
dashboard_id: string;
|
|
29
|
+
view_id: string;
|
|
30
|
+
item_key: string;
|
|
31
|
+
reverse: boolean;
|
|
32
|
+
relation_type: RelationTypeContract;
|
|
33
|
+
}
|
|
34
|
+
/**
|
|
35
|
+
* @openapi-union-type oneOf
|
|
36
|
+
*/
|
|
37
|
+
export type ResponseMap = ResponseMapValueContract | ResponseMapCountContract | ResponseMapObjectContract;
|
|
38
|
+
export interface ResponseMapCountContract {
|
|
39
|
+
_type_count: true;
|
|
40
|
+
type: "count";
|
|
41
|
+
}
|
|
42
|
+
export interface ResponseMapItemContract {
|
|
43
|
+
key: string;
|
|
44
|
+
path: string[];
|
|
45
|
+
}
|
|
46
|
+
export interface ResponseMapObjectContract {
|
|
47
|
+
_type_object: true;
|
|
48
|
+
type: "object";
|
|
49
|
+
is_array: boolean;
|
|
50
|
+
items: ResponseMapItemContract[];
|
|
51
|
+
}
|
|
52
|
+
export interface ResponseMapValueContract {
|
|
53
|
+
_type_value: true;
|
|
54
|
+
type: string;
|
|
55
|
+
type_value?: true;
|
|
56
|
+
is_array: boolean;
|
|
57
|
+
path?: string[];
|
|
58
|
+
}
|
|
59
|
+
export interface SchemaItemContract {
|
|
60
|
+
key: string;
|
|
61
|
+
alias?: AliasContract;
|
|
62
|
+
name: string;
|
|
63
|
+
description: string;
|
|
64
|
+
render: SchemaItemRender;
|
|
65
|
+
source: SchemaItemSource;
|
|
66
|
+
transform?: SchemaItemTransformContract;
|
|
67
|
+
/**
|
|
68
|
+
* JSON Schema for the item, see https://json-schema.org/
|
|
69
|
+
*/
|
|
70
|
+
json_schema: object;
|
|
71
|
+
/**
|
|
72
|
+
* Optional group ids for this item
|
|
73
|
+
*/
|
|
74
|
+
group_ids: string[];
|
|
75
|
+
section_id?: string;
|
|
76
|
+
hidden: boolean;
|
|
77
|
+
readonly: boolean;
|
|
78
|
+
unique: boolean;
|
|
79
|
+
required: boolean;
|
|
80
|
+
async?: boolean;
|
|
81
|
+
show_mode: {
|
|
82
|
+
dashboard: boolean;
|
|
83
|
+
detailed: boolean;
|
|
84
|
+
};
|
|
85
|
+
index?: IndexConfigContract;
|
|
86
|
+
metadata: SchemaItemMetadataContract;
|
|
87
|
+
}
|
|
88
|
+
export interface SchemaItemDataSectionsContract {
|
|
89
|
+
section_type: SectionTypeContract;
|
|
90
|
+
section_key: string;
|
|
91
|
+
}
|
|
92
|
+
export interface SchemaItemGroupContract {
|
|
93
|
+
key: string;
|
|
94
|
+
name: string;
|
|
95
|
+
description?: string;
|
|
96
|
+
root_entity?: RootEntityContract;
|
|
97
|
+
}
|
|
98
|
+
export interface SchemaItemMetadataContract {
|
|
99
|
+
/**
|
|
100
|
+
* Width of the item in pixels
|
|
101
|
+
*/
|
|
102
|
+
width?: number;
|
|
103
|
+
}
|
|
104
|
+
/**
|
|
105
|
+
* @openapi-union-type oneOf
|
|
106
|
+
*/
|
|
107
|
+
export type SchemaItemSource = SchemaItemSourceRootContract | SchemaItemSourceAssocContract | SchemaItemSourceFuncContract | SchemaItemSourceCustomContract | SchemaItemSourceLookupContract | SchemaItemSourceNoneContract;
|
|
108
|
+
/**
|
|
109
|
+
* Subset of SchemaItemSource for intent ops (createDashboardIntent, updateViewIntent).
|
|
110
|
+
* Only lookup (relation) is used in practice; narrow type keeps MCP describe small.
|
|
111
|
+
*/
|
|
112
|
+
export type SchemaItemSourceIntentContract = SchemaItemSourceLookupContract;
|
|
113
|
+
export interface SchemaItemSourceAssocContract {
|
|
114
|
+
_type_assoc: true;
|
|
115
|
+
type: "assoc";
|
|
116
|
+
root_key: string;
|
|
117
|
+
assoc_name: string;
|
|
118
|
+
assoc_args?: object;
|
|
119
|
+
response_map: ResponseMap;
|
|
120
|
+
}
|
|
121
|
+
export interface SchemaItemSourceFuncContract {
|
|
122
|
+
_type_func: true;
|
|
123
|
+
type: "func";
|
|
124
|
+
root_key: string;
|
|
125
|
+
func_name: string;
|
|
126
|
+
func_args?: string[];
|
|
127
|
+
response_map: ResponseMap;
|
|
128
|
+
}
|
|
129
|
+
export interface SchemaItemSourceLookupContract {
|
|
130
|
+
_type_lookup: true;
|
|
131
|
+
type: "lookup";
|
|
132
|
+
selectable: boolean;
|
|
133
|
+
relations: LookupRelationContract[];
|
|
134
|
+
}
|
|
135
|
+
export interface SchemaItemSourceNoneContract {
|
|
136
|
+
_type_none: true;
|
|
137
|
+
type: "none";
|
|
138
|
+
}
|
|
139
|
+
export interface SchemaItemSourceRootContract {
|
|
140
|
+
_type_root: true;
|
|
141
|
+
type: "root";
|
|
142
|
+
field: string;
|
|
143
|
+
response_map?: ResponseMap;
|
|
144
|
+
}
|
|
145
|
+
export type SchemaItemSourceTypeContract = "root" | "assoc" | "func" | "custom" | "lookup" | "none";
|
|
146
|
+
export interface SchemaItemsSectionContract {
|
|
147
|
+
id: string;
|
|
148
|
+
title: string;
|
|
149
|
+
description: string;
|
|
150
|
+
}
|
|
151
|
+
export interface SchemaItemTransformContract {
|
|
152
|
+
func: string;
|
|
153
|
+
}
|
|
154
|
+
export interface SchemaMetadataContract {
|
|
155
|
+
version: string;
|
|
156
|
+
created_at: string;
|
|
157
|
+
updated_at: string;
|
|
158
|
+
migrations: SchemaMetadataUpdateContract[];
|
|
159
|
+
}
|
|
160
|
+
export interface SchemaMetadataUpdateContract {
|
|
161
|
+
from_version: string;
|
|
162
|
+
to_version: string;
|
|
163
|
+
updated_at: string;
|
|
164
|
+
}
|
|
165
|
+
export declare const SchemaItemSourceTypeContract: {
|
|
166
|
+
readonly Root: "root";
|
|
167
|
+
readonly Assoc: "assoc";
|
|
168
|
+
readonly Func: "func";
|
|
169
|
+
readonly Custom: "custom";
|
|
170
|
+
readonly Lookup: "lookup";
|
|
171
|
+
readonly None: "none";
|
|
172
|
+
};
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
/**
|
|
3
|
+
* Schema Schemas
|
|
4
|
+
*
|
|
5
|
+
* Generated from OpenAPI specification
|
|
6
|
+
* Source: schemas/dashboard/schema.yaml
|
|
7
|
+
*/
|
|
8
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
9
|
+
exports.SchemaItemSourceTypeContract = void 0;
|
|
10
|
+
exports.SchemaItemSourceTypeContract = {
|
|
11
|
+
Root: "root",
|
|
12
|
+
Assoc: "assoc",
|
|
13
|
+
Func: "func",
|
|
14
|
+
Custom: "custom",
|
|
15
|
+
Lookup: "lookup",
|
|
16
|
+
None: "none"
|
|
17
|
+
};
|
|
@@ -0,0 +1,187 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Values Schemas
|
|
3
|
+
*
|
|
4
|
+
* Generated from OpenAPI specification
|
|
5
|
+
* Source: schemas/dashboard/values.yaml
|
|
6
|
+
*/
|
|
7
|
+
import type { RelationTypeContract } from "../relations/relations";
|
|
8
|
+
import type { StandardApiResponseContract } from "../shared/common";
|
|
9
|
+
export interface BatchDashboardValueResponseContract extends StandardApiResponseContract {
|
|
10
|
+
/**
|
|
11
|
+
* @nullable true
|
|
12
|
+
*/
|
|
13
|
+
data?: DashboardValue[];
|
|
14
|
+
}
|
|
15
|
+
export interface BatchUpdateDashboardDataRequestContract {
|
|
16
|
+
/**
|
|
17
|
+
* Array of row update requests, each containing multiple field values for a single row
|
|
18
|
+
*/
|
|
19
|
+
rows: BatchUpdateRowDataRequestContract[];
|
|
20
|
+
}
|
|
21
|
+
export interface BatchUpdateRowDataRequestContract {
|
|
22
|
+
/**
|
|
23
|
+
* Root index value (row identifier). Required if create_new_row is false. If create_new_row is true and this is omitted, a new UUID will be generated on the backend.
|
|
24
|
+
*
|
|
25
|
+
* @minLength 1
|
|
26
|
+
* @maxLength 36
|
|
27
|
+
*/
|
|
28
|
+
root_index_value?: string;
|
|
29
|
+
/**
|
|
30
|
+
* If true, creates a new row. root_index_value is optional in this case and will be auto-generated if not provided.
|
|
31
|
+
*
|
|
32
|
+
* @default false
|
|
33
|
+
*/
|
|
34
|
+
create_new_row?: boolean;
|
|
35
|
+
/**
|
|
36
|
+
* Array of item_key and value pairs
|
|
37
|
+
*/
|
|
38
|
+
values: {
|
|
39
|
+
/**
|
|
40
|
+
* The item key to identify the value
|
|
41
|
+
*
|
|
42
|
+
* @minLength 1
|
|
43
|
+
* @maxLength 36
|
|
44
|
+
*/
|
|
45
|
+
item_key: string;
|
|
46
|
+
/**
|
|
47
|
+
* The value to save (string, number, boolean, JSON object, array, or null to delete). Null values are allowed and will delete the value for the item_key.
|
|
48
|
+
*
|
|
49
|
+
* @openapi-union-type anyOf
|
|
50
|
+
*/
|
|
51
|
+
value: object | unknown[] | string | number | boolean;
|
|
52
|
+
}[];
|
|
53
|
+
}
|
|
54
|
+
/**
|
|
55
|
+
* @openapi-union-type oneOf
|
|
56
|
+
*/
|
|
57
|
+
export type DashboardValue = DashboardValueStringContract | DashboardValueNumberContract | DashboardValueBooleanContract | DashboardValueDateContract | DashboardValueJsonContract;
|
|
58
|
+
export interface DashboardValueBaseContract {
|
|
59
|
+
/**
|
|
60
|
+
* Unique identifier for the dashboard value
|
|
61
|
+
*
|
|
62
|
+
* @format uuid
|
|
63
|
+
*/
|
|
64
|
+
global_id: string;
|
|
65
|
+
/**
|
|
66
|
+
* ID of the dashboard this value belongs to
|
|
67
|
+
*
|
|
68
|
+
* @format uuid
|
|
69
|
+
*/
|
|
70
|
+
dashboard_id: string;
|
|
71
|
+
/**
|
|
72
|
+
* The root index key
|
|
73
|
+
*/
|
|
74
|
+
root_index_key: string;
|
|
75
|
+
/**
|
|
76
|
+
* The root index value
|
|
77
|
+
*/
|
|
78
|
+
root_index_value: string;
|
|
79
|
+
/**
|
|
80
|
+
* The item key
|
|
81
|
+
*/
|
|
82
|
+
item_key: string;
|
|
83
|
+
/**
|
|
84
|
+
* Type of the stored value
|
|
85
|
+
*
|
|
86
|
+
* @enum "string", "number", "boolean", "date", "json"
|
|
87
|
+
*/
|
|
88
|
+
value_type: "string" | "number" | "boolean" | "date" | "json";
|
|
89
|
+
/**
|
|
90
|
+
* @format date-time
|
|
91
|
+
*/
|
|
92
|
+
created_at: Date;
|
|
93
|
+
/**
|
|
94
|
+
* @format date-time
|
|
95
|
+
*/
|
|
96
|
+
updated_at: Date;
|
|
97
|
+
/**
|
|
98
|
+
* @format date-time
|
|
99
|
+
* @nullable true
|
|
100
|
+
*/
|
|
101
|
+
deleted_at?: Date | null;
|
|
102
|
+
}
|
|
103
|
+
export interface DashboardValueBooleanContract extends DashboardValueBaseContract {
|
|
104
|
+
value?: boolean;
|
|
105
|
+
_type_boolean: true;
|
|
106
|
+
}
|
|
107
|
+
export interface DashboardValueDateContract extends DashboardValueBaseContract {
|
|
108
|
+
value?: string;
|
|
109
|
+
_type_date: true;
|
|
110
|
+
}
|
|
111
|
+
/**
|
|
112
|
+
* @openapi-union-type oneOf
|
|
113
|
+
*/
|
|
114
|
+
export type DashboardValueExtended = DashboardValueBaseContract | DashboardValueLookupContract;
|
|
115
|
+
export interface DashboardValueJsonContract extends DashboardValueBaseContract {
|
|
116
|
+
value?: object;
|
|
117
|
+
_type_json: true;
|
|
118
|
+
}
|
|
119
|
+
export interface DashboardValueLookupContract {
|
|
120
|
+
value: DashboardValue;
|
|
121
|
+
occurrences: number;
|
|
122
|
+
relation: LookupRelationValueContract;
|
|
123
|
+
error_code: DashboardValueLookupItemErrorCodeContract;
|
|
124
|
+
}
|
|
125
|
+
export interface DashboardValueLookupItemErrorCodeContract {
|
|
126
|
+
error_code: "SOURCE_TABLE_NOT_FOUND" | "SOURCE_VIEW_NOT_FOUND" | "SOURCE_COLUMN_NOT_FOUND" | "SOURCE_ROW_NOT_FOUND";
|
|
127
|
+
/**
|
|
128
|
+
* @nullable true
|
|
129
|
+
*/
|
|
130
|
+
error_message?: string | null;
|
|
131
|
+
}
|
|
132
|
+
export interface DashboardValueNumberContract extends DashboardValueBaseContract {
|
|
133
|
+
value?: number;
|
|
134
|
+
_type_number: true;
|
|
135
|
+
}
|
|
136
|
+
export interface DashboardValueResponseContract extends StandardApiResponseContract {
|
|
137
|
+
/**
|
|
138
|
+
* @nullable true
|
|
139
|
+
*/
|
|
140
|
+
data?: DashboardValue;
|
|
141
|
+
}
|
|
142
|
+
export interface DashboardValueStringContract extends DashboardValueBaseContract {
|
|
143
|
+
value?: string;
|
|
144
|
+
_type_string: true;
|
|
145
|
+
}
|
|
146
|
+
export interface LookupRelationValueContract {
|
|
147
|
+
relation_id: string;
|
|
148
|
+
dashboard_id: string;
|
|
149
|
+
view_id: string;
|
|
150
|
+
item_key: string;
|
|
151
|
+
reverse: boolean;
|
|
152
|
+
/**
|
|
153
|
+
* Type of relationship between dashboards
|
|
154
|
+
*/
|
|
155
|
+
relation_type: RelationTypeContract;
|
|
156
|
+
/**
|
|
157
|
+
* Source index value
|
|
158
|
+
*/
|
|
159
|
+
source_index_value: string;
|
|
160
|
+
}
|
|
161
|
+
export interface UpdateDashboardDataRequestContract {
|
|
162
|
+
/**
|
|
163
|
+
* The root index key to identify the value
|
|
164
|
+
*
|
|
165
|
+
* @minLength 1
|
|
166
|
+
* @maxLength 36
|
|
167
|
+
*/
|
|
168
|
+
root_index_key: string;
|
|
169
|
+
/**
|
|
170
|
+
* The root index value to identify the value
|
|
171
|
+
*
|
|
172
|
+
* @minLength 1
|
|
173
|
+
* @maxLength 36
|
|
174
|
+
*/
|
|
175
|
+
root_index_value: string;
|
|
176
|
+
/**
|
|
177
|
+
* The item key to identify the value
|
|
178
|
+
*
|
|
179
|
+
* @minLength 1
|
|
180
|
+
* @maxLength 36
|
|
181
|
+
*/
|
|
182
|
+
item_key: string;
|
|
183
|
+
/**
|
|
184
|
+
* The value to save (string, number, boolean, or JSON object)
|
|
185
|
+
*/
|
|
186
|
+
data: object;
|
|
187
|
+
}
|