quickbase-js 1.1.0-beta.1 → 1.1.0-beta.3

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.
@@ -61,6 +61,38 @@
61
61
  }
62
62
  }
63
63
  }
64
+ },
65
+ "delete": {
66
+ "operationId": "deleteApp",
67
+ "summary": "Delete an application by ID",
68
+ "tags": [
69
+ "Apps"
70
+ ],
71
+ "parameters": [
72
+ {
73
+ "name": "appId",
74
+ "in": "path",
75
+ "required": true,
76
+ "type": "string",
77
+ "description": "The unique identifier of the app to delete."
78
+ },
79
+ {
80
+ "name": "body",
81
+ "in": "body",
82
+ "required": true,
83
+ "schema": {
84
+ "$ref": "#/definitions/DeleteAppRequest"
85
+ }
86
+ }
87
+ ],
88
+ "responses": {
89
+ "200": {
90
+ "description": "Success - application deleted",
91
+ "schema": {
92
+ "$ref": "#/definitions/DeleteApp200Response"
93
+ }
94
+ }
95
+ }
64
96
  }
65
97
  },
66
98
  "/apps/{appId}/events": {
@@ -230,167 +262,36 @@
230
262
  },
231
263
  "/apps/{appId}/copy": {
232
264
  "post": {
233
- "description": "Copies the specified application. The new application will have the same schema as the original. See below for additional copy options.",
234
- "summary": "Copy an app",
235
265
  "operationId": "copyApp",
236
- "consumes": [
237
- "application/json"
238
- ],
239
- "produces": [
240
- "application/json"
266
+ "summary": "Copy an existing application",
267
+ "tags": [
268
+ "Apps"
241
269
  ],
242
270
  "parameters": [
243
271
  {
244
272
  "name": "appId",
245
- "description": "The unique identifier of an app",
246
- "required": true,
247
273
  "in": "path",
248
- "type": "string"
274
+ "required": true,
275
+ "type": "string",
276
+ "description": "The unique identifier of the app to copy."
249
277
  },
250
278
  {
251
- "x-amf-mediaType": "application/json",
279
+ "name": "body",
252
280
  "in": "body",
253
- "name": "generated",
281
+ "required": true,
254
282
  "schema": {
255
- "example": {
256
- "name": "my copied app",
257
- "description": "copied from my original app",
258
- "properties": {
259
- "keepData": false,
260
- "excludeFiles": true,
261
- "usersAndRoles": false,
262
- "assignUserToken": true
263
- }
264
- },
265
- "type": "object",
266
- "additionalProperties": false,
267
- "required": [
268
- "name"
269
- ],
270
- "properties": {
271
- "name": {
272
- "description": "The name of the newly copied app",
273
- "type": "string"
274
- },
275
- "description": {
276
- "description": "The description of the newly copied app",
277
- "type": "string"
278
- },
279
- "properties": {
280
- "description": "The configuration properties for performing the app copy",
281
- "type": "object",
282
- "additionalProperties": false,
283
- "properties": {
284
- "assignUserToken": {
285
- "description": "Whether to add the user token used to make this request to the new app",
286
- "type": "boolean"
287
- },
288
- "excludeFiles": {
289
- "description": "If keepData is true, whether to copy the file attachments as well. If keepData is false, this property is ignored",
290
- "type": "boolean"
291
- },
292
- "keepData": {
293
- "description": "Whether to copy the app's data along with the schema",
294
- "type": "boolean"
295
- },
296
- "usersAndRoles": {
297
- "description": "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",
298
- "type": "boolean"
299
- }
300
- }
301
- }
302
- }
283
+ "$ref": "#/definitions/CopyAppRequest"
303
284
  }
304
285
  }
305
286
  ],
306
287
  "responses": {
307
288
  "200": {
308
- "description": "Success",
309
- "x-amf-mediaType": "application/json",
289
+ "description": "Success - application copied",
310
290
  "schema": {
311
- "example": {
312
- "ancestorId": "bqhskthaq",
313
- "created": "2020-03-27T18:34:12Z",
314
- "dateFormat": "MM-DD-YYYY",
315
- "description": "My testing app",
316
- "hasEveryoneOnTheInternet": true,
317
- "id": "bpqe82s1",
318
- "name": "Testing App",
319
- "timeZone": "(UTC-08:00) Pacific Time (US & Canada)",
320
- "updated": "2020-04-03T19:12:20Z",
321
- "dataClassification": "None"
322
- },
323
- "type": "object",
324
- "additionalProperties": true,
325
- "required": [
326
- "name"
327
- ],
328
- "properties": {
329
- "name": {
330
- "description": "The app name. You are allowed to create multiple apps with the same name, in the same realm, because they will have different dbid values. We urge you to be careful about doing this.",
331
- "type": "string"
332
- },
333
- "description": {
334
- "description": "The description for the app",
335
- "type": "string"
336
- },
337
- "created": {
338
- "description": "The time and date the app was created, in the ISO 8601 time format YYYY-MM-DDThh:mm:ss.sssZ (in UTC time zone).",
339
- "type": "string"
340
- },
341
- "updated": {
342
- "description": "The time and date the app was last updated, in the ISO 8601 time format YYYY-MM-DDThh:mm:ss.sssZ (in UTC time zone).",
343
- "type": "string"
344
- },
345
- "dateFormat": {
346
- "description": "A description of the format used when displaying date values in this app. Note that this is a browser-only parameter - see the [Field type details](../fieldInfo) page in the API Guide for how time values are returned in API calls. See [About Localizing Dates](https://help.quickbase.com/user-assistance/about_localizing_dates_numbers.html) to set the app’s date format.",
347
- "type": "string"
348
- },
349
- "timeZone": {
350
- "description": "A description of the time zone used when displaying time values in this app. Note that this is a browser-only parameter - see the [Field type details](../fieldInfo) page in the portal for how time values are returned in API calls. See [Set the Time Zone for Both the Application and the Account](https://help.quickbase.com/user-assistance/application_local_timezone.html) to set the application’s time zone.",
351
- "type": "string"
352
- },
353
- "id": {
354
- "description": "The unique identifier for this application.",
355
- "type": "string"
356
- },
357
- "hasEveryoneOnTheInternet": {
358
- "description": "Indicates whether app includes Everyone On The Internet access. See [Sharing apps with Everyone on the Internet (EOTI).](https://help.quickbase.com/user-assistance/share_with_everyone_on_internet.html)",
359
- "type": "boolean"
360
- },
361
- "variables": {
362
- "description": "The app variables. See [About Application Variables](https://help.quickbase.com/user-assistance/variables.html)",
363
- "type": "array",
364
- "items": {
365
- "type": "object",
366
- "additionalProperties": true,
367
- "properties": {
368
- "name": {
369
- "description": "Variable name.",
370
- "type": "string"
371
- },
372
- "value": {
373
- "description": "Variable value.",
374
- "type": "string"
375
- }
376
- }
377
- }
378
- },
379
- "ancestorId": {
380
- "description": "The id of the app from which this app was copied",
381
- "type": "string"
382
- },
383
- "dataClassification": {
384
- "description": "The Data Classification label assigned to the application. If Data Classification is not turned on, this will not be returned. If Data Classification is turned on, but application is not labeled, we return “None\". Data Classification labels can be added in the Admin Console by a Realm Administrator for Platform+ plans.",
385
- "type": "string"
386
- }
387
- }
291
+ "$ref": "#/definitions/CopyApp200Response"
388
292
  }
389
293
  }
390
- },
391
- "tags": [
392
- "Apps"
393
- ]
294
+ }
394
295
  }
395
296
  },
