@scaleway/sdk-lb 2.3.1 → 2.4.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1,1300 +1,967 @@
1
+ import { isJSONObject, resolveOneOf, unmarshalArrayOfObject, unmarshalDate } from "@scaleway/sdk-client";
1
2
  import randomName from "@scaleway/random-name";
2
- import { resolveOneOf, isJSONObject, unmarshalArrayOfObject, unmarshalDate } from "@scaleway/sdk-client";
3
3
  const unmarshalIp = (data) => {
4
- if (!isJSONObject(data)) {
5
- throw new TypeError(
6
- `Unmarshalling the type 'Ip' failed as data isn't a dictionary.`
7
- );
8
- }
9
- return {
10
- id: data.id,
11
- ipAddress: data.ip_address,
12
- lbId: data.lb_id,
13
- organizationId: data.organization_id,
14
- projectId: data.project_id,
15
- region: data.region,
16
- reverse: data.reverse,
17
- tags: data.tags,
18
- zone: data.zone
19
- };
20
- };
21
- const unmarshalSubscriberEmailConfig = (data) => {
22
- if (!isJSONObject(data)) {
23
- throw new TypeError(
24
- `Unmarshalling the type 'SubscriberEmailConfig' failed as data isn't a dictionary.`
25
- );
26
- }
27
- return {
28
- email: data.email
29
- };
30
- };
31
- const unmarshalSubscriberWebhookConfig = (data) => {
32
- if (!isJSONObject(data)) {
33
- throw new TypeError(
34
- `Unmarshalling the type 'SubscriberWebhookConfig' failed as data isn't a dictionary.`
35
- );
36
- }
37
- return {
38
- uri: data.uri
39
- };
4
+ if (!isJSONObject(data)) throw new TypeError(`Unmarshalling the type 'Ip' failed as data isn't a dictionary.`);
5
+ return {
6
+ id: data.id,
7
+ ipAddress: data.ip_address,
8
+ lbId: data.lb_id,
9
+ organizationId: data.organization_id,
10
+ projectId: data.project_id,
11
+ region: data.region,
12
+ reverse: data.reverse,
13
+ tags: data.tags,
14
+ zone: data.zone
15
+ };
16
+ };
17
+ var unmarshalSubscriberEmailConfig = (data) => {
18
+ if (!isJSONObject(data)) throw new TypeError(`Unmarshalling the type 'SubscriberEmailConfig' failed as data isn't a dictionary.`);
19
+ return { email: data.email };
20
+ };
21
+ var unmarshalSubscriberWebhookConfig = (data) => {
22
+ if (!isJSONObject(data)) throw new TypeError(`Unmarshalling the type 'SubscriberWebhookConfig' failed as data isn't a dictionary.`);
23
+ return { uri: data.uri };
40
24
  };
41
25
  const unmarshalSubscriber = (data) => {
42
- if (!isJSONObject(data)) {
43
- throw new TypeError(
44
- `Unmarshalling the type 'Subscriber' failed as data isn't a dictionary.`
45
- );
46
- }
47
- return {
48
- emailConfig: data.email_config ? unmarshalSubscriberEmailConfig(data.email_config) : void 0,
49
- id: data.id,
50
- name: data.name,
51
- webhookConfig: data.webhook_config ? unmarshalSubscriberWebhookConfig(data.webhook_config) : void 0
52
- };
53
- };
54
- const unmarshalHealthCheckHttpConfig = (data) => {
55
- if (!isJSONObject(data)) {
56
- throw new TypeError(
57
- `Unmarshalling the type 'HealthCheckHttpConfig' failed as data isn't a dictionary.`
58
- );
59
- }
60
- return {
61
- code: data.code,
62
- hostHeader: data.host_header,
63
- method: data.method,
64
- uri: data.uri
65
- };
66
- };
67
- const unmarshalHealthCheckHttpsConfig = (data) => {
68
- if (!isJSONObject(data)) {
69
- throw new TypeError(
70
- `Unmarshalling the type 'HealthCheckHttpsConfig' failed as data isn't a dictionary.`
71
- );
72
- }
73
- return {
74
- code: data.code,
75
- hostHeader: data.host_header,
76
- method: data.method,
77
- sni: data.sni,
78
- uri: data.uri
79
- };
80
- };
81
- const unmarshalHealthCheckLdapConfig = (data) => {
82
- if (!isJSONObject(data)) {
83
- throw new TypeError(
84
- `Unmarshalling the type 'HealthCheckLdapConfig' failed as data isn't a dictionary.`
85
- );
86
- }
87
- return {};
88
- };
89
- const unmarshalHealthCheckMysqlConfig = (data) => {
90
- if (!isJSONObject(data)) {
91
- throw new TypeError(
92
- `Unmarshalling the type 'HealthCheckMysqlConfig' failed as data isn't a dictionary.`
93
- );
94
- }
95
- return {
96
- user: data.user
97
- };
98
- };
99
- const unmarshalHealthCheckPgsqlConfig = (data) => {
100
- if (!isJSONObject(data)) {
101
- throw new TypeError(
102
- `Unmarshalling the type 'HealthCheckPgsqlConfig' failed as data isn't a dictionary.`
103
- );
104
- }
105
- return {
106
- user: data.user
107
- };
108
- };
109
- const unmarshalHealthCheckRedisConfig = (data) => {
110
- if (!isJSONObject(data)) {
111
- throw new TypeError(
112
- `Unmarshalling the type 'HealthCheckRedisConfig' failed as data isn't a dictionary.`
113
- );
114
- }
115
- return {};
116
- };
117
- const unmarshalHealthCheckTcpConfig = (data) => {
118
- if (!isJSONObject(data)) {
119
- throw new TypeError(
120
- `Unmarshalling the type 'HealthCheckTcpConfig' failed as data isn't a dictionary.`
121
- );
122
- }
123
- return {};
26
+ if (!isJSONObject(data)) throw new TypeError(`Unmarshalling the type 'Subscriber' failed as data isn't a dictionary.`);
27
+ return {
28
+ emailConfig: data.email_config ? unmarshalSubscriberEmailConfig(data.email_config) : void 0,
29
+ id: data.id,
30
+ name: data.name,
31
+ webhookConfig: data.webhook_config ? unmarshalSubscriberWebhookConfig(data.webhook_config) : void 0
32
+ };
33
+ };
34
+ var unmarshalHealthCheckHttpConfig = (data) => {
35
+ if (!isJSONObject(data)) throw new TypeError(`Unmarshalling the type 'HealthCheckHttpConfig' failed as data isn't a dictionary.`);
36
+ return {
37
+ code: data.code,
38
+ hostHeader: data.host_header,
39
+ method: data.method,
40
+ uri: data.uri
41
+ };
42
+ };
43
+ var unmarshalHealthCheckHttpsConfig = (data) => {
44
+ if (!isJSONObject(data)) throw new TypeError(`Unmarshalling the type 'HealthCheckHttpsConfig' failed as data isn't a dictionary.`);
45
+ return {
46
+ code: data.code,
47
+ hostHeader: data.host_header,
48
+ method: data.method,
49
+ sni: data.sni,
50
+ uri: data.uri
51
+ };
52
+ };
53
+ var unmarshalHealthCheckLdapConfig = (data) => {
54
+ if (!isJSONObject(data)) throw new TypeError(`Unmarshalling the type 'HealthCheckLdapConfig' failed as data isn't a dictionary.`);
55
+ return {};
56
+ };
57
+ var unmarshalHealthCheckMysqlConfig = (data) => {
58
+ if (!isJSONObject(data)) throw new TypeError(`Unmarshalling the type 'HealthCheckMysqlConfig' failed as data isn't a dictionary.`);
59
+ return { user: data.user };
60
+ };
61
+ var unmarshalHealthCheckPgsqlConfig = (data) => {
62
+ if (!isJSONObject(data)) throw new TypeError(`Unmarshalling the type 'HealthCheckPgsqlConfig' failed as data isn't a dictionary.`);
63
+ return { user: data.user };
64
+ };
65
+ var unmarshalHealthCheckRedisConfig = (data) => {
66
+ if (!isJSONObject(data)) throw new TypeError(`Unmarshalling the type 'HealthCheckRedisConfig' failed as data isn't a dictionary.`);
67
+ return {};
68
+ };
69
+ var unmarshalHealthCheckTcpConfig = (data) => {
70
+ if (!isJSONObject(data)) throw new TypeError(`Unmarshalling the type 'HealthCheckTcpConfig' failed as data isn't a dictionary.`);
71
+ return {};
124
72
  };
125
73
  const unmarshalHealthCheck = (data) => {
126
- if (!isJSONObject(data)) {
127
- throw new TypeError(
128
- `Unmarshalling the type 'HealthCheck' failed as data isn't a dictionary.`
129
- );
130
- }
131
- return {
132
- checkDelay: data.check_delay,
133
- checkMaxRetries: data.check_max_retries,
134
- checkSendProxy: data.check_send_proxy,
135
- checkTimeout: data.check_timeout,
136
- httpConfig: data.http_config ? unmarshalHealthCheckHttpConfig(data.http_config) : void 0,
137
- httpsConfig: data.https_config ? unmarshalHealthCheckHttpsConfig(data.https_config) : void 0,
138
- ldapConfig: data.ldap_config ? unmarshalHealthCheckLdapConfig(data.ldap_config) : void 0,
139
- mysqlConfig: data.mysql_config ? unmarshalHealthCheckMysqlConfig(data.mysql_config) : void 0,
140
- pgsqlConfig: data.pgsql_config ? unmarshalHealthCheckPgsqlConfig(data.pgsql_config) : void 0,
141
- port: data.port,
142
- redisConfig: data.redis_config ? unmarshalHealthCheckRedisConfig(data.redis_config) : void 0,
143
- tcpConfig: data.tcp_config ? unmarshalHealthCheckTcpConfig(data.tcp_config) : void 0,
144
- transientCheckDelay: data.transient_check_delay
145
- };
146
- };
147
- const unmarshalInstance = (data) => {
148
- if (!isJSONObject(data)) {
149
- throw new TypeError(
150
- `Unmarshalling the type 'Instance' failed as data isn't a dictionary.`
151
- );
152
- }
153
- return {
154
- createdAt: unmarshalDate(data.created_at),
155
- id: data.id,
156
- ipAddress: data.ip_address,
157
- region: data.region,
158
- status: data.status,
159
- updatedAt: unmarshalDate(data.updated_at),
160
- zone: data.zone
161
- };
74
+ if (!isJSONObject(data)) throw new TypeError(`Unmarshalling the type 'HealthCheck' failed as data isn't a dictionary.`);
75
+ return {
76
+ checkDelay: data.check_delay,
77
+ checkMaxRetries: data.check_max_retries,
78
+ checkSendProxy: data.check_send_proxy,
79
+ checkTimeout: data.check_timeout,
80
+ httpConfig: data.http_config ? unmarshalHealthCheckHttpConfig(data.http_config) : void 0,
81
+ httpsConfig: data.https_config ? unmarshalHealthCheckHttpsConfig(data.https_config) : void 0,
82
+ ldapConfig: data.ldap_config ? unmarshalHealthCheckLdapConfig(data.ldap_config) : void 0,
83
+ mysqlConfig: data.mysql_config ? unmarshalHealthCheckMysqlConfig(data.mysql_config) : void 0,
84
+ pgsqlConfig: data.pgsql_config ? unmarshalHealthCheckPgsqlConfig(data.pgsql_config) : void 0,
85
+ port: data.port,
86
+ redisConfig: data.redis_config ? unmarshalHealthCheckRedisConfig(data.redis_config) : void 0,
87
+ tcpConfig: data.tcp_config ? unmarshalHealthCheckTcpConfig(data.tcp_config) : void 0,
88
+ transientCheckDelay: data.transient_check_delay
89
+ };
90
+ };
91
+ var unmarshalInstance = (data) => {
92
+ if (!isJSONObject(data)) throw new TypeError(`Unmarshalling the type 'Instance' failed as data isn't a dictionary.`);
93
+ return {
94
+ createdAt: unmarshalDate(data.created_at),
95
+ id: data.id,
96
+ ipAddress: data.ip_address,
97
+ region: data.region,
98
+ status: data.status,
99
+ updatedAt: unmarshalDate(data.updated_at),
100
+ zone: data.zone
101
+ };
162
102
  };
