@distilled.cloud/cloudflare 0.12.1 → 0.12.3

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.
@@ -13,147 +13,98 @@ import {} from "../errors.js";
13
13
  // =============================================================================
14
14
  export class AccountCreationForbidden extends Schema.TaggedErrorClass()("AccountCreationForbidden", { code: Schema.Number, message: Schema.String }) {
15
15
  }
16
- T.applyErrorMatchers(AccountCreationForbidden, [{ code: 1002 }]);
16
+ T.applyErrorMatchers(AccountCreationForbidden, [{ "code": 1002 }]);
17
17
  export class AccountNameTooLong extends Schema.TaggedErrorClass()("AccountNameTooLong", { code: Schema.Number, message: Schema.String }) {
18
18
  }
19
- T.applyErrorMatchers(AccountNameTooLong, [
20
- { code: 1001, message: { includes: "too long" } },
21
- ]);
19
+ T.applyErrorMatchers(AccountNameTooLong, [{ "code": 1001, "message": { "includes": "too long" } }]);
22
20
  export class BadRequest extends Schema.TaggedErrorClass()("BadRequest", { code: Schema.Number, message: Schema.String }) {
23
21
  }
24
- T.applyErrorMatchers(BadRequest, [{ code: 400 }]);
22
+ T.applyErrorMatchers(BadRequest, [{ "code": 400 }]);
25
23
  export class EndpointNotFound extends Schema.TaggedErrorClass()("EndpointNotFound", { code: Schema.Number, message: Schema.String }) {
26
24
  }
27
- T.applyErrorMatchers(EndpointNotFound, [{ code: 1199 }]);
25
+ T.applyErrorMatchers(EndpointNotFound, [{ "code": 1199 }]);
28
26
  export class InvalidAccountName extends Schema.TaggedErrorClass()("InvalidAccountName", { code: Schema.Number, message: Schema.String }) {
29
27
  }
30
- T.applyErrorMatchers(InvalidAccountName, [
31
- { code: 1001, message: { includes: "invalid character" } },
32
- ]);
28
+ T.applyErrorMatchers(InvalidAccountName, [{ "code": 1001, "message": { "includes": "invalid character" } }]);
33
29
  export class InvalidRoute extends Schema.TaggedErrorClass()("InvalidRoute", { code: Schema.Number, message: Schema.String }) {
34
30
  }
35
- T.applyErrorMatchers(InvalidRoute, [{ code: 7003 }]);
31
+ T.applyErrorMatchers(InvalidRoute, [{ "code": 7003 }]);
36
32
  export class InvalidTokenName extends Schema.TaggedErrorClass()("InvalidTokenName", { code: Schema.Number, message: Schema.String }) {
37
33
  }
38
- T.applyErrorMatchers(InvalidTokenName, [
39
- { code: 400, message: { includes: "name must have a length" } },
40
- ]);
34
+ T.applyErrorMatchers(InvalidTokenName, [{ "code": 400, "message": { "includes": "name must have a length" } }]);
41
35
  export class JsonDecodeFailure extends Schema.TaggedErrorClass()("JsonDecodeFailure", { code: Schema.Number, message: Schema.String }) {
42
36
  }
43
- T.applyErrorMatchers(JsonDecodeFailure, [{ code: 1198 }]);
37
+ T.applyErrorMatchers(JsonDecodeFailure, [{ "code": 1198 }]);
44
38
  export class MemberNotFound extends Schema.TaggedErrorClass()("MemberNotFound", { code: Schema.Number, message: Schema.String }) {
45
39
  }
46
- T.applyErrorMatchers(MemberNotFound, [{ code: 1003 }]);
40
+ T.applyErrorMatchers(MemberNotFound, [{ "code": 1003 }]);
47
41
  export class MethodNotAllowed extends Schema.TaggedErrorClass()("MethodNotAllowed", { code: Schema.Number, message: Schema.String }) {
48
42
  }
49
- T.applyErrorMatchers(MethodNotAllowed, [
50
- { code: 7001 },
51
- { code: 10000 },
52
- { code: 10405 },
53
- ]);
43
+ T.applyErrorMatchers(MethodNotAllowed, [{ "code": 7001 }, { "code": 10000 }, { "code": 10405 }]);
54
44
  export class MissingAuthenticationToken extends Schema.TaggedErrorClass()("MissingAuthenticationToken", { code: Schema.Number, message: Schema.String }) {
55
45
  }
56
- T.applyErrorMatchers(MissingAuthenticationToken, [{ code: 1001 }]);
46
+ T.applyErrorMatchers(MissingAuthenticationToken, [{ "code": 1001 }]);
57
47
  export class MissingName extends Schema.TaggedErrorClass()("MissingName", { code: Schema.Number, message: Schema.String }) {
58
48
  }
59
- T.applyErrorMatchers(MissingName, [{ code: 1001 }]);
49
+ T.applyErrorMatchers(MissingName, [{ "code": 1001 }]);
50
+ export class PermissionGroupNotFound extends Schema.TaggedErrorClass()("PermissionGroupNotFound", { code: Schema.Number, message: Schema.String }) {
51
+ }
52
+ T.applyErrorMatchers(PermissionGroupNotFound, [{ "code": 1001, "message": { "includes": "Permission group" } }]);
53
+ export class TokenNotFound extends Schema.TaggedErrorClass()("TokenNotFound", { code: Schema.Number, message: Schema.String }) {
54
+ }
55
+ T.applyErrorMatchers(TokenNotFound, [{ "code": 1003 }]);
60
56
  export class UpdateAccountTypeNotSupported extends Schema.TaggedErrorClass()("UpdateAccountTypeNotSupported", { code: Schema.Number, message: Schema.String }) {
61
57
  }
62
- T.applyErrorMatchers(UpdateAccountTypeNotSupported, [
63
- { code: 1001, message: { includes: "account type is not supported" } },
64
- ]);
58
+ T.applyErrorMatchers(UpdateAccountTypeNotSupported, [{ "code": 1001, "message": { "includes": "account type is not supported" } }]);
65
59
  export class ValidationError extends Schema.TaggedErrorClass()("ValidationError", { code: Schema.Number, message: Schema.String }) {
66
60
  }
67
- T.applyErrorMatchers(ValidationError, [{ code: 1001 }]);
61
+ T.applyErrorMatchers(ValidationError, [{ "code": 1001 }]);
68
62
  export const GetAccountRequest = /*@__PURE__*/ /*#__PURE__*/ Schema.Struct({
69
- accountId: Schema.String.pipe(T.HttpPath("account_id")),
70
- }).pipe(T.Http({ method: "GET", path: "/accounts/{account_id}" }));
63
+ accountId: Schema.String.pipe(T.HttpPath("account_id"))
64
+ })
65
+ .pipe(T.Http({ method: "GET", path: "/accounts/{account_id}" }));
71
66
  export const GetAccountResponse = /*@__PURE__*/ /*#__PURE__*/ Schema.Struct({
72
67
  id: Schema.String,
73
68
  name: Schema.String,
74
69
  type: Schema.Literals(["standard", "enterprise"]),
75
70
  createdOn: Schema.optional(Schema.Union([Schema.String, Schema.Null])),
76
- managedBy: Schema.optional(Schema.Union([
77
- Schema.Struct({
71
+ managedBy: Schema.optional(Schema.Union([Schema.Struct({
78
72
  parentOrgId: Schema.optional(Schema.Union([Schema.String, Schema.Null])),
79
- parentOrgName: Schema.optional(Schema.Union([Schema.String, Schema.Null])),
80
- }).pipe(Schema.encodeKeys({
81
- parentOrgId: "parent_org_id",
82
- parentOrgName: "parent_org_name",
83
- })),
84
- Schema.Null,
85
- ])),
86
- settings: Schema.optional(Schema.Union([
87
- Schema.Struct({
73
+ parentOrgName: Schema.optional(Schema.Union([Schema.String, Schema.Null]))
74
+ }).pipe(Schema.encodeKeys({ parentOrgId: "parent_org_id", parentOrgName: "parent_org_name" })), Schema.Null])),
75
+ settings: Schema.optional(Schema.Union([Schema.Struct({
88
76
  abuseContactEmail: Schema.optional(Schema.Union([Schema.String, Schema.Null])),
89
- enforceTwofactor: Schema.optional(Schema.Union([Schema.Boolean, Schema.Null])),
90
- }).pipe(Schema.encodeKeys({
91
- abuseContactEmail: "abuse_contact_email",
92
- enforceTwofactor: "enforce_twofactor",
93
- })),
94
- Schema.Null,
95
- ])),
96
- })
97
- .pipe(Schema.encodeKeys({
98
- id: "id",
99
- name: "name",
100
- type: "type",
101
- createdOn: "created_on",
102
- managedBy: "managed_by",
103
- settings: "settings",
104
- }))
105
- .pipe(T.ResponsePath("result"));
77
+ enforceTwofactor: Schema.optional(Schema.Union([Schema.Boolean, Schema.Null]))
78
+ }).pipe(Schema.encodeKeys({ abuseContactEmail: "abuse_contact_email", enforceTwofactor: "enforce_twofactor" })), Schema.Null]))
79
+ }).pipe(Schema.encodeKeys({ id: "id", name: "name", type: "type", createdOn: "created_on", managedBy: "managed_by", settings: "settings" })).pipe(T.ResponsePath("result"));
106
80
  export const getAccount = /*@__PURE__*/ /*#__PURE__*/ API.make(() => ({
107
81
  input: GetAccountRequest,
108
82
  output: GetAccountResponse,
109
83
  errors: [InvalidRoute],
110
84
  }));
111
- export const ListAccountsRequest = /*@__PURE__*/ /*#__PURE__*/ Schema.Struct({}).pipe(T.Http({ method: "GET", path: "/accounts" }));
85
+ export const ListAccountsRequest = /*@__PURE__*/ /*#__PURE__*/ Schema.Struct({})
86
+ .pipe(T.Http({ method: "GET", path: "/accounts" }));
112
87
  export const ListAccountsResponse = /*@__PURE__*/ /*#__PURE__*/ Schema.Struct({
113
88
  result: Schema.Array(Schema.Struct({
114
89
  id: Schema.String,
115
90
  name: Schema.String,
116
91
  type: Schema.Literals(["standard", "enterprise"]),
117
92
  createdOn: Schema.optional(Schema.Union([Schema.String, Schema.Null])),
118
- managedBy: Schema.optional(Schema.Union([
119
- Schema.Struct({
93
+ managedBy: Schema.optional(Schema.Union([Schema.Struct({
120
94
  parentOrgId: Schema.optional(Schema.Union([Schema.String, Schema.Null])),
121
- parentOrgName: Schema.optional(Schema.Union([Schema.String, Schema.Null])),
122
- }).pipe(Schema.encodeKeys({
123
- parentOrgId: "parent_org_id",
124
- parentOrgName: "parent_org_name",
125
- })),
126
- Schema.Null,
127
- ])),
128
- settings: Schema.optional(Schema.Union([
129
- Schema.Struct({
95
+ parentOrgName: Schema.optional(Schema.Union([Schema.String, Schema.Null]))
96
+ }).pipe(Schema.encodeKeys({ parentOrgId: "parent_org_id", parentOrgName: "parent_org_name" })), Schema.Null])),
97
+ settings: Schema.optional(Schema.Union([Schema.Struct({
130
98
  abuseContactEmail: Schema.optional(Schema.Union([Schema.String, Schema.Null])),
131
- enforceTwofactor: Schema.optional(Schema.Union([Schema.Boolean, Schema.Null])),
132
- }).pipe(Schema.encodeKeys({
133
- abuseContactEmail: "abuse_contact_email",
134
- enforceTwofactor: "enforce_twofactor",
135
- })),
136
- Schema.Null,
137
- ])),
138
- }).pipe(Schema.encodeKeys({
139
- id: "id",
140
- name: "name",
141
- type: "type",
142
- createdOn: "created_on",
143
- managedBy: "managed_by",
144
- settings: "settings",
145
- }))),
99
+ enforceTwofactor: Schema.optional(Schema.Union([Schema.Boolean, Schema.Null]))
100
+ }).pipe(Schema.encodeKeys({ abuseContactEmail: "abuse_contact_email", enforceTwofactor: "enforce_twofactor" })), Schema.Null]))
101
+ }).pipe(Schema.encodeKeys({ id: "id", name: "name", type: "type", createdOn: "created_on", managedBy: "managed_by", settings: "settings" }))),
146
102
  resultInfo: Schema.Struct({
147
103
  count: Schema.optional(Schema.Union([Schema.Number, Schema.Null])),
148
104
  page: Schema.optional(Schema.Union([Schema.Number, Schema.Null])),
149
105
  perPage: Schema.optional(Schema.Union([Schema.Number, Schema.Null])),
150
- totalCount: Schema.optional(Schema.Union([Schema.Number, Schema.Null])),
151
- }).pipe(Schema.encodeKeys({
152
- count: "count",
153
- page: "page",
154
- perPage: "per_page",
155
- totalCount: "total_count",
156
- })),
106
+ totalCount: Schema.optional(Schema.Union([Schema.Number, Schema.Null]))
107
+ }).pipe(Schema.encodeKeys({ count: "count", page: "page", perPage: "per_page", totalCount: "total_count" }))
157
108
  }).pipe(Schema.encodeKeys({ result: "result", resultInfo: "result_info" }));
158
109
  export const listAccounts = /*@__PURE__*/ /*#__PURE__*/ API.makePaginated(() => ({
159
110
  input: ListAccountsRequest,
@@ -171,44 +122,24 @@ export const CreateAccountRequest = /*@__PURE__*/ /*#__PURE__*/ Schema.Struct({
171
122
  name: Schema.String,
172
123
  type: Schema.optional(Schema.Literals(["standard", "enterprise"])),
173
124
  unit: Schema.optional(Schema.Struct({
174
- id: Schema.optional(Schema.String),
175
- })),
176
- }).pipe(T.Http({ method: "POST", path: "/accounts" }));
125
+ id: Schema.optional(Schema.String)
126
+ }))
127
+ })
128
+ .pipe(T.Http({ method: "POST", path: "/accounts" }));
177
129
  export const CreateAccountResponse = /*@__PURE__*/ /*#__PURE__*/ Schema.Struct({
178
130
  id: Schema.String,
179
131
  name: Schema.String,
180
132
  type: Schema.Literals(["standard", "enterprise"]),
181
133
  createdOn: Schema.optional(Schema.Union([Schema.String, Schema.Null])),
182
- managedBy: Schema.optional(Schema.Union([
183
- Schema.Struct({
134
+ managedBy: Schema.optional(Schema.Union([Schema.Struct({
184
135
  parentOrgId: Schema.optional(Schema.Union([Schema.String, Schema.Null])),
185
- parentOrgName: Schema.optional(Schema.Union([Schema.String, Schema.Null])),
186
- }).pipe(Schema.encodeKeys({
187
- parentOrgId: "parent_org_id",
188
- parentOrgName: "parent_org_name",
189
- })),
190
- Schema.Null,
191
- ])),
192
- settings: Schema.optional(Schema.Union([
193
- Schema.Struct({
136
+ parentOrgName: Schema.optional(Schema.Union([Schema.String, Schema.Null]))
137
+ }).pipe(Schema.encodeKeys({ parentOrgId: "parent_org_id", parentOrgName: "parent_org_name" })), Schema.Null])),
138
+ settings: Schema.optional(Schema.Union([Schema.Struct({
194
139
  abuseContactEmail: Schema.optional(Schema.Union([Schema.String, Schema.Null])),
195
- enforceTwofactor: Schema.optional(Schema.Union([Schema.Boolean, Schema.Null])),
196
- }).pipe(Schema.encodeKeys({
197
- abuseContactEmail: "abuse_contact_email",
198
- enforceTwofactor: "enforce_twofactor",
199
- })),
200
- Schema.Null,
201
- ])),
202
- })
203
- .pipe(Schema.encodeKeys({
204
- id: "id",
205
- name: "name",
206
- type: "type",
207
- createdOn: "created_on",
208
- managedBy: "managed_by",
209
- settings: "settings",
210
- }))
211
- .pipe(T.ResponsePath("result"));
140
+ enforceTwofactor: Schema.optional(Schema.Union([Schema.Boolean, Schema.Null]))
141
+ }).pipe(Schema.encodeKeys({ abuseContactEmail: "abuse_contact_email", enforceTwofactor: "enforce_twofactor" })), Schema.Null]))
142
+ }).pipe(Schema.encodeKeys({ id: "id", name: "name", type: "type", createdOn: "created_on", managedBy: "managed_by", settings: "settings" })).pipe(T.ResponsePath("result"));
212
143
  export const createAccount = /*@__PURE__*/ /*#__PURE__*/ API.make(() => ({
213
144
  input: CreateAccountRequest,
214
145
  output: CreateAccountResponse,
@@ -222,69 +153,35 @@ export const UpdateAccountRequest = /*@__PURE__*/ /*#__PURE__*/ Schema.Struct({
222
153
  managedBy: Schema.optional(Schema.Unknown),
223
154
  settings: Schema.optional(Schema.Struct({
224
155
  abuseContactEmail: Schema.optional(Schema.String),
225
- enforceTwofactor: Schema.optional(Schema.Boolean),
226
- }).pipe(Schema.encodeKeys({
227
- abuseContactEmail: "abuse_contact_email",
228
- enforceTwofactor: "enforce_twofactor",
229
- }))),
230
- }).pipe(Schema.encodeKeys({
231
- id: "id",
232
- name: "name",
233
- type: "type",
234
- managedBy: "managed_by",
235
- settings: "settings",
236
- }), T.Http({ method: "PUT", path: "/accounts/{account_id}" }));
156
+ enforceTwofactor: Schema.optional(Schema.Boolean)
157
+ }).pipe(Schema.encodeKeys({ abuseContactEmail: "abuse_contact_email", enforceTwofactor: "enforce_twofactor" })))
158
+ })
159
+ .pipe(Schema.encodeKeys({ id: "id", name: "name", type: "type", managedBy: "managed_by", settings: "settings" }), T.Http({ method: "PUT", path: "/accounts/{account_id}" }));
237
160
  export const UpdateAccountResponse = /*@__PURE__*/ /*#__PURE__*/ Schema.Struct({
238
161
  id: Schema.String,
239
162
  name: Schema.String,
240
163
  type: Schema.Literals(["standard", "enterprise"]),
241
164
  createdOn: Schema.optional(Schema.Union([Schema.String, Schema.Null])),
242
- managedBy: Schema.optional(Schema.Union([
243
- Schema.Struct({
165
+ managedBy: Schema.optional(Schema.Union([Schema.Struct({
244
166
  parentOrgId: Schema.optional(Schema.Union([Schema.String, Schema.Null])),
245
- parentOrgName: Schema.optional(Schema.Union([Schema.String, Schema.Null])),
246
- }).pipe(Schema.encodeKeys({
247
- parentOrgId: "parent_org_id",
248
- parentOrgName: "parent_org_name",
249
- })),
250
- Schema.Null,
251
- ])),
252
- settings: Schema.optional(Schema.Union([
253
- Schema.Struct({
167
+ parentOrgName: Schema.optional(Schema.Union([Schema.String, Schema.Null]))
168
+ }).pipe(Schema.encodeKeys({ parentOrgId: "parent_org_id", parentOrgName: "parent_org_name" })), Schema.Null])),
169
+ settings: Schema.optional(Schema.Union([Schema.Struct({
254
170
  abuseContactEmail: Schema.optional(Schema.Union([Schema.String, Schema.Null])),
255
- enforceTwofactor: Schema.optional(Schema.Union([Schema.Boolean, Schema.Null])),
256
- }).pipe(Schema.encodeKeys({
257
- abuseContactEmail: "abuse_contact_email",
258
- enforceTwofactor: "enforce_twofactor",
259
- })),
260
- Schema.Null,
261
- ])),
262
- })
263
- .pipe(Schema.encodeKeys({
264
- id: "id",
265
- name: "name",
266
- type: "type",
267
- createdOn: "created_on",
268
- managedBy: "managed_by",
269
- settings: "settings",
270
- }))
271
- .pipe(T.ResponsePath("result"));
171
+ enforceTwofactor: Schema.optional(Schema.Union([Schema.Boolean, Schema.Null]))
172
+ }).pipe(Schema.encodeKeys({ abuseContactEmail: "abuse_contact_email", enforceTwofactor: "enforce_twofactor" })), Schema.Null]))
173
+ }).pipe(Schema.encodeKeys({ id: "id", name: "name", type: "type", createdOn: "created_on", managedBy: "managed_by", settings: "settings" })).pipe(T.ResponsePath("result"));
272
174
  export const updateAccount = /*@__PURE__*/ /*#__PURE__*/ API.make(() => ({
273
175
  input: UpdateAccountRequest,
274
176
  output: UpdateAccountResponse,
275
- errors: [
276
- InvalidAccountName,
277
- AccountNameTooLong,
278
- UpdateAccountTypeNotSupported,
279
- InvalidRoute,
280
- MethodNotAllowed,
281
- ],
177
+ errors: [InvalidAccountName, AccountNameTooLong, UpdateAccountTypeNotSupported, InvalidRoute, MethodNotAllowed],
282
178
  }));
