quickbase-js 1.1.0-beta.3 → 1.1.0-beta.4
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/CHANGELOG.md +23 -0
- package/README.md +61 -5
- package/dist/quickbase.d.ts +1108 -349
- package/dist/quickbase.js +828 -263
- package/dist/quickbase.js.map +1 -1
- package/examples/react.js +12 -12
- package/examples/vanillajs.html +12 -12
- package/log-gen.yaml +4622 -759
- package/package.json +12 -14
- package/playwright-results.txt/.last-run.json +4 -0
- package/playwright.config.ts +1 -1
- package/src/code-generation/definitions/apps.ts +274 -0
- package/src/code-generation/definitions/auth.ts +10 -0
- package/src/code-generation/definitions/fields.ts +751 -0
- package/src/code-generation/definitions/index.ts +18 -0
- package/src/code-generation/definitions/records.ts +269 -0
- package/src/code-generation/definitions/relationships.ts +90 -0
- package/src/code-generation/definitions/reports.ts +10 -0
- package/src/code-generation/definitions/tables.ts +112 -0
- package/src/code-generation/fix-spec-main.ts +2 -2
- package/src/code-generation/output/quickbase-fixed.json +3244 -4586
- package/src/code-generation/paths/apps.ts +100 -0
- package/src/code-generation/paths/auth.ts +25 -0
- package/src/code-generation/paths/fields.ts +207 -0
- package/src/code-generation/paths/index.ts +17 -0
- package/src/code-generation/paths/records.ts +68 -0
- package/src/code-generation/paths/relationships.ts +32 -0
- package/src/code-generation/paths/reports.ts +34 -0
- package/src/code-generation/paths/tables.ts +162 -0
- package/src/generated-unified/QuickbaseClient.ts +7 -6
- package/src/log-gen.ts +8 -6
- package/tests/vitest/qb/fields/createField.test.ts +78 -0
- package/tests/vitest/qb/fields/deleteFields.test.ts +89 -0
- package/tests/vitest/qb/fields/getField.test.ts +85 -0
- package/tests/vitest/qb/fields/getFieldUsage.test.ts +174 -0
- package/tests/vitest/qb/fields/getFieldsUsage.test.ts +77 -0
- package/tests/vitest/qb/index.ts +25 -1
- package/tests/vitest/unit/fields/createField.test.ts +391 -0
- package/tests/vitest/unit/fields/deleteFields.test.ts +141 -0
- package/tests/vitest/unit/fields/getField.test.ts +189 -0
- package/tests/vitest/unit/fields/getFieldUsage.test.ts +147 -0
- package/tests/vitest/unit/fields/getFieldsUsage.test.ts +160 -0
- package/tests/vitest/unit/index.ts +30 -1
- package/src/code-generation/fix-spec-definitions.ts +0 -809
- package/src/code-generation/fix-spec-paths.ts +0 -439
- package/test-artifacts/test-results.json +0 -829
|
@@ -1,809 +0,0 @@
|
|
|
1
|
-
// src/code-generation/fix-spec-definitions.ts
|
|
2
|
-
export const definitions = {
|
|
3
|
-
App: {
|
|
4
|
-
type: "object",
|
|
5
|
-
required: ["id", "name"],
|
|
6
|
-
properties: {
|
|
7
|
-
id: { type: "string" },
|
|
8
|
-
name: { type: "string" },
|
|
9
|
-
created: { type: "string", format: "date-time" },
|
|
10
|
-
updated: { type: "string", format: "date-time" },
|
|
11
|
-
description: { type: "string" },
|
|
12
|
-
timeZone: { type: "string" },
|
|
13
|
-
dateFormat: { type: "string" },
|
|
14
|
-
hasEveryoneOnTheInternet: { type: "boolean" },
|
|
15
|
-
memoryInfo: { $ref: "#/definitions/AppMemoryInfo" },
|
|
16
|
-
securityProperties: { $ref: "#/definitions/AppSecurityProperties" },
|
|
17
|
-
},
|
|
18
|
-
},
|
|
19
|
-
AppMemoryInfo: {
|
|
20
|
-
type: "object",
|
|
21
|
-
properties: {
|
|
22
|
-
estMemory: { type: "number" },
|
|
23
|
-
estMemoryInclDependentApps: { type: "number" },
|
|
24
|
-
},
|
|
25
|
-
},
|
|
26
|
-
AppSecurityProperties: {
|
|
27
|
-
type: "object",
|
|
28
|
-
properties: {
|
|
29
|
-
allowClone: { type: "boolean" },
|
|
30
|
-
allowExport: { type: "boolean" },
|
|
31
|
-
enableAppTokens: { type: "boolean" },
|
|
32
|
-
hideFromPublic: { type: "boolean" },
|
|
33
|
-
mustBeRealmApproved: { type: "boolean" },
|
|
34
|
-
useIPFilter: { type: "boolean" },
|
|
35
|
-
},
|
|
36
|
-
},
|
|
37
|
-
CreateAppRequest: {
|
|
38
|
-
type: "object",
|
|
39
|
-
required: ["name"],
|
|
40
|
-
properties: {
|
|
41
|
-
name: {
|
|
42
|
-
type: "string",
|
|
43
|
-
description:
|
|
44
|
-
"The app name. Multiple apps with the same name are allowed in the same realm.",
|
|
45
|
-
},
|
|
46
|
-
assignToken: {
|
|
47
|
-
type: "boolean",
|
|
48
|
-
description:
|
|
49
|
-
"Set to true to assign the app to the user token used to create it. Default is false.",
|
|
50
|
-
},
|
|
51
|
-
description: {
|
|
52
|
-
type: "string",
|
|
53
|
-
description:
|
|
54
|
-
"The description for the app. Defaults to blank if omitted.",
|
|
55
|
-
},
|
|
56
|
-
securityProperties: {
|
|
57
|
-
$ref: "#/definitions/AppSecurityProperties",
|
|
58
|
-
description: "Application security properties.",
|
|
59
|
-
},
|
|
60
|
-
variables: {
|
|
61
|
-
type: "array",
|
|
62
|
-
items: {
|
|
63
|
-
type: "object",
|
|
64
|
-
properties: {
|
|
65
|
-
name: { type: "string" },
|
|
66
|
-
value: { type: "string" },
|
|
67
|
-
},
|
|
68
|
-
required: ["name", "value"],
|
|
69
|
-
},
|
|
70
|
-
description:
|
|
71
|
-
"App variables (max 10, optional). See About Application Variables.",
|
|
72
|
-
},
|
|
73
|
-
},
|
|
74
|
-
},
|
|
75
|
-
CreateApp200Response: {
|
|
76
|
-
type: "object",
|
|
77
|
-
properties: {
|
|
78
|
-
id: {
|
|
79
|
-
type: "string",
|
|
80
|
-
description: "The unique identifier for this application.",
|
|
81
|
-
},
|
|
82
|
-
name: { type: "string", description: "The app name." },
|
|
83
|
-
description: {
|
|
84
|
-
type: "string",
|
|
85
|
-
description: "The description for the app.",
|
|
86
|
-
},
|
|
87
|
-
created: {
|
|
88
|
-
type: "string",
|
|
89
|
-
format: "date-time",
|
|
90
|
-
description: "The time and date the app was created (ISO 8601, UTC).",
|
|
91
|
-
},
|
|
92
|
-
updated: {
|
|
93
|
-
type: "string",
|
|
94
|
-
format: "date-time",
|
|
95
|
-
description:
|
|
96
|
-
"The time and date the app was last updated (ISO 8601, UTC).",
|
|
97
|
-
},
|
|
98
|
-
dateFormat: {
|
|
99
|
-
type: "string",
|
|
100
|
-
description:
|
|
101
|
-
"The format used for displaying dates in the app (e.g., MM-DD-YYYY).",
|
|
102
|
-
},
|
|
103
|
-
timeZone: {
|
|
104
|
-
type: "string",
|
|
105
|
-
description:
|
|
106
|
-
"The time zone used for displaying time values (e.g., (UTC-08:00) Pacific Time).",
|
|
107
|
-
},
|
|
108
|
-
memoryInfo: {
|
|
109
|
-
$ref: "#/definitions/AppMemoryInfo",
|
|
110
|
-
description: "Application memory information.",
|
|
111
|
-
},
|
|
112
|
-
hasEveryoneOnTheInternet: {
|
|
113
|
-
type: "boolean",
|
|
114
|
-
description:
|
|
115
|
-
"Indicates if the app includes Everyone On The Internet access.",
|
|
116
|
-
},
|
|
117
|
-
variables: {
|
|
118
|
-
type: "array",
|
|
119
|
-
items: {
|
|
120
|
-
type: "object",
|
|
121
|
-
properties: {
|
|
122
|
-
name: { type: "string" },
|
|
123
|
-
value: { type: "string" },
|
|
124
|
-
},
|
|
125
|
-
required: ["name", "value"],
|
|
126
|
-
},
|
|
127
|
-
description: "The app variables.",
|
|
128
|
-
},
|
|
129
|
-
dataClassification: {
|
|
130
|
-
type: "string",
|
|
131
|
-
description:
|
|
132
|
-
"The Data Classification label assigned to the app (optional, may be 'None').",
|
|
133
|
-
},
|
|
134
|
-
securityProperties: {
|
|
135
|
-
$ref: "#/definitions/AppSecurityProperties",
|
|
136
|
-
description: "Security properties of the application.",
|
|
137
|
-
},
|
|
138
|
-
},
|
|
139
|
-
required: ["id", "name"],
|
|
140
|
-
},
|
|
141
|
-
Field: {
|
|
142
|
-
type: "object",
|
|
143
|
-
required: ["id", "label", "fieldType"],
|
|
144
|
-
properties: {
|
|
145
|
-
id: { type: "integer" },
|
|
146
|
-
label: { type: "string" },
|
|
147
|
-
fieldType: { type: "string" },
|
|
148
|
-
noWrap: { type: "boolean" },
|
|
149
|
-
bold: { type: "boolean" },
|
|
150
|
-
required: { type: "boolean" },
|
|
151
|
-
appearsByDefault: { type: "boolean" },
|
|
152
|
-
findEnabled: { type: "boolean" },
|
|
153
|
-
unique: { type: "boolean" },
|
|
154
|
-
doesDataCopy: { type: "boolean" },
|
|
155
|
-
fieldHelp: { type: "string" },
|
|
156
|
-
audited: { type: "boolean" },
|
|
157
|
-
properties: { $ref: "#/definitions/FieldProperties" },
|
|
158
|
-
permissions: {
|
|
159
|
-
type: "array",
|
|
160
|
-
items: { $ref: "#/definitions/FieldPermissionsInner" },
|
|
161
|
-
},
|
|
162
|
-
},
|
|
163
|
-
},
|
|
164
|
-
FieldProperties: {
|
|
165
|
-
type: "object",
|
|
166
|
-
properties: {
|
|
167
|
-
primaryKey: { type: "boolean" },
|
|
168
|
-
foreignKey: { type: "boolean" },
|
|
169
|
-
numLines: { type: "integer" },
|
|
170
|
-
maxLength: { type: "integer" },
|
|
171
|
-
appendOnly: { type: "boolean" },
|
|
172
|
-
allowHTML: { type: "boolean" },
|
|
173
|
-
allowMentions: { type: "boolean" },
|
|
174
|
-
sortAsGiven: { type: "boolean" },
|
|
175
|
-
carryChoices: { type: "boolean" },
|
|
176
|
-
allowNewChoices: { type: "boolean" },
|
|
177
|
-
formula: { type: "string" },
|
|
178
|
-
defaultValue: { type: "string" },
|
|
179
|
-
},
|
|
180
|
-
},
|
|
181
|
-
FieldPermissionsInner: {
|
|
182
|
-
type: "object",
|
|
183
|
-
properties: {
|
|
184
|
-
permissionType: { type: "string" },
|
|
185
|
-
role: { type: "string" },
|
|
186
|
-
roleId: { type: "integer" },
|
|
187
|
-
},
|
|
188
|
-
},
|
|
189
|
-
Table: {
|
|
190
|
-
type: "object",
|
|
191
|
-
required: ["id", "name"],
|
|
192
|
-
properties: {
|
|
193
|
-
id: {
|
|
194
|
-
type: "string",
|
|
195
|
-
description: "The unique identifier (dbid) of the table.",
|
|
196
|
-
},
|
|
197
|
-
name: { type: "string", description: "The name of the table." },
|
|
198
|
-
alias: {
|
|
199
|
-
type: "string",
|
|
200
|
-
description: "The automatically-created table alias for the table.",
|
|
201
|
-
},
|
|
202
|
-
description: {
|
|
203
|
-
type: "string",
|
|
204
|
-
description:
|
|
205
|
-
"The description of the table, as configured by an application administrator.",
|
|
206
|
-
},
|
|
207
|
-
created: {
|
|
208
|
-
type: "string",
|
|
209
|
-
format: "date-time",
|
|
210
|
-
description:
|
|
211
|
-
"The time and date when the table was created, in ISO 8601 format (UTC).",
|
|
212
|
-
},
|
|
213
|
-
updated: {
|
|
214
|
-
type: "string",
|
|
215
|
-
format: "date-time",
|
|
216
|
-
description:
|
|
217
|
-
"The time and date when the table schema or data was last updated, in ISO 8601 format (UTC).",
|
|
218
|
-
},
|
|
219
|
-
nextRecordId: {
|
|
220
|
-
type: "integer",
|
|
221
|
-
description:
|
|
222
|
-
"The incremental Record ID that will be used when the next record is created.",
|
|
223
|
-
},
|
|
224
|
-
nextFieldId: {
|
|
225
|
-
type: "integer",
|
|
226
|
-
description:
|
|
227
|
-
"The incremental Field ID that will be used when the next field is created.",
|
|
228
|
-
},
|
|
229
|
-
defaultSortFieldId: {
|
|
230
|
-
type: "integer",
|
|
231
|
-
description:
|
|
232
|
-
"The id of the field that is configured for default sorting.",
|
|
233
|
-
},
|
|
234
|
-
defaultSortOrder: {
|
|
235
|
-
type: "string",
|
|
236
|
-
enum: ["ASC", "DESC"],
|
|
237
|
-
description:
|
|
238
|
-
"The default sort order for the table, either ascending (ASC) or descending (DESC).",
|
|
239
|
-
},
|
|
240
|
-
keyFieldId: {
|
|
241
|
-
type: "integer",
|
|
242
|
-
description:
|
|
243
|
-
"The id of the field that is configured to be the key on this table, usually the Quickbase Record ID.",
|
|
244
|
-
},
|
|
245
|
-
singleRecordName: {
|
|
246
|
-
type: "string",
|
|
247
|
-
description: "The builder-configured singular noun of the table.",
|
|
248
|
-
},
|
|
249
|
-
pluralRecordName: {
|
|
250
|
-
type: "string",
|
|
251
|
-
description: "The builder-configured plural noun of the table.",
|
|
252
|
-
},
|
|
253
|
-
sizeLimit: {
|
|
254
|
-
type: "string",
|
|
255
|
-
description: "The size limit for the table (e.g., '150 MB').",
|
|
256
|
-
},
|
|
257
|
-
spaceUsed: {
|
|
258
|
-
type: "string",
|
|
259
|
-
description:
|
|
260
|
-
"The amount of space currently being used by the table (e.g., '17 MB').",
|
|
261
|
-
},
|
|
262
|
-
spaceRemaining: {
|
|
263
|
-
type: "string",
|
|
264
|
-
description:
|
|
265
|
-
"The amount of space remaining for use by the table (e.g., '133 MB').",
|
|
266
|
-
},
|
|
267
|
-
},
|
|
268
|
-
},
|
|
269
|
-
UpdateTableRequest: {
|
|
270
|
-
type: "object",
|
|
271
|
-
properties: {
|
|
272
|
-
name: { type: "string", description: "The new name for the table." },
|
|
273
|
-
singleRecordName: {
|
|
274
|
-
type: "string",
|
|
275
|
-
description:
|
|
276
|
-
"The new singular noun for records in the table. Defaults to 'Record' if not provided.",
|
|
277
|
-
},
|
|
278
|
-
pluralRecordName: {
|
|
279
|
-
type: "string",
|
|
280
|
-
description:
|
|
281
|
-
"The new plural noun for records in the table. Defaults to 'Records' if not provided.",
|
|
282
|
-
},
|
|
283
|
-
description: {
|
|
284
|
-
type: "string",
|
|
285
|
-
description:
|
|
286
|
-
"The new description for the table. Defaults to blank if not provided.",
|
|
287
|
-
},
|
|
288
|
-
},
|
|
289
|
-
description:
|
|
290
|
-
"Request body for updating table properties. At least one property must be provided.",
|
|
291
|
-
},
|
|
292
|
-
DeleteTableResponse: {
|
|
293
|
-
type: "object",
|
|
294
|
-
properties: {
|
|
295
|
-
deletedTableId: { type: "string", description: "The deleted table id." },
|
|
296
|
-
},
|
|
297
|
-
},
|
|
298
|
-
Record: {
|
|
299
|
-
type: "object",
|
|
300
|
-
properties: {
|
|
301
|
-
_dummy: {
|
|
302
|
-
type: "string",
|
|
303
|
-
description: "Unused dummy property to force model generation.",
|
|
304
|
-
nullable: true,
|
|
305
|
-
},
|
|
306
|
-
},
|
|
307
|
-
additionalProperties: {
|
|
308
|
-
type: "object",
|
|
309
|
-
properties: {
|
|
310
|
-
value: {
|
|
311
|
-
anyOf: [
|
|
312
|
-
{ type: "string" },
|
|
313
|
-
{ type: "number" },
|
|
314
|
-
{ type: "boolean" },
|
|
315
|
-
{ type: "object" },
|
|
316
|
-
{ type: "array" },
|
|
317
|
-
{ type: "null" },
|
|
318
|
-
],
|
|
319
|
-
description: "The value of the field.",
|
|
320
|
-
},
|
|
321
|
-
},
|
|
322
|
-
required: ["value"],
|
|
323
|
-
description: "The value object for a field ID key.",
|
|
324
|
-
},
|
|
325
|
-
description:
|
|
326
|
-
"A record with field ID keys (e.g., '6') and value objects (e.g., { value: 'data' }).",
|
|
327
|
-
},
|
|
328
|
-
UpsertRequest: {
|
|
329
|
-
type: "object",
|
|
330
|
-
required: ["to"],
|
|
331
|
-
properties: {
|
|
332
|
-
to: { type: "string", description: "The table identifier (dbid)." },
|
|
333
|
-
data: {
|
|
334
|
-
type: "array",
|
|
335
|
-
items: { $ref: "#/definitions/Record" },
|
|
336
|
-
description: "Array of records to upsert.",
|
|
337
|
-
},
|
|
338
|
-
mergeFieldId: {
|
|
339
|
-
type: "integer",
|
|
340
|
-
description: "The field ID to merge on (optional).",
|
|
341
|
-
},
|
|
342
|
-
fieldsToReturn: {
|
|
343
|
-
type: "array",
|
|
344
|
-
items: { type: "integer" },
|
|
345
|
-
description: "Field IDs to return in the response (optional).",
|
|
346
|
-
},
|
|
347
|
-
},
|
|
348
|
-
},
|
|
349
|
-
Upsert200Response: {
|
|
350
|
-
type: "object",
|
|
351
|
-
properties: {
|
|
352
|
-
data: {
|
|
353
|
-
type: "array",
|
|
354
|
-
items: {
|
|
355
|
-
type: "object",
|
|
356
|
-
additionalProperties: {
|
|
357
|
-
type: "object",
|
|
358
|
-
properties: {
|
|
359
|
-
value: {
|
|
360
|
-
anyOf: [
|
|
361
|
-
{ type: "string" },
|
|
362
|
-
{ type: "number" },
|
|
363
|
-
{ type: "boolean" },
|
|
364
|
-
{ type: "object" },
|
|
365
|
-
{ type: "array" },
|
|
366
|
-
{ type: "null" },
|
|
367
|
-
],
|
|
368
|
-
description: "The value of the field.",
|
|
369
|
-
},
|
|
370
|
-
},
|
|
371
|
-
required: ["value"],
|
|
372
|
-
},
|
|
373
|
-
},
|
|
374
|
-
description: "Array of upserted records with field IDs and values.",
|
|
375
|
-
},
|
|
376
|
-
metadata: {
|
|
377
|
-
type: "object",
|
|
378
|
-
properties: {
|
|
379
|
-
createdRecordIds: {
|
|
380
|
-
type: "array",
|
|
381
|
-
items: { type: "integer" },
|
|
382
|
-
description: "IDs of newly created records.",
|
|
383
|
-
},
|
|
384
|
-
updatedRecordIds: {
|
|
385
|
-
type: "array",
|
|
386
|
-
items: { type: "integer" },
|
|
387
|
-
description: "IDs of updated records.",
|
|
388
|
-
},
|
|
389
|
-
unchangedRecordIds: {
|
|
390
|
-
type: "array",
|
|
391
|
-
items: { type: "integer" },
|
|
392
|
-
description: "IDs of unchanged records.",
|
|
393
|
-
},
|
|
394
|
-
totalNumberOfRecordsProcessed: {
|
|
395
|
-
type: "integer",
|
|
396
|
-
description: "Total records processed.",
|
|
397
|
-
},
|
|
398
|
-
},
|
|
399
|
-
required: ["totalNumberOfRecordsProcessed"],
|
|
400
|
-
},
|
|
401
|
-
},
|
|
402
|
-
},
|
|
403
|
-
Upsert207Response: {
|
|
404
|
-
type: "object",
|
|
405
|
-
properties: {
|
|
406
|
-
data: {
|
|
407
|
-
type: "array",
|
|
408
|
-
items: {
|
|
409
|
-
type: "object",
|
|
410
|
-
additionalProperties: {
|
|
411
|
-
type: "object",
|
|
412
|
-
properties: {
|
|
413
|
-
value: {
|
|
414
|
-
anyOf: [
|
|
415
|
-
{ type: "string" },
|
|
416
|
-
{ type: "number" },
|
|
417
|
-
{ type: "boolean" },
|
|
418
|
-
{ type: "object" },
|
|
419
|
-
{ type: "array" },
|
|
420
|
-
{ type: "null" },
|
|
421
|
-
],
|
|
422
|
-
description: "The value of the field.",
|
|
423
|
-
},
|
|
424
|
-
},
|
|
425
|
-
required: ["value"],
|
|
426
|
-
},
|
|
427
|
-
},
|
|
428
|
-
description: "Array of successfully upserted records (may be empty).",
|
|
429
|
-
},
|
|
430
|
-
metadata: {
|
|
431
|
-
type: "object",
|
|
432
|
-
properties: {
|
|
433
|
-
createdRecordIds: { type: "array", items: { type: "integer" } },
|
|
434
|
-
updatedRecordIds: { type: "array", items: { type: "integer" } },
|
|
435
|
-
unchangedRecordIds: { type: "array", items: { type: "integer" } },
|
|
436
|
-
lineErrors: {
|
|
437
|
-
type: "object",
|
|
438
|
-
additionalProperties: { type: "array", items: { type: "string" } },
|
|
439
|
-
description: "Errors by line number (1-based index).",
|
|
440
|
-
},
|
|
441
|
-
totalNumberOfRecordsProcessed: { type: "integer" },
|
|
442
|
-
},
|
|
443
|
-
required: ["totalNumberOfRecordsProcessed"],
|
|
444
|
-
},
|
|
445
|
-
},
|
|
446
|
-
},
|
|
447
|
-
ReportRunResponse: {
|
|
448
|
-
type: "object",
|
|
449
|
-
properties: {
|
|
450
|
-
id: { type: "string" },
|
|
451
|
-
data: { type: "object" },
|
|
452
|
-
},
|
|
453
|
-
},
|
|
454
|
-
GetTempTokenDBID200Response: {
|
|
455
|
-
type: "object",
|
|
456
|
-
required: ["temporaryAuthorization"],
|
|
457
|
-
properties: {
|
|
458
|
-
temporaryAuthorization: { type: "string" },
|
|
459
|
-
},
|
|
460
|
-
},
|
|
461
|
-
DeleteRecordsRequest: {
|
|
462
|
-
type: "object",
|
|
463
|
-
required: ["from", "where"],
|
|
464
|
-
properties: {
|
|
465
|
-
from: {
|
|
466
|
-
type: "string",
|
|
467
|
-
description:
|
|
468
|
-
"The table identifier (dbid) from which to delete records.",
|
|
469
|
-
},
|
|
470
|
-
where: {
|
|
471
|
-
type: "string",
|
|
472
|
-
description:
|
|
473
|
-
"A QuickBase query string specifying which records to delete.",
|
|
474
|
-
},
|
|
475
|
-
},
|
|
476
|
-
description:
|
|
477
|
-
"Request body for deleting records from a table using a query.",
|
|
478
|
-
},
|
|
479
|
-
DeleteRecords200Response: {
|
|
480
|
-
type: "object",
|
|
481
|
-
properties: {
|
|
482
|
-
numberDeleted: {
|
|
483
|
-
type: "integer",
|
|
484
|
-
description: "The number of records successfully deleted.",
|
|
485
|
-
},
|
|
486
|
-
},
|
|
487
|
-
required: ["numberDeleted"],
|
|
488
|
-
description: "Response body for successful deletion of records.",
|
|
489
|
-
},
|
|
490
|
-
RunQueryRequest: {
|
|
491
|
-
type: "object",
|
|
492
|
-
required: ["from"],
|
|
493
|
-
properties: {
|
|
494
|
-
from: { type: "string", description: "Table ID (dbid)" },
|
|
495
|
-
select: {
|
|
496
|
-
type: "array",
|
|
497
|
-
items: { type: "integer" },
|
|
498
|
-
description: "Field IDs to return",
|
|
499
|
-
},
|
|
500
|
-
where: { type: "string", description: "Query string" },
|
|
501
|
-
sortBy: {
|
|
502
|
-
type: "array",
|
|
503
|
-
items: {
|
|
504
|
-
type: "object",
|
|
505
|
-
properties: {
|
|
506
|
-
fieldId: { type: "integer" },
|
|
507
|
-
order: { type: "string", enum: ["ASC", "DESC"] },
|
|
508
|
-
},
|
|
509
|
-
},
|
|
510
|
-
description: "Sort criteria",
|
|
511
|
-
},
|
|
512
|
-
groupBy: {
|
|
513
|
-
type: "array",
|
|
514
|
-
items: {
|
|
515
|
-
type: "object",
|
|
516
|
-
properties: {
|
|
517
|
-
fieldId: { type: "integer" },
|
|
518
|
-
grouping: { type: "string", enum: ["equal-values"] },
|
|
519
|
-
},
|
|
520
|
-
},
|
|
521
|
-
description: "Grouping criteria",
|
|
522
|
-
},
|
|
523
|
-
options: {
|
|
524
|
-
type: "object",
|
|
525
|
-
properties: {
|
|
526
|
-
skip: { type: "integer", description: "Number of records to skip" },
|
|
527
|
-
top: {
|
|
528
|
-
type: "integer",
|
|
529
|
-
description: "Max number of records to return",
|
|
530
|
-
},
|
|
531
|
-
compareWithAppLocalTime: {
|
|
532
|
-
type: "boolean",
|
|
533
|
-
description: "Compare times with app local time",
|
|
534
|
-
},
|
|
535
|
-
},
|
|
536
|
-
},
|
|
537
|
-
},
|
|
538
|
-
},
|
|
539
|
-
RunQueryResponse: {
|
|
540
|
-
type: "object",
|
|
541
|
-
properties: {
|
|
542
|
-
data: {
|
|
543
|
-
type: "array",
|
|
544
|
-
items: {
|
|
545
|
-
type: "object",
|
|
546
|
-
additionalProperties: {
|
|
547
|
-
type: "object",
|
|
548
|
-
properties: { value: { type: "any" } },
|
|
549
|
-
},
|
|
550
|
-
},
|
|
551
|
-
description: "Array of record data with field IDs as keys",
|
|
552
|
-
},
|
|
553
|
-
fields: {
|
|
554
|
-
type: "array",
|
|
555
|
-
items: {
|
|
556
|
-
type: "object",
|
|
557
|
-
properties: {
|
|
558
|
-
id: { type: "integer" },
|
|
559
|
-
label: { type: "string" },
|
|
560
|
-
type: { type: "string" },
|
|
561
|
-
},
|
|
562
|
-
},
|
|
563
|
-
description: "Field metadata",
|
|
564
|
-
},
|
|
565
|
-
metadata: {
|
|
566
|
-
type: "object",
|
|
567
|
-
properties: {
|
|
568
|
-
numFields: { type: "integer" },
|
|
569
|
-
numRecords: { type: "integer" },
|
|
570
|
-
skip: { type: "integer" },
|
|
571
|
-
top: { type: "integer" },
|
|
572
|
-
totalRecords: { type: "integer" },
|
|
573
|
-
},
|
|
574
|
-
description: "Query metadata",
|
|
575
|
-
},
|
|
576
|
-
},
|
|
577
|
-
},
|
|
578
|
-
GetRelationships200Response: {
|
|
579
|
-
type: "object",
|
|
580
|
-
properties: {
|
|
581
|
-
metadata: {
|
|
582
|
-
type: "object",
|
|
583
|
-
properties: {
|
|
584
|
-
numRelationships: {
|
|
585
|
-
type: "integer",
|
|
586
|
-
description:
|
|
587
|
-
"The number of relationships in the current response object.",
|
|
588
|
-
},
|
|
589
|
-
skip: {
|
|
590
|
-
type: "integer",
|
|
591
|
-
description: "The number of relationships skipped.",
|
|
592
|
-
},
|
|
593
|
-
totalRelationships: {
|
|
594
|
-
type: "integer",
|
|
595
|
-
description: "The total number of relationships.",
|
|
596
|
-
},
|
|
597
|
-
},
|
|
598
|
-
required: ["numRelationships", "skip", "totalRelationships"],
|
|
599
|
-
description:
|
|
600
|
-
"Additional information about the results that may be helpful.",
|
|
601
|
-
},
|
|
602
|
-
relationships: {
|
|
603
|
-
type: "array",
|
|
604
|
-
items: { $ref: "#/definitions/Relationship" },
|
|
605
|
-
description: "The relationships in a table.",
|
|
606
|
-
},
|
|
607
|
-
},
|
|
608
|
-
required: ["metadata", "relationships"],
|
|
609
|
-
description: "Response containing relationships for a table.",
|
|
610
|
-
},
|
|
611
|
-
Relationship: {
|
|
612
|
-
type: "object",
|
|
613
|
-
properties: {
|
|
614
|
-
id: {
|
|
615
|
-
type: "integer",
|
|
616
|
-
description: "The relationship id (foreign key field id).",
|
|
617
|
-
},
|
|
618
|
-
parentTableId: {
|
|
619
|
-
type: "string",
|
|
620
|
-
description: "The parent table id of the relationship.",
|
|
621
|
-
},
|
|
622
|
-
childTableId: {
|
|
623
|
-
type: "string",
|
|
624
|
-
description: "The child table id of the relationship.",
|
|
625
|
-
},
|
|
626
|
-
foreignKeyField: {
|
|
627
|
-
$ref: "#/definitions/RelationshipField",
|
|
628
|
-
description: "The foreign key field information.",
|
|
629
|
-
},
|
|
630
|
-
isCrossApp: {
|
|
631
|
-
type: "boolean",
|
|
632
|
-
description: "Whether this is a cross-app relationship.",
|
|
633
|
-
},
|
|
634
|
-
lookupFields: {
|
|
635
|
-
type: "array",
|
|
636
|
-
items: { $ref: "#/definitions/RelationshipField" },
|
|
637
|
-
description: "The lookup fields array.",
|
|
638
|
-
},
|
|
639
|
-
summaryFields: {
|
|
640
|
-
type: "array",
|
|
641
|
-
items: { $ref: "#/definitions/RelationshipField" },
|
|
642
|
-
description: "The summary fields array.",
|
|
643
|
-
},
|
|
644
|
-
},
|
|
645
|
-
required: [
|
|
646
|
-
"id",
|
|
647
|
-
"parentTableId",
|
|
648
|
-
"childTableId",
|
|
649
|
-
"foreignKeyField",
|
|
650
|
-
"isCrossApp",
|
|
651
|
-
],
|
|
652
|
-
description: "A relationship between tables.",
|
|
653
|
-
},
|
|
654
|
-
RelationshipField: {
|
|
655
|
-
type: "object",
|
|
656
|
-
properties: {
|
|
657
|
-
id: {
|
|
658
|
-
type: "integer",
|
|
659
|
-
description: "Field id.",
|
|
660
|
-
},
|
|
661
|
-
label: {
|
|
662
|
-
type: "string",
|
|
663
|
-
description: "Field label.",
|
|
664
|
-
},
|
|
665
|
-
type: {
|
|
666
|
-
type: "string",
|
|
667
|
-
description: "Field type.",
|
|
668
|
-
},
|
|
669
|
-
},
|
|
670
|
-
required: ["id", "label", "type"],
|
|
671
|
-
description:
|
|
672
|
-
"A field involved in a relationship (foreign key, lookup, or summary).",
|
|
673
|
-
},
|
|
674
|
-
CopyAppRequest: {
|
|
675
|
-
type: "object",
|
|
676
|
-
required: ["name"],
|
|
677
|
-
properties: {
|
|
678
|
-
name: {
|
|
679
|
-
type: "string",
|
|
680
|
-
description: "The name of the newly copied app.",
|
|
681
|
-
},
|
|
682
|
-
description: {
|
|
683
|
-
type: "string",
|
|
684
|
-
description: "The description of the newly copied app.",
|
|
685
|
-
},
|
|
686
|
-
properties: {
|
|
687
|
-
type: "object",
|
|
688
|
-
properties: {
|
|
689
|
-
keepData: {
|
|
690
|
-
type: "boolean",
|
|
691
|
-
description:
|
|
692
|
-
"Whether to copy the app's data along with the schema.",
|
|
693
|
-
},
|
|
694
|
-
excludeFiles: {
|
|
695
|
-
type: "boolean",
|
|
696
|
-
description:
|
|
697
|
-
"If keepData is true, whether to copy file attachments. Ignored if keepData is false.",
|
|
698
|
-
},
|
|
699
|
-
usersAndRoles: {
|
|
700
|
-
type: "boolean",
|
|
701
|
-
description:
|
|
702
|
-
"If true, users will be copied along with their assigned roles. If false, users and roles will be copied but roles will not be assigned.",
|
|
703
|
-
},
|
|
704
|
-
assignUserToken: {
|
|
705
|
-
type: "boolean",
|
|
706
|
-
description:
|
|
707
|
-
"Whether to add the user token used to make this request to the new app.",
|
|
708
|
-
},
|
|
709
|
-
},
|
|
710
|
-
description:
|
|
711
|
-
"The configuration properties for performing the app copy.",
|
|
712
|
-
},
|
|
713
|
-
},
|
|
714
|
-
description: "Request body for copying an existing application.",
|
|
715
|
-
},
|
|
716
|
-
CopyApp200Response: {
|
|
717
|
-
type: "object",
|
|
718
|
-
required: ["id", "name"],
|
|
719
|
-
properties: {
|
|
720
|
-
id: {
|
|
721
|
-
type: "string",
|
|
722
|
-
description: "The unique identifier for the copied application.",
|
|
723
|
-
},
|
|
724
|
-
name: {
|
|
725
|
-
type: "string",
|
|
726
|
-
description:
|
|
727
|
-
"The app name. Multiple apps with the same name are allowed in the same realm.",
|
|
728
|
-
},
|
|
729
|
-
description: {
|
|
730
|
-
type: "string",
|
|
731
|
-
description: "The description for the app.",
|
|
732
|
-
},
|
|
733
|
-
created: {
|
|
734
|
-
type: "string",
|
|
735
|
-
format: "date-time",
|
|
736
|
-
description: "The time and date the app was created (ISO 8601, UTC).",
|
|
737
|
-
},
|
|
738
|
-
updated: {
|
|
739
|
-
type: "string",
|
|
740
|
-
format: "date-time",
|
|
741
|
-
description:
|
|
742
|
-
"The time and date the app was last updated (ISO 8601, UTC).",
|
|
743
|
-
},
|
|
744
|
-
dateFormat: {
|
|
745
|
-
type: "string",
|
|
746
|
-
description:
|
|
747
|
-
"The format used for displaying dates in the app (e.g., MM-DD-YYYY).",
|
|
748
|
-
},
|
|
749
|
-
timeZone: {
|
|
750
|
-
type: "string",
|
|
751
|
-
description:
|
|
752
|
-
"The time zone used for displaying time values (e.g., (UTC-08:00) Pacific Time).",
|
|
753
|
-
},
|
|
754
|
-
hasEveryoneOnTheInternet: {
|
|
755
|
-
type: "boolean",
|
|
756
|
-
description:
|
|
757
|
-
"Indicates if the app includes Everyone On The Internet access.",
|
|
758
|
-
},
|
|
759
|
-
variables: {
|
|
760
|
-
type: "array",
|
|
761
|
-
items: {
|
|
762
|
-
type: "object",
|
|
763
|
-
properties: {
|
|
764
|
-
name: { type: "string" },
|
|
765
|
-
value: { type: "string" },
|
|
766
|
-
},
|
|
767
|
-
required: ["name", "value"],
|
|
768
|
-
},
|
|
769
|
-
description: "The app variables.",
|
|
770
|
-
},
|
|
771
|
-
ancestorId: {
|
|
772
|
-
type: "string",
|
|
773
|
-
description: "The id of the app from which this app was copied.",
|
|
774
|
-
},
|
|
775
|
-
dataClassification: {
|
|
776
|
-
type: "string",
|
|
777
|
-
description:
|
|
778
|
-
"The Data Classification label assigned to the app (optional, may be 'None').",
|
|
779
|
-
},
|
|
780
|
-
},
|
|
781
|
-
description: "Response body for successful app copy operation.",
|
|
782
|
-
},
|
|
783
|
-
DeleteAppRequest: {
|
|
784
|
-
// New definition for deleteApp request
|
|
785
|
-
type: "object",
|
|
786
|
-
required: ["name"],
|
|
787
|
-
properties: {
|
|
788
|
-
name: {
|
|
789
|
-
type: "string",
|
|
790
|
-
description:
|
|
791
|
-
"The name of the application to delete, required for confirmation.",
|
|
792
|
-
},
|
|
793
|
-
},
|
|
794
|
-
description:
|
|
795
|
-
"Request body for deleting an application, requiring the app name for confirmation.",
|
|
796
|
-
},
|
|
797
|
-
DeleteApp200Response: {
|
|
798
|
-
// New definition for deleteApp response
|
|
799
|
-
type: "object",
|
|
800
|
-
properties: {
|
|
801
|
-
deletedAppId: {
|
|
802
|
-
type: "string",
|
|
803
|
-
description: "The ID of the deleted application.",
|
|
804
|
-
},
|
|
805
|
-
},
|
|
806
|
-
required: ["deletedAppId"],
|
|
807
|
-
description: "Response body for successful deletion of an application.",
|
|
808
|
-
},
|
|
809
|
-
};
|