163
103
  const unmarshalLb = (data) => {
164
- if (!isJSONObject(data)) {
165
- throw new TypeError(
166
- `Unmarshalling the type 'Lb' failed as data isn't a dictionary.`
167
- );
168
- }
169
- return {
170
- backendCount: data.backend_count,
171
- createdAt: unmarshalDate(data.created_at),
172
- description: data.description,
173
- frontendCount: data.frontend_count,
174
- id: data.id,
175
- instances: unmarshalArrayOfObject(data.instances, unmarshalInstance),
176
- ip: unmarshalArrayOfObject(data.ip, unmarshalIp),
177
- name: data.name,
178
- organizationId: data.organization_id,
179
- privateNetworkCount: data.private_network_count,
180
- projectId: data.project_id,
181
- region: data.region,
182
- routeCount: data.route_count,
183
- sslCompatibilityLevel: data.ssl_compatibility_level,
184
- status: data.status,
185
- subscriber: data.subscriber ? unmarshalSubscriber(data.subscriber) : void 0,
186
- tags: data.tags,
187
- type: data.type,
188
- updatedAt: unmarshalDate(data.updated_at),
189
- zone: data.zone
190
- };
104
+ if (!isJSONObject(data)) throw new TypeError(`Unmarshalling the type 'Lb' failed as data isn't a dictionary.`);
105
+ return {
106
+ backendCount: data.backend_count,
107
+ createdAt: unmarshalDate(data.created_at),
108
+ description: data.description,
109
+ frontendCount: data.frontend_count,
110
+ id: data.id,
111
+ instances: unmarshalArrayOfObject(data.instances, unmarshalInstance),
112
+ ip: unmarshalArrayOfObject(data.ip, unmarshalIp),
113
+ name: data.name,
114
+ organizationId: data.organization_id,
115
+ privateNetworkCount: data.private_network_count,
116
+ projectId: data.project_id,
117
+ region: data.region,
118
+ routeCount: data.route_count,
119
+ sslCompatibilityLevel: data.ssl_compatibility_level,
120
+ status: data.status,
121
+ subscriber: data.subscriber ? unmarshalSubscriber(data.subscriber) : void 0,
122
+ tags: data.tags,
123
+ type: data.type,
124
+ updatedAt: unmarshalDate(data.updated_at),
125
+ zone: data.zone
126
+ };
191
127
  };
192
128
  const unmarshalBackend = (data) => {
193
- if (!isJSONObject(data)) {
194
- throw new TypeError(
195
- `Unmarshalling the type 'Backend' failed as data isn't a dictionary.`
196
- );
197
- }
198
- return {
199
- createdAt: unmarshalDate(data.created_at),
200
- failoverHost: data.failover_host,
201
- forwardPort: data.forward_port,
202
- forwardPortAlgorithm: data.forward_port_algorithm,
203
- forwardProtocol: data.forward_protocol,
204
- healthCheck: data.health_check ? unmarshalHealthCheck(data.health_check) : void 0,
205
- id: data.id,
206
- ignoreSslServerVerify: data.ignore_ssl_server_verify,
207
- lb: data.lb ? unmarshalLb(data.lb) : void 0,
208
- maxConnections: data.max_connections,
209
- maxRetries: data.max_retries,
210
- name: data.name,
211
- onMarkedDownAction: data.on_marked_down_action,
212
- pool: data.pool,
213
- proxyProtocol: data.proxy_protocol,
214
- redispatchAttemptCount: data.redispatch_attempt_count,
215
- sendProxyV2: data.send_proxy_v2,
216
- sslBridging: data.ssl_bridging,
217
- stickySessions: data.sticky_sessions,
218
- stickySessionsCookieName: data.sticky_sessions_cookie_name,
219
- timeoutConnect: data.timeout_connect,
220
- timeoutQueue: data.timeout_queue,
221
- timeoutServer: data.timeout_server,
222
- timeoutTunnel: data.timeout_tunnel,
223
- updatedAt: unmarshalDate(data.updated_at)
224
- };
129
+ if (!isJSONObject(data)) throw new TypeError(`Unmarshalling the type 'Backend' failed as data isn't a dictionary.`);
130
+ return {
131
+ createdAt: unmarshalDate(data.created_at),
132
+ failoverHost: data.failover_host,
133
+ forwardPort: data.forward_port,
134
+ forwardPortAlgorithm: data.forward_port_algorithm,
135
+ forwardProtocol: data.forward_protocol,
136
+ healthCheck: data.health_check ? unmarshalHealthCheck(data.health_check) : void 0,
137
+ id: data.id,
138
+ ignoreSslServerVerify: data.ignore_ssl_server_verify,
139
+ lb: data.lb ? unmarshalLb(data.lb) : void 0,
140
+ maxConnections: data.max_connections,
141
+ maxRetries: data.max_retries,
142
+ name: data.name,
143
+ onMarkedDownAction: data.on_marked_down_action,
144
+ pool: data.pool,
145
+ proxyProtocol: data.proxy_protocol,
146
+ redispatchAttemptCount: data.redispatch_attempt_count,
147
+ sendProxyV2: data.send_proxy_v2,
148
+ sslBridging: data.ssl_bridging,
149
+ stickySessions: data.sticky_sessions,
150
+ stickySessionsCookieName: data.sticky_sessions_cookie_name,
151
+ timeoutConnect: data.timeout_connect,
152
+ timeoutQueue: data.timeout_queue,
153
+ timeoutServer: data.timeout_server,
154
+ timeoutTunnel: data.timeout_tunnel,
155
+ updatedAt: unmarshalDate(data.updated_at)
156
+ };
225
157
  };
226
158
  const unmarshalCertificate = (data) => {
227
- if (!isJSONObject(data)) {
228
- throw new TypeError(
229
- `Unmarshalling the type 'Certificate' failed as data isn't a dictionary.`
230
- );
231
- }
232
- return {
233
- commonName: data.common_name,
234
- createdAt: unmarshalDate(data.created_at),
235
- fingerprint: data.fingerprint,
236
- id: data.id,
237
- lb: data.lb ? unmarshalLb(data.lb) : void 0,
238
- name: data.name,
239
- notValidAfter: unmarshalDate(data.not_valid_after),
240
- notValidBefore: unmarshalDate(data.not_valid_before),
241
- status: data.status,
242
- statusDetails: data.status_details,
243
- subjectAlternativeName: data.subject_alternative_name,
244
- type: data.type,
245
- updatedAt: unmarshalDate(data.updated_at)
246
- };
159
+ if (!isJSONObject(data)) throw new TypeError(`Unmarshalling the type 'Certificate' failed as data isn't a dictionary.`);
160
+ return {
161
+ commonName: data.common_name,
162
+ createdAt: unmarshalDate(data.created_at),
163
+ fingerprint: data.fingerprint,
164
+ id: data.id,
165
+ lb: data.lb ? unmarshalLb(data.lb) : void 0,
166
+ name: data.name,
167
+ notValidAfter: unmarshalDate(data.not_valid_after),
168
+ notValidBefore: unmarshalDate(data.not_valid_before),
169
+ status: data.status,
170
+ statusDetails: data.status_details,
171
+ subjectAlternativeName: data.subject_alternative_name,
172
+ type: data.type,
173
+ updatedAt: unmarshalDate(data.updated_at)
174
+ };
247
175
  };
248
176
  const unmarshalFrontend = (data) => {
249
- if (!isJSONObject(data)) {
250
- throw new TypeError(
251
- `Unmarshalling the type 'Frontend' failed as data isn't a dictionary.`
252
- );
253
- }
254
- return {
255
- backend: data.backend ? unmarshalBackend(data.backend) : void 0,
256
- certificate: data.certificate ? unmarshalCertificate(data.certificate) : void 0,
257
- certificateIds: data.certificate_ids,
258
- connectionRateLimit: data.connection_rate_limit,
259
- createdAt: unmarshalDate(data.created_at),
260
- enableAccessLogs: data.enable_access_logs,
261
- enableHttp3: data.enable_http3,
262
- id: data.id,
263
- inboundPort: data.inbound_port,
264
- lb: data.lb ? unmarshalLb(data.lb) : void 0,
265
- name: data.name,
266
- timeoutClient: data.timeout_client,
267
- updatedAt: unmarshalDate(data.updated_at)
268
- };
269
- };
270
- const unmarshalAclActionRedirect = (data) => {
271
- if (!isJSONObject(data)) {
272
- throw new TypeError(
273
- `Unmarshalling the type 'AclActionRedirect' failed as data isn't a dictionary.`
274
- );
275
- }
276
- return {
277
- code: data.code,
278
- target: data.target,
279
- type: data.type
280
- };
281
- };
282
- const unmarshalAclAction = (data) => {
283
- if (!isJSONObject(data)) {
284
- throw new TypeError(
285
- `Unmarshalling the type 'AclAction' failed as data isn't a dictionary.`
286
- );
287
- }
288
- return {
289
- redirect: data.redirect ? unmarshalAclActionRedirect(data.redirect) : void 0,
290
- type: data.type
291
- };
292
- };
293
- const unmarshalAclMatch = (data) => {
294
- if (!isJSONObject(data)) {
295
- throw new TypeError(
296
- `Unmarshalling the type 'AclMatch' failed as data isn't a dictionary.`
297
- );
298
- }
299
- return {
300
- httpFilter: data.http_filter,
301
- httpFilterOption: data.http_filter_option,
302
- httpFilterValue: data.http_filter_value,
303
- invert: data.invert,
304
- ipSubnet: data.ip_subnet,
305
- ipsEdgeServices: data.ips_edge_services
306
- };
177
+ if (!isJSONObject(data)) throw new TypeError(`Unmarshalling the type 'Frontend' failed as data isn't a dictionary.`);
178
+ return {
179
+ backend: data.backend ? unmarshalBackend(data.backend) : void 0,
180
+ certificate: data.certificate ? unmarshalCertificate(data.certificate) : void 0,
181
+ certificateIds: data.certificate_ids,
182
+ connectionRateLimit: data.connection_rate_limit,
183
+ createdAt: unmarshalDate(data.created_at),
184
+ enableAccessLogs: data.enable_access_logs,
185
+ enableHttp3: data.enable_http3,
186
+ id: data.id,
187
+ inboundPort: data.inbound_port,
188
+ lb: data.lb ? unmarshalLb(data.lb) : void 0,
189
+ name: data.name,
190
+ timeoutClient: data.timeout_client,
191
+ updatedAt: unmarshalDate(data.updated_at)
192
+ };
193
+ };
194
+ var unmarshalAclActionRedirect = (data) => {
195
+ if (!isJSONObject(data)) throw new TypeError(`Unmarshalling the type 'AclActionRedirect' failed as data isn't a dictionary.`);
196
+ return {
197
+ code: data.code,
198
+ target: data.target,
199
+ type: data.type
200
+ };
201
+ };
202
+ var unmarshalAclAction = (data) => {
203
+ if (!isJSONObject(data)) throw new TypeError(`Unmarshalling the type 'AclAction' failed as data isn't a dictionary.`);
204
+ return {
205
+ redirect: data.redirect ? unmarshalAclActionRedirect(data.redirect) : void 0,
206
+ type: data.type
207
+ };
208
+ };
209
+ var unmarshalAclMatch = (data) => {
210
+ if (!isJSONObject(data)) throw new TypeError(`Unmarshalling the type 'AclMatch' failed as data isn't a dictionary.`);
211
+ return {
212
+ httpFilter: data.http_filter,
213
+ httpFilterOption: data.http_filter_option,
214
+ httpFilterValue: data.http_filter_value,
215
+ invert: data.invert,
216
+ ipSubnet: data.ip_subnet,
217
+ ipsEdgeServices: data.ips_edge_services
218
+ };
307
219
  };
308
220
  const unmarshalAcl = (data) => {
309
- if (!isJSONObject(data)) {
310
- throw new TypeError(
311
- `Unmarshalling the type 'Acl' failed as data isn't a dictionary.`
312
- );
313
- }
314
- return {
315
- action: data.action ? unmarshalAclAction(data.action) : void 0,
316
- createdAt: unmarshalDate(data.created_at),
317
- description: data.description,
318
- frontend: data.frontend ? unmarshalFrontend(data.frontend) : void 0,
319
- id: data.id,
320
- index: data.index,
321
- match: data.match ? unmarshalAclMatch(data.match) : void 0,
322
- name: data.name,
323
- updatedAt: unmarshalDate(data.updated_at)
324
- };
325
- };
326
- const unmarshalPrivateNetworkDHCPConfig = (data) => {
327
- if (!isJSONObject(data)) {
328
- throw new TypeError(
329
- `Unmarshalling the type 'PrivateNetworkDHCPConfig' failed as data isn't a dictionary.`
330
- );
331
- }
332
- return {
333
- ipId: data.ip_id
334
- };
335
- };
336
- const unmarshalPrivateNetworkIpamConfig = (data) => {
337
- if (!isJSONObject(data)) {
338
- throw new TypeError(
339
- `Unmarshalling the type 'PrivateNetworkIpamConfig' failed as data isn't a dictionary.`
340
- );
341
- }
342
- return {};
343
- };
344
- const unmarshalPrivateNetworkStaticConfig = (data) => {
345
- if (!isJSONObject(data)) {
346
- throw new TypeError(
347
- `Unmarshalling the type 'PrivateNetworkStaticConfig' failed as data isn't a dictionary.`
348
- );
349
- }
350
- return {
351
- ipAddress: data.ip_address ? data.ip_address : void 0
352
- };
221
+ if (!isJSONObject(data)) throw new TypeError(`Unmarshalling the type 'Acl' failed as data isn't a dictionary.`);
222
+ return {
223
+ action: data.action ? unmarshalAclAction(data.action) : void 0,
224
+ createdAt: unmarshalDate(data.created_at),
225
+ description: data.description,
226
+ frontend: data.frontend ? unmarshalFrontend(data.frontend) : void 0,
227
+ id: data.id,
228
+ index: data.index,
229
+ match: data.match ? unmarshalAclMatch(data.match) : void 0,
230
+ name: data.name,
231
+ updatedAt: unmarshalDate(data.updated_at)
232
+ };
233
+ };
234
+ var unmarshalPrivateNetworkDHCPConfig = (data) => {
235
+ if (!isJSONObject(data)) throw new TypeError(`Unmarshalling the type 'PrivateNetworkDHCPConfig' failed as data isn't a dictionary.`);
236
+ return { ipId: data.ip_id };
237
+ };
238
+ var unmarshalPrivateNetworkIpamConfig = (data) => {
239
+ if (!isJSONObject(data)) throw new TypeError(`Unmarshalling the type 'PrivateNetworkIpamConfig' failed as data isn't a dictionary.`);
240
+ return {};
241
+ };
242
+ var unmarshalPrivateNetworkStaticConfig = (data) => {
243
+ if (!isJSONObject(data)) throw new TypeError(`Unmarshalling the type 'PrivateNetworkStaticConfig' failed as data isn't a dictionary.`);
244
+ return { ipAddress: data.ip_address ? data.ip_address : void 0 };
353
245
  };
