@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.
- package/README.md +1 -1
- package/dist/module.json +5 -1
- package/dist/module.mjs +1 -1
- package/dist/runtime/api/apis/AdminApi.d.ts +2 -2
- package/dist/runtime/api/apis/{AdminApi.mjs → AdminApi.js} +101 -65
- package/dist/runtime/api/apis/ApplicationApi.d.ts +2 -2
- package/dist/runtime/api/apis/{ApplicationApi.mjs → ApplicationApi.js} +24 -15
- package/dist/runtime/api/apis/AuthApi.d.ts +2 -2
- package/dist/runtime/api/apis/{AuthApi.mjs → AuthApi.js} +21 -15
- package/dist/runtime/api/apis/BucketApi.d.ts +2 -2
- package/dist/runtime/api/apis/{BucketApi.mjs → BucketApi.js} +24 -15
- package/dist/runtime/api/apis/CollectionApi.d.ts +2 -2
- package/dist/runtime/api/apis/{CollectionApi.mjs → CollectionApi.js} +99 -66
- package/dist/runtime/api/apis/DatabaseApi.d.ts +2 -2
- package/dist/runtime/api/apis/{DatabaseApi.mjs → DatabaseApi.js} +25 -16
- package/dist/runtime/api/apis/DocumentApi.d.ts +6 -6
- package/dist/runtime/api/apis/{DocumentApi.mjs → DocumentApi.js} +153 -93
- package/dist/runtime/api/apis/FileApi.d.ts +2 -2
- package/dist/runtime/api/apis/{FileApi.mjs → FileApi.js} +121 -76
- package/dist/runtime/api/apis/IndexApi.d.ts +2 -2
- package/dist/runtime/api/apis/{IndexApi.mjs → IndexApi.js} +119 -71
- package/dist/runtime/api/apis/InformationApi.d.ts +2 -2
- package/dist/runtime/api/apis/{InformationApi.mjs → InformationApi.js} +2 -2
- package/dist/runtime/api/apis/JobsApi.d.ts +2 -2
- package/dist/runtime/api/apis/{JobsApi.mjs → JobsApi.js} +53 -29
- package/dist/runtime/api/apis/index.d.ts +11 -11
- package/dist/runtime/api/apis/index.js +11 -0
- package/dist/runtime/api/index.d.ts +3 -3
- package/dist/runtime/api/index.js +3 -0
- package/dist/runtime/api/models/BucketInformation.d.ts +1 -1
- package/dist/runtime/api/models/BucketInformation.js +32 -0
- package/dist/runtime/api/models/CollectionStatus.d.ts +3 -3
- package/dist/runtime/api/models/CollectionStatus.js +59 -0
- package/dist/runtime/api/models/DatabaseInfo.d.ts +2 -2
- package/dist/runtime/api/models/DatabaseInfo.js +35 -0
- package/dist/runtime/api/models/DeleteResponse.d.ts +1 -1
- package/dist/runtime/api/models/{DeleteResponse.mjs → DeleteResponse.js} +8 -12
- package/dist/runtime/api/models/ErrorDescription.d.ts +1 -1
- package/dist/runtime/api/models/{ErrorDescription.mjs → ErrorDescription.js} +10 -14
- package/dist/runtime/api/models/FileInformation.d.ts +2 -2
- package/dist/runtime/api/models/FileInformation.js +38 -0
- package/dist/runtime/api/models/Grant.d.ts +1 -1
- package/dist/runtime/api/models/Grant.js +35 -0
- package/dist/runtime/api/models/IndexCreateRequest.d.ts +3 -3
- package/dist/runtime/api/models/IndexCreateRequest.js +29 -0
- package/dist/runtime/api/models/IndexCreateResponse.d.ts +1 -1
- package/dist/runtime/api/models/{IndexCreateResponse.mjs → IndexCreateResponse.js} +6 -10
- package/dist/runtime/api/models/IndexDropResponse.d.ts +1 -1
- package/dist/runtime/api/models/{IndexDropResponse.mjs → IndexDropResponse.js} +6 -10
- package/dist/runtime/api/models/IndexOptionsRequest.d.ts +1 -1
- package/dist/runtime/api/models/IndexOptionsRequest.js +36 -0
- package/dist/runtime/api/models/InsertResponse.d.ts +1 -1
- package/dist/runtime/api/models/InsertResponse.js +25 -0
- package/dist/runtime/api/models/JobConfig.d.ts +1 -1
- package/dist/runtime/api/models/JobConfig.js +38 -0
- package/dist/runtime/api/models/JobInformation.d.ts +1 -1
- package/dist/runtime/api/models/JobInformation.js +44 -0
- package/dist/runtime/api/models/JsonSchema.d.ts +3 -3
- package/dist/runtime/api/models/JsonSchema.js +34 -0
- package/dist/runtime/api/models/JsonSchemaDefinition.d.ts +2 -2
- package/dist/runtime/api/models/JsonSchemaDefinition.js +34 -0
- package/dist/runtime/api/models/JsonValueAny.d.ts +1 -1
- package/dist/runtime/api/models/{JsonValueAny.mjs → JsonValueAny.js} +6 -10
- package/dist/runtime/api/models/JsonValueBoolean.d.ts +1 -1
- package/dist/runtime/api/models/{JsonValueBoolean.mjs → JsonValueBoolean.js} +6 -10
- package/dist/runtime/api/models/JsonValueString.d.ts +1 -1
- package/dist/runtime/api/models/{JsonValueString.mjs → JsonValueString.js} +6 -10
- package/dist/runtime/api/models/Login.d.ts +1 -1
- package/dist/runtime/api/models/{Login.mjs → Login.js} +8 -12
- package/dist/runtime/api/models/LoginResult.d.ts +2 -2
- package/dist/runtime/api/models/{LoginResult.mjs → LoginResult.js} +11 -15
- package/dist/runtime/api/models/MongoAggregateRequest.d.ts +2 -2
- package/dist/runtime/api/models/MongoAggregateRequest.js +29 -0
- package/dist/runtime/api/models/MongoCampConfiguration.d.ts +1 -1
- package/dist/runtime/api/models/MongoCampConfiguration.js +35 -0
- package/dist/runtime/api/models/MongoFindRequest.d.ts +4 -4
- package/dist/runtime/api/models/{MongoFindRequest.mjs → MongoFindRequest.js} +10 -14
- package/dist/runtime/api/models/MongoIndex.d.ts +4 -4
- package/dist/runtime/api/models/MongoIndex.js +55 -0
- package/dist/runtime/api/models/PasswordUpdateRequest.d.ts +1 -1
- package/dist/runtime/api/models/{PasswordUpdateRequest.mjs → PasswordUpdateRequest.js} +6 -10
- package/dist/runtime/api/models/PipelineStage.d.ts +1 -1
- package/dist/runtime/api/models/{PipelineStage.mjs → PipelineStage.js} +8 -12
- package/dist/runtime/api/models/Role.d.ts +2 -2
- package/dist/runtime/api/models/Role.js +32 -0
- package/dist/runtime/api/models/SchemaAnalysis.d.ts +2 -2
- package/dist/runtime/api/models/SchemaAnalysis.js +35 -0
- package/dist/runtime/api/models/SchemaAnalysisField.d.ts +2 -2
- package/dist/runtime/api/models/SchemaAnalysisField.js +40 -0
- package/dist/runtime/api/models/SchemaAnalysisFieldType.d.ts +1 -1
- package/dist/runtime/api/models/{SchemaAnalysisFieldType.mjs → SchemaAnalysisFieldType.js} +10 -14
- package/dist/runtime/api/models/SettingsResponse.d.ts +2 -2
- package/dist/runtime/api/models/SettingsResponse.js +29 -0
- package/dist/runtime/api/models/UpdateFileInformationRequest.d.ts +2 -2
- package/dist/runtime/api/models/UpdateFileInformationRequest.js +24 -0
- package/dist/runtime/api/models/UpdateRequest.d.ts +3 -3
- package/dist/runtime/api/models/{UpdateRequest.mjs → UpdateRequest.js} +8 -12
- package/dist/runtime/api/models/UpdateResponse.d.ts +1 -1
- package/dist/runtime/api/models/UpdateResponse.js +31 -0
- package/dist/runtime/api/models/UpdateRoleRequest.d.ts +2 -2
- package/dist/runtime/api/models/UpdateRoleRequest.js +29 -0
- package/dist/runtime/api/models/UserInformation.d.ts +1 -1
- package/dist/runtime/api/models/UserInformation.js +30 -0
- package/dist/runtime/api/models/UserProfile.d.ts +2 -2
- package/dist/runtime/api/models/UserProfile.js +36 -0
- package/dist/runtime/api/models/Version.d.ts +1 -1
- package/dist/runtime/api/models/Version.js +29 -0
- package/dist/runtime/api/models/index.d.ts +39 -39
- package/dist/runtime/api/models/index.js +39 -0
- package/dist/runtime/api/runtime.d.ts +2 -3
- package/dist/runtime/api/{runtime.mjs → runtime.js} +0 -4
- package/dist/runtime/composables/mongocampApi.d.ts +1 -1
- package/dist/runtime/composables/{mongocampApi.mjs → mongocampApi.js} +3 -3
- package/dist/runtime/composables/mongocampAuth.d.ts +1 -1
- package/dist/runtime/composables/{mongocampAuth.mjs → mongocampAuth.js} +3 -3
- package/dist/runtime/composables/mongocampSearch.d.ts +1 -1
- package/dist/runtime/composables/{mongocampSearch.mjs → mongocampSearch.js} +1 -1
- package/dist/runtime/composables/mongocampStorage.d.ts +5 -0
- package/dist/runtime/composables/mongocampUser.d.ts +1 -1
- package/dist/types.d.mts +1 -16
- package/dist/types.d.ts +1 -16
- package/package.json +18 -17
- package/dist/runtime/api/apis/index.mjs +0 -11
- package/dist/runtime/api/index.mjs +0 -3
- package/dist/runtime/api/models/BucketInformation.mjs +0 -36
- package/dist/runtime/api/models/CollectionStatus.mjs +0 -63
- package/dist/runtime/api/models/DatabaseInfo.mjs +0 -39
- package/dist/runtime/api/models/FileInformation.mjs +0 -42
- package/dist/runtime/api/models/Grant.mjs +0 -39
- package/dist/runtime/api/models/IndexCreateRequest.mjs +0 -34
- package/dist/runtime/api/models/IndexOptionsRequest.mjs +0 -41
- package/dist/runtime/api/models/InsertResponse.mjs +0 -30
- package/dist/runtime/api/models/JobConfig.mjs +0 -42
- package/dist/runtime/api/models/JobInformation.mjs +0 -49
- package/dist/runtime/api/models/JsonSchema.mjs +0 -38
- package/dist/runtime/api/models/JsonSchemaDefinition.mjs +0 -39
- package/dist/runtime/api/models/MongoAggregateRequest.mjs +0 -34
- package/dist/runtime/api/models/MongoCampConfiguration.mjs +0 -39
- package/dist/runtime/api/models/MongoIndex.mjs +0 -60
- package/dist/runtime/api/models/Role.mjs +0 -37
- package/dist/runtime/api/models/SchemaAnalysis.mjs +0 -40
- package/dist/runtime/api/models/SchemaAnalysisField.mjs +0 -45
- package/dist/runtime/api/models/SettingsResponse.mjs +0 -34
- package/dist/runtime/api/models/UpdateFileInformationRequest.mjs +0 -29
- package/dist/runtime/api/models/UpdateResponse.mjs +0 -36
- package/dist/runtime/api/models/UpdateRoleRequest.mjs +0 -34
- package/dist/runtime/api/models/UserInformation.mjs +0 -35
- package/dist/runtime/api/models/UserProfile.mjs +0 -41
- package/dist/runtime/api/models/Version.mjs +0 -33
- package/dist/runtime/api/models/index.mjs +0 -39
- /package/dist/runtime/composables/{mongocampStorage.mjs → mongocampStorage.js} +0 -0
- /package/dist/runtime/composables/{mongocampUrl.mjs → mongocampUrl.js} +0 -0
- /package/dist/runtime/composables/{mongocampUser.mjs → mongocampUser.js} +0 -0
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import * as runtime from "../runtime.
|
|
1
|
+
import * as runtime from "../runtime.js";
|
|
2
2
|
import {
|
|
3
3
|
DeleteResponseFromJSON,
|
|
4
4
|
FileInformationFromJSON,
|
|
@@ -6,18 +6,24 @@ import {
|
|
|
6
6
|
MongoFindRequestToJSON,
|
|
7
7
|
UpdateFileInformationRequestToJSON,
|
|
8
8
|
UpdateResponseFromJSON
|
|
9
|
-
} from "../models/index.
|
|
9
|
+
} from "../models/index.js";
|
|
10
10
|
export class FileApi extends runtime.BaseAPI {
|
|
11
11
|
/**
|
|
12
12
|
* Delete one File from given Bucket
|
|
13
13
|
* Delete File from Bucket
|
|
14
14
|
*/
|
|
15
15
|
async deleteFileRaw(requestParameters, initOverrides) {
|
|
16
|
-
if (requestParameters
|
|
17
|
-
throw new runtime.RequiredError(
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
16
|
+
if (requestParameters["bucketName"] == null) {
|
|
17
|
+
throw new runtime.RequiredError(
|
|
18
|
+
"bucketName",
|
|
19
|
+
'Required parameter "bucketName" was null or undefined when calling deleteFile().'
|
|
20
|
+
);
|
|
21
|
+
}
|
|
22
|
+
if (requestParameters["fileId"] == null) {
|
|
23
|
+
throw new runtime.RequiredError(
|
|
24
|
+
"fileId",
|
|
25
|
+
'Required parameter "fileId" was null or undefined when calling deleteFile().'
|
|
26
|
+
);
|
|
21
27
|
}
|
|
22
28
|
const queryParameters = {};
|
|
23
29
|
const headerParameters = {};
|
|
@@ -32,10 +38,10 @@ export class FileApi extends runtime.BaseAPI {
|
|
|
32
38
|
}
|
|
33
39
|
}
|
|
34
40
|
if (this.configuration && this.configuration.apiKey) {
|
|
35
|
-
headerParameters["X-AUTH-APIKEY"] = this.configuration.apiKey("X-AUTH-APIKEY");
|
|
41
|
+
headerParameters["X-AUTH-APIKEY"] = await this.configuration.apiKey("X-AUTH-APIKEY");
|
|
36
42
|
}
|
|
37
43
|
const response = await this.request({
|
|
38
|
-
path: `/mongodb/buckets/{bucketName}/files/{fileId}`.replace(`{${"bucketName"}}`, encodeURIComponent(String(requestParameters
|
|
44
|
+
path: `/mongodb/buckets/{bucketName}/files/{fileId}`.replace(`{${"bucketName"}}`, encodeURIComponent(String(requestParameters["bucketName"]))).replace(`{${"fileId"}}`, encodeURIComponent(String(requestParameters["fileId"]))),
|
|
39
45
|
method: "DELETE",
|
|
40
46
|
headers: headerParameters,
|
|
41
47
|
query: queryParameters
|
|
@@ -55,18 +61,24 @@ export class FileApi extends runtime.BaseAPI {
|
|
|
55
61
|
* Files in Bucket
|
|
56
62
|
*/
|
|
57
63
|
async findFilesRaw(requestParameters, initOverrides) {
|
|
58
|
-
if (requestParameters
|
|
59
|
-
throw new runtime.RequiredError(
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
64
|
+
if (requestParameters["bucketName"] == null) {
|
|
65
|
+
throw new runtime.RequiredError(
|
|
66
|
+
"bucketName",
|
|
67
|
+
'Required parameter "bucketName" was null or undefined when calling findFiles().'
|
|
68
|
+
);
|
|
69
|
+
}
|
|
70
|
+
if (requestParameters["mongoFindRequest"] == null) {
|
|
71
|
+
throw new runtime.RequiredError(
|
|
72
|
+
"mongoFindRequest",
|
|
73
|
+
'Required parameter "mongoFindRequest" was null or undefined when calling findFiles().'
|
|
74
|
+
);
|
|
63
75
|
}
|
|
64
76
|
const queryParameters = {};
|
|
65
|
-
if (requestParameters
|
|
66
|
-
queryParameters["rowsPerPage"] = requestParameters
|
|
77
|
+
if (requestParameters["rowsPerPage"] != null) {
|
|
78
|
+
queryParameters["rowsPerPage"] = requestParameters["rowsPerPage"];
|
|
67
79
|
}
|
|
68
|
-
if (requestParameters
|
|
69
|
-
queryParameters["page"] = requestParameters
|
|
80
|
+
if (requestParameters["page"] != null) {
|
|
81
|
+
queryParameters["page"] = requestParameters["page"];
|
|
70
82
|
}
|
|
71
83
|
const headerParameters = {};
|
|
72
84
|
headerParameters["Content-Type"] = "application/json";
|
|
@@ -81,14 +93,14 @@ export class FileApi extends runtime.BaseAPI {
|
|
|
81
93
|
}
|
|
82
94
|
}
|
|
83
95
|
if (this.configuration && this.configuration.apiKey) {
|
|
84
|
-
headerParameters["X-AUTH-APIKEY"] = this.configuration.apiKey("X-AUTH-APIKEY");
|
|
96
|
+
headerParameters["X-AUTH-APIKEY"] = await this.configuration.apiKey("X-AUTH-APIKEY");
|
|
85
97
|
}
|
|
86
98
|
const response = await this.request({
|
|
87
|
-
path: `/mongodb/buckets/{bucketName}/files`.replace(`{${"bucketName"}}`, encodeURIComponent(String(requestParameters
|
|
99
|
+
path: `/mongodb/buckets/{bucketName}/files`.replace(`{${"bucketName"}}`, encodeURIComponent(String(requestParameters["bucketName"]))),
|
|
88
100
|
method: "POST",
|
|
89
101
|
headers: headerParameters,
|
|
90
102
|
query: queryParameters,
|
|
91
|
-
body: MongoFindRequestToJSON(requestParameters
|
|
103
|
+
body: MongoFindRequestToJSON(requestParameters["mongoFindRequest"])
|
|
92
104
|
}, initOverrides);
|
|
93
105
|
return new runtime.JSONApiResponse(response, (jsonValue) => jsonValue.map(FileInformationFromJSON));
|
|
94
106
|
}
|
|
@@ -105,11 +117,17 @@ export class FileApi extends runtime.BaseAPI {
|
|
|
105
117
|
* File from Bucket
|
|
106
118
|
*/
|
|
107
119
|
async getFileRaw(requestParameters, initOverrides) {
|
|
108
|
-
if (requestParameters
|
|
109
|
-
throw new runtime.RequiredError(
|
|
110
|
-
|
|
111
|
-
|
|
112
|
-
|
|
120
|
+
if (requestParameters["bucketName"] == null) {
|
|
121
|
+
throw new runtime.RequiredError(
|
|
122
|
+
"bucketName",
|
|
123
|
+
'Required parameter "bucketName" was null or undefined when calling getFile().'
|
|
124
|
+
);
|
|
125
|
+
}
|
|
126
|
+
if (requestParameters["fileId"] == null) {
|
|
127
|
+
throw new runtime.RequiredError(
|
|
128
|
+
"fileId",
|
|
129
|
+
'Required parameter "fileId" was null or undefined when calling getFile().'
|
|
130
|
+
);
|
|
113
131
|
}
|
|
114
132
|
const queryParameters = {};
|
|
115
133
|
const headerParameters = {};
|
|
@@ -124,10 +142,10 @@ export class FileApi extends runtime.BaseAPI {
|
|
|
124
142
|
}
|
|
125
143
|
}
|
|
126
144
|
if (this.configuration && this.configuration.apiKey) {
|
|
127
|
-
headerParameters["X-AUTH-APIKEY"] = this.configuration.apiKey("X-AUTH-APIKEY");
|
|
145
|
+
headerParameters["X-AUTH-APIKEY"] = await this.configuration.apiKey("X-AUTH-APIKEY");
|
|
128
146
|
}
|
|
129
147
|
const response = await this.request({
|
|
130
|
-
path: `/mongodb/buckets/{bucketName}/files/{fileId}/file`.replace(`{${"bucketName"}}`, encodeURIComponent(String(requestParameters
|
|
148
|
+
path: `/mongodb/buckets/{bucketName}/files/{fileId}/file`.replace(`{${"bucketName"}}`, encodeURIComponent(String(requestParameters["bucketName"]))).replace(`{${"fileId"}}`, encodeURIComponent(String(requestParameters["fileId"]))),
|
|
131
149
|
method: "GET",
|
|
132
150
|
headers: headerParameters,
|
|
133
151
|
query: queryParameters
|
|
@@ -147,11 +165,17 @@ export class FileApi extends runtime.BaseAPI {
|
|
|
147
165
|
* FileInformation from Bucket
|
|
148
166
|
*/
|
|
149
167
|
async getFileInformationRaw(requestParameters, initOverrides) {
|
|
150
|
-
if (requestParameters
|
|
151
|
-
throw new runtime.RequiredError(
|
|
152
|
-
|
|
153
|
-
|
|
154
|
-
|
|
168
|
+
if (requestParameters["bucketName"] == null) {
|
|
169
|
+
throw new runtime.RequiredError(
|
|
170
|
+
"bucketName",
|
|
171
|
+
'Required parameter "bucketName" was null or undefined when calling getFileInformation().'
|
|
172
|
+
);
|
|
173
|
+
}
|
|
174
|
+
if (requestParameters["fileId"] == null) {
|
|
175
|
+
throw new runtime.RequiredError(
|
|
176
|
+
"fileId",
|
|
177
|
+
'Required parameter "fileId" was null or undefined when calling getFileInformation().'
|
|
178
|
+
);
|
|
155
179
|
}
|
|
156
180
|
const queryParameters = {};
|
|
157
181
|
const headerParameters = {};
|
|
@@ -166,10 +190,10 @@ export class FileApi extends runtime.BaseAPI {
|
|
|
166
190
|
}
|
|
167
191
|
}
|
|
168
192
|
if (this.configuration && this.configuration.apiKey) {
|
|
169
|
-
headerParameters["X-AUTH-APIKEY"] = this.configuration.apiKey("X-AUTH-APIKEY");
|
|
193
|
+
headerParameters["X-AUTH-APIKEY"] = await this.configuration.apiKey("X-AUTH-APIKEY");
|
|
170
194
|
}
|
|
171
195
|
const response = await this.request({
|
|
172
|
-
path: `/mongodb/buckets/{bucketName}/files/{fileId}`.replace(`{${"bucketName"}}`, encodeURIComponent(String(requestParameters
|
|
196
|
+
path: `/mongodb/buckets/{bucketName}/files/{fileId}`.replace(`{${"bucketName"}}`, encodeURIComponent(String(requestParameters["bucketName"]))).replace(`{${"fileId"}}`, encodeURIComponent(String(requestParameters["fileId"]))),
|
|
173
197
|
method: "GET",
|
|
174
198
|
headers: headerParameters,
|
|
175
199
|
query: queryParameters
|
|
@@ -189,18 +213,27 @@ export class FileApi extends runtime.BaseAPI {
|
|
|
189
213
|
* Insert File
|
|
190
214
|
*/
|
|
191
215
|
async insertFileRaw(requestParameters, initOverrides) {
|
|
192
|
-
if (requestParameters
|
|
193
|
-
throw new runtime.RequiredError(
|
|
194
|
-
|
|
195
|
-
|
|
196
|
-
|
|
197
|
-
}
|
|
198
|
-
if (requestParameters
|
|
199
|
-
throw new runtime.RequiredError(
|
|
216
|
+
if (requestParameters["bucketName"] == null) {
|
|
217
|
+
throw new runtime.RequiredError(
|
|
218
|
+
"bucketName",
|
|
219
|
+
'Required parameter "bucketName" was null or undefined when calling insertFile().'
|
|
220
|
+
);
|
|
221
|
+
}
|
|
222
|
+
if (requestParameters["file"] == null) {
|
|
223
|
+
throw new runtime.RequiredError(
|
|
224
|
+
"file",
|
|
225
|
+
'Required parameter "file" was null or undefined when calling insertFile().'
|
|
226
|
+
);
|
|
227
|
+
}
|
|
228
|
+
if (requestParameters["metaData"] == null) {
|
|
229
|
+
throw new runtime.RequiredError(
|
|
230
|
+
"metaData",
|
|
231
|
+
'Required parameter "metaData" was null or undefined when calling insertFile().'
|
|
232
|
+
);
|
|
200
233
|
}
|
|
201
234
|
const queryParameters = {};
|
|
202
|
-
if (requestParameters
|
|
203
|
-
queryParameters["fileName"] = requestParameters
|
|
235
|
+
if (requestParameters["fileName"] != null) {
|
|
236
|
+
queryParameters["fileName"] = requestParameters["fileName"];
|
|
204
237
|
}
|
|
205
238
|
const headerParameters = {};
|
|
206
239
|
if (this.configuration && (this.configuration.username !== void 0 || this.configuration.password !== void 0)) {
|
|
@@ -214,7 +247,7 @@ export class FileApi extends runtime.BaseAPI {
|
|
|
214
247
|
}
|
|
215
248
|
}
|
|
216
249
|
if (this.configuration && this.configuration.apiKey) {
|
|
217
|
-
headerParameters["X-AUTH-APIKEY"] = this.configuration.apiKey("X-AUTH-APIKEY");
|
|
250
|
+
headerParameters["X-AUTH-APIKEY"] = await this.configuration.apiKey("X-AUTH-APIKEY");
|
|
218
251
|
}
|
|
219
252
|
const consumes = [
|
|
220
253
|
{ contentType: "multipart/form-data" }
|
|
@@ -228,14 +261,14 @@ export class FileApi extends runtime.BaseAPI {
|
|
|
228
261
|
} else {
|
|
229
262
|
formParams = new URLSearchParams();
|
|
230
263
|
}
|
|
231
|
-
if (requestParameters
|
|
232
|
-
formParams.append("file", requestParameters
|
|
264
|
+
if (requestParameters["file"] != null) {
|
|
265
|
+
formParams.append("file", requestParameters["file"]);
|
|
233
266
|
}
|
|
234
|
-
if (requestParameters
|
|
235
|
-
formParams.append("metaData", requestParameters
|
|
267
|
+
if (requestParameters["metaData"] != null) {
|
|
268
|
+
formParams.append("metaData", requestParameters["metaData"]);
|
|
236
269
|
}
|
|
237
270
|
const response = await this.request({
|
|
238
|
-
path: `/mongodb/buckets/{bucketName}/files`.replace(`{${"bucketName"}}`, encodeURIComponent(String(requestParameters
|
|
271
|
+
path: `/mongodb/buckets/{bucketName}/files`.replace(`{${"bucketName"}}`, encodeURIComponent(String(requestParameters["bucketName"]))),
|
|
239
272
|
method: "PUT",
|
|
240
273
|
headers: headerParameters,
|
|
241
274
|
query: queryParameters,
|
|
@@ -256,24 +289,27 @@ export class FileApi extends runtime.BaseAPI {
|
|
|
256
289
|
* Files in Bucket
|
|
257
290
|
*/
|
|
258
291
|
async listFilesRaw(requestParameters, initOverrides) {
|
|
259
|
-
if (requestParameters
|
|
260
|
-
throw new runtime.RequiredError(
|
|
292
|
+
if (requestParameters["bucketName"] == null) {
|
|
293
|
+
throw new runtime.RequiredError(
|
|
294
|
+
"bucketName",
|
|
295
|
+
'Required parameter "bucketName" was null or undefined when calling listFiles().'
|
|
296
|
+
);
|
|
261
297
|
}
|
|
262
298
|
const queryParameters = {};
|
|
263
|
-
if (requestParameters
|
|
264
|
-
queryParameters["filter"] = requestParameters
|
|
299
|
+
if (requestParameters["filter"] != null) {
|
|
300
|
+
queryParameters["filter"] = requestParameters["filter"];
|
|
265
301
|
}
|
|
266
|
-
if (requestParameters
|
|
267
|
-
queryParameters["sort"] = requestParameters
|
|
302
|
+
if (requestParameters["sort"] != null) {
|
|
303
|
+
queryParameters["sort"] = requestParameters["sort"];
|
|
268
304
|
}
|
|
269
|
-
if (requestParameters
|
|
270
|
-
queryParameters["projection"] = requestParameters
|
|
305
|
+
if (requestParameters["projection"] != null) {
|
|
306
|
+
queryParameters["projection"] = requestParameters["projection"];
|
|
271
307
|
}
|
|
272
|
-
if (requestParameters
|
|
273
|
-
queryParameters["rowsPerPage"] = requestParameters
|
|
308
|
+
if (requestParameters["rowsPerPage"] != null) {
|
|
309
|
+
queryParameters["rowsPerPage"] = requestParameters["rowsPerPage"];
|
|
274
310
|
}
|
|
275
|
-
if (requestParameters
|
|
276
|
-
queryParameters["page"] = requestParameters
|
|
311
|
+
if (requestParameters["page"] != null) {
|
|
312
|
+
queryParameters["page"] = requestParameters["page"];
|
|
277
313
|
}
|
|
278
314
|
const headerParameters = {};
|
|
279
315
|
if (this.configuration && (this.configuration.username !== void 0 || this.configuration.password !== void 0)) {
|
|
@@ -287,10 +323,10 @@ export class FileApi extends runtime.BaseAPI {
|
|
|
287
323
|
}
|
|
288
324
|
}
|
|
289
325
|
if (this.configuration && this.configuration.apiKey) {
|
|
290
|
-
headerParameters["X-AUTH-APIKEY"] = this.configuration.apiKey("X-AUTH-APIKEY");
|
|
326
|
+
headerParameters["X-AUTH-APIKEY"] = await this.configuration.apiKey("X-AUTH-APIKEY");
|
|
291
327
|
}
|
|
292
328
|
const response = await this.request({
|
|
293
|
-
path: `/mongodb/buckets/{bucketName}/files`.replace(`{${"bucketName"}}`, encodeURIComponent(String(requestParameters
|
|
329
|
+
path: `/mongodb/buckets/{bucketName}/files`.replace(`{${"bucketName"}}`, encodeURIComponent(String(requestParameters["bucketName"]))),
|
|
294
330
|
method: "GET",
|
|
295
331
|
headers: headerParameters,
|
|
296
332
|
query: queryParameters
|
|
@@ -310,14 +346,23 @@ export class FileApi extends runtime.BaseAPI {
|
|
|
310
346
|
* Update FileInformation in Bucket
|
|
311
347
|
*/
|
|
312
348
|
async updateFileInformationRaw(requestParameters, initOverrides) {
|
|
313
|
-
if (requestParameters
|
|
314
|
-
throw new runtime.RequiredError(
|
|
315
|
-
|
|
316
|
-
|
|
317
|
-
|
|
318
|
-
}
|
|
319
|
-
if (requestParameters
|
|
320
|
-
throw new runtime.RequiredError(
|
|
349
|
+
if (requestParameters["bucketName"] == null) {
|
|
350
|
+
throw new runtime.RequiredError(
|
|
351
|
+
"bucketName",
|
|
352
|
+
'Required parameter "bucketName" was null or undefined when calling updateFileInformation().'
|
|
353
|
+
);
|
|
354
|
+
}
|
|
355
|
+
if (requestParameters["fileId"] == null) {
|
|
356
|
+
throw new runtime.RequiredError(
|
|
357
|
+
"fileId",
|
|
358
|
+
'Required parameter "fileId" was null or undefined when calling updateFileInformation().'
|
|
359
|
+
);
|
|
360
|
+
}
|
|
361
|
+
if (requestParameters["updateFileInformationRequest"] == null) {
|
|
362
|
+
throw new runtime.RequiredError(
|
|
363
|
+
"updateFileInformationRequest",
|
|
364
|
+
'Required parameter "updateFileInformationRequest" was null or undefined when calling updateFileInformation().'
|
|
365
|
+
);
|
|
321
366
|
}
|
|
322
367
|
const queryParameters = {};
|
|
323
368
|
const headerParameters = {};
|
|
@@ -333,14 +378,14 @@ export class FileApi extends runtime.BaseAPI {
|
|
|
333
378
|
}
|
|
334
379
|
}
|
|
335
380
|
if (this.configuration && this.configuration.apiKey) {
|
|
336
|
-
headerParameters["X-AUTH-APIKEY"] = this.configuration.apiKey("X-AUTH-APIKEY");
|
|
381
|
+
headerParameters["X-AUTH-APIKEY"] = await this.configuration.apiKey("X-AUTH-APIKEY");
|
|
337
382
|
}
|
|
338
383
|
const response = await this.request({
|
|
339
|
-
path: `/mongodb/buckets/{bucketName}/files/{fileId}`.replace(`{${"bucketName"}}`, encodeURIComponent(String(requestParameters
|
|
384
|
+
path: `/mongodb/buckets/{bucketName}/files/{fileId}`.replace(`{${"bucketName"}}`, encodeURIComponent(String(requestParameters["bucketName"]))).replace(`{${"fileId"}}`, encodeURIComponent(String(requestParameters["fileId"]))),
|
|
340
385
|
method: "PATCH",
|
|
341
386
|
headers: headerParameters,
|
|
342
387
|
query: queryParameters,
|
|
343
|
-
body: UpdateFileInformationRequestToJSON(requestParameters
|
|
388
|
+
body: UpdateFileInformationRequestToJSON(requestParameters["updateFileInformationRequest"])
|
|
344
389
|
}, initOverrides);
|
|
345
390
|
return new runtime.JSONApiResponse(response, (jsonValue) => UpdateResponseFromJSON(jsonValue));
|
|
346
391
|
}
|
|
@@ -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 { IndexCreateRequest, IndexCreateResponse, IndexDropResponse, IndexOptionsRequest, MongoIndex } from '../models/index';
|
|
12
|
+
import * as runtime from '../runtime.js';
|
|
13
|
+
import type { IndexCreateRequest, IndexCreateResponse, IndexDropResponse, IndexOptionsRequest, MongoIndex } from '../models/index.js';
|
|
14
14
|
export interface CreateExpiringIndexRequest {
|
|
15
15
|
collectionName: string;
|
|
16
16
|
fieldName: string;
|