@sfxcode/nuxt-mongocamp-server 1.6.3 → 1.8.0
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 +8 -0
- package/dist/module.json +1 -1
- package/dist/module.mjs +1 -1
- package/dist/runtime/api/.openapi-generator/FILES +30 -0
- package/dist/runtime/api/apis/AdminApi.d.ts +1 -1
- package/dist/runtime/api/apis/ApplicationApi.d.ts +1 -1
- package/dist/runtime/api/apis/AuthApi.d.ts +19 -2
- package/dist/runtime/api/apis/AuthApi.js +48 -0
- package/dist/runtime/api/apis/BucketApi.d.ts +1 -1
- package/dist/runtime/api/apis/CollectionApi.d.ts +78 -4
- package/dist/runtime/api/apis/CollectionApi.js +236 -2
- package/dist/runtime/api/apis/DatabaseApi.d.ts +1 -1
- package/dist/runtime/api/apis/DocumentApi.d.ts +92 -2
- package/dist/runtime/api/apis/DocumentApi.js +275 -0
- package/dist/runtime/api/apis/FileApi.d.ts +1 -1
- package/dist/runtime/api/apis/IndexApi.d.ts +36 -2
- package/dist/runtime/api/apis/IndexApi.js +104 -0
- package/dist/runtime/api/apis/JobsApi.d.ts +1 -1
- package/dist/runtime/api/apis/SystemApi.d.ts +1 -1
- package/dist/runtime/api/docs/AuthApi.md +78 -0
- package/dist/runtime/api/docs/CollectionApi.md +335 -2
- package/dist/runtime/api/docs/CollectionPermission.md +40 -0
- package/dist/runtime/api/docs/CollectionSummary.md +50 -0
- package/dist/runtime/api/docs/CopyRequest.md +40 -0
- package/dist/runtime/api/docs/CopyResponse.md +38 -0
- package/dist/runtime/api/docs/CountResponse.md +34 -0
- package/dist/runtime/api/docs/DocumentApi.md +377 -8
- package/dist/runtime/api/docs/FieldInfo.md +36 -0
- package/dist/runtime/api/docs/FieldTypeCount.md +36 -0
- package/dist/runtime/api/docs/ImportResponse.md +42 -0
- package/dist/runtime/api/docs/IndexApi.md +156 -0
- package/dist/runtime/api/docs/IndexCreateRequest.md +2 -0
- package/dist/runtime/api/docs/IndexInfo.md +54 -0
- package/dist/runtime/api/docs/IndexKey.md +36 -0
- package/dist/runtime/api/docs/IndexOptionsRequest.md +10 -0
- package/dist/runtime/api/docs/IndexUsage.md +40 -0
- package/dist/runtime/api/docs/InsertError.md +38 -0
- package/dist/runtime/api/docs/InsertResponse.md +4 -0
- package/dist/runtime/api/docs/RenameRequest.md +36 -0
- package/dist/runtime/api/docs/RenameResponse.md +34 -0
- package/dist/runtime/api/docs/SearchRequest.md +38 -0
- package/dist/runtime/api/models/BucketInformation.d.ts +1 -1
- package/dist/runtime/api/models/ClusterInformation.d.ts +1 -1
- package/dist/runtime/api/models/ClusterMemberInformation.d.ts +1 -1
- package/dist/runtime/api/models/CollectionPermission.d.ts +50 -0
- package/dist/runtime/api/models/CollectionPermission.js +35 -0
- package/dist/runtime/api/models/CollectionStatus.d.ts +1 -1
- package/dist/runtime/api/models/CollectionSummary.d.ts +80 -0
- package/dist/runtime/api/models/CollectionSummary.js +50 -0
- package/dist/runtime/api/models/CopyRequest.d.ts +50 -0
- package/dist/runtime/api/models/CopyRequest.js +32 -0
- package/dist/runtime/api/models/CopyResponse.d.ts +44 -0
- package/dist/runtime/api/models/CopyResponse.js +32 -0
- package/dist/runtime/api/models/CountResponse.d.ts +32 -0
- package/dist/runtime/api/models/CountResponse.js +26 -0
- package/dist/runtime/api/models/DatabaseInfo.d.ts +1 -1
- package/dist/runtime/api/models/DeleteResponse.d.ts +1 -1
- package/dist/runtime/api/models/ErrorDescription.d.ts +1 -1
- package/dist/runtime/api/models/FieldInfo.d.ts +39 -0
- package/dist/runtime/api/models/FieldInfo.js +32 -0
- package/dist/runtime/api/models/FieldTypeCount.d.ts +38 -0
- package/dist/runtime/api/models/FieldTypeCount.js +29 -0
- package/dist/runtime/api/models/FileInformation.d.ts +1 -1
- package/dist/runtime/api/models/Grant.d.ts +1 -1
- package/dist/runtime/api/models/ImportResponse.d.ts +57 -0
- package/dist/runtime/api/models/ImportResponse.js +41 -0
- package/dist/runtime/api/models/IndexCreateRequest.d.ts +9 -2
- package/dist/runtime/api/models/IndexCreateRequest.js +9 -4
- package/dist/runtime/api/models/IndexCreateResponse.d.ts +1 -1
- package/dist/runtime/api/models/IndexDropResponse.d.ts +1 -1
- package/dist/runtime/api/models/IndexInfo.d.ts +99 -0
- package/dist/runtime/api/models/IndexInfo.js +54 -0
- package/dist/runtime/api/models/IndexKey.d.ts +38 -0
- package/dist/runtime/api/models/IndexKey.js +29 -0
- package/dist/runtime/api/models/IndexOptionsRequest.d.ts +37 -1
- package/dist/runtime/api/models/IndexOptionsRequest.js +12 -2
- package/dist/runtime/api/models/IndexUsage.d.ts +52 -0
- package/dist/runtime/api/models/IndexUsage.js +35 -0
- package/dist/runtime/api/models/InsertError.d.ts +44 -0
- package/dist/runtime/api/models/InsertError.js +32 -0
- package/dist/runtime/api/models/InsertResponse.d.ts +14 -1
- package/dist/runtime/api/models/InsertResponse.js +10 -2
- package/dist/runtime/api/models/JobConfig.d.ts +1 -1
- package/dist/runtime/api/models/JobInformation.d.ts +1 -1
- package/dist/runtime/api/models/JsonSchema.d.ts +1 -1
- package/dist/runtime/api/models/JsonSchemaDefinition.d.ts +1 -1
- package/dist/runtime/api/models/JsonValueAny.d.ts +1 -1
- package/dist/runtime/api/models/JsonValueBoolean.d.ts +1 -1
- package/dist/runtime/api/models/JsonValueString.d.ts +1 -1
- package/dist/runtime/api/models/Login.d.ts +1 -1
- package/dist/runtime/api/models/LoginResult.d.ts +1 -1
- package/dist/runtime/api/models/MongoAggregateRequest.d.ts +1 -1
- package/dist/runtime/api/models/MongoCampConfiguration.d.ts +1 -1
- package/dist/runtime/api/models/MongoFindRequest.d.ts +1 -1
- package/dist/runtime/api/models/MongoIndex.d.ts +1 -1
- package/dist/runtime/api/models/PasswordUpdateRequest.d.ts +1 -1
- package/dist/runtime/api/models/PipelineStage.d.ts +1 -1
- package/dist/runtime/api/models/RenameRequest.d.ts +38 -0
- package/dist/runtime/api/models/RenameRequest.js +28 -0
- package/dist/runtime/api/models/RenameResponse.d.ts +32 -0
- package/dist/runtime/api/models/RenameResponse.js +26 -0
- package/dist/runtime/api/models/Role.d.ts +1 -1
- package/dist/runtime/api/models/SchemaAnalysis.d.ts +1 -1
- package/dist/runtime/api/models/SchemaAnalysisField.d.ts +1 -1
- package/dist/runtime/api/models/SchemaAnalysisFieldType.d.ts +1 -1
- package/dist/runtime/api/models/SearchRequest.d.ts +44 -0
- package/dist/runtime/api/models/SearchRequest.js +29 -0
- package/dist/runtime/api/models/SettingsResponse.d.ts +1 -1
- package/dist/runtime/api/models/UpdateFileInformationRequest.d.ts +1 -1
- package/dist/runtime/api/models/UpdateRequest.d.ts +1 -1
- package/dist/runtime/api/models/UpdateResponse.d.ts +1 -1
- package/dist/runtime/api/models/UpdateRoleRequest.d.ts +1 -1
- package/dist/runtime/api/models/UserInformation.d.ts +1 -1
- package/dist/runtime/api/models/UserProfile.d.ts +1 -1
- package/dist/runtime/api/models/Version.d.ts +1 -1
- package/dist/runtime/api/models/index.d.ts +15 -0
- package/dist/runtime/api/models/index.js +15 -0
- package/dist/runtime/api/runtime.d.ts +1 -1
- package/package.json +8 -8
package/README.md
CHANGED
|
@@ -2,6 +2,14 @@
|
|
|
2
2
|
|
|
3
3
|
Nuxt module wrapping a generated OpenAPI client for [MongoCamp](https://mongocamp.io), with composables for browser-session auth and server-side API-key/bearer auth.
|
|
4
4
|
|
|
5
|
+
## MongoCamp Server
|
|
6
|
+
|
|
7
|
+
This module is a client for [MongoCamp Server](https://github.com/MongoCamp/mongocamp-server), a REST API server for MongoDB that provides authentication, user/role management, and collection, document and index APIs. The OpenAPI client in this module is generated from the server's OpenAPI spec, so the module version should match a compatible server version. See the [server repository](https://github.com/MongoCamp/mongocamp-server) for installation, configuration and API documentation.
|
|
8
|
+
|
|
9
|
+
## Nuxt UI MongoCamp
|
|
10
|
+
|
|
11
|
+
[nuxt-ui-mongocamp](https://github.com/sfxcode/nuxt-ui-mongocamp) is a companion project built on [Nuxt UI](https://ui.nuxt.com) that provides a user interface for MongoCamp. See its repository for setup and usage.
|
|
12
|
+
|
|
5
13
|
## Setup
|
|
6
14
|
|
|
7
15
|
```bash
|
package/dist/module.json
CHANGED
package/dist/module.mjs
CHANGED
|
@@ -18,20 +18,32 @@ docs/BucketInformation.md
|
|
|
18
18
|
docs/ClusterInformation.md
|
|
19
19
|
docs/ClusterMemberInformation.md
|
|
20
20
|
docs/CollectionApi.md
|
|
21
|
+
docs/CollectionPermission.md
|
|
21
22
|
docs/CollectionStatus.md
|
|
23
|
+
docs/CollectionSummary.md
|
|
24
|
+
docs/CopyRequest.md
|
|
25
|
+
docs/CopyResponse.md
|
|
26
|
+
docs/CountResponse.md
|
|
22
27
|
docs/DatabaseApi.md
|
|
23
28
|
docs/DatabaseInfo.md
|
|
24
29
|
docs/DeleteResponse.md
|
|
25
30
|
docs/DocumentApi.md
|
|
26
31
|
docs/ErrorDescription.md
|
|
32
|
+
docs/FieldInfo.md
|
|
33
|
+
docs/FieldTypeCount.md
|
|
27
34
|
docs/FileApi.md
|
|
28
35
|
docs/FileInformation.md
|
|
29
36
|
docs/Grant.md
|
|
37
|
+
docs/ImportResponse.md
|
|
30
38
|
docs/IndexApi.md
|
|
31
39
|
docs/IndexCreateRequest.md
|
|
32
40
|
docs/IndexCreateResponse.md
|
|
33
41
|
docs/IndexDropResponse.md
|
|
42
|
+
docs/IndexInfo.md
|
|
43
|
+
docs/IndexKey.md
|
|
34
44
|
docs/IndexOptionsRequest.md
|
|
45
|
+
docs/IndexUsage.md
|
|
46
|
+
docs/InsertError.md
|
|
35
47
|
docs/InsertResponse.md
|
|
36
48
|
docs/JobConfig.md
|
|
37
49
|
docs/JobInformation.md
|
|
@@ -49,10 +61,13 @@ docs/MongoFindRequest.md
|
|
|
49
61
|
docs/MongoIndex.md
|
|
50
62
|
docs/PasswordUpdateRequest.md
|
|
51
63
|
docs/PipelineStage.md
|
|
64
|
+
docs/RenameRequest.md
|
|
65
|
+
docs/RenameResponse.md
|
|
52
66
|
docs/Role.md
|
|
53
67
|
docs/SchemaAnalysis.md
|
|
54
68
|
docs/SchemaAnalysisField.md
|
|
55
69
|
docs/SchemaAnalysisFieldType.md
|
|
70
|
+
docs/SearchRequest.md
|
|
56
71
|
docs/SettingsResponse.md
|
|
57
72
|
docs/SystemApi.md
|
|
58
73
|
docs/UpdateFileInformationRequest.md
|
|
@@ -66,16 +81,28 @@ index.ts
|
|
|
66
81
|
models/BucketInformation.ts
|
|
67
82
|
models/ClusterInformation.ts
|
|
68
83
|
models/ClusterMemberInformation.ts
|
|
84
|
+
models/CollectionPermission.ts
|
|
69
85
|
models/CollectionStatus.ts
|
|
86
|
+
models/CollectionSummary.ts
|
|
87
|
+
models/CopyRequest.ts
|
|
88
|
+
models/CopyResponse.ts
|
|
89
|
+
models/CountResponse.ts
|
|
70
90
|
models/DatabaseInfo.ts
|
|
71
91
|
models/DeleteResponse.ts
|
|
72
92
|
models/ErrorDescription.ts
|
|
93
|
+
models/FieldInfo.ts
|
|
94
|
+
models/FieldTypeCount.ts
|
|
73
95
|
models/FileInformation.ts
|
|
74
96
|
models/Grant.ts
|
|
97
|
+
models/ImportResponse.ts
|
|
75
98
|
models/IndexCreateRequest.ts
|
|
76
99
|
models/IndexCreateResponse.ts
|
|
77
100
|
models/IndexDropResponse.ts
|
|
101
|
+
models/IndexInfo.ts
|
|
102
|
+
models/IndexKey.ts
|
|
78
103
|
models/IndexOptionsRequest.ts
|
|
104
|
+
models/IndexUsage.ts
|
|
105
|
+
models/InsertError.ts
|
|
79
106
|
models/InsertResponse.ts
|
|
80
107
|
models/JobConfig.ts
|
|
81
108
|
models/JobInformation.ts
|
|
@@ -92,10 +119,13 @@ models/MongoFindRequest.ts
|
|
|
92
119
|
models/MongoIndex.ts
|
|
93
120
|
models/PasswordUpdateRequest.ts
|
|
94
121
|
models/PipelineStage.ts
|
|
122
|
+
models/RenameRequest.ts
|
|
123
|
+
models/RenameResponse.ts
|
|
95
124
|
models/Role.ts
|
|
96
125
|
models/SchemaAnalysis.ts
|
|
97
126
|
models/SchemaAnalysisField.ts
|
|
98
127
|
models/SchemaAnalysisFieldType.ts
|
|
128
|
+
models/SearchRequest.ts
|
|
99
129
|
models/SettingsResponse.ts
|
|
100
130
|
models/UpdateFileInformationRequest.ts
|
|
101
131
|
models/UpdateRequest.ts
|
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
* mongocamp-library
|
|
3
3
|
* No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator)
|
|
4
4
|
*
|
|
5
|
-
* The version of the OpenAPI document: 1.
|
|
5
|
+
* The version of the OpenAPI document: 1.8.1
|
|
6
6
|
*
|
|
7
7
|
*
|
|
8
8
|
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
* mongocamp-library
|
|
3
3
|
* No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator)
|
|
4
4
|
*
|
|
5
|
-
* The version of the OpenAPI document: 1.
|
|
5
|
+
* The version of the OpenAPI document: 1.8.1
|
|
6
6
|
*
|
|
7
7
|
*
|
|
8
8
|
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
* mongocamp-library
|
|
3
3
|
* No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator)
|
|
4
4
|
*
|
|
5
|
-
* The version of the OpenAPI document: 1.
|
|
5
|
+
* The version of the OpenAPI document: 1.8.1
|
|
6
6
|
*
|
|
7
7
|
*
|
|
8
8
|
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
|
@@ -10,13 +10,16 @@
|
|
|
10
10
|
* Do not edit the class manually.
|
|
11
11
|
*/
|
|
12
12
|
import * as runtime from '../runtime.js';
|
|
13
|
-
import type { JsonValueBoolean, JsonValueString, Login, LoginResult, PasswordUpdateRequest, UserProfile } from '../models/index.js';
|
|
13
|
+
import type { CollectionPermission, JsonValueBoolean, JsonValueString, Login, LoginResult, PasswordUpdateRequest, UserProfile } from '../models/index.js';
|
|
14
14
|
export interface LoginRequest {
|
|
15
15
|
login: Login;
|
|
16
16
|
}
|
|
17
17
|
export interface UpdatePasswordRequest {
|
|
18
18
|
passwordUpdateRequest: PasswordUpdateRequest;
|
|
19
19
|
}
|
|
20
|
+
export interface UserPermissionsRequest {
|
|
21
|
+
collection?: string;
|
|
22
|
+
}
|
|
20
23
|
/**
|
|
21
24
|
*
|
|
22
25
|
*/
|
|
@@ -119,6 +122,20 @@ export declare class AuthApi extends runtime.BaseAPI {
|
|
|
119
122
|
* Update Password
|
|
120
123
|
*/
|
|
121
124
|
updatePassword(requestParameters: UpdatePasswordRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<JsonValueBoolean>;
|
|
125
|
+
/**
|
|
126
|
+
* Creates request options for userPermissions without sending the request
|
|
127
|
+
*/
|
|
128
|
+
userPermissionsRequestOpts(requestParameters: UserPermissionsRequest): Promise<runtime.RequestOpts>;
|
|
129
|
+
/**
|
|
130
|
+
* Return the resolved rights (read, write, administrate) of the loggedin user for the collections of the default database
|
|
131
|
+
* Collection permissions
|
|
132
|
+
*/
|
|
133
|
+
userPermissionsRaw(requestParameters: UserPermissionsRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<Array<CollectionPermission>>>;
|
|
134
|
+
/**
|
|
135
|
+
* Return the resolved rights (read, write, administrate) of the loggedin user for the collections of the default database
|
|
136
|
+
* Collection permissions
|
|
137
|
+
*/
|
|
138
|
+
userPermissions(requestParameters?: UserPermissionsRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<Array<CollectionPermission>>;
|
|
122
139
|
/**
|
|
123
140
|
* Creates request options for userProfile without sending the request
|
|
124
141
|
*/
|
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
import * as runtime from "../runtime.js";
|
|
2
2
|
import {
|
|
3
|
+
CollectionPermissionFromJSON,
|
|
3
4
|
JsonValueBooleanFromJSON,
|
|
4
5
|
JsonValueStringFromJSON,
|
|
5
6
|
LoginToJSON,
|
|
@@ -319,6 +320,53 @@ export class AuthApi extends runtime.BaseAPI {
|
|
|
319
320
|
const response = await this.updatePasswordRaw(requestParameters, initOverrides);
|
|
320
321
|
return await response.value();
|
|
321
322
|
}
|
|
323
|
+
/**
|
|
324
|
+
* Creates request options for userPermissions without sending the request
|
|
325
|
+
*/
|
|
326
|
+
async userPermissionsRequestOpts(requestParameters) {
|
|
327
|
+
const queryParameters = {};
|
|
328
|
+
if (requestParameters["collection"] != null) {
|
|
329
|
+
queryParameters["collection"] = requestParameters["collection"];
|
|
330
|
+
}
|
|
331
|
+
const headerParameters = {};
|
|
332
|
+
if (this.configuration && (this.configuration.username !== void 0 || this.configuration.password !== void 0)) {
|
|
333
|
+
headerParameters["Authorization"] = "Basic " + btoa(this.configuration.username + ":" + this.configuration.password);
|
|
334
|
+
}
|
|
335
|
+
if (this.configuration && this.configuration.accessToken) {
|
|
336
|
+
const token = this.configuration.accessToken;
|
|
337
|
+
const tokenString = await token("httpAuth", []);
|
|
338
|
+
if (tokenString) {
|
|
339
|
+
headerParameters["Authorization"] = `Bearer ${tokenString}`;
|
|
340
|
+
}
|
|
341
|
+
}
|
|
342
|
+
if (this.configuration && this.configuration.apiKey) {
|
|
343
|
+
headerParameters["X-AUTH-APIKEY"] = await this.configuration.apiKey("X-AUTH-APIKEY");
|
|
344
|
+
}
|
|
345
|
+
let urlPath = `/auth/permissions`;
|
|
346
|
+
return {
|
|
347
|
+
path: urlPath,
|
|
348
|
+
method: "GET",
|
|
349
|
+
headers: headerParameters,
|
|
350
|
+
query: queryParameters
|
|
351
|
+
};
|
|
352
|
+
}
|
|
353
|
+
/**
|
|
354
|
+
* Return the resolved rights (read, write, administrate) of the loggedin user for the collections of the default database
|
|
355
|
+
* Collection permissions
|
|
356
|
+
*/
|
|
357
|
+
async userPermissionsRaw(requestParameters, initOverrides) {
|
|
358
|
+
const requestOptions = await this.userPermissionsRequestOpts(requestParameters);
|
|
359
|
+
const response = await this.request(requestOptions, initOverrides);
|
|
360
|
+
return new runtime.JSONApiResponse(response, (jsonValue) => jsonValue.map(CollectionPermissionFromJSON));
|
|
361
|
+
}
|
|
362
|
+
/**
|
|
363
|
+
* Return the resolved rights (read, write, administrate) of the loggedin user for the collections of the default database
|
|
364
|
+
* Collection permissions
|
|
365
|
+
*/
|
|
366
|
+
async userPermissions(requestParameters = {}, initOverrides) {
|
|
367
|
+
const response = await this.userPermissionsRaw(requestParameters, initOverrides);
|
|
368
|
+
return await response.value();
|
|
369
|
+
}
|
|
322
370
|
/**
|
|
323
371
|
* Creates request options for userProfile without sending the request
|
|
324
372
|
*/
|
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
* mongocamp-library
|
|
3
3
|
* No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator)
|
|
4
4
|
*
|
|
5
|
-
* The version of the OpenAPI document: 1.
|
|
5
|
+
* The version of the OpenAPI document: 1.8.1
|
|
6
6
|
*
|
|
7
7
|
*
|
|
8
8
|
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
* mongocamp-library
|
|
3
3
|
* No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator)
|
|
4
4
|
*
|
|
5
|
-
* The version of the OpenAPI document: 1.
|
|
5
|
+
* The version of the OpenAPI document: 1.8.1
|
|
6
6
|
*
|
|
7
7
|
*
|
|
8
8
|
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
|
@@ -10,16 +10,22 @@
|
|
|
10
10
|
* Do not edit the class manually.
|
|
11
11
|
*/
|
|
12
12
|
import * as runtime from '../runtime.js';
|
|
13
|
-
import type { CollectionStatus, JsonSchema, JsonValueBoolean, MongoAggregateRequest, SchemaAnalysis } from '../models/index.js';
|
|
13
|
+
import type { CollectionStatus, CollectionSummary, CopyRequest, CopyResponse, FieldInfo, JsonSchema, JsonValueBoolean, MongoAggregateRequest, RenameRequest, RenameResponse, SchemaAnalysis } from '../models/index.js';
|
|
14
14
|
export interface AggregateRequest {
|
|
15
15
|
collectionName: string;
|
|
16
16
|
mongoAggregateRequest: MongoAggregateRequest;
|
|
17
17
|
rowsPerPage?: number;
|
|
18
18
|
page?: number;
|
|
19
|
+
filter?: string;
|
|
20
|
+
extendedJson?: string;
|
|
19
21
|
}
|
|
20
22
|
export interface ClearCollectionRequest {
|
|
21
23
|
collectionName: string;
|
|
22
24
|
}
|
|
25
|
+
export interface CopyCollectionRequest {
|
|
26
|
+
collectionName: string;
|
|
27
|
+
copyRequest: CopyRequest;
|
|
28
|
+
}
|
|
23
29
|
export interface DeleteCollectionRequest {
|
|
24
30
|
collectionName: string;
|
|
25
31
|
}
|
|
@@ -37,6 +43,11 @@ export interface GetCollectionInformationRequest {
|
|
|
37
43
|
collectionName: string;
|
|
38
44
|
includeDetails?: boolean;
|
|
39
45
|
}
|
|
46
|
+
export interface GetFieldDetailsRequest {
|
|
47
|
+
collectionName: string;
|
|
48
|
+
sampleSize?: number;
|
|
49
|
+
depth?: number;
|
|
50
|
+
}
|
|
40
51
|
export interface GetJsonSchemaRequest {
|
|
41
52
|
collectionName: string;
|
|
42
53
|
sampleSize?: number;
|
|
@@ -47,9 +58,16 @@ export interface GetSchemaAnalysisRequest {
|
|
|
47
58
|
sampleSize?: number;
|
|
48
59
|
deepth?: number;
|
|
49
60
|
}
|
|
61
|
+
export interface ListCollectionInformationRequest {
|
|
62
|
+
name?: Array<string>;
|
|
63
|
+
}
|
|
50
64
|
export interface ListCollectionsByDatabaseRequest {
|
|
51
65
|
databaseName: string;
|
|
52
66
|
}
|
|
67
|
+
export interface RenameCollectionRequest {
|
|
68
|
+
collectionName: string;
|
|
69
|
+
renameRequest: RenameRequest;
|
|
70
|
+
}
|
|
53
71
|
/**
|
|
54
72
|
*
|
|
55
73
|
*/
|
|
@@ -59,14 +77,14 @@ export declare class CollectionApi extends runtime.BaseAPI {
|
|
|
59
77
|
*/
|
|
60
78
|
aggregateRequestOpts(requestParameters: AggregateRequest): Promise<runtime.RequestOpts>;
|
|
61
79
|
/**
|
|
62
|
-
* Aggregate in a given Collection. The value of a stage is any JSON value. Operators that run JavaScript on the database server or write to collections (`$function`, `$accumulator`, `$where`, `$out`, `$merge`, `$currentOp`, `$listSessions` by default, configured with AGGREGATION_STAGES_DENIED) are refused with 403.
|
|
80
|
+
* Aggregate in a given Collection. The value of a stage is any JSON value. Operators that run JavaScript on the database server or write to collections (`$function`, `$accumulator`, `$where`, `$out`, `$merge`, `$currentOp`, `$listSessions`, `$collStats`, `$indexStats` by default, configured with AGGREGATION_STAGES_DENIED) are refused with 403.
|
|
63
81
|
* Aggregate in Collection
|
|
64
82
|
*/
|
|
65
83
|
aggregateRaw(requestParameters: AggregateRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<Array<{
|
|
66
84
|
[key: string]: any;
|
|
67
85
|
}>>>;
|
|
68
86
|
/**
|
|
69
|
-
* Aggregate in a given Collection. The value of a stage is any JSON value. Operators that run JavaScript on the database server or write to collections (`$function`, `$accumulator`, `$where`, `$out`, `$merge`, `$currentOp`, `$listSessions` by default, configured with AGGREGATION_STAGES_DENIED) are refused with 403.
|
|
87
|
+
* Aggregate in a given Collection. The value of a stage is any JSON value. Operators that run JavaScript on the database server or write to collections (`$function`, `$accumulator`, `$where`, `$out`, `$merge`, `$currentOp`, `$listSessions`, `$collStats`, `$indexStats` by default, configured with AGGREGATION_STAGES_DENIED) are refused with 403.
|
|
70
88
|
* Aggregate in Collection
|
|
71
89
|
*/
|
|
72
90
|
aggregate(requestParameters: AggregateRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<Array<{
|
|
@@ -86,6 +104,20 @@ export declare class CollectionApi extends runtime.BaseAPI {
|
|
|
86
104
|
* Clear Collection
|
|
87
105
|
*/
|
|
88
106
|
clearCollection(requestParameters: ClearCollectionRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<JsonValueBoolean>;
|
|
107
|
+
/**
|
|
108
|
+
* Creates request options for copyCollection without sending the request
|
|
109
|
+
*/
|
|
110
|
+
copyCollectionRequestOpts(requestParameters: CopyCollectionRequest): Promise<runtime.RequestOpts>;
|
|
111
|
+
/**
|
|
112
|
+
* Copy a Collection in the database, optionally only the documents that match a Lucene filter, with its indices (withIndexes, true by default). The target is a name in the database of the Collection. The read grant for the Collection and the write grant for the target are needed. An existing target is a conflict (409), unless dropTarget is true and the user has the administrate grant for it: it is replaced when the copy is complete. The copy is made in one request, a big collection takes its time.
|
|
113
|
+
* Copy Collection
|
|
114
|
+
*/
|
|
115
|
+
copyCollectionRaw(requestParameters: CopyCollectionRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<CopyResponse>>;
|
|
116
|
+
/**
|
|
117
|
+
* Copy a Collection in the database, optionally only the documents that match a Lucene filter, with its indices (withIndexes, true by default). The target is a name in the database of the Collection. The read grant for the Collection and the write grant for the target are needed. An existing target is a conflict (409), unless dropTarget is true and the user has the administrate grant for it: it is replaced when the copy is complete. The copy is made in one request, a big collection takes its time.
|
|
118
|
+
* Copy Collection
|
|
119
|
+
*/
|
|
120
|
+
copyCollection(requestParameters: CopyCollectionRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<CopyResponse>;
|
|
89
121
|
/**
|
|
90
122
|
* Creates request options for deleteCollection without sending the request
|
|
91
123
|
*/
|
|
@@ -142,6 +174,20 @@ export declare class CollectionApi extends runtime.BaseAPI {
|
|
|
142
174
|
* Collection Information
|
|
143
175
|
*/
|
|
144
176
|
getCollectionInformation(requestParameters: GetCollectionInformationRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<CollectionStatus>;
|
|
177
|
+
/**
|
|
178
|
+
* Creates request options for getFieldDetails without sending the request
|
|
179
|
+
*/
|
|
180
|
+
getFieldDetailsRequestOpts(requestParameters: GetFieldDetailsRequest): Promise<runtime.RequestOpts>;
|
|
181
|
+
/**
|
|
182
|
+
* All fields of a collection as a flat list, one entry per path (`address.city`, `tags[]` for the elements of an array) with the types of the values and how often every type was found in the analysed documents.
|
|
183
|
+
* Fields of a Collection with types
|
|
184
|
+
*/
|
|
185
|
+
getFieldDetailsRaw(requestParameters: GetFieldDetailsRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<Array<FieldInfo>>>;
|
|
186
|
+
/**
|
|
187
|
+
* All fields of a collection as a flat list, one entry per path (`address.city`, `tags[]` for the elements of an array) with the types of the values and how often every type was found in the analysed documents.
|
|
188
|
+
* Fields of a Collection with types
|
|
189
|
+
*/
|
|
190
|
+
getFieldDetails(requestParameters: GetFieldDetailsRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<Array<FieldInfo>>;
|
|
145
191
|
/**
|
|
146
192
|
* Creates request options for getJsonSchema without sending the request
|
|
147
193
|
*/
|
|
@@ -170,6 +216,20 @@ export declare class CollectionApi extends runtime.BaseAPI {
|
|
|
170
216
|
* Collection Fields
|
|
171
217
|
*/
|
|
172
218
|
getSchemaAnalysis(requestParameters: GetSchemaAnalysisRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<SchemaAnalysis>;
|
|
219
|
+
/**
|
|
220
|
+
* Creates request options for listCollectionInformation without sending the request
|
|
221
|
+
*/
|
|
222
|
+
listCollectionInformationRequestOpts(requestParameters: ListCollectionInformationRequest): Promise<runtime.RequestOpts>;
|
|
223
|
+
/**
|
|
224
|
+
* The numbers of all Collections of the default database that the user may read in one request (count, size, storage size, average size of a document, number and size of the indices). A Collection without statistics, for example a view, is listed with available false.
|
|
225
|
+
* Information of all Collections
|
|
226
|
+
*/
|
|
227
|
+
listCollectionInformationRaw(requestParameters: ListCollectionInformationRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<Array<CollectionSummary>>>;
|
|
228
|
+
/**
|
|
229
|
+
* The numbers of all Collections of the default database that the user may read in one request (count, size, storage size, average size of a document, number and size of the indices). A Collection without statistics, for example a view, is listed with available false.
|
|
230
|
+
* Information of all Collections
|
|
231
|
+
*/
|
|
232
|
+
listCollectionInformation(requestParameters?: ListCollectionInformationRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<Array<CollectionSummary>>;
|
|
173
233
|
/**
|
|
174
234
|
* Creates request options for listCollections without sending the request
|
|
175
235
|
*/
|
|
@@ -198,4 +258,18 @@ export declare class CollectionApi extends runtime.BaseAPI {
|
|
|
198
258
|
* List of Collections
|
|
199
259
|
*/
|
|
200
260
|
listCollectionsByDatabase(requestParameters: ListCollectionsByDatabaseRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<Array<string>>;
|
|
261
|
+
/**
|
|
262
|
+
* Creates request options for renameCollection without sending the request
|
|
263
|
+
*/
|
|
264
|
+
renameCollectionRequestOpts(requestParameters: RenameCollectionRequest): Promise<runtime.RequestOpts>;
|
|
265
|
+
/**
|
|
266
|
+
* Rename a Collection in the database, with its Documents and Indices. The target is a name in the database of the Collection. The administrate grant for the Collection and the write grant for the target are needed. An existing target is a conflict (409), unless dropTarget is true and the user has the administrate grant for it: it is replaced then.
|
|
267
|
+
* Rename Collection
|
|
268
|
+
*/
|
|
269
|
+
renameCollectionRaw(requestParameters: RenameCollectionRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<RenameResponse>>;
|
|
270
|
+
/**
|
|
271
|
+
* Rename a Collection in the database, with its Documents and Indices. The target is a name in the database of the Collection. The administrate grant for the Collection and the write grant for the target are needed. An existing target is a conflict (409), unless dropTarget is true and the user has the administrate grant for it: it is replaced then.
|
|
272
|
+
* Rename Collection
|
|
273
|
+
*/
|
|
274
|
+
renameCollection(requestParameters: RenameCollectionRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<RenameResponse>;
|
|
201
275
|
}
|