354
246
  const unmarshalPrivateNetwork = (data) => {
355
- if (!isJSONObject(data)) {
356
- throw new TypeError(
357
- `Unmarshalling the type 'PrivateNetwork' failed as data isn't a dictionary.`
358
- );
359
- }
360
- return {
361
- createdAt: unmarshalDate(data.created_at),
362
- dhcpConfig: data.dhcp_config ? unmarshalPrivateNetworkDHCPConfig(data.dhcp_config) : void 0,
363
- ipamConfig: data.ipam_config ? unmarshalPrivateNetworkIpamConfig(data.ipam_config) : void 0,
364
- ipamIds: data.ipam_ids,
365
- lb: data.lb ? unmarshalLb(data.lb) : void 0,
366
- privateNetworkId: data.private_network_id,
367
- staticConfig: data.static_config ? unmarshalPrivateNetworkStaticConfig(data.static_config) : void 0,
368
- status: data.status,
369
- updatedAt: unmarshalDate(data.updated_at)
370
- };
371
- };
372
- const unmarshalRouteMatch = (data) => {
373
- if (!isJSONObject(data)) {
374
- throw new TypeError(
375
- `Unmarshalling the type 'RouteMatch' failed as data isn't a dictionary.`
376
- );
377
- }
378
- return {
379
- hostHeader: data.host_header,
380
- matchSubdomains: data.match_subdomains,
381
- pathBegin: data.path_begin,
382
- sni: data.sni
383
- };
247
+ if (!isJSONObject(data)) throw new TypeError(`Unmarshalling the type 'PrivateNetwork' failed as data isn't a dictionary.`);
248
+ return {
249
+ createdAt: unmarshalDate(data.created_at),
250
+ dhcpConfig: data.dhcp_config ? unmarshalPrivateNetworkDHCPConfig(data.dhcp_config) : void 0,
251
+ ipamConfig: data.ipam_config ? unmarshalPrivateNetworkIpamConfig(data.ipam_config) : void 0,
252
+ ipamIds: data.ipam_ids,
253
+ lb: data.lb ? unmarshalLb(data.lb) : void 0,
254
+ privateNetworkId: data.private_network_id,
255
+ staticConfig: data.static_config ? unmarshalPrivateNetworkStaticConfig(data.static_config) : void 0,
256
+ status: data.status,
257
+ updatedAt: unmarshalDate(data.updated_at)
258
+ };
259
+ };
260
+ var unmarshalRouteMatch = (data) => {
261
+ if (!isJSONObject(data)) throw new TypeError(`Unmarshalling the type 'RouteMatch' failed as data isn't a dictionary.`);
262
+ return {
263
+ hostHeader: data.host_header,
264
+ matchSubdomains: data.match_subdomains,
265
+ pathBegin: data.path_begin,
266
+ sni: data.sni
267
+ };
384
268
  };
385
269
  const unmarshalRoute = (data) => {
386
- if (!isJSONObject(data)) {
387
- throw new TypeError(
388
- `Unmarshalling the type 'Route' failed as data isn't a dictionary.`
389
- );
390
- }
391
- return {
392
- backendId: data.backend_id,
393
- createdAt: unmarshalDate(data.created_at),
394
- frontendId: data.frontend_id,
395
- id: data.id,
396
- match: data.match ? unmarshalRouteMatch(data.match) : void 0,
397
- updatedAt: unmarshalDate(data.updated_at)
398
- };
270
+ if (!isJSONObject(data)) throw new TypeError(`Unmarshalling the type 'Route' failed as data isn't a dictionary.`);
271
+ return {
272
+ backendId: data.backend_id,
273
+ createdAt: unmarshalDate(data.created_at),
274
+ frontendId: data.frontend_id,
275
+ id: data.id,
276
+ match: data.match ? unmarshalRouteMatch(data.match) : void 0,
277
+ updatedAt: unmarshalDate(data.updated_at)
278
+ };
399
279
  };
400
280
  const unmarshalBackendServerStats = (data) => {
401
- if (!isJSONObject(data)) {
402
- throw new TypeError(
403
- `Unmarshalling the type 'BackendServerStats' failed as data isn't a dictionary.`
404
- );
405
- }
406
- return {
407
- backendId: data.backend_id,
408
- instanceId: data.instance_id,
409
- ip: data.ip,
410
- lastHealthCheckStatus: data.last_health_check_status,
411
- serverState: data.server_state,
412
- serverStateChangedAt: unmarshalDate(data.server_state_changed_at)
413
- };
281
+ if (!isJSONObject(data)) throw new TypeError(`Unmarshalling the type 'BackendServerStats' failed as data isn't a dictionary.`);
282
+ return {
283
+ backendId: data.backend_id,
284
+ instanceId: data.instance_id,
285
+ ip: data.ip,
286
+ lastHealthCheckStatus: data.last_health_check_status,
287
+ serverState: data.server_state,
288
+ serverStateChangedAt: unmarshalDate(data.server_state_changed_at)
289
+ };
414
290
  };
415
291
  const unmarshalLbStats = (data) => {
416
- if (!isJSONObject(data)) {
417
- throw new TypeError(
418
- `Unmarshalling the type 'LbStats' failed as data isn't a dictionary.`
419
- );
420
- }
421
- return {
422
- backendServersStats: unmarshalArrayOfObject(data.backend_servers_stats, unmarshalBackendServerStats)
423
- };
292
+ if (!isJSONObject(data)) throw new TypeError(`Unmarshalling the type 'LbStats' failed as data isn't a dictionary.`);
293
+ return { backendServersStats: unmarshalArrayOfObject(data.backend_servers_stats, unmarshalBackendServerStats) };
424
294
  };
425
295
  const unmarshalListAclResponse = (data) => {
426
- if (!isJSONObject(data)) {
427
- throw new TypeError(
428
- `Unmarshalling the type 'ListAclResponse' failed as data isn't a dictionary.`
429
- );
430
- }
431
- return {
432
- acls: unmarshalArrayOfObject(data.acls, unmarshalAcl),
433
- totalCount: data.total_count
434
- };
296
+ if (!isJSONObject(data)) throw new TypeError(`Unmarshalling the type 'ListAclResponse' failed as data isn't a dictionary.`);
297
+ return {
298
+ acls: unmarshalArrayOfObject(data.acls, unmarshalAcl),
299
+ totalCount: data.total_count
300
+ };
435
301
  };
436
302
  const unmarshalListBackendStatsResponse = (data) => {
437
- if (!isJSONObject(data)) {
438
- throw new TypeError(
439
- `Unmarshalling the type 'ListBackendStatsResponse' failed as data isn't a dictionary.`
440
- );
441
- }
442
- return {
443
- backendServersStats: unmarshalArrayOfObject(data.backend_servers_stats, unmarshalBackendServerStats),
444
- totalCount: data.total_count
445
- };
303
+ if (!isJSONObject(data)) throw new TypeError(`Unmarshalling the type 'ListBackendStatsResponse' failed as data isn't a dictionary.`);
304
+ return {
305
+ backendServersStats: unmarshalArrayOfObject(data.backend_servers_stats, unmarshalBackendServerStats),
306
+ totalCount: data.total_count
307
+ };
446
308
  };
447
309
  const unmarshalListBackendsResponse = (data) => {
448
- if (!isJSONObject(data)) {
449
- throw new TypeError(
450
- `Unmarshalling the type 'ListBackendsResponse' failed as data isn't a dictionary.`
451
- );
452
- }
453
- return {
454
- backends: unmarshalArrayOfObject(data.backends, unmarshalBackend),
455
- totalCount: data.total_count
456
- };
310
+ if (!isJSONObject(data)) throw new TypeError(`Unmarshalling the type 'ListBackendsResponse' failed as data isn't a dictionary.`);
311
+ return {
312
+ backends: unmarshalArrayOfObject(data.backends, unmarshalBackend),
313
+ totalCount: data.total_count
314
+ };
457
315
  };
458
316
  const unmarshalListCertificatesResponse = (data) => {
459
- if (!isJSONObject(data)) {
460
- throw new TypeError(
461
- `Unmarshalling the type 'ListCertificatesResponse' failed as data isn't a dictionary.`
462
- );
463
- }
464
- return {
465
- certificates: unmarshalArrayOfObject(data.certificates, unmarshalCertificate),
466
- totalCount: data.total_count
467
- };
317
+ if (!isJSONObject(data)) throw new TypeError(`Unmarshalling the type 'ListCertificatesResponse' failed as data isn't a dictionary.`);
318
+ return {
319
+ certificates: unmarshalArrayOfObject(data.certificates, unmarshalCertificate),
320
+ totalCount: data.total_count
321
+ };
468
322
  };
469
323
  const unmarshalListFrontendsResponse = (data) => {
470
- if (!isJSONObject(data)) {
471
- throw new TypeError(
472
- `Unmarshalling the type 'ListFrontendsResponse' failed as data isn't a dictionary.`
473
- );
474
- }
475
- return {
476
- frontends: unmarshalArrayOfObject(data.frontends, unmarshalFrontend),
477
- totalCount: data.total_count
478
- };
324
+ if (!isJSONObject(data)) throw new TypeError(`Unmarshalling the type 'ListFrontendsResponse' failed as data isn't a dictionary.`);
325
+ return {
326
+ frontends: unmarshalArrayOfObject(data.frontends, unmarshalFrontend),
327
+ totalCount: data.total_count
328
+ };
479
329
  };
480
330
  const unmarshalListIpsResponse = (data) => {
481
- if (!isJSONObject(data)) {
482
- throw new TypeError(
483
- `Unmarshalling the type 'ListIpsResponse' failed as data isn't a dictionary.`
484
- );
485
- }
486
- return {
487
- ips: unmarshalArrayOfObject(data.ips, unmarshalIp),
488
- totalCount: data.total_count
489
- };
331
+ if (!isJSONObject(data)) throw new TypeError(`Unmarshalling the type 'ListIpsResponse' failed as data isn't a dictionary.`);
332
+ return {
333
+ ips: unmarshalArrayOfObject(data.ips, unmarshalIp),
334
+ totalCount: data.total_count
335
+ };
490
336
  };
491
337
  const unmarshalListLbPrivateNetworksResponse = (data) => {
492
- if (!isJSONObject(data)) {
493
- throw new TypeError(
494
- `Unmarshalling the type 'ListLbPrivateNetworksResponse' failed as data isn't a dictionary.`
495
- );
496
- }
497
- return {
498
- privateNetwork: unmarshalArrayOfObject(data.private_network, unmarshalPrivateNetwork),
499
- totalCount: data.total_count
500
- };
501
- };
502
- const unmarshalLbType = (data) => {
503
- if (!isJSONObject(data)) {
504
- throw new TypeError(
505
- `Unmarshalling the type 'LbType' failed as data isn't a dictionary.`
506
- );
507
- }
508
- return {
509
- description: data.description,
510
- name: data.name,
511
- region: data.region,
512
- stockStatus: data.stock_status,
513
- zone: data.zone
514
- };
338
+ if (!isJSONObject(data)) throw new TypeError(`Unmarshalling the type 'ListLbPrivateNetworksResponse' failed as data isn't a dictionary.`);
339
+ return {
340
+ privateNetwork: unmarshalArrayOfObject(data.private_network, unmarshalPrivateNetwork),
341
+ totalCount: data.total_count
342
+ };
343
+ };
344
+ var unmarshalLbType = (data) => {
345
+ if (!isJSONObject(data)) throw new TypeError(`Unmarshalling the type 'LbType' failed as data isn't a dictionary.`);
346
+ return {
347
+ description: data.description,
348
+ name: data.name,
349
+ region: data.region,
350
+ stockStatus: data.stock_status,
351
+ zone: data.zone
352
+ };
515
353
  };
