@scaleway/sdk-mailbox 1.1.0 → 1.1.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/_virtual/_rolldown/runtime.js +2 -0
- package/dist/v1alpha1/api.gen.js +5 -3
- package/dist/v1alpha1/content.gen.js +5 -3
- package/dist/v1alpha1/index.gen.js +3 -1
- package/dist/v1alpha1/marshalling.gen.js +11 -9
- package/dist/v1alpha1/types.gen.js +0 -0
- package/dist/v1alpha1/validation-rules.gen.js +8 -6
- package/package.json +5 -5
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
//#region \0rolldown/runtime.js
|
|
1
2
|
var __defProp = Object.defineProperty;
|
|
2
3
|
var __exportAll = (all, no_symbols) => {
|
|
3
4
|
let target = {};
|
|
@@ -8,4 +9,5 @@ var __exportAll = (all, no_symbols) => {
|
|
|
8
9
|
if (!no_symbols) __defProp(target, Symbol.toStringTag, { value: "Module" });
|
|
9
10
|
return target;
|
|
10
11
|
};
|
|
12
|
+
//#endregion
|
|
11
13
|
export { __exportAll };
|
package/dist/v1alpha1/api.gen.js
CHANGED
|
@@ -1,13 +1,14 @@
|
|
|
1
1
|
import { DOMAIN_TRANSIENT_STATUSES, MAILBOX_TRANSIENT_STATUSES } from "./content.gen.js";
|
|
2
2
|
import { marshalBatchCreateMailboxesRequest, marshalCreateDomainRequest, marshalUpdateMailboxRequest, unmarshalBatchCreateMailboxesResponse, unmarshalDomain, unmarshalGetDomainRecordsResponse, unmarshalListDomainsResponse, unmarshalListMailboxesResponse, unmarshalMailbox } from "./marshalling.gen.js";
|
|
3
|
-
import { API, enrichForPagination, urlParams, validatePathParam, waitForResource } from "@scaleway/sdk-client";
|
|
3
|
+
import { API as API$1, enrichForPagination, urlParams, validatePathParam, waitForResource } from "@scaleway/sdk-client";
|
|
4
|
+
//#region src/v1alpha1/api.gen.ts
|
|
4
5
|
var jsonContentHeaders = { "Content-Type": "application/json; charset=utf-8" };
|
|
5
6
|
/**
|
|
6
7
|
* Mailbox API.
|
|
7
8
|
|
|
8
9
|
This API allows you to manage your Mailbox services.
|
|
9
10
|
*/
|
|
10
|
-
var API
|
|
11
|
+
var API = class extends API$1 {
|
|
11
12
|
/**
|
|
12
13
|
* Register a domain in a project.. You must specify a `project_id` and a `domain_name` to register a domain in a specific Project.
|
|
13
14
|
*
|
|
@@ -147,4 +148,5 @@ var API$1 = class extends API {
|
|
|
147
148
|
path: `/mailbox/v1alpha1/mailboxes/${validatePathParam("mailboxId", request.mailboxId)}/restore`
|
|
148
149
|
}, unmarshalMailbox);
|
|
149
150
|
};
|
|
150
|
-
|
|
151
|
+
//#endregion
|
|
152
|
+
export { API };
|
|
@@ -1,14 +1,15 @@
|
|
|
1
|
+
//#region src/v1alpha1/content.gen.ts
|
|
1
2
|
/** Lists transient statutes of the enum {@link DomainRecordStatus}. */
|
|
2
|
-
|
|
3
|
+
var DOMAIN_RECORD_TRANSIENT_STATUSES = ["validating"];
|
|
3
4
|
/** Lists transient statutes of the enum {@link DomainStatus}. */
|
|
4
|
-
|
|
5
|
+
var DOMAIN_TRANSIENT_STATUSES = [
|
|
5
6
|
"creating",
|
|
6
7
|
"validating",
|
|
7
8
|
"provisioning",
|
|
8
9
|
"deleting"
|
|
9
10
|
];
|
|
10
11
|
/** Lists transient statutes of the enum {@link MailboxStatus}. */
|
|
11
|
-
|
|
12
|
+
var MAILBOX_TRANSIENT_STATUSES = [
|
|
12
13
|
"creating",
|
|
13
14
|
"waiting_payment",
|
|
14
15
|
"waiting_domain",
|
|
@@ -16,4 +17,5 @@ const MAILBOX_TRANSIENT_STATUSES = [
|
|
|
16
17
|
"deleting",
|
|
17
18
|
"restoring"
|
|
18
19
|
];
|
|
20
|
+
//#endregion
|
|
19
21
|
export { DOMAIN_RECORD_TRANSIENT_STATUSES, DOMAIN_TRANSIENT_STATUSES, MAILBOX_TRANSIENT_STATUSES };
|
|
@@ -3,6 +3,7 @@ import { DOMAIN_RECORD_TRANSIENT_STATUSES, DOMAIN_TRANSIENT_STATUSES, MAILBOX_TR
|
|
|
3
3
|
import { marshalBatchCreateMailboxesRequest, marshalCreateDomainRequest, marshalUpdateMailboxRequest, unmarshalBatchCreateMailboxesResponse, unmarshalDomain, unmarshalGetDomainRecordsResponse, unmarshalListDomainsResponse, unmarshalListMailboxesResponse, unmarshalMailbox } from "./marshalling.gen.js";
|
|
4
4
|
import { API } from "./api.gen.js";
|
|
5
5
|
import { validation_rules_gen_exports } from "./validation-rules.gen.js";
|
|
6
|
+
//#region src/v1alpha1/index.gen.ts
|
|
6
7
|
var index_gen_exports = /* @__PURE__ */ __exportAll({
|
|
7
8
|
API: () => API,
|
|
8
9
|
DOMAIN_RECORD_TRANSIENT_STATUSES: () => DOMAIN_RECORD_TRANSIENT_STATUSES,
|
|
@@ -19,4 +20,5 @@ var index_gen_exports = /* @__PURE__ */ __exportAll({
|
|
|
19
20
|
unmarshalListMailboxesResponse: () => unmarshalListMailboxesResponse,
|
|
20
21
|
unmarshalMailbox: () => unmarshalMailbox
|
|
21
22
|
});
|
|
22
|
-
|
|
23
|
+
//#endregion
|
|
24
|
+
export { API, DOMAIN_RECORD_TRANSIENT_STATUSES, DOMAIN_TRANSIENT_STATUSES, MAILBOX_TRANSIENT_STATUSES, validation_rules_gen_exports as ValidationRules, index_gen_exports, marshalBatchCreateMailboxesRequest, marshalCreateDomainRequest, marshalUpdateMailboxRequest, unmarshalBatchCreateMailboxesResponse, unmarshalDomain, unmarshalGetDomainRecordsResponse, unmarshalListDomainsResponse, unmarshalListMailboxesResponse, unmarshalMailbox };
|
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
import { isJSONObject, unmarshalArrayOfObject, unmarshalDate } from "@scaleway/sdk-client";
|
|
2
|
-
|
|
2
|
+
//#region src/v1alpha1/marshalling.gen.ts
|
|
3
|
+
var unmarshalMailbox = (data) => {
|
|
3
4
|
if (!isJSONObject(data)) throw new TypeError(`Unmarshalling the type 'Mailbox' failed as data isn't a dictionary.`);
|
|
4
5
|
return {
|
|
5
6
|
createdAt: unmarshalDate(data.created_at),
|
|
@@ -17,7 +18,7 @@ const unmarshalMailbox = (data) => {
|
|
|
17
18
|
updatedAt: unmarshalDate(data.updated_at)
|
|
18
19
|
};
|
|
19
20
|
};
|
|
20
|
-
|
|
21
|
+
var unmarshalDomain = (data) => {
|
|
21
22
|
if (!isJSONObject(data)) throw new TypeError(`Unmarshalling the type 'Domain' failed as data isn't a dictionary.`);
|
|
22
23
|
return {
|
|
23
24
|
createdAt: unmarshalDate(data.created_at),
|
|
@@ -34,7 +35,7 @@ const unmarshalDomain = (data) => {
|
|
|
34
35
|
webmailUrl: data.webmail_url
|
|
35
36
|
};
|
|
36
37
|
};
|
|
37
|
-
|
|
38
|
+
var unmarshalBatchCreateMailboxesResponse = (data) => {
|
|
38
39
|
if (!isJSONObject(data)) throw new TypeError(`Unmarshalling the type 'BatchCreateMailboxesResponse' failed as data isn't a dictionary.`);
|
|
39
40
|
return { mailboxes: unmarshalArrayOfObject(data.mailboxes, unmarshalMailbox) };
|
|
40
41
|
};
|
|
@@ -53,7 +54,7 @@ var unmarshalDomainRecord = (data) => {
|
|
|
53
54
|
updatedAt: unmarshalDate(data.updated_at)
|
|
54
55
|
};
|
|
55
56
|
};
|
|
56
|
-
|
|
57
|
+
var unmarshalGetDomainRecordsResponse = (data) => {
|
|
57
58
|
if (!isJSONObject(data)) throw new TypeError(`Unmarshalling the type 'GetDomainRecordsResponse' failed as data isn't a dictionary.`);
|
|
58
59
|
return {
|
|
59
60
|
autoconfig: data.autoconfig ? unmarshalDomainRecord(data.autoconfig) : void 0,
|
|
@@ -71,14 +72,14 @@ const unmarshalGetDomainRecordsResponse = (data) => {
|
|
|
71
72
|
submission: data.submission ? unmarshalDomainRecord(data.submission) : void 0
|
|
72
73
|
};
|
|
73
74
|
};
|
|
74
|
-
|
|
75
|
+
var unmarshalListDomainsResponse = (data) => {
|
|
75
76
|
if (!isJSONObject(data)) throw new TypeError(`Unmarshalling the type 'ListDomainsResponse' failed as data isn't a dictionary.`);
|
|
76
77
|
return {
|
|
77
78
|
domains: unmarshalArrayOfObject(data.domains, unmarshalDomain),
|
|
78
79
|
totalCount: data.total_count
|
|
79
80
|
};
|
|
80
81
|
};
|
|
81
|
-
|
|
82
|
+
var unmarshalListMailboxesResponse = (data) => {
|
|
82
83
|
if (!isJSONObject(data)) throw new TypeError(`Unmarshalling the type 'ListMailboxesResponse' failed as data isn't a dictionary.`);
|
|
83
84
|
return {
|
|
84
85
|
mailboxes: unmarshalArrayOfObject(data.mailboxes, unmarshalMailbox),
|
|
@@ -91,19 +92,20 @@ var marshalBatchCreateMailboxesRequestMailboxParameters = (request, defaults) =>
|
|
|
91
92
|
password: request.password,
|
|
92
93
|
recovery_email: request.recoveryEmail
|
|
93
94
|
});
|
|
94
|
-
|
|
95
|
+
var marshalBatchCreateMailboxesRequest = (request, defaults) => ({
|
|
95
96
|
domain_id: request.domainId,
|
|
96
97
|
mailboxes: request.mailboxes !== void 0 ? request.mailboxes.map((elt) => marshalBatchCreateMailboxesRequestMailboxParameters(elt, defaults)) : void 0,
|
|
97
98
|
subscription_period: request.subscriptionPeriod
|
|
98
99
|
});
|
|
99
|
-
|
|
100
|
+
var marshalCreateDomainRequest = (request, defaults) => ({
|
|
100
101
|
name: request.name,
|
|
101
102
|
project_id: request.projectId ?? defaults.defaultProjectId
|
|
102
103
|
});
|
|
103
|
-
|
|
104
|
+
var marshalUpdateMailboxRequest = (request, defaults) => ({
|
|
104
105
|
display_name: request.displayName,
|
|
105
106
|
new_password: request.newPassword,
|
|
106
107
|
recovery_email: request.recoveryEmail,
|
|
107
108
|
subscription_period: request.subscriptionPeriod
|
|
108
109
|
});
|
|
110
|
+
//#endregion
|
|
109
111
|
export { marshalBatchCreateMailboxesRequest, marshalCreateDomainRequest, marshalUpdateMailboxRequest, unmarshalBatchCreateMailboxesResponse, unmarshalDomain, unmarshalGetDomainRecordsResponse, unmarshalListDomainsResponse, unmarshalListMailboxesResponse, unmarshalMailbox };
|
|
File without changes
|
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import { __exportAll } from "../_virtual/_rolldown/runtime.js";
|
|
2
|
+
//#region src/v1alpha1/validation-rules.gen.ts
|
|
2
3
|
var validation_rules_gen_exports = /* @__PURE__ */ __exportAll({
|
|
3
4
|
BatchCreateMailboxesRequestMailboxParameters: () => BatchCreateMailboxesRequestMailboxParameters,
|
|
4
5
|
CreateDomainRequest: () => CreateDomainRequest,
|
|
@@ -6,7 +7,7 @@ var validation_rules_gen_exports = /* @__PURE__ */ __exportAll({
|
|
|
6
7
|
ListMailboxesRequest: () => ListMailboxesRequest,
|
|
7
8
|
UpdateMailboxRequest: () => UpdateMailboxRequest
|
|
8
9
|
});
|
|
9
|
-
|
|
10
|
+
var BatchCreateMailboxesRequestMailboxParameters = {
|
|
10
11
|
displayName: {
|
|
11
12
|
maxLength: 64,
|
|
12
13
|
minLength: 1
|
|
@@ -24,25 +25,25 @@ const BatchCreateMailboxesRequestMailboxParameters = {
|
|
|
24
25
|
minLength: 6
|
|
25
26
|
}
|
|
26
27
|
};
|
|
27
|
-
|
|
28
|
+
var CreateDomainRequest = { name: {
|
|
28
29
|
maxLength: 253,
|
|
29
30
|
minLength: 1
|
|
30
31
|
} };
|
|
31
|
-
|
|
32
|
+
var ListDomainsRequest = {
|
|
32
33
|
page: { greaterThanOrEqual: 1 },
|
|
33
34
|
pageSize: {
|
|
34
35
|
greaterThanOrEqual: 1,
|
|
35
36
|
lessThanOrEqual: 1e3
|
|
36
37
|
}
|
|
37
38
|
};
|
|
38
|
-
|
|
39
|
+
var ListMailboxesRequest = {
|
|
39
40
|
page: { greaterThanOrEqual: 1 },
|
|
40
41
|
pageSize: {
|
|
41
42
|
greaterThanOrEqual: 1,
|
|
42
43
|
lessThanOrEqual: 1e3
|
|
43
44
|
}
|
|
44
45
|
};
|
|
45
|
-
|
|
46
|
+
var UpdateMailboxRequest = {
|
|
46
47
|
displayName: {
|
|
47
48
|
maxLength: 64,
|
|
48
49
|
minLength: 1
|
|
@@ -56,4 +57,5 @@ const UpdateMailboxRequest = {
|
|
|
56
57
|
minLength: 6
|
|
57
58
|
}
|
|
58
59
|
};
|
|
59
|
-
|
|
60
|
+
//#endregion
|
|
61
|
+
export { BatchCreateMailboxesRequestMailboxParameters, CreateDomainRequest, ListDomainsRequest, ListMailboxesRequest, UpdateMailboxRequest, validation_rules_gen_exports };
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@scaleway/sdk-mailbox",
|
|
3
|
-
"version": "1.1.
|
|
3
|
+
"version": "1.1.1",
|
|
4
4
|
"description": "Scaleway SDK mailbox",
|
|
5
5
|
"license": "Apache-2.0",
|
|
6
6
|
"files": [
|
|
@@ -26,14 +26,14 @@
|
|
|
26
26
|
"node": ">=20.18.3"
|
|
27
27
|
},
|
|
28
28
|
"dependencies": {
|
|
29
|
-
"@scaleway/random-name": "5.1.
|
|
30
|
-
"@scaleway/sdk-std": "2.2.
|
|
29
|
+
"@scaleway/random-name": "5.1.4",
|
|
30
|
+
"@scaleway/sdk-std": "2.2.2"
|
|
31
31
|
},
|
|
32
32
|
"peerDependencies": {
|
|
33
|
-
"@scaleway/sdk-client": "^2.2.
|
|
33
|
+
"@scaleway/sdk-client": "^2.2.2"
|
|
34
34
|
},
|
|
35
35
|
"devDependencies": {
|
|
36
|
-
"@scaleway/sdk-client": "^2.2.
|
|
36
|
+
"@scaleway/sdk-client": "^2.2.2"
|
|
37
37
|
},
|
|
38
38
|
"scripts": {
|
|
39
39
|
"package:check": "pnpm publint",
|