@sfxcode/nuxt-mongocamp-server 1.2.0 → 1.2.2

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.
Files changed (153) hide show
  1. package/README.md +1 -1
  2. package/dist/module.json +5 -1
  3. package/dist/module.mjs +1 -1
  4. package/dist/runtime/api/apis/AdminApi.d.ts +2 -2
  5. package/dist/runtime/api/apis/{AdminApi.mjs → AdminApi.js} +101 -65
  6. package/dist/runtime/api/apis/ApplicationApi.d.ts +2 -2
  7. package/dist/runtime/api/apis/{ApplicationApi.mjs → ApplicationApi.js} +24 -15
  8. package/dist/runtime/api/apis/AuthApi.d.ts +2 -2
  9. package/dist/runtime/api/apis/{AuthApi.mjs → AuthApi.js} +21 -15
  10. package/dist/runtime/api/apis/BucketApi.d.ts +2 -2
  11. package/dist/runtime/api/apis/{BucketApi.mjs → BucketApi.js} +24 -15
  12. package/dist/runtime/api/apis/CollectionApi.d.ts +2 -2
  13. package/dist/runtime/api/apis/{CollectionApi.mjs → CollectionApi.js} +99 -66
  14. package/dist/runtime/api/apis/DatabaseApi.d.ts +2 -2
  15. package/dist/runtime/api/apis/{DatabaseApi.mjs → DatabaseApi.js} +25 -16
  16. package/dist/runtime/api/apis/DocumentApi.d.ts +6 -6
  17. package/dist/runtime/api/apis/{DocumentApi.mjs → DocumentApi.js} +153 -93
  18. package/dist/runtime/api/apis/FileApi.d.ts +2 -2
  19. package/dist/runtime/api/apis/{FileApi.mjs → FileApi.js} +121 -76
  20. package/dist/runtime/api/apis/IndexApi.d.ts +2 -2
  21. package/dist/runtime/api/apis/{IndexApi.mjs → IndexApi.js} +119 -71
  22. package/dist/runtime/api/apis/InformationApi.d.ts +2 -2
  23. package/dist/runtime/api/apis/{InformationApi.mjs → InformationApi.js} +2 -2
  24. package/dist/runtime/api/apis/JobsApi.d.ts +2 -2
  25. package/dist/runtime/api/apis/{JobsApi.mjs → JobsApi.js} +53 -29
  26. package/dist/runtime/api/apis/index.d.ts +11 -11
  27. package/dist/runtime/api/apis/index.js +11 -0
  28. package/dist/runtime/api/index.d.ts +3 -3
  29. package/dist/runtime/api/index.js +3 -0
  30. package/dist/runtime/api/models/BucketInformation.d.ts +1 -1
  31. package/dist/runtime/api/models/BucketInformation.js +32 -0
  32. package/dist/runtime/api/models/CollectionStatus.d.ts +3 -3
  33. package/dist/runtime/api/models/CollectionStatus.js +59 -0
  34. package/dist/runtime/api/models/DatabaseInfo.d.ts +2 -2
  35. package/dist/runtime/api/models/DatabaseInfo.js +35 -0
  36. package/dist/runtime/api/models/DeleteResponse.d.ts +1 -1
  37. package/dist/runtime/api/models/{DeleteResponse.mjs → DeleteResponse.js} +8 -12
  38. package/dist/runtime/api/models/ErrorDescription.d.ts +1 -1
  39. package/dist/runtime/api/models/{ErrorDescription.mjs → ErrorDescription.js} +10 -14
  40. package/dist/runtime/api/models/FileInformation.d.ts +2 -2
  41. package/dist/runtime/api/models/FileInformation.js +38 -0
  42. package/dist/runtime/api/models/Grant.d.ts +1 -1
  43. package/dist/runtime/api/models/Grant.js +35 -0
  44. package/dist/runtime/api/models/IndexCreateRequest.d.ts +3 -3
  45. package/dist/runtime/api/models/IndexCreateRequest.js +29 -0
  46. package/dist/runtime/api/models/IndexCreateResponse.d.ts +1 -1
  47. package/dist/runtime/api/models/{IndexCreateResponse.mjs → IndexCreateResponse.js} +6 -10
  48. package/dist/runtime/api/models/IndexDropResponse.d.ts +1 -1
  49. package/dist/runtime/api/models/{IndexDropResponse.mjs → IndexDropResponse.js} +6 -10
  50. package/dist/runtime/api/models/IndexOptionsRequest.d.ts +1 -1
  51. package/dist/runtime/api/models/IndexOptionsRequest.js +36 -0
  52. package/dist/runtime/api/models/InsertResponse.d.ts +1 -1
  53. package/dist/runtime/api/models/InsertResponse.js +25 -0
  54. package/dist/runtime/api/models/JobConfig.d.ts +1 -1
  55. package/dist/runtime/api/models/JobConfig.js +38 -0
  56. package/dist/runtime/api/models/JobInformation.d.ts +1 -1
  57. package/dist/runtime/api/models/JobInformation.js +44 -0
  58. package/dist/runtime/api/models/JsonSchema.d.ts +3 -3
  59. package/dist/runtime/api/models/JsonSchema.js +34 -0
  60. package/dist/runtime/api/models/JsonSchemaDefinition.d.ts +2 -2
  61. package/dist/runtime/api/models/JsonSchemaDefinition.js +34 -0
  62. package/dist/runtime/api/models/JsonValueAny.d.ts +1 -1
  63. package/dist/runtime/api/models/{JsonValueAny.mjs → JsonValueAny.js} +6 -10
  64. package/dist/runtime/api/models/JsonValueBoolean.d.ts +1 -1
  65. package/dist/runtime/api/models/{JsonValueBoolean.mjs → JsonValueBoolean.js} +6 -10
  66. package/dist/runtime/api/models/JsonValueString.d.ts +1 -1
  67. package/dist/runtime/api/models/{JsonValueString.mjs → JsonValueString.js} +6 -10
  68. package/dist/runtime/api/models/Login.d.ts +1 -1
  69. package/dist/runtime/api/models/{Login.mjs → Login.js} +8 -12
  70. package/dist/runtime/api/models/LoginResult.d.ts +2 -2
  71. package/dist/runtime/api/models/{LoginResult.mjs → LoginResult.js} +11 -15
  72. package/dist/runtime/api/models/MongoAggregateRequest.d.ts +2 -2
  73. package/dist/runtime/api/models/MongoAggregateRequest.js +29 -0
  74. package/dist/runtime/api/models/MongoCampConfiguration.d.ts +1 -1
  75. package/dist/runtime/api/models/MongoCampConfiguration.js +35 -0
  76. package/dist/runtime/api/models/MongoFindRequest.d.ts +4 -4
  77. package/dist/runtime/api/models/{MongoFindRequest.mjs → MongoFindRequest.js} +10 -14
  78. package/dist/runtime/api/models/MongoIndex.d.ts +4 -4
  79. package/dist/runtime/api/models/MongoIndex.js +55 -0
  80. package/dist/runtime/api/models/PasswordUpdateRequest.d.ts +1 -1
  81. package/dist/runtime/api/models/{PasswordUpdateRequest.mjs → PasswordUpdateRequest.js} +6 -10
  82. package/dist/runtime/api/models/PipelineStage.d.ts +1 -1
  83. package/dist/runtime/api/models/{PipelineStage.mjs → PipelineStage.js} +8 -12
  84. package/dist/runtime/api/models/Role.d.ts +2 -2
  85. package/dist/runtime/api/models/Role.js +32 -0
  86. package/dist/runtime/api/models/SchemaAnalysis.d.ts +2 -2
  87. package/dist/runtime/api/models/SchemaAnalysis.js +35 -0
  88. package/dist/runtime/api/models/SchemaAnalysisField.d.ts +2 -2
  89. package/dist/runtime/api/models/SchemaAnalysisField.js +40 -0
  90. package/dist/runtime/api/models/SchemaAnalysisFieldType.d.ts +1 -1
  91. package/dist/runtime/api/models/{SchemaAnalysisFieldType.mjs → SchemaAnalysisFieldType.js} +10 -14
  92. package/dist/runtime/api/models/SettingsResponse.d.ts +2 -2
  93. package/dist/runtime/api/models/SettingsResponse.js +29 -0
  94. package/dist/runtime/api/models/UpdateFileInformationRequest.d.ts +2 -2
  95. package/dist/runtime/api/models/UpdateFileInformationRequest.js +24 -0
  96. package/dist/runtime/api/models/UpdateRequest.d.ts +3 -3
  97. package/dist/runtime/api/models/{UpdateRequest.mjs → UpdateRequest.js} +8 -12
  98. package/dist/runtime/api/models/UpdateResponse.d.ts +1 -1
  99. package/dist/runtime/api/models/UpdateResponse.js +31 -0
  100. package/dist/runtime/api/models/UpdateRoleRequest.d.ts +2 -2
  101. package/dist/runtime/api/models/UpdateRoleRequest.js +29 -0
  102. package/dist/runtime/api/models/UserInformation.d.ts +1 -1
  103. package/dist/runtime/api/models/UserInformation.js +30 -0
  104. package/dist/runtime/api/models/UserProfile.d.ts +2 -2
  105. package/dist/runtime/api/models/UserProfile.js +36 -0
  106. package/dist/runtime/api/models/Version.d.ts +1 -1
  107. package/dist/runtime/api/models/Version.js +29 -0
  108. package/dist/runtime/api/models/index.d.ts +39 -39
  109. package/dist/runtime/api/models/index.js +39 -0
  110. package/dist/runtime/api/runtime.d.ts +2 -3
  111. package/dist/runtime/api/{runtime.mjs → runtime.js} +0 -4
  112. package/dist/runtime/composables/mongocampApi.d.ts +1 -1
  113. package/dist/runtime/composables/{mongocampApi.mjs → mongocampApi.js} +3 -3
  114. package/dist/runtime/composables/mongocampAuth.d.ts +1 -1
  115. package/dist/runtime/composables/{mongocampAuth.mjs → mongocampAuth.js} +3 -3
  116. package/dist/runtime/composables/mongocampSearch.d.ts +1 -1
  117. package/dist/runtime/composables/{mongocampSearch.mjs → mongocampSearch.js} +1 -1
  118. package/dist/runtime/composables/mongocampStorage.d.ts +5 -0
  119. package/dist/runtime/composables/mongocampUser.d.ts +1 -1
  120. package/dist/types.d.mts +1 -16
  121. package/dist/types.d.ts +1 -16
  122. package/package.json +18 -17
  123. package/dist/runtime/api/apis/index.mjs +0 -11
  124. package/dist/runtime/api/index.mjs +0 -3
  125. package/dist/runtime/api/models/BucketInformation.mjs +0 -36
  126. package/dist/runtime/api/models/CollectionStatus.mjs +0 -63
  127. package/dist/runtime/api/models/DatabaseInfo.mjs +0 -39
  128. package/dist/runtime/api/models/FileInformation.mjs +0 -42
  129. package/dist/runtime/api/models/Grant.mjs +0 -39
  130. package/dist/runtime/api/models/IndexCreateRequest.mjs +0 -34
  131. package/dist/runtime/api/models/IndexOptionsRequest.mjs +0 -41
  132. package/dist/runtime/api/models/InsertResponse.mjs +0 -30
  133. package/dist/runtime/api/models/JobConfig.mjs +0 -42
  134. package/dist/runtime/api/models/JobInformation.mjs +0 -49
  135. package/dist/runtime/api/models/JsonSchema.mjs +0 -38
  136. package/dist/runtime/api/models/JsonSchemaDefinition.mjs +0 -39
  137. package/dist/runtime/api/models/MongoAggregateRequest.mjs +0 -34
  138. package/dist/runtime/api/models/MongoCampConfiguration.mjs +0 -39
  139. package/dist/runtime/api/models/MongoIndex.mjs +0 -60
  140. package/dist/runtime/api/models/Role.mjs +0 -37
  141. package/dist/runtime/api/models/SchemaAnalysis.mjs +0 -40
  142. package/dist/runtime/api/models/SchemaAnalysisField.mjs +0 -45
  143. package/dist/runtime/api/models/SettingsResponse.mjs +0 -34
  144. package/dist/runtime/api/models/UpdateFileInformationRequest.mjs +0 -29
  145. package/dist/runtime/api/models/UpdateResponse.mjs +0 -36
  146. package/dist/runtime/api/models/UpdateRoleRequest.mjs +0 -34
  147. package/dist/runtime/api/models/UserInformation.mjs +0 -35
  148. package/dist/runtime/api/models/UserProfile.mjs +0 -41
  149. package/dist/runtime/api/models/Version.mjs +0 -33
  150. package/dist/runtime/api/models/index.mjs +0 -39
  151. /package/dist/runtime/composables/{mongocampStorage.mjs → mongocampStorage.js} +0 -0
  152. /package/dist/runtime/composables/{mongocampUrl.mjs → mongocampUrl.js} +0 -0
  153. /package/dist/runtime/composables/{mongocampUser.mjs → mongocampUser.js} +0 -0