516
354
  const unmarshalListLbTypesResponse = (data) => {
517
- if (!isJSONObject(data)) {
518
- throw new TypeError(
519
- `Unmarshalling the type 'ListLbTypesResponse' failed as data isn't a dictionary.`
520
- );
521
- }
522
- return {
523
- lbTypes: unmarshalArrayOfObject(data.lb_types, unmarshalLbType),
524
- totalCount: data.total_count
525
- };
355
+ if (!isJSONObject(data)) throw new TypeError(`Unmarshalling the type 'ListLbTypesResponse' failed as data isn't a dictionary.`);
356
+ return {
357
+ lbTypes: unmarshalArrayOfObject(data.lb_types, unmarshalLbType),
358
+ totalCount: data.total_count
359
+ };
526
360
  };
527
361
  const unmarshalListLbsResponse = (data) => {
528
- if (!isJSONObject(data)) {
529
- throw new TypeError(
530
- `Unmarshalling the type 'ListLbsResponse' failed as data isn't a dictionary.`
531
- );
532
- }
533
- return {
534
- lbs: unmarshalArrayOfObject(data.lbs, unmarshalLb),
535
- totalCount: data.total_count
536
- };
362
+ if (!isJSONObject(data)) throw new TypeError(`Unmarshalling the type 'ListLbsResponse' failed as data isn't a dictionary.`);
363
+ return {
364
+ lbs: unmarshalArrayOfObject(data.lbs, unmarshalLb),
365
+ totalCount: data.total_count
366
+ };
537
367
  };
538
368
  const unmarshalListRoutesResponse = (data) => {
539
- if (!isJSONObject(data)) {
540
- throw new TypeError(
541
- `Unmarshalling the type 'ListRoutesResponse' failed as data isn't a dictionary.`
542
- );
543
- }
544
- return {
545
- routes: unmarshalArrayOfObject(data.routes, unmarshalRoute),
546
- totalCount: data.total_count
547
- };
369
+ if (!isJSONObject(data)) throw new TypeError(`Unmarshalling the type 'ListRoutesResponse' failed as data isn't a dictionary.`);
370
+ return {
371
+ routes: unmarshalArrayOfObject(data.routes, unmarshalRoute),
372
+ totalCount: data.total_count
373
+ };
548
374
  };
549
375
  const unmarshalListSubscriberResponse = (data) => {
550
- if (!isJSONObject(data)) {
551
- throw new TypeError(
552
- `Unmarshalling the type 'ListSubscriberResponse' failed as data isn't a dictionary.`
553
- );
554
- }
555
- return {
556
- subscribers: unmarshalArrayOfObject(data.subscribers, unmarshalSubscriber),
557
- totalCount: data.total_count
558
- };
376
+ if (!isJSONObject(data)) throw new TypeError(`Unmarshalling the type 'ListSubscriberResponse' failed as data isn't a dictionary.`);
377
+ return {
378
+ subscribers: unmarshalArrayOfObject(data.subscribers, unmarshalSubscriber),
379
+ totalCount: data.total_count
380
+ };
559
381
  };
560
382
  const unmarshalSetAclsResponse = (data) => {
561
- if (!isJSONObject(data)) {
562
- throw new TypeError(
563
- `Unmarshalling the type 'SetAclsResponse' failed as data isn't a dictionary.`
564
- );
565
- }
566
- return {
567
- acls: unmarshalArrayOfObject(data.acls, unmarshalAcl),
568
- totalCount: data.total_count
569
- };
570
- };
571
- const marshalAddBackendServersRequest = (request, defaults) => ({
572
- server_ip: request.serverIp
573
- });
574
- const marshalPrivateNetworkDHCPConfig = (request, defaults) => ({
575
- ip_id: request.ipId
576
- });
577
- const marshalPrivateNetworkIpamConfig = (request, defaults) => ({});
578
- const marshalPrivateNetworkStaticConfig = (request, defaults) => ({
579
- ip_address: request.ipAddress
580
- });
383
+ if (!isJSONObject(data)) throw new TypeError(`Unmarshalling the type 'SetAclsResponse' failed as data isn't a dictionary.`);
384
+ return {
385
+ acls: unmarshalArrayOfObject(data.acls, unmarshalAcl),
386
+ totalCount: data.total_count
387
+ };
388
+ };
389
+ const marshalAddBackendServersRequest = (request, defaults) => ({ server_ip: request.serverIp });
390
+ var marshalPrivateNetworkDHCPConfig = (request, defaults) => ({ ip_id: request.ipId });
391
+ var marshalPrivateNetworkIpamConfig = (request, defaults) => ({});
392
+ var marshalPrivateNetworkStaticConfig = (request, defaults) => ({ ip_address: request.ipAddress });
581
393
  const marshalAttachPrivateNetworkRequest = (request, defaults) => ({
582
- ipam_ids: request.ipamIds,
583
- ...resolveOneOf([
584
- {
585
- param: "static_config",
586
- value: request.staticConfig !== void 0 ? marshalPrivateNetworkStaticConfig(request.staticConfig) : void 0
587
- },
588
- {
589
- param: "dhcp_config",
590
- value: request.dhcpConfig !== void 0 ? marshalPrivateNetworkDHCPConfig(request.dhcpConfig) : void 0
591
- },
592
- {
593
- param: "ipam_config",
594
- value: request.ipamConfig !== void 0 ? marshalPrivateNetworkIpamConfig(request.ipamConfig) : void 0
595
- }
596
- ])
597
- });
598
- const marshalAclActionRedirect = (request, defaults) => ({
599
- code: request.code,
600
- target: request.target,
601
- type: request.type
602
- });
603
- const marshalAclAction = (request, defaults) => ({
604
- redirect: request.redirect !== void 0 ? marshalAclActionRedirect(request.redirect) : void 0,
605
- type: request.type
606
- });
607
- const marshalAclMatch = (request, defaults) => ({
608
- http_filter: request.httpFilter,
609
- http_filter_option: request.httpFilterOption,
610
- http_filter_value: request.httpFilterValue,
611
- invert: request.invert,
612
- ip_subnet: request.ipSubnet,
613
- ips_edge_services: request.ipsEdgeServices
394
+ ipam_ids: request.ipamIds,
395
+ ...resolveOneOf([
396
+ {
397
+ param: "static_config",
398
+ value: request.staticConfig !== void 0 ? marshalPrivateNetworkStaticConfig(request.staticConfig, defaults) : void 0
399
+ },
400
+ {
401
+ param: "dhcp_config",
402
+ value: request.dhcpConfig !== void 0 ? marshalPrivateNetworkDHCPConfig(request.dhcpConfig, defaults) : void 0
403
+ },
404
+ {
405
+ param: "ipam_config",
406
+ value: request.ipamConfig !== void 0 ? marshalPrivateNetworkIpamConfig(request.ipamConfig, defaults) : void 0
407
+ }
408
+ ])
409
+ });
410
+ var marshalAclActionRedirect = (request, defaults) => ({
411
+ code: request.code,
412
+ target: request.target,
413
+ type: request.type
414
+ });
415
+ var marshalAclAction = (request, defaults) => ({
416
+ redirect: request.redirect !== void 0 ? marshalAclActionRedirect(request.redirect, defaults) : void 0,
417
+ type: request.type
418
+ });
419
+ var marshalAclMatch = (request, defaults) => ({
420
+ http_filter: request.httpFilter,
421
+ http_filter_option: request.httpFilterOption,
422
+ http_filter_value: request.httpFilterValue,
423
+ invert: request.invert,
424
+ ip_subnet: request.ipSubnet,
425
+ ips_edge_services: request.ipsEdgeServices
614
426
  });
615
427
  const marshalCreateAclRequest = (request, defaults) => ({
616
- action: marshalAclAction(request.action),
617
- description: request.description,
618
- index: request.index,
619
- match: request.match !== void 0 ? marshalAclMatch(request.match) : void 0,
620
- name: request.name || randomName("acl")
621
- });
622
- const marshalHealthCheckHttpConfig = (request, defaults) => ({
623
- code: request.code,
624
- host_header: request.hostHeader,
625
- method: request.method,
626
- uri: request.uri
627
- });
628
- const marshalHealthCheckHttpsConfig = (request, defaults) => ({
629
- code: request.code,
630
- host_header: request.hostHeader,
631
- method: request.method,
632
- sni: request.sni,
633
- uri: request.uri
634
- });
635
- const marshalHealthCheckLdapConfig = (request, defaults) => ({});
636
- const marshalHealthCheckMysqlConfig = (request, defaults) => ({
637
- user: request.user
638
- });
639
- const marshalHealthCheckPgsqlConfig = (request, defaults) => ({
640
- user: request.user
641
- });
642
- const marshalHealthCheckRedisConfig = (request, defaults) => ({});
643
- const marshalHealthCheckTcpConfig = (request, defaults) => ({});
644
- const marshalHealthCheck = (request, defaults) => ({
645
- check_delay: request.checkDelay,
646
- check_max_retries: request.checkMaxRetries,
647
- check_send_proxy: request.checkSendProxy,
648
- check_timeout: request.checkTimeout,
649
- port: request.port,
650
- transient_check_delay: request.transientCheckDelay,
651
- ...resolveOneOf([
652
- {
653
- param: "tcp_config",
654
- value: request.tcpConfig !== void 0 ? marshalHealthCheckTcpConfig(request.tcpConfig) : void 0
655
- },
656
- {
657
- param: "mysql_config",
658
- value: request.mysqlConfig !== void 0 ? marshalHealthCheckMysqlConfig(request.mysqlConfig) : void 0
659
- },
660
- {
661
- param: "pgsql_config",
662
- value: request.pgsqlConfig !== void 0 ? marshalHealthCheckPgsqlConfig(request.pgsqlConfig) : void 0
663
- },
664
- {
665
- param: "ldap_config",
666
- value: request.ldapConfig !== void 0 ? marshalHealthCheckLdapConfig(request.ldapConfig) : void 0
667
- },
668
- {
669
- param: "redis_config",
670
- value: request.redisConfig !== void 0 ? marshalHealthCheckRedisConfig(request.redisConfig) : void 0
671
- },
672
- {
673
- param: "http_config",
674
- value: request.httpConfig !== void 0 ? marshalHealthCheckHttpConfig(request.httpConfig) : void 0
675
- },
676
- {
677
- param: "https_config",
678
- value: request.httpsConfig !== void 0 ? marshalHealthCheckHttpsConfig(request.httpsConfig) : void 0
679
- }
680
- ])
428
+ action: marshalAclAction(request.action, defaults),
429
+ description: request.description,
430
+ index: request.index,
431
+ match: request.match !== void 0 ? marshalAclMatch(request.match, defaults) : void 0,
432
+ name: request.name || randomName("acl")
433
+ });
434
+ var marshalHealthCheckHttpConfig = (request, defaults) => ({
435
+ code: request.code,
436
+ host_header: request.hostHeader,
437
+ method: request.method,
438
+ uri: request.uri
439
+ });
440
+ var marshalHealthCheckHttpsConfig = (request, defaults) => ({
441
+ code: request.code,
442
+ host_header: request.hostHeader,
443
+ method: request.method,
444
+ sni: request.sni,
445
+ uri: request.uri
446
+ });
447
+ var marshalHealthCheckLdapConfig = (request, defaults) => ({});
448
+ var marshalHealthCheckMysqlConfig = (request, defaults) => ({ user: request.user });
449
+ var marshalHealthCheckPgsqlConfig = (request, defaults) => ({ user: request.user });
450
+ var marshalHealthCheckRedisConfig = (request, defaults) => ({});
451
+ var marshalHealthCheckTcpConfig = (request, defaults) => ({});
452
+ var marshalHealthCheck = (request, defaults) => ({
453
+ check_delay: request.checkDelay,
454
+ check_max_retries: request.checkMaxRetries,
455
+ check_send_proxy: request.checkSendProxy,
456
+ check_timeout: request.checkTimeout,
457
+ port: request.port,
458
+ transient_check_delay: request.transientCheckDelay,
459
+ ...resolveOneOf([
460
+ {
461
+ param: "tcp_config",
462
+ value: request.tcpConfig !== void 0 ? marshalHealthCheckTcpConfig(request.tcpConfig, defaults) : void 0
463
+ },
464
+ {
465
+ param: "mysql_config",
466
+ value: request.mysqlConfig !== void 0 ? marshalHealthCheckMysqlConfig(request.mysqlConfig, defaults) : void 0
467
+ },
468
+ {
469
+ param: "pgsql_config",
470
+ value: request.pgsqlConfig !== void 0 ? marshalHealthCheckPgsqlConfig(request.pgsqlConfig, defaults) : void 0
471
+ },
472
+ {
473
+ param: "ldap_config",
474
+ value: request.ldapConfig !== void 0 ? marshalHealthCheckLdapConfig(request.ldapConfig, defaults) : void 0
475
+ },
476
+ {
477
+ param: "redis_config",
478
+ value: request.redisConfig !== void 0 ? marshalHealthCheckRedisConfig(request.redisConfig, defaults) : void 0
479
+ },
480
+ {
481
+ param: "http_config",
482
+ value: request.httpConfig !== void 0 ? marshalHealthCheckHttpConfig(request.httpConfig, defaults) : void 0
483
+ },
484
+ {
485
+ param: "https_config",
486
+ value: request.httpsConfig !== void 0 ? marshalHealthCheckHttpsConfig(request.httpsConfig, defaults) : void 0
487
+ }
488
+ ])
681
489
  });
