linkque-cli-v2 1.4.0 → 1.4.1

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.
@@ -11387,6 +11387,3683 @@ var Databases = class {
11387
11387
  }
11388
11388
  };
11389
11389
 
11390
+ // ../../node_modules/@alipay/appbase-node-sdk/dist/services/tables-db.mjs
11391
+ var TablesDB = class {
11392
+ constructor(client) {
11393
+ this.client = client;
11394
+ }
11395
+ list(paramsOrFirst, ...rest) {
11396
+ let params;
11397
+ if (!paramsOrFirst || paramsOrFirst && typeof paramsOrFirst === "object" && !Array.isArray(paramsOrFirst)) {
11398
+ params = paramsOrFirst || {};
11399
+ } else {
11400
+ params = {
11401
+ queries: paramsOrFirst,
11402
+ search: rest[0],
11403
+ total: rest[1]
11404
+ };
11405
+ }
11406
+ const queries = params.queries;
11407
+ const search = params.search;
11408
+ const total = params.total;
11409
+ const apiPath = "/tablesdb";
11410
+ const payload = {};
11411
+ if (typeof queries !== "undefined") {
11412
+ payload["queries"] = queries;
11413
+ }
11414
+ if (typeof search !== "undefined") {
11415
+ payload["search"] = search;
11416
+ }
11417
+ if (typeof total !== "undefined") {
11418
+ payload["total"] = total;
11419
+ }
11420
+ const uri = new URL(this.client.config.endpoint + apiPath);
11421
+ const apiHeaders = {};
11422
+ return this.client.call(
11423
+ "get",
11424
+ uri,
11425
+ apiHeaders,
11426
+ payload
11427
+ );
11428
+ }
11429
+ create(paramsOrFirst, ...rest) {
11430
+ let params;
11431
+ if (paramsOrFirst && typeof paramsOrFirst === "object" && !Array.isArray(paramsOrFirst)) {
11432
+ params = paramsOrFirst || {};
11433
+ } else {
11434
+ params = {
11435
+ databaseId: paramsOrFirst,
11436
+ name: rest[0],
11437
+ enabled: rest[1]
11438
+ };
11439
+ }
11440
+ const databaseId = params.databaseId;
11441
+ const name = params.name;
11442
+ const enabled = params.enabled;
11443
+ if (typeof databaseId === "undefined") {
11444
+ throw new AppBaseException('Missing required parameter: "databaseId"');
11445
+ }
11446
+ if (typeof name === "undefined") {
11447
+ throw new AppBaseException('Missing required parameter: "name"');
11448
+ }
11449
+ const apiPath = "/tablesdb";
11450
+ const payload = {};
11451
+ if (typeof databaseId !== "undefined") {
11452
+ payload["databaseId"] = databaseId;
11453
+ }
11454
+ if (typeof name !== "undefined") {
11455
+ payload["name"] = name;
11456
+ }
11457
+ if (typeof enabled !== "undefined") {
11458
+ payload["enabled"] = enabled;
11459
+ }
11460
+ const uri = new URL(this.client.config.endpoint + apiPath);
11461
+ const apiHeaders = {
11462
+ "content-type": "application/json"
11463
+ };
11464
+ return this.client.call(
11465
+ "post",
11466
+ uri,
11467
+ apiHeaders,
11468
+ payload
11469
+ );
11470
+ }
11471
+ listTransactions(paramsOrFirst) {
11472
+ let params;
11473
+ if (!paramsOrFirst || paramsOrFirst && typeof paramsOrFirst === "object" && !Array.isArray(paramsOrFirst)) {
11474
+ params = paramsOrFirst || {};
11475
+ } else {
11476
+ params = {
11477
+ queries: paramsOrFirst
11478
+ };
11479
+ }
11480
+ const queries = params.queries;
11481
+ const apiPath = "/tablesdb/transactions";
11482
+ const payload = {};
11483
+ if (typeof queries !== "undefined") {
11484
+ payload["queries"] = queries;
11485
+ }
11486
+ const uri = new URL(this.client.config.endpoint + apiPath);
11487
+ const apiHeaders = {};
11488
+ return this.client.call(
11489
+ "get",
11490
+ uri,
11491
+ apiHeaders,
11492
+ payload
11493
+ );
11494
+ }
11495
+ createTransaction(paramsOrFirst) {
11496
+ let params;
11497
+ if (!paramsOrFirst || paramsOrFirst && typeof paramsOrFirst === "object" && !Array.isArray(paramsOrFirst)) {
11498
+ params = paramsOrFirst || {};
11499
+ } else {
11500
+ params = {
11501
+ ttl: paramsOrFirst
11502
+ };
11503
+ }
11504
+ const ttl = params.ttl;
11505
+ const apiPath = "/tablesdb/transactions";
11506
+ const payload = {};
11507
+ if (typeof ttl !== "undefined") {
11508
+ payload["ttl"] = ttl;
11509
+ }
11510
+ const uri = new URL(this.client.config.endpoint + apiPath);
11511
+ const apiHeaders = {
11512
+ "content-type": "application/json"
11513
+ };
11514
+ return this.client.call(
11515
+ "post",
11516
+ uri,
11517
+ apiHeaders,
11518
+ payload
11519
+ );
11520
+ }
11521
+ getTransaction(paramsOrFirst) {
11522
+ let params;
11523
+ if (paramsOrFirst && typeof paramsOrFirst === "object" && !Array.isArray(paramsOrFirst)) {
11524
+ params = paramsOrFirst || {};
11525
+ } else {
11526
+ params = {
11527
+ transactionId: paramsOrFirst
11528
+ };
11529
+ }
11530
+ const transactionId = params.transactionId;
11531
+ if (typeof transactionId === "undefined") {
11532
+ throw new AppBaseException('Missing required parameter: "transactionId"');
11533
+ }
11534
+ const apiPath = "/tablesdb/transactions/{transactionId}".replace("{transactionId}", transactionId);
11535
+ const payload = {};
11536
+ const uri = new URL(this.client.config.endpoint + apiPath);
11537
+ const apiHeaders = {};
11538
+ return this.client.call(
11539
+ "get",
11540
+ uri,
11541
+ apiHeaders,
11542
+ payload
11543
+ );
11544
+ }
11545
+ updateTransaction(paramsOrFirst, ...rest) {
11546
+ let params;
11547
+ if (paramsOrFirst && typeof paramsOrFirst === "object" && !Array.isArray(paramsOrFirst)) {
11548
+ params = paramsOrFirst || {};
11549
+ } else {
11550
+ params = {
11551
+ transactionId: paramsOrFirst,
11552
+ commit: rest[0],
11553
+ rollback: rest[1]
11554
+ };
11555
+ }
11556
+ const transactionId = params.transactionId;
11557
+ const commit = params.commit;
11558
+ const rollback = params.rollback;
11559
+ if (typeof transactionId === "undefined") {
11560
+ throw new AppBaseException('Missing required parameter: "transactionId"');
11561
+ }
11562
+ const apiPath = "/tablesdb/transactions/{transactionId}".replace("{transactionId}", transactionId);
11563
+ const payload = {};
11564
+ if (typeof commit !== "undefined") {
11565
+ payload["commit"] = commit;
11566
+ }
11567
+ if (typeof rollback !== "undefined") {
11568
+ payload["rollback"] = rollback;
11569
+ }
11570
+ const uri = new URL(this.client.config.endpoint + apiPath);
11571
+ const apiHeaders = {
11572
+ "content-type": "application/json"
11573
+ };
11574
+ return this.client.call(
11575
+ "patch",
11576
+ uri,
11577
+ apiHeaders,
11578
+ payload
11579
+ );
11580
+ }
11581
+ deleteTransaction(paramsOrFirst) {
11582
+ let params;
11583
+ if (paramsOrFirst && typeof paramsOrFirst === "object" && !Array.isArray(paramsOrFirst)) {
11584
+ params = paramsOrFirst || {};
11585
+ } else {
11586
+ params = {
11587
+ transactionId: paramsOrFirst
11588
+ };
11589
+ }
11590
+ const transactionId = params.transactionId;
11591
+ if (typeof transactionId === "undefined") {
11592
+ throw new AppBaseException('Missing required parameter: "transactionId"');
11593
+ }
11594
+ const apiPath = "/tablesdb/transactions/{transactionId}".replace("{transactionId}", transactionId);
11595
+ const payload = {};
11596
+ const uri = new URL(this.client.config.endpoint + apiPath);
11597
+ const apiHeaders = {
11598
+ "content-type": "application/json"
11599
+ };
11600
+ return this.client.call(
11601
+ "delete",
11602
+ uri,
11603
+ apiHeaders,
11604
+ payload
11605
+ );
11606
+ }
11607
+ createOperations(paramsOrFirst, ...rest) {
11608
+ let params;
11609
+ if (paramsOrFirst && typeof paramsOrFirst === "object" && !Array.isArray(paramsOrFirst)) {
11610
+ params = paramsOrFirst || {};
11611
+ } else {
11612
+ params = {
11613
+ transactionId: paramsOrFirst,
11614
+ operations: rest[0]
11615
+ };
11616
+ }
11617
+ const transactionId = params.transactionId;
11618
+ const operations = params.operations;
11619
+ if (typeof transactionId === "undefined") {
11620
+ throw new AppBaseException('Missing required parameter: "transactionId"');
11621
+ }
11622
+ const apiPath = "/tablesdb/transactions/{transactionId}/operations".replace("{transactionId}", transactionId);
11623
+ const payload = {};
11624
+ if (typeof operations !== "undefined") {
11625
+ payload["operations"] = operations;
11626
+ }
11627
+ const uri = new URL(this.client.config.endpoint + apiPath);
11628
+ const apiHeaders = {
11629
+ "content-type": "application/json"
11630
+ };
11631
+ return this.client.call(
11632
+ "post",
11633
+ uri,
11634
+ apiHeaders,
11635
+ payload
11636
+ );
11637
+ }
11638
+ get(paramsOrFirst) {
11639
+ let params;
11640
+ if (paramsOrFirst && typeof paramsOrFirst === "object" && !Array.isArray(paramsOrFirst)) {
11641
+ params = paramsOrFirst || {};
11642
+ } else {
11643
+ params = {
11644
+ databaseId: paramsOrFirst
11645
+ };
11646
+ }
11647
+ const databaseId = params.databaseId;
11648
+ if (typeof databaseId === "undefined") {
11649
+ throw new AppBaseException('Missing required parameter: "databaseId"');
11650
+ }
11651
+ const apiPath = "/tablesdb/{databaseId}".replace("{databaseId}", databaseId);
11652
+ const payload = {};
11653
+ const uri = new URL(this.client.config.endpoint + apiPath);
11654
+ const apiHeaders = {};
11655
+ return this.client.call(
11656
+ "get",
11657
+ uri,
11658
+ apiHeaders,
11659
+ payload
11660
+ );
11661
+ }
11662
+ update(paramsOrFirst, ...rest) {
11663
+ let params;
11664
+ if (paramsOrFirst && typeof paramsOrFirst === "object" && !Array.isArray(paramsOrFirst)) {
11665
+ params = paramsOrFirst || {};
11666
+ } else {
11667
+ params = {
11668
+ databaseId: paramsOrFirst,
11669
+ name: rest[0],
11670
+ enabled: rest[1]
11671
+ };
11672
+ }
11673
+ const databaseId = params.databaseId;
11674
+ const name = params.name;
11675
+ const enabled = params.enabled;
11676
+ if (typeof databaseId === "undefined") {
11677
+ throw new AppBaseException('Missing required parameter: "databaseId"');
11678
+ }
11679
+ const apiPath = "/tablesdb/{databaseId}".replace("{databaseId}", databaseId);
11680
+ const payload = {};
11681
+ if (typeof name !== "undefined") {
11682
+ payload["name"] = name;
11683
+ }
11684
+ if (typeof enabled !== "undefined") {
11685
+ payload["enabled"] = enabled;
11686
+ }
11687
+ const uri = new URL(this.client.config.endpoint + apiPath);
11688
+ const apiHeaders = {
11689
+ "content-type": "application/json"
11690
+ };
11691
+ return this.client.call(
11692
+ "put",
11693
+ uri,
11694
+ apiHeaders,
11695
+ payload
11696
+ );
11697
+ }
11698
+ delete(paramsOrFirst) {
11699
+ let params;
11700
+ if (paramsOrFirst && typeof paramsOrFirst === "object" && !Array.isArray(paramsOrFirst)) {
11701
+ params = paramsOrFirst || {};
11702
+ } else {
11703
+ params = {
11704
+ databaseId: paramsOrFirst
11705
+ };
11706
+ }
11707
+ const databaseId = params.databaseId;
11708
+ if (typeof databaseId === "undefined") {
11709
+ throw new AppBaseException('Missing required parameter: "databaseId"');
11710
+ }
11711
+ const apiPath = "/tablesdb/{databaseId}".replace("{databaseId}", databaseId);
11712
+ const payload = {};
11713
+ const uri = new URL(this.client.config.endpoint + apiPath);
11714
+ const apiHeaders = {
11715
+ "content-type": "application/json"
11716
+ };
11717
+ return this.client.call(
11718
+ "delete",
11719
+ uri,
11720
+ apiHeaders,
11721
+ payload
11722
+ );
11723
+ }
11724
+ rollbackSchemaVersion(paramsOrFirst, ...rest) {
11725
+ let params;
11726
+ if (paramsOrFirst && typeof paramsOrFirst === "object" && !Array.isArray(paramsOrFirst)) {
11727
+ params = paramsOrFirst || {};
11728
+ } else {
11729
+ params = {
11730
+ databaseId: paramsOrFirst,
11731
+ versionId: rest[0]
11732
+ };
11733
+ }
11734
+ const databaseId = params.databaseId;
11735
+ const versionId = params.versionId;
11736
+ if (typeof databaseId === "undefined") {
11737
+ throw new AppBaseException('Missing required parameter: "databaseId"');
11738
+ }
11739
+ if (typeof versionId === "undefined") {
11740
+ throw new AppBaseException('Missing required parameter: "versionId"');
11741
+ }
11742
+ const apiPath = "/tablesdb/{databaseId}/schema/rollback/{versionId}".replace("{databaseId}", databaseId).replace("{versionId}", versionId);
11743
+ const payload = {};
11744
+ const uri = new URL(this.client.config.endpoint + apiPath);
11745
+ const apiHeaders = {
11746
+ "content-type": "application/json"
11747
+ };
11748
+ return this.client.call(
11749
+ "post",
11750
+ uri,
11751
+ apiHeaders,
11752
+ payload
11753
+ );
11754
+ }
11755
+ listSchemaVersions(paramsOrFirst, ...rest) {
11756
+ let params;
11757
+ if (paramsOrFirst && typeof paramsOrFirst === "object" && !Array.isArray(paramsOrFirst)) {
11758
+ params = paramsOrFirst || {};
11759
+ } else {
11760
+ params = {
11761
+ databaseId: paramsOrFirst,
11762
+ queries: rest[0],
11763
+ total: rest[1]
11764
+ };
11765
+ }
11766
+ const databaseId = params.databaseId;
11767
+ const queries = params.queries;
11768
+ const total = params.total;
11769
+ if (typeof databaseId === "undefined") {
11770
+ throw new AppBaseException('Missing required parameter: "databaseId"');
11771
+ }
11772
+ const apiPath = "/tablesdb/{databaseId}/schema/versions".replace("{databaseId}", databaseId);
11773
+ const payload = {};
11774
+ if (typeof queries !== "undefined") {
11775
+ payload["queries"] = queries;
11776
+ }
11777
+ if (typeof total !== "undefined") {
11778
+ payload["total"] = total;
11779
+ }
11780
+ const uri = new URL(this.client.config.endpoint + apiPath);
11781
+ const apiHeaders = {};
11782
+ return this.client.call(
11783
+ "get",
11784
+ uri,
11785
+ apiHeaders,
11786
+ payload
11787
+ );
11788
+ }
11789
+ createSchemaVersion(paramsOrFirst, ...rest) {
11790
+ let params;
11791
+ if (paramsOrFirst && typeof paramsOrFirst === "object" && !Array.isArray(paramsOrFirst)) {
11792
+ params = paramsOrFirst || {};
11793
+ } else {
11794
+ params = {
11795
+ databaseId: paramsOrFirst,
11796
+ schema: rest[0]
11797
+ };
11798
+ }
11799
+ const databaseId = params.databaseId;
11800
+ const schema = params.schema;
11801
+ if (typeof databaseId === "undefined") {
11802
+ throw new AppBaseException('Missing required parameter: "databaseId"');
11803
+ }
11804
+ if (typeof schema === "undefined") {
11805
+ throw new AppBaseException('Missing required parameter: "schema"');
11806
+ }
11807
+ const apiPath = "/tablesdb/{databaseId}/schema/versions".replace("{databaseId}", databaseId);
11808
+ const payload = {};
11809
+ if (typeof schema !== "undefined") {
11810
+ payload["schema"] = schema;
11811
+ }
11812
+ const uri = new URL(this.client.config.endpoint + apiPath);
11813
+ const apiHeaders = {
11814
+ "content-type": "application/json"
11815
+ };
11816
+ return this.client.call(
11817
+ "post",
11818
+ uri,
11819
+ apiHeaders,
11820
+ payload
11821
+ );
11822
+ }
11823
+ getSchemaVersion(paramsOrFirst, ...rest) {
11824
+ let params;
11825
+ if (paramsOrFirst && typeof paramsOrFirst === "object" && !Array.isArray(paramsOrFirst)) {
11826
+ params = paramsOrFirst || {};
11827
+ } else {
11828
+ params = {
11829
+ databaseId: paramsOrFirst,
11830
+ versionId: rest[0]
11831
+ };
11832
+ }
11833
+ const databaseId = params.databaseId;
11834
+ const versionId = params.versionId;
11835
+ if (typeof databaseId === "undefined") {
11836
+ throw new AppBaseException('Missing required parameter: "databaseId"');
11837
+ }
11838
+ if (typeof versionId === "undefined") {
11839
+ throw new AppBaseException('Missing required parameter: "versionId"');
11840
+ }
11841
+ const apiPath = "/tablesdb/{databaseId}/schema/versions/{versionId}".replace("{databaseId}", databaseId).replace("{versionId}", versionId);
11842
+ const payload = {};
11843
+ const uri = new URL(this.client.config.endpoint + apiPath);
11844
+ const apiHeaders = {};
11845
+ return this.client.call(
11846
+ "get",
11847
+ uri,
11848
+ apiHeaders,
11849
+ payload
11850
+ );
11851
+ }
11852
+ listTables(paramsOrFirst, ...rest) {
11853
+ let params;
11854
+ if (paramsOrFirst && typeof paramsOrFirst === "object" && !Array.isArray(paramsOrFirst)) {
11855
+ params = paramsOrFirst || {};
11856
+ } else {
11857
+ params = {
11858
+ databaseId: paramsOrFirst,
11859
+ queries: rest[0],
11860
+ search: rest[1],
11861
+ total: rest[2]
11862
+ };
11863
+ }
11864
+ const databaseId = params.databaseId;
11865
+ const queries = params.queries;
11866
+ const search = params.search;
11867
+ const total = params.total;
11868
+ if (typeof databaseId === "undefined") {
11869
+ throw new AppBaseException('Missing required parameter: "databaseId"');
11870
+ }
11871
+ const apiPath = "/tablesdb/{databaseId}/tables".replace("{databaseId}", databaseId);
11872
+ const payload = {};
11873
+ if (typeof queries !== "undefined") {
11874
+ payload["queries"] = queries;
11875
+ }
11876
+ if (typeof search !== "undefined") {
11877
+ payload["search"] = search;
11878
+ }
11879
+ if (typeof total !== "undefined") {
11880
+ payload["total"] = total;
11881
+ }
11882
+ const uri = new URL(this.client.config.endpoint + apiPath);
11883
+ const apiHeaders = {};
11884
+ return this.client.call(
11885
+ "get",
11886
+ uri,
11887
+ apiHeaders,
11888
+ payload
11889
+ );
11890
+ }
11891
+ createTable(paramsOrFirst, ...rest) {
11892
+ let params;
11893
+ if (paramsOrFirst && typeof paramsOrFirst === "object" && !Array.isArray(paramsOrFirst)) {
11894
+ params = paramsOrFirst || {};
11895
+ } else {
11896
+ params = {
11897
+ databaseId: paramsOrFirst,
11898
+ tableId: rest[0],
11899
+ name: rest[1],
11900
+ permissions: rest[2],
11901
+ rowSecurity: rest[3],
11902
+ enabled: rest[4],
11903
+ columns: rest[5],
11904
+ indexes: rest[6],
11905
+ comment: rest[7]
11906
+ };
11907
+ }
11908
+ const databaseId = params.databaseId;
11909
+ const tableId = params.tableId;
11910
+ const name = params.name;
11911
+ const permissions = params.permissions;
11912
+ const rowSecurity = params.rowSecurity;
11913
+ const enabled = params.enabled;
11914
+ const columns = params.columns;
11915
+ const indexes = params.indexes;
11916
+ const comment = params.comment;
11917
+ if (typeof databaseId === "undefined") {
11918
+ throw new AppBaseException('Missing required parameter: "databaseId"');
11919
+ }
11920
+ if (typeof tableId === "undefined") {
11921
+ throw new AppBaseException('Missing required parameter: "tableId"');
11922
+ }
11923
+ if (typeof name === "undefined") {
11924
+ throw new AppBaseException('Missing required parameter: "name"');
11925
+ }
11926
+ const apiPath = "/tablesdb/{databaseId}/tables".replace("{databaseId}", databaseId);
11927
+ const payload = {};
11928
+ if (typeof tableId !== "undefined") {
11929
+ payload["tableId"] = tableId;
11930
+ }
11931
+ if (typeof name !== "undefined") {
11932
+ payload["name"] = name;
11933
+ }
11934
+ if (typeof permissions !== "undefined") {
11935
+ payload["permissions"] = permissions;
11936
+ }
11937
+ if (typeof rowSecurity !== "undefined") {
11938
+ payload["rowSecurity"] = rowSecurity;
11939
+ }
11940
+ if (typeof enabled !== "undefined") {
11941
+ payload["enabled"] = enabled;
11942
+ }
11943
+ if (typeof columns !== "undefined") {
11944
+ payload["columns"] = columns;
11945
+ }
11946
+ if (typeof indexes !== "undefined") {
11947
+ payload["indexes"] = indexes;
11948
+ }
11949
+ if (typeof comment !== "undefined") {
11950
+ payload["comment"] = comment;
11951
+ }
11952
+ const uri = new URL(this.client.config.endpoint + apiPath);
11953
+ const apiHeaders = {
11954
+ "content-type": "application/json"
11955
+ };
11956
+ return this.client.call(
11957
+ "post",
11958
+ uri,
11959
+ apiHeaders,
11960
+ payload
11961
+ );
11962
+ }
11963
+ getTable(paramsOrFirst, ...rest) {
11964
+ let params;
11965
+ if (paramsOrFirst && typeof paramsOrFirst === "object" && !Array.isArray(paramsOrFirst)) {
11966
+ params = paramsOrFirst || {};
11967
+ } else {
11968
+ params = {
11969
+ databaseId: paramsOrFirst,
11970
+ tableId: rest[0]
11971
+ };
11972
+ }
11973
+ const databaseId = params.databaseId;
11974
+ const tableId = params.tableId;
11975
+ if (typeof databaseId === "undefined") {
11976
+ throw new AppBaseException('Missing required parameter: "databaseId"');
11977
+ }
11978
+ if (typeof tableId === "undefined") {
11979
+ throw new AppBaseException('Missing required parameter: "tableId"');
11980
+ }
11981
+ const apiPath = "/tablesdb/{databaseId}/tables/{tableId}".replace("{databaseId}", databaseId).replace("{tableId}", tableId);
11982
+ const payload = {};
11983
+ const uri = new URL(this.client.config.endpoint + apiPath);
11984
+ const apiHeaders = {};
11985
+ return this.client.call(
11986
+ "get",
11987
+ uri,
11988
+ apiHeaders,
11989
+ payload
11990
+ );
11991
+ }
11992
+ updateTable(paramsOrFirst, ...rest) {
11993
+ let params;
11994
+ if (paramsOrFirst && typeof paramsOrFirst === "object" && !Array.isArray(paramsOrFirst)) {
11995
+ params = paramsOrFirst || {};
11996
+ } else {
11997
+ params = {
11998
+ databaseId: paramsOrFirst,
11999
+ tableId: rest[0],
12000
+ name: rest[1],
12001
+ permissions: rest[2],
12002
+ rowSecurity: rest[3],
12003
+ enabled: rest[4],
12004
+ columns: rest[5],
12005
+ indexes: rest[6],
12006
+ skipOnEmpty: rest[7],
12007
+ comment: rest[8]
12008
+ };
12009
+ }
12010
+ const databaseId = params.databaseId;
12011
+ const tableId = params.tableId;
12012
+ const name = params.name;
12013
+ const permissions = params.permissions;
12014
+ const rowSecurity = params.rowSecurity;
12015
+ const enabled = params.enabled;
12016
+ const columns = params.columns;
12017
+ const indexes = params.indexes;
12018
+ const skipOnEmpty = params.skipOnEmpty;
12019
+ const comment = params.comment;
12020
+ if (typeof databaseId === "undefined") {
12021
+ throw new AppBaseException('Missing required parameter: "databaseId"');
12022
+ }
12023
+ if (typeof tableId === "undefined") {
12024
+ throw new AppBaseException('Missing required parameter: "tableId"');
12025
+ }
12026
+ const apiPath = "/tablesdb/{databaseId}/tables/{tableId}".replace("{databaseId}", databaseId).replace("{tableId}", tableId);
12027
+ const payload = {};
12028
+ if (typeof name !== "undefined") {
12029
+ payload["name"] = name;
12030
+ }
12031
+ if (typeof permissions !== "undefined") {
12032
+ payload["permissions"] = permissions;
12033
+ }
12034
+ if (typeof rowSecurity !== "undefined") {
12035
+ payload["rowSecurity"] = rowSecurity;
12036
+ }
12037
+ if (typeof enabled !== "undefined") {
12038
+ payload["enabled"] = enabled;
12039
+ }
12040
+ if (typeof columns !== "undefined") {
12041
+ payload["columns"] = columns;
12042
+ }
12043
+ if (typeof indexes !== "undefined") {
12044
+ payload["indexes"] = indexes;
12045
+ }
12046
+ if (typeof skipOnEmpty !== "undefined") {
12047
+ payload["skipOnEmpty"] = skipOnEmpty;
12048
+ }
12049
+ if (typeof comment !== "undefined") {
12050
+ payload["comment"] = comment;
12051
+ }
12052
+ const uri = new URL(this.client.config.endpoint + apiPath);
12053
+ const apiHeaders = {
12054
+ "content-type": "application/json"
12055
+ };
12056
+ return this.client.call(
12057
+ "put",
12058
+ uri,
12059
+ apiHeaders,
12060
+ payload
12061
+ );
12062
+ }
12063
+ deleteTable(paramsOrFirst, ...rest) {
12064
+ let params;
12065
+ if (paramsOrFirst && typeof paramsOrFirst === "object" && !Array.isArray(paramsOrFirst)) {
12066
+ params = paramsOrFirst || {};
12067
+ } else {
12068
+ params = {
12069
+ databaseId: paramsOrFirst,
12070
+ tableId: rest[0]
12071
+ };
12072
+ }
12073
+ const databaseId = params.databaseId;
12074
+ const tableId = params.tableId;
12075
+ if (typeof databaseId === "undefined") {
12076
+ throw new AppBaseException('Missing required parameter: "databaseId"');
12077
+ }
12078
+ if (typeof tableId === "undefined") {
12079
+ throw new AppBaseException('Missing required parameter: "tableId"');
12080
+ }
12081
+ const apiPath = "/tablesdb/{databaseId}/tables/{tableId}".replace("{databaseId}", databaseId).replace("{tableId}", tableId);
12082
+ const payload = {};
12083
+ const uri = new URL(this.client.config.endpoint + apiPath);
12084
+ const apiHeaders = {
12085
+ "content-type": "application/json"
12086
+ };
12087
+ return this.client.call(
12088
+ "delete",
12089
+ uri,
12090
+ apiHeaders,
12091
+ payload
12092
+ );
12093
+ }
12094
+ aggregateRows(paramsOrFirst, ...rest) {
12095
+ let params;
12096
+ if (paramsOrFirst && typeof paramsOrFirst === "object" && !Array.isArray(paramsOrFirst)) {
12097
+ params = paramsOrFirst || {};
12098
+ } else {
12099
+ params = {
12100
+ databaseId: paramsOrFirst,
12101
+ tableId: rest[0],
12102
+ select: rest[1],
12103
+ queries: rest[2],
12104
+ groupBy: rest[3],
12105
+ transactionId: rest[4]
12106
+ };
12107
+ }
12108
+ const databaseId = params.databaseId;
12109
+ const tableId = params.tableId;
12110
+ const select = params.select;
12111
+ const queries = params.queries;
12112
+ const groupBy = params.groupBy;
12113
+ const transactionId = params.transactionId;
12114
+ if (typeof databaseId === "undefined") {
12115
+ throw new AppBaseException('Missing required parameter: "databaseId"');
12116
+ }
12117
+ if (typeof tableId === "undefined") {
12118
+ throw new AppBaseException('Missing required parameter: "tableId"');
12119
+ }
12120
+ if (typeof select === "undefined") {
12121
+ throw new AppBaseException('Missing required parameter: "select"');
12122
+ }
12123
+ const apiPath = "/tablesdb/{databaseId}/tables/{tableId}/aggregation".replace("{databaseId}", databaseId).replace("{tableId}", tableId);
12124
+ const payload = {};
12125
+ if (typeof queries !== "undefined") {
12126
+ payload["queries"] = queries;
12127
+ }
12128
+ if (typeof groupBy !== "undefined") {
12129
+ payload["groupBy"] = groupBy;
12130
+ }
12131
+ if (typeof select !== "undefined") {
12132
+ payload["select"] = select;
12133
+ }
12134
+ if (typeof transactionId !== "undefined") {
12135
+ payload["transactionId"] = transactionId;
12136
+ }
12137
+ const uri = new URL(this.client.config.endpoint + apiPath);
12138
+ const apiHeaders = {};
12139
+ return this.client.call(
12140
+ "get",
12141
+ uri,
12142
+ apiHeaders,
12143
+ payload
12144
+ );
12145
+ }
12146
+ listColumns(paramsOrFirst, ...rest) {
12147
+ let params;
12148
+ if (paramsOrFirst && typeof paramsOrFirst === "object" && !Array.isArray(paramsOrFirst)) {
12149
+ params = paramsOrFirst || {};
12150
+ } else {
12151
+ params = {
12152
+ databaseId: paramsOrFirst,
12153
+ tableId: rest[0],
12154
+ queries: rest[1],
12155
+ total: rest[2]
12156
+ };
12157
+ }
12158
+ const databaseId = params.databaseId;
12159
+ const tableId = params.tableId;
12160
+ const queries = params.queries;
12161
+ const total = params.total;
12162
+ if (typeof databaseId === "undefined") {
12163
+ throw new AppBaseException('Missing required parameter: "databaseId"');
12164
+ }
12165
+ if (typeof tableId === "undefined") {
12166
+ throw new AppBaseException('Missing required parameter: "tableId"');
12167
+ }
12168
+ const apiPath = "/tablesdb/{databaseId}/tables/{tableId}/columns".replace("{databaseId}", databaseId).replace("{tableId}", tableId);
12169
+ const payload = {};
12170
+ if (typeof queries !== "undefined") {
12171
+ payload["queries"] = queries;
12172
+ }
12173
+ if (typeof total !== "undefined") {
12174
+ payload["total"] = total;
12175
+ }
12176
+ const uri = new URL(this.client.config.endpoint + apiPath);
12177
+ const apiHeaders = {};
12178
+ return this.client.call(
12179
+ "get",
12180
+ uri,
12181
+ apiHeaders,
12182
+ payload
12183
+ );
12184
+ }
12185
+ createBooleanColumn(paramsOrFirst, ...rest) {
12186
+ let params;
12187
+ if (paramsOrFirst && typeof paramsOrFirst === "object" && !Array.isArray(paramsOrFirst)) {
12188
+ params = paramsOrFirst || {};
12189
+ } else {
12190
+ params = {
12191
+ databaseId: paramsOrFirst,
12192
+ tableId: rest[0],
12193
+ key: rest[1],
12194
+ required: rest[2],
12195
+ xdefault: rest[3],
12196
+ array: rest[4]
12197
+ };
12198
+ }
12199
+ const databaseId = params.databaseId;
12200
+ const tableId = params.tableId;
12201
+ const key = params.key;
12202
+ const required = params.required;
12203
+ const xdefault = params.xdefault;
12204
+ const array = params.array;
12205
+ if (typeof databaseId === "undefined") {
12206
+ throw new AppBaseException('Missing required parameter: "databaseId"');
12207
+ }
12208
+ if (typeof tableId === "undefined") {
12209
+ throw new AppBaseException('Missing required parameter: "tableId"');
12210
+ }
12211
+ if (typeof key === "undefined") {
12212
+ throw new AppBaseException('Missing required parameter: "key"');
12213
+ }
12214
+ if (typeof required === "undefined") {
12215
+ throw new AppBaseException('Missing required parameter: "required"');
12216
+ }
12217
+ const apiPath = "/tablesdb/{databaseId}/tables/{tableId}/columns/boolean".replace("{databaseId}", databaseId).replace("{tableId}", tableId);
12218
+ const payload = {};
12219
+ if (typeof key !== "undefined") {
12220
+ payload["key"] = key;
12221
+ }
12222
+ if (typeof required !== "undefined") {
12223
+ payload["required"] = required;
12224
+ }
12225
+ if (typeof xdefault !== "undefined") {
12226
+ payload["default"] = xdefault;
12227
+ }
12228
+ if (typeof array !== "undefined") {
12229
+ payload["array"] = array;
12230
+ }
12231
+ const uri = new URL(this.client.config.endpoint + apiPath);
12232
+ const apiHeaders = {
12233
+ "content-type": "application/json"
12234
+ };
12235
+ return this.client.call(
12236
+ "post",
12237
+ uri,
12238
+ apiHeaders,
12239
+ payload
12240
+ );
12241
+ }
12242
+ updateBooleanColumn(paramsOrFirst, ...rest) {
12243
+ let params;
12244
+ if (paramsOrFirst && typeof paramsOrFirst === "object" && !Array.isArray(paramsOrFirst)) {
12245
+ params = paramsOrFirst || {};
12246
+ } else {
12247
+ params = {
12248
+ databaseId: paramsOrFirst,
12249
+ tableId: rest[0],
12250
+ key: rest[1],
12251
+ required: rest[2],
12252
+ xdefault: rest[3],
12253
+ newKey: rest[4]
12254
+ };
12255
+ }
12256
+ const databaseId = params.databaseId;
12257
+ const tableId = params.tableId;
12258
+ const key = params.key;
12259
+ const required = params.required;
12260
+ const xdefault = params.xdefault;
12261
+ const newKey = params.newKey;
12262
+ if (typeof databaseId === "undefined") {
12263
+ throw new AppBaseException('Missing required parameter: "databaseId"');
12264
+ }
12265
+ if (typeof tableId === "undefined") {
12266
+ throw new AppBaseException('Missing required parameter: "tableId"');
12267
+ }
12268
+ if (typeof key === "undefined") {
12269
+ throw new AppBaseException('Missing required parameter: "key"');
12270
+ }
12271
+ if (typeof required === "undefined") {
12272
+ throw new AppBaseException('Missing required parameter: "required"');
12273
+ }
12274
+ if (typeof xdefault === "undefined") {
12275
+ throw new AppBaseException('Missing required parameter: "xdefault"');
12276
+ }
12277
+ const apiPath = "/tablesdb/{databaseId}/tables/{tableId}/columns/boolean/{key}".replace("{databaseId}", databaseId).replace("{tableId}", tableId).replace("{key}", key);
12278
+ const payload = {};
12279
+ if (typeof required !== "undefined") {
12280
+ payload["required"] = required;
12281
+ }
12282
+ if (typeof xdefault !== "undefined") {
12283
+ payload["default"] = xdefault;
12284
+ }
12285
+ if (typeof newKey !== "undefined") {
12286
+ payload["newKey"] = newKey;
12287
+ }
12288
+ const uri = new URL(this.client.config.endpoint + apiPath);
12289
+ const apiHeaders = {
12290
+ "content-type": "application/json"
12291
+ };
12292
+ return this.client.call(
12293
+ "patch",
12294
+ uri,
12295
+ apiHeaders,
12296
+ payload
12297
+ );
12298
+ }
12299
+ createDatetimeColumn(paramsOrFirst, ...rest) {
12300
+ let params;
12301
+ if (paramsOrFirst && typeof paramsOrFirst === "object" && !Array.isArray(paramsOrFirst)) {
12302
+ params = paramsOrFirst || {};
12303
+ } else {
12304
+ params = {
12305
+ databaseId: paramsOrFirst,
12306
+ tableId: rest[0],
12307
+ key: rest[1],
12308
+ required: rest[2],
12309
+ xdefault: rest[3],
12310
+ array: rest[4]
12311
+ };
12312
+ }
12313
+ const databaseId = params.databaseId;
12314
+ const tableId = params.tableId;
12315
+ const key = params.key;
12316
+ const required = params.required;
12317
+ const xdefault = params.xdefault;
12318
+ const array = params.array;
12319
+ if (typeof databaseId === "undefined") {
12320
+ throw new AppBaseException('Missing required parameter: "databaseId"');
12321
+ }
12322
+ if (typeof tableId === "undefined") {
12323
+ throw new AppBaseException('Missing required parameter: "tableId"');
12324
+ }
12325
+ if (typeof key === "undefined") {
12326
+ throw new AppBaseException('Missing required parameter: "key"');
12327
+ }
12328
+ if (typeof required === "undefined") {
12329
+ throw new AppBaseException('Missing required parameter: "required"');
12330
+ }
12331
+ const apiPath = "/tablesdb/{databaseId}/tables/{tableId}/columns/datetime".replace("{databaseId}", databaseId).replace("{tableId}", tableId);
12332
+ const payload = {};
12333
+ if (typeof key !== "undefined") {
12334
+ payload["key"] = key;
12335
+ }
12336
+ if (typeof required !== "undefined") {
12337
+ payload["required"] = required;
12338
+ }
12339
+ if (typeof xdefault !== "undefined") {
12340
+ payload["default"] = xdefault;
12341
+ }
12342
+ if (typeof array !== "undefined") {
12343
+ payload["array"] = array;
12344
+ }
12345
+ const uri = new URL(this.client.config.endpoint + apiPath);
12346
+ const apiHeaders = {
12347
+ "content-type": "application/json"
12348
+ };
12349
+ return this.client.call(
12350
+ "post",
12351
+ uri,
12352
+ apiHeaders,
12353
+ payload
12354
+ );
12355
+ }
12356
+ updateDatetimeColumn(paramsOrFirst, ...rest) {
12357
+ let params;
12358
+ if (paramsOrFirst && typeof paramsOrFirst === "object" && !Array.isArray(paramsOrFirst)) {
12359
+ params = paramsOrFirst || {};
12360
+ } else {
12361
+ params = {
12362
+ databaseId: paramsOrFirst,
12363
+ tableId: rest[0],
12364
+ key: rest[1],
12365
+ required: rest[2],
12366
+ xdefault: rest[3],
12367
+ newKey: rest[4]
12368
+ };
12369
+ }
12370
+ const databaseId = params.databaseId;
12371
+ const tableId = params.tableId;
12372
+ const key = params.key;
12373
+ const required = params.required;
12374
+ const xdefault = params.xdefault;
12375
+ const newKey = params.newKey;
12376
+ if (typeof databaseId === "undefined") {
12377
+ throw new AppBaseException('Missing required parameter: "databaseId"');
12378
+ }
12379
+ if (typeof tableId === "undefined") {
12380
+ throw new AppBaseException('Missing required parameter: "tableId"');
12381
+ }
12382
+ if (typeof key === "undefined") {
12383
+ throw new AppBaseException('Missing required parameter: "key"');
12384
+ }
12385
+ if (typeof required === "undefined") {
12386
+ throw new AppBaseException('Missing required parameter: "required"');
12387
+ }
12388
+ if (typeof xdefault === "undefined") {
12389
+ throw new AppBaseException('Missing required parameter: "xdefault"');
12390
+ }
12391
+ const apiPath = "/tablesdb/{databaseId}/tables/{tableId}/columns/datetime/{key}".replace("{databaseId}", databaseId).replace("{tableId}", tableId).replace("{key}", key);
12392
+ const payload = {};
12393
+ if (typeof required !== "undefined") {
12394
+ payload["required"] = required;
12395
+ }
12396
+ if (typeof xdefault !== "undefined") {
12397
+ payload["default"] = xdefault;
12398
+ }
12399
+ if (typeof newKey !== "undefined") {
12400
+ payload["newKey"] = newKey;
12401
+ }
12402
+ const uri = new URL(this.client.config.endpoint + apiPath);
12403
+ const apiHeaders = {
12404
+ "content-type": "application/json"
12405
+ };
12406
+ return this.client.call(
12407
+ "patch",
12408
+ uri,
12409
+ apiHeaders,
12410
+ payload
12411
+ );
12412
+ }
12413
+ createEmailColumn(paramsOrFirst, ...rest) {
12414
+ let params;
12415
+ if (paramsOrFirst && typeof paramsOrFirst === "object" && !Array.isArray(paramsOrFirst)) {
12416
+ params = paramsOrFirst || {};
12417
+ } else {
12418
+ params = {
12419
+ databaseId: paramsOrFirst,
12420
+ tableId: rest[0],
12421
+ key: rest[1],
12422
+ required: rest[2],
12423
+ xdefault: rest[3],
12424
+ array: rest[4]
12425
+ };
12426
+ }
12427
+ const databaseId = params.databaseId;
12428
+ const tableId = params.tableId;
12429
+ const key = params.key;
12430
+ const required = params.required;
12431
+ const xdefault = params.xdefault;
12432
+ const array = params.array;
12433
+ if (typeof databaseId === "undefined") {
12434
+ throw new AppBaseException('Missing required parameter: "databaseId"');
12435
+ }
12436
+ if (typeof tableId === "undefined") {
12437
+ throw new AppBaseException('Missing required parameter: "tableId"');
12438
+ }
12439
+ if (typeof key === "undefined") {
12440
+ throw new AppBaseException('Missing required parameter: "key"');
12441
+ }
12442
+ if (typeof required === "undefined") {
12443
+ throw new AppBaseException('Missing required parameter: "required"');
12444
+ }
12445
+ const apiPath = "/tablesdb/{databaseId}/tables/{tableId}/columns/email".replace("{databaseId}", databaseId).replace("{tableId}", tableId);
12446
+ const payload = {};
12447
+ if (typeof key !== "undefined") {
12448
+ payload["key"] = key;
12449
+ }
12450
+ if (typeof required !== "undefined") {
12451
+ payload["required"] = required;
12452
+ }
12453
+ if (typeof xdefault !== "undefined") {
12454
+ payload["default"] = xdefault;
12455
+ }
12456
+ if (typeof array !== "undefined") {
12457
+ payload["array"] = array;
12458
+ }
12459
+ const uri = new URL(this.client.config.endpoint + apiPath);
12460
+ const apiHeaders = {
12461
+ "content-type": "application/json"
12462
+ };
12463
+ return this.client.call(
12464
+ "post",
12465
+ uri,
12466
+ apiHeaders,
12467
+ payload
12468
+ );
12469
+ }
12470
+ updateEmailColumn(paramsOrFirst, ...rest) {
12471
+ let params;
12472
+ if (paramsOrFirst && typeof paramsOrFirst === "object" && !Array.isArray(paramsOrFirst)) {
12473
+ params = paramsOrFirst || {};
12474
+ } else {
12475
+ params = {
12476
+ databaseId: paramsOrFirst,
12477
+ tableId: rest[0],
12478
+ key: rest[1],
12479
+ required: rest[2],
12480
+ xdefault: rest[3],
12481
+ newKey: rest[4]
12482
+ };
12483
+ }
12484
+ const databaseId = params.databaseId;
12485
+ const tableId = params.tableId;
12486
+ const key = params.key;
12487
+ const required = params.required;
12488
+ const xdefault = params.xdefault;
12489
+ const newKey = params.newKey;
12490
+ if (typeof databaseId === "undefined") {
12491
+ throw new AppBaseException('Missing required parameter: "databaseId"');
12492
+ }
12493
+ if (typeof tableId === "undefined") {
12494
+ throw new AppBaseException('Missing required parameter: "tableId"');
12495
+ }
12496
+ if (typeof key === "undefined") {
12497
+ throw new AppBaseException('Missing required parameter: "key"');
12498
+ }
12499
+ if (typeof required === "undefined") {
12500
+ throw new AppBaseException('Missing required parameter: "required"');
12501
+ }
12502
+ if (typeof xdefault === "undefined") {
12503
+ throw new AppBaseException('Missing required parameter: "xdefault"');
12504
+ }
12505
+ const apiPath = "/tablesdb/{databaseId}/tables/{tableId}/columns/email/{key}".replace("{databaseId}", databaseId).replace("{tableId}", tableId).replace("{key}", key);
12506
+ const payload = {};
12507
+ if (typeof required !== "undefined") {
12508
+ payload["required"] = required;
12509
+ }
12510
+ if (typeof xdefault !== "undefined") {
12511
+ payload["default"] = xdefault;
12512
+ }
12513
+ if (typeof newKey !== "undefined") {
12514
+ payload["newKey"] = newKey;
12515
+ }
12516
+ const uri = new URL(this.client.config.endpoint + apiPath);
12517
+ const apiHeaders = {
12518
+ "content-type": "application/json"
12519
+ };
12520
+ return this.client.call(
12521
+ "patch",
12522
+ uri,
12523
+ apiHeaders,
12524
+ payload
12525
+ );
12526
+ }
12527
+ createEnumColumn(paramsOrFirst, ...rest) {
12528
+ let params;
12529
+ if (paramsOrFirst && typeof paramsOrFirst === "object" && !Array.isArray(paramsOrFirst)) {
12530
+ params = paramsOrFirst || {};
12531
+ } else {
12532
+ params = {
12533
+ databaseId: paramsOrFirst,
12534
+ tableId: rest[0],
12535
+ key: rest[1],
12536
+ elements: rest[2],
12537
+ required: rest[3],
12538
+ xdefault: rest[4],
12539
+ array: rest[5]
12540
+ };
12541
+ }
12542
+ const databaseId = params.databaseId;
12543
+ const tableId = params.tableId;
12544
+ const key = params.key;
12545
+ const elements = params.elements;
12546
+ const required = params.required;
12547
+ const xdefault = params.xdefault;
12548
+ const array = params.array;
12549
+ if (typeof databaseId === "undefined") {
12550
+ throw new AppBaseException('Missing required parameter: "databaseId"');
12551
+ }
12552
+ if (typeof tableId === "undefined") {
12553
+ throw new AppBaseException('Missing required parameter: "tableId"');
12554
+ }
12555
+ if (typeof key === "undefined") {
12556
+ throw new AppBaseException('Missing required parameter: "key"');
12557
+ }
12558
+ if (typeof elements === "undefined") {
12559
+ throw new AppBaseException('Missing required parameter: "elements"');
12560
+ }
12561
+ if (typeof required === "undefined") {
12562
+ throw new AppBaseException('Missing required parameter: "required"');
12563
+ }
12564
+ const apiPath = "/tablesdb/{databaseId}/tables/{tableId}/columns/enum".replace("{databaseId}", databaseId).replace("{tableId}", tableId);
12565
+ const payload = {};
12566
+ if (typeof key !== "undefined") {
12567
+ payload["key"] = key;
12568
+ }
12569
+ if (typeof elements !== "undefined") {
12570
+ payload["elements"] = elements;
12571
+ }
12572
+ if (typeof required !== "undefined") {
12573
+ payload["required"] = required;
12574
+ }
12575
+ if (typeof xdefault !== "undefined") {
12576
+ payload["default"] = xdefault;
12577
+ }
12578
+ if (typeof array !== "undefined") {
12579
+ payload["array"] = array;
12580
+ }
12581
+ const uri = new URL(this.client.config.endpoint + apiPath);
12582
+ const apiHeaders = {
12583
+ "content-type": "application/json"
12584
+ };
12585
+ return this.client.call(
12586
+ "post",
12587
+ uri,
12588
+ apiHeaders,
12589
+ payload
12590
+ );
12591
+ }
12592
+ updateEnumColumn(paramsOrFirst, ...rest) {
12593
+ let params;
12594
+ if (paramsOrFirst && typeof paramsOrFirst === "object" && !Array.isArray(paramsOrFirst)) {
12595
+ params = paramsOrFirst || {};
12596
+ } else {
12597
+ params = {
12598
+ databaseId: paramsOrFirst,
12599
+ tableId: rest[0],
12600
+ key: rest[1],
12601
+ elements: rest[2],
12602
+ required: rest[3],
12603
+ xdefault: rest[4],
12604
+ newKey: rest[5]
12605
+ };
12606
+ }
12607
+ const databaseId = params.databaseId;
12608
+ const tableId = params.tableId;
12609
+ const key = params.key;
12610
+ const elements = params.elements;
12611
+ const required = params.required;
12612
+ const xdefault = params.xdefault;
12613
+ const newKey = params.newKey;
12614
+ if (typeof databaseId === "undefined") {
12615
+ throw new AppBaseException('Missing required parameter: "databaseId"');
12616
+ }
12617
+ if (typeof tableId === "undefined") {
12618
+ throw new AppBaseException('Missing required parameter: "tableId"');
12619
+ }
12620
+ if (typeof key === "undefined") {
12621
+ throw new AppBaseException('Missing required parameter: "key"');
12622
+ }
12623
+ if (typeof elements === "undefined") {
12624
+ throw new AppBaseException('Missing required parameter: "elements"');
12625
+ }
12626
+ if (typeof required === "undefined") {
12627
+ throw new AppBaseException('Missing required parameter: "required"');
12628
+ }
12629
+ if (typeof xdefault === "undefined") {
12630
+ throw new AppBaseException('Missing required parameter: "xdefault"');
12631
+ }
12632
+ const apiPath = "/tablesdb/{databaseId}/tables/{tableId}/columns/enum/{key}".replace("{databaseId}", databaseId).replace("{tableId}", tableId).replace("{key}", key);
12633
+ const payload = {};
12634
+ if (typeof elements !== "undefined") {
12635
+ payload["elements"] = elements;
12636
+ }
12637
+ if (typeof required !== "undefined") {
12638
+ payload["required"] = required;
12639
+ }
12640
+ if (typeof xdefault !== "undefined") {
12641
+ payload["default"] = xdefault;
12642
+ }
12643
+ if (typeof newKey !== "undefined") {
12644
+ payload["newKey"] = newKey;
12645
+ }
12646
+ const uri = new URL(this.client.config.endpoint + apiPath);
12647
+ const apiHeaders = {
12648
+ "content-type": "application/json"
12649
+ };
12650
+ return this.client.call(
12651
+ "patch",
12652
+ uri,
12653
+ apiHeaders,
12654
+ payload
12655
+ );
12656
+ }
12657
+ createFloatColumn(paramsOrFirst, ...rest) {
12658
+ let params;
12659
+ if (paramsOrFirst && typeof paramsOrFirst === "object" && !Array.isArray(paramsOrFirst)) {
12660
+ params = paramsOrFirst || {};
12661
+ } else {
12662
+ params = {
12663
+ databaseId: paramsOrFirst,
12664
+ tableId: rest[0],
12665
+ key: rest[1],
12666
+ required: rest[2],
12667
+ min: rest[3],
12668
+ max: rest[4],
12669
+ xdefault: rest[5],
12670
+ array: rest[6]
12671
+ };
12672
+ }
12673
+ const databaseId = params.databaseId;
12674
+ const tableId = params.tableId;
12675
+ const key = params.key;
12676
+ const required = params.required;
12677
+ const min = params.min;
12678
+ const max = params.max;
12679
+ const xdefault = params.xdefault;
12680
+ const array = params.array;
12681
+ if (typeof databaseId === "undefined") {
12682
+ throw new AppBaseException('Missing required parameter: "databaseId"');
12683
+ }
12684
+ if (typeof tableId === "undefined") {
12685
+ throw new AppBaseException('Missing required parameter: "tableId"');
12686
+ }
12687
+ if (typeof key === "undefined") {
12688
+ throw new AppBaseException('Missing required parameter: "key"');
12689
+ }
12690
+ if (typeof required === "undefined") {
12691
+ throw new AppBaseException('Missing required parameter: "required"');
12692
+ }
12693
+ const apiPath = "/tablesdb/{databaseId}/tables/{tableId}/columns/float".replace("{databaseId}", databaseId).replace("{tableId}", tableId);
12694
+ const payload = {};
12695
+ if (typeof key !== "undefined") {
12696
+ payload["key"] = key;
12697
+ }
12698
+ if (typeof required !== "undefined") {
12699
+ payload["required"] = required;
12700
+ }
12701
+ if (typeof min !== "undefined") {
12702
+ payload["min"] = min;
12703
+ }
12704
+ if (typeof max !== "undefined") {
12705
+ payload["max"] = max;
12706
+ }
12707
+ if (typeof xdefault !== "undefined") {
12708
+ payload["default"] = xdefault;
12709
+ }
12710
+ if (typeof array !== "undefined") {
12711
+ payload["array"] = array;
12712
+ }
12713
+ const uri = new URL(this.client.config.endpoint + apiPath);
12714
+ const apiHeaders = {
12715
+ "content-type": "application/json"
12716
+ };
12717
+ return this.client.call(
12718
+ "post",
12719
+ uri,
12720
+ apiHeaders,
12721
+ payload
12722
+ );
12723
+ }
12724
+ updateFloatColumn(paramsOrFirst, ...rest) {
12725
+ let params;
12726
+ if (paramsOrFirst && typeof paramsOrFirst === "object" && !Array.isArray(paramsOrFirst)) {
12727
+ params = paramsOrFirst || {};
12728
+ } else {
12729
+ params = {
12730
+ databaseId: paramsOrFirst,
12731
+ tableId: rest[0],
12732
+ key: rest[1],
12733
+ required: rest[2],
12734
+ xdefault: rest[3],
12735
+ min: rest[4],
12736
+ max: rest[5],
12737
+ newKey: rest[6]
12738
+ };
12739
+ }
12740
+ const databaseId = params.databaseId;
12741
+ const tableId = params.tableId;
12742
+ const key = params.key;
12743
+ const required = params.required;
12744
+ const xdefault = params.xdefault;
12745
+ const min = params.min;
12746
+ const max = params.max;
12747
+ const newKey = params.newKey;
12748
+ if (typeof databaseId === "undefined") {
12749
+ throw new AppBaseException('Missing required parameter: "databaseId"');
12750
+ }
12751
+ if (typeof tableId === "undefined") {
12752
+ throw new AppBaseException('Missing required parameter: "tableId"');
12753
+ }
12754
+ if (typeof key === "undefined") {
12755
+ throw new AppBaseException('Missing required parameter: "key"');
12756
+ }
12757
+ if (typeof required === "undefined") {
12758
+ throw new AppBaseException('Missing required parameter: "required"');
12759
+ }
12760
+ if (typeof xdefault === "undefined") {
12761
+ throw new AppBaseException('Missing required parameter: "xdefault"');
12762
+ }
12763
+ const apiPath = "/tablesdb/{databaseId}/tables/{tableId}/columns/float/{key}".replace("{databaseId}", databaseId).replace("{tableId}", tableId).replace("{key}", key);
12764
+ const payload = {};
12765
+ if (typeof required !== "undefined") {
12766
+ payload["required"] = required;
12767
+ }
12768
+ if (typeof min !== "undefined") {
12769
+ payload["min"] = min;
12770
+ }
12771
+ if (typeof max !== "undefined") {
12772
+ payload["max"] = max;
12773
+ }
12774
+ if (typeof xdefault !== "undefined") {
12775
+ payload["default"] = xdefault;
12776
+ }
12777
+ if (typeof newKey !== "undefined") {
12778
+ payload["newKey"] = newKey;
12779
+ }
12780
+ const uri = new URL(this.client.config.endpoint + apiPath);
12781
+ const apiHeaders = {
12782
+ "content-type": "application/json"
12783
+ };
12784
+ return this.client.call(
12785
+ "patch",
12786
+ uri,
12787
+ apiHeaders,
12788
+ payload
12789
+ );
12790
+ }
12791
+ createIntegerColumn(paramsOrFirst, ...rest) {
12792
+ let params;
12793
+ if (paramsOrFirst && typeof paramsOrFirst === "object" && !Array.isArray(paramsOrFirst)) {
12794
+ params = paramsOrFirst || {};
12795
+ } else {
12796
+ params = {
12797
+ databaseId: paramsOrFirst,
12798
+ tableId: rest[0],
12799
+ key: rest[1],
12800
+ required: rest[2],
12801
+ min: rest[3],
12802
+ max: rest[4],
12803
+ xdefault: rest[5],
12804
+ array: rest[6]
12805
+ };
12806
+ }
12807
+ const databaseId = params.databaseId;
12808
+ const tableId = params.tableId;
12809
+ const key = params.key;
12810
+ const required = params.required;
12811
+ const min = params.min;
12812
+ const max = params.max;
12813
+ const xdefault = params.xdefault;
12814
+ const array = params.array;
12815
+ if (typeof databaseId === "undefined") {
12816
+ throw new AppBaseException('Missing required parameter: "databaseId"');
12817
+ }
12818
+ if (typeof tableId === "undefined") {
12819
+ throw new AppBaseException('Missing required parameter: "tableId"');
12820
+ }
12821
+ if (typeof key === "undefined") {
12822
+ throw new AppBaseException('Missing required parameter: "key"');
12823
+ }
12824
+ if (typeof required === "undefined") {
12825
+ throw new AppBaseException('Missing required parameter: "required"');
12826
+ }
12827
+ const apiPath = "/tablesdb/{databaseId}/tables/{tableId}/columns/integer".replace("{databaseId}", databaseId).replace("{tableId}", tableId);
12828
+ const payload = {};
12829
+ if (typeof key !== "undefined") {
12830
+ payload["key"] = key;
12831
+ }
12832
+ if (typeof required !== "undefined") {
12833
+ payload["required"] = required;
12834
+ }
12835
+ if (typeof min !== "undefined") {
12836
+ payload["min"] = min;
12837
+ }
12838
+ if (typeof max !== "undefined") {
12839
+ payload["max"] = max;
12840
+ }
12841
+ if (typeof xdefault !== "undefined") {
12842
+ payload["default"] = xdefault;
12843
+ }
12844
+ if (typeof array !== "undefined") {
12845
+ payload["array"] = array;
12846
+ }
12847
+ const uri = new URL(this.client.config.endpoint + apiPath);
12848
+ const apiHeaders = {
12849
+ "content-type": "application/json"
12850
+ };
12851
+ return this.client.call(
12852
+ "post",
12853
+ uri,
12854
+ apiHeaders,
12855
+ payload
12856
+ );
12857
+ }
12858
+ updateIntegerColumn(paramsOrFirst, ...rest) {
12859
+ let params;
12860
+ if (paramsOrFirst && typeof paramsOrFirst === "object" && !Array.isArray(paramsOrFirst)) {
12861
+ params = paramsOrFirst || {};
12862
+ } else {
12863
+ params = {
12864
+ databaseId: paramsOrFirst,
12865
+ tableId: rest[0],
12866
+ key: rest[1],
12867
+ required: rest[2],
12868
+ xdefault: rest[3],
12869
+ min: rest[4],
12870
+ max: rest[5],
12871
+ newKey: rest[6]
12872
+ };
12873
+ }
12874
+ const databaseId = params.databaseId;
12875
+ const tableId = params.tableId;
12876
+ const key = params.key;
12877
+ const required = params.required;
12878
+ const xdefault = params.xdefault;
12879
+ const min = params.min;
12880
+ const max = params.max;
12881
+ const newKey = params.newKey;
12882
+ if (typeof databaseId === "undefined") {
12883
+ throw new AppBaseException('Missing required parameter: "databaseId"');
12884
+ }
12885
+ if (typeof tableId === "undefined") {
12886
+ throw new AppBaseException('Missing required parameter: "tableId"');
12887
+ }
12888
+ if (typeof key === "undefined") {
12889
+ throw new AppBaseException('Missing required parameter: "key"');
12890
+ }
12891
+ if (typeof required === "undefined") {
12892
+ throw new AppBaseException('Missing required parameter: "required"');
12893
+ }
12894
+ if (typeof xdefault === "undefined") {
12895
+ throw new AppBaseException('Missing required parameter: "xdefault"');
12896
+ }
12897
+ const apiPath = "/tablesdb/{databaseId}/tables/{tableId}/columns/integer/{key}".replace("{databaseId}", databaseId).replace("{tableId}", tableId).replace("{key}", key);
12898
+ const payload = {};
12899
+ if (typeof required !== "undefined") {
12900
+ payload["required"] = required;
12901
+ }
12902
+ if (typeof min !== "undefined") {
12903
+ payload["min"] = min;
12904
+ }
12905
+ if (typeof max !== "undefined") {
12906
+ payload["max"] = max;
12907
+ }
12908
+ if (typeof xdefault !== "undefined") {
12909
+ payload["default"] = xdefault;
12910
+ }
12911
+ if (typeof newKey !== "undefined") {
12912
+ payload["newKey"] = newKey;
12913
+ }
12914
+ const uri = new URL(this.client.config.endpoint + apiPath);
12915
+ const apiHeaders = {
12916
+ "content-type": "application/json"
12917
+ };
12918
+ return this.client.call(
12919
+ "patch",
12920
+ uri,
12921
+ apiHeaders,
12922
+ payload
12923
+ );
12924
+ }
12925
+ createIpColumn(paramsOrFirst, ...rest) {
12926
+ let params;
12927
+ if (paramsOrFirst && typeof paramsOrFirst === "object" && !Array.isArray(paramsOrFirst)) {
12928
+ params = paramsOrFirst || {};
12929
+ } else {
12930
+ params = {
12931
+ databaseId: paramsOrFirst,
12932
+ tableId: rest[0],
12933
+ key: rest[1],
12934
+ required: rest[2],
12935
+ xdefault: rest[3],
12936
+ array: rest[4]
12937
+ };
12938
+ }
12939
+ const databaseId = params.databaseId;
12940
+ const tableId = params.tableId;
12941
+ const key = params.key;
12942
+ const required = params.required;
12943
+ const xdefault = params.xdefault;
12944
+ const array = params.array;
12945
+ if (typeof databaseId === "undefined") {
12946
+ throw new AppBaseException('Missing required parameter: "databaseId"');
12947
+ }
12948
+ if (typeof tableId === "undefined") {
12949
+ throw new AppBaseException('Missing required parameter: "tableId"');
12950
+ }
12951
+ if (typeof key === "undefined") {
12952
+ throw new AppBaseException('Missing required parameter: "key"');
12953
+ }
12954
+ if (typeof required === "undefined") {
12955
+ throw new AppBaseException('Missing required parameter: "required"');
12956
+ }
12957
+ const apiPath = "/tablesdb/{databaseId}/tables/{tableId}/columns/ip".replace("{databaseId}", databaseId).replace("{tableId}", tableId);
12958
+ const payload = {};
12959
+ if (typeof key !== "undefined") {
12960
+ payload["key"] = key;
12961
+ }
12962
+ if (typeof required !== "undefined") {
12963
+ payload["required"] = required;
12964
+ }
12965
+ if (typeof xdefault !== "undefined") {
12966
+ payload["default"] = xdefault;
12967
+ }
12968
+ if (typeof array !== "undefined") {
12969
+ payload["array"] = array;
12970
+ }
12971
+ const uri = new URL(this.client.config.endpoint + apiPath);
12972
+ const apiHeaders = {
12973
+ "content-type": "application/json"
12974
+ };
12975
+ return this.client.call(
12976
+ "post",
12977
+ uri,
12978
+ apiHeaders,
12979
+ payload
12980
+ );
12981
+ }
12982
+ updateIpColumn(paramsOrFirst, ...rest) {
12983
+ let params;
12984
+ if (paramsOrFirst && typeof paramsOrFirst === "object" && !Array.isArray(paramsOrFirst)) {
12985
+ params = paramsOrFirst || {};
12986
+ } else {
12987
+ params = {
12988
+ databaseId: paramsOrFirst,
12989
+ tableId: rest[0],
12990
+ key: rest[1],
12991
+ required: rest[2],
12992
+ xdefault: rest[3],
12993
+ newKey: rest[4]
12994
+ };
12995
+ }
12996
+ const databaseId = params.databaseId;
12997
+ const tableId = params.tableId;
12998
+ const key = params.key;
12999
+ const required = params.required;
13000
+ const xdefault = params.xdefault;
13001
+ const newKey = params.newKey;
13002
+ if (typeof databaseId === "undefined") {
13003
+ throw new AppBaseException('Missing required parameter: "databaseId"');
13004
+ }
13005
+ if (typeof tableId === "undefined") {
13006
+ throw new AppBaseException('Missing required parameter: "tableId"');
13007
+ }
13008
+ if (typeof key === "undefined") {
13009
+ throw new AppBaseException('Missing required parameter: "key"');
13010
+ }
13011
+ if (typeof required === "undefined") {
13012
+ throw new AppBaseException('Missing required parameter: "required"');
13013
+ }
13014
+ if (typeof xdefault === "undefined") {
13015
+ throw new AppBaseException('Missing required parameter: "xdefault"');
13016
+ }
13017
+ const apiPath = "/tablesdb/{databaseId}/tables/{tableId}/columns/ip/{key}".replace("{databaseId}", databaseId).replace("{tableId}", tableId).replace("{key}", key);
13018
+ const payload = {};
13019
+ if (typeof required !== "undefined") {
13020
+ payload["required"] = required;
13021
+ }
13022
+ if (typeof xdefault !== "undefined") {
13023
+ payload["default"] = xdefault;
13024
+ }
13025
+ if (typeof newKey !== "undefined") {
13026
+ payload["newKey"] = newKey;
13027
+ }
13028
+ const uri = new URL(this.client.config.endpoint + apiPath);
13029
+ const apiHeaders = {
13030
+ "content-type": "application/json"
13031
+ };
13032
+ return this.client.call(
13033
+ "patch",
13034
+ uri,
13035
+ apiHeaders,
13036
+ payload
13037
+ );
13038
+ }
13039
+ createLineColumn(paramsOrFirst, ...rest) {
13040
+ let params;
13041
+ if (paramsOrFirst && typeof paramsOrFirst === "object" && !Array.isArray(paramsOrFirst)) {
13042
+ params = paramsOrFirst || {};
13043
+ } else {
13044
+ params = {
13045
+ databaseId: paramsOrFirst,
13046
+ tableId: rest[0],
13047
+ key: rest[1],
13048
+ required: rest[2],
13049
+ xdefault: rest[3]
13050
+ };
13051
+ }
13052
+ const databaseId = params.databaseId;
13053
+ const tableId = params.tableId;
13054
+ const key = params.key;
13055
+ const required = params.required;
13056
+ const xdefault = params.xdefault;
13057
+ if (typeof databaseId === "undefined") {
13058
+ throw new AppBaseException('Missing required parameter: "databaseId"');
13059
+ }
13060
+ if (typeof tableId === "undefined") {
13061
+ throw new AppBaseException('Missing required parameter: "tableId"');
13062
+ }
13063
+ if (typeof key === "undefined") {
13064
+ throw new AppBaseException('Missing required parameter: "key"');
13065
+ }
13066
+ if (typeof required === "undefined") {
13067
+ throw new AppBaseException('Missing required parameter: "required"');
13068
+ }
13069
+ const apiPath = "/tablesdb/{databaseId}/tables/{tableId}/columns/line".replace("{databaseId}", databaseId).replace("{tableId}", tableId);
13070
+ const payload = {};
13071
+ if (typeof key !== "undefined") {
13072
+ payload["key"] = key;
13073
+ }
13074
+ if (typeof required !== "undefined") {
13075
+ payload["required"] = required;
13076
+ }
13077
+ if (typeof xdefault !== "undefined") {
13078
+ payload["default"] = xdefault;
13079
+ }
13080
+ const uri = new URL(this.client.config.endpoint + apiPath);
13081
+ const apiHeaders = {
13082
+ "content-type": "application/json"
13083
+ };
13084
+ return this.client.call(
13085
+ "post",
13086
+ uri,
13087
+ apiHeaders,
13088
+ payload
13089
+ );
13090
+ }
13091
+ updateLineColumn(paramsOrFirst, ...rest) {
13092
+ let params;
13093
+ if (paramsOrFirst && typeof paramsOrFirst === "object" && !Array.isArray(paramsOrFirst)) {
13094
+ params = paramsOrFirst || {};
13095
+ } else {
13096
+ params = {
13097
+ databaseId: paramsOrFirst,
13098
+ tableId: rest[0],
13099
+ key: rest[1],
13100
+ required: rest[2],
13101
+ xdefault: rest[3],
13102
+ newKey: rest[4]
13103
+ };
13104
+ }
13105
+ const databaseId = params.databaseId;
13106
+ const tableId = params.tableId;
13107
+ const key = params.key;
13108
+ const required = params.required;
13109
+ const xdefault = params.xdefault;
13110
+ const newKey = params.newKey;
13111
+ if (typeof databaseId === "undefined") {
13112
+ throw new AppBaseException('Missing required parameter: "databaseId"');
13113
+ }
13114
+ if (typeof tableId === "undefined") {
13115
+ throw new AppBaseException('Missing required parameter: "tableId"');
13116
+ }
13117
+ if (typeof key === "undefined") {
13118
+ throw new AppBaseException('Missing required parameter: "key"');
13119
+ }
13120
+ if (typeof required === "undefined") {
13121
+ throw new AppBaseException('Missing required parameter: "required"');
13122
+ }
13123
+ const apiPath = "/tablesdb/{databaseId}/tables/{tableId}/columns/line/{key}".replace("{databaseId}", databaseId).replace("{tableId}", tableId).replace("{key}", key);
13124
+ const payload = {};
13125
+ if (typeof required !== "undefined") {
13126
+ payload["required"] = required;
13127
+ }
13128
+ if (typeof xdefault !== "undefined") {
13129
+ payload["default"] = xdefault;
13130
+ }
13131
+ if (typeof newKey !== "undefined") {
13132
+ payload["newKey"] = newKey;
13133
+ }
13134
+ const uri = new URL(this.client.config.endpoint + apiPath);
13135
+ const apiHeaders = {
13136
+ "content-type": "application/json"
13137
+ };
13138
+ return this.client.call(
13139
+ "patch",
13140
+ uri,
13141
+ apiHeaders,
13142
+ payload
13143
+ );
13144
+ }
13145
+ createLongtextColumn(paramsOrFirst, ...rest) {
13146
+ let params;
13147
+ if (paramsOrFirst && typeof paramsOrFirst === "object" && !Array.isArray(paramsOrFirst)) {
13148
+ params = paramsOrFirst || {};
13149
+ } else {
13150
+ params = {
13151
+ databaseId: paramsOrFirst,
13152
+ tableId: rest[0],
13153
+ key: rest[1],
13154
+ required: rest[2],
13155
+ xdefault: rest[3],
13156
+ array: rest[4],
13157
+ encrypt: rest[5]
13158
+ };
13159
+ }
13160
+ const databaseId = params.databaseId;
13161
+ const tableId = params.tableId;
13162
+ const key = params.key;
13163
+ const required = params.required;
13164
+ const xdefault = params.xdefault;
13165
+ const array = params.array;
13166
+ const encrypt = params.encrypt;
13167
+ if (typeof databaseId === "undefined") {
13168
+ throw new AppBaseException('Missing required parameter: "databaseId"');
13169
+ }
13170
+ if (typeof tableId === "undefined") {
13171
+ throw new AppBaseException('Missing required parameter: "tableId"');
13172
+ }
13173
+ if (typeof key === "undefined") {
13174
+ throw new AppBaseException('Missing required parameter: "key"');
13175
+ }
13176
+ if (typeof required === "undefined") {
13177
+ throw new AppBaseException('Missing required parameter: "required"');
13178
+ }
13179
+ const apiPath = "/tablesdb/{databaseId}/tables/{tableId}/columns/longtext".replace("{databaseId}", databaseId).replace("{tableId}", tableId);
13180
+ const payload = {};
13181
+ if (typeof key !== "undefined") {
13182
+ payload["key"] = key;
13183
+ }
13184
+ if (typeof required !== "undefined") {
13185
+ payload["required"] = required;
13186
+ }
13187
+ if (typeof xdefault !== "undefined") {
13188
+ payload["default"] = xdefault;
13189
+ }
13190
+ if (typeof array !== "undefined") {
13191
+ payload["array"] = array;
13192
+ }
13193
+ if (typeof encrypt !== "undefined") {
13194
+ payload["encrypt"] = encrypt;
13195
+ }
13196
+ const uri = new URL(this.client.config.endpoint + apiPath);
13197
+ const apiHeaders = {
13198
+ "content-type": "application/json"
13199
+ };
13200
+ return this.client.call(
13201
+ "post",
13202
+ uri,
13203
+ apiHeaders,
13204
+ payload
13205
+ );
13206
+ }
13207
+ updateLongtextColumn(paramsOrFirst, ...rest) {
13208
+ let params;
13209
+ if (paramsOrFirst && typeof paramsOrFirst === "object" && !Array.isArray(paramsOrFirst)) {
13210
+ params = paramsOrFirst || {};
13211
+ } else {
13212
+ params = {
13213
+ databaseId: paramsOrFirst,
13214
+ tableId: rest[0],
13215
+ key: rest[1],
13216
+ required: rest[2],
13217
+ xdefault: rest[3],
13218
+ newKey: rest[4]
13219
+ };
13220
+ }
13221
+ const databaseId = params.databaseId;
13222
+ const tableId = params.tableId;
13223
+ const key = params.key;
13224
+ const required = params.required;
13225
+ const xdefault = params.xdefault;
13226
+ const newKey = params.newKey;
13227
+ if (typeof databaseId === "undefined") {
13228
+ throw new AppBaseException('Missing required parameter: "databaseId"');
13229
+ }
13230
+ if (typeof tableId === "undefined") {
13231
+ throw new AppBaseException('Missing required parameter: "tableId"');
13232
+ }
13233
+ if (typeof key === "undefined") {
13234
+ throw new AppBaseException('Missing required parameter: "key"');
13235
+ }
13236
+ if (typeof required === "undefined") {
13237
+ throw new AppBaseException('Missing required parameter: "required"');
13238
+ }
13239
+ if (typeof xdefault === "undefined") {
13240
+ throw new AppBaseException('Missing required parameter: "xdefault"');
13241
+ }
13242
+ const apiPath = "/tablesdb/{databaseId}/tables/{tableId}/columns/longtext/{key}".replace("{databaseId}", databaseId).replace("{tableId}", tableId).replace("{key}", key);
13243
+ const payload = {};
13244
+ if (typeof required !== "undefined") {
13245
+ payload["required"] = required;
13246
+ }
13247
+ if (typeof xdefault !== "undefined") {
13248
+ payload["default"] = xdefault;
13249
+ }
13250
+ if (typeof newKey !== "undefined") {
13251
+ payload["newKey"] = newKey;
13252
+ }
13253
+ const uri = new URL(this.client.config.endpoint + apiPath);
13254
+ const apiHeaders = {
13255
+ "content-type": "application/json"
13256
+ };
13257
+ return this.client.call(
13258
+ "patch",
13259
+ uri,
13260
+ apiHeaders,
13261
+ payload
13262
+ );
13263
+ }
13264
+ createMediumtextColumn(paramsOrFirst, ...rest) {
13265
+ let params;
13266
+ if (paramsOrFirst && typeof paramsOrFirst === "object" && !Array.isArray(paramsOrFirst)) {
13267
+ params = paramsOrFirst || {};
13268
+ } else {
13269
+ params = {
13270
+ databaseId: paramsOrFirst,
13271
+ tableId: rest[0],
13272
+ key: rest[1],
13273
+ required: rest[2],
13274
+ xdefault: rest[3],
13275
+ array: rest[4],
13276
+ encrypt: rest[5]
13277
+ };
13278
+ }
13279
+ const databaseId = params.databaseId;
13280
+ const tableId = params.tableId;
13281
+ const key = params.key;
13282
+ const required = params.required;
13283
+ const xdefault = params.xdefault;
13284
+ const array = params.array;
13285
+ const encrypt = params.encrypt;
13286
+ if (typeof databaseId === "undefined") {
13287
+ throw new AppBaseException('Missing required parameter: "databaseId"');
13288
+ }
13289
+ if (typeof tableId === "undefined") {
13290
+ throw new AppBaseException('Missing required parameter: "tableId"');
13291
+ }
13292
+ if (typeof key === "undefined") {
13293
+ throw new AppBaseException('Missing required parameter: "key"');
13294
+ }
13295
+ if (typeof required === "undefined") {
13296
+ throw new AppBaseException('Missing required parameter: "required"');
13297
+ }
13298
+ const apiPath = "/tablesdb/{databaseId}/tables/{tableId}/columns/mediumtext".replace("{databaseId}", databaseId).replace("{tableId}", tableId);
13299
+ const payload = {};
13300
+ if (typeof key !== "undefined") {
13301
+ payload["key"] = key;
13302
+ }
13303
+ if (typeof required !== "undefined") {
13304
+ payload["required"] = required;
13305
+ }
13306
+ if (typeof xdefault !== "undefined") {
13307
+ payload["default"] = xdefault;
13308
+ }
13309
+ if (typeof array !== "undefined") {
13310
+ payload["array"] = array;
13311
+ }
13312
+ if (typeof encrypt !== "undefined") {
13313
+ payload["encrypt"] = encrypt;
13314
+ }
13315
+ const uri = new URL(this.client.config.endpoint + apiPath);
13316
+ const apiHeaders = {
13317
+ "content-type": "application/json"
13318
+ };
13319
+ return this.client.call(
13320
+ "post",
13321
+ uri,
13322
+ apiHeaders,
13323
+ payload
13324
+ );
13325
+ }
13326
+ updateMediumtextColumn(paramsOrFirst, ...rest) {
13327
+ let params;
13328
+ if (paramsOrFirst && typeof paramsOrFirst === "object" && !Array.isArray(paramsOrFirst)) {
13329
+ params = paramsOrFirst || {};
13330
+ } else {
13331
+ params = {
13332
+ databaseId: paramsOrFirst,
13333
+ tableId: rest[0],
13334
+ key: rest[1],
13335
+ required: rest[2],
13336
+ xdefault: rest[3],
13337
+ newKey: rest[4]
13338
+ };
13339
+ }
13340
+ const databaseId = params.databaseId;
13341
+ const tableId = params.tableId;
13342
+ const key = params.key;
13343
+ const required = params.required;
13344
+ const xdefault = params.xdefault;
13345
+ const newKey = params.newKey;
13346
+ if (typeof databaseId === "undefined") {
13347
+ throw new AppBaseException('Missing required parameter: "databaseId"');
13348
+ }
13349
+ if (typeof tableId === "undefined") {
13350
+ throw new AppBaseException('Missing required parameter: "tableId"');
13351
+ }
13352
+ if (typeof key === "undefined") {
13353
+ throw new AppBaseException('Missing required parameter: "key"');
13354
+ }
13355
+ if (typeof required === "undefined") {
13356
+ throw new AppBaseException('Missing required parameter: "required"');
13357
+ }
13358
+ if (typeof xdefault === "undefined") {
13359
+ throw new AppBaseException('Missing required parameter: "xdefault"');
13360
+ }
13361
+ const apiPath = "/tablesdb/{databaseId}/tables/{tableId}/columns/mediumtext/{key}".replace("{databaseId}", databaseId).replace("{tableId}", tableId).replace("{key}", key);
13362
+ const payload = {};
13363
+ if (typeof required !== "undefined") {
13364
+ payload["required"] = required;
13365
+ }
13366
+ if (typeof xdefault !== "undefined") {
13367
+ payload["default"] = xdefault;
13368
+ }
13369
+ if (typeof newKey !== "undefined") {
13370
+ payload["newKey"] = newKey;
13371
+ }
13372
+ const uri = new URL(this.client.config.endpoint + apiPath);
13373
+ const apiHeaders = {
13374
+ "content-type": "application/json"
13375
+ };
13376
+ return this.client.call(
13377
+ "patch",
13378
+ uri,
13379
+ apiHeaders,
13380
+ payload
13381
+ );
13382
+ }
13383
+ createPointColumn(paramsOrFirst, ...rest) {
13384
+ let params;
13385
+ if (paramsOrFirst && typeof paramsOrFirst === "object" && !Array.isArray(paramsOrFirst)) {
13386
+ params = paramsOrFirst || {};
13387
+ } else {
13388
+ params = {
13389
+ databaseId: paramsOrFirst,
13390
+ tableId: rest[0],
13391
+ key: rest[1],
13392
+ required: rest[2],
13393
+ xdefault: rest[3]
13394
+ };
13395
+ }
13396
+ const databaseId = params.databaseId;
13397
+ const tableId = params.tableId;
13398
+ const key = params.key;
13399
+ const required = params.required;
13400
+ const xdefault = params.xdefault;
13401
+ if (typeof databaseId === "undefined") {
13402
+ throw new AppBaseException('Missing required parameter: "databaseId"');
13403
+ }
13404
+ if (typeof tableId === "undefined") {
13405
+ throw new AppBaseException('Missing required parameter: "tableId"');
13406
+ }
13407
+ if (typeof key === "undefined") {
13408
+ throw new AppBaseException('Missing required parameter: "key"');
13409
+ }
13410
+ if (typeof required === "undefined") {
13411
+ throw new AppBaseException('Missing required parameter: "required"');
13412
+ }
13413
+ const apiPath = "/tablesdb/{databaseId}/tables/{tableId}/columns/point".replace("{databaseId}", databaseId).replace("{tableId}", tableId);
13414
+ const payload = {};
13415
+ if (typeof key !== "undefined") {
13416
+ payload["key"] = key;
13417
+ }
13418
+ if (typeof required !== "undefined") {
13419
+ payload["required"] = required;
13420
+ }
13421
+ if (typeof xdefault !== "undefined") {
13422
+ payload["default"] = xdefault;
13423
+ }
13424
+ const uri = new URL(this.client.config.endpoint + apiPath);
13425
+ const apiHeaders = {
13426
+ "content-type": "application/json"
13427
+ };
13428
+ return this.client.call(
13429
+ "post",
13430
+ uri,
13431
+ apiHeaders,
13432
+ payload
13433
+ );
13434
+ }
13435
+ updatePointColumn(paramsOrFirst, ...rest) {
13436
+ let params;
13437
+ if (paramsOrFirst && typeof paramsOrFirst === "object" && !Array.isArray(paramsOrFirst)) {
13438
+ params = paramsOrFirst || {};
13439
+ } else {
13440
+ params = {
13441
+ databaseId: paramsOrFirst,
13442
+ tableId: rest[0],
13443
+ key: rest[1],
13444
+ required: rest[2],
13445
+ xdefault: rest[3],
13446
+ newKey: rest[4]
13447
+ };
13448
+ }
13449
+ const databaseId = params.databaseId;
13450
+ const tableId = params.tableId;
13451
+ const key = params.key;
13452
+ const required = params.required;
13453
+ const xdefault = params.xdefault;
13454
+ const newKey = params.newKey;
13455
+ if (typeof databaseId === "undefined") {
13456
+ throw new AppBaseException('Missing required parameter: "databaseId"');
13457
+ }
13458
+ if (typeof tableId === "undefined") {
13459
+ throw new AppBaseException('Missing required parameter: "tableId"');
13460
+ }
13461
+ if (typeof key === "undefined") {
13462
+ throw new AppBaseException('Missing required parameter: "key"');
13463
+ }
13464
+ if (typeof required === "undefined") {
13465
+ throw new AppBaseException('Missing required parameter: "required"');
13466
+ }
13467
+ const apiPath = "/tablesdb/{databaseId}/tables/{tableId}/columns/point/{key}".replace("{databaseId}", databaseId).replace("{tableId}", tableId).replace("{key}", key);
13468
+ const payload = {};
13469
+ if (typeof required !== "undefined") {
13470
+ payload["required"] = required;
13471
+ }
13472
+ if (typeof xdefault !== "undefined") {
13473
+ payload["default"] = xdefault;
13474
+ }
13475
+ if (typeof newKey !== "undefined") {
13476
+ payload["newKey"] = newKey;
13477
+ }
13478
+ const uri = new URL(this.client.config.endpoint + apiPath);
13479
+ const apiHeaders = {
13480
+ "content-type": "application/json"
13481
+ };
13482
+ return this.client.call(
13483
+ "patch",
13484
+ uri,
13485
+ apiHeaders,
13486
+ payload
13487
+ );
13488
+ }
13489
+ createPolygonColumn(paramsOrFirst, ...rest) {
13490
+ let params;
13491
+ if (paramsOrFirst && typeof paramsOrFirst === "object" && !Array.isArray(paramsOrFirst)) {
13492
+ params = paramsOrFirst || {};
13493
+ } else {
13494
+ params = {
13495
+ databaseId: paramsOrFirst,
13496
+ tableId: rest[0],
13497
+ key: rest[1],
13498
+ required: rest[2],
13499
+ xdefault: rest[3]
13500
+ };
13501
+ }
13502
+ const databaseId = params.databaseId;
13503
+ const tableId = params.tableId;
13504
+ const key = params.key;
13505
+ const required = params.required;
13506
+ const xdefault = params.xdefault;
13507
+ if (typeof databaseId === "undefined") {
13508
+ throw new AppBaseException('Missing required parameter: "databaseId"');
13509
+ }
13510
+ if (typeof tableId === "undefined") {
13511
+ throw new AppBaseException('Missing required parameter: "tableId"');
13512
+ }
13513
+ if (typeof key === "undefined") {
13514
+ throw new AppBaseException('Missing required parameter: "key"');
13515
+ }
13516
+ if (typeof required === "undefined") {
13517
+ throw new AppBaseException('Missing required parameter: "required"');
13518
+ }
13519
+ const apiPath = "/tablesdb/{databaseId}/tables/{tableId}/columns/polygon".replace("{databaseId}", databaseId).replace("{tableId}", tableId);
13520
+ const payload = {};
13521
+ if (typeof key !== "undefined") {
13522
+ payload["key"] = key;
13523
+ }
13524
+ if (typeof required !== "undefined") {
13525
+ payload["required"] = required;
13526
+ }
13527
+ if (typeof xdefault !== "undefined") {
13528
+ payload["default"] = xdefault;
13529
+ }
13530
+ const uri = new URL(this.client.config.endpoint + apiPath);
13531
+ const apiHeaders = {
13532
+ "content-type": "application/json"
13533
+ };
13534
+ return this.client.call(
13535
+ "post",
13536
+ uri,
13537
+ apiHeaders,
13538
+ payload
13539
+ );
13540
+ }
13541
+ updatePolygonColumn(paramsOrFirst, ...rest) {
13542
+ let params;
13543
+ if (paramsOrFirst && typeof paramsOrFirst === "object" && !Array.isArray(paramsOrFirst)) {
13544
+ params = paramsOrFirst || {};
13545
+ } else {
13546
+ params = {
13547
+ databaseId: paramsOrFirst,
13548
+ tableId: rest[0],
13549
+ key: rest[1],
13550
+ required: rest[2],
13551
+ xdefault: rest[3],
13552
+ newKey: rest[4]
13553
+ };
13554
+ }
13555
+ const databaseId = params.databaseId;
13556
+ const tableId = params.tableId;
13557
+ const key = params.key;
13558
+ const required = params.required;
13559
+ const xdefault = params.xdefault;
13560
+ const newKey = params.newKey;
13561
+ if (typeof databaseId === "undefined") {
13562
+ throw new AppBaseException('Missing required parameter: "databaseId"');
13563
+ }
13564
+ if (typeof tableId === "undefined") {
13565
+ throw new AppBaseException('Missing required parameter: "tableId"');
13566
+ }
13567
+ if (typeof key === "undefined") {
13568
+ throw new AppBaseException('Missing required parameter: "key"');
13569
+ }
13570
+ if (typeof required === "undefined") {
13571
+ throw new AppBaseException('Missing required parameter: "required"');
13572
+ }
13573
+ const apiPath = "/tablesdb/{databaseId}/tables/{tableId}/columns/polygon/{key}".replace("{databaseId}", databaseId).replace("{tableId}", tableId).replace("{key}", key);
13574
+ const payload = {};
13575
+ if (typeof required !== "undefined") {
13576
+ payload["required"] = required;
13577
+ }
13578
+ if (typeof xdefault !== "undefined") {
13579
+ payload["default"] = xdefault;
13580
+ }
13581
+ if (typeof newKey !== "undefined") {
13582
+ payload["newKey"] = newKey;
13583
+ }
13584
+ const uri = new URL(this.client.config.endpoint + apiPath);
13585
+ const apiHeaders = {
13586
+ "content-type": "application/json"
13587
+ };
13588
+ return this.client.call(
13589
+ "patch",
13590
+ uri,
13591
+ apiHeaders,
13592
+ payload
13593
+ );
13594
+ }
13595
+ createRelationshipColumn(paramsOrFirst, ...rest) {
13596
+ let params;
13597
+ if (paramsOrFirst && typeof paramsOrFirst === "object" && !Array.isArray(paramsOrFirst)) {
13598
+ params = paramsOrFirst || {};
13599
+ } else {
13600
+ params = {
13601
+ databaseId: paramsOrFirst,
13602
+ tableId: rest[0],
13603
+ relatedTableId: rest[1],
13604
+ type: rest[2],
13605
+ twoWay: rest[3],
13606
+ key: rest[4],
13607
+ twoWayKey: rest[5],
13608
+ onDelete: rest[6]
13609
+ };
13610
+ }
13611
+ const databaseId = params.databaseId;
13612
+ const tableId = params.tableId;
13613
+ const relatedTableId = params.relatedTableId;
13614
+ const type = params.type;
13615
+ const twoWay = params.twoWay;
13616
+ const key = params.key;
13617
+ const twoWayKey = params.twoWayKey;
13618
+ const onDelete = params.onDelete;
13619
+ if (typeof databaseId === "undefined") {
13620
+ throw new AppBaseException('Missing required parameter: "databaseId"');
13621
+ }
13622
+ if (typeof tableId === "undefined") {
13623
+ throw new AppBaseException('Missing required parameter: "tableId"');
13624
+ }
13625
+ if (typeof relatedTableId === "undefined") {
13626
+ throw new AppBaseException('Missing required parameter: "relatedTableId"');
13627
+ }
13628
+ if (typeof type === "undefined") {
13629
+ throw new AppBaseException('Missing required parameter: "type"');
13630
+ }
13631
+ const apiPath = "/tablesdb/{databaseId}/tables/{tableId}/columns/relationship".replace("{databaseId}", databaseId).replace("{tableId}", tableId);
13632
+ const payload = {};
13633
+ if (typeof relatedTableId !== "undefined") {
13634
+ payload["relatedTableId"] = relatedTableId;
13635
+ }
13636
+ if (typeof type !== "undefined") {
13637
+ payload["type"] = type;
13638
+ }
13639
+ if (typeof twoWay !== "undefined") {
13640
+ payload["twoWay"] = twoWay;
13641
+ }
13642
+ if (typeof key !== "undefined") {
13643
+ payload["key"] = key;
13644
+ }
13645
+ if (typeof twoWayKey !== "undefined") {
13646
+ payload["twoWayKey"] = twoWayKey;
13647
+ }
13648
+ if (typeof onDelete !== "undefined") {
13649
+ payload["onDelete"] = onDelete;
13650
+ }
13651
+ const uri = new URL(this.client.config.endpoint + apiPath);
13652
+ const apiHeaders = {
13653
+ "content-type": "application/json"
13654
+ };
13655
+ return this.client.call(
13656
+ "post",
13657
+ uri,
13658
+ apiHeaders,
13659
+ payload
13660
+ );
13661
+ }
13662
+ createStringColumn(paramsOrFirst, ...rest) {
13663
+ let params;
13664
+ if (paramsOrFirst && typeof paramsOrFirst === "object" && !Array.isArray(paramsOrFirst)) {
13665
+ params = paramsOrFirst || {};
13666
+ } else {
13667
+ params = {
13668
+ databaseId: paramsOrFirst,
13669
+ tableId: rest[0],
13670
+ key: rest[1],
13671
+ size: rest[2],
13672
+ required: rest[3],
13673
+ xdefault: rest[4],
13674
+ array: rest[5],
13675
+ encrypt: rest[6]
13676
+ };
13677
+ }
13678
+ const databaseId = params.databaseId;
13679
+ const tableId = params.tableId;
13680
+ const key = params.key;
13681
+ const size = params.size;
13682
+ const required = params.required;
13683
+ const xdefault = params.xdefault;
13684
+ const array = params.array;
13685
+ const encrypt = params.encrypt;
13686
+ if (typeof databaseId === "undefined") {
13687
+ throw new AppBaseException('Missing required parameter: "databaseId"');
13688
+ }
13689
+ if (typeof tableId === "undefined") {
13690
+ throw new AppBaseException('Missing required parameter: "tableId"');
13691
+ }
13692
+ if (typeof key === "undefined") {
13693
+ throw new AppBaseException('Missing required parameter: "key"');
13694
+ }
13695
+ if (typeof size === "undefined") {
13696
+ throw new AppBaseException('Missing required parameter: "size"');
13697
+ }
13698
+ if (typeof required === "undefined") {
13699
+ throw new AppBaseException('Missing required parameter: "required"');
13700
+ }
13701
+ const apiPath = "/tablesdb/{databaseId}/tables/{tableId}/columns/string".replace("{databaseId}", databaseId).replace("{tableId}", tableId);
13702
+ const payload = {};
13703
+ if (typeof key !== "undefined") {
13704
+ payload["key"] = key;
13705
+ }
13706
+ if (typeof size !== "undefined") {
13707
+ payload["size"] = size;
13708
+ }
13709
+ if (typeof required !== "undefined") {
13710
+ payload["required"] = required;
13711
+ }
13712
+ if (typeof xdefault !== "undefined") {
13713
+ payload["default"] = xdefault;
13714
+ }
13715
+ if (typeof array !== "undefined") {
13716
+ payload["array"] = array;
13717
+ }
13718
+ if (typeof encrypt !== "undefined") {
13719
+ payload["encrypt"] = encrypt;
13720
+ }
13721
+ const uri = new URL(this.client.config.endpoint + apiPath);
13722
+ const apiHeaders = {
13723
+ "content-type": "application/json"
13724
+ };
13725
+ return this.client.call(
13726
+ "post",
13727
+ uri,
13728
+ apiHeaders,
13729
+ payload
13730
+ );
13731
+ }
13732
+ updateStringColumn(paramsOrFirst, ...rest) {
13733
+ let params;
13734
+ if (paramsOrFirst && typeof paramsOrFirst === "object" && !Array.isArray(paramsOrFirst)) {
13735
+ params = paramsOrFirst || {};
13736
+ } else {
13737
+ params = {
13738
+ databaseId: paramsOrFirst,
13739
+ tableId: rest[0],
13740
+ key: rest[1],
13741
+ required: rest[2],
13742
+ xdefault: rest[3],
13743
+ size: rest[4],
13744
+ newKey: rest[5]
13745
+ };
13746
+ }
13747
+ const databaseId = params.databaseId;
13748
+ const tableId = params.tableId;
13749
+ const key = params.key;
13750
+ const required = params.required;
13751
+ const xdefault = params.xdefault;
13752
+ const size = params.size;
13753
+ const newKey = params.newKey;
13754
+ if (typeof databaseId === "undefined") {
13755
+ throw new AppBaseException('Missing required parameter: "databaseId"');
13756
+ }
13757
+ if (typeof tableId === "undefined") {
13758
+ throw new AppBaseException('Missing required parameter: "tableId"');
13759
+ }
13760
+ if (typeof key === "undefined") {
13761
+ throw new AppBaseException('Missing required parameter: "key"');
13762
+ }
13763
+ if (typeof required === "undefined") {
13764
+ throw new AppBaseException('Missing required parameter: "required"');
13765
+ }
13766
+ if (typeof xdefault === "undefined") {
13767
+ throw new AppBaseException('Missing required parameter: "xdefault"');
13768
+ }
13769
+ const apiPath = "/tablesdb/{databaseId}/tables/{tableId}/columns/string/{key}".replace("{databaseId}", databaseId).replace("{tableId}", tableId).replace("{key}", key);
13770
+ const payload = {};
13771
+ if (typeof required !== "undefined") {
13772
+ payload["required"] = required;
13773
+ }
13774
+ if (typeof xdefault !== "undefined") {
13775
+ payload["default"] = xdefault;
13776
+ }
13777
+ if (typeof size !== "undefined") {
13778
+ payload["size"] = size;
13779
+ }
13780
+ if (typeof newKey !== "undefined") {
13781
+ payload["newKey"] = newKey;
13782
+ }
13783
+ const uri = new URL(this.client.config.endpoint + apiPath);
13784
+ const apiHeaders = {
13785
+ "content-type": "application/json"
13786
+ };
13787
+ return this.client.call(
13788
+ "patch",
13789
+ uri,
13790
+ apiHeaders,
13791
+ payload
13792
+ );
13793
+ }
13794
+ createTextColumn(paramsOrFirst, ...rest) {
13795
+ let params;
13796
+ if (paramsOrFirst && typeof paramsOrFirst === "object" && !Array.isArray(paramsOrFirst)) {
13797
+ params = paramsOrFirst || {};
13798
+ } else {
13799
+ params = {
13800
+ databaseId: paramsOrFirst,
13801
+ tableId: rest[0],
13802
+ key: rest[1],
13803
+ required: rest[2],
13804
+ xdefault: rest[3],
13805
+ array: rest[4],
13806
+ encrypt: rest[5]
13807
+ };
13808
+ }
13809
+ const databaseId = params.databaseId;
13810
+ const tableId = params.tableId;
13811
+ const key = params.key;
13812
+ const required = params.required;
13813
+ const xdefault = params.xdefault;
13814
+ const array = params.array;
13815
+ const encrypt = params.encrypt;
13816
+ if (typeof databaseId === "undefined") {
13817
+ throw new AppBaseException('Missing required parameter: "databaseId"');
13818
+ }
13819
+ if (typeof tableId === "undefined") {
13820
+ throw new AppBaseException('Missing required parameter: "tableId"');
13821
+ }
13822
+ if (typeof key === "undefined") {
13823
+ throw new AppBaseException('Missing required parameter: "key"');
13824
+ }
13825
+ if (typeof required === "undefined") {
13826
+ throw new AppBaseException('Missing required parameter: "required"');
13827
+ }
13828
+ const apiPath = "/tablesdb/{databaseId}/tables/{tableId}/columns/text".replace("{databaseId}", databaseId).replace("{tableId}", tableId);
13829
+ const payload = {};
13830
+ if (typeof key !== "undefined") {
13831
+ payload["key"] = key;
13832
+ }
13833
+ if (typeof required !== "undefined") {
13834
+ payload["required"] = required;
13835
+ }
13836
+ if (typeof xdefault !== "undefined") {
13837
+ payload["default"] = xdefault;
13838
+ }
13839
+ if (typeof array !== "undefined") {
13840
+ payload["array"] = array;
13841
+ }
13842
+ if (typeof encrypt !== "undefined") {
13843
+ payload["encrypt"] = encrypt;
13844
+ }
13845
+ const uri = new URL(this.client.config.endpoint + apiPath);
13846
+ const apiHeaders = {
13847
+ "content-type": "application/json"
13848
+ };
13849
+ return this.client.call(
13850
+ "post",
13851
+ uri,
13852
+ apiHeaders,
13853
+ payload
13854
+ );
13855
+ }
13856
+ updateTextColumn(paramsOrFirst, ...rest) {
13857
+ let params;
13858
+ if (paramsOrFirst && typeof paramsOrFirst === "object" && !Array.isArray(paramsOrFirst)) {
13859
+ params = paramsOrFirst || {};
13860
+ } else {
13861
+ params = {
13862
+ databaseId: paramsOrFirst,
13863
+ tableId: rest[0],
13864
+ key: rest[1],
13865
+ required: rest[2],
13866
+ xdefault: rest[3],
13867
+ newKey: rest[4]
13868
+ };
13869
+ }
13870
+ const databaseId = params.databaseId;
13871
+ const tableId = params.tableId;
13872
+ const key = params.key;
13873
+ const required = params.required;
13874
+ const xdefault = params.xdefault;
13875
+ const newKey = params.newKey;
13876
+ if (typeof databaseId === "undefined") {
13877
+ throw new AppBaseException('Missing required parameter: "databaseId"');
13878
+ }
13879
+ if (typeof tableId === "undefined") {
13880
+ throw new AppBaseException('Missing required parameter: "tableId"');
13881
+ }
13882
+ if (typeof key === "undefined") {
13883
+ throw new AppBaseException('Missing required parameter: "key"');
13884
+ }
13885
+ if (typeof required === "undefined") {
13886
+ throw new AppBaseException('Missing required parameter: "required"');
13887
+ }
13888
+ if (typeof xdefault === "undefined") {
13889
+ throw new AppBaseException('Missing required parameter: "xdefault"');
13890
+ }
13891
+ const apiPath = "/tablesdb/{databaseId}/tables/{tableId}/columns/text/{key}".replace("{databaseId}", databaseId).replace("{tableId}", tableId).replace("{key}", key);
13892
+ const payload = {};
13893
+ if (typeof required !== "undefined") {
13894
+ payload["required"] = required;
13895
+ }
13896
+ if (typeof xdefault !== "undefined") {
13897
+ payload["default"] = xdefault;
13898
+ }
13899
+ if (typeof newKey !== "undefined") {
13900
+ payload["newKey"] = newKey;
13901
+ }
13902
+ const uri = new URL(this.client.config.endpoint + apiPath);
13903
+ const apiHeaders = {
13904
+ "content-type": "application/json"
13905
+ };
13906
+ return this.client.call(
13907
+ "patch",
13908
+ uri,
13909
+ apiHeaders,
13910
+ payload
13911
+ );
13912
+ }
13913
+ createUrlColumn(paramsOrFirst, ...rest) {
13914
+ let params;
13915
+ if (paramsOrFirst && typeof paramsOrFirst === "object" && !Array.isArray(paramsOrFirst)) {
13916
+ params = paramsOrFirst || {};
13917
+ } else {
13918
+ params = {
13919
+ databaseId: paramsOrFirst,
13920
+ tableId: rest[0],
13921
+ key: rest[1],
13922
+ required: rest[2],
13923
+ xdefault: rest[3],
13924
+ array: rest[4]
13925
+ };
13926
+ }
13927
+ const databaseId = params.databaseId;
13928
+ const tableId = params.tableId;
13929
+ const key = params.key;
13930
+ const required = params.required;
13931
+ const xdefault = params.xdefault;
13932
+ const array = params.array;
13933
+ if (typeof databaseId === "undefined") {
13934
+ throw new AppBaseException('Missing required parameter: "databaseId"');
13935
+ }
13936
+ if (typeof tableId === "undefined") {
13937
+ throw new AppBaseException('Missing required parameter: "tableId"');
13938
+ }
13939
+ if (typeof key === "undefined") {
13940
+ throw new AppBaseException('Missing required parameter: "key"');
13941
+ }
13942
+ if (typeof required === "undefined") {
13943
+ throw new AppBaseException('Missing required parameter: "required"');
13944
+ }
13945
+ const apiPath = "/tablesdb/{databaseId}/tables/{tableId}/columns/url".replace("{databaseId}", databaseId).replace("{tableId}", tableId);
13946
+ const payload = {};
13947
+ if (typeof key !== "undefined") {
13948
+ payload["key"] = key;
13949
+ }
13950
+ if (typeof required !== "undefined") {
13951
+ payload["required"] = required;
13952
+ }
13953
+ if (typeof xdefault !== "undefined") {
13954
+ payload["default"] = xdefault;
13955
+ }
13956
+ if (typeof array !== "undefined") {
13957
+ payload["array"] = array;
13958
+ }
13959
+ const uri = new URL(this.client.config.endpoint + apiPath);
13960
+ const apiHeaders = {
13961
+ "content-type": "application/json"
13962
+ };
13963
+ return this.client.call(
13964
+ "post",
13965
+ uri,
13966
+ apiHeaders,
13967
+ payload
13968
+ );
13969
+ }
13970
+ updateUrlColumn(paramsOrFirst, ...rest) {
13971
+ let params;
13972
+ if (paramsOrFirst && typeof paramsOrFirst === "object" && !Array.isArray(paramsOrFirst)) {
13973
+ params = paramsOrFirst || {};
13974
+ } else {
13975
+ params = {
13976
+ databaseId: paramsOrFirst,
13977
+ tableId: rest[0],
13978
+ key: rest[1],
13979
+ required: rest[2],
13980
+ xdefault: rest[3],
13981
+ newKey: rest[4]
13982
+ };
13983
+ }
13984
+ const databaseId = params.databaseId;
13985
+ const tableId = params.tableId;
13986
+ const key = params.key;
13987
+ const required = params.required;
13988
+ const xdefault = params.xdefault;
13989
+ const newKey = params.newKey;
13990
+ if (typeof databaseId === "undefined") {
13991
+ throw new AppBaseException('Missing required parameter: "databaseId"');
13992
+ }
13993
+ if (typeof tableId === "undefined") {
13994
+ throw new AppBaseException('Missing required parameter: "tableId"');
13995
+ }
13996
+ if (typeof key === "undefined") {
13997
+ throw new AppBaseException('Missing required parameter: "key"');
13998
+ }
13999
+ if (typeof required === "undefined") {
14000
+ throw new AppBaseException('Missing required parameter: "required"');
14001
+ }
14002
+ if (typeof xdefault === "undefined") {
14003
+ throw new AppBaseException('Missing required parameter: "xdefault"');
14004
+ }
14005
+ const apiPath = "/tablesdb/{databaseId}/tables/{tableId}/columns/url/{key}".replace("{databaseId}", databaseId).replace("{tableId}", tableId).replace("{key}", key);
14006
+ const payload = {};
14007
+ if (typeof required !== "undefined") {
14008
+ payload["required"] = required;
14009
+ }
14010
+ if (typeof xdefault !== "undefined") {
14011
+ payload["default"] = xdefault;
14012
+ }
14013
+ if (typeof newKey !== "undefined") {
14014
+ payload["newKey"] = newKey;
14015
+ }
14016
+ const uri = new URL(this.client.config.endpoint + apiPath);
14017
+ const apiHeaders = {
14018
+ "content-type": "application/json"
14019
+ };
14020
+ return this.client.call(
14021
+ "patch",
14022
+ uri,
14023
+ apiHeaders,
14024
+ payload
14025
+ );
14026
+ }
14027
+ createVarcharColumn(paramsOrFirst, ...rest) {
14028
+ let params;
14029
+ if (paramsOrFirst && typeof paramsOrFirst === "object" && !Array.isArray(paramsOrFirst)) {
14030
+ params = paramsOrFirst || {};
14031
+ } else {
14032
+ params = {
14033
+ databaseId: paramsOrFirst,
14034
+ tableId: rest[0],
14035
+ key: rest[1],
14036
+ size: rest[2],
14037
+ required: rest[3],
14038
+ xdefault: rest[4],
14039
+ array: rest[5],
14040
+ encrypt: rest[6]
14041
+ };
14042
+ }
14043
+ const databaseId = params.databaseId;
14044
+ const tableId = params.tableId;
14045
+ const key = params.key;
14046
+ const size = params.size;
14047
+ const required = params.required;
14048
+ const xdefault = params.xdefault;
14049
+ const array = params.array;
14050
+ const encrypt = params.encrypt;
14051
+ if (typeof databaseId === "undefined") {
14052
+ throw new AppBaseException('Missing required parameter: "databaseId"');
14053
+ }
14054
+ if (typeof tableId === "undefined") {
14055
+ throw new AppBaseException('Missing required parameter: "tableId"');
14056
+ }
14057
+ if (typeof key === "undefined") {
14058
+ throw new AppBaseException('Missing required parameter: "key"');
14059
+ }
14060
+ if (typeof size === "undefined") {
14061
+ throw new AppBaseException('Missing required parameter: "size"');
14062
+ }
14063
+ if (typeof required === "undefined") {
14064
+ throw new AppBaseException('Missing required parameter: "required"');
14065
+ }
14066
+ const apiPath = "/tablesdb/{databaseId}/tables/{tableId}/columns/varchar".replace("{databaseId}", databaseId).replace("{tableId}", tableId);
14067
+ const payload = {};
14068
+ if (typeof key !== "undefined") {
14069
+ payload["key"] = key;
14070
+ }
14071
+ if (typeof size !== "undefined") {
14072
+ payload["size"] = size;
14073
+ }
14074
+ if (typeof required !== "undefined") {
14075
+ payload["required"] = required;
14076
+ }
14077
+ if (typeof xdefault !== "undefined") {
14078
+ payload["default"] = xdefault;
14079
+ }
14080
+ if (typeof array !== "undefined") {
14081
+ payload["array"] = array;
14082
+ }
14083
+ if (typeof encrypt !== "undefined") {
14084
+ payload["encrypt"] = encrypt;
14085
+ }
14086
+ const uri = new URL(this.client.config.endpoint + apiPath);
14087
+ const apiHeaders = {
14088
+ "content-type": "application/json"
14089
+ };
14090
+ return this.client.call(
14091
+ "post",
14092
+ uri,
14093
+ apiHeaders,
14094
+ payload
14095
+ );
14096
+ }
14097
+ updateVarcharColumn(paramsOrFirst, ...rest) {
14098
+ let params;
14099
+ if (paramsOrFirst && typeof paramsOrFirst === "object" && !Array.isArray(paramsOrFirst)) {
14100
+ params = paramsOrFirst || {};
14101
+ } else {
14102
+ params = {
14103
+ databaseId: paramsOrFirst,
14104
+ tableId: rest[0],
14105
+ key: rest[1],
14106
+ required: rest[2],
14107
+ xdefault: rest[3],
14108
+ size: rest[4],
14109
+ newKey: rest[5]
14110
+ };
14111
+ }
14112
+ const databaseId = params.databaseId;
14113
+ const tableId = params.tableId;
14114
+ const key = params.key;
14115
+ const required = params.required;
14116
+ const xdefault = params.xdefault;
14117
+ const size = params.size;
14118
+ const newKey = params.newKey;
14119
+ if (typeof databaseId === "undefined") {
14120
+ throw new AppBaseException('Missing required parameter: "databaseId"');
14121
+ }
14122
+ if (typeof tableId === "undefined") {
14123
+ throw new AppBaseException('Missing required parameter: "tableId"');
14124
+ }
14125
+ if (typeof key === "undefined") {
14126
+ throw new AppBaseException('Missing required parameter: "key"');
14127
+ }
14128
+ if (typeof required === "undefined") {
14129
+ throw new AppBaseException('Missing required parameter: "required"');
14130
+ }
14131
+ if (typeof xdefault === "undefined") {
14132
+ throw new AppBaseException('Missing required parameter: "xdefault"');
14133
+ }
14134
+ const apiPath = "/tablesdb/{databaseId}/tables/{tableId}/columns/varchar/{key}".replace("{databaseId}", databaseId).replace("{tableId}", tableId).replace("{key}", key);
14135
+ const payload = {};
14136
+ if (typeof required !== "undefined") {
14137
+ payload["required"] = required;
14138
+ }
14139
+ if (typeof xdefault !== "undefined") {
14140
+ payload["default"] = xdefault;
14141
+ }
14142
+ if (typeof size !== "undefined") {
14143
+ payload["size"] = size;
14144
+ }
14145
+ if (typeof newKey !== "undefined") {
14146
+ payload["newKey"] = newKey;
14147
+ }
14148
+ const uri = new URL(this.client.config.endpoint + apiPath);
14149
+ const apiHeaders = {
14150
+ "content-type": "application/json"
14151
+ };
14152
+ return this.client.call(
14153
+ "patch",
14154
+ uri,
14155
+ apiHeaders,
14156
+ payload
14157
+ );
14158
+ }
14159
+ getColumn(paramsOrFirst, ...rest) {
14160
+ let params;
14161
+ if (paramsOrFirst && typeof paramsOrFirst === "object" && !Array.isArray(paramsOrFirst)) {
14162
+ params = paramsOrFirst || {};
14163
+ } else {
14164
+ params = {
14165
+ databaseId: paramsOrFirst,
14166
+ tableId: rest[0],
14167
+ key: rest[1]
14168
+ };
14169
+ }
14170
+ const databaseId = params.databaseId;
14171
+ const tableId = params.tableId;
14172
+ const key = params.key;
14173
+ if (typeof databaseId === "undefined") {
14174
+ throw new AppBaseException('Missing required parameter: "databaseId"');
14175
+ }
14176
+ if (typeof tableId === "undefined") {
14177
+ throw new AppBaseException('Missing required parameter: "tableId"');
14178
+ }
14179
+ if (typeof key === "undefined") {
14180
+ throw new AppBaseException('Missing required parameter: "key"');
14181
+ }
14182
+ const apiPath = "/tablesdb/{databaseId}/tables/{tableId}/columns/{key}".replace("{databaseId}", databaseId).replace("{tableId}", tableId).replace("{key}", key);
14183
+ const payload = {};
14184
+ const uri = new URL(this.client.config.endpoint + apiPath);
14185
+ const apiHeaders = {};
14186
+ return this.client.call(
14187
+ "get",
14188
+ uri,
14189
+ apiHeaders,
14190
+ payload
14191
+ );
14192
+ }
14193
+ deleteColumn(paramsOrFirst, ...rest) {
14194
+ let params;
14195
+ if (paramsOrFirst && typeof paramsOrFirst === "object" && !Array.isArray(paramsOrFirst)) {
14196
+ params = paramsOrFirst || {};
14197
+ } else {
14198
+ params = {
14199
+ databaseId: paramsOrFirst,
14200
+ tableId: rest[0],
14201
+ key: rest[1]
14202
+ };
14203
+ }
14204
+ const databaseId = params.databaseId;
14205
+ const tableId = params.tableId;
14206
+ const key = params.key;
14207
+ if (typeof databaseId === "undefined") {
14208
+ throw new AppBaseException('Missing required parameter: "databaseId"');
14209
+ }
14210
+ if (typeof tableId === "undefined") {
14211
+ throw new AppBaseException('Missing required parameter: "tableId"');
14212
+ }
14213
+ if (typeof key === "undefined") {
14214
+ throw new AppBaseException('Missing required parameter: "key"');
14215
+ }
14216
+ const apiPath = "/tablesdb/{databaseId}/tables/{tableId}/columns/{key}".replace("{databaseId}", databaseId).replace("{tableId}", tableId).replace("{key}", key);
14217
+ const payload = {};
14218
+ const uri = new URL(this.client.config.endpoint + apiPath);
14219
+ const apiHeaders = {
14220
+ "content-type": "application/json"
14221
+ };
14222
+ return this.client.call(
14223
+ "delete",
14224
+ uri,
14225
+ apiHeaders,
14226
+ payload
14227
+ );
14228
+ }
14229
+ updateColumnComment(paramsOrFirst, ...rest) {
14230
+ let params;
14231
+ if (paramsOrFirst && typeof paramsOrFirst === "object" && !Array.isArray(paramsOrFirst)) {
14232
+ params = paramsOrFirst || {};
14233
+ } else {
14234
+ params = {
14235
+ databaseId: paramsOrFirst,
14236
+ tableId: rest[0],
14237
+ key: rest[1],
14238
+ comment: rest[2]
14239
+ };
14240
+ }
14241
+ const databaseId = params.databaseId;
14242
+ const tableId = params.tableId;
14243
+ const key = params.key;
14244
+ const comment = params.comment;
14245
+ if (typeof databaseId === "undefined") {
14246
+ throw new AppBaseException('Missing required parameter: "databaseId"');
14247
+ }
14248
+ if (typeof tableId === "undefined") {
14249
+ throw new AppBaseException('Missing required parameter: "tableId"');
14250
+ }
14251
+ if (typeof key === "undefined") {
14252
+ throw new AppBaseException('Missing required parameter: "key"');
14253
+ }
14254
+ if (typeof comment === "undefined") {
14255
+ throw new AppBaseException('Missing required parameter: "comment"');
14256
+ }
14257
+ const apiPath = "/tablesdb/{databaseId}/tables/{tableId}/columns/{key}/comment".replace("{databaseId}", databaseId).replace("{tableId}", tableId).replace("{key}", key);
14258
+ const payload = {};
14259
+ if (typeof comment !== "undefined") {
14260
+ payload["comment"] = comment;
14261
+ }
14262
+ const uri = new URL(this.client.config.endpoint + apiPath);
14263
+ const apiHeaders = {
14264
+ "content-type": "application/json"
14265
+ };
14266
+ return this.client.call(
14267
+ "patch",
14268
+ uri,
14269
+ apiHeaders,
14270
+ payload
14271
+ );
14272
+ }
14273
+ updateRelationshipColumn(paramsOrFirst, ...rest) {
14274
+ let params;
14275
+ if (paramsOrFirst && typeof paramsOrFirst === "object" && !Array.isArray(paramsOrFirst)) {
14276
+ params = paramsOrFirst || {};
14277
+ } else {
14278
+ params = {
14279
+ databaseId: paramsOrFirst,
14280
+ tableId: rest[0],
14281
+ key: rest[1],
14282
+ onDelete: rest[2],
14283
+ newKey: rest[3]
14284
+ };
14285
+ }
14286
+ const databaseId = params.databaseId;
14287
+ const tableId = params.tableId;
14288
+ const key = params.key;
14289
+ const onDelete = params.onDelete;
14290
+ const newKey = params.newKey;
14291
+ if (typeof databaseId === "undefined") {
14292
+ throw new AppBaseException('Missing required parameter: "databaseId"');
14293
+ }
14294
+ if (typeof tableId === "undefined") {
14295
+ throw new AppBaseException('Missing required parameter: "tableId"');
14296
+ }
14297
+ if (typeof key === "undefined") {
14298
+ throw new AppBaseException('Missing required parameter: "key"');
14299
+ }
14300
+ const apiPath = "/tablesdb/{databaseId}/tables/{tableId}/columns/{key}/relationship".replace("{databaseId}", databaseId).replace("{tableId}", tableId).replace("{key}", key);
14301
+ const payload = {};
14302
+ if (typeof onDelete !== "undefined") {
14303
+ payload["onDelete"] = onDelete;
14304
+ }
14305
+ if (typeof newKey !== "undefined") {
14306
+ payload["newKey"] = newKey;
14307
+ }
14308
+ const uri = new URL(this.client.config.endpoint + apiPath);
14309
+ const apiHeaders = {
14310
+ "content-type": "application/json"
14311
+ };
14312
+ return this.client.call(
14313
+ "patch",
14314
+ uri,
14315
+ apiHeaders,
14316
+ payload
14317
+ );
14318
+ }
14319
+ listIndexes(paramsOrFirst, ...rest) {
14320
+ let params;
14321
+ if (paramsOrFirst && typeof paramsOrFirst === "object" && !Array.isArray(paramsOrFirst)) {
14322
+ params = paramsOrFirst || {};
14323
+ } else {
14324
+ params = {
14325
+ databaseId: paramsOrFirst,
14326
+ tableId: rest[0],
14327
+ queries: rest[1],
14328
+ total: rest[2]
14329
+ };
14330
+ }
14331
+ const databaseId = params.databaseId;
14332
+ const tableId = params.tableId;
14333
+ const queries = params.queries;
14334
+ const total = params.total;
14335
+ if (typeof databaseId === "undefined") {
14336
+ throw new AppBaseException('Missing required parameter: "databaseId"');
14337
+ }
14338
+ if (typeof tableId === "undefined") {
14339
+ throw new AppBaseException('Missing required parameter: "tableId"');
14340
+ }
14341
+ const apiPath = "/tablesdb/{databaseId}/tables/{tableId}/indexes".replace("{databaseId}", databaseId).replace("{tableId}", tableId);
14342
+ const payload = {};
14343
+ if (typeof queries !== "undefined") {
14344
+ payload["queries"] = queries;
14345
+ }
14346
+ if (typeof total !== "undefined") {
14347
+ payload["total"] = total;
14348
+ }
14349
+ const uri = new URL(this.client.config.endpoint + apiPath);
14350
+ const apiHeaders = {};
14351
+ return this.client.call(
14352
+ "get",
14353
+ uri,
14354
+ apiHeaders,
14355
+ payload
14356
+ );
14357
+ }
14358
+ createIndex(paramsOrFirst, ...rest) {
14359
+ let params;
14360
+ if (paramsOrFirst && typeof paramsOrFirst === "object" && !Array.isArray(paramsOrFirst)) {
14361
+ params = paramsOrFirst || {};
14362
+ } else {
14363
+ params = {
14364
+ databaseId: paramsOrFirst,
14365
+ tableId: rest[0],
14366
+ key: rest[1],
14367
+ type: rest[2],
14368
+ columns: rest[3],
14369
+ orders: rest[4],
14370
+ lengths: rest[5]
14371
+ };
14372
+ }
14373
+ const databaseId = params.databaseId;
14374
+ const tableId = params.tableId;
14375
+ const key = params.key;
14376
+ const type = params.type;
14377
+ const columns = params.columns;
14378
+ const orders = params.orders;
14379
+ const lengths = params.lengths;
14380
+ if (typeof databaseId === "undefined") {
14381
+ throw new AppBaseException('Missing required parameter: "databaseId"');
14382
+ }
14383
+ if (typeof tableId === "undefined") {
14384
+ throw new AppBaseException('Missing required parameter: "tableId"');
14385
+ }
14386
+ if (typeof key === "undefined") {
14387
+ throw new AppBaseException('Missing required parameter: "key"');
14388
+ }
14389
+ if (typeof type === "undefined") {
14390
+ throw new AppBaseException('Missing required parameter: "type"');
14391
+ }
14392
+ if (typeof columns === "undefined") {
14393
+ throw new AppBaseException('Missing required parameter: "columns"');
14394
+ }
14395
+ const apiPath = "/tablesdb/{databaseId}/tables/{tableId}/indexes".replace("{databaseId}", databaseId).replace("{tableId}", tableId);
14396
+ const payload = {};
14397
+ if (typeof key !== "undefined") {
14398
+ payload["key"] = key;
14399
+ }
14400
+ if (typeof type !== "undefined") {
14401
+ payload["type"] = type;
14402
+ }
14403
+ if (typeof columns !== "undefined") {
14404
+ payload["columns"] = columns;
14405
+ }
14406
+ if (typeof orders !== "undefined") {
14407
+ payload["orders"] = orders;
14408
+ }
14409
+ if (typeof lengths !== "undefined") {
14410
+ payload["lengths"] = lengths;
14411
+ }
14412
+ const uri = new URL(this.client.config.endpoint + apiPath);
14413
+ const apiHeaders = {
14414
+ "content-type": "application/json"
14415
+ };
14416
+ return this.client.call(
14417
+ "post",
14418
+ uri,
14419
+ apiHeaders,
14420
+ payload
14421
+ );
14422
+ }
14423
+ getIndex(paramsOrFirst, ...rest) {
14424
+ let params;
14425
+ if (paramsOrFirst && typeof paramsOrFirst === "object" && !Array.isArray(paramsOrFirst)) {
14426
+ params = paramsOrFirst || {};
14427
+ } else {
14428
+ params = {
14429
+ databaseId: paramsOrFirst,
14430
+ tableId: rest[0],
14431
+ key: rest[1]
14432
+ };
14433
+ }
14434
+ const databaseId = params.databaseId;
14435
+ const tableId = params.tableId;
14436
+ const key = params.key;
14437
+ if (typeof databaseId === "undefined") {
14438
+ throw new AppBaseException('Missing required parameter: "databaseId"');
14439
+ }
14440
+ if (typeof tableId === "undefined") {
14441
+ throw new AppBaseException('Missing required parameter: "tableId"');
14442
+ }
14443
+ if (typeof key === "undefined") {
14444
+ throw new AppBaseException('Missing required parameter: "key"');
14445
+ }
14446
+ const apiPath = "/tablesdb/{databaseId}/tables/{tableId}/indexes/{key}".replace("{databaseId}", databaseId).replace("{tableId}", tableId).replace("{key}", key);
14447
+ const payload = {};
14448
+ const uri = new URL(this.client.config.endpoint + apiPath);
14449
+ const apiHeaders = {};
14450
+ return this.client.call(
14451
+ "get",
14452
+ uri,
14453
+ apiHeaders,
14454
+ payload
14455
+ );
14456
+ }
14457
+ deleteIndex(paramsOrFirst, ...rest) {
14458
+ let params;
14459
+ if (paramsOrFirst && typeof paramsOrFirst === "object" && !Array.isArray(paramsOrFirst)) {
14460
+ params = paramsOrFirst || {};
14461
+ } else {
14462
+ params = {
14463
+ databaseId: paramsOrFirst,
14464
+ tableId: rest[0],
14465
+ key: rest[1]
14466
+ };
14467
+ }
14468
+ const databaseId = params.databaseId;
14469
+ const tableId = params.tableId;
14470
+ const key = params.key;
14471
+ if (typeof databaseId === "undefined") {
14472
+ throw new AppBaseException('Missing required parameter: "databaseId"');
14473
+ }
14474
+ if (typeof tableId === "undefined") {
14475
+ throw new AppBaseException('Missing required parameter: "tableId"');
14476
+ }
14477
+ if (typeof key === "undefined") {
14478
+ throw new AppBaseException('Missing required parameter: "key"');
14479
+ }
14480
+ const apiPath = "/tablesdb/{databaseId}/tables/{tableId}/indexes/{key}".replace("{databaseId}", databaseId).replace("{tableId}", tableId).replace("{key}", key);
14481
+ const payload = {};
14482
+ const uri = new URL(this.client.config.endpoint + apiPath);
14483
+ const apiHeaders = {
14484
+ "content-type": "application/json"
14485
+ };
14486
+ return this.client.call(
14487
+ "delete",
14488
+ uri,
14489
+ apiHeaders,
14490
+ payload
14491
+ );
14492
+ }
14493
+ listRows(paramsOrFirst, ...rest) {
14494
+ let params;
14495
+ if (paramsOrFirst && typeof paramsOrFirst === "object" && !Array.isArray(paramsOrFirst)) {
14496
+ params = paramsOrFirst || {};
14497
+ } else {
14498
+ params = {
14499
+ databaseId: paramsOrFirst,
14500
+ tableId: rest[0],
14501
+ queries: rest[1],
14502
+ transactionId: rest[2],
14503
+ total: rest[3],
14504
+ ttl: rest[4]
14505
+ };
14506
+ }
14507
+ const databaseId = params.databaseId;
14508
+ const tableId = params.tableId;
14509
+ const queries = params.queries;
14510
+ const transactionId = params.transactionId;
14511
+ const total = params.total;
14512
+ const ttl = params.ttl;
14513
+ if (typeof databaseId === "undefined") {
14514
+ throw new AppBaseException('Missing required parameter: "databaseId"');
14515
+ }
14516
+ if (typeof tableId === "undefined") {
14517
+ throw new AppBaseException('Missing required parameter: "tableId"');
14518
+ }
14519
+ const apiPath = "/tablesdb/{databaseId}/tables/{tableId}/rows".replace("{databaseId}", databaseId).replace("{tableId}", tableId);
14520
+ const payload = {};
14521
+ if (typeof queries !== "undefined") {
14522
+ payload["queries"] = queries;
14523
+ }
14524
+ if (typeof transactionId !== "undefined") {
14525
+ payload["transactionId"] = transactionId;
14526
+ }
14527
+ if (typeof total !== "undefined") {
14528
+ payload["total"] = total;
14529
+ }
14530
+ if (typeof ttl !== "undefined") {
14531
+ payload["ttl"] = ttl;
14532
+ }
14533
+ const uri = new URL(this.client.config.endpoint + apiPath);
14534
+ const apiHeaders = {};
14535
+ return this.client.call(
14536
+ "get",
14537
+ uri,
14538
+ apiHeaders,
14539
+ payload
14540
+ );
14541
+ }
14542
+ createRow(paramsOrFirst, ...rest) {
14543
+ let params;
14544
+ if (paramsOrFirst && typeof paramsOrFirst === "object" && !Array.isArray(paramsOrFirst)) {
14545
+ params = paramsOrFirst || {};
14546
+ } else {
14547
+ params = {
14548
+ databaseId: paramsOrFirst,
14549
+ tableId: rest[0],
14550
+ rowId: rest[1],
14551
+ data: rest[2],
14552
+ permissions: rest[3],
14553
+ transactionId: rest[4]
14554
+ };
14555
+ }
14556
+ const databaseId = params.databaseId;
14557
+ const tableId = params.tableId;
14558
+ const rowId = params.rowId;
14559
+ const data = params.data;
14560
+ const permissions = params.permissions;
14561
+ const transactionId = params.transactionId;
14562
+ if (typeof databaseId === "undefined") {
14563
+ throw new AppBaseException('Missing required parameter: "databaseId"');
14564
+ }
14565
+ if (typeof tableId === "undefined") {
14566
+ throw new AppBaseException('Missing required parameter: "tableId"');
14567
+ }
14568
+ if (typeof rowId === "undefined") {
14569
+ throw new AppBaseException('Missing required parameter: "rowId"');
14570
+ }
14571
+ if (typeof data === "undefined") {
14572
+ throw new AppBaseException('Missing required parameter: "data"');
14573
+ }
14574
+ const apiPath = "/tablesdb/{databaseId}/tables/{tableId}/rows".replace("{databaseId}", databaseId).replace("{tableId}", tableId);
14575
+ const payload = {};
14576
+ if (typeof rowId !== "undefined") {
14577
+ payload["rowId"] = rowId;
14578
+ }
14579
+ if (typeof data !== "undefined") {
14580
+ payload["data"] = data;
14581
+ }
14582
+ if (typeof permissions !== "undefined") {
14583
+ payload["permissions"] = permissions;
14584
+ }
14585
+ if (typeof transactionId !== "undefined") {
14586
+ payload["transactionId"] = transactionId;
14587
+ }
14588
+ const uri = new URL(this.client.config.endpoint + apiPath);
14589
+ const apiHeaders = {
14590
+ "content-type": "application/json"
14591
+ };
14592
+ return this.client.call(
14593
+ "post",
14594
+ uri,
14595
+ apiHeaders,
14596
+ payload
14597
+ );
14598
+ }
14599
+ createRows(paramsOrFirst, ...rest) {
14600
+ let params;
14601
+ if (paramsOrFirst && typeof paramsOrFirst === "object" && !Array.isArray(paramsOrFirst)) {
14602
+ params = paramsOrFirst || {};
14603
+ } else {
14604
+ params = {
14605
+ databaseId: paramsOrFirst,
14606
+ tableId: rest[0],
14607
+ transactionId: rest[1]
14608
+ };
14609
+ }
14610
+ const databaseId = params.databaseId;
14611
+ const tableId = params.tableId;
14612
+ const transactionId = params.transactionId;
14613
+ if (typeof databaseId === "undefined") {
14614
+ throw new AppBaseException('Missing required parameter: "databaseId"');
14615
+ }
14616
+ if (typeof tableId === "undefined") {
14617
+ throw new AppBaseException('Missing required parameter: "tableId"');
14618
+ }
14619
+ const apiPath = "/tablesdb/{databaseId}/tables/{tableId}/rows".replace("{databaseId}", databaseId).replace("{tableId}", tableId);
14620
+ const payload = {};
14621
+ if (typeof transactionId !== "undefined") {
14622
+ payload["transactionId"] = transactionId;
14623
+ }
14624
+ const uri = new URL(this.client.config.endpoint + apiPath);
14625
+ const apiHeaders = {
14626
+ "content-type": "application/json"
14627
+ };
14628
+ return this.client.call(
14629
+ "post",
14630
+ uri,
14631
+ apiHeaders,
14632
+ payload
14633
+ );
14634
+ }
14635
+ upsertRows(paramsOrFirst, ...rest) {
14636
+ let params;
14637
+ if (paramsOrFirst && typeof paramsOrFirst === "object" && !Array.isArray(paramsOrFirst)) {
14638
+ params = paramsOrFirst || {};
14639
+ } else {
14640
+ params = {
14641
+ databaseId: paramsOrFirst,
14642
+ tableId: rest[0],
14643
+ rows: rest[1],
14644
+ transactionId: rest[2]
14645
+ };
14646
+ }
14647
+ const databaseId = params.databaseId;
14648
+ const tableId = params.tableId;
14649
+ const rows = params.rows;
14650
+ const transactionId = params.transactionId;
14651
+ if (typeof databaseId === "undefined") {
14652
+ throw new AppBaseException('Missing required parameter: "databaseId"');
14653
+ }
14654
+ if (typeof tableId === "undefined") {
14655
+ throw new AppBaseException('Missing required parameter: "tableId"');
14656
+ }
14657
+ if (typeof rows === "undefined") {
14658
+ throw new AppBaseException('Missing required parameter: "rows"');
14659
+ }
14660
+ const apiPath = "/tablesdb/{databaseId}/tables/{tableId}/rows".replace("{databaseId}", databaseId).replace("{tableId}", tableId);
14661
+ const payload = {};
14662
+ if (typeof rows !== "undefined") {
14663
+ payload["rows"] = rows;
14664
+ }
14665
+ if (typeof transactionId !== "undefined") {
14666
+ payload["transactionId"] = transactionId;
14667
+ }
14668
+ const uri = new URL(this.client.config.endpoint + apiPath);
14669
+ const apiHeaders = {
14670
+ "content-type": "application/json"
14671
+ };
14672
+ return this.client.call(
14673
+ "put",
14674
+ uri,
14675
+ apiHeaders,
14676
+ payload
14677
+ );
14678
+ }
14679
+ updateRows(paramsOrFirst, ...rest) {
14680
+ let params;
14681
+ if (paramsOrFirst && typeof paramsOrFirst === "object" && !Array.isArray(paramsOrFirst)) {
14682
+ params = paramsOrFirst || {};
14683
+ } else {
14684
+ params = {
14685
+ databaseId: paramsOrFirst,
14686
+ tableId: rest[0],
14687
+ data: rest[1],
14688
+ queries: rest[2],
14689
+ transactionId: rest[3]
14690
+ };
14691
+ }
14692
+ const databaseId = params.databaseId;
14693
+ const tableId = params.tableId;
14694
+ const data = params.data;
14695
+ const queries = params.queries;
14696
+ const transactionId = params.transactionId;
14697
+ if (typeof databaseId === "undefined") {
14698
+ throw new AppBaseException('Missing required parameter: "databaseId"');
14699
+ }
14700
+ if (typeof tableId === "undefined") {
14701
+ throw new AppBaseException('Missing required parameter: "tableId"');
14702
+ }
14703
+ const apiPath = "/tablesdb/{databaseId}/tables/{tableId}/rows".replace("{databaseId}", databaseId).replace("{tableId}", tableId);
14704
+ const payload = {};
14705
+ if (typeof data !== "undefined") {
14706
+ payload["data"] = data;
14707
+ }
14708
+ if (typeof queries !== "undefined") {
14709
+ payload["queries"] = queries;
14710
+ }
14711
+ if (typeof transactionId !== "undefined") {
14712
+ payload["transactionId"] = transactionId;
14713
+ }
14714
+ const uri = new URL(this.client.config.endpoint + apiPath);
14715
+ const apiHeaders = {
14716
+ "content-type": "application/json"
14717
+ };
14718
+ return this.client.call(
14719
+ "patch",
14720
+ uri,
14721
+ apiHeaders,
14722
+ payload
14723
+ );
14724
+ }
14725
+ deleteRows(paramsOrFirst, ...rest) {
14726
+ let params;
14727
+ if (paramsOrFirst && typeof paramsOrFirst === "object" && !Array.isArray(paramsOrFirst)) {
14728
+ params = paramsOrFirst || {};
14729
+ } else {
14730
+ params = {
14731
+ databaseId: paramsOrFirst,
14732
+ tableId: rest[0],
14733
+ queries: rest[1],
14734
+ transactionId: rest[2]
14735
+ };
14736
+ }
14737
+ const databaseId = params.databaseId;
14738
+ const tableId = params.tableId;
14739
+ const queries = params.queries;
14740
+ const transactionId = params.transactionId;
14741
+ if (typeof databaseId === "undefined") {
14742
+ throw new AppBaseException('Missing required parameter: "databaseId"');
14743
+ }
14744
+ if (typeof tableId === "undefined") {
14745
+ throw new AppBaseException('Missing required parameter: "tableId"');
14746
+ }
14747
+ const apiPath = "/tablesdb/{databaseId}/tables/{tableId}/rows".replace("{databaseId}", databaseId).replace("{tableId}", tableId);
14748
+ const payload = {};
14749
+ if (typeof queries !== "undefined") {
14750
+ payload["queries"] = queries;
14751
+ }
14752
+ if (typeof transactionId !== "undefined") {
14753
+ payload["transactionId"] = transactionId;
14754
+ }
14755
+ const uri = new URL(this.client.config.endpoint + apiPath);
14756
+ const apiHeaders = {
14757
+ "content-type": "application/json"
14758
+ };
14759
+ return this.client.call(
14760
+ "delete",
14761
+ uri,
14762
+ apiHeaders,
14763
+ payload
14764
+ );
14765
+ }
14766
+ getRow(paramsOrFirst, ...rest) {
14767
+ let params;
14768
+ if (paramsOrFirst && typeof paramsOrFirst === "object" && !Array.isArray(paramsOrFirst)) {
14769
+ params = paramsOrFirst || {};
14770
+ } else {
14771
+ params = {
14772
+ databaseId: paramsOrFirst,
14773
+ tableId: rest[0],
14774
+ rowId: rest[1],
14775
+ queries: rest[2],
14776
+ transactionId: rest[3]
14777
+ };
14778
+ }
14779
+ const databaseId = params.databaseId;
14780
+ const tableId = params.tableId;
14781
+ const rowId = params.rowId;
14782
+ const queries = params.queries;
14783
+ const transactionId = params.transactionId;
14784
+ if (typeof databaseId === "undefined") {
14785
+ throw new AppBaseException('Missing required parameter: "databaseId"');
14786
+ }
14787
+ if (typeof tableId === "undefined") {
14788
+ throw new AppBaseException('Missing required parameter: "tableId"');
14789
+ }
14790
+ if (typeof rowId === "undefined") {
14791
+ throw new AppBaseException('Missing required parameter: "rowId"');
14792
+ }
14793
+ const apiPath = "/tablesdb/{databaseId}/tables/{tableId}/rows/{rowId}".replace("{databaseId}", databaseId).replace("{tableId}", tableId).replace("{rowId}", rowId);
14794
+ const payload = {};
14795
+ if (typeof queries !== "undefined") {
14796
+ payload["queries"] = queries;
14797
+ }
14798
+ if (typeof transactionId !== "undefined") {
14799
+ payload["transactionId"] = transactionId;
14800
+ }
14801
+ const uri = new URL(this.client.config.endpoint + apiPath);
14802
+ const apiHeaders = {};
14803
+ return this.client.call(
14804
+ "get",
14805
+ uri,
14806
+ apiHeaders,
14807
+ payload
14808
+ );
14809
+ }
14810
+ upsertRow(paramsOrFirst, ...rest) {
14811
+ let params;
14812
+ if (paramsOrFirst && typeof paramsOrFirst === "object" && !Array.isArray(paramsOrFirst)) {
14813
+ params = paramsOrFirst || {};
14814
+ } else {
14815
+ params = {
14816
+ databaseId: paramsOrFirst,
14817
+ tableId: rest[0],
14818
+ rowId: rest[1],
14819
+ data: rest[2],
14820
+ permissions: rest[3],
14821
+ transactionId: rest[4]
14822
+ };
14823
+ }
14824
+ const databaseId = params.databaseId;
14825
+ const tableId = params.tableId;
14826
+ const rowId = params.rowId;
14827
+ const data = params.data;
14828
+ const permissions = params.permissions;
14829
+ const transactionId = params.transactionId;
14830
+ if (typeof databaseId === "undefined") {
14831
+ throw new AppBaseException('Missing required parameter: "databaseId"');
14832
+ }
14833
+ if (typeof tableId === "undefined") {
14834
+ throw new AppBaseException('Missing required parameter: "tableId"');
14835
+ }
14836
+ if (typeof rowId === "undefined") {
14837
+ throw new AppBaseException('Missing required parameter: "rowId"');
14838
+ }
14839
+ const apiPath = "/tablesdb/{databaseId}/tables/{tableId}/rows/{rowId}".replace("{databaseId}", databaseId).replace("{tableId}", tableId).replace("{rowId}", rowId);
14840
+ const payload = {};
14841
+ if (typeof data !== "undefined") {
14842
+ payload["data"] = data;
14843
+ }
14844
+ if (typeof permissions !== "undefined") {
14845
+ payload["permissions"] = permissions;
14846
+ }
14847
+ if (typeof transactionId !== "undefined") {
14848
+ payload["transactionId"] = transactionId;
14849
+ }
14850
+ const uri = new URL(this.client.config.endpoint + apiPath);
14851
+ const apiHeaders = {
14852
+ "content-type": "application/json"
14853
+ };
14854
+ return this.client.call(
14855
+ "put",
14856
+ uri,
14857
+ apiHeaders,
14858
+ payload
14859
+ );
14860
+ }
14861
+ updateRow(paramsOrFirst, ...rest) {
14862
+ let params;
14863
+ if (paramsOrFirst && typeof paramsOrFirst === "object" && !Array.isArray(paramsOrFirst)) {
14864
+ params = paramsOrFirst || {};
14865
+ } else {
14866
+ params = {
14867
+ databaseId: paramsOrFirst,
14868
+ tableId: rest[0],
14869
+ rowId: rest[1],
14870
+ data: rest[2],
14871
+ permissions: rest[3],
14872
+ transactionId: rest[4]
14873
+ };
14874
+ }
14875
+ const databaseId = params.databaseId;
14876
+ const tableId = params.tableId;
14877
+ const rowId = params.rowId;
14878
+ const data = params.data;
14879
+ const permissions = params.permissions;
14880
+ const transactionId = params.transactionId;
14881
+ if (typeof databaseId === "undefined") {
14882
+ throw new AppBaseException('Missing required parameter: "databaseId"');
14883
+ }
14884
+ if (typeof tableId === "undefined") {
14885
+ throw new AppBaseException('Missing required parameter: "tableId"');
14886
+ }
14887
+ if (typeof rowId === "undefined") {
14888
+ throw new AppBaseException('Missing required parameter: "rowId"');
14889
+ }
14890
+ const apiPath = "/tablesdb/{databaseId}/tables/{tableId}/rows/{rowId}".replace("{databaseId}", databaseId).replace("{tableId}", tableId).replace("{rowId}", rowId);
14891
+ const payload = {};
14892
+ if (typeof data !== "undefined") {
14893
+ payload["data"] = data;
14894
+ }
14895
+ if (typeof permissions !== "undefined") {
14896
+ payload["permissions"] = permissions;
14897
+ }
14898
+ if (typeof transactionId !== "undefined") {
14899
+ payload["transactionId"] = transactionId;
14900
+ }
14901
+ const uri = new URL(this.client.config.endpoint + apiPath);
14902
+ const apiHeaders = {
14903
+ "content-type": "application/json"
14904
+ };
14905
+ return this.client.call(
14906
+ "patch",
14907
+ uri,
14908
+ apiHeaders,
14909
+ payload
14910
+ );
14911
+ }
14912
+ deleteRow(paramsOrFirst, ...rest) {
14913
+ let params;
14914
+ if (paramsOrFirst && typeof paramsOrFirst === "object" && !Array.isArray(paramsOrFirst)) {
14915
+ params = paramsOrFirst || {};
14916
+ } else {
14917
+ params = {
14918
+ databaseId: paramsOrFirst,
14919
+ tableId: rest[0],
14920
+ rowId: rest[1],
14921
+ transactionId: rest[2]
14922
+ };
14923
+ }
14924
+ const databaseId = params.databaseId;
14925
+ const tableId = params.tableId;
14926
+ const rowId = params.rowId;
14927
+ const transactionId = params.transactionId;
14928
+ if (typeof databaseId === "undefined") {
14929
+ throw new AppBaseException('Missing required parameter: "databaseId"');
14930
+ }
14931
+ if (typeof tableId === "undefined") {
14932
+ throw new AppBaseException('Missing required parameter: "tableId"');
14933
+ }
14934
+ if (typeof rowId === "undefined") {
14935
+ throw new AppBaseException('Missing required parameter: "rowId"');
14936
+ }
14937
+ const apiPath = "/tablesdb/{databaseId}/tables/{tableId}/rows/{rowId}".replace("{databaseId}", databaseId).replace("{tableId}", tableId).replace("{rowId}", rowId);
14938
+ const payload = {};
14939
+ if (typeof transactionId !== "undefined") {
14940
+ payload["transactionId"] = transactionId;
14941
+ }
14942
+ const uri = new URL(this.client.config.endpoint + apiPath);
14943
+ const apiHeaders = {
14944
+ "content-type": "application/json"
14945
+ };
14946
+ return this.client.call(
14947
+ "delete",
14948
+ uri,
14949
+ apiHeaders,
14950
+ payload
14951
+ );
14952
+ }
14953
+ decrementRowColumn(paramsOrFirst, ...rest) {
14954
+ let params;
14955
+ if (paramsOrFirst && typeof paramsOrFirst === "object" && !Array.isArray(paramsOrFirst)) {
14956
+ params = paramsOrFirst || {};
14957
+ } else {
14958
+ params = {
14959
+ databaseId: paramsOrFirst,
14960
+ tableId: rest[0],
14961
+ rowId: rest[1],
14962
+ column: rest[2],
14963
+ value: rest[3],
14964
+ min: rest[4],
14965
+ transactionId: rest[5]
14966
+ };
14967
+ }
14968
+ const databaseId = params.databaseId;
14969
+ const tableId = params.tableId;
14970
+ const rowId = params.rowId;
14971
+ const column = params.column;
14972
+ const value = params.value;
14973
+ const min = params.min;
14974
+ const transactionId = params.transactionId;
14975
+ if (typeof databaseId === "undefined") {
14976
+ throw new AppBaseException('Missing required parameter: "databaseId"');
14977
+ }
14978
+ if (typeof tableId === "undefined") {
14979
+ throw new AppBaseException('Missing required parameter: "tableId"');
14980
+ }
14981
+ if (typeof rowId === "undefined") {
14982
+ throw new AppBaseException('Missing required parameter: "rowId"');
14983
+ }
14984
+ if (typeof column === "undefined") {
14985
+ throw new AppBaseException('Missing required parameter: "column"');
14986
+ }
14987
+ const apiPath = "/tablesdb/{databaseId}/tables/{tableId}/rows/{rowId}/{column}/decrement".replace("{databaseId}", databaseId).replace("{tableId}", tableId).replace("{rowId}", rowId).replace("{column}", column);
14988
+ const payload = {};
14989
+ if (typeof value !== "undefined") {
14990
+ payload["value"] = value;
14991
+ }
14992
+ if (typeof min !== "undefined") {
14993
+ payload["min"] = min;
14994
+ }
14995
+ if (typeof transactionId !== "undefined") {
14996
+ payload["transactionId"] = transactionId;
14997
+ }
14998
+ const uri = new URL(this.client.config.endpoint + apiPath);
14999
+ const apiHeaders = {
15000
+ "content-type": "application/json"
15001
+ };
15002
+ return this.client.call(
15003
+ "patch",
15004
+ uri,
15005
+ apiHeaders,
15006
+ payload
15007
+ );
15008
+ }
15009
+ incrementRowColumn(paramsOrFirst, ...rest) {
15010
+ let params;
15011
+ if (paramsOrFirst && typeof paramsOrFirst === "object" && !Array.isArray(paramsOrFirst)) {
15012
+ params = paramsOrFirst || {};
15013
+ } else {
15014
+ params = {
15015
+ databaseId: paramsOrFirst,
15016
+ tableId: rest[0],
15017
+ rowId: rest[1],
15018
+ column: rest[2],
15019
+ value: rest[3],
15020
+ max: rest[4],
15021
+ transactionId: rest[5]
15022
+ };
15023
+ }
15024
+ const databaseId = params.databaseId;
15025
+ const tableId = params.tableId;
15026
+ const rowId = params.rowId;
15027
+ const column = params.column;
15028
+ const value = params.value;
15029
+ const max = params.max;
15030
+ const transactionId = params.transactionId;
15031
+ if (typeof databaseId === "undefined") {
15032
+ throw new AppBaseException('Missing required parameter: "databaseId"');
15033
+ }
15034
+ if (typeof tableId === "undefined") {
15035
+ throw new AppBaseException('Missing required parameter: "tableId"');
15036
+ }
15037
+ if (typeof rowId === "undefined") {
15038
+ throw new AppBaseException('Missing required parameter: "rowId"');
15039
+ }
15040
+ if (typeof column === "undefined") {
15041
+ throw new AppBaseException('Missing required parameter: "column"');
15042
+ }
15043
+ const apiPath = "/tablesdb/{databaseId}/tables/{tableId}/rows/{rowId}/{column}/increment".replace("{databaseId}", databaseId).replace("{tableId}", tableId).replace("{rowId}", rowId).replace("{column}", column);
15044
+ const payload = {};
15045
+ if (typeof value !== "undefined") {
15046
+ payload["value"] = value;
15047
+ }
15048
+ if (typeof max !== "undefined") {
15049
+ payload["max"] = max;
15050
+ }
15051
+ if (typeof transactionId !== "undefined") {
15052
+ payload["transactionId"] = transactionId;
15053
+ }
15054
+ const uri = new URL(this.client.config.endpoint + apiPath);
15055
+ const apiHeaders = {
15056
+ "content-type": "application/json"
15057
+ };
15058
+ return this.client.call(
15059
+ "patch",
15060
+ uri,
15061
+ apiHeaders,
15062
+ payload
15063
+ );
15064
+ }
15065
+ };
15066
+
11390
15067
  // ../../node_modules/@alipay/appbase-node-sdk/dist/permission.mjs