283
179
  export const DeleteAccountRequest = /*@__PURE__*/ /*#__PURE__*/ Schema.Struct({
284
- accountId: Schema.String.pipe(T.HttpPath("account_id")),
285
- }).pipe(T.Http({ method: "DELETE", path: "/accounts/{account_id}" }));
180
+ accountId: Schema.String.pipe(T.HttpPath("account_id"))
181
+ })
182
+ .pipe(T.Http({ method: "DELETE", path: "/accounts/{account_id}" }));
286
183
  export const DeleteAccountResponse = /*@__PURE__*/ /*#__PURE__*/ Schema.Struct({
287
- id: Schema.String,
184
+ id: Schema.String
288
185
  }).pipe(T.ResponsePath("result"));
289
186
  export const deleteAccount = /*@__PURE__*/ /*#__PURE__*/ API.make(() => ({
290
187
  input: DeleteAccountRequest,
@@ -296,179 +193,122 @@ export const ListLogAuditsRequest = /*@__PURE__*/ /*#__PURE__*/ Schema.Struct({
296
193
  before: Schema.String.pipe(T.HttpQuery("before")),
297
194
  since: Schema.String.pipe(T.HttpQuery("since")),
298
195
  id: Schema.optional(Schema.Struct({
299
- not: Schema.optional(Schema.Array(Schema.String)),
196
+ not: Schema.optional(Schema.Array(Schema.String))
300
197
  })).pipe(T.HttpQuery("id")),
301
198
  accountName: Schema.optional(Schema.Struct({
302
- not: Schema.optional(Schema.Array(Schema.String)),
199
+ not: Schema.optional(Schema.Array(Schema.String))
303
200
  })).pipe(T.HttpQuery("account_name")),
304
201
  actionResult: Schema.optional(Schema.Struct({
305
- not: Schema.optional(Schema.Array(Schema.Literals(["success", "failure"]))),
202
+ not: Schema.optional(Schema.Array(Schema.Literals(["success", "failure"])))
306
203
  })).pipe(T.HttpQuery("action_result")),
307
204
  actionType: Schema.optional(Schema.Struct({
308
- not: Schema.optional(Schema.Array(Schema.Literals(["create", "delete", "view", "update"]))),
205
+ not: Schema.optional(Schema.Array(Schema.Literals(["create", "delete", "view", "update"])))
309
206
  })).pipe(T.HttpQuery("action_type")),
310
207
  actorContext: Schema.optional(Schema.Struct({
311
- not: Schema.optional(Schema.Array(Schema.Literals([
312
- "api_key",
313
- "api_token",
314
- "dash",
315
- "oauth",
316
- "origin_ca_key",
317
- ]))),
208
+ not: Schema.optional(Schema.Array(Schema.Literals(["api_key", "api_token", "dash", "oauth", "origin_ca_key"])))
318
209
  })).pipe(T.HttpQuery("actor_context")),
319
210
  actorEmail: Schema.optional(Schema.Struct({
320
- not: Schema.optional(Schema.Array(Schema.String)),
211
+ not: Schema.optional(Schema.Array(Schema.String))
321
212
  })).pipe(T.HttpQuery("actor_email")),
322
213
  actorId: Schema.optional(Schema.Struct({
323
- not: Schema.optional(Schema.Array(Schema.String)),
214
+ not: Schema.optional(Schema.Array(Schema.String))
324
215
  })).pipe(T.HttpQuery("actor_id")),
325
216
  actorIpAddress: Schema.optional(Schema.Struct({
326
- not: Schema.optional(Schema.Array(Schema.String)),
217
+ not: Schema.optional(Schema.Array(Schema.String))
327
218
  })).pipe(T.HttpQuery("actor_ip_address")),
328
219
  actorTokenId: Schema.optional(Schema.Struct({
329
- not: Schema.optional(Schema.Array(Schema.String)),
220
+ not: Schema.optional(Schema.Array(Schema.String))
330
221
  })).pipe(T.HttpQuery("actor_token_id")),
331
222
  actorTokenName: Schema.optional(Schema.Struct({
332
- not: Schema.optional(Schema.Array(Schema.String)),
223
+ not: Schema.optional(Schema.Array(Schema.String))
333
224
  })).pipe(T.HttpQuery("actor_token_name")),
334
225
  actorType: Schema.optional(Schema.Struct({
335
- not: Schema.optional(Schema.Array(Schema.Literals(["account", "cloudflare_admin", "system", "user"]))),
226
+ not: Schema.optional(Schema.Array(Schema.Literals(["account", "cloudflare_admin", "system", "user"])))
336
227
  })).pipe(T.HttpQuery("actor_type")),
337
228
  auditLogId: Schema.optional(Schema.Struct({
338
- not: Schema.optional(Schema.Array(Schema.String)),
229
+ not: Schema.optional(Schema.Array(Schema.String))
339
230
  })).pipe(T.HttpQuery("audit_log_id")),
340
231
  direction: Schema.optional(Schema.Literals(["desc", "asc"])).pipe(T.HttpQuery("direction")),
341
232
  limit: Schema.optional(Schema.Number).pipe(T.HttpQuery("limit")),
342
233
  rawCfRayId: Schema.optional(Schema.Struct({
343
- not: Schema.optional(Schema.Array(Schema.String)),
234
+ not: Schema.optional(Schema.Array(Schema.String))
344
235
  })).pipe(T.HttpQuery("raw_cf_ray_id")),
345
236
  rawMethod: Schema.optional(Schema.Struct({
346
- not: Schema.optional(Schema.Array(Schema.String)),
237
+ not: Schema.optional(Schema.Array(Schema.String))
347
238
  })).pipe(T.HttpQuery("raw_method")),
348
239
  rawStatusCode: Schema.optional(Schema.Struct({
349
- not: Schema.optional(Schema.Array(Schema.Number)),
240
+ not: Schema.optional(Schema.Array(Schema.Number))
350
241
  })).pipe(T.HttpQuery("raw_status_code")),
351
242
  rawUri: Schema.optional(Schema.Struct({
352
- not: Schema.optional(Schema.Array(Schema.String)),
243
+ not: Schema.optional(Schema.Array(Schema.String))
353
244
  })).pipe(T.HttpQuery("raw_uri")),
354
245
  resourceId: Schema.optional(Schema.Struct({
355
- not: Schema.optional(Schema.Array(Schema.String)),
246
+ not: Schema.optional(Schema.Array(Schema.String))
356
247
  })).pipe(T.HttpQuery("resource_id")),
357
248
  resourceProduct: Schema.optional(Schema.Struct({
358
- not: Schema.optional(Schema.Array(Schema.String)),
249
+ not: Schema.optional(Schema.Array(Schema.String))
359
250
  })).pipe(T.HttpQuery("resource_product")),
360
251
  resourceScope: Schema.optional(Schema.Struct({
361
- not: Schema.optional(Schema.Array(Schema.Literals(["accounts", "user", "zones"]))),
252
+ not: Schema.optional(Schema.Array(Schema.Literals(["accounts", "user", "zones"])))
362
253
  })).pipe(T.HttpQuery("resource_scope")),
363
254
  resourceType: Schema.optional(Schema.Struct({
364
- not: Schema.optional(Schema.Array(Schema.String)),
255
+ not: Schema.optional(Schema.Array(Schema.String))
365
256
  })).pipe(T.HttpQuery("resource_type")),
366
257
  zoneId: Schema.optional(Schema.Struct({
367
- not: Schema.optional(Schema.Array(Schema.String)),
258
+ not: Schema.optional(Schema.Array(Schema.String))
368
259
  })).pipe(T.HttpQuery("zone_id")),
369
260
  zoneName: Schema.optional(Schema.Struct({
370
- not: Schema.optional(Schema.Array(Schema.String)),
371
- })).pipe(T.HttpQuery("zone_name")),
372
- }).pipe(T.Http({ method: "GET", path: "/accounts/{account_id}/logs/audit" }));
261
+ not: Schema.optional(Schema.Array(Schema.String))
262
+ })).pipe(T.HttpQuery("zone_name"))
263
+ })
264
+ .pipe(T.Http({ method: "GET", path: "/accounts/{account_id}/logs/audit" }));
373
265
  export const ListLogAuditsResponse = /*@__PURE__*/ /*#__PURE__*/ Schema.Struct({
374
266
  result: Schema.Array(Schema.Struct({
375
267
  id: Schema.optional(Schema.Union([Schema.String, Schema.Null])),
376
- account: Schema.optional(Schema.Union([
377
- Schema.Struct({
268
+ account: Schema.optional(Schema.Union([Schema.Struct({
378
269
  id: Schema.optional(Schema.Union([Schema.String, Schema.Null])),
379
- name: Schema.optional(Schema.Union([Schema.String, Schema.Null])),
380
- }),
381
- Schema.Null,
382
- ])),
383
- action: Schema.optional(Schema.Union([
384
- Schema.Struct({
270
+ name: Schema.optional(Schema.Union([Schema.String, Schema.Null]))
271
+ }), Schema.Null])),
272
+ action: Schema.optional(Schema.Union([Schema.Struct({
385
273
  description: Schema.optional(Schema.Union([Schema.String, Schema.Null])),
386
274
  result: Schema.optional(Schema.Union([Schema.String, Schema.Null])),
387
275
  time: Schema.optional(Schema.Union([Schema.String, Schema.Null])),
388
- type: Schema.optional(Schema.Union([Schema.String, Schema.Null])),
389
- }),
390
- Schema.Null,
391
- ])),
392
- actor: Schema.optional(Schema.Union([
393
- Schema.Struct({
276
+ type: Schema.optional(Schema.Union([Schema.String, Schema.Null]))
277
+ }), Schema.Null])),
278
+ actor: Schema.optional(Schema.Union([Schema.Struct({
394
279
  id: Schema.optional(Schema.Union([Schema.String, Schema.Null])),
395
- context: Schema.optional(Schema.Union([
396
- Schema.Literals([
397
- "api_key",
398
- "api_token",
399
- "dash",
400
- "oauth",
401
- "origin_ca_key",
402
- ]),
403
- Schema.Null,
404
- ])),
280
+ context: Schema.optional(Schema.Union([Schema.Literals(["api_key", "api_token", "dash", "oauth", "origin_ca_key"]), Schema.Null])),
405
281
  email: Schema.optional(Schema.Union([Schema.String, Schema.Null])),
406
282
  ipAddress: Schema.optional(Schema.Union([Schema.String, Schema.Null])),
407
283
  tokenId: Schema.optional(Schema.Union([Schema.String, Schema.Null])),
408
284
  tokenName: Schema.optional(Schema.Union([Schema.String, Schema.Null])),
409
- type: Schema.optional(Schema.Union([
410
- Schema.Literals([
411
- "account",
412
- "cloudflare_admin",
413
- "system",
414
- "user",
415
- ]),
416
- Schema.Null,
417
- ])),
418
- }).pipe(Schema.encodeKeys({
419
- id: "id",
420
- context: "context",
421
- email: "email",
422
- ipAddress: "ip_address",
423
- tokenId: "token_id",
424
- tokenName: "token_name",
425
- type: "type",
426
- })),
427
- Schema.Null,
428
- ])),
429
- raw: Schema.optional(Schema.Union([
430
- Schema.Struct({
285
+ type: Schema.optional(Schema.Union([Schema.Literals(["account", "cloudflare_admin", "system", "user"]), Schema.Null]))
286
+ }).pipe(Schema.encodeKeys({ id: "id", context: "context", email: "email", ipAddress: "ip_address", tokenId: "token_id", tokenName: "token_name", type: "type" })), Schema.Null])),
287
+ raw: Schema.optional(Schema.Union([Schema.Struct({
431
288
  cfRayId: Schema.optional(Schema.Union([Schema.String, Schema.Null])),
432
289
  method: Schema.optional(Schema.Union([Schema.String, Schema.Null])),
433
290
  statusCode: Schema.optional(Schema.Union([Schema.Number, Schema.Null])),
434
291
  uri: Schema.optional(Schema.Union([Schema.String, Schema.Null])),
435
- userAgent: Schema.optional(Schema.Union([Schema.String, Schema.Null])),
436
- }).pipe(Schema.encodeKeys({
437
- cfRayId: "cf_ray_id",
438
- method: "method",
439
- statusCode: "status_code",
440
- uri: "uri",
441
- userAgent: "user_agent",
442
- })),
443
- Schema.Null,
444
- ])),
445
- resource: Schema.optional(Schema.Union([
446
- Schema.Struct({
292
+ userAgent: Schema.optional(Schema.Union([Schema.String, Schema.Null]))
293
+ }).pipe(Schema.encodeKeys({ cfRayId: "cf_ray_id", method: "method", statusCode: "status_code", uri: "uri", userAgent: "user_agent" })), Schema.Null])),
294
+ resource: Schema.optional(Schema.Union([Schema.Struct({
447
295
  id: Schema.optional(Schema.Union([Schema.String, Schema.Null])),
448
296
  product: Schema.optional(Schema.Union([Schema.String, Schema.Null])),
449
297
  request: Schema.optional(Schema.Union([Schema.Unknown, Schema.Null])),
450
298
  response: Schema.optional(Schema.Union([Schema.Unknown, Schema.Null])),
451
299
  scope: Schema.optional(Schema.Union([Schema.Unknown, Schema.Null])),
452
- type: Schema.optional(Schema.Union([Schema.String, Schema.Null])),
453
- }),
454
- Schema.Null,
455
- ])),
456
- zone: Schema.optional(Schema.Union([
457
- Schema.Struct({
300
+ type: Schema.optional(Schema.Union([Schema.String, Schema.Null]))
301
+ }), Schema.Null])),
302
+ zone: Schema.optional(Schema.Union([Schema.Struct({
458
303
  id: Schema.optional(Schema.Union([Schema.String, Schema.Null])),
459
- name: Schema.optional(Schema.Union([Schema.String, Schema.Null])),
460
- }),
461
- Schema.Null,
462
- ])),
304
+ name: Schema.optional(Schema.Union([Schema.String, Schema.Null]))
305
+ }), Schema.Null]))
463
306
  })),
464
307
  resultInfo: Schema.Struct({
465
- cursors: Schema.optional(Schema.Union([
466
- Schema.Struct({
467
- after: Schema.optional(Schema.Union([Schema.String, Schema.Null])),
468
- }),
469
- Schema.Null,
470
- ])),
471
- }),
308
+ cursors: Schema.optional(Schema.Union([Schema.Struct({
309
+ after: Schema.optional(Schema.Union([Schema.String, Schema.Null]))
310
+ }), Schema.Null]))
311
+ })
472
312
  }).pipe(Schema.encodeKeys({ result: "result", resultInfo: "result_info" }));