682
490
  const marshalCreateBackendRequest = (request, defaults) => ({
683
- failover_host: request.failoverHost,
684
- forward_port: request.forwardPort,
685
- forward_port_algorithm: request.forwardPortAlgorithm,
686
- forward_protocol: request.forwardProtocol,
687
- health_check: marshalHealthCheck(request.healthCheck),
688
- ignore_ssl_server_verify: request.ignoreSslServerVerify,
689
- max_connections: request.maxConnections,
690
- max_retries: request.maxRetries,
691
- name: request.name || randomName("lbb"),
692
- on_marked_down_action: request.onMarkedDownAction,
693
- proxy_protocol: request.proxyProtocol,
694
- redispatch_attempt_count: request.redispatchAttemptCount,
695
- send_proxy_v2: request.sendProxyV2,
696
- server_ip: request.serverIp,
697
- ssl_bridging: request.sslBridging,
698
- sticky_sessions: request.stickySessions,
699
- sticky_sessions_cookie_name: request.stickySessionsCookieName,
700
- timeout_connect: request.timeoutConnect,
701
- timeout_queue: request.timeoutQueue,
702
- timeout_server: request.timeoutServer,
703
- timeout_tunnel: request.timeoutTunnel
704
- });
705
- const marshalCreateCertificateRequestCustomCertificate = (request, defaults) => ({
706
- certificate_chain: request.certificateChain
707
- });
708
- const marshalCreateCertificateRequestLetsencryptConfig = (request, defaults) => ({
709
- common_name: request.commonName,
710
- subject_alternative_name: request.subjectAlternativeName
491
+ failover_host: request.failoverHost,
492
+ forward_port: request.forwardPort,
493
+ forward_port_algorithm: request.forwardPortAlgorithm,
494
+ forward_protocol: request.forwardProtocol,
495
+ health_check: marshalHealthCheck(request.healthCheck, defaults),
496
+ ignore_ssl_server_verify: request.ignoreSslServerVerify,
497
+ max_connections: request.maxConnections,
498
+ max_retries: request.maxRetries,
499
+ name: request.name || randomName("lbb"),
500
+ on_marked_down_action: request.onMarkedDownAction,
501
+ proxy_protocol: request.proxyProtocol,
502
+ redispatch_attempt_count: request.redispatchAttemptCount,
503
+ send_proxy_v2: request.sendProxyV2,
504
+ server_ip: request.serverIp,
505
+ ssl_bridging: request.sslBridging,
506
+ sticky_sessions: request.stickySessions,
507
+ sticky_sessions_cookie_name: request.stickySessionsCookieName,
508
+ timeout_connect: request.timeoutConnect,
509
+ timeout_queue: request.timeoutQueue,
510
+ timeout_server: request.timeoutServer,
511
+ timeout_tunnel: request.timeoutTunnel
512
+ });
513
+ var marshalCreateCertificateRequestCustomCertificate = (request, defaults) => ({ certificate_chain: request.certificateChain });
514
+ var marshalCreateCertificateRequestLetsencryptConfig = (request, defaults) => ({
515
+ common_name: request.commonName,
516
+ subject_alternative_name: request.subjectAlternativeName
711
517
  });
712
518
  const marshalCreateCertificateRequest = (request, defaults) => ({
713
- name: request.name || randomName("certificate"),
714
- ...resolveOneOf([
715
- {
716
- param: "letsencrypt",
717
- value: request.letsencrypt !== void 0 ? marshalCreateCertificateRequestLetsencryptConfig(request.letsencrypt) : void 0
718
- },
719
- {
720
- param: "custom_certificate",
721
- value: request.customCertificate !== void 0 ? marshalCreateCertificateRequestCustomCertificate(request.customCertificate) : void 0
722
- }
723
- ])
519
+ name: request.name || randomName("certificate"),
520
+ ...resolveOneOf([{
521
+ param: "letsencrypt",
522
+ value: request.letsencrypt !== void 0 ? marshalCreateCertificateRequestLetsencryptConfig(request.letsencrypt, defaults) : void 0
523
+ }, {
524
+ param: "custom_certificate",
525
+ value: request.customCertificate !== void 0 ? marshalCreateCertificateRequestCustomCertificate(request.customCertificate, defaults) : void 0
526
+ }])
724
527
  });
725
528
  const marshalCreateFrontendRequest = (request, defaults) => ({
726
- backend_id: request.backendId,
727
- certificate_id: request.certificateId,
728
- certificate_ids: request.certificateIds,
729
- connection_rate_limit: request.connectionRateLimit,
730
- enable_access_logs: request.enableAccessLogs,
731
- enable_http3: request.enableHttp3,
732
- inbound_port: request.inboundPort,
733
- name: request.name || randomName("lbf"),
734
- timeout_client: request.timeoutClient
529
+ backend_id: request.backendId,
530
+ certificate_id: request.certificateId,
531
+ certificate_ids: request.certificateIds,
532
+ connection_rate_limit: request.connectionRateLimit,
533
+ enable_access_logs: request.enableAccessLogs,
534
+ enable_http3: request.enableHttp3,
535
+ inbound_port: request.inboundPort,
536
+ name: request.name || randomName("lbf"),
537
+ timeout_client: request.timeoutClient
735
538
  });
736
539
  const marshalCreateIpRequest = (request, defaults) => ({
737
- is_ipv6: request.isIpv6,
738
- reverse: request.reverse,
739
- tags: request.tags,
740
- ...resolveOneOf([
741
- {
742
- default: defaults.defaultProjectId,
743
- param: "project_id",
744
- value: request.projectId
745
- },
746
- {
747
- default: defaults.defaultOrganizationId,
748
- param: "organization_id",
749
- value: request.organizationId
750
- }
751
- ])
540
+ is_ipv6: request.isIpv6,
541
+ reverse: request.reverse,
542
+ tags: request.tags,
543
+ ...resolveOneOf([{
544
+ default: defaults.defaultProjectId,
545
+ param: "project_id",
546
+ value: request.projectId
547
+ }, {
548
+ default: defaults.defaultOrganizationId,
549
+ param: "organization_id",
550
+ value: request.organizationId
551
+ }])
752
552
  });
753
553
  const marshalCreateLbRequest = (request, defaults) => ({
754
- assign_flexible_ip: request.assignFlexibleIp,
755
- assign_flexible_ipv6: request.assignFlexibleIpv6,
756
- description: request.description,
757
- ip_id: request.ipId,
758
- ip_ids: request.ipIds,
759
- name: request.name || randomName("lb"),
760
- ssl_compatibility_level: request.sslCompatibilityLevel,
761
- tags: request.tags,
762
- type: request.type,
763
- ...resolveOneOf([
764
- {
765
- default: defaults.defaultProjectId,
766
- param: "project_id",
767
- value: request.projectId
768
- },
769
- {
770
- default: defaults.defaultOrganizationId,
771
- param: "organization_id",
772
- value: request.organizationId
773
- }
774
- ])
775
- });
776
- const marshalRouteMatch = (request, defaults) => ({
777
- match_subdomains: request.matchSubdomains,
778
- ...resolveOneOf([
779
- {
780
- param: "sni",
781
- value: request.sni
782
- },
783
- {
784
- param: "host_header",
785
- value: request.hostHeader
786
- },
787
- {
788
- param: "path_begin",
789
- value: request.pathBegin
790
- }
791
- ])
554
+ assign_flexible_ip: request.assignFlexibleIp,
555
+ assign_flexible_ipv6: request.assignFlexibleIpv6,
556
+ description: request.description,
557
+ ip_id: request.ipId,
558
+ ip_ids: request.ipIds,
559
+ name: request.name || randomName("lb"),
560
+ ssl_compatibility_level: request.sslCompatibilityLevel,
561
+ tags: request.tags,
562
+ type: request.type,
563
+ ...resolveOneOf([{
564
+ default: defaults.defaultProjectId,
565
+ param: "project_id",
566
+ value: request.projectId
567
+ }, {
568
+ default: defaults.defaultOrganizationId,
569
+ param: "organization_id",
570
+ value: request.organizationId
571
+ }])
572
+ });
573
+ var marshalRouteMatch = (request, defaults) => ({
574
+ match_subdomains: request.matchSubdomains,
575
+ ...resolveOneOf([
576
+ {
577
+ param: "sni",
578
+ value: request.sni
579
+ },
580
+ {
581
+ param: "host_header",
582
+ value: request.hostHeader
583
+ },
584
+ {
585
+ param: "path_begin",
586
+ value: request.pathBegin
587
+ }
588
+ ])
792
589
  });
793
590
  const marshalCreateRouteRequest = (request, defaults) => ({
794
- backend_id: request.backendId,
795
- frontend_id: request.frontendId,
796
- match: request.match !== void 0 ? marshalRouteMatch(request.match) : void 0
797
- });
798
- const marshalSubscriberEmailConfig = (request, defaults) => ({
799
- email: request.email
800
- });
801
- const marshalSubscriberWebhookConfig = (request, defaults) => ({
802
- uri: request.uri
591
+ backend_id: request.backendId,
592
+ frontend_id: request.frontendId,
593
+ match: request.match !== void 0 ? marshalRouteMatch(request.match, defaults) : void 0
803
594
  });
595
+ var marshalSubscriberEmailConfig = (request, defaults) => ({ email: request.email });
596
+ var marshalSubscriberWebhookConfig = (request, defaults) => ({ uri: request.uri });
804
597
  const marshalCreateSubscriberRequest = (request, defaults) => ({
805
- name: request.name,
806
- ...resolveOneOf([
807
- {
808
- default: defaults.defaultProjectId,
809
- param: "project_id",
810
- value: request.projectId
811
- },
812
- {
813
- default: defaults.defaultOrganizationId,
814
- param: "organization_id",
815
- value: request.organizationId
816
- }
817
- ]),
818
- ...resolveOneOf([
819
- {
820
- param: "email_config",
821
- value: request.emailConfig !== void 0 ? marshalSubscriberEmailConfig(request.emailConfig) : void 0
822
- },
823
- {
824
- param: "webhook_config",
825
- value: request.webhookConfig !== void 0 ? marshalSubscriberWebhookConfig(request.webhookConfig) : void 0
826
- }
827
- ])
828
- });
829
- const marshalMigrateLbRequest = (request, defaults) => ({
830
- type: request.type
831
- });
832
- const marshalRemoveBackendServersRequest = (request, defaults) => ({
833
- server_ip: request.serverIp
834
- });
835
- const marshalSetBackendServersRequest = (request, defaults) => ({
836
- server_ip: request.serverIp
837
- });
838
- const marshalSubscribeToLbRequest = (request, defaults) => ({
839
- subscriber_id: request.subscriberId
840
- });
598
+ name: request.name,
599
+ ...resolveOneOf([{
600
+ default: defaults.defaultProjectId,
601
+ param: "project_id",
602
+ value: request.projectId
603
+ }, {
604
+ default: defaults.defaultOrganizationId,
605
+ param: "organization_id",
606
+ value: request.organizationId
607
+ }]),
608
+ ...resolveOneOf([{
609
+ param: "email_config",
610
+ value: request.emailConfig !== void 0 ? marshalSubscriberEmailConfig(request.emailConfig, defaults) : void 0
611
+ }, {
612
+ param: "webhook_config",
613
+ value: request.webhookConfig !== void 0 ? marshalSubscriberWebhookConfig(request.webhookConfig, defaults) : void 0
614
+ }])
615
+ });
616
+ const marshalMigrateLbRequest = (request, defaults) => ({ type: request.type });
617
+ const marshalRemoveBackendServersRequest = (request, defaults) => ({ server_ip: request.serverIp });
618
+ const marshalSetBackendServersRequest = (request, defaults) => ({ server_ip: request.serverIp });
619
+ const marshalSubscribeToLbRequest = (request, defaults) => ({ subscriber_id: request.subscriberId });
841
620
  const marshalUpdateAclRequest = (request, defaults) => ({
842
- action: marshalAclAction(request.action),
843
- description: request.description,
844
- index: request.index,
845
- match: request.match !== void 0 ? marshalAclMatch(request.match) : void 0,
846
- name: request.name
621
+ action: marshalAclAction(request.action, defaults),
622
+ description: request.description,
623
+ index: request.index,
624
+ match: request.match !== void 0 ? marshalAclMatch(request.match, defaults) : void 0,
625
+ name: request.name
847
626
  });