@@ -1,4 +1,4 @@
1
- import * as runtime from "../runtime.mjs";
1
+ import * as runtime from "../runtime.js";
2
2
  import {
3
3
  JsonValueBooleanFromJSON,
4
4
  JsonValueStringFromJSON,
@@ -6,7 +6,7 @@ import {
6
6
  LoginResultFromJSON,
7
7
  PasswordUpdateRequestToJSON,
8
8
  UserProfileFromJSON
9
- } from "../models/index.mjs";
9
+ } from "../models/index.js";
10
10
  export class AuthApi extends runtime.BaseAPI {
11
11
  /**
12
12
  * Generate new ApiKey of logged in User
@@ -26,7 +26,7 @@ export class AuthApi extends runtime.BaseAPI {
26
26
  }
27
27
  }
28
28
  if (this.configuration && this.configuration.apiKey) {
29
- headerParameters["X-AUTH-APIKEY"] = this.configuration.apiKey("X-AUTH-APIKEY");
29
+ headerParameters["X-AUTH-APIKEY"] = await this.configuration.apiKey("X-AUTH-APIKEY");
30
30
  }
31
31
  const response = await this.request({
32
32
  path: `/auth/profile/apikey`,
@@ -62,7 +62,7 @@ export class AuthApi extends runtime.BaseAPI {
62
62
  }
63
63
  }
64
64
  if (this.configuration && this.configuration.apiKey) {
65
- headerParameters["X-AUTH-APIKEY"] = this.configuration.apiKey("X-AUTH-APIKEY");
65
+ headerParameters["X-AUTH-APIKEY"] = await this.configuration.apiKey("X-AUTH-APIKEY");
66
66
  }
67
67
  const response = await this.request({
68
68
  path: `/auth/authenticated`,
@@ -85,8 +85,11 @@ export class AuthApi extends runtime.BaseAPI {
85
85
  * Login User
86
86
  */
87
87
  async loginRaw(requestParameters, initOverrides) {
88
- if (requestParameters.login === null || requestParameters.login === void 0) {
89
- throw new runtime.RequiredError("login", "Required parameter requestParameters.login was null or undefined when calling login.");
88
+ if (requestParameters["login"] == null) {
89
+ throw new runtime.RequiredError(
90
+ "login",
91
+ 'Required parameter "login" was null or undefined when calling login().'
92
+ );
90
93
  }
91
94
  const queryParameters = {};
92
95
  const headerParameters = {};
@@ -96,7 +99,7 @@ export class AuthApi extends runtime.BaseAPI {
96
99
  method: "POST",
97
100
  headers: headerParameters,
98
101
  query: queryParameters,
99
- body: LoginToJSON(requestParameters.login)
102
+ body: LoginToJSON(requestParameters["login"])
100
103
  }, initOverrides);
101
104
  return new runtime.JSONApiResponse(response, (jsonValue) => LoginResultFromJSON(jsonValue));
102
105
  }
@@ -126,7 +129,7 @@ export class AuthApi extends runtime.BaseAPI {
126
129
  }
127
130
  }