473
313
  export const listLogAudits = /*@__PURE__*/ /*#__PURE__*/ API.makePaginated(() => ({
474
314
  input: ListLogAuditsRequest,
@@ -483,159 +323,85 @@ export const listLogAudits = /*@__PURE__*/ /*#__PURE__*/ API.makePaginated(() =>
483
323
  }));
484
324
  export const GetMemberRequest = /*@__PURE__*/ /*#__PURE__*/ Schema.Struct({
485
325
  memberId: Schema.String.pipe(T.HttpPath("memberId")),
486
- accountId: Schema.String.pipe(T.HttpPath("account_id")),
487
- }).pipe(T.Http({ method: "GET", path: "/accounts/{account_id}/members/{memberId}" }));
326
+ accountId: Schema.String.pipe(T.HttpPath("account_id"))
327
+ })
328
+ .pipe(T.Http({ method: "GET", path: "/accounts/{account_id}/members/{memberId}" }));
488
329
  export const GetMemberResponse = /*@__PURE__*/ /*#__PURE__*/ Schema.Struct({
489
330
  id: Schema.optional(Schema.Union([Schema.String, Schema.Null])),
490
331
  email: Schema.optional(Schema.Union([Schema.String, Schema.Null])),
491
- policies: Schema.optional(Schema.Union([
492
- Schema.Array(Schema.Struct({
332
+ policies: Schema.optional(Schema.Union([Schema.Array(Schema.Struct({
493
333
  id: Schema.optional(Schema.Union([Schema.String, Schema.Null])),
494
334
  access: Schema.optional(Schema.Union([Schema.Literals(["allow", "deny"]), Schema.Null])),
495
- permissionGroups: Schema.optional(Schema.Union([
496
- Schema.Array(Schema.Struct({
497
- id: Schema.String,
498
- })),
499
- Schema.Null,
500
- ])),
501
- resourceGroups: Schema.optional(Schema.Union([
502
- Schema.Array(Schema.Struct({
503
- id: Schema.String,
504
- })),
505
- Schema.Null,
506
- ])),
507
- }).pipe(Schema.encodeKeys({
508
- id: "id",
509
- access: "access",
510
- permissionGroups: "permission_groups",
511
- resourceGroups: "resource_groups",
512
- }))),
513
- Schema.Null,
514
- ])),
515
- roles: Schema.optional(Schema.Union([
516
- Schema.Array(Schema.Struct({
335
+ permissionGroups: Schema.optional(Schema.Union([Schema.Array(Schema.Struct({
336
+ id: Schema.String
337
+ })), Schema.Null])),
338
+ resourceGroups: Schema.optional(Schema.Union([Schema.Array(Schema.Struct({
339
+ id: Schema.String
340
+ })), Schema.Null]))
341
+ }).pipe(Schema.encodeKeys({ id: "id", access: "access", permissionGroups: "permission_groups", resourceGroups: "resource_groups" }))), Schema.Null])),
342
+ roles: Schema.optional(Schema.Union([Schema.Array(Schema.Struct({
517
343
  id: Schema.String,
518
344
  description: Schema.String,
519
345
  name: Schema.String,
520
346
  permissions: Schema.Struct({
521
- analytics: Schema.optional(Schema.Union([
522
- Schema.Struct({
347
+ analytics: Schema.optional(Schema.Union([Schema.Struct({
523
348
  read: Schema.optional(Schema.Union([Schema.Boolean, Schema.Null])),
524
- write: Schema.optional(Schema.Union([Schema.Boolean, Schema.Null])),
525
- }),
526
- Schema.Null,
527
- ])),
528
- billing: Schema.optional(Schema.Union([
529
- Schema.Struct({
349
+ write: Schema.optional(Schema.Union([Schema.Boolean, Schema.Null]))
350
+ }), Schema.Null])),
351
+ billing: Schema.optional(Schema.Union([Schema.Struct({
530
352
  read: Schema.optional(Schema.Union([Schema.Boolean, Schema.Null])),
531
- write: Schema.optional(Schema.Union([Schema.Boolean, Schema.Null])),
532
- }),
533
- Schema.Null,
534
- ])),
535
- cachePurge: Schema.optional(Schema.Union([
536
- Schema.Struct({
353
+ write: Schema.optional(Schema.Union([Schema.Boolean, Schema.Null]))
354
+ }), Schema.Null])),
355
+ cachePurge: Schema.optional(Schema.Union([Schema.Struct({
537
356
  read: Schema.optional(Schema.Union([Schema.Boolean, Schema.Null])),
538
- write: Schema.optional(Schema.Union([Schema.Boolean, Schema.Null])),
539
- }),
540
- Schema.Null,
541
- ])),
542
- dns: Schema.optional(Schema.Union([
543
- Schema.Struct({
357
+ write: Schema.optional(Schema.Union([Schema.Boolean, Schema.Null]))
358
+ }), Schema.Null])),
359
+ dns: Schema.optional(Schema.Union([Schema.Struct({
544
360
  read: Schema.optional(Schema.Union([Schema.Boolean, Schema.Null])),
545
- write: Schema.optional(Schema.Union([Schema.Boolean, Schema.Null])),
546
- }),
547
- Schema.Null,
548
- ])),
549
- dnsRecords: Schema.optional(Schema.Union([
550
- Schema.Struct({
361
+ write: Schema.optional(Schema.Union([Schema.Boolean, Schema.Null]))
362
+ }), Schema.Null])),
363
+ dnsRecords: Schema.optional(Schema.Union([Schema.Struct({
551
364
  read: Schema.optional(Schema.Union([Schema.Boolean, Schema.Null])),
552
- write: Schema.optional(Schema.Union([Schema.Boolean, Schema.Null])),
553
- }),
554
- Schema.Null,
555
- ])),
556
- lb: Schema.optional(Schema.Union([
557
- Schema.Struct({
365
+ write: Schema.optional(Schema.Union([Schema.Boolean, Schema.Null]))
366
+ }), Schema.Null])),
367
+ lb: Schema.optional(Schema.Union([Schema.Struct({
558
368
  read: Schema.optional(Schema.Union([Schema.Boolean, Schema.Null])),
559
- write: Schema.optional(Schema.Union([Schema.Boolean, Schema.Null])),
560
- }),
561
- Schema.Null,
562
- ])),
563
- logs: Schema.optional(Schema.Union([
564
- Schema.Struct({
369
+ write: Schema.optional(Schema.Union([Schema.Boolean, Schema.Null]))
370
+ }), Schema.Null])),
371
+ logs: Schema.optional(Schema.Union([Schema.Struct({
565
372
  read: Schema.optional(Schema.Union([Schema.Boolean, Schema.Null])),
566
- write: Schema.optional(Schema.Union([Schema.Boolean, Schema.Null])),
567
- }),
568
- Schema.Null,
569
- ])),
570
- organization: Schema.optional(Schema.Union([
571
- Schema.Struct({
373
+ write: Schema.optional(Schema.Union([Schema.Boolean, Schema.Null]))
374
+ }), Schema.Null])),
375
+ organization: Schema.optional(Schema.Union([Schema.Struct({
572
376
  read: Schema.optional(Schema.Union([Schema.Boolean, Schema.Null])),
573
- write: Schema.optional(Schema.Union([Schema.Boolean, Schema.Null])),
574
- }),
575
- Schema.Null,
576
- ])),
577
- ssl: Schema.optional(Schema.Union([
578
- Schema.Struct({
377
+ write: Schema.optional(Schema.Union([Schema.Boolean, Schema.Null]))
378
+ }), Schema.Null])),
379
+ ssl: Schema.optional(Schema.Union([Schema.Struct({
579
380
  read: Schema.optional(Schema.Union([Schema.Boolean, Schema.Null])),
580
- write: Schema.optional(Schema.Union([Schema.Boolean, Schema.Null])),
581
- }),
582
- Schema.Null,
583
- ])),
584
- waf: Schema.optional(Schema.Union([
585
- Schema.Struct({
381
+ write: Schema.optional(Schema.Union([Schema.Boolean, Schema.Null]))
382
+ }), Schema.Null])),
383
+ waf: Schema.optional(Schema.Union([Schema.Struct({
586
384
  read: Schema.optional(Schema.Union([Schema.Boolean, Schema.Null])),
587
- write: Schema.optional(Schema.Union([Schema.Boolean, Schema.Null])),
588
- }),
589
- Schema.Null,
590
- ])),
591
- zoneSettings: Schema.optional(Schema.Union([
592
- Schema.Struct({
385
+ write: Schema.optional(Schema.Union([Schema.Boolean, Schema.Null]))
386
+ }), Schema.Null])),
387
+ zoneSettings: Schema.optional(Schema.Union([Schema.Struct({
593
388
  read: Schema.optional(Schema.Union([Schema.Boolean, Schema.Null])),
594
- write: Schema.optional(Schema.Union([Schema.Boolean, Schema.Null])),
595
- }),
596
- Schema.Null,
597
- ])),
598
- zones: Schema.optional(Schema.Union([
599
- Schema.Struct({
389
+ write: Schema.optional(Schema.Union([Schema.Boolean, Schema.Null]))
390
+ }), Schema.Null])),
391
+ zones: Schema.optional(Schema.Union([Schema.Struct({
600
392
  read: Schema.optional(Schema.Union([Schema.Boolean, Schema.Null])),
601
- write: Schema.optional(Schema.Union([Schema.Boolean, Schema.Null])),
602
- }),
603
- Schema.Null,
604
- ])),
605
- }).pipe(Schema.encodeKeys({
606
- analytics: "analytics",
607
- billing: "billing",
608
- cachePurge: "cache_purge",
609
- dns: "dns",
610
- dnsRecords: "dns_records",
611
- lb: "lb",
612
- logs: "logs",
613
- organization: "organization",
614
- ssl: "ssl",
615
- waf: "waf",
616
- zoneSettings: "zone_settings",
617
- zones: "zones",
618
- })),
619
- })),
620
- Schema.Null,
621
- ])),
393
+ write: Schema.optional(Schema.Union([Schema.Boolean, Schema.Null]))
394
+ }), Schema.Null]))
395
+ }).pipe(Schema.encodeKeys({ analytics: "analytics", billing: "billing", cachePurge: "cache_purge", dns: "dns", dnsRecords: "dns_records", lb: "lb", logs: "logs", organization: "organization", ssl: "ssl", waf: "waf", zoneSettings: "zone_settings", zones: "zones" }))
396
+ })), Schema.Null])),
622
397
  status: Schema.optional(Schema.Union([Schema.Literals(["accepted", "pending"]), Schema.Null])),
623
- user: Schema.optional(Schema.Union([
624
- Schema.Struct({
398
+ user: Schema.optional(Schema.Union([Schema.Struct({
625
399
  email: Schema.String,
626
400
  id: Schema.optional(Schema.Union([Schema.String, Schema.Null])),
627
401
  firstName: Schema.optional(Schema.Union([Schema.String, Schema.Null])),
628
402
  lastName: Schema.optional(Schema.Union([Schema.String, Schema.Null])),
629
- twoFactorAuthenticationEnabled: Schema.optional(Schema.Union([Schema.Boolean, Schema.Null])),
630
- }).pipe(Schema.encodeKeys({
631
- email: "email",
632
- id: "id",
633
- firstName: "first_name",
634
- lastName: "last_name",
635
- twoFactorAuthenticationEnabled: "two_factor_authentication_enabled",
636
- })),
637
- Schema.Null,
638
- ])),
403
+ twoFactorAuthenticationEnabled: Schema.optional(Schema.Union([Schema.Boolean, Schema.Null]))
404
+ }).pipe(Schema.encodeKeys({ email: "email", id: "id", firstName: "first_name", lastName: "last_name", twoFactorAuthenticationEnabled: "two_factor_authentication_enabled" })), Schema.Null]))
639
405
  }).pipe(T.ResponsePath("result"));
640
406
  export const getMember = /*@__PURE__*/ /*#__PURE__*/ API.make(() => ({
641
407
  input: GetMemberRequest,
@@ -645,178 +411,94 @@ export const getMember = /*@__PURE__*/ /*#__PURE__*/ API.make(() => ({
645
411
  export const ListMembersRequest = /*@__PURE__*/ /*#__PURE__*/ Schema.Struct({
646
412
  accountId: Schema.String.pipe(T.HttpPath("account_id")),
647
413
  direction: Schema.optional(Schema.Literals(["asc", "desc"])).pipe(T.HttpQuery("direction")),
648
- order: Schema.optional(Schema.Literals([
649
- "user.first_name",
650
- "user.last_name",
651
- "user.email",
652
- "status",
653
- ])).pipe(T.HttpQuery("order")),
654
- status: Schema.optional(Schema.Literals(["accepted", "pending", "rejected"])).pipe(T.HttpQuery("status")),
655
- }).pipe(T.Http({ method: "GET", path: "/accounts/{account_id}/members" }));
414
+ order: Schema.optional(Schema.Literals(["user.first_name", "user.last_name", "user.email", "status"])).pipe(T.HttpQuery("order")),
415
+ status: Schema.optional(Schema.Literals(["accepted", "pending", "rejected"])).pipe(T.HttpQuery("status"))
416
+ })
417
+ .pipe(T.Http({ method: "GET", path: "/accounts/{account_id}/members" }));
656
418
  export const ListMembersResponse = /*@__PURE__*/ /*#__PURE__*/ Schema.Struct({
657
419
  result: Schema.Array(Schema.Struct({
658
420
  id: Schema.optional(Schema.Union([Schema.String, Schema.Null])),
659
421
  email: Schema.optional(Schema.Union([Schema.String, Schema.Null])),
660
- policies: Schema.optional(Schema.Union([
661
- Schema.Array(Schema.Struct({
422
+ policies: Schema.optional(Schema.Union([Schema.Array(Schema.Struct({
662
423
  id: Schema.optional(Schema.Union([Schema.String, Schema.Null])),
663
424
  access: Schema.optional(Schema.Union([Schema.Literals(["allow", "deny"]), Schema.Null])),
664
- permissionGroups: Schema.optional(Schema.Union([
665
- Schema.Array(Schema.Struct({
666
- id: Schema.String,
667
- })),
668
- Schema.Null,
669
- ])),
670
- resourceGroups: Schema.optional(Schema.Union([
671
- Schema.Array(Schema.Struct({
672
- id: Schema.String,
673
- })),
674
- Schema.Null,
675
- ])),
676
- }).pipe(Schema.encodeKeys({
677
- id: "id",
678
- access: "access",
679
- permissionGroups: "permission_groups",
680
- resourceGroups: "resource_groups",
681
- }))),
682
- Schema.Null,
683
- ])),
684
- roles: Schema.optional(Schema.Union([
685
- Schema.Array(Schema.Struct({
425
+ permissionGroups: Schema.optional(Schema.Union([Schema.Array(Schema.Struct({
426
+ id: Schema.String
427
+ })), Schema.Null])),
428
+ resourceGroups: Schema.optional(Schema.Union([Schema.Array(Schema.Struct({
429
+ id: Schema.String
430
+ })), Schema.Null]))
431
+ }).pipe(Schema.encodeKeys({ id: "id", access: "access", permissionGroups: "permission_groups", resourceGroups: "resource_groups" }))), Schema.Null])),
432
+ roles: Schema.optional(Schema.Union([Schema.Array(Schema.Struct({
686
433
  id: Schema.String,
687
434
  description: Schema.String,
688
435
  name: Schema.String,
689
436
  permissions: Schema.Struct({
690
- analytics: Schema.optional(Schema.Union([
691
- Schema.Struct({
437
+ analytics: Schema.optional(Schema.Union([Schema.Struct({
692
438
  read: Schema.optional(Schema.Union([Schema.Boolean, Schema.Null])),
693
- write: Schema.optional(Schema.Union([Schema.Boolean, Schema.Null])),
694
- }),
695
- Schema.Null,
696
- ])),
697
- billing: Schema.optional(Schema.Union([
698
- Schema.Struct({
439
+ write: Schema.optional(Schema.Union([Schema.Boolean, Schema.Null]))
440
+ }), Schema.Null])),
441
+ billing: Schema.optional(Schema.Union([Schema.Struct({
699
442
  read: Schema.optional(Schema.Union([Schema.Boolean, Schema.Null])),
700
- write: Schema.optional(Schema.Union([Schema.Boolean, Schema.Null])),
701
- }),
702
- Schema.Null,
703
- ])),
704
- cachePurge: Schema.optional(Schema.Union([
705
- Schema.Struct({
443
+ write: Schema.optional(Schema.Union([Schema.Boolean, Schema.Null]))
444
+ }), Schema.Null])),
445
+ cachePurge: Schema.optional(Schema.Union([Schema.Struct({
706
446
  read: Schema.optional(Schema.Union([Schema.Boolean, Schema.Null])),
707
- write: Schema.optional(Schema.Union([Schema.Boolean, Schema.Null])),
708
- }),
709
- Schema.Null,
710
- ])),
711
- dns: Schema.optional(Schema.Union([
712
- Schema.Struct({
447
+ write: Schema.optional(Schema.Union([Schema.Boolean, Schema.Null]))
448
+ }), Schema.Null])),
449
+ dns: Schema.optional(Schema.Union([Schema.Struct({
713
450
  read: Schema.optional(Schema.Union([Schema.Boolean, Schema.Null])),
714
- write: Schema.optional(Schema.Union([Schema.Boolean, Schema.Null])),
715
- }),
716
- Schema.Null,
717
- ])),
718
- dnsRecords: Schema.optional(Schema.Union([
719
- Schema.Struct({
451
+ write: Schema.optional(Schema.Union([Schema.Boolean, Schema.Null]))
452
+ }), Schema.Null])),
453
+ dnsRecords: Schema.optional(Schema.Union([Schema.Struct({
720
454
  read: Schema.optional(Schema.Union([Schema.Boolean, Schema.Null])),
721
- write: Schema.optional(Schema.Union([Schema.Boolean, Schema.Null])),
722
- }),
723
- Schema.Null,
724
- ])),
725
- lb: Schema.optional(Schema.Union([
726
- Schema.Struct({
455
+ write: Schema.optional(Schema.Union([Schema.Boolean, Schema.Null]))
456
+ }), Schema.Null])),
457
+ lb: Schema.optional(Schema.Union([Schema.Struct({
727
458
  read: Schema.optional(Schema.Union([Schema.Boolean, Schema.Null])),
728
- write: Schema.optional(Schema.Union([Schema.Boolean, Schema.Null])),
729
- }),
730
- Schema.Null,
731
- ])),
732
- logs: Schema.optional(Schema.Union([
733
- Schema.Struct({
459
+ write: Schema.optional(Schema.Union([Schema.Boolean, Schema.Null]))
460
+ }), Schema.Null])),
461
+ logs: Schema.optional(Schema.Union([Schema.Struct({
734
462
  read: Schema.optional(Schema.Union([Schema.Boolean, Schema.Null])),
735
- write: Schema.optional(Schema.Union([Schema.Boolean, Schema.Null])),
736
- }),
737
- Schema.Null,
738
- ])),
739
- organization: Schema.optional(Schema.Union([
740
- Schema.Struct({
463
+ write: Schema.optional(Schema.Union([Schema.Boolean, Schema.Null]))
464
+ }), Schema.Null])),
465
+ organization: Schema.optional(Schema.Union([Schema.Struct({
741
466
  read: Schema.optional(Schema.Union([Schema.Boolean, Schema.Null])),
742
- write: Schema.optional(Schema.Union([Schema.Boolean, Schema.Null])),
743
- }),
744
- Schema.Null,
745
- ])),
746
- ssl: Schema.optional(Schema.Union([
747
- Schema.Struct({
467
+ write: Schema.optional(Schema.Union([Schema.Boolean, Schema.Null]))
468
+ }), Schema.Null])),
469
+ ssl: Schema.optional(Schema.Union([Schema.Struct({
748
470
  read: Schema.optional(Schema.Union([Schema.Boolean, Schema.Null])),
749
- write: Schema.optional(Schema.Union([Schema.Boolean, Schema.Null])),
750
- }),
751
- Schema.Null,
752
- ])),
753
- waf: Schema.optional(Schema.Union([
754
- Schema.Struct({
471
+ write: Schema.optional(Schema.Union([Schema.Boolean, Schema.Null]))
472
+ }), Schema.Null])),
473
+ waf: Schema.optional(Schema.Union([Schema.Struct({
755
474
  read: Schema.optional(Schema.Union([Schema.Boolean, Schema.Null])),
756
- write: Schema.optional(Schema.Union([Schema.Boolean, Schema.Null])),
757
- }),
758
- Schema.Null,
759
- ])),
760
- zoneSettings: Schema.optional(Schema.Union([
761
- Schema.Struct({
475
+ write: Schema.optional(Schema.Union([Schema.Boolean, Schema.Null]))
476
+ }), Schema.Null])),
477
+ zoneSettings: Schema.optional(Schema.Union([Schema.Struct({
762
478
  read: Schema.optional(Schema.Union([Schema.Boolean, Schema.Null])),
763
- write: Schema.optional(Schema.Union([Schema.Boolean, Schema.Null])),
764
- }),
765
- Schema.Null,
766
- ])),
767
- zones: Schema.optional(Schema.Union([
768
- Schema.Struct({
479
+ write: Schema.optional(Schema.Union([Schema.Boolean, Schema.Null]))
480
+ }), Schema.Null])),
481
+ zones: Schema.optional(Schema.Union([Schema.Struct({
769
482
  read: Schema.optional(Schema.Union([Schema.Boolean, Schema.Null])),
770
- write: Schema.optional(Schema.Union([Schema.Boolean, Schema.Null])),
771
- }),
772
- Schema.Null,
773
- ])),
774
- }).pipe(Schema.encodeKeys({
775
- analytics: "analytics",
776
- billing: "billing",
777
- cachePurge: "cache_purge",
778
- dns: "dns",
779
- dnsRecords: "dns_records",
780
- lb: "lb",
781
- logs: "logs",
782
- organization: "organization",
783
- ssl: "ssl",
784
- waf: "waf",
785
- zoneSettings: "zone_settings",
786
- zones: "zones",
787
- })),
788
- })),
789
- Schema.Null,
790
- ])),
483
+ write: Schema.optional(Schema.Union([Schema.Boolean, Schema.Null]))
484
+ }), Schema.Null]))
485
+ }).pipe(Schema.encodeKeys({ analytics: "analytics", billing: "billing", cachePurge: "cache_purge", dns: "dns", dnsRecords: "dns_records", lb: "lb", logs: "logs", organization: "organization", ssl: "ssl", waf: "waf", zoneSettings: "zone_settings", zones: "zones" }))
486
+ })), Schema.Null])),
791
487
  status: Schema.optional(Schema.Union([Schema.Literals(["accepted", "pending"]), Schema.Null])),
792
- user: Schema.optional(Schema.Union([
793
- Schema.Struct({
488
+ user: Schema.optional(Schema.Union([Schema.Struct({
794
489
  email: Schema.String,
795
490
  id: Schema.optional(Schema.Union([Schema.String, Schema.Null])),
796
491
  firstName: Schema.optional(Schema.Union([Schema.String, Schema.Null])),
797
492
  lastName: Schema.optional(Schema.Union([Schema.String, Schema.Null])),
798
- twoFactorAuthenticationEnabled: Schema.optional(Schema.Union([Schema.Boolean, Schema.Null])),
799
- }).pipe(Schema.encodeKeys({
800
- email: "email",
801
- id: "id",
802
- firstName: "first_name",
803
- lastName: "last_name",
804
- twoFactorAuthenticationEnabled: "two_factor_authentication_enabled",
805
- })),
806
- Schema.Null,
807
- ])),
493
+ twoFactorAuthenticationEnabled: Schema.optional(Schema.Union([Schema.Boolean, Schema.Null]))
494
+ }).pipe(Schema.encodeKeys({ email: "email", id: "id", firstName: "first_name", lastName: "last_name", twoFactorAuthenticationEnabled: "two_factor_authentication_enabled" })), Schema.Null]))
808
495
  })),
809
496
  resultInfo: Schema.Struct({
810
497
  count: Schema.optional(Schema.Union([Schema.Number, Schema.Null])),
811
498
  page: Schema.optional(Schema.Union([Schema.Number, Schema.Null])),
812
499
  perPage: Schema.optional(Schema.Union([Schema.Number, Schema.Null])),
813
- totalCount: Schema.optional(Schema.Union([Schema.Number, Schema.Null])),
814
- }).pipe(Schema.encodeKeys({
815
- count: "count",
816
- page: "page",
817
- perPage: "per_page",
818
- totalCount: "total_count",
819
- })),
500
+ totalCount: Schema.optional(Schema.Union([Schema.Number, Schema.Null]))
501
+ }).pipe(Schema.encodeKeys({ count: "count", page: "page", perPage: "per_page", totalCount: "total_count" }))
820
502
  }).pipe(Schema.encodeKeys({ result: "result", resultInfo: "result_info" }));