848
627
  const marshalUpdateBackendRequest = (request, defaults) => ({
849
- failover_host: request.failoverHost,
850
- forward_port: request.forwardPort,
851
- forward_port_algorithm: request.forwardPortAlgorithm,
852
- forward_protocol: request.forwardProtocol,
853
- ignore_ssl_server_verify: request.ignoreSslServerVerify,
854
- max_connections: request.maxConnections,
855
- max_retries: request.maxRetries,
856
- name: request.name,
857
- on_marked_down_action: request.onMarkedDownAction,
858
- proxy_protocol: request.proxyProtocol,
859
- redispatch_attempt_count: request.redispatchAttemptCount,
860
- send_proxy_v2: request.sendProxyV2,
861
- ssl_bridging: request.sslBridging,
862
- sticky_sessions: request.stickySessions,
863
- sticky_sessions_cookie_name: request.stickySessionsCookieName,
864
- timeout_connect: request.timeoutConnect,
865
- timeout_queue: request.timeoutQueue,
866
- timeout_server: request.timeoutServer,
867
- timeout_tunnel: request.timeoutTunnel
868
- });
869
- const marshalUpdateCertificateRequest = (request, defaults) => ({
870
- name: request.name
871
- });
628
+ failover_host: request.failoverHost,
629
+ forward_port: request.forwardPort,
630
+ forward_port_algorithm: request.forwardPortAlgorithm,
631
+ forward_protocol: request.forwardProtocol,
632
+ ignore_ssl_server_verify: request.ignoreSslServerVerify,
633
+ max_connections: request.maxConnections,
634
+ max_retries: request.maxRetries,
635
+ name: request.name,
636
+ on_marked_down_action: request.onMarkedDownAction,
637
+ proxy_protocol: request.proxyProtocol,
638
+ redispatch_attempt_count: request.redispatchAttemptCount,
639
+ send_proxy_v2: request.sendProxyV2,
640
+ ssl_bridging: request.sslBridging,
641
+ sticky_sessions: request.stickySessions,
642
+ sticky_sessions_cookie_name: request.stickySessionsCookieName,
643
+ timeout_connect: request.timeoutConnect,
644
+ timeout_queue: request.timeoutQueue,
645
+ timeout_server: request.timeoutServer,
646
+ timeout_tunnel: request.timeoutTunnel
647
+ });
648
+ const marshalUpdateCertificateRequest = (request, defaults) => ({ name: request.name });
872
649
  const marshalUpdateFrontendRequest = (request, defaults) => ({
873
- backend_id: request.backendId,
874
- certificate_id: request.certificateId,
875
- certificate_ids: request.certificateIds,
876
- connection_rate_limit: request.connectionRateLimit,
877
- enable_access_logs: request.enableAccessLogs,
878
- enable_http3: request.enableHttp3,
879
- inbound_port: request.inboundPort,
880
- name: request.name,
881
- timeout_client: request.timeoutClient
650
+ backend_id: request.backendId,
651
+ certificate_id: request.certificateId,
652
+ certificate_ids: request.certificateIds,
653
+ connection_rate_limit: request.connectionRateLimit,
654
+ enable_access_logs: request.enableAccessLogs,
655
+ enable_http3: request.enableHttp3,
656
+ inbound_port: request.inboundPort,
657
+ name: request.name,
658
+ timeout_client: request.timeoutClient
882
659
  });
883
660
  const marshalUpdateHealthCheckRequest = (request, defaults) => ({
884
- check_delay: request.checkDelay,
885
- check_max_retries: request.checkMaxRetries,
886
- check_send_proxy: request.checkSendProxy,
887
- check_timeout: request.checkTimeout,
888
- port: request.port,
889
- transient_check_delay: request.transientCheckDelay,
890
- ...resolveOneOf([
891
- {
892
- param: "tcp_config",
893
- value: request.tcpConfig !== void 0 ? marshalHealthCheckTcpConfig(request.tcpConfig) : void 0
894
- },
895
- {
896
- param: "mysql_config",
897
- value: request.mysqlConfig !== void 0 ? marshalHealthCheckMysqlConfig(request.mysqlConfig) : void 0
898
- },
899
- {
900
- param: "pgsql_config",
901
- value: request.pgsqlConfig !== void 0 ? marshalHealthCheckPgsqlConfig(request.pgsqlConfig) : void 0
902
- },
903
- {
904
- param: "ldap_config",
905
- value: request.ldapConfig !== void 0 ? marshalHealthCheckLdapConfig(request.ldapConfig) : void 0
906
- },
907
- {
908
- param: "redis_config",
909
- value: request.redisConfig !== void 0 ? marshalHealthCheckRedisConfig(request.redisConfig) : void 0
910
- },
911
- {
912
- param: "http_config",
913
- value: request.httpConfig !== void 0 ? marshalHealthCheckHttpConfig(request.httpConfig) : void 0
914
- },
915
- {
916
- param: "https_config",
917
- value: request.httpsConfig !== void 0 ? marshalHealthCheckHttpsConfig(request.httpsConfig) : void 0
918
- }
919
- ])
661
+ check_delay: request.checkDelay,
662
+ check_max_retries: request.checkMaxRetries,
663
+ check_send_proxy: request.checkSendProxy,
664
+ check_timeout: request.checkTimeout,
665
+ port: request.port,
666
+ transient_check_delay: request.transientCheckDelay,
667
+ ...resolveOneOf([
668
+ {
669
+ param: "tcp_config",
670
+ value: request.tcpConfig !== void 0 ? marshalHealthCheckTcpConfig(request.tcpConfig, defaults) : void 0
671
+ },
672
+ {
673
+ param: "mysql_config",
674
+ value: request.mysqlConfig !== void 0 ? marshalHealthCheckMysqlConfig(request.mysqlConfig, defaults) : void 0
675
+ },
676
+ {
677
+ param: "pgsql_config",
678
+ value: request.pgsqlConfig !== void 0 ? marshalHealthCheckPgsqlConfig(request.pgsqlConfig, defaults) : void 0
679
+ },
680
+ {
681
+ param: "ldap_config",
682
+ value: request.ldapConfig !== void 0 ? marshalHealthCheckLdapConfig(request.ldapConfig, defaults) : void 0
683
+ },
684
+ {
685
+ param: "redis_config",
686
+ value: request.redisConfig !== void 0 ? marshalHealthCheckRedisConfig(request.redisConfig, defaults) : void 0
687
+ },
688
+ {
689
+ param: "http_config",
690
+ value: request.httpConfig !== void 0 ? marshalHealthCheckHttpConfig(request.httpConfig, defaults) : void 0
691
+ },
692
+ {
693
+ param: "https_config",
694
+ value: request.httpsConfig !== void 0 ? marshalHealthCheckHttpsConfig(request.httpsConfig, defaults) : void 0
695
+ }
696
+ ])
920
697
  });
921
698
  const marshalUpdateIpRequest = (request, defaults) => ({
922
- lb_id: request.lbId,
923
- reverse: request.reverse,
924
- tags: request.tags
699
+ lb_id: request.lbId,
700
+ reverse: request.reverse,
701
+ tags: request.tags
925
702
  });
926
703
  const marshalUpdateLbRequest = (request, defaults) => ({
927
- description: request.description,
928
- name: request.name,
929
- ssl_compatibility_level: request.sslCompatibilityLevel,
930
- tags: request.tags
704
+ description: request.description,
705
+ name: request.name,
706
+ ssl_compatibility_level: request.sslCompatibilityLevel,
707
+ tags: request.tags
931
708
  });
932
709
  const marshalUpdateRouteRequest = (request, defaults) => ({
933
- backend_id: request.backendId,
934
- match: request.match !== void 0 ? marshalRouteMatch(request.match) : void 0
710
+ backend_id: request.backendId,
711
+ match: request.match !== void 0 ? marshalRouteMatch(request.match, defaults) : void 0
935
712
  });
936
713
  const marshalUpdateSubscriberRequest = (request, defaults) => ({
937
- name: request.name,
938
- ...resolveOneOf([
939
- {
940
- param: "email_config",
941
- value: request.emailConfig !== void 0 ? marshalSubscriberEmailConfig(request.emailConfig) : void 0
942
- },
943
- {
944
- param: "webhook_config",
945
- value: request.webhookConfig !== void 0 ? marshalSubscriberWebhookConfig(request.webhookConfig) : void 0
946
- }
947
- ])
948
- });
949
- const marshalZonedApiAddBackendServersRequest = (request, defaults) => ({
950
- server_ip: request.serverIp
951
- });
714
+ name: request.name,
715
+ ...resolveOneOf([{
716
+ param: "email_config",
717
+ value: request.emailConfig !== void 0 ? marshalSubscriberEmailConfig(request.emailConfig, defaults) : void 0
718
+ }, {
719
+ param: "webhook_config",
720
+ value: request.webhookConfig !== void 0 ? marshalSubscriberWebhookConfig(request.webhookConfig, defaults) : void 0
721
+ }])
722
+ });
723
+ const marshalZonedApiAddBackendServersRequest = (request, defaults) => ({ server_ip: request.serverIp });
952
724
  const marshalZonedApiAttachPrivateNetworkRequest = (request, defaults) => ({
953
- ipam_ids: request.ipamIds,
954
- private_network_id: request.privateNetworkId,
955
- ...resolveOneOf([
956
- {
957
- param: "static_config",
958
- value: request.staticConfig !== void 0 ? marshalPrivateNetworkStaticConfig(request.staticConfig) : void 0
959
- },
960
- {
961
- param: "dhcp_config",
962
- value: request.dhcpConfig !== void 0 ? marshalPrivateNetworkDHCPConfig(request.dhcpConfig) : void 0
963
- },
964
- {
965
- param: "ipam_config",
966
- value: request.ipamConfig !== void 0 ? marshalPrivateNetworkIpamConfig(request.ipamConfig) : void 0
967
- }
968
- ])
725
+ ipam_ids: request.ipamIds,
726
+ private_network_id: request.privateNetworkId,
727
+ ...resolveOneOf([
728
+ {
729
+ param: "static_config",
730
+ value: request.staticConfig !== void 0 ? marshalPrivateNetworkStaticConfig(request.staticConfig, defaults) : void 0
731
+ },
732
+ {
733
+ param: "dhcp_config",
734
+ value: request.dhcpConfig !== void 0 ? marshalPrivateNetworkDHCPConfig(request.dhcpConfig, defaults) : void 0
735
+ },
736
+ {
737
+ param: "ipam_config",
738
+ value: request.ipamConfig !== void 0 ? marshalPrivateNetworkIpamConfig(request.ipamConfig, defaults) : void 0
739
+ }
740
+ ])
969
741
  });
970
742
  const marshalZonedApiCreateAclRequest = (request, defaults) => ({
971
- action: marshalAclAction(request.action),
972
- description: request.description,
973
- index: request.index,
974
- match: request.match !== void 0 ? marshalAclMatch(request.match) : void 0,
975
- name: request.name || randomName("acl")
743
+ action: marshalAclAction(request.action, defaults),
744
+ description: request.description,
745
+ index: request.index,
746
+ match: request.match !== void 0 ? marshalAclMatch(request.match, defaults) : void 0,
747
+ name: request.name || randomName("acl")
976
748
  });
977
749
  const marshalZonedApiCreateBackendRequest = (request, defaults) => ({
978
- failover_host: request.failoverHost,
979
- forward_port: request.forwardPort,
980
- forward_port_algorithm: request.forwardPortAlgorithm,
981
- forward_protocol: request.forwardProtocol,
982
- health_check: marshalHealthCheck(request.healthCheck),
983
- ignore_ssl_server_verify: request.ignoreSslServerVerify,
984
- max_connections: request.maxConnections,
985
- max_retries: request.maxRetries,
986
- name: request.name || randomName("lbb"),
987
- on_marked_down_action: request.onMarkedDownAction,
988
- proxy_protocol: request.proxyProtocol,
989
- redispatch_attempt_count: request.redispatchAttemptCount,
990
- send_proxy_v2: request.sendProxyV2,
991
- server_ip: request.serverIp,
992
- ssl_bridging: request.sslBridging,
993
- sticky_sessions: request.stickySessions,
994
- sticky_sessions_cookie_name: request.stickySessionsCookieName,
995
- timeout_connect: request.timeoutConnect,
996
- timeout_queue: request.timeoutQueue,
997
- timeout_server: request.timeoutServer,
998
- timeout_tunnel: request.timeoutTunnel
750
+ failover_host: request.failoverHost,
751
+ forward_port: request.forwardPort,
752
+ forward_port_algorithm: request.forwardPortAlgorithm,
753
+ forward_protocol: request.forwardProtocol,
754
+ health_check: marshalHealthCheck(request.healthCheck, defaults),
755
+ ignore_ssl_server_verify: request.ignoreSslServerVerify,
756
+ max_connections: request.maxConnections,
757
+ max_retries: request.maxRetries,
758
+ name: request.name || randomName("lbb"),
759
+ on_marked_down_action: request.onMarkedDownAction,
760
+ proxy_protocol: request.proxyProtocol,
761
+ redispatch_attempt_count: request.redispatchAttemptCount,
762
+ send_proxy_v2: request.sendProxyV2,
763
+ server_ip: request.serverIp,
764
+ ssl_bridging: request.sslBridging,
765
+ sticky_sessions: request.stickySessions,
766
+ sticky_sessions_cookie_name: request.stickySessionsCookieName,
767
+ timeout_connect: request.timeoutConnect,
768
+ timeout_queue: request.timeoutQueue,
769
+ timeout_server: request.timeoutServer,
770
+ timeout_tunnel: request.timeoutTunnel
999
771
  });