128
131
  if (this.configuration && this.configuration.apiKey) {
129
- headerParameters["X-AUTH-APIKEY"] = this.configuration.apiKey("X-AUTH-APIKEY");
132
+ headerParameters["X-AUTH-APIKEY"] = await this.configuration.apiKey("X-AUTH-APIKEY");
130
133
  }
131
134
  const response = await this.request({
132
135
  path: `/auth/logout`,
@@ -162,7 +165,7 @@ export class AuthApi extends runtime.BaseAPI {
162
165
  }
163
166
  }
164
167
  if (this.configuration && this.configuration.apiKey) {
165
- headerParameters["X-AUTH-APIKEY"] = this.configuration.apiKey("X-AUTH-APIKEY");
168
+ headerParameters["X-AUTH-APIKEY"] = await this.configuration.apiKey("X-AUTH-APIKEY");
166
169
  }
167
170
  const response = await this.request({
168
171
  path: `/auth/logout`,
@@ -198,7 +201,7 @@ export class AuthApi extends runtime.BaseAPI {
198
201
  }
199
202
  }
200
203
  if (this.configuration && this.configuration.apiKey) {
201
- headerParameters["X-AUTH-APIKEY"] = this.configuration.apiKey("X-AUTH-APIKEY");
204
+ headerParameters["X-AUTH-APIKEY"] = await this.configuration.apiKey("X-AUTH-APIKEY");
202
205
  }
203
206
  const response = await this.request({
204
207
  path: `/auth/token/refresh`,
@@ -221,8 +224,11 @@ export class AuthApi extends runtime.BaseAPI {
221
224
  * Update Password
222
225
  */
223
226
  async updatePasswordRaw(requestParameters, initOverrides) {
224
- if (requestParameters.passwordUpdateRequest === null || requestParameters.passwordUpdateRequest === void 0) {
225
- throw new runtime.RequiredError("passwordUpdateRequest", "Required parameter requestParameters.passwordUpdateRequest was null or undefined when calling updatePassword.");
227
+ if (requestParameters["passwordUpdateRequest"] == null) {
228
+ throw new runtime.RequiredError(
229
+ "passwordUpdateRequest",
230
+ 'Required parameter "passwordUpdateRequest" was null or undefined when calling updatePassword().'
231
+ );
226
232
  }
227
233
  const queryParameters = {};
228
234
  const headerParameters = {};
@@ -238,14 +244,14 @@ export class AuthApi extends runtime.BaseAPI {
238
244
  }
239
245
  }
240
246
  if (this.configuration && this.configuration.apiKey) {
241
- headerParameters["X-AUTH-APIKEY"] = this.configuration.apiKey("X-AUTH-APIKEY");
247
+ headerParameters["X-AUTH-APIKEY"] = await this.configuration.apiKey("X-AUTH-APIKEY");
242
248
  }
243
249
  const response = await this.request({
244
250
  path: `/auth/profile/password`,
245
251
  method: "PATCH",
246
252
  headers: headerParameters,
247
253
  query: queryParameters,
248
- body: PasswordUpdateRequestToJSON(requestParameters.passwordUpdateRequest)
254
+ body: PasswordUpdateRequestToJSON(requestParameters["passwordUpdateRequest"])
249
255
  }, initOverrides);
250
256
  return new runtime.JSONApiResponse(response, (jsonValue) => JsonValueBooleanFromJSON(jsonValue));
251
257
  }
@@ -275,7 +281,7 @@ export class AuthApi extends runtime.BaseAPI {
275
281
  }
276
282
  }
277
283
  if (this.configuration && this.configuration.apiKey) {
278
- headerParameters["X-AUTH-APIKEY"] = this.configuration.apiKey("X-AUTH-APIKEY");
284
+ headerParameters["X-AUTH-APIKEY"] = await this.configuration.apiKey("X-AUTH-APIKEY");
279
285
  }
280
286
  const response = await this.request({
281
287
  path: `/auth/profile`,
@@ -9,8 +9,8 @@
9
9
  * https://openapi-generator.tech
10
10
  * Do not edit the class manually.
11
11
  */
12
- import * as runtime from '../runtime';
13
- import type { BucketInformation, JsonValueBoolean } from '../models/index';
12
+ import * as runtime from '../runtime.js';
13
+ import type { BucketInformation, JsonValueBoolean } from '../models/index.js';
14
14
  export interface ClearBucketRequest {
15
15
  bucketName: string;
16
16
  }
@@ -1,16 +1,19 @@
1
- import * as runtime from "../runtime.mjs";
1
+ import * as runtime from "../runtime.js";
2
2
  import {
3
3
  BucketInformationFromJSON,
4
4
  JsonValueBooleanFromJSON
5
- } from "../models/index.mjs";
5
+ } from "../models/index.js";
6
6
  export class BucketApi extends runtime.BaseAPI {
7
7
  /**
8
8
  * Delete all Files in Bucket
9
9
  * Clear Bucket
10
10
  */
11
11
  async clearBucketRaw(requestParameters, initOverrides) {
12
- if (requestParameters.bucketName === null || requestParameters.bucketName === void 0) {
13
- throw new runtime.RequiredError("bucketName", "Required parameter requestParameters.bucketName was null or undefined when calling clearBucket.");
12
+ if (requestParameters["bucketName"] == null) {
13
+ throw new runtime.RequiredError(
14
+ "bucketName",
15
+ 'Required parameter "bucketName" was null or undefined when calling clearBucket().'
16
+ );
14
17
  }
15
18
  const queryParameters = {};
16
19
  const headerParameters = {};
@@ -25,10 +28,10 @@ export class BucketApi extends runtime.BaseAPI {
25
28
  }
26
29
  }
27
30
  if (this.configuration && this.configuration.apiKey) {
28
- headerParameters["X-AUTH-APIKEY"] = this.configuration.apiKey("X-AUTH-APIKEY");
31
+ headerParameters["X-AUTH-APIKEY"] = await this.configuration.apiKey("X-AUTH-APIKEY");
29
32
  }
30
33
  const response = await this.request({
31
- path: `/mongodb/buckets/{bucketName}/clear`.replace(`{${"bucketName"}}`, encodeURIComponent(String(requestParameters.bucketName))),
34
+ path: `/mongodb/buckets/{bucketName}/clear`.replace(`{${"bucketName"}}`, encodeURIComponent(String(requestParameters["bucketName"]))),
32
35
  method: "DELETE",
33
36
  headers: headerParameters,
34
37
  query: queryParameters
@@ -48,8 +51,11 @@ export class BucketApi extends runtime.BaseAPI {
48
51
  * Delete Bucket
49
52
  */
50
53
  async deleteBucketRaw(requestParameters, initOverrides) {
51
- if (requestParameters.bucketName === null || requestParameters.bucketName === void 0) {
52
- throw new runtime.RequiredError("bucketName", "Required parameter requestParameters.bucketName was null or undefined when calling deleteBucket.");
54
+ if (requestParameters["bucketName"] == null) {
55
+ throw new runtime.RequiredError(
56
+ "bucketName",
57
+ 'Required parameter "bucketName" was null or undefined when calling deleteBucket().'
58
+ );
53
59
  }
54
60
  const queryParameters = {};
55
61
  const headerParameters = {};
@@ -64,10 +70,10 @@ export class BucketApi extends runtime.BaseAPI {
64
70
  }
65
71
  }
66
72
  if (this.configuration && this.configuration.apiKey) {
67
- headerParameters["X-AUTH-APIKEY"] = this.configuration.apiKey("X-AUTH-APIKEY");
73
+ headerParameters["X-AUTH-APIKEY"] = await this.configuration.apiKey("X-AUTH-APIKEY");
68
74
  }
69
75
  const response = await this.request({
70
- path: `/mongodb/buckets/{bucketName}`.replace(`{${"bucketName"}}`, encodeURIComponent(String(requestParameters.bucketName))),
76
+ path: `/mongodb/buckets/{bucketName}`.replace(`{${"bucketName"}}`, encodeURIComponent(String(requestParameters["bucketName"]))),
71
77
  method: "DELETE",
72
78
  headers: headerParameters,
73
79
  query: queryParameters
@@ -87,8 +93,11 @@ export class BucketApi extends runtime.BaseAPI {
87
93
  * Bucket Information
88
94
  */
89
95
  async getBucketRaw(requestParameters, initOverrides) {
90
- if (requestParameters.bucketName === null || requestParameters.bucketName === void 0) {
91
- throw new runtime.RequiredError("bucketName", "Required parameter requestParameters.bucketName was null or undefined when calling getBucket.");
96
+ if (requestParameters["bucketName"] == null) {
97
+ throw new runtime.RequiredError(
98
+ "bucketName",
99
+ 'Required parameter "bucketName" was null or undefined when calling getBucket().'
100
+ );
92
101
  }
93
102
  const queryParameters = {};
94
103
  const headerParameters = {};
@@ -103,10 +112,10 @@ export class BucketApi extends runtime.BaseAPI {
103
112
  }
104
113
  }
105
114
  if (this.configuration && this.configuration.apiKey) {
106
- headerParameters["X-AUTH-APIKEY"] = this.configuration.apiKey("X-AUTH-APIKEY");
115
+ headerParameters["X-AUTH-APIKEY"] = await this.configuration.apiKey("X-AUTH-APIKEY");
107
116
  }
108
117
  const response = await this.request({
109
- path: `/mongodb/buckets/{bucketName}`.replace(`{${"bucketName"}}`, encodeURIComponent(String(requestParameters.bucketName))),
118
+ path: `/mongodb/buckets/{bucketName}`.replace(`{${"bucketName"}}`, encodeURIComponent(String(requestParameters["bucketName"]))),
110
119
  method: "GET",
111
120
  headers: headerParameters,
112
121
  query: queryParameters
@@ -139,7 +148,7 @@ export class BucketApi extends runtime.BaseAPI {
139
148
  }
140
149
  }
141
150
  if (this.configuration && this.configuration.apiKey) {
142
- headerParameters["X-AUTH-APIKEY"] = this.configuration.apiKey("X-AUTH-APIKEY");
151
+ headerParameters["X-AUTH-APIKEY"] = await this.configuration.apiKey("X-AUTH-APIKEY");
143
152
  }
144
153
  const response = await this.request({
145
154
  path: `/mongodb/buckets`,
@@ -9,8 +9,8 @@
9
9
  * https://openapi-generator.tech
10
10
  * Do not edit the class manually.
11
11
  */
12
- import * as runtime from '../runtime';
13
- import type { CollectionStatus, JsonSchema, JsonValueBoolean, MongoAggregateRequest, SchemaAnalysis } from '../models/index';
12
+ import * as runtime from '../runtime.js';
13
+ import type { CollectionStatus, JsonSchema, JsonValueBoolean, MongoAggregateRequest, SchemaAnalysis } from '../models/index.js';
14
14
  export interface AggregateRequest {
15
15
  collectionName: string;
16
16
  mongoAggregateRequest: MongoAggregateRequest;
@@ -1,29 +1,35 @@
1
- import * as runtime from "../runtime.mjs";
1
+ import * as runtime from "../runtime.js";
2
2
  import {
3
3
  CollectionStatusFromJSON,
4
4
  JsonSchemaFromJSON,
5
5
  JsonValueBooleanFromJSON,
6
6
  MongoAggregateRequestToJSON,
7
7
  SchemaAnalysisFromJSON
8
- } from "../models/index.mjs";
8
+ } from "../models/index.js";
9
9
  export class CollectionApi extends runtime.BaseAPI {
10
10
  /**
11
11
  * Aggregate in a given Collection
12
12
  * Aggregate in Collection
13
13
  */
14
14
  async aggregateRaw(requestParameters, initOverrides) {
15
- if (requestParameters.collectionName === null || requestParameters.collectionName === void 0) {
16
- throw new runtime.RequiredError("collectionName", "Required parameter requestParameters.collectionName was null or undefined when calling aggregate.");
17
- }
18
- if (requestParameters.mongoAggregateRequest === null || requestParameters.mongoAggregateRequest === void 0) {
19
- throw new runtime.RequiredError("mongoAggregateRequest", "Required parameter requestParameters.mongoAggregateRequest was null or undefined when calling aggregate.");
15
+ if (requestParameters["collectionName"] == null) {
16
+ throw new runtime.RequiredError(
17
+ "collectionName",
18
+ 'Required parameter "collectionName" was null or undefined when calling aggregate().'
19
+ );
20
+ }
21
+ if (requestParameters["mongoAggregateRequest"] == null) {
22
+ throw new runtime.RequiredError(
23
+ "mongoAggregateRequest",
24
+ 'Required parameter "mongoAggregateRequest" was null or undefined when calling aggregate().'
25
+ );
20
26
  }
21
27
  const queryParameters = {};
22
- if (requestParameters.rowsPerPage !== void 0) {
23
- queryParameters["rowsPerPage"] = requestParameters.rowsPerPage;
28
+ if (requestParameters["rowsPerPage"] != null) {
29
+ queryParameters["rowsPerPage"] = requestParameters["rowsPerPage"];
24
30
  }
25
- if (requestParameters.page !== void 0) {
26
- queryParameters["page"] = requestParameters.page;
31
+ if (requestParameters["page"] != null) {
32
+ queryParameters["page"] = requestParameters["page"];
27
33
  }
28
34
  const headerParameters = {};
29
35
  headerParameters["Content-Type"] = "application/json";
@@ -38,14 +44,14 @@ export class CollectionApi extends runtime.BaseAPI {
38
44
  }
39
45
  }
40
46
  if (this.configuration && this.configuration.apiKey) {
41
- headerParameters["X-AUTH-APIKEY"] = this.configuration.apiKey("X-AUTH-APIKEY");
47
+ headerParameters["X-AUTH-APIKEY"] = await this.configuration.apiKey("X-AUTH-APIKEY");
42
48
  }
43
49
  const response = await this.request({
44
- path: `/mongodb/collections/{collectionName}/aggregate`.replace(`{${"collectionName"}}`, encodeURIComponent(String(requestParameters.collectionName))),
50
+ path: `/mongodb/collections/{collectionName}/aggregate`.replace(`{${"collectionName"}}`, encodeURIComponent(String(requestParameters["collectionName"]))),
45
51
  method: "POST",
46
52
  headers: headerParameters,
47
53
  query: queryParameters,
48
- body: MongoAggregateRequestToJSON(requestParameters.mongoAggregateRequest)
54
+ body: MongoAggregateRequestToJSON(requestParameters["mongoAggregateRequest"])
49
55
  }, initOverrides);
50
56
  return new runtime.JSONApiResponse(response);
51
57
  }
@@ -62,8 +68,11 @@ export class CollectionApi extends runtime.BaseAPI {
62
68
  * Clear Collection
63
69
  */
64
70
  async clearCollectionRaw(requestParameters, initOverrides) {
65
- if (requestParameters.collectionName === null || requestParameters.collectionName === void 0) {
66
- throw new runtime.RequiredError("collectionName", "Required parameter requestParameters.collectionName was null or undefined when calling clearCollection.");
71
+ if (requestParameters["collectionName"] == null) {
72
+ throw new runtime.RequiredError(
73
+ "collectionName",
74
+ 'Required parameter "collectionName" was null or undefined when calling clearCollection().'
75
+ );
67
76
  }
68
77
  const queryParameters = {};
69
78
  const headerParameters = {};
@@ -78,10 +87,10 @@ export class CollectionApi extends runtime.BaseAPI {
78
87
  }
79
88
  }
80
89
  if (this.configuration && this.configuration.apiKey) {
81
- headerParameters["X-AUTH-APIKEY"] = this.configuration.apiKey("X-AUTH-APIKEY");
90
+ headerParameters["X-AUTH-APIKEY"] = await this.configuration.apiKey("X-AUTH-APIKEY");
82
91
  }
83
92
  const response = await this.request({
84
- path: `/mongodb/collections/{collectionName}/clear`.replace(`{${"collectionName"}}`, encodeURIComponent(String(requestParameters.collectionName))),
93
+ path: `/mongodb/collections/{collectionName}/clear`.replace(`{${"collectionName"}}`, encodeURIComponent(String(requestParameters["collectionName"]))),
85
94
  method: "DELETE",
86
95
  headers: headerParameters,
87
96
  query: queryParameters
@@ -101,8 +110,11 @@ export class CollectionApi extends runtime.BaseAPI {
101
110
  * Delete Collection
102
111
  */
103
112
  async deleteCollectionRaw(requestParameters, initOverrides) {
104
- if (requestParameters.collectionName === null || requestParameters.collectionName === void 0) {
105
- throw new runtime.RequiredError("collectionName", "Required parameter requestParameters.collectionName was null or undefined when calling deleteCollection.");
113
+ if (requestParameters["collectionName"] == null) {
114
+ throw new runtime.RequiredError(
115
+ "collectionName",
116
+ 'Required parameter "collectionName" was null or undefined when calling deleteCollection().'
117
+ );
106
118
  }
107
119
  const queryParameters = {};
108
120
  const headerParameters = {};
@@ -117,10 +129,10 @@ export class CollectionApi extends runtime.BaseAPI {
117
129
  }
118
130
  }
119
131
  if (this.configuration && this.configuration.apiKey) {
120
- headerParameters["X-AUTH-APIKEY"] = this.configuration.apiKey("X-AUTH-APIKEY");
132
+ headerParameters["X-AUTH-APIKEY"] = await this.configuration.apiKey("X-AUTH-APIKEY");
121
133
  }
122
134
  const response = await this.request({
123
- path: `/mongodb/collections/{collectionName}`.replace(`{${"collectionName"}}`, encodeURIComponent(String(requestParameters.collectionName))),
135
+ path: `/mongodb/collections/{collectionName}`.replace(`{${"collectionName"}}`, encodeURIComponent(String(requestParameters["collectionName"]))),
124
136
  method: "DELETE",
125
137
  headers: headerParameters,
126
138
  query: queryParameters
@@ -140,18 +152,24 @@ export class CollectionApi extends runtime.BaseAPI {
140
152
  * Distinct in Collection
141
153
  */
142
154
  async distinctRaw(requestParameters, initOverrides) {
143
- if (requestParameters.collectionName === null || requestParameters.collectionName === void 0) {
144
- throw new runtime.RequiredError("collectionName", "Required parameter requestParameters.collectionName was null or undefined when calling distinct.");
145
- }
146
- if (requestParameters.field === null || requestParameters.field === void 0) {
147
- throw new runtime.RequiredError("field", "Required parameter requestParameters.field was null or undefined when calling distinct.");
155
+ if (requestParameters["collectionName"] == null) {
156
+ throw new runtime.RequiredError(
157
+ "collectionName",
158
+ 'Required parameter "collectionName" was null or undefined when calling distinct().'
159
+ );
160
+ }
161
+ if (requestParameters["field"] == null) {
162
+ throw new runtime.RequiredError(
163
+ "field",
164
+ 'Required parameter "field" was null or undefined when calling distinct().'
165
+ );
148
166
  }
149
167
  const queryParameters = {};
150
- if (requestParameters.rowsPerPage !== void 0) {
151
- queryParameters["rowsPerPage"] = requestParameters.rowsPerPage;
168
+ if (requestParameters["rowsPerPage"] != null) {
169
+ queryParameters["rowsPerPage"] = requestParameters["rowsPerPage"];
152
170
  }
153
- if (requestParameters.page !== void 0) {
154
- queryParameters["page"] = requestParameters.page;
171
+ if (requestParameters["page"] != null) {
172
+ queryParameters["page"] = requestParameters["page"];
155
173
  }
156
174
  const headerParameters = {};
157
175
  if (this.configuration && (this.configuration.username !== void 0 || this.configuration.password !== void 0)) {
@@ -165,10 +183,10 @@ export class CollectionApi extends runtime.BaseAPI {
165
183
  }
166
184
  }
167
185
  if (this.configuration && this.configuration.apiKey) {
168
- headerParameters["X-AUTH-APIKEY"] = this.configuration.apiKey("X-AUTH-APIKEY");
186
+ headerParameters["X-AUTH-APIKEY"] = await this.configuration.apiKey("X-AUTH-APIKEY");
169
187
  }
170
188
  const response = await this.request({
171
- path: `/mongodb/collections/{collectionName}/distinct/{field}`.replace(`{${"collectionName"}}`, encodeURIComponent(String(requestParameters.collectionName))).replace(`{${"field"}}`, encodeURIComponent(String(requestParameters.field))),
189
+ path: `/mongodb/collections/{collectionName}/distinct/{field}`.replace(`{${"collectionName"}}`, encodeURIComponent(String(requestParameters["collectionName"]))).replace(`{${"field"}}`, encodeURIComponent(String(requestParameters["field"]))),
172
190
  method: "POST",
173
191
  headers: headerParameters,
174
192
  query: queryParameters
@@ -188,12 +206,15 @@ export class CollectionApi extends runtime.BaseAPI {
188
206
  * Collection Fields
189
207
  */
190
208
  async getCollectionFieldsRaw(requestParameters, initOverrides) {
191
- if (requestParameters.collectionName === null || requestParameters.collectionName === void 0) {
192
- throw new runtime.RequiredError("collectionName", "Required parameter requestParameters.collectionName was null or undefined when calling getCollectionFields.");
209
+ if (requestParameters["collectionName"] == null) {
210
+ throw new runtime.RequiredError(
211
+ "collectionName",
212
+ 'Required parameter "collectionName" was null or undefined when calling getCollectionFields().'
213
+ );
193
214
  }
194
215
  const queryParameters = {};
195
- if (requestParameters.sampleSize !== void 0) {
196
- queryParameters["sample size"] = requestParameters.sampleSize;
216
+ if (requestParameters["sampleSize"] != null) {
217
+ queryParameters["sample size"] = requestParameters["sampleSize"];
197
218
  }
198
219
  const headerParameters = {};
199
220
  if (this.configuration && (this.configuration.username !== void 0 || this.configuration.password !== void 0)) {
@@ -207,10 +228,10 @@ export class CollectionApi extends runtime.BaseAPI {
207
228
  }
208
229
  }
209
230
  if (this.configuration && this.configuration.apiKey) {
210
- headerParameters["X-AUTH-APIKEY"] = this.configuration.apiKey("X-AUTH-APIKEY");
231
+ headerParameters["X-AUTH-APIKEY"] = await this.configuration.apiKey("X-AUTH-APIKEY");
211
232
  }
212
233
  const response = await this.request({
213
- path: `/mongodb/collections/{collectionName}/fields`.replace(`{${"collectionName"}}`, encodeURIComponent(String(requestParameters.collectionName))),
234
+ path: `/mongodb/collections/{collectionName}/fields`.replace(`{${"collectionName"}}`, encodeURIComponent(String(requestParameters["collectionName"]))),
214
235
  method: "GET",
215
236
  headers: headerParameters,
216
237
  query: queryParameters
@@ -230,12 +251,15 @@ export class CollectionApi extends runtime.BaseAPI {
230
251
  * Collection Information
231
252
  */
232
253
  async getCollectionInformationRaw(requestParameters, initOverrides) {
233
- if (requestParameters.collectionName === null || requestParameters.collectionName === void 0) {
234
- throw new runtime.RequiredError("collectionName", "Required parameter requestParameters.collectionName was null or undefined when calling getCollectionInformation.");
254
+ if (requestParameters["collectionName"] == null) {
255
+ throw new runtime.RequiredError(
256
+ "collectionName",
257
+ 'Required parameter "collectionName" was null or undefined when calling getCollectionInformation().'
258
+ );
235
259
  }
236
260
  const queryParameters = {};
237
- if (requestParameters.includeDetails !== void 0) {
238
- queryParameters["includeDetails"] = requestParameters.includeDetails;
261
+ if (requestParameters["includeDetails"] != null) {
262
+ queryParameters["includeDetails"] = requestParameters["includeDetails"];
239
263
  }
240
264
  const headerParameters = {};
241
265
  if (this.configuration && (this.configuration.username !== void 0 || this.configuration.password !== void 0)) {
@@ -249,10 +273,10 @@ export class CollectionApi extends runtime.BaseAPI {
249
273
  }
250
274
  }
251
275
  if (this.configuration && this.configuration.apiKey) {
252
- headerParameters["X-AUTH-APIKEY"] = this.configuration.apiKey("X-AUTH-APIKEY");
276
+ headerParameters["X-AUTH-APIKEY"] = await this.configuration.apiKey("X-AUTH-APIKEY");
253
277
  }
254
278
  const response = await this.request({
255
- path: `/mongodb/collections/{collectionName}`.replace(`{${"collectionName"}}`, encodeURIComponent(String(requestParameters.collectionName))),
279
+ path: `/mongodb/collections/{collectionName}`.replace(`{${"collectionName"}}`, encodeURIComponent(String(requestParameters["collectionName"]))),
256
280
  method: "GET",
257
281
  headers: headerParameters,
258
282
  query: queryParameters
@@ -272,15 +296,18 @@ export class CollectionApi extends runtime.BaseAPI {
272
296
  * Collection Fields
273
297
  */
274
298
  async getJsonSchemaRaw(requestParameters, initOverrides) {
275
- if (requestParameters.collectionName === null || requestParameters.collectionName === void 0) {
276
- throw new runtime.RequiredError("collectionName", "Required parameter requestParameters.collectionName was null or undefined when calling getJsonSchema.");
299
+ if (requestParameters["collectionName"] == null) {
300
+ throw new runtime.RequiredError(
301
+ "collectionName",
302
+ 'Required parameter "collectionName" was null or undefined when calling getJsonSchema().'
303
+ );
277
304
  }
278
305
  const queryParameters = {};
279
- if (requestParameters.sampleSize !== void 0) {
280
- queryParameters["sampleSize"] = requestParameters.sampleSize;
306
+ if (requestParameters["sampleSize"] != null) {
307
+ queryParameters["sampleSize"] = requestParameters["sampleSize"];
281
308
  }
282
- if (requestParameters.deepth !== void 0) {
283
- queryParameters["deepth"] = requestParameters.deepth;
309
+ if (requestParameters["deepth"] != null) {
310
+ queryParameters["deepth"] = requestParameters["deepth"];
284
311
  }
285
312
  const headerParameters = {};
286
313
  if (this.configuration && (this.configuration.username !== void 0 || this.configuration.password !== void 0)) {
@@ -294,10 +321,10 @@ export class CollectionApi extends runtime.BaseAPI {
294
321
  }
295
322
  }
296
323
  if (this.configuration && this.configuration.apiKey) {
297
- headerParameters["X-AUTH-APIKEY"] = this.configuration.apiKey("X-AUTH-APIKEY");
324
+ headerParameters["X-AUTH-APIKEY"] = await this.configuration.apiKey("X-AUTH-APIKEY");
298
325
  }
299
326
  const response = await this.request({
300
- path: `/mongodb/collections/{collectionName}/schema`.replace(`{${"collectionName"}}`, encodeURIComponent(String(requestParameters.collectionName))),
327
+ path: `/mongodb/collections/{collectionName}/schema`.replace(`{${"collectionName"}}`, encodeURIComponent(String(requestParameters["collectionName"]))),
301
328
  method: "GET",
302
329
  headers: headerParameters,
303
330
  query: queryParameters
@@ -317,15 +344,18 @@ export class CollectionApi extends runtime.BaseAPI {
317
344
  * Collection Fields
318
345
  */
319
346
  async getSchemaAnalysisRaw(requestParameters, initOverrides) {
320
- if (requestParameters.collectionName === null || requestParameters.collectionName === void 0) {
321
- throw new runtime.RequiredError("collectionName", "Required parameter requestParameters.collectionName was null or undefined when calling getSchemaAnalysis.");
347
+ if (requestParameters["collectionName"] == null) {
348
+ throw new runtime.RequiredError(
349
+ "collectionName",
350
+ 'Required parameter "collectionName" was null or undefined when calling getSchemaAnalysis().'
351
+ );
322
352
  }
323
353
  const queryParameters = {};
324
- if (requestParameters.sampleSize !== void 0) {
325
- queryParameters["sampleSize"] = requestParameters.sampleSize;
354
+ if (requestParameters["sampleSize"] != null) {
355
+ queryParameters["sampleSize"] = requestParameters["sampleSize"];
326
356
  }
327
- if (requestParameters.deepth !== void 0) {
328
- queryParameters["deepth"] = requestParameters.deepth;
357
+ if (requestParameters["deepth"] != null) {
358
+ queryParameters["deepth"] = requestParameters["deepth"];
329
359
  }
330
360
  const headerParameters = {};
331
361
  if (this.configuration && (this.configuration.username !== void 0 || this.configuration.password !== void 0)) {
@@ -339,10 +369,10 @@ export class CollectionApi extends runtime.BaseAPI {
339
369
  }
340
370
  }
341
371
  if (this.configuration && this.configuration.apiKey) {
342
- headerParameters["X-AUTH-APIKEY"] = this.configuration.apiKey("X-AUTH-APIKEY");
372
+ headerParameters["X-AUTH-APIKEY"] = await this.configuration.apiKey("X-AUTH-APIKEY");
343
373
  }
344
374
  const response = await this.request({
345
- path: `/mongodb/collections/{collectionName}/schema/analysis`.replace(`{${"collectionName"}}`, encodeURIComponent(String(requestParameters.collectionName))),
375
+ path: `/mongodb/collections/{collectionName}/schema/analysis`.replace(`{${"collectionName"}}`, encodeURIComponent(String(requestParameters["collectionName"]))),
346
376
  method: "GET",
347
377
  headers: headerParameters,
348
378
  query: queryParameters
@@ -375,7 +405,7 @@ export class CollectionApi extends runtime.BaseAPI {
375
405
  }
376
406
  }
377
407
  if (this.configuration && this.configuration.apiKey) {
378
- headerParameters["X-AUTH-APIKEY"] = this.configuration.apiKey("X-AUTH-APIKEY");
408
+ headerParameters["X-AUTH-APIKEY"] = await this.configuration.apiKey("X-AUTH-APIKEY");
379
409
  }
380
410
  const response = await this.request({
381
411
  path: `/mongodb/collections`,
@@ -398,8 +428,11 @@ export class CollectionApi extends runtime.BaseAPI {
398
428
  * List of Collections
399
429
  */
400
430
  async listCollectionsByDatabaseRaw(requestParameters, initOverrides) {
401
- if (requestParameters.databaseName === null || requestParameters.databaseName === void 0) {
402
- throw new runtime.RequiredError("databaseName", "Required parameter requestParameters.databaseName was null or undefined when calling listCollectionsByDatabase.");
431
+ if (requestParameters["databaseName"] == null) {
432
+ throw new runtime.RequiredError(
433
+ "databaseName",
434
+ 'Required parameter "databaseName" was null or undefined when calling listCollectionsByDatabase().'
435
+ );
403
436
  }
404
437
  const queryParameters = {};
405
438
  const headerParameters = {};
@@ -414,10 +447,10 @@ export class CollectionApi extends runtime.BaseAPI {
414
447
  }
415
448
  }
416
449
  if (this.configuration && this.configuration.apiKey) {
417
- headerParameters["X-AUTH-APIKEY"] = this.configuration.apiKey("X-AUTH-APIKEY");
450
+ headerParameters["X-AUTH-APIKEY"] = await this.configuration.apiKey("X-AUTH-APIKEY");
418
451
  }
419
452
  const response = await this.request({
420
- path: `/mongodb/databases/{databaseName}/collections`.replace(`{${"databaseName"}}`, encodeURIComponent(String(requestParameters.databaseName))),
453
+ path: `/mongodb/databases/{databaseName}/collections`.replace(`{${"databaseName"}}`, encodeURIComponent(String(requestParameters["databaseName"]))),
421
454
  method: "GET",
422
455
  headers: headerParameters,
423
456
  query: queryParameters
@@ -9,8 +9,8 @@
9
9
  * https://openapi-generator.tech
10
10
  * Do not edit the class manually.
11
11
  */
12
- import * as runtime from '../runtime';
13
- import type { DatabaseInfo, JsonValueBoolean } from '../models/index';
12
+ import * as runtime from '../runtime.js';
13
+ import type { DatabaseInfo, JsonValueBoolean } from '../models/index.js';
14
14
  export interface DeleteDatabaseRequest {
15
15
  databaseName: string;
16
16
  }