821
503
  export const listMembers = /*@__PURE__*/ /*#__PURE__*/ API.makePaginated(() => ({
822
504
  input: ListMembersRequest,
@@ -834,159 +516,85 @@ export const CreateMemberRequest = /*@__PURE__*/ /*#__PURE__*/ Schema.Struct({
834
516
  accountId: Schema.String.pipe(T.HttpPath("account_id")),
835
517
  email: Schema.String,
836
518
  roles: Schema.Array(Schema.String),
837
- status: Schema.optional(Schema.Literals(["accepted", "pending"])),
838
- }).pipe(T.Http({ method: "POST", path: "/accounts/{account_id}/members" }));
519
+ status: Schema.optional(Schema.Literals(["accepted", "pending"]))
520
+ })
521
+ .pipe(T.Http({ method: "POST", path: "/accounts/{account_id}/members" }));
839
522
  export const CreateMemberResponse = /*@__PURE__*/ /*#__PURE__*/ Schema.Struct({
840
523
  id: Schema.optional(Schema.Union([Schema.String, Schema.Null])),
841
524
  email: Schema.optional(Schema.Union([Schema.String, Schema.Null])),
842
- policies: Schema.optional(Schema.Union([
843
- Schema.Array(Schema.Struct({
525
+ policies: Schema.optional(Schema.Union([Schema.Array(Schema.Struct({
844
526
  id: Schema.optional(Schema.Union([Schema.String, Schema.Null])),
845
527
  access: Schema.optional(Schema.Union([Schema.Literals(["allow", "deny"]), Schema.Null])),
846
- permissionGroups: Schema.optional(Schema.Union([
847
- Schema.Array(Schema.Struct({
848
- id: Schema.String,
849
- })),
850
- Schema.Null,
851
- ])),
852
- resourceGroups: Schema.optional(Schema.Union([
853
- Schema.Array(Schema.Struct({
854
- id: Schema.String,
855
- })),
856
- Schema.Null,
857
- ])),
858
- }).pipe(Schema.encodeKeys({
859
- id: "id",
860
- access: "access",
861
- permissionGroups: "permission_groups",
862
- resourceGroups: "resource_groups",
863
- }))),
864
- Schema.Null,
865
- ])),
866
- roles: Schema.optional(Schema.Union([
867
- Schema.Array(Schema.Struct({
528
+ permissionGroups: Schema.optional(Schema.Union([Schema.Array(Schema.Struct({
529
+ id: Schema.String
530
+ })), Schema.Null])),
531
+ resourceGroups: Schema.optional(Schema.Union([Schema.Array(Schema.Struct({
532
+ id: Schema.String
533
+ })), Schema.Null]))
534
+ }).pipe(Schema.encodeKeys({ id: "id", access: "access", permissionGroups: "permission_groups", resourceGroups: "resource_groups" }))), Schema.Null])),
535
+ roles: Schema.optional(Schema.Union([Schema.Array(Schema.Struct({
868
536
  id: Schema.String,
869
537
  description: Schema.String,
870
538
  name: Schema.String,
871
539
  permissions: Schema.Struct({
872
- analytics: Schema.optional(Schema.Union([
873
- Schema.Struct({
540
+ analytics: Schema.optional(Schema.Union([Schema.Struct({
874
541
  read: Schema.optional(Schema.Union([Schema.Boolean, Schema.Null])),
875
- write: Schema.optional(Schema.Union([Schema.Boolean, Schema.Null])),
876
- }),
877
- Schema.Null,
878
- ])),
879
- billing: Schema.optional(Schema.Union([
880
- Schema.Struct({
542
+ write: Schema.optional(Schema.Union([Schema.Boolean, Schema.Null]))
543
+ }), Schema.Null])),
544
+ billing: Schema.optional(Schema.Union([Schema.Struct({
881
545
  read: Schema.optional(Schema.Union([Schema.Boolean, Schema.Null])),
882
- write: Schema.optional(Schema.Union([Schema.Boolean, Schema.Null])),
883
- }),
884
- Schema.Null,
885
- ])),
886
- cachePurge: Schema.optional(Schema.Union([
887
- Schema.Struct({
546
+ write: Schema.optional(Schema.Union([Schema.Boolean, Schema.Null]))
547
+ }), Schema.Null])),
548
+ cachePurge: Schema.optional(Schema.Union([Schema.Struct({
888
549
  read: Schema.optional(Schema.Union([Schema.Boolean, Schema.Null])),
889
- write: Schema.optional(Schema.Union([Schema.Boolean, Schema.Null])),
890
- }),
891
- Schema.Null,
892
- ])),
893
- dns: Schema.optional(Schema.Union([
894
- Schema.Struct({
550
+ write: Schema.optional(Schema.Union([Schema.Boolean, Schema.Null]))
551
+ }), Schema.Null])),
552
+ dns: Schema.optional(Schema.Union([Schema.Struct({
895
553
  read: Schema.optional(Schema.Union([Schema.Boolean, Schema.Null])),
896
- write: Schema.optional(Schema.Union([Schema.Boolean, Schema.Null])),
897
- }),
898
- Schema.Null,
899
- ])),
900
- dnsRecords: Schema.optional(Schema.Union([
901
- Schema.Struct({
554
+ write: Schema.optional(Schema.Union([Schema.Boolean, Schema.Null]))
555
+ }), Schema.Null])),
556
+ dnsRecords: Schema.optional(Schema.Union([Schema.Struct({
902
557
  read: Schema.optional(Schema.Union([Schema.Boolean, Schema.Null])),
903
- write: Schema.optional(Schema.Union([Schema.Boolean, Schema.Null])),
904
- }),
905
- Schema.Null,
906
- ])),
907
- lb: Schema.optional(Schema.Union([
908
- Schema.Struct({
558
+ write: Schema.optional(Schema.Union([Schema.Boolean, Schema.Null]))
559
+ }), Schema.Null])),
560
+ lb: Schema.optional(Schema.Union([Schema.Struct({
909
561
  read: Schema.optional(Schema.Union([Schema.Boolean, Schema.Null])),
910
- write: Schema.optional(Schema.Union([Schema.Boolean, Schema.Null])),
911
- }),
912
- Schema.Null,
913
- ])),
914
- logs: Schema.optional(Schema.Union([
915
- Schema.Struct({
562
+ write: Schema.optional(Schema.Union([Schema.Boolean, Schema.Null]))
563
+ }), Schema.Null])),
564
+ logs: Schema.optional(Schema.Union([Schema.Struct({
916
565
  read: Schema.optional(Schema.Union([Schema.Boolean, Schema.Null])),
917
- write: Schema.optional(Schema.Union([Schema.Boolean, Schema.Null])),
918
- }),
919
- Schema.Null,
920
- ])),
921
- organization: Schema.optional(Schema.Union([
922
- Schema.Struct({
566
+ write: Schema.optional(Schema.Union([Schema.Boolean, Schema.Null]))
567
+ }), Schema.Null])),
568
+ organization: Schema.optional(Schema.Union([Schema.Struct({
923
569
  read: Schema.optional(Schema.Union([Schema.Boolean, Schema.Null])),
924
- write: Schema.optional(Schema.Union([Schema.Boolean, Schema.Null])),
925
- }),
926
- Schema.Null,
927
- ])),
928
- ssl: Schema.optional(Schema.Union([
929
- Schema.Struct({
570
+ write: Schema.optional(Schema.Union([Schema.Boolean, Schema.Null]))
571
+ }), Schema.Null])),
572
+ ssl: Schema.optional(Schema.Union([Schema.Struct({
930
573
  read: Schema.optional(Schema.Union([Schema.Boolean, Schema.Null])),
931
- write: Schema.optional(Schema.Union([Schema.Boolean, Schema.Null])),
932
- }),
933
- Schema.Null,
934
- ])),
935
- waf: Schema.optional(Schema.Union([
936
- Schema.Struct({
574
+ write: Schema.optional(Schema.Union([Schema.Boolean, Schema.Null]))
575
+ }), Schema.Null])),
576
+ waf: Schema.optional(Schema.Union([Schema.Struct({
937
577
  read: Schema.optional(Schema.Union([Schema.Boolean, Schema.Null])),
938
- write: Schema.optional(Schema.Union([Schema.Boolean, Schema.Null])),
939
- }),
940
- Schema.Null,
941
- ])),
942
- zoneSettings: Schema.optional(Schema.Union([
943
- Schema.Struct({
578
+ write: Schema.optional(Schema.Union([Schema.Boolean, Schema.Null]))
579
+ }), Schema.Null])),
580
+ zoneSettings: Schema.optional(Schema.Union([Schema.Struct({
944
581
  read: Schema.optional(Schema.Union([Schema.Boolean, Schema.Null])),
945
- write: Schema.optional(Schema.Union([Schema.Boolean, Schema.Null])),
946
- }),
947
- Schema.Null,
948
- ])),
949
- zones: Schema.optional(Schema.Union([
950
- Schema.Struct({
582
+ write: Schema.optional(Schema.Union([Schema.Boolean, Schema.Null]))
583
+ }), Schema.Null])),
584
+ zones: Schema.optional(Schema.Union([Schema.Struct({
951
585
  read: Schema.optional(Schema.Union([Schema.Boolean, Schema.Null])),
952
- write: Schema.optional(Schema.Union([Schema.Boolean, Schema.Null])),
953
- }),
954
- Schema.Null,
955
- ])),
956
- }).pipe(Schema.encodeKeys({
957
- analytics: "analytics",
958
- billing: "billing",
959
- cachePurge: "cache_purge",
960
- dns: "dns",
961
- dnsRecords: "dns_records",
962
- lb: "lb",
963
- logs: "logs",
964
- organization: "organization",
965
- ssl: "ssl",
966
- waf: "waf",
967
- zoneSettings: "zone_settings",
968
- zones: "zones",
969
- })),
970
- })),
971
- Schema.Null,
972
- ])),
586
+ write: Schema.optional(Schema.Union([Schema.Boolean, Schema.Null]))
587
+ }), Schema.Null]))
588
+ }).pipe(Schema.encodeKeys({ analytics: "analytics", billing: "billing", cachePurge: "cache_purge", dns: "dns", dnsRecords: "dns_records", lb: "lb", logs: "logs", organization: "organization", ssl: "ssl", waf: "waf", zoneSettings: "zone_settings", zones: "zones" }))
589
+ })), Schema.Null])),
973
590
  status: Schema.optional(Schema.Union([Schema.Literals(["accepted", "pending"]), Schema.Null])),
974
- user: Schema.optional(Schema.Union([
975
- Schema.Struct({
591
+ user: Schema.optional(Schema.Union([Schema.Struct({
976
592
  email: Schema.String,
977
593
  id: Schema.optional(Schema.Union([Schema.String, Schema.Null])),
978
594
  firstName: Schema.optional(Schema.Union([Schema.String, Schema.Null])),
979
595
  lastName: Schema.optional(Schema.Union([Schema.String, Schema.Null])),
980
- twoFactorAuthenticationEnabled: Schema.optional(Schema.Union([Schema.Boolean, Schema.Null])),
981
- }).pipe(Schema.encodeKeys({
982
- email: "email",
983
- id: "id",
984
- firstName: "first_name",
985
- lastName: "last_name",
986
- twoFactorAuthenticationEnabled: "two_factor_authentication_enabled",
987
- })),
988
- Schema.Null,
989
- ])),
596
+ twoFactorAuthenticationEnabled: Schema.optional(Schema.Union([Schema.Boolean, Schema.Null]))
597
+ }).pipe(Schema.encodeKeys({ email: "email", id: "id", firstName: "first_name", lastName: "last_name", twoFactorAuthenticationEnabled: "two_factor_authentication_enabled" })), Schema.Null]))
990
598
  }).pipe(T.ResponsePath("result"));
991
599
  export const createMember = /*@__PURE__*/ /*#__PURE__*/ API.make(() => ({
992
600
  input: CreateMemberRequest,
@@ -997,160 +605,86 @@ export const UpdateMemberRequest = /*@__PURE__*/ /*#__PURE__*/ Schema.Struct({
997
605
  memberId: Schema.String.pipe(T.HttpPath("memberId")),
998
606
  accountId: Schema.String.pipe(T.HttpPath("account_id")),
999
607
  roles: Schema.optional(Schema.Array(Schema.Struct({
1000
- id: Schema.String,
1001
- }))),
1002
- }).pipe(T.Http({ method: "PUT", path: "/accounts/{account_id}/members/{memberId}" }));
608
+ id: Schema.String
609
+ })))
610
+ })
611
+ .pipe(T.Http({ method: "PUT", path: "/accounts/{account_id}/members/{memberId}" }));
1003
612
  export const UpdateMemberResponse = /*@__PURE__*/ /*#__PURE__*/ Schema.Struct({
1004
613
  id: Schema.optional(Schema.Union([Schema.String, Schema.Null])),
1005
614
  email: Schema.optional(Schema.Union([Schema.String, Schema.Null])),
1006
- policies: Schema.optional(Schema.Union([
1007
- Schema.Array(Schema.Struct({
615
+ policies: Schema.optional(Schema.Union([Schema.Array(Schema.Struct({
1008
616
  id: Schema.optional(Schema.Union([Schema.String, Schema.Null])),
1009
617
  access: Schema.optional(Schema.Union([Schema.Literals(["allow", "deny"]), Schema.Null])),
1010
- permissionGroups: Schema.optional(Schema.Union([
1011
- Schema.Array(Schema.Struct({
1012
- id: Schema.String,
1013
- })),
1014
- Schema.Null,
1015
- ])),
1016
- resourceGroups: Schema.optional(Schema.Union([
1017
- Schema.Array(Schema.Struct({
1018
- id: Schema.String,
1019
- })),
1020
- Schema.Null,
1021
- ])),
1022
- }).pipe(Schema.encodeKeys({
1023
- id: "id",
1024
- access: "access",
1025
- permissionGroups: "permission_groups",
1026
- resourceGroups: "resource_groups",
1027
- }))),
1028
- Schema.Null,
1029
- ])),
1030
- roles: Schema.optional(Schema.Union([
1031
- Schema.Array(Schema.Struct({
618
+ permissionGroups: Schema.optional(Schema.Union([Schema.Array(Schema.Struct({
619
+ id: Schema.String
620
+ })), Schema.Null])),
621
+ resourceGroups: Schema.optional(Schema.Union([Schema.Array(Schema.Struct({
622
+ id: Schema.String
623
+ })), Schema.Null]))
624
+ }).pipe(Schema.encodeKeys({ id: "id", access: "access", permissionGroups: "permission_groups", resourceGroups: "resource_groups" }))), Schema.Null])),
625
+ roles: Schema.optional(Schema.Union([Schema.Array(Schema.Struct({
1032
626
  id: Schema.String,
1033
627
  description: Schema.String,
1034
628
  name: Schema.String,
1035
629
  permissions: Schema.Struct({
1036
- analytics: Schema.optional(Schema.Union([
1037
- Schema.Struct({
630
+ analytics: Schema.optional(Schema.Union([Schema.Struct({
1038
631
  read: Schema.optional(Schema.Union([Schema.Boolean, Schema.Null])),
1039
- write: Schema.optional(Schema.Union([Schema.Boolean, Schema.Null])),
1040
- }),
1041
- Schema.Null,
1042
- ])),
1043
- billing: Schema.optional(Schema.Union([
1044
- Schema.Struct({
632
+ write: Schema.optional(Schema.Union([Schema.Boolean, Schema.Null]))
633
+ }), Schema.Null])),
634
+ billing: Schema.optional(Schema.Union([Schema.Struct({
1045
635
  read: Schema.optional(Schema.Union([Schema.Boolean, Schema.Null])),
1046
- write: Schema.optional(Schema.Union([Schema.Boolean, Schema.Null])),
1047
- }),
1048
- Schema.Null,
1049
- ])),
1050
- cachePurge: Schema.optional(Schema.Union([
1051
- Schema.Struct({
636
+ write: Schema.optional(Schema.Union([Schema.Boolean, Schema.Null]))
637
+ }), Schema.Null])),
638
+ cachePurge: Schema.optional(Schema.Union([Schema.Struct({
1052
639
  read: Schema.optional(Schema.Union([Schema.Boolean, Schema.Null])),
1053
- write: Schema.optional(Schema.Union([Schema.Boolean, Schema.Null])),
1054
- }),
1055
- Schema.Null,
1056
- ])),
1057
- dns: Schema.optional(Schema.Union([
1058
- Schema.Struct({
640
+ write: Schema.optional(Schema.Union([Schema.Boolean, Schema.Null]))
641
+ }), Schema.Null])),
642
+ dns: Schema.optional(Schema.Union([Schema.Struct({
1059
643
  read: Schema.optional(Schema.Union([Schema.Boolean, Schema.Null])),
1060
- write: Schema.optional(Schema.Union([Schema.Boolean, Schema.Null])),
1061
- }),
1062
- Schema.Null,
1063
- ])),
1064
- dnsRecords: Schema.optional(Schema.Union([
1065
- Schema.Struct({
644
+ write: Schema.optional(Schema.Union([Schema.Boolean, Schema.Null]))
645
+ }), Schema.Null])),
646
+ dnsRecords: Schema.optional(Schema.Union([Schema.Struct({
1066
647
  read: Schema.optional(Schema.Union([Schema.Boolean, Schema.Null])),
1067
- write: Schema.optional(Schema.Union([Schema.Boolean, Schema.Null])),
1068
- }),
1069
- Schema.Null,
1070
- ])),
1071
- lb: Schema.optional(Schema.Union([
1072
- Schema.Struct({
648
+ write: Schema.optional(Schema.Union([Schema.Boolean, Schema.Null]))
649
+ }), Schema.Null])),
650
+ lb: Schema.optional(Schema.Union([Schema.Struct({
1073
651
  read: Schema.optional(Schema.Union([Schema.Boolean, Schema.Null])),
1074
- write: Schema.optional(Schema.Union([Schema.Boolean, Schema.Null])),
1075
- }),
1076
- Schema.Null,
1077
- ])),
1078
- logs: Schema.optional(Schema.Union([
1079
- Schema.Struct({
652
+ write: Schema.optional(Schema.Union([Schema.Boolean, Schema.Null]))
653
+ }), Schema.Null])),
654
+ logs: Schema.optional(Schema.Union([Schema.Struct({
1080
655
  read: Schema.optional(Schema.Union([Schema.Boolean, Schema.Null])),
1081
- write: Schema.optional(Schema.Union([Schema.Boolean, Schema.Null])),
1082
- }),
1083
- Schema.Null,
1084
- ])),
1085
- organization: Schema.optional(Schema.Union([
1086
- Schema.Struct({
656
+ write: Schema.optional(Schema.Union([Schema.Boolean, Schema.Null]))
657
+ }), Schema.Null])),
658
+ organization: Schema.optional(Schema.Union([Schema.Struct({
1087
659
  read: Schema.optional(Schema.Union([Schema.Boolean, Schema.Null])),
1088
- write: Schema.optional(Schema.Union([Schema.Boolean, Schema.Null])),
1089
- }),
1090
- Schema.Null,
1091
- ])),
1092
- ssl: Schema.optional(Schema.Union([
1093
- Schema.Struct({
660
+ write: Schema.optional(Schema.Union([Schema.Boolean, Schema.Null]))
661
+ }), Schema.Null])),
662
+ ssl: Schema.optional(Schema.Union([Schema.Struct({
1094
663
  read: Schema.optional(Schema.Union([Schema.Boolean, Schema.Null])),
1095
- write: Schema.optional(Schema.Union([Schema.Boolean, Schema.Null])),
1096
- }),
1097
- Schema.Null,
1098
- ])),
1099
- waf: Schema.optional(Schema.Union([
1100
- Schema.Struct({
664
+ write: Schema.optional(Schema.Union([Schema.Boolean, Schema.Null]))
665
+ }), Schema.Null])),
666
+ waf: Schema.optional(Schema.Union([Schema.Struct({
1101
667
  read: Schema.optional(Schema.Union([Schema.Boolean, Schema.Null])),
1102
- write: Schema.optional(Schema.Union([Schema.Boolean, Schema.Null])),
1103
- }),
1104
- Schema.Null,
1105
- ])),
1106
- zoneSettings: Schema.optional(Schema.Union([
1107
- Schema.Struct({
668
+ write: Schema.optional(Schema.Union([Schema.Boolean, Schema.Null]))
669
+ }), Schema.Null])),
670
+ zoneSettings: Schema.optional(Schema.Union([Schema.Struct({
1108
671
  read: Schema.optional(Schema.Union([Schema.Boolean, Schema.Null])),
1109
- write: Schema.optional(Schema.Union([Schema.Boolean, Schema.Null])),
1110
- }),
1111
- Schema.Null,
1112
- ])),
1113
- zones: Schema.optional(Schema.Union([
1114
- Schema.Struct({
672
+ write: Schema.optional(Schema.Union([Schema.Boolean, Schema.Null]))
673
+ }), Schema.Null])),
674
+ zones: Schema.optional(Schema.Union([Schema.Struct({
1115
675
  read: Schema.optional(Schema.Union([Schema.Boolean, Schema.Null])),
1116
- write: Schema.optional(Schema.Union([Schema.Boolean, Schema.Null])),
1117
- }),
1118
- Schema.Null,
1119
- ])),
1120
- }).pipe(Schema.encodeKeys({
1121
- analytics: "analytics",
1122
- billing: "billing",
1123
- cachePurge: "cache_purge",
1124
- dns: "dns",
1125
- dnsRecords: "dns_records",
1126
- lb: "lb",
1127
- logs: "logs",
1128
- organization: "organization",
1129
- ssl: "ssl",
1130
- waf: "waf",
1131
- zoneSettings: "zone_settings",
1132
- zones: "zones",
1133
- })),
1134
- })),
1135
- Schema.Null,
1136
- ])),
676
+ write: Schema.optional(Schema.Union([Schema.Boolean, Schema.Null]))
677
+ }), Schema.Null]))
678
+ }).pipe(Schema.encodeKeys({ analytics: "analytics", billing: "billing", cachePurge: "cache_purge", dns: "dns", dnsRecords: "dns_records", lb: "lb", logs: "logs", organization: "organization", ssl: "ssl", waf: "waf", zoneSettings: "zone_settings", zones: "zones" }))
679
+ })), Schema.Null])),
1137
680
  status: Schema.optional(Schema.Union([Schema.Literals(["accepted", "pending"]), Schema.Null])),