396
297
  "/tables": {
@@ -580,222 +481,35 @@
580
481
  },
581
482
  "/tables/{tableId}/relationships": {
582
483
  "get": {
583
- "description": "Get a list of all relationships, and their definitions, for a specific table. Details are provided for the child side of relationships within a given application. Limited details are returned for cross-application relationships.",
584
484
  "operationId": "getRelationships",
585
- "summary": "Get all relationships",
586
- "consumes": [
587
- "application/json"
588
- ],
589
- "produces": [
590
- "application/json"
485
+ "summary": "Get relationships for a table",
486
+ "tags": [
487
+ "Relationships"
591
488
  ],
592
489
  "parameters": [
593
- {
594
- "name": "skip",
595
- "description": "The number of relationships to skip.",
596
- "required": false,
597
- "in": "query",
598
- "type": "integer"
599
- },
600
490
  {
601
491
  "name": "tableId",
602
- "description": "The unique identifier (dbid) of the child table.",
603
- "required": true,
604
492
  "in": "path",
605
- "type": "string"
493
+ "required": true,
494
+ "type": "string",
495
+ "description": "The unique identifier (dbid) of the child table."
496
+ },
497
+ {
498
+ "name": "skip",
499
+ "in": "query",
500
+ "required": false,
501
+ "type": "integer",
502
+ "description": "The number of relationships to skip."
606
503
  }
607
504
  ],
608
505
  "responses": {
609
506
  "200": {
610
- "description": "Success",
611
- "x-amf-mediaType": "application/json",
507
+ "description": "Success - relationships retrieved",
612
508
  "schema": {
613
- "example": {
614
- "metadata": {
615
- "numRelationships": 1,
616
- "skip": 0,
617
- "totalRelationships": 1
618
- },
619
- "relationships": [
620
- {
621
- "childTableId": "bqqjnwsuy",
622
- "foreignKeyField": {
623
- "id": 6,
624
- "label": "Related record",
625
- "type": "numeric"
626
- },
627
- "id": 6,
628
- "isCrossApp": false,
629
- "lookupFields": [
630
- {
631
- "id": 3,
632
- "label": "Name",
633
- "type": "text"
634
- }
635
- ],
636
- "parentTableId": "bck7gp3q2",
637
- "summaryFields": [
638
- {
639
- "id": 8,
640
- "label": "my summary field",
641
- "type": "numeric"
642
- }
643
- ]
644
- }
645
- ]
646
- },
647
- "type": "object",
648
- "additionalProperties": true,
649
- "required": [
650
- "relationships"
651
- ],
652
- "properties": {
653
- "relationships": {
654
- "description": "The relationships in a table.",
655
- "type": "array",
656
- "items": {
657
- "example": {
658
- "id": 6,
659
- "foreignKeyField": {
660
- "id": 6,
661
- "label": "Related record",
662
- "type": "numeric"
663
- },
664
- "lookupFields": [
665
- {
666
- "id": 7,
667
- "label": "record - text field",
668
- "type": "text"
669
- }
670
- ],
671
- "isCrossApp": false,
672
- "parentTableId": "bck7gp3q2",
673
- "childTableId": "bck7gp3q3",
674
- "summaryFields": [
675
- {
676
- "id": 8,
677
- "label": "Summary of Record ID#2",
678
- "type": "numeric"
679
- }
680
- ]
681
- },
682
- "type": "object",
683
- "additionalProperties": true,
684
- "required": [
685
- "id",
686
- "parentTableId",
687
- "childTableId",
688
- "isCrossApp"
689
- ],
690
- "properties": {
691
- "id": {
692
- "description": "The relationship id (foreign key field id).",
693
- "type": "integer"
694
- },
695
- "parentTableId": {
696
- "description": "The parent table id of the relationship.",
697
- "type": "string"
698
- },
699
- "childTableId": {
700
- "description": "The child table id of the relationship.",
701
- "type": "string"
702
- },
703
- "foreignKeyField": {
704
- "description": "The foreign key field information.",
705
- "type": "object",
706
- "additionalProperties": true,
707
- "properties": {
708
- "id": {
709
- "description": "Field id.",
710
- "type": "integer"
711
- },
712
- "label": {
713
- "description": "Field label.",
714
- "type": "string"
715
- },
716
- "type": {
717
- "description": "Field type.",
718
- "type": "string"
719
- }
720
- }
721
- },
722
- "isCrossApp": {
723
- "description": "Whether this is a cross-app relationship.",
724
- "type": "boolean"
725
- },
726
- "lookupFields": {
727
- "description": "The lookup fields array.",
728
- "type": "array",
729
- "items": {
730
- "type": "object",
731
- "additionalProperties": true,
732
- "properties": {
733
- "id": {
734
- "description": "Field id.",
735
- "type": "integer"
736
- },
737
- "label": {
738
- "description": "Field label.",
739
- "type": "string"
740
- },
741
- "type": {
742
- "description": "Field type.",
743
- "type": "string"
744
- }
745
- }
746
- }
747
- },
748
- "summaryFields": {
749
- "description": "The summary fields array.",
750
- "type": "array",
751
- "items": {
752
- "type": "object",
753
- "additionalProperties": true,
754
- "properties": {
755
- "id": {
756
- "description": "Field id.",
757
- "type": "integer"
758
- },
759
- "label": {
760
- "description": "Field label.",
761
- "type": "string"
762
- },
763
- "type": {
764
- "description": "Field type.",
765
- "type": "string"
766
- }
767
- }
768
- }
769
- }
770
- }
771
- }
772
- },
773
- "metadata": {
774
- "description": "Additional information about the results that may be helpful.",
775
- "type": "object",
776
- "additionalProperties": true,
777
- "properties": {
778
- "skip": {
779
- "description": "The number of relationships to skip.",
780
- "type": "integer"
781
- },
782
- "totalRelationships": {
783
- "description": "The total number of relationships.",
784
- "type": "integer"
785
- },
786
- "numRelationships": {
787
- "description": "The number of relationships in the current response object.",
788
- "type": "integer"
789
- }
790
- }
791
- }
792
- }
509
+ "$ref": "#/definitions/GetRelationships200Response"
793
510
  }
794
511
  }
795
- },
796
- "tags": [
797
- "Tables"
798
- ]
512
+ }
799
513
  }
800
514
  },