1000
772
  const marshalZonedApiCreateCertificateRequest = (request, defaults) => ({
1001
- name: request.name || randomName("certificate"),
1002
- ...resolveOneOf([
1003
- {
1004
- param: "letsencrypt",
1005
- value: request.letsencrypt !== void 0 ? marshalCreateCertificateRequestLetsencryptConfig(request.letsencrypt) : void 0
1006
- },
1007
- {
1008
- param: "custom_certificate",
1009
- value: request.customCertificate !== void 0 ? marshalCreateCertificateRequestCustomCertificate(request.customCertificate) : void 0
1010
- }
1011
- ])
773
+ name: request.name || randomName("certificate"),
774
+ ...resolveOneOf([{
775
+ param: "letsencrypt",
776
+ value: request.letsencrypt !== void 0 ? marshalCreateCertificateRequestLetsencryptConfig(request.letsencrypt, defaults) : void 0
777
+ }, {
778
+ param: "custom_certificate",
779
+ value: request.customCertificate !== void 0 ? marshalCreateCertificateRequestCustomCertificate(request.customCertificate, defaults) : void 0
780
+ }])
1012
781
  });
1013
782
  const marshalZonedApiCreateFrontendRequest = (request, defaults) => ({
1014
- backend_id: request.backendId,
1015
- certificate_id: request.certificateId,
1016
- certificate_ids: request.certificateIds,
1017
- connection_rate_limit: request.connectionRateLimit,
1018
- enable_access_logs: request.enableAccessLogs,
1019
- enable_http3: request.enableHttp3,
1020
- inbound_port: request.inboundPort,
1021
- name: request.name || randomName("lbf"),
1022
- timeout_client: request.timeoutClient
783
+ backend_id: request.backendId,
784
+ certificate_id: request.certificateId,
785
+ certificate_ids: request.certificateIds,
786
+ connection_rate_limit: request.connectionRateLimit,
787
+ enable_access_logs: request.enableAccessLogs,
788
+ enable_http3: request.enableHttp3,
789
+ inbound_port: request.inboundPort,
790
+ name: request.name || randomName("lbf"),
791
+ timeout_client: request.timeoutClient
1023
792
  });
1024
793
  const marshalZonedApiCreateIpRequest = (request, defaults) => ({
1025
- is_ipv6: request.isIpv6,
1026
- reverse: request.reverse,
1027
- tags: request.tags,
1028
- ...resolveOneOf([
1029
- {
1030
- default: defaults.defaultProjectId,
1031
- param: "project_id",
1032
- value: request.projectId
1033
- },
1034
- {
1035
- default: defaults.defaultOrganizationId,
1036
- param: "organization_id",
1037
- value: request.organizationId
1038
- }
1039
- ])
794
+ is_ipv6: request.isIpv6,
795
+ reverse: request.reverse,
796
+ tags: request.tags,
797
+ ...resolveOneOf([{
798
+ default: defaults.defaultProjectId,
799
+ param: "project_id",
800
+ value: request.projectId
801
+ }, {
802
+ default: defaults.defaultOrganizationId,
803
+ param: "organization_id",
804
+ value: request.organizationId
805
+ }])
1040
806
  });
1041
807
  const marshalZonedApiCreateLbRequest = (request, defaults) => ({
1042
- assign_flexible_ip: request.assignFlexibleIp,
1043
- assign_flexible_ipv6: request.assignFlexibleIpv6,
1044
- description: request.description,
1045
- ip_id: request.ipId,
1046
- ip_ids: request.ipIds,
1047
- name: request.name || randomName("lb"),
1048
- ssl_compatibility_level: request.sslCompatibilityLevel,
1049
- tags: request.tags,
1050
- type: request.type,
1051
- ...resolveOneOf([
1052
- {
1053
- default: defaults.defaultProjectId,
1054
- param: "project_id",
1055
- value: request.projectId
1056
- },
1057
- {
1058
- default: defaults.defaultOrganizationId,
1059
- param: "organization_id",
1060
- value: request.organizationId
1061
- }
1062
- ])
808
+ assign_flexible_ip: request.assignFlexibleIp,
809
+ assign_flexible_ipv6: request.assignFlexibleIpv6,
810
+ description: request.description,
811
+ ip_id: request.ipId,
812
+ ip_ids: request.ipIds,
813
+ name: request.name || randomName("lb"),
814
+ ssl_compatibility_level: request.sslCompatibilityLevel,
815
+ tags: request.tags,
816
+ type: request.type,
817
+ ...resolveOneOf([{
818
+ default: defaults.defaultProjectId,
819
+ param: "project_id",
820
+ value: request.projectId
821
+ }, {
822
+ default: defaults.defaultOrganizationId,
823
+ param: "organization_id",
824
+ value: request.organizationId
825
+ }])
1063
826
  });
1064
827
  const marshalZonedApiCreateRouteRequest = (request, defaults) => ({
1065
- backend_id: request.backendId,
1066
- frontend_id: request.frontendId,
1067
- match: request.match !== void 0 ? marshalRouteMatch(request.match) : void 0
828
+ backend_id: request.backendId,
829
+ frontend_id: request.frontendId,
830
+ match: request.match !== void 0 ? marshalRouteMatch(request.match, defaults) : void 0
1068
831
  });
1069
832
  const marshalZonedApiCreateSubscriberRequest = (request, defaults) => ({
1070
- name: request.name,
1071
- ...resolveOneOf([
1072
- {
1073
- default: defaults.defaultProjectId,
1074
- param: "project_id",
1075
- value: request.projectId
1076
- },
1077
- {
1078
- default: defaults.defaultOrganizationId,
1079
- param: "organization_id",
1080
- value: request.organizationId
1081
- }
1082
- ]),
1083
- ...resolveOneOf([
1084
- {
1085
- param: "email_config",
1086
- value: request.emailConfig !== void 0 ? marshalSubscriberEmailConfig(request.emailConfig) : void 0
1087
- },
1088
- {
1089
- param: "webhook_config",
1090
- value: request.webhookConfig !== void 0 ? marshalSubscriberWebhookConfig(request.webhookConfig) : void 0
1091
- }
1092
- ])
1093
- });
1094
- const marshalZonedApiDetachPrivateNetworkRequest = (request, defaults) => ({
1095
- private_network_id: request.privateNetworkId
1096
- });
1097
- const marshalZonedApiMigrateLbRequest = (request, defaults) => ({
1098
- type: request.type
1099
- });
1100
- const marshalZonedApiRemoveBackendServersRequest = (request, defaults) => ({
1101
- server_ip: request.serverIp
1102
- });
1103
- const marshalAclSpec = (request, defaults) => ({
1104
- action: marshalAclAction(request.action),
1105
- description: request.description,
1106
- index: request.index,
1107
- match: request.match !== void 0 ? marshalAclMatch(request.match) : void 0,
1108
- name: request.name
1109
- });
1110
- const marshalZonedApiSetAclsRequest = (request, defaults) => ({
1111
- acls: request.acls.map((elt) => marshalAclSpec(elt))
1112
- });
1113
- const marshalZonedApiSetBackendServersRequest = (request, defaults) => ({
1114
- server_ip: request.serverIp
1115
- });
1116
- const marshalZonedApiSubscribeToLbRequest = (request, defaults) => ({
1117
- subscriber_id: request.subscriberId
1118
- });
833
+ name: request.name,
834
+ ...resolveOneOf([{
835
+ default: defaults.defaultProjectId,
836
+ param: "project_id",
837
+ value: request.projectId
838
+ }, {
839
+ default: defaults.defaultOrganizationId,
840
+ param: "organization_id",
841
+ value: request.organizationId
842
+ }]),
843
+ ...resolveOneOf([{
844
+ param: "email_config",
845
+ value: request.emailConfig !== void 0 ? marshalSubscriberEmailConfig(request.emailConfig, defaults) : void 0
846
+ }, {
847
+ param: "webhook_config",
848
+ value: request.webhookConfig !== void 0 ? marshalSubscriberWebhookConfig(request.webhookConfig, defaults) : void 0
849
+ }])
850
+ });
851
+ const marshalZonedApiDetachPrivateNetworkRequest = (request, defaults) => ({ private_network_id: request.privateNetworkId });
852
+ const marshalZonedApiMigrateLbRequest = (request, defaults) => ({ type: request.type });
853
+ const marshalZonedApiRemoveBackendServersRequest = (request, defaults) => ({ server_ip: request.serverIp });
854
+ var marshalAclSpec = (request, defaults) => ({
855
+ action: marshalAclAction(request.action, defaults),
856
+ description: request.description,
857
+ index: request.index,
858
+ match: request.match !== void 0 ? marshalAclMatch(request.match, defaults) : void 0,
859
+ name: request.name
860
+ });
861
+ const marshalZonedApiSetAclsRequest = (request, defaults) => ({ acls: request.acls.map((elt) => marshalAclSpec(elt, defaults)) });
862
+ const marshalZonedApiSetBackendServersRequest = (request, defaults) => ({ server_ip: request.serverIp });
863
+ const marshalZonedApiSubscribeToLbRequest = (request, defaults) => ({ subscriber_id: request.subscriberId });
1119
864
  const marshalZonedApiUpdateAclRequest = (request, defaults) => ({
1120
- action: marshalAclAction(request.action),
1121
- description: request.description,
1122
- index: request.index,
1123
- match: request.match !== void 0 ? marshalAclMatch(request.match) : void 0,
1124
- name: request.name
865
+ action: marshalAclAction(request.action, defaults),
866
+ description: request.description,
867
+ index: request.index,
868
+ match: request.match !== void 0 ? marshalAclMatch(request.match, defaults) : void 0,
869
+ name: request.name
1125
870
  });
1126
871
  const marshalZonedApiUpdateBackendRequest = (request, defaults) => ({
1127
- failover_host: request.failoverHost,
1128
- forward_port: request.forwardPort,
1129
- forward_port_algorithm: request.forwardPortAlgorithm,
1130
- forward_protocol: request.forwardProtocol,
1131
- ignore_ssl_server_verify: request.ignoreSslServerVerify,
1132
- max_connections: request.maxConnections,
1133
- max_retries: request.maxRetries,
1134
- name: request.name,
1135
- on_marked_down_action: request.onMarkedDownAction,
1136
- proxy_protocol: request.proxyProtocol,
1137
- redispatch_attempt_count: request.redispatchAttemptCount,
1138
- send_proxy_v2: request.sendProxyV2,
1139
- ssl_bridging: request.sslBridging,
1140
- sticky_sessions: request.stickySessions,
1141
- sticky_sessions_cookie_name: request.stickySessionsCookieName,
1142
- timeout_connect: request.timeoutConnect,
1143
- timeout_queue: request.timeoutQueue,
1144
- timeout_server: request.timeoutServer,
1145
- timeout_tunnel: request.timeoutTunnel
1146
- });
1147
- const marshalZonedApiUpdateCertificateRequest = (request, defaults) => ({
1148
- name: request.name
1149
- });
872
+ failover_host: request.failoverHost,
873
+ forward_port: request.forwardPort,
874
+ forward_port_algorithm: request.forwardPortAlgorithm,
875
+ forward_protocol: request.forwardProtocol,
876
+ ignore_ssl_server_verify: request.ignoreSslServerVerify,
877
+ max_connections: request.maxConnections,
878
+ max_retries: request.maxRetries,
879
+ name: request.name,
880
+ on_marked_down_action: request.onMarkedDownAction,
881
+ proxy_protocol: request.proxyProtocol,
882
+ redispatch_attempt_count: request.redispatchAttemptCount,
883
+ send_proxy_v2: request.sendProxyV2,
884
+ ssl_bridging: request.sslBridging,
885
+ sticky_sessions: request.stickySessions,
886
+ sticky_sessions_cookie_name: request.stickySessionsCookieName,
887
+ timeout_connect: request.timeoutConnect,
888
+ timeout_queue: request.timeoutQueue,
889
+ timeout_server: request.timeoutServer,
890
+ timeout_tunnel: request.timeoutTunnel
891
+ });
892
+ const marshalZonedApiUpdateCertificateRequest = (request, defaults) => ({ name: request.name });
1150
893
  const marshalZonedApiUpdateFrontendRequest = (request, defaults) => ({
1151
- backend_id: request.backendId,
1152
- certificate_id: request.certificateId,
1153
- certificate_ids: request.certificateIds,
1154
- connection_rate_limit: request.connectionRateLimit,
1155
- enable_access_logs: request.enableAccessLogs,
1156
- enable_http3: request.enableHttp3,
1157
- inbound_port: request.inboundPort,
1158
- name: request.name,
1159
- timeout_client: request.timeoutClient
894
+ backend_id: request.backendId,
895
+ certificate_id: request.certificateId,
896
+ certificate_ids: request.certificateIds,
897
+ connection_rate_limit: request.connectionRateLimit,
898
+ enable_access_logs: request.enableAccessLogs,
899
+ enable_http3: request.enableHttp3,
900
+ inbound_port: request.inboundPort,
901
+ name: request.name,
902
+ timeout_client: request.timeoutClient
1160
903
  });