1138
- user: Schema.optional(Schema.Union([
1139
- Schema.Struct({
681
+ user: Schema.optional(Schema.Union([Schema.Struct({
1140
682
  email: Schema.String,
1141
683
  id: Schema.optional(Schema.Union([Schema.String, Schema.Null])),
1142
684
  firstName: Schema.optional(Schema.Union([Schema.String, Schema.Null])),
1143
685
  lastName: Schema.optional(Schema.Union([Schema.String, Schema.Null])),
1144
- twoFactorAuthenticationEnabled: Schema.optional(Schema.Union([Schema.Boolean, Schema.Null])),
1145
- }).pipe(Schema.encodeKeys({
1146
- email: "email",
1147
- id: "id",
1148
- firstName: "first_name",
1149
- lastName: "last_name",
1150
- twoFactorAuthenticationEnabled: "two_factor_authentication_enabled",
1151
- })),
1152
- Schema.Null,
1153
- ])),
686
+ twoFactorAuthenticationEnabled: Schema.optional(Schema.Union([Schema.Boolean, Schema.Null]))
687
+ }).pipe(Schema.encodeKeys({ email: "email", id: "id", firstName: "first_name", lastName: "last_name", twoFactorAuthenticationEnabled: "two_factor_authentication_enabled" })), Schema.Null]))
1154
688
  }).pipe(T.ResponsePath("result"));
1155
689
  export const updateMember = /*@__PURE__*/ /*#__PURE__*/ API.make(() => ({
1156
690
  input: UpdateMemberRequest,
@@ -1159,13 +693,11 @@ export const updateMember = /*@__PURE__*/ /*#__PURE__*/ API.make(() => ({
1159
693
  }));
1160
694
  export const DeleteMemberRequest = /*@__PURE__*/ /*#__PURE__*/ Schema.Struct({
1161
695
  memberId: Schema.String.pipe(T.HttpPath("memberId")),
1162
- accountId: Schema.String.pipe(T.HttpPath("account_id")),
1163
- }).pipe(T.Http({
1164
- method: "DELETE",
1165
- path: "/accounts/{account_id}/members/{memberId}",
1166
- }));
696
+ accountId: Schema.String.pipe(T.HttpPath("account_id"))
697
+ })
698
+ .pipe(T.Http({ method: "DELETE", path: "/accounts/{account_id}/members/{memberId}" }));
1167
699
  export const DeleteMemberResponse = /*@__PURE__*/ /*#__PURE__*/ Schema.Struct({
1168
- id: Schema.String,
700
+ id: Schema.String
1169
701
  }).pipe(T.ResponsePath("result"));
1170
702
  export const deleteMember = /*@__PURE__*/ /*#__PURE__*/ API.make(() => ({
1171
703
  input: DeleteMemberRequest,
@@ -1174,111 +706,63 @@ export const deleteMember = /*@__PURE__*/ /*#__PURE__*/ API.make(() => ({
1174
706
  }));
1175
707
  export const GetRoleRequest = /*@__PURE__*/ /*#__PURE__*/ Schema.Struct({
1176
708
  roleId: Schema.String.pipe(T.HttpPath("roleId")),
1177
- accountId: Schema.String.pipe(T.HttpPath("account_id")),
1178
- }).pipe(T.Http({ method: "GET", path: "/accounts/{account_id}/roles/{roleId}" }));
709
+ accountId: Schema.String.pipe(T.HttpPath("account_id"))
710
+ })
711
+ .pipe(T.Http({ method: "GET", path: "/accounts/{account_id}/roles/{roleId}" }));
1179
712
  export const GetRoleResponse = /*@__PURE__*/ /*#__PURE__*/ Schema.Struct({
1180
713
  id: Schema.String,
1181
714
  description: Schema.String,
1182
715
  name: Schema.String,
1183
716
  permissions: Schema.Struct({
1184
- analytics: Schema.optional(Schema.Union([
1185
- Schema.Struct({
717
+ analytics: Schema.optional(Schema.Union([Schema.Struct({
1186
718
  read: Schema.optional(Schema.Union([Schema.Boolean, Schema.Null])),
1187
- write: Schema.optional(Schema.Union([Schema.Boolean, Schema.Null])),
1188
- }),
1189
- Schema.Null,
1190
- ])),
1191
- billing: Schema.optional(Schema.Union([
1192
- Schema.Struct({
719
+ write: Schema.optional(Schema.Union([Schema.Boolean, Schema.Null]))
720
+ }), Schema.Null])),
721
+ billing: Schema.optional(Schema.Union([Schema.Struct({
1193
722
  read: Schema.optional(Schema.Union([Schema.Boolean, Schema.Null])),
1194
- write: Schema.optional(Schema.Union([Schema.Boolean, Schema.Null])),
1195
- }),
1196
- Schema.Null,
1197
- ])),
1198
- cachePurge: Schema.optional(Schema.Union([
1199
- Schema.Struct({
723
+ write: Schema.optional(Schema.Union([Schema.Boolean, Schema.Null]))
724
+ }), Schema.Null])),
725
+ cachePurge: Schema.optional(Schema.Union([Schema.Struct({
1200
726
  read: Schema.optional(Schema.Union([Schema.Boolean, Schema.Null])),
1201
- write: Schema.optional(Schema.Union([Schema.Boolean, Schema.Null])),
1202
- }),
1203
- Schema.Null,
1204
- ])),
1205
- dns: Schema.optional(Schema.Union([
1206
- Schema.Struct({
727
+ write: Schema.optional(Schema.Union([Schema.Boolean, Schema.Null]))
728
+ }), Schema.Null])),
729
+ dns: Schema.optional(Schema.Union([Schema.Struct({
1207
730
  read: Schema.optional(Schema.Union([Schema.Boolean, Schema.Null])),
1208
- write: Schema.optional(Schema.Union([Schema.Boolean, Schema.Null])),
1209
- }),
1210
- Schema.Null,
1211
- ])),
1212
- dnsRecords: Schema.optional(Schema.Union([
1213
- Schema.Struct({
731
+ write: Schema.optional(Schema.Union([Schema.Boolean, Schema.Null]))
732
+ }), Schema.Null])),
733
+ dnsRecords: Schema.optional(Schema.Union([Schema.Struct({
1214
734
  read: Schema.optional(Schema.Union([Schema.Boolean, Schema.Null])),
1215
- write: Schema.optional(Schema.Union([Schema.Boolean, Schema.Null])),
1216
- }),
1217
- Schema.Null,
1218
- ])),
1219
- lb: Schema.optional(Schema.Union([
1220
- Schema.Struct({
735
+ write: Schema.optional(Schema.Union([Schema.Boolean, Schema.Null]))
736
+ }), Schema.Null])),
737
+ lb: Schema.optional(Schema.Union([Schema.Struct({
1221
738
  read: Schema.optional(Schema.Union([Schema.Boolean, Schema.Null])),
1222
- write: Schema.optional(Schema.Union([Schema.Boolean, Schema.Null])),
1223
- }),
1224
- Schema.Null,
1225
- ])),
1226
- logs: Schema.optional(Schema.Union([
1227
- Schema.Struct({
739
+ write: Schema.optional(Schema.Union([Schema.Boolean, Schema.Null]))
740
+ }), Schema.Null])),
741
+ logs: Schema.optional(Schema.Union([Schema.Struct({
1228
742
  read: Schema.optional(Schema.Union([Schema.Boolean, Schema.Null])),
1229
- write: Schema.optional(Schema.Union([Schema.Boolean, Schema.Null])),
1230
- }),
1231
- Schema.Null,
1232
- ])),
1233
- organization: Schema.optional(Schema.Union([
1234
- Schema.Struct({
743
+ write: Schema.optional(Schema.Union([Schema.Boolean, Schema.Null]))
744
+ }), Schema.Null])),
745
+ organization: Schema.optional(Schema.Union([Schema.Struct({
1235
746
  read: Schema.optional(Schema.Union([Schema.Boolean, Schema.Null])),
1236
- write: Schema.optional(Schema.Union([Schema.Boolean, Schema.Null])),
1237
- }),
1238
- Schema.Null,
1239
- ])),
1240
- ssl: Schema.optional(Schema.Union([
1241
- Schema.Struct({
747
+ write: Schema.optional(Schema.Union([Schema.Boolean, Schema.Null]))
748
+ }), Schema.Null])),
749
+ ssl: Schema.optional(Schema.Union([Schema.Struct({
1242
750
  read: Schema.optional(Schema.Union([Schema.Boolean, Schema.Null])),
1243
- write: Schema.optional(Schema.Union([Schema.Boolean, Schema.Null])),
1244
- }),
1245
- Schema.Null,
1246
- ])),
1247
- waf: Schema.optional(Schema.Union([
1248
- Schema.Struct({
751
+ write: Schema.optional(Schema.Union([Schema.Boolean, Schema.Null]))
752
+ }), Schema.Null])),
753
+ waf: Schema.optional(Schema.Union([Schema.Struct({
1249
754
  read: Schema.optional(Schema.Union([Schema.Boolean, Schema.Null])),
1250
- write: Schema.optional(Schema.Union([Schema.Boolean, Schema.Null])),
1251
- }),
1252
- Schema.Null,
1253
- ])),
1254
- zoneSettings: Schema.optional(Schema.Union([
1255
- Schema.Struct({
755
+ write: Schema.optional(Schema.Union([Schema.Boolean, Schema.Null]))
756
+ }), Schema.Null])),
757
+ zoneSettings: Schema.optional(Schema.Union([Schema.Struct({
1256
758
  read: Schema.optional(Schema.Union([Schema.Boolean, Schema.Null])),
1257
- write: Schema.optional(Schema.Union([Schema.Boolean, Schema.Null])),
1258
- }),
1259
- Schema.Null,
1260
- ])),
1261
- zones: Schema.optional(Schema.Union([
1262
- Schema.Struct({
759
+ write: Schema.optional(Schema.Union([Schema.Boolean, Schema.Null]))
760
+ }), Schema.Null])),
761
+ zones: Schema.optional(Schema.Union([Schema.Struct({
1263
762
  read: Schema.optional(Schema.Union([Schema.Boolean, Schema.Null])),
1264
- write: Schema.optional(Schema.Union([Schema.Boolean, Schema.Null])),
1265
- }),
1266
- Schema.Null,
1267
- ])),
1268
- }).pipe(Schema.encodeKeys({
1269
- analytics: "analytics",
1270
- billing: "billing",
1271
- cachePurge: "cache_purge",
1272
- dns: "dns",
1273
- dnsRecords: "dns_records",
1274
- lb: "lb",
1275
- logs: "logs",
1276
- organization: "organization",
1277
- ssl: "ssl",
1278
- waf: "waf",
1279
- zoneSettings: "zone_settings",
1280
- zones: "zones",
1281
- })),
763
+ write: Schema.optional(Schema.Union([Schema.Boolean, Schema.Null]))
764
+ }), Schema.Null]))
765
+ }).pipe(Schema.encodeKeys({ analytics: "analytics", billing: "billing", cachePurge: "cache_purge", dns: "dns", dnsRecords: "dns_records", lb: "lb", logs: "logs", organization: "organization", ssl: "ssl", waf: "waf", zoneSettings: "zone_settings", zones: "zones" }))
1282
766
  }).pipe(T.ResponsePath("result"));
1283
767
  export const getRole = /*@__PURE__*/ /*#__PURE__*/ API.make(() => ({
1284
768
  input: GetRoleRequest,
@@ -1286,124 +770,71 @@ export const getRole = /*@__PURE__*/ /*#__PURE__*/ API.make(() => ({
1286
770
  errors: [InvalidRoute],
1287
771
  }));
1288
772
  export const ListRolesRequest = /*@__PURE__*/ /*#__PURE__*/ Schema.Struct({
1289
- accountId: Schema.String.pipe(T.HttpPath("account_id")),
1290
- }).pipe(T.Http({ method: "GET", path: "/accounts/{account_id}/roles" }));
773
+ accountId: Schema.String.pipe(T.HttpPath("account_id"))
774
+ })
775
+ .pipe(T.Http({ method: "GET", path: "/accounts/{account_id}/roles" }));
1291
776
  export const ListRolesResponse = /*@__PURE__*/ /*#__PURE__*/ Schema.Struct({
1292
777
  result: Schema.Array(Schema.Struct({
1293
778
  id: Schema.String,
1294
779
  description: Schema.String,
1295
780
  name: Schema.String,
1296
781
  permissions: Schema.Struct({
1297
- analytics: Schema.optional(Schema.Union([
1298
- Schema.Struct({
782
+ analytics: Schema.optional(Schema.Union([Schema.Struct({
1299
783
  read: Schema.optional(Schema.Union([Schema.Boolean, Schema.Null])),
1300
- write: Schema.optional(Schema.Union([Schema.Boolean, Schema.Null])),
1301
- }),
1302
- Schema.Null,
1303
- ])),
1304
- billing: Schema.optional(Schema.Union([
1305
- Schema.Struct({
784
+ write: Schema.optional(Schema.Union([Schema.Boolean, Schema.Null]))
785
+ }), Schema.Null])),
786
+ billing: Schema.optional(Schema.Union([Schema.Struct({
1306
787
  read: Schema.optional(Schema.Union([Schema.Boolean, Schema.Null])),
1307
- write: Schema.optional(Schema.Union([Schema.Boolean, Schema.Null])),
1308
- }),
1309
- Schema.Null,
1310
- ])),
1311
- cachePurge: Schema.optional(Schema.Union([
1312
- Schema.Struct({
788
+ write: Schema.optional(Schema.Union([Schema.Boolean, Schema.Null]))
789
+ }), Schema.Null])),
790
+ cachePurge: Schema.optional(Schema.Union([Schema.Struct({
1313
791
  read: Schema.optional(Schema.Union([Schema.Boolean, Schema.Null])),
1314
- write: Schema.optional(Schema.Union([Schema.Boolean, Schema.Null])),
1315
- }),
1316
- Schema.Null,
1317
- ])),
1318
- dns: Schema.optional(Schema.Union([
1319
- Schema.Struct({
792
+ write: Schema.optional(Schema.Union([Schema.Boolean, Schema.Null]))
793
+ }), Schema.Null])),
794
+ dns: Schema.optional(Schema.Union([Schema.Struct({
1320
795
  read: Schema.optional(Schema.Union([Schema.Boolean, Schema.Null])),
1321
- write: Schema.optional(Schema.Union([Schema.Boolean, Schema.Null])),
1322
- }),
1323
- Schema.Null,
1324
- ])),
1325
- dnsRecords: Schema.optional(Schema.Union([
1326
- Schema.Struct({
796
+ write: Schema.optional(Schema.Union([Schema.Boolean, Schema.Null]))
797
+ }), Schema.Null])),
798
+ dnsRecords: Schema.optional(Schema.Union([Schema.Struct({
1327
799
  read: Schema.optional(Schema.Union([Schema.Boolean, Schema.Null])),
1328
- write: Schema.optional(Schema.Union([Schema.Boolean, Schema.Null])),
1329
- }),
1330
- Schema.Null,
1331
- ])),
1332
- lb: Schema.optional(Schema.Union([
1333
- Schema.Struct({
800
+ write: Schema.optional(Schema.Union([Schema.Boolean, Schema.Null]))
801
+ }), Schema.Null])),
802
+ lb: Schema.optional(Schema.Union([Schema.Struct({
1334
803
  read: Schema.optional(Schema.Union([Schema.Boolean, Schema.Null])),
1335
- write: Schema.optional(Schema.Union([Schema.Boolean, Schema.Null])),
1336
- }),
1337
- Schema.Null,
1338
- ])),
1339
- logs: Schema.optional(Schema.Union([
1340
- Schema.Struct({
804
+ write: Schema.optional(Schema.Union([Schema.Boolean, Schema.Null]))
805
+ }), Schema.Null])),
806
+ logs: Schema.optional(Schema.Union([Schema.Struct({
1341
807
  read: Schema.optional(Schema.Union([Schema.Boolean, Schema.Null])),
1342
- write: Schema.optional(Schema.Union([Schema.Boolean, Schema.Null])),
1343
- }),
1344
- Schema.Null,
1345
- ])),
1346
- organization: Schema.optional(Schema.Union([
1347
- Schema.Struct({
808
+ write: Schema.optional(Schema.Union([Schema.Boolean, Schema.Null]))
809
+ }), Schema.Null])),
810
+ organization: Schema.optional(Schema.Union([Schema.Struct({
1348
811
  read: Schema.optional(Schema.Union([Schema.Boolean, Schema.Null])),
1349
- write: Schema.optional(Schema.Union([Schema.Boolean, Schema.Null])),
1350
- }),
1351
- Schema.Null,
1352
- ])),
1353
- ssl: Schema.optional(Schema.Union([
1354
- Schema.Struct({
812
+ write: Schema.optional(Schema.Union([Schema.Boolean, Schema.Null]))
813
+ }), Schema.Null])),
814
+ ssl: Schema.optional(Schema.Union([Schema.Struct({
1355
815
  read: Schema.optional(Schema.Union([Schema.Boolean, Schema.Null])),
1356
- write: Schema.optional(Schema.Union([Schema.Boolean, Schema.Null])),
1357
- }),
1358
- Schema.Null,
1359
- ])),
1360
- waf: Schema.optional(Schema.Union([
1361
- Schema.Struct({
816
+ write: Schema.optional(Schema.Union([Schema.Boolean, Schema.Null]))
817
+ }), Schema.Null])),
818
+ waf: Schema.optional(Schema.Union([Schema.Struct({
1362
819
  read: Schema.optional(Schema.Union([Schema.Boolean, Schema.Null])),
1363
- write: Schema.optional(Schema.Union([Schema.Boolean, Schema.Null])),
1364
- }),
1365
- Schema.Null,
1366
- ])),
1367
- zoneSettings: Schema.optional(Schema.Union([
1368
- Schema.Struct({
820
+ write: Schema.optional(Schema.Union([Schema.Boolean, Schema.Null]))
821
+ }), Schema.Null])),
822
+ zoneSettings: Schema.optional(Schema.Union([Schema.Struct({
1369
823
  read: Schema.optional(Schema.Union([Schema.Boolean, Schema.Null])),
1370
- write: Schema.optional(Schema.Union([Schema.Boolean, Schema.Null])),
1371
- }),
1372
- Schema.Null,
1373
- ])),
1374
- zones: Schema.optional(Schema.Union([
1375
- Schema.Struct({
824
+ write: Schema.optional(Schema.Union([Schema.Boolean, Schema.Null]))
825
+ }), Schema.Null])),
826
+ zones: Schema.optional(Schema.Union([Schema.Struct({
1376
827
  read: Schema.optional(Schema.Union([Schema.Boolean, Schema.Null])),
1377
- write: Schema.optional(Schema.Union([Schema.Boolean, Schema.Null])),
1378
- }),
1379
- Schema.Null,
1380
- ])),
1381
- }).pipe(Schema.encodeKeys({
1382
- analytics: "analytics",
1383
- billing: "billing",
1384
- cachePurge: "cache_purge",
1385
- dns: "dns",
1386
- dnsRecords: "dns_records",
1387
- lb: "lb",
1388
- logs: "logs",
1389
- organization: "organization",
1390
- ssl: "ssl",
1391
- waf: "waf",
1392
- zoneSettings: "zone_settings",
1393
- zones: "zones",
1394
- })),
828
+ write: Schema.optional(Schema.Union([Schema.Boolean, Schema.Null]))
829
+ }), Schema.Null]))
830
+ }).pipe(Schema.encodeKeys({ analytics: "analytics", billing: "billing", cachePurge: "cache_purge", dns: "dns", dnsRecords: "dns_records", lb: "lb", logs: "logs", organization: "organization", ssl: "ssl", waf: "waf", zoneSettings: "zone_settings", zones: "zones" }))
1395
831
  })),
1396
832
  resultInfo: Schema.Struct({
1397
833
  count: Schema.optional(Schema.Union([Schema.Number, Schema.Null])),
1398
834
  page: Schema.optional(Schema.Union([Schema.Number, Schema.Null])),
1399
835
  perPage: Schema.optional(Schema.Union([Schema.Number, Schema.Null])),
1400
- totalCount: Schema.optional(Schema.Union([Schema.Number, Schema.Null])),
1401
- }).pipe(Schema.encodeKeys({
1402
- count: "count",
1403
- page: "page",
1404
- perPage: "per_page",
1405
- totalCount: "total_count",
1406
- })),
836
+ totalCount: Schema.optional(Schema.Union([Schema.Number, Schema.Null]))
837
+ }).pipe(Schema.encodeKeys({ count: "count", page: "page", perPage: "per_page", totalCount: "total_count" }))
1407
838
  }).pipe(Schema.encodeKeys({ result: "result", resultInfo: "result_info" }));