11391
15068
  var Permission = class {
11392
15069
  };
@@ -11749,7 +15426,8 @@ function resolveProvider(raw, log, logError) {
11749
15426
  import { createHash } from "node:crypto";
11750
15427
  var TRANSACTION_TTL_SECONDS = 60;
11751
15428
  var COMPLETE_MAX_ATTEMPTS = 3;
11752
- function createClientCapabilityStore(databases, databaseId, tableId) {
15429
+ var CLEANUP_BATCH_SIZE = 100;
15430
+ function createClientCapabilityStore(databases, databaseId, tableId, tablesDB) {
11753
15431
  return {
11754
15432
  async create(row) {
11755
15433
  const { invocationId, ...data } = row;
@@ -11851,15 +15529,20 @@ function createClientCapabilityStore(databases, databaseId, tableId) {
11851
15529
  }
11852
15530
  },
11853
15531
  async cleanup(now) {
11854
- const result = await databases.listDocuments(databaseId, tableId, [
11855
- Query.lessThanEqual("expiresAt", now),
11856
- Query.limit(500)
11857
- ]);
11858
15532
  let deleted = 0;
11859
- for (const document of result.documents) {
11860
- await databases.deleteDocument(databaseId, tableId, document.$id);
11861
- deleted += 1;
11862
- }
15533
+ let batchDeleted;
15534
+ do {
15535
+ const result = await tablesDB.deleteRows({
15536
+ databaseId,
15537
+ tableId,
15538
+ queries: [
15539
+ Query.lessThanEqual("expiresAt", now),
15540
+ Query.limit(CLEANUP_BATCH_SIZE)
15541
+ ]
15542
+ });
15543
+ batchDeleted = result.rows.length;
15544
+ deleted += batchDeleted;
15545
+ } while (batchDeleted === CLEANUP_BATCH_SIZE);
11863
15546
  return deleted;
11864
15547
  }
11865
15548
  };
@@ -12162,7 +15845,7 @@ async function clientCapability(ctx) {
12162
15845
  try {
12163
15846
  const handle = createAppBaseClient(process.env, logCtx, readAppwriteApiKey(ctx.req.headers));
12164
15847
  const config = new AppbaseRuntimeConfigProvider();
12165
- const store = createClientCapabilityStore(handle.databases, config.get("CLIENT_CAPABILITY_DATABASE_ID"), config.get("CLIENT_CAPABILITY_TABLE_ID"));
15848
+ const store = createClientCapabilityStore(handle.databases, config.get("CLIENT_CAPABILITY_DATABASE_ID"), config.get("CLIENT_CAPABILITY_TABLE_ID"), new TablesDB(handle.client));
12166
15849
  const trigger = readAppwriteTrigger(ctx.req.headers);
12167
15850
  result = await runClientCapability(trigger, ctx.req.method, resolveBodyJSON(ctx.req), readAuthenticatedUserId(ctx.req.headers), store);
12168
15851
  } catch (error) {
@@ -12206,6 +15889,7 @@ export {
12206
15889
  APPBASE_RUNTIME_CONFIG_DEFAULTS,
12207
15890
  AppbaseRuntimeConfigProvider,
12208
15891
  Query,
15892
+ TablesDB,
12209
15893
  resolveRunStorage,
12210
15894
  createAppBaseClient,
12211
15895
  withIsoTimestamp,