cloudflare 3.0.0-beta.1 → 3.0.0-beta.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.
Files changed (115) hide show
  1. package/CHANGELOG.md +22 -0
  2. package/index.d.mts +1 -1
  3. package/index.d.ts +1 -1
  4. package/package.json +1 -1
  5. package/resources/alerting/v3/destinations/destinations.d.ts +2 -1
  6. package/resources/alerting/v3/destinations/destinations.d.ts.map +1 -1
  7. package/resources/alerting/v3/destinations/destinations.js.map +1 -1
  8. package/resources/alerting/v3/destinations/destinations.mjs.map +1 -1
  9. package/resources/alerting/v3/destinations/index.d.ts +2 -2
  10. package/resources/alerting/v3/destinations/index.d.ts.map +1 -1
  11. package/resources/alerting/v3/destinations/index.js +5 -5
  12. package/resources/alerting/v3/destinations/index.js.map +1 -1
  13. package/resources/alerting/v3/destinations/index.mjs +2 -2
  14. package/resources/alerting/v3/destinations/index.mjs.map +1 -1
  15. package/resources/alerting/v3/destinations/pagerduty.d.ts +12 -13
  16. package/resources/alerting/v3/destinations/pagerduty.d.ts.map +1 -1
  17. package/resources/alerting/v3/destinations/pagerduty.js.map +1 -1
  18. package/resources/alerting/v3/destinations/pagerduty.mjs.map +1 -1
  19. package/resources/alerting/v3/destinations/webhooks.d.ts +17 -58
  20. package/resources/alerting/v3/destinations/webhooks.d.ts.map +1 -1
  21. package/resources/alerting/v3/destinations/webhooks.js.map +1 -1
  22. package/resources/alerting/v3/destinations/webhooks.mjs.map +1 -1
  23. package/resources/alerting/v3/histories.d.ts +5 -5
  24. package/resources/alerting/v3/histories.d.ts.map +1 -1
  25. package/resources/alerting/v3/histories.js +5 -5
  26. package/resources/alerting/v3/histories.js.map +1 -1
  27. package/resources/alerting/v3/histories.mjs +3 -3
  28. package/resources/alerting/v3/histories.mjs.map +1 -1
  29. package/resources/alerting/v3/index.d.ts +2 -2
  30. package/resources/alerting/v3/index.d.ts.map +1 -1
  31. package/resources/alerting/v3/index.js +4 -4
  32. package/resources/alerting/v3/index.js.map +1 -1
  33. package/resources/alerting/v3/index.mjs +2 -2
  34. package/resources/alerting/v3/index.mjs.map +1 -1
  35. package/resources/alerting/v3/policies.d.ts +20 -235
  36. package/resources/alerting/v3/policies.d.ts.map +1 -1
  37. package/resources/alerting/v3/policies.js.map +1 -1
  38. package/resources/alerting/v3/policies.mjs.map +1 -1
  39. package/resources/alerting/v3/v3.d.ts +3 -3
  40. package/resources/alerting/v3/v3.d.ts.map +1 -1
  41. package/resources/alerting/v3/v3.js +1 -1
  42. package/resources/alerting/v3/v3.js.map +1 -1
  43. package/resources/alerting/v3/v3.mjs +1 -1
  44. package/resources/alerting/v3/v3.mjs.map +1 -1
  45. package/resources/challenges/challenges.d.ts +9 -0
  46. package/resources/challenges/challenges.d.ts.map +1 -1
  47. package/resources/challenges/challenges.js +1 -0
  48. package/resources/challenges/challenges.js.map +1 -1
  49. package/resources/challenges/challenges.mjs +1 -0
  50. package/resources/challenges/challenges.mjs.map +1 -1
  51. package/resources/challenges/index.d.ts +1 -1
  52. package/resources/challenges/index.d.ts.map +1 -1
  53. package/resources/challenges/index.js +2 -1
  54. package/resources/challenges/index.js.map +1 -1
  55. package/resources/challenges/index.mjs +1 -1
  56. package/resources/challenges/index.mjs.map +1 -1
  57. package/resources/challenges/widgets.d.ts +267 -0
  58. package/resources/challenges/widgets.d.ts.map +1 -1
  59. package/resources/challenges/widgets.js +87 -1
  60. package/resources/challenges/widgets.js.map +1 -1
  61. package/resources/challenges/widgets.mjs +62 -0
  62. package/resources/challenges/widgets.mjs.map +1 -1
  63. package/resources/index.d.ts +1 -1
  64. package/resources/ips.d.ts +3 -3
  65. package/resources/page-shield/scripts.d.ts +12 -0
  66. package/resources/page-shield/scripts.d.ts.map +1 -1
  67. package/resources/page-shield/scripts.js.map +1 -1
  68. package/resources/page-shield/scripts.mjs.map +1 -1
  69. package/resources/zero-trust/access/access.d.ts +1 -1
  70. package/resources/zero-trust/access/access.d.ts.map +1 -1
  71. package/resources/zero-trust/access/certificates/certificates.d.ts +2 -2
  72. package/resources/zero-trust/access/certificates/certificates.d.ts.map +1 -1
  73. package/resources/zero-trust/access/certificates/index.d.ts +1 -1
  74. package/resources/zero-trust/access/certificates/index.d.ts.map +1 -1
  75. package/resources/zero-trust/access/certificates/settings.d.ts +6 -6
  76. package/resources/zero-trust/access/certificates/settings.d.ts.map +1 -1
  77. package/resources/zero-trust/access/certificates/settings.js +2 -2
  78. package/resources/zero-trust/access/certificates/settings.js.map +1 -1
  79. package/resources/zero-trust/access/certificates/settings.mjs +2 -2
  80. package/resources/zero-trust/access/certificates/settings.mjs.map +1 -1
  81. package/resources/zero-trust/access/index.d.ts +1 -1
  82. package/resources/zero-trust/access/index.d.ts.map +1 -1
  83. package/resources/zero-trust/access/index.js.map +1 -1
  84. package/resources/zero-trust/access/index.mjs.map +1 -1
  85. package/resources/zero-trust/access/keys.d.ts +3 -3
  86. package/resources/zero-trust/access/keys.d.ts.map +1 -1
  87. package/resources/zero-trust/access/keys.js +1 -1
  88. package/resources/zero-trust/access/keys.js.map +1 -1
  89. package/resources/zero-trust/access/keys.mjs +1 -1
  90. package/resources/zero-trust/access/keys.mjs.map +1 -1
  91. package/src/index.ts +1 -1
  92. package/src/resources/alerting/v3/destinations/destinations.ts +2 -1
  93. package/src/resources/alerting/v3/destinations/index.ts +4 -3
  94. package/src/resources/alerting/v3/destinations/pagerduty.ts +14 -15
  95. package/src/resources/alerting/v3/destinations/webhooks.ts +22 -71
  96. package/src/resources/alerting/v3/histories.ts +6 -6
  97. package/src/resources/alerting/v3/index.ts +3 -8
  98. package/src/resources/alerting/v3/policies.ts +25 -350
  99. package/src/resources/alerting/v3/v3.ts +3 -3
  100. package/src/resources/challenges/challenges.ts +9 -0
  101. package/src/resources/challenges/index.ts +12 -1
  102. package/src/resources/challenges/widgets.ts +391 -1
  103. package/src/resources/index.ts +1 -1
  104. package/src/resources/ips.ts +3 -3
  105. package/src/resources/page-shield/scripts.ts +18 -0
  106. package/src/resources/zero-trust/access/access.ts +1 -1
  107. package/src/resources/zero-trust/access/certificates/certificates.ts +2 -2
  108. package/src/resources/zero-trust/access/certificates/index.ts +2 -2
  109. package/src/resources/zero-trust/access/certificates/settings.ts +11 -14
  110. package/src/resources/zero-trust/access/index.ts +1 -1
  111. package/src/resources/zero-trust/access/keys.ts +4 -4
  112. package/src/version.ts +1 -1
  113. package/version.d.ts +1 -1
  114. package/version.js +1 -1
  115. package/version.mjs +1 -1