1408
839
  export const listRoles = /*@__PURE__*/ /*#__PURE__*/ API.makePaginated(() => ({
1409
840
  input: ListRolesRequest,
@@ -1418,76 +849,28 @@ export const listRoles = /*@__PURE__*/ /*#__PURE__*/ API.makePaginated(() => ({
1418
849
  },
1419
850
  }));
1420
851
  export const GetSubscriptionRequest = /*@__PURE__*/ /*#__PURE__*/ Schema.Struct({
1421
- accountId: Schema.String.pipe(T.HttpPath("account_id")),
1422
- }).pipe(T.Http({ method: "GET", path: "/accounts/{account_id}/subscriptions" }));
1423
- export const GetSubscriptionResponse =
1424
- /*@__PURE__*/ /*#__PURE__*/ Schema.Struct({
852
+ accountId: Schema.String.pipe(T.HttpPath("account_id"))
853
+ })
854
+ .pipe(T.Http({ method: "GET", path: "/accounts/{account_id}/subscriptions" }));
855
+ export const GetSubscriptionResponse = /*@__PURE__*/ /*#__PURE__*/ Schema.Struct({
1425
856
  result: Schema.Array(Schema.Struct({
1426
857
  id: Schema.optional(Schema.Union([Schema.String, Schema.Null])),
1427
858
  currency: Schema.optional(Schema.Union([Schema.String, Schema.Null])),
1428
859
  currentPeriodEnd: Schema.optional(Schema.Union([Schema.String, Schema.Null])),
1429
860
  currentPeriodStart: Schema.optional(Schema.Union([Schema.String, Schema.Null])),
1430
- frequency: Schema.optional(Schema.Union([
1431
- Schema.Literals(["weekly", "monthly", "quarterly", "yearly"]),
1432
- Schema.Null,
1433
- ])),
861
+ frequency: Schema.optional(Schema.Union([Schema.Literals(["weekly", "monthly", "quarterly", "yearly"]), Schema.Null])),
1434
862
  price: Schema.optional(Schema.Union([Schema.Number, Schema.Null])),
1435
- ratePlan: Schema.optional(Schema.Union([
1436
- Schema.Struct({
1437
- id: Schema.optional(Schema.Union([
1438
- Schema.Literals([
1439
- "free",
1440
- "lite",
1441
- "pro",
1442
- "pro_plus",
1443
- "business",
1444
- "enterprise",
1445
- "partners_free",
1446
- "partners_pro",
1447
- "partners_business",
1448
- "partners_enterprise",
1449
- ]),
1450
- Schema.Null,
1451
- ])),
863
+ ratePlan: Schema.optional(Schema.Union([Schema.Struct({
864
+ id: Schema.optional(Schema.Union([Schema.Literals(["free", "lite", "pro", "pro_plus", "business", "enterprise", "partners_free", "partners_pro", "partners_business", "partners_enterprise"]), Schema.Null])),
1452
865
  currency: Schema.optional(Schema.Union([Schema.String, Schema.Null])),
1453
866
  externallyManaged: Schema.optional(Schema.Union([Schema.Boolean, Schema.Null])),
1454
867
  isContract: Schema.optional(Schema.Union([Schema.Boolean, Schema.Null])),
1455
868
  publicName: Schema.optional(Schema.Union([Schema.String, Schema.Null])),
1456
869
  scope: Schema.optional(Schema.Union([Schema.String, Schema.Null])),
1457
- sets: Schema.optional(Schema.Union([Schema.Array(Schema.String), Schema.Null])),
1458
- }).pipe(Schema.encodeKeys({
1459
- id: "id",
1460
- currency: "currency",
1461
- externallyManaged: "externally_managed",
1462
- isContract: "is_contract",
1463
- publicName: "public_name",
1464
- scope: "scope",
1465
- sets: "sets",
1466
- })),
1467
- Schema.Null,
1468
- ])),
1469
- state: Schema.optional(Schema.Union([
1470
- Schema.Literals([
1471
- "Trial",
1472
- "Provisioned",
1473
- "Paid",
1474
- "AwaitingPayment",
1475
- "Cancelled",
1476
- "Failed",
1477
- "Expired",
1478
- ]),
1479
- Schema.Null,
1480
- ])),
1481
- }).pipe(Schema.encodeKeys({
1482
- id: "id",
1483
- currency: "currency",
1484
- currentPeriodEnd: "current_period_end",
1485
- currentPeriodStart: "current_period_start",
1486
- frequency: "frequency",
1487
- price: "price",
1488
- ratePlan: "rate_plan",
1489
- state: "state",
1490
- }))),
870
+ sets: Schema.optional(Schema.Union([Schema.Array(Schema.String), Schema.Null]))
871
+ }).pipe(Schema.encodeKeys({ id: "id", currency: "currency", externallyManaged: "externally_managed", isContract: "is_contract", publicName: "public_name", scope: "scope", sets: "sets" })), Schema.Null])),
872
+ state: Schema.optional(Schema.Union([Schema.Literals(["Trial", "Provisioned", "Paid", "AwaitingPayment", "Cancelled", "Failed", "Expired"]), Schema.Null]))
873
+ }).pipe(Schema.encodeKeys({ id: "id", currency: "currency", currentPeriodEnd: "current_period_end", currentPeriodStart: "current_period_start", frequency: "frequency", price: "price", ratePlan: "rate_plan", state: "state" })))
1491
874
  });
1492
875
  export const getSubscription = /*@__PURE__*/ /*#__PURE__*/ API.makePaginated(() => ({
1493
876
  input: GetSubscriptionRequest,
@@ -1498,238 +881,89 @@ export const getSubscription = /*@__PURE__*/ /*#__PURE__*/ API.makePaginated(()
1498
881
  items: "result",
1499
882
  },
1500
883
  }));
1501
- export const CreateSubscriptionRequest =
1502
- /*@__PURE__*/ /*#__PURE__*/ Schema.Struct({
884
+ export const CreateSubscriptionRequest = /*@__PURE__*/ /*#__PURE__*/ Schema.Struct({
1503
885
  accountId: Schema.String.pipe(T.HttpPath("account_id")),
1504
886
  frequency: Schema.optional(Schema.Literals(["weekly", "monthly", "quarterly", "yearly"])),
1505
887
  ratePlan: Schema.optional(Schema.Struct({
1506
- id: Schema.optional(Schema.Literals([
1507
- "free",
1508
- "lite",
1509
- "pro",
1510
- "pro_plus",
1511
- "business",
1512
- "enterprise",
1513
- "partners_free",
1514
- "partners_pro",
1515
- "partners_business",
1516
- "partners_enterprise",
1517
- ])),
888
+ id: Schema.optional(Schema.Literals(["free", "lite", "pro", "pro_plus", "business", "enterprise", "partners_free", "partners_pro", "partners_business", "partners_enterprise"])),
1518
889
  currency: Schema.optional(Schema.String),
1519
890
  externallyManaged: Schema.optional(Schema.Boolean),
1520
891
  isContract: Schema.optional(Schema.Boolean),
1521
892
  publicName: Schema.optional(Schema.String),
1522
893
  scope: Schema.optional(Schema.String),
1523
- sets: Schema.optional(Schema.Array(Schema.String)),
1524
- }).pipe(Schema.encodeKeys({
1525
- id: "id",
1526
- currency: "currency",
1527
- externallyManaged: "externally_managed",
1528
- isContract: "is_contract",
1529
- publicName: "public_name",
1530
- scope: "scope",
1531
- sets: "sets",
1532
- }))),
1533
- }).pipe(Schema.encodeKeys({ frequency: "frequency", ratePlan: "rate_plan" }), T.Http({ method: "POST", path: "/accounts/{account_id}/subscriptions" }));
1534
- export const CreateSubscriptionResponse =
1535
- /*@__PURE__*/ /*#__PURE__*/ Schema.Struct({
894
+ sets: Schema.optional(Schema.Array(Schema.String))
895
+ }).pipe(Schema.encodeKeys({ id: "id", currency: "currency", externallyManaged: "externally_managed", isContract: "is_contract", publicName: "public_name", scope: "scope", sets: "sets" })))
896
+ })
897
+ .pipe(Schema.encodeKeys({ frequency: "frequency", ratePlan: "rate_plan" }), T.Http({ method: "POST", path: "/accounts/{account_id}/subscriptions" }));
898
+ export const CreateSubscriptionResponse = /*@__PURE__*/ /*#__PURE__*/ Schema.Struct({
1536
899
  id: Schema.optional(Schema.Union([Schema.String, Schema.Null])),
1537
900
  currency: Schema.optional(Schema.Union([Schema.String, Schema.Null])),
1538
901
  currentPeriodEnd: Schema.optional(Schema.Union([Schema.String, Schema.Null])),
1539
902
  currentPeriodStart: Schema.optional(Schema.Union([Schema.String, Schema.Null])),
1540
- frequency: Schema.optional(Schema.Union([
1541
- Schema.Literals(["weekly", "monthly", "quarterly", "yearly"]),
1542
- Schema.Null,
1543
- ])),
903
+ frequency: Schema.optional(Schema.Union([Schema.Literals(["weekly", "monthly", "quarterly", "yearly"]), Schema.Null])),
1544
904
  price: Schema.optional(Schema.Union([Schema.Number, Schema.Null])),
1545
- ratePlan: Schema.optional(Schema.Union([
1546
- Schema.Struct({
1547
- id: Schema.optional(Schema.Union([
1548
- Schema.Literals([
1549
- "free",
1550
- "lite",
1551
- "pro",
1552
- "pro_plus",
1553
- "business",
1554
- "enterprise",
1555
- "partners_free",
1556
- "partners_pro",
1557
- "partners_business",
1558
- "partners_enterprise",
1559
- ]),
1560
- Schema.Null,
1561
- ])),
905
+ ratePlan: Schema.optional(Schema.Union([Schema.Struct({
906
+ id: Schema.optional(Schema.Union([Schema.Literals(["free", "lite", "pro", "pro_plus", "business", "enterprise", "partners_free", "partners_pro", "partners_business", "partners_enterprise"]), Schema.Null])),
1562
907
  currency: Schema.optional(Schema.Union([Schema.String, Schema.Null])),
1563
908
  externallyManaged: Schema.optional(Schema.Union([Schema.Boolean, Schema.Null])),
1564
909
  isContract: Schema.optional(Schema.Union([Schema.Boolean, Schema.Null])),
1565
910
  publicName: Schema.optional(Schema.Union([Schema.String, Schema.Null])),
1566
911
  scope: Schema.optional(Schema.Union([Schema.String, Schema.Null])),
1567
- sets: Schema.optional(Schema.Union([Schema.Array(Schema.String), Schema.Null])),
1568
- }).pipe(Schema.encodeKeys({
1569
- id: "id",
1570
- currency: "currency",
1571
- externallyManaged: "externally_managed",
1572
- isContract: "is_contract",
1573
- publicName: "public_name",
1574
- scope: "scope",
1575
- sets: "sets",
1576
- })),
1577
- Schema.Null,
1578
- ])),
1579
- state: Schema.optional(Schema.Union([
1580
- Schema.Literals([
1581
- "Trial",
1582
- "Provisioned",
1583
- "Paid",
1584
- "AwaitingPayment",
1585
- "Cancelled",
1586
- "Failed",
1587
- "Expired",
1588
- ]),
1589
- Schema.Null,
1590
- ])),
1591
- })
1592
- .pipe(Schema.encodeKeys({
1593
- id: "id",
1594
- currency: "currency",
1595
- currentPeriodEnd: "current_period_end",
1596
- currentPeriodStart: "current_period_start",
1597
- frequency: "frequency",
1598
- price: "price",
1599
- ratePlan: "rate_plan",
1600
- state: "state",
1601
- }))
1602
- .pipe(T.ResponsePath("result"));
912
+ sets: Schema.optional(Schema.Union([Schema.Array(Schema.String), Schema.Null]))
913
+ }).pipe(Schema.encodeKeys({ id: "id", currency: "currency", externallyManaged: "externally_managed", isContract: "is_contract", publicName: "public_name", scope: "scope", sets: "sets" })), Schema.Null])),
914
+ state: Schema.optional(Schema.Union([Schema.Literals(["Trial", "Provisioned", "Paid", "AwaitingPayment", "Cancelled", "Failed", "Expired"]), Schema.Null]))
915
+ }).pipe(Schema.encodeKeys({ id: "id", currency: "currency", currentPeriodEnd: "current_period_end", currentPeriodStart: "current_period_start", frequency: "frequency", price: "price", ratePlan: "rate_plan", state: "state" })).pipe(T.ResponsePath("result"));
1603
916
  export const createSubscription = /*@__PURE__*/ /*#__PURE__*/ API.make(() => ({
1604
917
  input: CreateSubscriptionRequest,
1605
918
  output: CreateSubscriptionResponse,
1606
919
  errors: [JsonDecodeFailure, InvalidRoute],
1607
920
  }));
1608
- export const UpdateSubscriptionRequest =
1609
- /*@__PURE__*/ /*#__PURE__*/ Schema.Struct({
921
+ export const UpdateSubscriptionRequest = /*@__PURE__*/ /*#__PURE__*/ Schema.Struct({
1610
922
  subscriptionIdentifier: Schema.String.pipe(T.HttpPath("subscriptionIdentifier")),
1611
923
  accountId: Schema.String.pipe(T.HttpPath("account_id")),
1612
924
  frequency: Schema.optional(Schema.Literals(["weekly", "monthly", "quarterly", "yearly"])),
1613
925
  ratePlan: Schema.optional(Schema.Struct({
1614
- id: Schema.optional(Schema.Literals([
1615
- "free",
1616
- "lite",
1617
- "pro",
1618
- "pro_plus",
1619
- "business",
1620
- "enterprise",
1621
- "partners_free",
1622
- "partners_pro",
1623
- "partners_business",
1624
- "partners_enterprise",
1625
- ])),
926
+ id: Schema.optional(Schema.Literals(["free", "lite", "pro", "pro_plus", "business", "enterprise", "partners_free", "partners_pro", "partners_business", "partners_enterprise"])),
1626
927
  currency: Schema.optional(Schema.String),
1627
928
  externallyManaged: Schema.optional(Schema.Boolean),
1628
929
  isContract: Schema.optional(Schema.Boolean),
1629
930
  publicName: Schema.optional(Schema.String),
1630
931
  scope: Schema.optional(Schema.String),
1631
- sets: Schema.optional(Schema.Array(Schema.String)),
1632
- }).pipe(Schema.encodeKeys({
1633
- id: "id",
1634
- currency: "currency",
1635
- externallyManaged: "externally_managed",
1636
- isContract: "is_contract",
1637
- publicName: "public_name",
1638
- scope: "scope",
1639
- sets: "sets",
1640
- }))),
1641
- }).pipe(Schema.encodeKeys({ frequency: "frequency", ratePlan: "rate_plan" }), T.Http({
1642
- method: "PUT",
1643
- path: "/accounts/{account_id}/subscriptions/{subscriptionIdentifier}",
1644
- }));
1645
- export const UpdateSubscriptionResponse =
1646
- /*@__PURE__*/ /*#__PURE__*/ Schema.Struct({
932
+ sets: Schema.optional(Schema.Array(Schema.String))
933
+ }).pipe(Schema.encodeKeys({ id: "id", currency: "currency", externallyManaged: "externally_managed", isContract: "is_contract", publicName: "public_name", scope: "scope", sets: "sets" })))
934
+ })
935
+ .pipe(Schema.encodeKeys({ frequency: "frequency", ratePlan: "rate_plan" }), T.Http({ method: "PUT", path: "/accounts/{account_id}/subscriptions/{subscriptionIdentifier}" }));
936
+ export const UpdateSubscriptionResponse = /*@__PURE__*/ /*#__PURE__*/ Schema.Struct({
1647
937
  id: Schema.optional(Schema.Union([Schema.String, Schema.Null])),
1648
938
  currency: Schema.optional(Schema.Union([Schema.String, Schema.Null])),
1649
939
  currentPeriodEnd: Schema.optional(Schema.Union([Schema.String, Schema.Null])),
1650
940
  currentPeriodStart: Schema.optional(Schema.Union([Schema.String, Schema.Null])),
1651
- frequency: Schema.optional(Schema.Union([
1652
- Schema.Literals(["weekly", "monthly", "quarterly", "yearly"]),
1653
- Schema.Null,
1654
- ])),
941
+ frequency: Schema.optional(Schema.Union([Schema.Literals(["weekly", "monthly", "quarterly", "yearly"]), Schema.Null])),
1655
942
  price: Schema.optional(Schema.Union([Schema.Number, Schema.Null])),
1656
- ratePlan: Schema.optional(Schema.Union([
1657
- Schema.Struct({
1658
- id: Schema.optional(Schema.Union([
1659
- Schema.Literals([
1660
- "free",
1661
- "lite",
1662
- "pro",
1663
- "pro_plus",
1664
- "business",
1665
- "enterprise",
1666
- "partners_free",
1667
- "partners_pro",
1668
- "partners_business",
1669
- "partners_enterprise",
1670
- ]),
1671
- Schema.Null,
1672
- ])),
943
+ ratePlan: Schema.optional(Schema.Union([Schema.Struct({
944
+ id: Schema.optional(Schema.Union([Schema.Literals(["free", "lite", "pro", "pro_plus", "business", "enterprise", "partners_free", "partners_pro", "partners_business", "partners_enterprise"]), Schema.Null])),
1673
945
  currency: Schema.optional(Schema.Union([Schema.String, Schema.Null])),
1674
946
  externallyManaged: Schema.optional(Schema.Union([Schema.Boolean, Schema.Null])),
1675
947
  isContract: Schema.optional(Schema.Union([Schema.Boolean, Schema.Null])),
1676
948
  publicName: Schema.optional(Schema.Union([Schema.String, Schema.Null])),
1677
949
  scope: Schema.optional(Schema.Union([Schema.String, Schema.Null])),
1678
- sets: Schema.optional(Schema.Union([Schema.Array(Schema.String), Schema.Null])),
1679
- }).pipe(Schema.encodeKeys({
1680
- id: "id",
1681
- currency: "currency",
1682
- externallyManaged: "externally_managed",
1683
- isContract: "is_contract",
1684
- publicName: "public_name",
1685
- scope: "scope",
1686
- sets: "sets",
1687
- })),
1688
- Schema.Null,
1689
- ])),
1690
- state: Schema.optional(Schema.Union([
1691
- Schema.Literals([
1692
- "Trial",
1693
- "Provisioned",
1694
- "Paid",
1695
- "AwaitingPayment",
1696
- "Cancelled",
1697
- "Failed",
1698
- "Expired",
1699
- ]),
1700
- Schema.Null,
1701
- ])),
1702
- })
1703
- .pipe(Schema.encodeKeys({
1704
- id: "id",
1705
- currency: "currency",
1706
- currentPeriodEnd: "current_period_end",
1707
- currentPeriodStart: "current_period_start",
1708
- frequency: "frequency",
1709
- price: "price",
1710
- ratePlan: "rate_plan",
1711
- state: "state",
1712
- }))
1713
- .pipe(T.ResponsePath("result"));
950
+ sets: Schema.optional(Schema.Union([Schema.Array(Schema.String), Schema.Null]))
951
+ }).pipe(Schema.encodeKeys({ id: "id", currency: "currency", externallyManaged: "externally_managed", isContract: "is_contract", publicName: "public_name", scope: "scope", sets: "sets" })), Schema.Null])),
952
+ state: Schema.optional(Schema.Union([Schema.Literals(["Trial", "Provisioned", "Paid", "AwaitingPayment", "Cancelled", "Failed", "Expired"]), Schema.Null]))
953
+ }).pipe(Schema.encodeKeys({ id: "id", currency: "currency", currentPeriodEnd: "current_period_end", currentPeriodStart: "current_period_start", frequency: "frequency", price: "price", ratePlan: "rate_plan", state: "state" })).pipe(T.ResponsePath("result"));
1714
954
  export const updateSubscription = /*@__PURE__*/ /*#__PURE__*/ API.make(() => ({
1715
955
  input: UpdateSubscriptionRequest,
1716
956
  output: UpdateSubscriptionResponse,
1717
957
  errors: [JsonDecodeFailure, InvalidRoute, EndpointNotFound],
1718
958
  }));