1161
904
  const marshalZonedApiUpdateHealthCheckRequest = (request, defaults) => ({
1162
- check_delay: request.checkDelay,
1163
- check_max_retries: request.checkMaxRetries,
1164
- check_send_proxy: request.checkSendProxy,
1165
- check_timeout: request.checkTimeout,
1166
- port: request.port,
1167
- transient_check_delay: request.transientCheckDelay,
1168
- ...resolveOneOf([
1169
- {
1170
- param: "tcp_config",
1171
- value: request.tcpConfig !== void 0 ? marshalHealthCheckTcpConfig(request.tcpConfig) : void 0
1172
- },
1173
- {
1174
- param: "mysql_config",
1175
- value: request.mysqlConfig !== void 0 ? marshalHealthCheckMysqlConfig(request.mysqlConfig) : void 0
1176
- },
1177
- {
1178
- param: "pgsql_config",
1179
- value: request.pgsqlConfig !== void 0 ? marshalHealthCheckPgsqlConfig(request.pgsqlConfig) : void 0
1180
- },
1181
- {
1182
- param: "ldap_config",
1183
- value: request.ldapConfig !== void 0 ? marshalHealthCheckLdapConfig(request.ldapConfig) : void 0
1184
- },
1185
- {
1186
- param: "redis_config",
1187
- value: request.redisConfig !== void 0 ? marshalHealthCheckRedisConfig(request.redisConfig) : void 0
1188
- },
1189
- {
1190
- param: "http_config",
1191
- value: request.httpConfig !== void 0 ? marshalHealthCheckHttpConfig(request.httpConfig) : void 0
1192
- },
1193
- {
1194
- param: "https_config",
1195
- value: request.httpsConfig !== void 0 ? marshalHealthCheckHttpsConfig(request.httpsConfig) : void 0
1196
- }
1197
- ])
905
+ check_delay: request.checkDelay,
906
+ check_max_retries: request.checkMaxRetries,
907
+ check_send_proxy: request.checkSendProxy,
908
+ check_timeout: request.checkTimeout,
909
+ port: request.port,
910
+ transient_check_delay: request.transientCheckDelay,
911
+ ...resolveOneOf([
912
+ {
913
+ param: "tcp_config",
914
+ value: request.tcpConfig !== void 0 ? marshalHealthCheckTcpConfig(request.tcpConfig, defaults) : void 0
915
+ },
916
+ {
917
+ param: "mysql_config",
918
+ value: request.mysqlConfig !== void 0 ? marshalHealthCheckMysqlConfig(request.mysqlConfig, defaults) : void 0
919
+ },
920
+ {
921
+ param: "pgsql_config",
922
+ value: request.pgsqlConfig !== void 0 ? marshalHealthCheckPgsqlConfig(request.pgsqlConfig, defaults) : void 0
923
+ },
924
+ {
925
+ param: "ldap_config",
926
+ value: request.ldapConfig !== void 0 ? marshalHealthCheckLdapConfig(request.ldapConfig, defaults) : void 0
927
+ },
928
+ {
929
+ param: "redis_config",
930
+ value: request.redisConfig !== void 0 ? marshalHealthCheckRedisConfig(request.redisConfig, defaults) : void 0
931
+ },
932
+ {
933
+ param: "http_config",
934
+ value: request.httpConfig !== void 0 ? marshalHealthCheckHttpConfig(request.httpConfig, defaults) : void 0
935
+ },
936
+ {
937
+ param: "https_config",
938
+ value: request.httpsConfig !== void 0 ? marshalHealthCheckHttpsConfig(request.httpsConfig, defaults) : void 0
939
+ }
940
+ ])
1198
941
  });
1199
942
  const marshalZonedApiUpdateIpRequest = (request, defaults) => ({
1200
- lb_id: request.lbId,
1201
- reverse: request.reverse,
1202
- tags: request.tags
943
+ lb_id: request.lbId,
944
+ reverse: request.reverse,
945
+ tags: request.tags
1203
946
  });
1204
947
  const marshalZonedApiUpdateLbRequest = (request, defaults) => ({
1205
- description: request.description,
1206
- name: request.name,
1207
- ssl_compatibility_level: request.sslCompatibilityLevel,
1208
- tags: request.tags
948
+ description: request.description,
949
+ name: request.name,
950
+ ssl_compatibility_level: request.sslCompatibilityLevel,
951
+ tags: request.tags
1209
952
  });
1210
953
  const marshalZonedApiUpdateRouteRequest = (request, defaults) => ({
1211
- backend_id: request.backendId,
1212
- match: request.match !== void 0 ? marshalRouteMatch(request.match) : void 0
954
+ backend_id: request.backendId,
955
+ match: request.match !== void 0 ? marshalRouteMatch(request.match, defaults) : void 0
1213
956
  });
1214
957
  const marshalZonedApiUpdateSubscriberRequest = (request, defaults) => ({
1215
- name: request.name,
1216
- ...resolveOneOf([
1217
- {
1218
- param: "email_config",
1219
- value: request.emailConfig !== void 0 ? marshalSubscriberEmailConfig(request.emailConfig) : void 0
1220
- },
1221
- {
1222
- param: "webhook_config",
1223
- value: request.webhookConfig !== void 0 ? marshalSubscriberWebhookConfig(request.webhookConfig) : void 0
1224
- }
1225
- ])
1226
- });
1227
- export {
1228
- marshalAddBackendServersRequest,
1229
- marshalAttachPrivateNetworkRequest,
1230
- marshalCreateAclRequest,
1231
- marshalCreateBackendRequest,
1232
- marshalCreateCertificateRequest,
1233
- marshalCreateFrontendRequest,
1234
- marshalCreateIpRequest,
1235
- marshalCreateLbRequest,
1236
- marshalCreateRouteRequest,
1237
- marshalCreateSubscriberRequest,
1238
- marshalMigrateLbRequest,
1239
- marshalRemoveBackendServersRequest,
1240
- marshalSetBackendServersRequest,
1241
- marshalSubscribeToLbRequest,
1242
- marshalUpdateAclRequest,
1243
- marshalUpdateBackendRequest,
1244
- marshalUpdateCertificateRequest,
1245
- marshalUpdateFrontendRequest,
1246
- marshalUpdateHealthCheckRequest,
1247
- marshalUpdateIpRequest,
1248
- marshalUpdateLbRequest,
1249
- marshalUpdateRouteRequest,
1250
- marshalUpdateSubscriberRequest,
1251
- marshalZonedApiAddBackendServersRequest,
1252
- marshalZonedApiAttachPrivateNetworkRequest,
1253
- marshalZonedApiCreateAclRequest,
1254
- marshalZonedApiCreateBackendRequest,
1255
- marshalZonedApiCreateCertificateRequest,
1256
- marshalZonedApiCreateFrontendRequest,
1257
- marshalZonedApiCreateIpRequest,
1258
- marshalZonedApiCreateLbRequest,
1259
- marshalZonedApiCreateRouteRequest,
1260
- marshalZonedApiCreateSubscriberRequest,
1261
- marshalZonedApiDetachPrivateNetworkRequest,
1262
- marshalZonedApiMigrateLbRequest,
1263
- marshalZonedApiRemoveBackendServersRequest,
1264
- marshalZonedApiSetAclsRequest,
1265
- marshalZonedApiSetBackendServersRequest,
1266
- marshalZonedApiSubscribeToLbRequest,
1267
- marshalZonedApiUpdateAclRequest,
1268
- marshalZonedApiUpdateBackendRequest,
1269
- marshalZonedApiUpdateCertificateRequest,
1270
- marshalZonedApiUpdateFrontendRequest,
1271
- marshalZonedApiUpdateHealthCheckRequest,
1272
- marshalZonedApiUpdateIpRequest,
1273
- marshalZonedApiUpdateLbRequest,
1274
- marshalZonedApiUpdateRouteRequest,
1275
- marshalZonedApiUpdateSubscriberRequest,
1276
- unmarshalAcl,
1277
- unmarshalBackend,
1278
- unmarshalBackendServerStats,
1279
- unmarshalCertificate,
1280
- unmarshalFrontend,
1281
- unmarshalHealthCheck,
1282
- unmarshalIp,
1283
- unmarshalLb,
1284
- unmarshalLbStats,
1285
- unmarshalListAclResponse,
1286
- unmarshalListBackendStatsResponse,
1287
- unmarshalListBackendsResponse,
1288
- unmarshalListCertificatesResponse,
1289
- unmarshalListFrontendsResponse,
1290
- unmarshalListIpsResponse,
1291
- unmarshalListLbPrivateNetworksResponse,
1292
- unmarshalListLbTypesResponse,
1293
- unmarshalListLbsResponse,
1294
- unmarshalListRoutesResponse,
1295
- unmarshalListSubscriberResponse,
1296
- unmarshalPrivateNetwork,
1297
- unmarshalRoute,
1298
- unmarshalSetAclsResponse,
1299
- unmarshalSubscriber
1300
- };
958
+ name: request.name,
959
+ ...resolveOneOf([{
960
+ param: "email_config",
961
+ value: request.emailConfig !== void 0 ? marshalSubscriberEmailConfig(request.emailConfig, defaults) : void 0
962
+ }, {
963
+ param: "webhook_config",
964
+ value: request.webhookConfig !== void 0 ? marshalSubscriberWebhookConfig(request.webhookConfig, defaults) : void 0
965
+ }])
966
+ });
967
+ export { marshalAddBackendServersRequest, marshalAttachPrivateNetworkRequest, marshalCreateAclRequest, marshalCreateBackendRequest, marshalCreateCertificateRequest, marshalCreateFrontendRequest, marshalCreateIpRequest, marshalCreateLbRequest, marshalCreateRouteRequest, marshalCreateSubscriberRequest, marshalMigrateLbRequest, marshalRemoveBackendServersRequest, marshalSetBackendServersRequest, marshalSubscribeToLbRequest, marshalUpdateAclRequest, marshalUpdateBackendRequest, marshalUpdateCertificateRequest, marshalUpdateFrontendRequest, marshalUpdateHealthCheckRequest, marshalUpdateIpRequest, marshalUpdateLbRequest, marshalUpdateRouteRequest, marshalUpdateSubscriberRequest, marshalZonedApiAddBackendServersRequest, marshalZonedApiAttachPrivateNetworkRequest, marshalZonedApiCreateAclRequest, marshalZonedApiCreateBackendRequest, marshalZonedApiCreateCertificateRequest, marshalZonedApiCreateFrontendRequest, marshalZonedApiCreateIpRequest, marshalZonedApiCreateLbRequest, marshalZonedApiCreateRouteRequest, marshalZonedApiCreateSubscriberRequest, marshalZonedApiDetachPrivateNetworkRequest, marshalZonedApiMigrateLbRequest, marshalZonedApiRemoveBackendServersRequest, marshalZonedApiSetAclsRequest, marshalZonedApiSetBackendServersRequest, marshalZonedApiSubscribeToLbRequest, marshalZonedApiUpdateAclRequest, marshalZonedApiUpdateBackendRequest, marshalZonedApiUpdateCertificateRequest, marshalZonedApiUpdateFrontendRequest, marshalZonedApiUpdateHealthCheckRequest, marshalZonedApiUpdateIpRequest, marshalZonedApiUpdateLbRequest, marshalZonedApiUpdateRouteRequest, marshalZonedApiUpdateSubscriberRequest, unmarshalAcl, unmarshalBackend, unmarshalBackendServerStats, unmarshalCertificate, unmarshalFrontend, unmarshalHealthCheck, unmarshalIp, unmarshalLb, unmarshalLbStats, unmarshalListAclResponse, unmarshalListBackendStatsResponse, unmarshalListBackendsResponse, unmarshalListCertificatesResponse, unmarshalListFrontendsResponse, unmarshalListIpsResponse, unmarshalListLbPrivateNetworksResponse, unmarshalListLbTypesResponse, unmarshalListLbsResponse, unmarshalListRoutesResponse, unmarshalListSubscriberResponse, unmarshalPrivateNetwork, unmarshalRoute, unmarshalSetAclsResponse, unmarshalSubscriber };