@@ -1,5 +1,395 @@
1
1
  // File generated from our OpenAPI spec by Stainless.
2
2
 
3
+ import * as Core from "../../core";
3
4
  import { APIResource } from "../../resource";
5
+ import * as WidgetsAPI from "./widgets";
6
+ import { V4PagePaginationArray, type V4PagePaginationArrayParams } from "../../pagination";
4
7
 
5
- export class Widgets extends APIResource {}
8
+ export class Widgets extends APIResource {
9
+ /**
10
+ * Lists challenge widgets.
11
+ */
12
+ create(
13
+ params: WidgetCreateParams,
14
+ options?: Core.RequestOptions,
15
+ ): Core.APIPromise<NcChallengesAdminWidgetDetail> {
16
+ const { account_id, direction, order, page, per_page, ...body } = params;
17
+ return (
18
+ this._client.post(`/accounts/${account_id}/challenges/widgets`, {
19
+ query: { direction, order, page, per_page },
20
+ body,
21
+ ...options,
22
+ }) as Core.APIPromise<{ result: NcChallengesAdminWidgetDetail }>
23
+ )._thenUnwrap((obj) => obj.result);
24
+ }
25
+
26
+ /**
27
+ * Update the configuration of a widget.
28
+ */
29
+ update(
30
+ sitekey: string,
31
+ params: WidgetUpdateParams,
32
+ options?: Core.RequestOptions,
33
+ ): Core.APIPromise<NcChallengesAdminWidgetDetail> {
34
+ const { account_id, ...body } = params;
35
+ return (
36
+ this._client.put(`/accounts/${account_id}/challenges/widgets/${sitekey}`, {
37
+ body,
38
+ ...options,
39
+ }) as Core.APIPromise<{ result: NcChallengesAdminWidgetDetail }>
40
+ )._thenUnwrap((obj) => obj.result);
41
+ }
42
+
43
+ /**
44
+ * Lists all turnstile widgets of an account.
45
+ */
46
+ list(
47
+ params: WidgetListParams,
48
+ options?: Core.RequestOptions,
49
+ ): Core.PagePromise<NcChallengesAdminWidgetListsV4PagePaginationArray, NcChallengesAdminWidgetList> {
50
+ const { account_id, ...query } = params;
51
+ return this._client.getAPIList(
52
+ `/accounts/${account_id}/challenges/widgets`,
53
+ NcChallengesAdminWidgetListsV4PagePaginationArray,
54
+ { query, ...options },
55
+ );
56
+ }
57
+
58
+ /**
59
+ * Destroy a Turnstile Widget.
60
+ */
61
+ delete(
62
+ sitekey: string,
63
+ params: WidgetDeleteParams,
64
+ options?: Core.RequestOptions,
65
+ ): Core.APIPromise<NcChallengesAdminWidgetDetail> {
66
+ const { account_id } = params;
67
+ return (
68
+ this._client.delete(
69
+ `/accounts/${account_id}/challenges/widgets/${sitekey}`,
70
+ options,
71
+ ) as Core.APIPromise<{ result: NcChallengesAdminWidgetDetail }>
72
+ )._thenUnwrap((obj) => obj.result);
73
+ }
74
+
75
+ /**
76
+ * Show a single challenge widget configuration.
77
+ */
78
+ get(
79
+ sitekey: string,
80
+ params: WidgetGetParams,
81
+ options?: Core.RequestOptions,
82
+ ): Core.APIPromise<NcChallengesAdminWidgetDetail> {
83
+ const { account_id } = params;
84
+ return (
85
+ this._client.get(`/accounts/${account_id}/challenges/widgets/${sitekey}`, options) as Core.APIPromise<{
86
+ result: NcChallengesAdminWidgetDetail;
87
+ }>
88
+ )._thenUnwrap((obj) => obj.result);
89
+ }
90
+
91
+ /**
92
+ * Generate a new secret key for this widget. If `invalidate_immediately` is set to
93
+ * `false`, the previous secret remains valid for 2 hours.
94
+ *
95
+ * Note that secrets cannot be rotated again during the grace period.
96
+ */
97
+ rotateSecret(
98
+ sitekey: string,
99
+ params: WidgetRotateSecretParams,
100
+ options?: Core.RequestOptions,
101
+ ): Core.APIPromise<NcChallengesAdminWidgetDetail> {
102
+ const { account_id, ...body } = params;
103
+ return (
104
+ this._client.post(`/accounts/${account_id}/challenges/widgets/${sitekey}/rotate_secret`, {
105
+ body,
106
+ ...options,
107
+ }) as Core.APIPromise<{ result: NcChallengesAdminWidgetDetail }>
108
+ )._thenUnwrap((obj) => obj.result);
109
+ }
110
+ }
111
+
112
+ export class NcChallengesAdminWidgetListsV4PagePaginationArray extends V4PagePaginationArray<NcChallengesAdminWidgetList> {}
113
+
114
+ /**
115
+ * A Turnstile widget's detailed configuration
116
+ */
117
+ export interface NcChallengesAdminWidgetDetail {
118
+ /**
119
+ * If bot_fight_mode is set to `true`, Cloudflare issues computationally expensive
120
+ * challenges in response to malicious bots (ENT only).
121
+ */
122
+ bot_fight_mode: boolean;
123
+
124
+ /**
125
+ * If Turnstile is embedded on a Cloudflare site and the widget should grant
126
+ * challenge clearance, this setting can determine the clearance level to be set
127
+ */
128
+ clearance_level: 'no_clearance' | 'jschallenge' | 'managed' | 'interactive';
129
+
130
+ /**
131
+ * When the widget was created.
132
+ */
133
+ created_on: string;
134
+
135
+ domains: Array<string>;
136
+
137
+ /**
138
+ * Widget Mode
139
+ */
140
+ mode: 'non-interactive' | 'invisible' | 'managed';
141
+
142
+ /**
143
+ * When the widget was modified.
144
+ */
145
+ modified_on: string;
146
+
147
+ /**
148
+ * Human readable widget name. Not unique. Cloudflare suggests that you set this to
149
+ * a meaningful string to make it easier to identify your widget, and where it is
150
+ * used.
151
+ */
152
+ name: string;
153
+
154
+ /**
155
+ * Do not show any Cloudflare branding on the widget (ENT only).
156
+ */
157
+ offlabel: boolean;
158
+
159
+ /**
160
+ * Region where this widget can be used.
161
+ */
162
+ region: 'world';
163
+
164
+ /**
165
+ * Secret key for this widget.
166
+ */
167
+ secret: string;
168
+
169
+ /**
170
+ * Widget item identifier tag.
171
+ */
172
+ sitekey: string;
173
+ }
174
+
175
+ /**
176
+ * A Turnstile Widgets configuration as it appears in listings
177
+ */
178
+ export interface NcChallengesAdminWidgetList {
179
+ /**
180
+ * If bot_fight_mode is set to `true`, Cloudflare issues computationally expensive
181
+ * challenges in response to malicious bots (ENT only).
182
+ */
183
+ bot_fight_mode: boolean;
184
+
185
+ /**
186
+ * If Turnstile is embedded on a Cloudflare site and the widget should grant
187
+ * challenge clearance, this setting can determine the clearance level to be set
188
+ */
189
+ clearance_level: 'no_clearance' | 'jschallenge' | 'managed' | 'interactive';
190
+
191
+ /**
192
+ * When the widget was created.
193
+ */
194
+ created_on: string;
195
+
196
+ domains: Array<string>;
197
+
198
+ /**
199
+ * Widget Mode
200
+ */
201
+ mode: 'non-interactive' | 'invisible' | 'managed';
202
+
203
+ /**
204
+ * When the widget was modified.
205
+ */
206
+ modified_on: string;
207
+
208
+ /**
209
+ * Human readable widget name. Not unique. Cloudflare suggests that you set this to
210
+ * a meaningful string to make it easier to identify your widget, and where it is
211
+ * used.
212
+ */
213
+ name: string;
214
+
215
+ /**
216
+ * Do not show any Cloudflare branding on the widget (ENT only).
217
+ */
218
+ offlabel: boolean;
219
+
220
+ /**
221
+ * Region where this widget can be used.
222
+ */
223
+ region: 'world';
224
+
225
+ /**
226
+ * Widget item identifier tag.
227
+ */
228
+ sitekey: string;
229
+ }
230
+
231
+ export interface WidgetCreateParams {
232
+ /**
233
+ * Path param: Identifier
234
+ */
235
+ account_id: string;
236
+
237
+ /**
238
+ * Body param:
239
+ */
240
+ domains: Array<string>;
241
+
242
+ /**
243
+ * Body param: Widget Mode
244
+ */
245
+ mode: 'non-interactive' | 'invisible' | 'managed';
246
+
247
+ /**
248
+ * Body param: Human readable widget name. Not unique. Cloudflare suggests that you
249
+ * set this to a meaningful string to make it easier to identify your widget, and
250
+ * where it is used.
251
+ */
252
+ name: string;
253
+
254
+ /**
255
+ * Query param: Direction to order widgets.
256
+ */
257
+ direction?: 'asc' | 'desc';
258
+
259
+ /**
260
+ * Query param: Field to order widgets by.
261
+ */
262
+ order?: 'id' | 'sitekey' | 'name' | 'created_on' | 'modified_on';
263
+
264
+ /**
265
+ * Query param: Page number of paginated results.
266
+ */
267
+ page?: number;
268
+
269
+ /**
270
+ * Query param: Number of items per page.
271
+ */
272
+ per_page?: number;
273
+
274
+ /**
275
+ * Body param: If bot_fight_mode is set to `true`, Cloudflare issues
276
+ * computationally expensive challenges in response to malicious bots (ENT only).
277
+ */
278
+ bot_fight_mode?: boolean;
279
+
280
+ /**
281
+ * Body param: If Turnstile is embedded on a Cloudflare site and the widget should
282
+ * grant challenge clearance, this setting can determine the clearance level to be
283
+ * set
284
+ */
285
+ clearance_level?: 'no_clearance' | 'jschallenge' | 'managed' | 'interactive';
286
+
287
+ /**
288
+ * Body param: Do not show any Cloudflare branding on the widget (ENT only).
289
+ */
290
+ offlabel?: boolean;
291
+
292
+ /**
293
+ * Body param: Region where this widget can be used.
294
+ */
295
+ region?: 'world';
296
+ }
297
+
298
+ export interface WidgetUpdateParams {
299
+ /**
300
+ * Path param: Identifier
301
+ */
302
+ account_id: string;
303
+
304
+ /**
305
+ * Body param:
306
+ */
307
+ domains: Array<string>;
308
+
309
+ /**
310
+ * Body param: Widget Mode
311
+ */
312
+ mode: 'non-interactive' | 'invisible' | 'managed';
313
+
314
+ /**
315
+ * Body param: Human readable widget name. Not unique. Cloudflare suggests that you
316
+ * set this to a meaningful string to make it easier to identify your widget, and
317
+ * where it is used.
318
+ */
319
+ name: string;
320
+
321
+ /**
322
+ * Body param: If bot_fight_mode is set to `true`, Cloudflare issues
323
+ * computationally expensive challenges in response to malicious bots (ENT only).
324
+ */
325
+ bot_fight_mode?: boolean;
326
+
327
+ /**
328
+ * Body param: If Turnstile is embedded on a Cloudflare site and the widget should
329
+ * grant challenge clearance, this setting can determine the clearance level to be
330
+ * set
331
+ */
332
+ clearance_level?: 'no_clearance' | 'jschallenge' | 'managed' | 'interactive';
333
+
334
+ /**
335
+ * Body param: Do not show any Cloudflare branding on the widget (ENT only).
336
+ */
337
+ offlabel?: boolean;
338
+ }
339
+
340
+ export interface WidgetListParams extends V4PagePaginationArrayParams {
341
+ /**
342
+ * Path param: Identifier
343
+ */
344
+ account_id: string;
345
+
346
+ /**
347
+ * Query param: Direction to order widgets.
348
+ */
349
+ direction?: 'asc' | 'desc';
350
+
351
+ /**
352
+ * Query param: Field to order widgets by.
353
+ */
354
+ order?: 'id' | 'sitekey' | 'name' | 'created_on' | 'modified_on';
355
+ }
356
+
357
+ export interface WidgetDeleteParams {
358
+ /**
359
+ * Identifier
360
+ */
361
+ account_id: string;
362
+ }
363
+
364
+ export interface WidgetGetParams {
365
+ /**
366
+ * Identifier
367
+ */
368
+ account_id: string;
369
+ }
370
+
371
+ export interface WidgetRotateSecretParams {
372
+ /**
373
+ * Path param: Identifier
374
+ */
375
+ account_id: string;
376
+
377
+ /**
378
+ * Body param: If `invalidate_immediately` is set to `false`, the previous secret
379
+ * will remain valid for two hours. Otherwise, the secret is immediately
380
+ * invalidated, and requests using it will be rejected.
381
+ */
382
+ invalidate_immediately?: boolean;
383
+ }
384
+
385
+ export namespace Widgets {
386
+ export import NcChallengesAdminWidgetDetail = WidgetsAPI.NcChallengesAdminWidgetDetail;
387
+ export import NcChallengesAdminWidgetList = WidgetsAPI.NcChallengesAdminWidgetList;
388
+ export import NcChallengesAdminWidgetListsV4PagePaginationArray = WidgetsAPI.NcChallengesAdminWidgetListsV4PagePaginationArray;
389
+ export import WidgetCreateParams = WidgetsAPI.WidgetCreateParams;
390
+ export import WidgetUpdateParams = WidgetsAPI.WidgetUpdateParams;
391
+ export import WidgetListParams = WidgetsAPI.WidgetListParams;
392
+ export import WidgetDeleteParams = WidgetsAPI.WidgetDeleteParams;
393
+ export import WidgetGetParams = WidgetsAPI.WidgetGetParams;
394
+ export import WidgetRotateSecretParams = WidgetsAPI.WidgetRotateSecretParams;
395
+ }
@@ -85,7 +85,7 @@ export {
85
85
  } from './healthchecks/healthchecks';