1719
- export const DeleteSubscriptionRequest =
1720
- /*@__PURE__*/ /*#__PURE__*/ Schema.Struct({
959
+ export const DeleteSubscriptionRequest = /*@__PURE__*/ /*#__PURE__*/ Schema.Struct({
1721
960
  subscriptionIdentifier: Schema.String.pipe(T.HttpPath("subscriptionIdentifier")),
1722
- accountId: Schema.String.pipe(T.HttpPath("account_id")),
1723
- }).pipe(T.Http({
1724
- method: "DELETE",
1725
- path: "/accounts/{account_id}/subscriptions/{subscriptionIdentifier}",
1726
- }));
1727
- export const DeleteSubscriptionResponse =
1728
- /*@__PURE__*/ /*#__PURE__*/ Schema.Struct({
1729
- subscriptionId: Schema.optional(Schema.Union([Schema.String, Schema.Null])),
961
+ accountId: Schema.String.pipe(T.HttpPath("account_id"))
1730
962
  })
1731
- .pipe(Schema.encodeKeys({ subscriptionId: "subscription_id" }))
1732
- .pipe(T.ResponsePath("result"));
963
+ .pipe(T.Http({ method: "DELETE", path: "/accounts/{account_id}/subscriptions/{subscriptionIdentifier}" }));
964
+ export const DeleteSubscriptionResponse = /*@__PURE__*/ /*#__PURE__*/ Schema.Struct({
965
+ subscriptionId: Schema.optional(Schema.Union([Schema.String, Schema.Null]))
966
+ }).pipe(Schema.encodeKeys({ subscriptionId: "subscription_id" })).pipe(T.ResponsePath("result"));
1733
967
  export const deleteSubscription = /*@__PURE__*/ /*#__PURE__*/ API.make(() => ({
1734
968
  input: DeleteSubscriptionRequest,
1735
969
  output: DeleteSubscriptionResponse,
@@ -1737,151 +971,84 @@ export const deleteSubscription = /*@__PURE__*/ /*#__PURE__*/ API.make(() => ({
1737
971
  }));
1738
972
  export const GetTokenRequest = /*@__PURE__*/ /*#__PURE__*/ Schema.Struct({
1739
973
  tokenId: Schema.String.pipe(T.HttpPath("tokenId")),
1740
- accountId: Schema.String.pipe(T.HttpPath("account_id")),
1741
- }).pipe(T.Http({ method: "GET", path: "/accounts/{account_id}/tokens/{tokenId}" }));
974
+ accountId: Schema.String.pipe(T.HttpPath("account_id"))
975
+ })
976
+ .pipe(T.Http({ method: "GET", path: "/accounts/{account_id}/tokens/{tokenId}" }));
1742
977
  export const GetTokenResponse = /*@__PURE__*/ /*#__PURE__*/ Schema.Struct({
1743
978
  id: Schema.optional(Schema.Union([Schema.String, Schema.Null])),
1744
- condition: Schema.optional(Schema.Union([
1745
- Schema.Struct({
1746
- requestIp: Schema.optional(Schema.Union([
1747
- Schema.Struct({
979
+ condition: Schema.optional(Schema.Union([Schema.Struct({
980
+ requestIp: Schema.optional(Schema.Union([Schema.Struct({
1748
981
  in: Schema.optional(Schema.Union([Schema.Array(Schema.String), Schema.Null])),
1749
- notIn: Schema.optional(Schema.Union([Schema.Array(Schema.String), Schema.Null])),
1750
- }).pipe(Schema.encodeKeys({ in: "in", notIn: "not_in" })),
1751
- Schema.Null,
1752
- ])),
1753
- }).pipe(Schema.encodeKeys({ requestIp: "request_ip" })),
1754
- Schema.Null,
1755
- ])),
982
+ notIn: Schema.optional(Schema.Union([Schema.Array(Schema.String), Schema.Null]))
983
+ }).pipe(Schema.encodeKeys({ in: "in", notIn: "not_in" })), Schema.Null]))
984
+ }).pipe(Schema.encodeKeys({ requestIp: "request_ip" })), Schema.Null])),
1756
985
  expiresOn: Schema.optional(Schema.Union([Schema.String, Schema.Null])),
1757
986
  issuedOn: Schema.optional(Schema.Union([Schema.String, Schema.Null])),
1758
987
  lastUsedOn: Schema.optional(Schema.Union([Schema.String, Schema.Null])),
1759
988
  modifiedOn: Schema.optional(Schema.Union([Schema.String, Schema.Null])),
1760
989
  name: Schema.optional(Schema.Union([Schema.String, Schema.Null])),
1761
990
  notBefore: Schema.optional(Schema.Union([Schema.String, Schema.Null])),
1762
- policies: Schema.optional(Schema.Union([
1763
- Schema.Array(Schema.Struct({
991
+ policies: Schema.optional(Schema.Union([Schema.Array(Schema.Struct({
1764
992
  id: Schema.String,
1765
993
  effect: Schema.Literals(["allow", "deny"]),
1766
994
  permissionGroups: Schema.Array(Schema.Struct({
1767
995
  id: Schema.String,
1768
- meta: Schema.optional(Schema.Union([
1769
- Schema.Struct({
996
+ meta: Schema.optional(Schema.Union([Schema.Struct({
1770
997
  key: Schema.optional(Schema.Union([Schema.String, Schema.Null])),
1771
- value: Schema.optional(Schema.Union([Schema.String, Schema.Null])),
1772
- }),
1773
- Schema.Null,
1774
- ])),
1775
- name: Schema.optional(Schema.Union([Schema.String, Schema.Null])),
998
+ value: Schema.optional(Schema.Union([Schema.String, Schema.Null]))
999
+ }), Schema.Null])),
1000
+ name: Schema.optional(Schema.Union([Schema.String, Schema.Null]))
1776
1001
  })),
1777
- resources: Schema.Record(Schema.String, Schema.Unknown),
1778
- }).pipe(Schema.encodeKeys({
1779
- id: "id",
1780
- effect: "effect",
1781
- permissionGroups: "permission_groups",
1782
- resources: "resources",
1783
- }))),
1784
- Schema.Null,
1785
- ])),
1786
- status: Schema.optional(Schema.Union([
1787
- Schema.Literals(["active", "disabled", "expired"]),
1788
- Schema.Null,
1789
- ])),
1790
- })
1791
- .pipe(Schema.encodeKeys({
1792
- id: "id",
1793
- condition: "condition",
1794
- expiresOn: "expires_on",
1795
- issuedOn: "issued_on",
1796
- lastUsedOn: "last_used_on",
1797
- modifiedOn: "modified_on",
1798
- name: "name",
1799
- notBefore: "not_before",
1800
- policies: "policies",
1801
- status: "status",
1802
- }))
1803
- .pipe(T.ResponsePath("result"));
1002
+ resources: Schema.Record(Schema.String, Schema.Unknown)
1003
+ }).pipe(Schema.encodeKeys({ id: "id", effect: "effect", permissionGroups: "permission_groups", resources: "resources" }))), Schema.Null])),
1004
+ status: Schema.optional(Schema.Union([Schema.Literals(["active", "disabled", "expired"]), Schema.Null]))
1005
+ }).pipe(Schema.encodeKeys({ id: "id", condition: "condition", expiresOn: "expires_on", issuedOn: "issued_on", lastUsedOn: "last_used_on", modifiedOn: "modified_on", name: "name", notBefore: "not_before", policies: "policies", status: "status" })).pipe(T.ResponsePath("result"));
1804
1006
  export const getToken = /*@__PURE__*/ /*#__PURE__*/ API.make(() => ({
1805
1007
  input: GetTokenRequest,
1806
1008
  output: GetTokenResponse,
1807
- errors: [InvalidRoute],
1009
+ errors: [InvalidRoute, TokenNotFound],
1808
1010
  }));
1809
1011
  export const ListTokensRequest = /*@__PURE__*/ /*#__PURE__*/ Schema.Struct({
1810
1012
  accountId: Schema.String.pipe(T.HttpPath("account_id")),
1811
- direction: Schema.optional(Schema.Literals(["asc", "desc"])).pipe(T.HttpQuery("direction")),
1812
- }).pipe(T.Http({ method: "GET", path: "/accounts/{account_id}/tokens" }));
1013
+ direction: Schema.optional(Schema.Literals(["asc", "desc"])).pipe(T.HttpQuery("direction"))
1014
+ })
1015
+ .pipe(T.Http({ method: "GET", path: "/accounts/{account_id}/tokens" }));
1813
1016
  export const ListTokensResponse = /*@__PURE__*/ /*#__PURE__*/ Schema.Struct({
1814
1017
  result: Schema.Array(Schema.Struct({
1815
1018
  id: Schema.optional(Schema.Union([Schema.String, Schema.Null])),
1816
- condition: Schema.optional(Schema.Union([
1817
- Schema.Struct({
1818
- requestIp: Schema.optional(Schema.Union([
1819
- Schema.Struct({
1019
+ condition: Schema.optional(Schema.Union([Schema.Struct({
1020
+ requestIp: Schema.optional(Schema.Union([Schema.Struct({
1820
1021
  in: Schema.optional(Schema.Union([Schema.Array(Schema.String), Schema.Null])),
1821
- notIn: Schema.optional(Schema.Union([Schema.Array(Schema.String), Schema.Null])),
1822
- }).pipe(Schema.encodeKeys({ in: "in", notIn: "not_in" })),
1823
- Schema.Null,
1824
- ])),
1825
- }).pipe(Schema.encodeKeys({ requestIp: "request_ip" })),
1826
- Schema.Null,
1827
- ])),
1022
+ notIn: Schema.optional(Schema.Union([Schema.Array(Schema.String), Schema.Null]))
1023
+ }).pipe(Schema.encodeKeys({ in: "in", notIn: "not_in" })), Schema.Null]))
1024
+ }).pipe(Schema.encodeKeys({ requestIp: "request_ip" })), Schema.Null])),
1828
1025
  expiresOn: Schema.optional(Schema.Union([Schema.String, Schema.Null])),
1829
1026
  issuedOn: Schema.optional(Schema.Union([Schema.String, Schema.Null])),
1830
1027
  lastUsedOn: Schema.optional(Schema.Union([Schema.String, Schema.Null])),
1831
1028
  modifiedOn: Schema.optional(Schema.Union([Schema.String, Schema.Null])),
1832
1029
  name: Schema.optional(Schema.Union([Schema.String, Schema.Null])),
1833
1030
  notBefore: Schema.optional(Schema.Union([Schema.String, Schema.Null])),
1834
- policies: Schema.optional(Schema.Union([
1835
- Schema.Array(Schema.Struct({
1031
+ policies: Schema.optional(Schema.Union([Schema.Array(Schema.Struct({
1836
1032
  id: Schema.String,
1837
1033
  effect: Schema.Literals(["allow", "deny"]),
1838
1034
  permissionGroups: Schema.Array(Schema.Struct({
1839
1035
  id: Schema.String,
1840
- meta: Schema.optional(Schema.Union([
1841
- Schema.Struct({
1036
+ meta: Schema.optional(Schema.Union([Schema.Struct({
1842
1037
  key: Schema.optional(Schema.Union([Schema.String, Schema.Null])),
1843
- value: Schema.optional(Schema.Union([Schema.String, Schema.Null])),
1844
- }),
1845
- Schema.Null,
1846
- ])),
1847
- name: Schema.optional(Schema.Union([Schema.String, Schema.Null])),
1038
+ value: Schema.optional(Schema.Union([Schema.String, Schema.Null]))
1039
+ }), Schema.Null])),
1040
+ name: Schema.optional(Schema.Union([Schema.String, Schema.Null]))
1848
1041
  })),
1849
- resources: Schema.Record(Schema.String, Schema.Unknown),
1850
- }).pipe(Schema.encodeKeys({
1851
- id: "id",
1852
- effect: "effect",
1853
- permissionGroups: "permission_groups",
1854
- resources: "resources",
1855
- }))),
1856
- Schema.Null,
1857
- ])),
1858
- status: Schema.optional(Schema.Union([
1859
- Schema.Literals(["active", "disabled", "expired"]),
1860
- Schema.Null,
1861
- ])),
1862
- }).pipe(Schema.encodeKeys({
1863
- id: "id",
1864
- condition: "condition",
1865
- expiresOn: "expires_on",
1866
- issuedOn: "issued_on",
1867
- lastUsedOn: "last_used_on",
1868
- modifiedOn: "modified_on",
1869
- name: "name",
1870
- notBefore: "not_before",
1871
- policies: "policies",
1872
- status: "status",
1873
- }))),
1042
+ resources: Schema.Record(Schema.String, Schema.Unknown)
1043
+ }).pipe(Schema.encodeKeys({ id: "id", effect: "effect", permissionGroups: "permission_groups", resources: "resources" }))), Schema.Null])),
1044
+ status: Schema.optional(Schema.Union([Schema.Literals(["active", "disabled", "expired"]), Schema.Null]))
1045
+ }).pipe(Schema.encodeKeys({ id: "id", condition: "condition", expiresOn: "expires_on", issuedOn: "issued_on", lastUsedOn: "last_used_on", modifiedOn: "modified_on", name: "name", notBefore: "not_before", policies: "policies", status: "status" }))),
1874
1046
  resultInfo: Schema.Struct({
1875
1047
  count: Schema.optional(Schema.Union([Schema.Number, Schema.Null])),
1876
1048
  page: Schema.optional(Schema.Union([Schema.Number, Schema.Null])),
1877
1049
  perPage: Schema.optional(Schema.Union([Schema.Number, Schema.Null])),
1878
- totalCount: Schema.optional(Schema.Union([Schema.Number, Schema.Null])),
1879
- }).pipe(Schema.encodeKeys({
1880
- count: "count",
1881
- page: "page",
1882
- perPage: "per_page",
1883
- totalCount: "total_count",
1884
- })),
1050
+ totalCount: Schema.optional(Schema.Union([Schema.Number, Schema.Null]))
1051
+ }).pipe(Schema.encodeKeys({ count: "count", page: "page", perPage: "per_page", totalCount: "total_count" }))
1885
1052
  }).pipe(Schema.encodeKeys({ result: "result", resultInfo: "result_info" }));
1886
1053
  export const listTokens = /*@__PURE__*/ /*#__PURE__*/ API.makePaginated(() => ({
1887
1054
  input: ListTokensRequest,
@@ -1904,98 +1071,55 @@ export const CreateTokenRequest = /*@__PURE__*/ /*#__PURE__*/ Schema.Struct({
1904
1071
  id: Schema.String,
1905
1072
  meta: Schema.optional(Schema.Struct({
1906
1073
  key: Schema.optional(Schema.String),
1907
- value: Schema.optional(Schema.String),
1908
- })),
1074
+ value: Schema.optional(Schema.String)
1075
+ }))
1909
1076
  })),
1910
- resources: Schema.Record(Schema.String, Schema.Unknown),
1911
- }).pipe(Schema.encodeKeys({
1912
- effect: "effect",
1913
- permissionGroups: "permission_groups",
1914
- resources: "resources",
1915
- }))),
1077
+ resources: Schema.Record(Schema.String, Schema.Unknown)
1078
+ }).pipe(Schema.encodeKeys({ effect: "effect", permissionGroups: "permission_groups", resources: "resources" }))),
1916
1079
  condition: Schema.optional(Schema.Struct({
1917
1080
  requestIp: Schema.optional(Schema.Struct({
1918
1081
  in: Schema.optional(Schema.Array(Schema.String)),
1919
- notIn: Schema.optional(Schema.Array(Schema.String)),
1920
- }).pipe(Schema.encodeKeys({ in: "in", notIn: "not_in" }))),
1082
+ notIn: Schema.optional(Schema.Array(Schema.String))
1083
+ }).pipe(Schema.encodeKeys({ in: "in", notIn: "not_in" })))
1921
1084
  }).pipe(Schema.encodeKeys({ requestIp: "request_ip" }))),
1922
1085
  expiresOn: Schema.optional(Schema.String),
1923
- notBefore: Schema.optional(Schema.String),
1924
- }).pipe(Schema.encodeKeys({
1925
- name: "name",
1926
- policies: "policies",
1927
- condition: "condition",
1928
- expiresOn: "expires_on",
1929
- notBefore: "not_before",
1930
- }), T.Http({ method: "POST", path: "/accounts/{account_id}/tokens" }));
1086
+ notBefore: Schema.optional(Schema.String)
1087
+ })
1088
+ .pipe(Schema.encodeKeys({ name: "name", policies: "policies", condition: "condition", expiresOn: "expires_on", notBefore: "not_before" }), T.Http({ method: "POST", path: "/accounts/{account_id}/tokens" }));
1931
1089
  export const CreateTokenResponse = /*@__PURE__*/ /*#__PURE__*/ Schema.Struct({
1932
1090
  id: Schema.optional(Schema.Union([Schema.String, Schema.Null])),
1933
- condition: Schema.optional(Schema.Union([
1934
- Schema.Struct({
1935
- requestIp: Schema.optional(Schema.Union([
1936
- Schema.Struct({
1091
+ condition: Schema.optional(Schema.Union([Schema.Struct({
1092
+ requestIp: Schema.optional(Schema.Union([Schema.Struct({
1937
1093
  in: Schema.optional(Schema.Union([Schema.Array(Schema.String), Schema.Null])),
1938
- notIn: Schema.optional(Schema.Union([Schema.Array(Schema.String), Schema.Null])),
1939
- }).pipe(Schema.encodeKeys({ in: "in", notIn: "not_in" })),
1940
- Schema.Null,
1941
- ])),
1942
- }).pipe(Schema.encodeKeys({ requestIp: "request_ip" })),
1943
- Schema.Null,
1944
- ])),
1094
+ notIn: Schema.optional(Schema.Union([Schema.Array(Schema.String), Schema.Null]))
1095
+ }).pipe(Schema.encodeKeys({ in: "in", notIn: "not_in" })), Schema.Null]))
1096
+ }).pipe(Schema.encodeKeys({ requestIp: "request_ip" })), Schema.Null])),
1945
1097
  expiresOn: Schema.optional(Schema.Union([Schema.String, Schema.Null])),
1946
1098
  issuedOn: Schema.optional(Schema.Union([Schema.String, Schema.Null])),
1947
1099
  lastUsedOn: Schema.optional(Schema.Union([Schema.String, Schema.Null])),
1948
1100
  modifiedOn: Schema.optional(Schema.Union([Schema.String, Schema.Null])),
1949
1101
  name: Schema.optional(Schema.Union([Schema.String, Schema.Null])),
1950
1102
  notBefore: Schema.optional(Schema.Union([Schema.String, Schema.Null])),
1951
- policies: Schema.optional(Schema.Union([
1952
- Schema.Array(Schema.Struct({
1103
+ policies: Schema.optional(Schema.Union([Schema.Array(Schema.Struct({
1953
1104
  id: Schema.String,
1954
1105
  effect: Schema.Literals(["allow", "deny"]),
1955
1106
  permissionGroups: Schema.Array(Schema.Struct({
1956
1107
  id: Schema.String,
1957
- meta: Schema.optional(Schema.Union([
1958
- Schema.Struct({
1108
+ meta: Schema.optional(Schema.Union([Schema.Struct({
1959
1109
  key: Schema.optional(Schema.Union([Schema.String, Schema.Null])),
1960
- value: Schema.optional(Schema.Union([Schema.String, Schema.Null])),
1961
- }),
1962
- Schema.Null,
1963
- ])),
1964
- name: Schema.optional(Schema.Union([Schema.String, Schema.Null])),
1110
+ value: Schema.optional(Schema.Union([Schema.String, Schema.Null]))
1111
+ }), Schema.Null])),
1112
+ name: Schema.optional(Schema.Union([Schema.String, Schema.Null]))
1965
1113
  })),
1966
- resources: Schema.Record(Schema.String, Schema.Unknown),
1967
- }).pipe(Schema.encodeKeys({
1968
- id: "id",
1969
- effect: "effect",
1970
- permissionGroups: "permission_groups",
1971
- resources: "resources",
1972
- }))),
1973
- Schema.Null,
1974
- ])),
1975
- status: Schema.optional(Schema.Union([
1976
- Schema.Literals(["active", "disabled", "expired"]),
1977
- Schema.Null,
1978
- ])),
1979
- value: Schema.optional(Schema.Union([Schema.String, Schema.Null])),
1980
- })
1981
- .pipe(Schema.encodeKeys({
1982
- id: "id",
1983
- condition: "condition",
1984
- expiresOn: "expires_on",
1985
- issuedOn: "issued_on",
1986
- lastUsedOn: "last_used_on",
1987
- modifiedOn: "modified_on",
1988
- name: "name",
1989
- notBefore: "not_before",
1990
- policies: "policies",
1991
- status: "status",
1992
- value: "value",
1993
- }))
1994
- .pipe(T.ResponsePath("result"));
1114
+ resources: Schema.Record(Schema.String, Schema.Unknown)
1115
+ }).pipe(Schema.encodeKeys({ id: "id", effect: "effect", permissionGroups: "permission_groups", resources: "resources" }))), Schema.Null])),
1116
+ status: Schema.optional(Schema.Union([Schema.Literals(["active", "disabled", "expired"]), Schema.Null])),
1117
+ value: Schema.optional(Schema.Union([Schema.String, Schema.Null]))
1118
+ }).pipe(Schema.encodeKeys({ id: "id", condition: "condition", expiresOn: "expires_on", issuedOn: "issued_on", lastUsedOn: "last_used_on", modifiedOn: "modified_on", name: "name", notBefore: "not_before", policies: "policies", status: "status", value: "value" })).pipe(T.ResponsePath("result"));
1995
1119
  export const createToken = /*@__PURE__*/ /*#__PURE__*/ API.make(() => ({
1996
1120
  input: CreateTokenRequest,
1997
1121
  output: CreateTokenResponse,
1998
- errors: [InvalidRoute, InvalidTokenName],
1122
+ errors: [InvalidRoute, InvalidTokenName, PermissionGroupNotFound],
1999
1123
  }));