801
515
  "/tables/{tableId}/relationship": {
@@ -7731,16 +7445,32 @@
7731
7445
  "type": "object",
7732
7446
  "properties": {
7733
7447
  "value": {
7734
- "type": [
7735
- "string",
7736
- "number",
7737
- "boolean",
7738
- "object",
7739
- "array",
7740
- "null"
7741
- ]
7448
+ "anyOf": [
7449
+ {
7450
+ "type": "string"
7451
+ },
7452
+ {
7453
+ "type": "number"
7454
+ },
7455
+ {
7456
+ "type": "boolean"
7457
+ },
7458
+ {
7459
+ "type": "object"
7460
+ },
7461
+ {
7462
+ "type": "array"
7463
+ },
7464
+ {
7465
+ "type": "null"
7466
+ }
7467
+ ],
7468
+ "description": "The value of the field."
7742
7469
  }
7743
7470
  },
7471
+ "required": [
7472
+ "value"
7473
+ ],
7744
7474
  "description": "The value object for a field ID key."
7745
7475
  },
7746
7476
  "description": "A record with field ID keys (e.g., '6') and value objects (e.g., { value: 'data' })."
@@ -7786,9 +7516,32 @@
7786
7516
  "type": "object",
7787
7517
  "properties": {
7788
7518
  "value": {
7789
- "type": "any"
7519
+ "anyOf": [
7520
+ {
7521
+ "type": "string"
7522
+ },
7523
+ {
7524
+ "type": "number"
7525
+ },
7526
+ {
7527
+ "type": "boolean"
7528
+ },
7529
+ {
7530
+ "type": "object"
7531
+ },
7532
+ {
7533
+ "type": "array"
7534
+ },
7535
+ {
7536
+ "type": "null"
7537
+ }
7538
+ ],
7539
+ "description": "The value of the field."
7790
7540
  }
7791
- }
7541
+ },
7542
+ "required": [
7543
+ "value"
7544
+ ]
7792
7545
  }