86
86
  export { Hostnames } from './hostnames/hostnames';
87
87
  export { Hyperdrive } from './hyperdrive/hyperdrive';
88
- export { IPs, JdcloudIPs, IPListResponse, IPListParams } from './ips';
88
+ export { IPs, JDCloudIPs, IPListResponse, IPListParams } from './ips';
89
89
  export { Images } from './images/images';
90
90
  export { Intel } from './intel/intel';
91
91
  export {
@@ -44,7 +44,7 @@ export interface IPs {
44
44
  ipv6_cidrs?: Array<string>;
45
45
  }
46
46
 
47
- export interface JdcloudIPs {
47
+ export interface JDCloudIPs {
48
48
  /**
49
49
  * A digest of the IP data. Useful for determining if the data has changed.
50
50
  */
@@ -66,7 +66,7 @@ export interface JdcloudIPs {
66
66
  jdcloud_cidrs?: Array<string>;
67
67
  }
68
68
 
69
- export type IPListResponse = IPs | JdcloudIPs;
69
+ export type IPListResponse = IPs | JDCloudIPs;
70
70
 
71
71
  export interface IPListParams {
72
72
  /**
@@ -77,7 +77,7 @@ export interface IPListParams {
77
77
 
78
78
  export namespace IPs {
79
79
  export import IPs = IPsAPI.IPs;
80
- export import JdcloudIPs = IPsAPI.JdcloudIPs;
80
+ export import JDCloudIPs = IPsAPI.JDCloudIPs;
81
81
  export import IPListResponse = IPsAPI.IPListResponse;
82
82
  export import IPListParams = IPsAPI.IPListParams;
83
83
  }
@@ -35,6 +35,8 @@ export interface PageShieldScript {
35
35
 
36
36
  added_at?: unknown;
37
37
 
38
+ dataflow_score?: unknown;
39
+
38
40
  domain_reported_malicious?: unknown;
39
41
 
40
42
  fetched_at?: unknown;
@@ -51,6 +53,8 @@ export interface PageShieldScript {
51
53
 
52
54
  last_seen_at?: unknown;
53
55
 
56
+ obfuscation_score?: unknown;
57
+
54
58
  page_urls?: unknown;
55
59
 
56
60
  url?: unknown;
@@ -65,6 +69,8 @@ export interface ScriptGetResponse {
65
69
 
66
70
  added_at?: unknown;
67
71
 
72
+ dataflow_score?: unknown;
73
+
68
74
  domain_reported_malicious?: unknown;
69
75
 
70
76
  fetched_at?: unknown;
@@ -81,6 +87,8 @@ export interface ScriptGetResponse {
81
87
 
82
88
  last_seen_at?: unknown;
83
89
 
90
+ obfuscation_score?: unknown;
91
+
84
92
  page_urls?: unknown;
85
93
 
86
94
  url?: unknown;
@@ -95,6 +103,11 @@ export namespace ScriptGetResponse {
95
103
  * The version of the analyzed script.
96
104
  */
97
105
  export interface Version {
106
+ /**
107
+ * The dataflow score of the JavaScript content.
108
+ */
109
+ dataflow_score?: number | null;
110
+
98
111
  /**
99
112
  * The timestamp of when the script was last fetched.
100
113
  */
@@ -109,6 +122,11 @@ export namespace ScriptGetResponse {
109
122
  * The integrity score of the JavaScript content.
110
123
  */
111
124
  js_integrity_score?: number | null;
125
+
126
+ /**
127
+ * The obfuscation score of the JavaScript content.
128
+ */
129
+ obfuscation_score?: number | null;
112
130
  }
113
131
  }
114
132
 
@@ -70,7 +70,7 @@ export namespace Access {
70
70
  export import BookmarkDeleteResponse = BookmarksAPI.BookmarkDeleteResponse;
71
71
  export import Keys = KeysAPI.Keys;
72
72
  export import KeyUpdateResponse = KeysAPI.KeyUpdateResponse;
73
- export import KeyListResponse = KeysAPI.KeyListResponse;
73
+ export import KeyGetResponse = KeysAPI.KeyGetResponse;
74
74
  export import KeyRotateResponse = KeysAPI.KeyRotateResponse;
75
75
  export import KeyUpdateParams = KeysAPI.KeyUpdateParams;
76
76
  export import Logs = LogsAPI.Logs;
@@ -338,7 +338,7 @@ export namespace Certificates {
338
338
  export import Settings = SettingsAPI.Settings;
339
339
  export import AccessSettings = SettingsAPI.AccessSettings;
340
340
  export import SettingUpdateResponse = SettingsAPI.SettingUpdateResponse;
341
- export import SettingListResponse = SettingsAPI.SettingListResponse;
341
+ export import SettingGetResponse = SettingsAPI.SettingGetResponse;
342
342
  export import SettingUpdateParams = SettingsAPI.SettingUpdateParams;
343
- export import SettingListParams = SettingsAPI.SettingListParams;
343
+ export import SettingGetParams = SettingsAPI.SettingGetParams;
344
344
  }
@@ -14,8 +14,8 @@ export {
14
14
  export {
15
15
  AccessSettings,
16
16
  SettingUpdateResponse,
17
- SettingListResponse,
17
+ SettingGetResponse,
18
18
  SettingUpdateParams,
19
- SettingListParams,
19
+ SettingGetParams,
20
20
  Settings,
21
21
  } from './settings';
@@ -42,17 +42,14 @@ export class Settings extends APIResource {
42
42
  /**
43
43
  * List all mTLS hostname settings for this account or zone.
44
44
  */
45
- list(
46
- params?: SettingListParams,
45
+ get(params?: SettingGetParams, options?: Core.RequestOptions): Core.APIPromise<SettingGetResponse | null>;
46
+ get(options?: Core.RequestOptions): Core.APIPromise<SettingGetResponse | null>;
47
+ get(
48
+ params: SettingGetParams | Core.RequestOptions = {},
47
49
  options?: Core.RequestOptions,
48
- ): Core.APIPromise<SettingListResponse | null>;
49
- list(options?: Core.RequestOptions): Core.APIPromise<SettingListResponse | null>;
50
- list(
51
- params: SettingListParams | Core.RequestOptions = {},
52
- options?: Core.RequestOptions,
53
- ): Core.APIPromise<SettingListResponse | null> {
50
+ ): Core.APIPromise<SettingGetResponse | null> {
54
51
  if (isRequestOptions(params)) {
55
- return this.list({}, params);
52
+ return this.get({}, params);
56
53
  }
57
54
  const { account_id, zone_id } = params;
58
55
  if (!account_id && !zone_id) {
@@ -75,7 +72,7 @@ export class Settings extends APIResource {
75
72
  this._client.get(
76
73
  `/${accountOrZone}/${accountOrZoneId}/access/certificates/settings`,
77
74
  options,
78
- ) as Core.APIPromise<{ result: SettingListResponse | null }>
75
+ ) as Core.APIPromise<{ result: SettingGetResponse | null }>
79
76
  )._thenUnwrap((obj) => obj.result);
80
77
  }
81
78
  }
@@ -102,7 +99,7 @@ export interface AccessSettings {
102
99
 
103
100
  export type SettingUpdateResponse = Array<AccessSettings>;
104
101
 
105
- export type SettingListResponse = Array<AccessSettings>;
102
+ export type SettingGetResponse = Array<AccessSettings>;
106
103
 
107
104
  export interface SettingUpdateParams {
108
105
  /**
@@ -123,7 +120,7 @@ export interface SettingUpdateParams {
123
120
  zone_id?: string;
124
121
  }
125
122
 
126
- export interface SettingListParams {
123
+ export interface SettingGetParams {
127
124
  /**
128
125
  * The Account ID to use for this endpoint. Mutually exclusive with the Zone ID.
129
126
  */
@@ -138,7 +135,7 @@ export interface SettingListParams {
138
135
  export namespace Settings {
139
136
  export import AccessSettings = SettingsAPI.AccessSettings;
140
137
  export import SettingUpdateResponse = SettingsAPI.SettingUpdateResponse;
141
- export import SettingListResponse = SettingsAPI.SettingListResponse;
138
+ export import SettingGetResponse = SettingsAPI.SettingGetResponse;
142
139
  export import SettingUpdateParams = SettingsAPI.SettingUpdateParams;
143
- export import SettingListParams = SettingsAPI.SettingListParams;
140
+ export import SettingGetParams = SettingsAPI.SettingGetParams;
144
141
  }
@@ -66,5 +66,5 @@ export {
66
66
  Tags,
67
67
  } from './tags';
68
68
  export { AccessUsers, UserListResponse, Users } from './users/index';
69
- export { KeyUpdateResponse, KeyListResponse, KeyRotateResponse, KeyUpdateParams, Keys } from './keys';
69
+ export { KeyUpdateResponse, KeyGetResponse, KeyRotateResponse, KeyUpdateParams, Keys } from './keys';
70
70
  export { Logs } from './logs/index';
@@ -23,10 +23,10 @@ export class Keys extends APIResource {
23
23
  /**
24
24
  * Gets the Access key rotation settings for an account.
25
25
  */
26
- list(identifier: string, options?: Core.RequestOptions): Core.APIPromise<KeyListResponse> {
26
+ get(identifier: string, options?: Core.RequestOptions): Core.APIPromise<KeyGetResponse> {
27
27
  return (
28
28
  this._client.get(`/accounts/${identifier}/access/keys`, options) as Core.APIPromise<{
29
- result: KeyListResponse;
29
+ result: KeyGetResponse;
30
30
  }>
31
31
  )._thenUnwrap((obj) => obj.result);
32
32
  }
@@ -45,7 +45,7 @@ export class Keys extends APIResource {
45
45
 
46
46
  export type KeyUpdateResponse = unknown | string;
47
47
 
48
- export type KeyListResponse = unknown | string;
48
+ export type KeyGetResponse = unknown | string;
49
49
 
50
50
  export type KeyRotateResponse = unknown | string;
51
51
 
@@ -58,7 +58,7 @@ export interface KeyUpdateParams {
58
58
 
59
59
  export namespace Keys {
60
60
  export import KeyUpdateResponse = KeysAPI.KeyUpdateResponse;
61
- export import KeyListResponse = KeysAPI.KeyListResponse;
61
+ export import KeyGetResponse = KeysAPI.KeyGetResponse;
62
62
  export import KeyRotateResponse = KeysAPI.KeyRotateResponse;
63
63
  export import KeyUpdateParams = KeysAPI.KeyUpdateParams;
64
64
  }
package/src/version.ts CHANGED
@@ -1 +1 @@
1
- export const VERSION = '3.0.0-beta.1'; // x-release-please-version
1
+ export const VERSION = '3.0.0-beta.3'; // x-release-please-version
package/version.d.ts CHANGED
@@ -1,2 +1,2 @@
1
- export declare const VERSION = "3.0.0-beta.1";
1
+ export declare const VERSION = "3.0.0-beta.3";
2
2
  //# sourceMappingURL=version.d.ts.map
package/version.js CHANGED
@@ -1,5 +1,5 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.VERSION = void 0;
4
- exports.VERSION = '3.0.0-beta.1'; // x-release-please-version
4
+ exports.VERSION = '3.0.0-beta.3'; // x-release-please-version
5
5
  //# sourceMappingURL=version.js.map
package/version.mjs CHANGED
@@ -1,2 +1,2 @@
1
- export const VERSION = '3.0.0-beta.1'; // x-release-please-version
1
+ export const VERSION = '3.0.0-beta.3'; // x-release-please-version
2
2
  //# sourceMappingURL=version.mjs.map