2000
1124
  export const UpdateTokenRequest = /*@__PURE__*/ /*#__PURE__*/ Schema.Struct({
2001
1125
  tokenId: Schema.String.pipe(T.HttpPath("tokenId")),
@@ -2007,184 +1131,112 @@ export const UpdateTokenRequest = /*@__PURE__*/ /*#__PURE__*/ Schema.Struct({
2007
1131
  id: Schema.String,
2008
1132
  meta: Schema.optional(Schema.Struct({
2009
1133
  key: Schema.optional(Schema.String),
2010
- value: Schema.optional(Schema.String),
2011
- })),
1134
+ value: Schema.optional(Schema.String)
1135
+ }))
2012
1136
  })),
2013
- resources: Schema.Record(Schema.String, Schema.Unknown),
2014
- }).pipe(Schema.encodeKeys({
2015
- effect: "effect",
2016
- permissionGroups: "permission_groups",
2017
- resources: "resources",
2018
- }))),
1137
+ resources: Schema.Record(Schema.String, Schema.Unknown)
1138
+ }).pipe(Schema.encodeKeys({ effect: "effect", permissionGroups: "permission_groups", resources: "resources" }))),
2019
1139
  condition: Schema.optional(Schema.Struct({
2020
1140
  requestIp: Schema.optional(Schema.Struct({
2021
1141
  in: Schema.optional(Schema.Array(Schema.String)),
2022
- notIn: Schema.optional(Schema.Array(Schema.String)),
2023
- }).pipe(Schema.encodeKeys({ in: "in", notIn: "not_in" }))),
1142
+ notIn: Schema.optional(Schema.Array(Schema.String))
1143
+ }).pipe(Schema.encodeKeys({ in: "in", notIn: "not_in" })))
2024
1144
  }).pipe(Schema.encodeKeys({ requestIp: "request_ip" }))),
2025
1145
  expiresOn: Schema.optional(Schema.String),
2026
1146
  notBefore: Schema.optional(Schema.String),
2027
- status: Schema.optional(Schema.Literals(["active", "disabled", "expired"])),
2028
- }).pipe(Schema.encodeKeys({
2029
- name: "name",
2030
- policies: "policies",
2031
- condition: "condition",
2032
- expiresOn: "expires_on",
2033
- notBefore: "not_before",
2034
- status: "status",
2035
- }), T.Http({ method: "PUT", path: "/accounts/{account_id}/tokens/{tokenId}" }));
1147
+ status: Schema.optional(Schema.Literals(["active", "disabled", "expired"]))
1148
+ })
1149
+ .pipe(Schema.encodeKeys({ name: "name", policies: "policies", condition: "condition", expiresOn: "expires_on", notBefore: "not_before", status: "status" }), T.Http({ method: "PUT", path: "/accounts/{account_id}/tokens/{tokenId}" }));
2036
1150
  export const UpdateTokenResponse = /*@__PURE__*/ /*#__PURE__*/ Schema.Struct({
2037
1151
  id: Schema.optional(Schema.Union([Schema.String, Schema.Null])),
2038
- condition: Schema.optional(Schema.Union([
2039
- Schema.Struct({
2040
- requestIp: Schema.optional(Schema.Union([
2041
- Schema.Struct({
1152
+ condition: Schema.optional(Schema.Union([Schema.Struct({
1153
+ requestIp: Schema.optional(Schema.Union([Schema.Struct({
2042
1154
  in: Schema.optional(Schema.Union([Schema.Array(Schema.String), Schema.Null])),
2043
- notIn: Schema.optional(Schema.Union([Schema.Array(Schema.String), Schema.Null])),
2044
- }).pipe(Schema.encodeKeys({ in: "in", notIn: "not_in" })),
2045
- Schema.Null,
2046
- ])),
2047
- }).pipe(Schema.encodeKeys({ requestIp: "request_ip" })),
2048
- Schema.Null,
2049
- ])),
1155
+ notIn: Schema.optional(Schema.Union([Schema.Array(Schema.String), Schema.Null]))
1156
+ }).pipe(Schema.encodeKeys({ in: "in", notIn: "not_in" })), Schema.Null]))
1157
+ }).pipe(Schema.encodeKeys({ requestIp: "request_ip" })), Schema.Null])),
2050
1158
  expiresOn: Schema.optional(Schema.Union([Schema.String, Schema.Null])),
2051
1159
  issuedOn: Schema.optional(Schema.Union([Schema.String, Schema.Null])),
2052
1160
  lastUsedOn: Schema.optional(Schema.Union([Schema.String, Schema.Null])),
2053
1161
  modifiedOn: Schema.optional(Schema.Union([Schema.String, Schema.Null])),
2054
1162
  name: Schema.optional(Schema.Union([Schema.String, Schema.Null])),
2055
1163
  notBefore: Schema.optional(Schema.Union([Schema.String, Schema.Null])),
2056
- policies: Schema.optional(Schema.Union([
2057
- Schema.Array(Schema.Struct({
1164
+ policies: Schema.optional(Schema.Union([Schema.Array(Schema.Struct({
2058
1165
  id: Schema.String,
2059
1166
  effect: Schema.Literals(["allow", "deny"]),
2060
1167
  permissionGroups: Schema.Array(Schema.Struct({
2061
1168
  id: Schema.String,
2062
- meta: Schema.optional(Schema.Union([
2063
- Schema.Struct({
1169
+ meta: Schema.optional(Schema.Union([Schema.Struct({
2064
1170
  key: Schema.optional(Schema.Union([Schema.String, Schema.Null])),
2065
- value: Schema.optional(Schema.Union([Schema.String, Schema.Null])),
2066
- }),
2067
- Schema.Null,
2068
- ])),
2069
- name: Schema.optional(Schema.Union([Schema.String, Schema.Null])),
1171
+ value: Schema.optional(Schema.Union([Schema.String, Schema.Null]))
1172
+ }), Schema.Null])),
1173
+ name: Schema.optional(Schema.Union([Schema.String, Schema.Null]))
2070
1174
  })),
2071
- resources: Schema.Record(Schema.String, Schema.Unknown),
2072
- }).pipe(Schema.encodeKeys({
2073
- id: "id",
2074
- effect: "effect",
2075
- permissionGroups: "permission_groups",
2076
- resources: "resources",
2077
- }))),
2078
- Schema.Null,
2079
- ])),
2080
- status: Schema.optional(Schema.Union([
2081
- Schema.Literals(["active", "disabled", "expired"]),
2082
- Schema.Null,
2083
- ])),
2084
- })
2085
- .pipe(Schema.encodeKeys({
2086
- id: "id",
2087
- condition: "condition",
2088
- expiresOn: "expires_on",
2089
- issuedOn: "issued_on",
2090
- lastUsedOn: "last_used_on",
2091
- modifiedOn: "modified_on",
2092
- name: "name",
2093
- notBefore: "not_before",
2094
- policies: "policies",
2095
- status: "status",
2096
- }))
2097
- .pipe(T.ResponsePath("result"));
1175
+ resources: Schema.Record(Schema.String, Schema.Unknown)
1176
+ }).pipe(Schema.encodeKeys({ id: "id", effect: "effect", permissionGroups: "permission_groups", resources: "resources" }))), Schema.Null])),
1177
+ status: Schema.optional(Schema.Union([Schema.Literals(["active", "disabled", "expired"]), Schema.Null]))
1178
+ }).pipe(Schema.encodeKeys({ id: "id", condition: "condition", expiresOn: "expires_on", issuedOn: "issued_on", lastUsedOn: "last_used_on", modifiedOn: "modified_on", name: "name", notBefore: "not_before", policies: "policies", status: "status" })).pipe(T.ResponsePath("result"));
2098
1179
  export const updateToken = /*@__PURE__*/ /*#__PURE__*/ API.make(() => ({
2099
1180
  input: UpdateTokenRequest,
2100
1181
  output: UpdateTokenResponse,
2101
- errors: [InvalidRoute, MethodNotAllowed],
1182
+ errors: [InvalidRoute, MethodNotAllowed, TokenNotFound, PermissionGroupNotFound],
2102
1183
  }));
2103
1184
  export const DeleteTokenRequest = /*@__PURE__*/ /*#__PURE__*/ Schema.Struct({
2104
1185
  tokenId: Schema.String.pipe(T.HttpPath("tokenId")),
2105
- accountId: Schema.String.pipe(T.HttpPath("account_id")),
2106
- }).pipe(T.Http({ method: "DELETE", path: "/accounts/{account_id}/tokens/{tokenId}" }));
1186
+ accountId: Schema.String.pipe(T.HttpPath("account_id"))
1187
+ })
1188
+ .pipe(T.Http({ method: "DELETE", path: "/accounts/{account_id}/tokens/{tokenId}" }));
2107
1189
  export const DeleteTokenResponse = /*@__PURE__*/ /*#__PURE__*/ Schema.Struct({
2108
- id: Schema.String,
1190
+ id: Schema.String
2109
1191
  }).pipe(T.ResponsePath("result"));
2110
1192
  export const deleteToken = /*@__PURE__*/ /*#__PURE__*/ API.make(() => ({
2111
1193
  input: DeleteTokenRequest,
2112
1194
  output: DeleteTokenResponse,
2113
- errors: [InvalidRoute, MethodNotAllowed],
1195
+ errors: [InvalidRoute, MethodNotAllowed, TokenNotFound],
2114
1196
  }));
2115
1197
  export const VerifyTokenRequest = /*@__PURE__*/ /*#__PURE__*/ Schema.Struct({
2116
- accountId: Schema.String.pipe(T.HttpPath("account_id")),
2117
- }).pipe(T.Http({ method: "GET", path: "/accounts/{account_id}/tokens/verify" }));
1198
+ accountId: Schema.String.pipe(T.HttpPath("account_id"))
1199
+ })
1200
+ .pipe(T.Http({ method: "GET", path: "/accounts/{account_id}/tokens/verify" }));
2118
1201
  export const VerifyTokenResponse = /*@__PURE__*/ /*#__PURE__*/ Schema.Struct({
2119
1202
  id: Schema.String,
2120
1203
  status: Schema.Literals(["active", "disabled", "expired"]),
2121
1204
  expiresOn: Schema.optional(Schema.Union([Schema.String, Schema.Null])),
2122
- notBefore: Schema.optional(Schema.Union([Schema.String, Schema.Null])),
2123
- })
2124
- .pipe(Schema.encodeKeys({
2125
- id: "id",
2126
- status: "status",
2127
- expiresOn: "expires_on",
2128
- notBefore: "not_before",
2129
- }))
2130
- .pipe(T.ResponsePath("result"));
1205
+ notBefore: Schema.optional(Schema.Union([Schema.String, Schema.Null]))
1206
+ }).pipe(Schema.encodeKeys({ id: "id", status: "status", expiresOn: "expires_on", notBefore: "not_before" })).pipe(T.ResponsePath("result"));
2131
1207
  export const verifyToken = /*@__PURE__*/ /*#__PURE__*/ API.make(() => ({
2132
1208
  input: VerifyTokenRequest,
2133
1209
  output: VerifyTokenResponse,
2134
1210
  errors: [MissingAuthenticationToken, InvalidRoute],
2135
1211
  }));
2136
- export const GetTokenPermissionGroupRequest =
2137
- /*@__PURE__*/ /*#__PURE__*/ Schema.Struct({
1212
+ export const GetTokenPermissionGroupRequest = /*@__PURE__*/ /*#__PURE__*/ Schema.Struct({
2138
1213
  accountId: Schema.String.pipe(T.HttpPath("account_id")),
2139
1214
  name: Schema.optional(Schema.String).pipe(T.HttpQuery("name")),
2140
- scope: Schema.optional(Schema.String).pipe(T.HttpQuery("scope")),
2141
- }).pipe(T.Http({
2142
- method: "GET",
2143
- path: "/accounts/{account_id}/tokens/permission_groups",
2144
- }));
2145
- export const GetTokenPermissionGroupResponse =
2146
- /*@__PURE__*/ /*#__PURE__*/ Schema.Array(Schema.Struct({
1215
+ scope: Schema.optional(Schema.String).pipe(T.HttpQuery("scope"))
1216
+ })
1217
+ .pipe(T.Http({ method: "GET", path: "/accounts/{account_id}/tokens/permission_groups" }));
1218
+ export const GetTokenPermissionGroupResponse = /*@__PURE__*/ /*#__PURE__*/ Schema.Array(Schema.Struct({
2147
1219
  id: Schema.optional(Schema.Union([Schema.String, Schema.Null])),
2148
1220
  name: Schema.optional(Schema.Union([Schema.String, Schema.Null])),
2149
- scopes: Schema.optional(Schema.Union([
2150
- Schema.Array(Schema.Literals([
2151
- "com.cloudflare.api.account",
2152
- "com.cloudflare.api.account.zone",
2153
- "com.cloudflare.api.user",
2154
- "com.cloudflare.edge.r2.bucket",
2155
- ])),
2156
- Schema.Null,
2157
- ])),
1221
+ scopes: Schema.optional(Schema.Union([Schema.Array(Schema.Literals(["com.cloudflare.api.account", "com.cloudflare.api.account.zone", "com.cloudflare.api.user", "com.cloudflare.edge.r2.bucket"])), Schema.Null]))
2158
1222
  })).pipe(T.ResponsePath("result"));
2159
1223
  export const getTokenPermissionGroup = /*@__PURE__*/ /*#__PURE__*/ API.make(() => ({
2160
1224
  input: GetTokenPermissionGroupRequest,
2161
1225
  output: GetTokenPermissionGroupResponse,
2162
1226
  errors: [InvalidRoute],
2163
1227
  }));
2164
- export const ListTokenPermissionGroupsRequest =
2165
- /*@__PURE__*/ /*#__PURE__*/ Schema.Struct({
1228
+ export const ListTokenPermissionGroupsRequest = /*@__PURE__*/ /*#__PURE__*/ Schema.Struct({
2166
1229
  accountId: Schema.String.pipe(T.HttpPath("account_id")),
2167
1230
  name: Schema.optional(Schema.String).pipe(T.HttpQuery("name")),
2168
- scope: Schema.optional(Schema.String).pipe(T.HttpQuery("scope")),
2169
- }).pipe(T.Http({
2170
- method: "GET",
2171
- path: "/accounts/{account_id}/tokens/permission_groups",
2172
- }));
2173
- export const ListTokenPermissionGroupsResponse =
2174
- /*@__PURE__*/ /*#__PURE__*/ Schema.Struct({
1231
+ scope: Schema.optional(Schema.String).pipe(T.HttpQuery("scope"))
1232
+ })
1233
+ .pipe(T.Http({ method: "GET", path: "/accounts/{account_id}/tokens/permission_groups" }));
1234
+ export const ListTokenPermissionGroupsResponse = /*@__PURE__*/ /*#__PURE__*/ Schema.Struct({
2175
1235
  result: Schema.Array(Schema.Struct({
2176
1236
  id: Schema.optional(Schema.Union([Schema.String, Schema.Null])),
2177
1237
  name: Schema.optional(Schema.Union([Schema.String, Schema.Null])),
2178
- scopes: Schema.optional(Schema.Union([
2179
- Schema.Array(Schema.Literals([
2180
- "com.cloudflare.api.account",
2181
- "com.cloudflare.api.account.zone",
2182
- "com.cloudflare.api.user",
2183
- "com.cloudflare.edge.r2.bucket",
2184
- ])),
2185
- Schema.Null,
2186
- ])),
2187
- })),
1238
+ scopes: Schema.optional(Schema.Union([Schema.Array(Schema.Literals(["com.cloudflare.api.account", "com.cloudflare.api.account.zone", "com.cloudflare.api.user", "com.cloudflare.edge.r2.bucket"])), Schema.Null]))
1239
+ }))
2188
1240
  });
2189
1241
  export const listTokenPermissionGroups = /*@__PURE__*/ /*#__PURE__*/ API.makePaginated(() => ({
2190
1242
  input: ListTokenPermissionGroupsRequest,
@@ -2198,16 +1250,13 @@ export const listTokenPermissionGroups = /*@__PURE__*/ /*#__PURE__*/ API.makePag
2198
1250
  export const PutTokenValueRequest = /*@__PURE__*/ /*#__PURE__*/ Schema.Struct({
2199
1251
  tokenId: Schema.String.pipe(T.HttpPath("tokenId")),
2200
1252
  accountId: Schema.String.pipe(T.HttpPath("account_id")),
2201
- body: Schema.Unknown.pipe(T.HttpBody()),
2202
- }).pipe(T.Http({
2203
- method: "PUT",
2204
- path: "/accounts/{account_id}/tokens/{tokenId}/value",
2205
- }));
2206
- export const PutTokenValueResponse =
2207
- /*@__PURE__*/ /*#__PURE__*/ Schema.String.pipe(T.ResponsePath("result"));
1253
+ body: Schema.Unknown.pipe(T.HttpBody())
1254
+ })
1255
+ .pipe(T.Http({ method: "PUT", path: "/accounts/{account_id}/tokens/{tokenId}/value" }));
1256
+ export const PutTokenValueResponse = /*@__PURE__*/ /*#__PURE__*/ Schema.String.pipe(T.ResponsePath("result"));
2208
1257
  export const putTokenValue = /*@__PURE__*/ /*#__PURE__*/ API.make(() => ({
2209
1258
  input: PutTokenValueRequest,
2210
1259
  output: PutTokenValueResponse,
2211
- errors: [InvalidRoute],
1260
+ errors: [InvalidRoute, TokenNotFound],
2212
1261
  }));
2213
1262
  //# sourceMappingURL=accounts.js.map