7793
7546
  },
7794
7547
  "description": "Array of upserted records with field IDs and values."
@@ -7839,9 +7592,32 @@
7839
7592
  "type": "object",
7840
7593
  "properties": {
7841
7594
  "value": {
7842
- "type": "any"
7595
+ "anyOf": [
7596
+ {
7597
+ "type": "string"
7598
+ },
7599
+ {
7600
+ "type": "number"
7601
+ },
7602
+ {
7603
+ "type": "boolean"
7604
+ },
7605
+ {
7606
+ "type": "object"
7607
+ },
7608
+ {
7609
+ "type": "array"
7610
+ },
7611
+ {
7612
+ "type": "null"
7613
+ }
7614
+ ],
7615
+ "description": "The value of the field."
7843
7616
  }
7844
- }
7617
+ },
7618
+ "required": [
7619
+ "value"
7620
+ ]
7845
7621
  }
7846
7622
  },
7847
7623
  "description": "Array of successfully upserted records (may be empty)."
@@ -8075,6 +7851,252 @@
8075
7851
  "description": "Query metadata"
8076
7852
  }
8077
7853
  }
7854
+ },
7855
+ "GetRelationships200Response": {
7856
+ "type": "object",
7857
+ "properties": {
7858
+ "metadata": {
7859
+ "type": "object",
7860
+ "properties": {
7861
+ "numRelationships": {
7862
+ "type": "integer",
7863
+ "description": "The number of relationships in the current response object."
7864
+ },
7865
+ "skip": {
7866
+ "type": "integer",
7867
+ "description": "The number of relationships skipped."
7868
+ },
7869
+ "totalRelationships": {
7870
+ "type": "integer",
7871
+ "description": "The total number of relationships."
7872
+ }
7873
+ },
7874
+ "required": [
7875
+ "numRelationships",
7876
+ "skip",
7877
+ "totalRelationships"
7878
+ ],
7879
+ "description": "Additional information about the results that may be helpful."
7880
+ },
7881
+ "relationships": {
7882
+ "type": "array",
7883
+ "items": {
7884
+ "$ref": "#/definitions/Relationship"
7885
+ },
7886
+ "description": "The relationships in a table."
7887
+ }
7888
+ },
7889
+ "required": [
7890
+ "metadata",
7891
+ "relationships"
7892
+ ],
7893
+ "description": "Response containing relationships for a table."
7894
+ },
7895
+ "Relationship": {
7896
+ "type": "object",
7897
+ "properties": {
7898
+ "id": {
7899
+ "type": "integer",
7900
+ "description": "The relationship id (foreign key field id)."
7901
+ },
7902
+ "parentTableId": {
7903
+ "type": "string",
7904
+ "description": "The parent table id of the relationship."
7905
+ },
7906
+ "childTableId": {
7907
+ "type": "string",
7908
+ "description": "The child table id of the relationship."
7909
+ },
7910
+ "foreignKeyField": {
7911
+ "$ref": "#/definitions/RelationshipField",
7912
+ "description": "The foreign key field information."
7913
+ },
7914
+ "isCrossApp": {
7915
+ "type": "boolean",
7916
+ "description": "Whether this is a cross-app relationship."
7917
+ },
7918
+ "lookupFields": {
7919
+ "type": "array",
7920
+ "items": {
7921
+ "$ref": "#/definitions/RelationshipField"
7922
+ },
7923
+ "description": "The lookup fields array."
7924
+ },
7925
+ "summaryFields": {
7926
+ "type": "array",
7927
+ "items": {
7928
+ "$ref": "#/definitions/RelationshipField"
7929
+ },
7930
+ "description": "The summary fields array."
7931
+ }
7932
+ },
7933
+ "required": [
7934
+ "id",
7935
+ "parentTableId",
7936
+ "childTableId",
7937
+ "foreignKeyField",
7938
+ "isCrossApp"
7939
+ ],
7940
+ "description": "A relationship between tables."
7941
+ },
7942
+ "RelationshipField": {
7943
+ "type": "object",
7944
+ "properties": {
7945
+ "id": {
7946
+ "type": "integer",
7947
+ "description": "Field id."
7948
+ },
7949
+ "label": {
7950
+ "type": "string",
7951
+ "description": "Field label."
7952
+ },
7953
+ "type": {
7954
+ "type": "string",
7955
+ "description": "Field type."
7956
+ }
7957
+ },
7958
+ "required": [
7959
+ "id",
7960
+ "label",
7961
+ "type"
7962
+ ],
7963
+ "description": "A field involved in a relationship (foreign key, lookup, or summary)."
7964
+ },
7965
+ "CopyAppRequest": {
7966
+ "type": "object",
7967
+ "required": [
7968
+ "name"
7969
+ ],
7970
+ "properties": {
7971
+ "name": {
7972
+ "type": "string",
7973
+ "description": "The name of the newly copied app."
7974
+ },
7975
+ "description": {
7976
+ "type": "string",
7977
+ "description": "The description of the newly copied app."
7978
+ },
7979
+ "properties": {
7980
+ "type": "object",
7981
+ "properties": {
7982
+ "keepData": {
7983
+ "type": "boolean",
7984
+ "description": "Whether to copy the app's data along with the schema."
7985
+ },
7986
+ "excludeFiles": {
7987
+ "type": "boolean",
7988
+ "description": "If keepData is true, whether to copy file attachments. Ignored if keepData is false."
7989
+ },
7990
+ "usersAndRoles": {
7991
+ "type": "boolean",
7992
+ "description": "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."
7993
+ },
7994
+ "assignUserToken": {
7995
+ "type": "boolean",
7996
+ "description": "Whether to add the user token used to make this request to the new app."
7997
+ }
7998
+ },
7999
+ "description": "The configuration properties for performing the app copy."
8000
+ }
8001
+ },
8002
+ "description": "Request body for copying an existing application."
8003
+ },
8004
+ "CopyApp200Response": {
8005
+ "type": "object",
8006
+ "required": [
8007
+ "id",
8008
+ "name"
8009
+ ],
8010
+ "properties": {
8011
+ "id": {
8012
+ "type": "string",
8013
+ "description": "The unique identifier for the copied application."
8014
+ },
8015
+ "name": {
8016
+ "type": "string",
8017
+ "description": "The app name. Multiple apps with the same name are allowed in the same realm."
8018
+ },
8019
+ "description": {
8020
+ "type": "string",
8021
+ "description": "The description for the app."
8022
+ },
8023
+ "created": {
8024
+ "type": "string",
8025
+ "format": "date-time",
8026
+ "description": "The time and date the app was created (ISO 8601, UTC)."
8027
+ },
8028
+ "updated": {
8029
+ "type": "string",
8030
+ "format": "date-time",
8031
+ "description": "The time and date the app was last updated (ISO 8601, UTC)."
8032
+ },
8033
+ "dateFormat": {
8034
+ "type": "string",
8035
+ "description": "The format used for displaying dates in the app (e.g., MM-DD-YYYY)."
8036
+ },
8037
+ "timeZone": {
8038
+ "type": "string",
8039
+ "description": "The time zone used for displaying time values (e.g., (UTC-08:00) Pacific Time)."
8040
+ },
8041
+ "hasEveryoneOnTheInternet": {
8042
+ "type": "boolean",
8043
+ "description": "Indicates if the app includes Everyone On The Internet access."
8044
+ },
8045
+ "variables": {
8046
+ "type": "array",
8047
+ "items": {
8048
+ "type": "object",
8049
+ "properties": {
8050
+ "name": {
8051
+ "type": "string"
8052
+ },
8053
+ "value": {
8054
+ "type": "string"
8055
+ }
8056
+ },
8057
+ "required": [
8058
+ "name",
8059
+ "value"
8060
+ ]
8061
+ },
8062
+ "description": "The app variables."
8063
+ },
8064
+ "ancestorId": {
8065
+ "type": "string",
8066
+ "description": "The id of the app from which this app was copied."
8067
+ },
8068
+ "dataClassification": {
8069
+ "type": "string",
8070
+ "description": "The Data Classification label assigned to the app (optional, may be 'None')."
8071
+ }
8072
+ },
8073
+ "description": "Response body for successful app copy operation."
8074
+ },
8075
+ "DeleteAppRequest": {
8076
+ "type": "object",
8077
+ "required": [
8078
+ "name"
8079
+ ],
8080
+ "properties": {
8081
+ "name": {
8082
+ "type": "string",
8083
+ "description": "The name of the application to delete, required for confirmation."
8084
+ }
8085
+ },
8086
+ "description": "Request body for deleting an application, requiring the app name for confirmation."
8087
+ },
8088
+ "DeleteApp200Response": {
8089
+ "type": "object",
8090
+ "properties": {
8091
+ "deletedAppId": {
8092
+ "type": "string",
8093
+ "description": "The ID of the deleted application."
8094
+ }
8095
+ },
8096
+ "required": [
8097
+ "deletedAppId"
8098
+ ],
8099
+ "description": "Response body for successful deletion of an application."
8078
8100
  }
8079
8101
  }
8080
8102
  }