@distilled.cloud/cloudflare 0.18.1 → 0.19.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (250) hide show
  1. package/lib/client/api.d.ts.map +1 -1
  2. package/lib/client/api.js +9 -1
  3. package/lib/client/api.js.map +1 -1
  4. package/lib/services/abuse-reports.d.ts +4 -4
  5. package/lib/services/abuse-reports.d.ts.map +1 -1
  6. package/lib/services/abuse-reports.js +28 -22
  7. package/lib/services/abuse-reports.js.map +1 -1
  8. package/lib/services/accounts.d.ts +10 -10
  9. package/lib/services/accounts.d.ts.map +1 -1
  10. package/lib/services/accounts.js +67 -52
  11. package/lib/services/accounts.js.map +1 -1
  12. package/lib/services/ai-gateway.d.ts +10 -10
  13. package/lib/services/ai-gateway.d.ts.map +1 -1
  14. package/lib/services/ai-gateway.js +70 -55
  15. package/lib/services/ai-gateway.js.map +1 -1
  16. package/lib/services/ai.d.ts +2 -2
  17. package/lib/services/ai.d.ts.map +1 -1
  18. package/lib/services/ai.js +14 -11
  19. package/lib/services/ai.js.map +1 -1
  20. package/lib/services/alerting.d.ts +2 -2
  21. package/lib/services/alerting.d.ts.map +1 -1
  22. package/lib/services/alerting.js +14 -11
  23. package/lib/services/alerting.js.map +1 -1
  24. package/lib/services/api-gateway.d.ts +10 -10
  25. package/lib/services/api-gateway.d.ts.map +1 -1
  26. package/lib/services/api-gateway.js +70 -55
  27. package/lib/services/api-gateway.js.map +1 -1
  28. package/lib/services/audit-logs.d.ts +2 -2
  29. package/lib/services/audit-logs.d.ts.map +1 -1
  30. package/lib/services/audit-logs.js +14 -11
  31. package/lib/services/audit-logs.js.map +1 -1
  32. package/lib/services/client-certificates.d.ts +2 -2
  33. package/lib/services/client-certificates.d.ts.map +1 -1
  34. package/lib/services/client-certificates.js +14 -11
  35. package/lib/services/client-certificates.js.map +1 -1
  36. package/lib/services/custom-certificates.d.ts +2 -2
  37. package/lib/services/custom-certificates.d.ts.map +1 -1
  38. package/lib/services/custom-certificates.js +14 -11
  39. package/lib/services/custom-certificates.js.map +1 -1
  40. package/lib/services/custom-hostnames.d.ts +2 -2
  41. package/lib/services/custom-hostnames.d.ts.map +1 -1
  42. package/lib/services/custom-hostnames.js +14 -11
  43. package/lib/services/custom-hostnames.js.map +1 -1
  44. package/lib/services/d1.d.ts +2 -2
  45. package/lib/services/d1.d.ts.map +1 -1
  46. package/lib/services/d1.js +14 -11
  47. package/lib/services/d1.js.map +1 -1
  48. package/lib/services/dns-firewall.d.ts +2 -2
  49. package/lib/services/dns-firewall.d.ts.map +1 -1
  50. package/lib/services/dns-firewall.js +14 -11
  51. package/lib/services/dns-firewall.js.map +1 -1
  52. package/lib/services/dns.d.ts +4 -4
  53. package/lib/services/dns.d.ts.map +1 -1
  54. package/lib/services/dns.js +28 -22
  55. package/lib/services/dns.js.map +1 -1
  56. package/lib/services/durable-objects.d.ts +4 -4
  57. package/lib/services/durable-objects.d.ts.map +1 -1
  58. package/lib/services/durable-objects.js +25 -19
  59. package/lib/services/durable-objects.js.map +1 -1
  60. package/lib/services/email-routing.d.ts +4 -4
  61. package/lib/services/email-routing.d.ts.map +1 -1
  62. package/lib/services/email-routing.js +28 -22
  63. package/lib/services/email-routing.js.map +1 -1
  64. package/lib/services/email-security.d.ts +14 -14
  65. package/lib/services/email-security.d.ts.map +1 -1
  66. package/lib/services/email-security.js +98 -77
  67. package/lib/services/email-security.js.map +1 -1
  68. package/lib/services/filters.d.ts +2 -2
  69. package/lib/services/filters.d.ts.map +1 -1
  70. package/lib/services/filters.js +14 -11
  71. package/lib/services/filters.js.map +1 -1
  72. package/lib/services/firewall.d.ts +16 -16
  73. package/lib/services/firewall.d.ts.map +1 -1
  74. package/lib/services/firewall.js +112 -88
  75. package/lib/services/firewall.js.map +1 -1
  76. package/lib/services/healthchecks.d.ts +2 -2
  77. package/lib/services/healthchecks.d.ts.map +1 -1
  78. package/lib/services/healthchecks.js +14 -11
  79. package/lib/services/healthchecks.js.map +1 -1
  80. package/lib/services/images.d.ts +2 -2
  81. package/lib/services/images.d.ts.map +1 -1
  82. package/lib/services/images.js +14 -11
  83. package/lib/services/images.js.map +1 -1
  84. package/lib/services/intel.d.ts +4 -4
  85. package/lib/services/intel.d.ts.map +1 -1
  86. package/lib/services/intel.js +28 -22
  87. package/lib/services/intel.js.map +1 -1
  88. package/lib/services/kv.d.ts +4 -4
  89. package/lib/services/kv.d.ts.map +1 -1
  90. package/lib/services/kv.js +25 -19
  91. package/lib/services/kv.js.map +1 -1
  92. package/lib/services/load-balancers.d.ts +2 -2
  93. package/lib/services/load-balancers.d.ts.map +1 -1
  94. package/lib/services/load-balancers.js +14 -11
  95. package/lib/services/load-balancers.js.map +1 -1
  96. package/lib/services/magic-cloud-networking.d.ts +2 -2
  97. package/lib/services/magic-cloud-networking.d.ts.map +1 -1
  98. package/lib/services/magic-cloud-networking.js +14 -11
  99. package/lib/services/magic-cloud-networking.js.map +1 -1
  100. package/lib/services/memberships.d.ts +2 -2
  101. package/lib/services/memberships.d.ts.map +1 -1
  102. package/lib/services/memberships.js +14 -11
  103. package/lib/services/memberships.js.map +1 -1
  104. package/lib/services/origin-ca-certificates.d.ts +2 -2
  105. package/lib/services/origin-ca-certificates.d.ts.map +1 -1
  106. package/lib/services/origin-ca-certificates.js +14 -11
  107. package/lib/services/origin-ca-certificates.js.map +1 -1
  108. package/lib/services/pages.d.ts +4 -4
  109. package/lib/services/pages.d.ts.map +1 -1
  110. package/lib/services/pages.js +28 -22
  111. package/lib/services/pages.js.map +1 -1
  112. package/lib/services/queues.d.ts +10 -4
  113. package/lib/services/queues.d.ts.map +1 -1
  114. package/lib/services/queues.js +22 -11
  115. package/lib/services/queues.js.map +1 -1
  116. package/lib/services/r2.d.ts +68 -0
  117. package/lib/services/r2.d.ts.map +1 -1
  118. package/lib/services/r2.js +105 -0
  119. package/lib/services/r2.js.map +1 -1
  120. package/lib/services/radar.d.ts +4 -4
  121. package/lib/services/radar.d.ts.map +1 -1
  122. package/lib/services/radar.js +28 -22
  123. package/lib/services/radar.js.map +1 -1
  124. package/lib/services/rate-limits.d.ts +2 -2
  125. package/lib/services/rate-limits.d.ts.map +1 -1
  126. package/lib/services/rate-limits.js +14 -11
  127. package/lib/services/rate-limits.js.map +1 -1
  128. package/lib/services/resource-sharing.d.ts +6 -6
  129. package/lib/services/resource-sharing.d.ts.map +1 -1
  130. package/lib/services/resource-sharing.js +42 -33
  131. package/lib/services/resource-sharing.js.map +1 -1
  132. package/lib/services/rules.d.ts +2 -2
  133. package/lib/services/rules.d.ts.map +1 -1
  134. package/lib/services/rules.js +11 -8
  135. package/lib/services/rules.js.map +1 -1
  136. package/lib/services/rulesets.d.ts +2 -2
  137. package/lib/services/rulesets.d.ts.map +1 -1
  138. package/lib/services/rulesets.js +12 -9
  139. package/lib/services/rulesets.js.map +1 -1
  140. package/lib/services/rum.d.ts +2 -2
  141. package/lib/services/rum.d.ts.map +1 -1
  142. package/lib/services/rum.js +14 -11
  143. package/lib/services/rum.js.map +1 -1
  144. package/lib/services/schema-validation.d.ts +4 -4
  145. package/lib/services/schema-validation.d.ts.map +1 -1
  146. package/lib/services/schema-validation.js +28 -22
  147. package/lib/services/schema-validation.js.map +1 -1
  148. package/lib/services/secrets-store.d.ts +4 -4
  149. package/lib/services/secrets-store.d.ts.map +1 -1
  150. package/lib/services/secrets-store.js +28 -22
  151. package/lib/services/secrets-store.js.map +1 -1
  152. package/lib/services/security-center.d.ts +2 -2
  153. package/lib/services/security-center.d.ts.map +1 -1
  154. package/lib/services/security-center.js +14 -11
  155. package/lib/services/security-center.js.map +1 -1
  156. package/lib/services/snippets.d.ts +2 -2
  157. package/lib/services/snippets.d.ts.map +1 -1
  158. package/lib/services/snippets.js +14 -11
  159. package/lib/services/snippets.js.map +1 -1
  160. package/lib/services/spectrum.d.ts +2 -2
  161. package/lib/services/spectrum.d.ts.map +1 -1
  162. package/lib/services/spectrum.js +14 -11
  163. package/lib/services/spectrum.js.map +1 -1
  164. package/lib/services/speed.d.ts +2 -2
  165. package/lib/services/speed.d.ts.map +1 -1
  166. package/lib/services/speed.js +14 -11
  167. package/lib/services/speed.js.map +1 -1
  168. package/lib/services/token-validation.d.ts +4 -4
  169. package/lib/services/token-validation.d.ts.map +1 -1
  170. package/lib/services/token-validation.js +28 -22
  171. package/lib/services/token-validation.js.map +1 -1
  172. package/lib/services/turnstile.d.ts +2 -2
  173. package/lib/services/turnstile.d.ts.map +1 -1
  174. package/lib/services/turnstile.js +14 -11
  175. package/lib/services/turnstile.js.map +1 -1
  176. package/lib/services/user.d.ts +8 -8
  177. package/lib/services/user.d.ts.map +1 -1
  178. package/lib/services/user.js +56 -44
  179. package/lib/services/user.js.map +1 -1
  180. package/lib/services/waiting-rooms.d.ts +4 -4
  181. package/lib/services/waiting-rooms.d.ts.map +1 -1
  182. package/lib/services/waiting-rooms.js +28 -22
  183. package/lib/services/waiting-rooms.js.map +1 -1
  184. package/lib/services/workers.d.ts +17 -17
  185. package/lib/services/workers.d.ts.map +1 -1
  186. package/lib/services/workers.js +53 -44
  187. package/lib/services/workers.js.map +1 -1
  188. package/lib/services/workflows.d.ts +6 -6
  189. package/lib/services/workflows.d.ts.map +1 -1
  190. package/lib/services/workflows.js +42 -33
  191. package/lib/services/workflows.js.map +1 -1
  192. package/lib/services/zero-trust.d.ts +60 -60
  193. package/lib/services/zero-trust.d.ts.map +1 -1
  194. package/lib/services/zero-trust.js +416 -326
  195. package/lib/services/zero-trust.js.map +1 -1
  196. package/lib/services/zones.d.ts +2 -2
  197. package/lib/services/zones.d.ts.map +1 -1
  198. package/lib/services/zones.js +14 -11
  199. package/lib/services/zones.js.map +1 -1
  200. package/package.json +2 -2
  201. package/src/client/api.ts +10 -0
  202. package/src/services/abuse-reports.ts +42 -28
  203. package/src/services/accounts.ts +94 -67
  204. package/src/services/ai-gateway.ts +101 -70
  205. package/src/services/ai.ts +19 -14
  206. package/src/services/alerting.ts +19 -14
  207. package/src/services/api-gateway.ts +105 -70
  208. package/src/services/audit-logs.ts +19 -14
  209. package/src/services/client-certificates.ts +21 -14
  210. package/src/services/custom-certificates.ts +21 -14
  211. package/src/services/custom-hostnames.ts +21 -14
  212. package/src/services/d1.ts +19 -14
  213. package/src/services/dns-firewall.ts +21 -14
  214. package/src/services/dns.ts +40 -28
  215. package/src/services/durable-objects.ts +39 -25
  216. package/src/services/email-routing.ts +38 -28
  217. package/src/services/email-security.ts +147 -98
  218. package/src/services/filters.ts +19 -14
  219. package/src/services/firewall.ts +162 -112
  220. package/src/services/healthchecks.ts +21 -14
  221. package/src/services/images.ts +19 -14
  222. package/src/services/intel.ts +40 -28
  223. package/src/services/kv.ts +39 -25
  224. package/src/services/load-balancers.ts +19 -14
  225. package/src/services/magic-cloud-networking.ts +19 -14
  226. package/src/services/memberships.ts +21 -14
  227. package/src/services/origin-ca-certificates.ts +21 -14
  228. package/src/services/pages.ts +40 -28
  229. package/src/services/queues.ts +34 -14
  230. package/src/services/r2.ts +241 -0
  231. package/src/services/radar.ts +42 -28
  232. package/src/services/rate-limits.ts +21 -14
  233. package/src/services/resource-sharing.ts +61 -42
  234. package/src/services/rules.ts +18 -11
  235. package/src/services/rulesets.ts +17 -12
  236. package/src/services/rum.ts +19 -14
  237. package/src/services/schema-validation.ts +40 -28
  238. package/src/services/secrets-store.ts +40 -28
  239. package/src/services/security-center.ts +19 -14
  240. package/src/services/snippets.ts +19 -14
  241. package/src/services/spectrum.ts +19 -14
  242. package/src/services/speed.ts +19 -14
  243. package/src/services/token-validation.ts +40 -28
  244. package/src/services/turnstile.ts +19 -14
  245. package/src/services/user.ts +80 -56
  246. package/src/services/waiting-rooms.ts +40 -28
  247. package/src/services/workers.ts +85 -64
  248. package/src/services/workflows.ts +57 -42
  249. package/src/services/zero-trust.ts +618 -416
  250. package/src/services/zones.ts +19 -14
@@ -2662,6 +2662,138 @@ export const getObject: API.OperationMethod<
2662
2662
  errors: [NoSuchBucket, InvalidRoute, NoRoute],
2663
2663
  }));
2664
2664
 
2665
+ export interface ListObjectsRequest {
2666
+ /** Name of the R2 bucket. */
2667
+ bucketName: string;
2668
+ /** Account ID. */
2669
+ accountId: string;
2670
+ /** Maximum number of objects to return per page (1-1000). */
2671
+ perPage?: number;
2672
+ /** Restrict results to keys beginning with this prefix. */
2673
+ prefix?: string;
2674
+ /** Single character used to group keys. */
2675
+ delimiter?: string;
2676
+ /** Pagination cursor returned by a previous List Objects call. */
2677
+ cursor?: string;
2678
+ /** Returns keys lexicographically after this key. */
2679
+ startAfter?: string;
2680
+ /** Jurisdiction where objects in this bucket are guaranteed to be stored. */
2681
+ cfR2Jurisdiction?: "default" | "eu" | "fedramp";
2682
+ }
2683
+
2684
+ export const ListObjectsRequest = /*@__PURE__*/ /*#__PURE__*/ Schema.Struct({
2685
+ bucketName: Schema.String.pipe(T.HttpPath("bucketName")),
2686
+ accountId: Schema.String.pipe(T.HttpPath("account_id")),
2687
+ perPage: Schema.optional(Schema.Number).pipe(T.HttpQuery("per_page")),
2688
+ prefix: Schema.optional(Schema.String).pipe(T.HttpQuery("prefix")),
2689
+ delimiter: Schema.optional(Schema.String).pipe(T.HttpQuery("delimiter")),
2690
+ cursor: Schema.optional(Schema.String).pipe(T.HttpQuery("cursor")),
2691
+ startAfter: Schema.optional(Schema.String).pipe(T.HttpQuery("start_after")),
2692
+ cfR2Jurisdiction: Schema.optional(
2693
+ Schema.Literals(["default", "eu", "fedramp"]),
2694
+ ).pipe(T.HttpHeader("cf-r2-jurisdiction")),
2695
+ }).pipe(
2696
+ T.Http({
2697
+ method: "GET",
2698
+ path: "/accounts/{account_id}/r2/buckets/{bucketName}/objects",
2699
+ }),
2700
+ ) as unknown as Schema.Schema<ListObjectsRequest>;
2701
+
2702
+ export interface ListObjectsResponse {
2703
+ result: {
2704
+ key?: string | null;
2705
+ size?: number | null;
2706
+ etag?: string | null;
2707
+ lastModified?: string | null;
2708
+ storageClass?: "Standard" | "InfrequentAccess" | null;
2709
+ ssec?: boolean | null;
2710
+ customMetadata?: unknown | null;
2711
+ httpMetadata?: unknown | null;
2712
+ }[];
2713
+ resultInfo?: {
2714
+ count?: number | null;
2715
+ cursor?: string | null;
2716
+ perPage?: number | null;
2717
+ } | null;
2718
+ }
2719
+
2720
+ export const ListObjectsResponse = /*@__PURE__*/ /*#__PURE__*/ Schema.Struct({
2721
+ result: Schema.Array(
2722
+ Schema.Struct({
2723
+ key: Schema.optional(Schema.Union([Schema.String, Schema.Null])),
2724
+ size: Schema.optional(Schema.Union([Schema.Number, Schema.Null])),
2725
+ etag: Schema.optional(Schema.Union([Schema.String, Schema.Null])),
2726
+ lastModified: Schema.optional(Schema.Union([Schema.String, Schema.Null])),
2727
+ storageClass: Schema.optional(
2728
+ Schema.Union([
2729
+ Schema.Literals(["Standard", "InfrequentAccess"]),
2730
+ Schema.Null,
2731
+ ]),
2732
+ ),
2733
+ ssec: Schema.optional(Schema.Union([Schema.Boolean, Schema.Null])),
2734
+ customMetadata: Schema.optional(
2735
+ Schema.Union([Schema.Unknown, Schema.Null]),
2736
+ ),
2737
+ httpMetadata: Schema.optional(
2738
+ Schema.Union([Schema.Unknown, Schema.Null]),
2739
+ ),
2740
+ }).pipe(
2741
+ Schema.encodeKeys({
2742
+ key: "key",
2743
+ size: "size",
2744
+ etag: "etag",
2745
+ lastModified: "last_modified",
2746
+ storageClass: "storage_class",
2747
+ ssec: "ssec",
2748
+ customMetadata: "custom_metadata",
2749
+ httpMetadata: "http_metadata",
2750
+ }),
2751
+ ),
2752
+ ),
2753
+ resultInfo: Schema.optional(
2754
+ Schema.Union([
2755
+ Schema.Struct({
2756
+ count: Schema.optional(Schema.Union([Schema.Number, Schema.Null])),
2757
+ cursor: Schema.optional(Schema.Union([Schema.String, Schema.Null])),
2758
+ perPage: Schema.optional(Schema.Union([Schema.Number, Schema.Null])),
2759
+ }).pipe(
2760
+ Schema.encodeKeys({
2761
+ count: "count",
2762
+ cursor: "cursor",
2763
+ perPage: "per_page",
2764
+ }),
2765
+ ),
2766
+ Schema.Null,
2767
+ ]),
2768
+ ),
2769
+ }).pipe(
2770
+ Schema.encodeKeys({ result: "result", resultInfo: "result_info" }),
2771
+ ) as unknown as Schema.Schema<ListObjectsResponse>;
2772
+
2773
+ export type ListObjectsError =
2774
+ | DefaultErrors
2775
+ | NoSuchBucket
2776
+ | InvalidRoute
2777
+ | NoRoute;
2778
+
2779
+ export const listObjects: API.PaginatedOperationMethod<
2780
+ ListObjectsRequest,
2781
+ ListObjectsResponse,
2782
+ ListObjectsError,
2783
+ Credentials | HttpClient.HttpClient
2784
+ > = /*@__PURE__*/ /*#__PURE__*/ API.makePaginated(() => ({
2785
+ input: ListObjectsRequest,
2786
+ output: ListObjectsResponse,
2787
+ errors: [NoSuchBucket, InvalidRoute, NoRoute],
2788
+ pagination: {
2789
+ mode: "cursor",
2790
+ inputToken: "cursor",
2791
+ outputToken: "resultInfo.cursor",
2792
+ items: "result",
2793
+ pageSize: "perPage",
2794
+ } as const,
2795
+ }));
2796
+
2665
2797
  export interface PutObjectRequest {
2666
2798
  /** Name of the R2 bucket. */
2667
2799
  bucketName: string;
@@ -2752,6 +2884,115 @@ export const putObject: API.OperationMethod<
2752
2884
  errors: [NoSuchBucket, InvalidRoute, NoRoute],
2753
2885
  }));
2754
2886
 
2887
+ export interface DeleteObjectsRequest {
2888
+ /** Name of the R2 bucket. */
2889
+ bucketName: string;
2890
+ /** Account ID. */
2891
+ accountId: string;
2892
+ /** When set, switches to "delete by prefix" mode and asynchronously deletes every object whose key begins with the given prefix. The response is a prefix-delete job descriptor instead of a per-key list. */
2893
+ prefix?: string;
2894
+ /** Jurisdiction where objects in this bucket are guaranteed to be stored. */
2895
+ cfR2Jurisdiction?: "default" | "eu" | "fedramp";
2896
+ body?: string[];
2897
+ }
2898
+
2899
+ export const DeleteObjectsRequest = /*@__PURE__*/ /*#__PURE__*/ Schema.Struct({
2900
+ bucketName: Schema.String.pipe(T.HttpPath("bucketName")),
2901
+ accountId: Schema.String.pipe(T.HttpPath("account_id")),
2902
+ prefix: Schema.optional(Schema.String).pipe(T.HttpQuery("prefix")),
2903
+ cfR2Jurisdiction: Schema.optional(
2904
+ Schema.Literals(["default", "eu", "fedramp"]),
2905
+ ).pipe(T.HttpHeader("cf-r2-jurisdiction")),
2906
+ body: Schema.optional(Schema.Array(Schema.String)).pipe(T.HttpBody()),
2907
+ }).pipe(
2908
+ T.Http({
2909
+ method: "DELETE",
2910
+ path: "/accounts/{account_id}/r2/buckets/{bucketName}/objects",
2911
+ }),
2912
+ ) as unknown as Schema.Schema<DeleteObjectsRequest>;
2913
+
2914
+ export type DeleteObjectsResponse =
2915
+ | { key?: string | null }[]
2916
+ | {
2917
+ id?: string | null;
2918
+ jobType?: "prefixDelete" | null;
2919
+ status?:
2920
+ | "ENQUEUED"
2921
+ | "RUNNING"
2922
+ | "COMPLETED"
2923
+ | "FAILED"
2924
+ | "CANCELLED"
2925
+ | null;
2926
+ startTime?: string | null;
2927
+ endTime?: string | null;
2928
+ prefixDelete?: {
2929
+ prefix?: string | null;
2930
+ deletedObjects?: number | null;
2931
+ isBucketClear?: boolean | null;
2932
+ } | null;
2933
+ };
2934
+
2935
+ export const DeleteObjectsResponse = /*@__PURE__*/ /*#__PURE__*/ Schema.Union([
2936
+ Schema.Array(
2937
+ Schema.Struct({
2938
+ key: Schema.optional(Schema.Union([Schema.String, Schema.Null])),
2939
+ }),
2940
+ ),
2941
+ Schema.Struct({
2942
+ id: Schema.optional(Schema.Union([Schema.String, Schema.Null])),
2943
+ jobType: Schema.optional(
2944
+ Schema.Union([Schema.Literal("prefixDelete"), Schema.Null]),
2945
+ ),
2946
+ status: Schema.optional(
2947
+ Schema.Union([
2948
+ Schema.Literals([
2949
+ "ENQUEUED",
2950
+ "RUNNING",
2951
+ "COMPLETED",
2952
+ "FAILED",
2953
+ "CANCELLED",
2954
+ ]),
2955
+ Schema.Null,
2956
+ ]),
2957
+ ),
2958
+ startTime: Schema.optional(Schema.Union([Schema.String, Schema.Null])),
2959
+ endTime: Schema.optional(Schema.Union([Schema.String, Schema.Null])),
2960
+ prefixDelete: Schema.optional(
2961
+ Schema.Union([
2962
+ Schema.Struct({
2963
+ prefix: Schema.optional(Schema.Union([Schema.String, Schema.Null])),
2964
+ deletedObjects: Schema.optional(
2965
+ Schema.Union([Schema.Number, Schema.Null]),
2966
+ ),
2967
+ isBucketClear: Schema.optional(
2968
+ Schema.Union([Schema.Boolean, Schema.Null]),
2969
+ ),
2970
+ }),
2971
+ Schema.Null,
2972
+ ]),
2973
+ ),
2974
+ }),
2975
+ ]).pipe(
2976
+ T.ResponsePath("result"),
2977
+ ) as unknown as Schema.Schema<DeleteObjectsResponse>;
2978
+
2979
+ export type DeleteObjectsError =
2980
+ | DefaultErrors
2981
+ | NoSuchBucket
2982
+ | InvalidRoute
2983
+ | NoRoute;
2984
+
2985
+ export const deleteObjects: API.OperationMethod<
2986
+ DeleteObjectsRequest,
2987
+ DeleteObjectsResponse,
2988
+ DeleteObjectsError,
2989
+ Credentials | HttpClient.HttpClient
2990
+ > = /*@__PURE__*/ /*#__PURE__*/ API.make(() => ({
2991
+ input: DeleteObjectsRequest,
2992
+ output: DeleteObjectsResponse,
2993
+ errors: [NoSuchBucket, InvalidRoute, NoRoute],
2994
+ }));
2995
+
2755
2996
  export interface DeleteObjectRequest {
2756
2997
  /** Name of the R2 bucket. */
2757
2998
  bucketName: string;
@@ -9688,12 +9688,12 @@ export interface ListBgpHijackEventsResponse {
9688
9688
  }[]
9689
9689
  | null;
9690
9690
  };
9691
- resultInfo: {
9691
+ resultInfo?: {
9692
9692
  count?: number | null;
9693
9693
  page?: number | null;
9694
9694
  perPage?: number | null;
9695
9695
  totalCount?: number | null;
9696
- };
9696
+ } | null;
9697
9697
  }
9698
9698
 
9699
9699
  export const ListBgpHijackEventsResponse =
@@ -9777,18 +9777,25 @@ export const ListBgpHijackEventsResponse =
9777
9777
  ]),
9778
9778
  ),
9779
9779
  }),
9780
- resultInfo: Schema.Struct({
9781
- count: Schema.optional(Schema.Union([Schema.Number, Schema.Null])),
9782
- page: Schema.optional(Schema.Union([Schema.Number, Schema.Null])),
9783
- perPage: Schema.optional(Schema.Union([Schema.Number, Schema.Null])),
9784
- totalCount: Schema.optional(Schema.Union([Schema.Number, Schema.Null])),
9785
- }).pipe(
9786
- Schema.encodeKeys({
9787
- count: "count",
9788
- page: "page",
9789
- perPage: "per_page",
9790
- totalCount: "total_count",
9791
- }),
9780
+ resultInfo: Schema.optional(
9781
+ Schema.Union([
9782
+ Schema.Struct({
9783
+ count: Schema.optional(Schema.Union([Schema.Number, Schema.Null])),
9784
+ page: Schema.optional(Schema.Union([Schema.Number, Schema.Null])),
9785
+ perPage: Schema.optional(Schema.Union([Schema.Number, Schema.Null])),
9786
+ totalCount: Schema.optional(
9787
+ Schema.Union([Schema.Number, Schema.Null]),
9788
+ ),
9789
+ }).pipe(
9790
+ Schema.encodeKeys({
9791
+ count: "count",
9792
+ page: "page",
9793
+ perPage: "per_page",
9794
+ totalCount: "total_count",
9795
+ }),
9796
+ ),
9797
+ Schema.Null,
9798
+ ]),
9792
9799
  ),
9793
9800
  }).pipe(
9794
9801
  Schema.encodeKeys({ result: "result", resultInfo: "result_info" }),
@@ -10088,12 +10095,12 @@ export interface ListBgpLeakEventsResponse {
10088
10095
  }[]
10089
10096
  | null;
10090
10097
  };
10091
- resultInfo: {
10098
+ resultInfo?: {
10092
10099
  count?: number | null;
10093
10100
  page?: number | null;
10094
10101
  perPage?: number | null;
10095
10102
  totalCount?: number | null;
10096
- };
10103
+ } | null;
10097
10104
  }
10098
10105
 
10099
10106
  export const ListBgpLeakEventsResponse =
@@ -10157,18 +10164,25 @@ export const ListBgpLeakEventsResponse =
10157
10164
  ]),
10158
10165
  ),
10159
10166
  }),
10160
- resultInfo: Schema.Struct({
10161
- count: Schema.optional(Schema.Union([Schema.Number, Schema.Null])),
10162
- page: Schema.optional(Schema.Union([Schema.Number, Schema.Null])),
10163
- perPage: Schema.optional(Schema.Union([Schema.Number, Schema.Null])),
10164
- totalCount: Schema.optional(Schema.Union([Schema.Number, Schema.Null])),
10165
- }).pipe(
10166
- Schema.encodeKeys({
10167
- count: "count",
10168
- page: "page",
10169
- perPage: "per_page",
10170
- totalCount: "total_count",
10171
- }),
10167
+ resultInfo: Schema.optional(
10168
+ Schema.Union([
10169
+ Schema.Struct({
10170
+ count: Schema.optional(Schema.Union([Schema.Number, Schema.Null])),
10171
+ page: Schema.optional(Schema.Union([Schema.Number, Schema.Null])),
10172
+ perPage: Schema.optional(Schema.Union([Schema.Number, Schema.Null])),
10173
+ totalCount: Schema.optional(
10174
+ Schema.Union([Schema.Number, Schema.Null]),
10175
+ ),
10176
+ }).pipe(
10177
+ Schema.encodeKeys({
10178
+ count: "count",
10179
+ page: "page",
10180
+ perPage: "per_page",
10181
+ totalCount: "total_count",
10182
+ }),
10183
+ ),
10184
+ Schema.Null,
10185
+ ]),
10172
10186
  ),
10173
10187
  }).pipe(
10174
10188
  Schema.encodeKeys({ result: "result", resultInfo: "result_info" }),
@@ -257,12 +257,12 @@ export interface ListRateLimitsResponse {
257
257
  period?: number | null;
258
258
  threshold?: number | null;
259
259
  }[];
260
- resultInfo: {
260
+ resultInfo?: {
261
261
  count?: number | null;
262
262
  page?: number | null;
263
263
  perPage?: number | null;
264
264
  totalCount?: number | null;
265
- };
265
+ } | null;
266
266
  }
267
267
 
268
268
  export const ListRateLimitsResponse = /*@__PURE__*/ /*#__PURE__*/ Schema.Struct(
@@ -402,18 +402,25 @@ export const ListRateLimitsResponse = /*@__PURE__*/ /*#__PURE__*/ Schema.Struct(
402
402
  threshold: Schema.optional(Schema.Union([Schema.Number, Schema.Null])),
403
403
  }),
404
404
  ),
405
- resultInfo: Schema.Struct({
406
- count: Schema.optional(Schema.Union([Schema.Number, Schema.Null])),
407
- page: Schema.optional(Schema.Union([Schema.Number, Schema.Null])),
408
- perPage: Schema.optional(Schema.Union([Schema.Number, Schema.Null])),
409
- totalCount: Schema.optional(Schema.Union([Schema.Number, Schema.Null])),
410
- }).pipe(
411
- Schema.encodeKeys({
412
- count: "count",
413
- page: "page",
414
- perPage: "per_page",
415
- totalCount: "total_count",
416
- }),
405
+ resultInfo: Schema.optional(
406
+ Schema.Union([
407
+ Schema.Struct({
408
+ count: Schema.optional(Schema.Union([Schema.Number, Schema.Null])),
409
+ page: Schema.optional(Schema.Union([Schema.Number, Schema.Null])),
410
+ perPage: Schema.optional(Schema.Union([Schema.Number, Schema.Null])),
411
+ totalCount: Schema.optional(
412
+ Schema.Union([Schema.Number, Schema.Null]),
413
+ ),
414
+ }).pipe(
415
+ Schema.encodeKeys({
416
+ count: "count",
417
+ page: "page",
418
+ perPage: "per_page",
419
+ totalCount: "total_count",
420
+ }),
421
+ ),
422
+ Schema.Null,
423
+ ]),
417
424
  ),
418
425
  },
419
426
  ).pipe(
@@ -168,12 +168,12 @@ export interface ListRecipientsResponse {
168
168
  }[]
169
169
  | null;
170
170
  }[];
171
- resultInfo: {
171
+ resultInfo?: {
172
172
  count?: number | null;
173
173
  page?: number | null;
174
174
  perPage?: number | null;
175
175
  totalCount?: number | null;
176
- };
176
+ } | null;
177
177
  }
178
178
 
179
179
  export const ListRecipientsResponse = /*@__PURE__*/ /*#__PURE__*/ Schema.Struct(
@@ -221,18 +221,25 @@ export const ListRecipientsResponse = /*@__PURE__*/ /*#__PURE__*/ Schema.Struct(
221
221
  }),
222
222
  ),
223
223
  ),
224
- resultInfo: Schema.Struct({
225
- count: Schema.optional(Schema.Union([Schema.Number, Schema.Null])),
226
- page: Schema.optional(Schema.Union([Schema.Number, Schema.Null])),
227
- perPage: Schema.optional(Schema.Union([Schema.Number, Schema.Null])),
228
- totalCount: Schema.optional(Schema.Union([Schema.Number, Schema.Null])),
229
- }).pipe(
230
- Schema.encodeKeys({
231
- count: "count",
232
- page: "page",
233
- perPage: "per_page",
234
- totalCount: "total_count",
235
- }),
224
+ resultInfo: Schema.optional(
225
+ Schema.Union([
226
+ Schema.Struct({
227
+ count: Schema.optional(Schema.Union([Schema.Number, Schema.Null])),
228
+ page: Schema.optional(Schema.Union([Schema.Number, Schema.Null])),
229
+ perPage: Schema.optional(Schema.Union([Schema.Number, Schema.Null])),
230
+ totalCount: Schema.optional(
231
+ Schema.Union([Schema.Number, Schema.Null]),
232
+ ),
233
+ }).pipe(
234
+ Schema.encodeKeys({
235
+ count: "count",
236
+ page: "page",
237
+ perPage: "per_page",
238
+ totalCount: "total_count",
239
+ }),
240
+ ),
241
+ Schema.Null,
242
+ ]),
236
243
  ),
237
244
  },
238
245
  ).pipe(
@@ -635,12 +642,12 @@ export interface ListResourcesResponse {
635
642
  resourceVersion: number;
636
643
  status: "active" | "deleting" | "deleted";
637
644
  }[];
638
- resultInfo: {
645
+ resultInfo?: {
639
646
  count?: number | null;
640
647
  page?: number | null;
641
648
  perPage?: number | null;
642
649
  totalCount?: number | null;
643
- };
650
+ } | null;
644
651
  }
645
652
 
646
653
  export const ListResourcesResponse = /*@__PURE__*/ /*#__PURE__*/ Schema.Struct({
@@ -676,18 +683,23 @@ export const ListResourcesResponse = /*@__PURE__*/ /*#__PURE__*/ Schema.Struct({
676
683
  }),
677
684
  ),
678
685
  ),
679
- resultInfo: Schema.Struct({
680
- count: Schema.optional(Schema.Union([Schema.Number, Schema.Null])),
681
- page: Schema.optional(Schema.Union([Schema.Number, Schema.Null])),
682
- perPage: Schema.optional(Schema.Union([Schema.Number, Schema.Null])),
683
- totalCount: Schema.optional(Schema.Union([Schema.Number, Schema.Null])),
684
- }).pipe(
685
- Schema.encodeKeys({
686
- count: "count",
687
- page: "page",
688
- perPage: "per_page",
689
- totalCount: "total_count",
690
- }),
686
+ resultInfo: Schema.optional(
687
+ Schema.Union([
688
+ Schema.Struct({
689
+ count: Schema.optional(Schema.Union([Schema.Number, Schema.Null])),
690
+ page: Schema.optional(Schema.Union([Schema.Number, Schema.Null])),
691
+ perPage: Schema.optional(Schema.Union([Schema.Number, Schema.Null])),
692
+ totalCount: Schema.optional(Schema.Union([Schema.Number, Schema.Null])),
693
+ }).pipe(
694
+ Schema.encodeKeys({
695
+ count: "count",
696
+ page: "page",
697
+ perPage: "per_page",
698
+ totalCount: "total_count",
699
+ }),
700
+ ),
701
+ Schema.Null,
702
+ ]),
691
703
  ),
692
704
  }).pipe(
693
705
  Schema.encodeKeys({ result: "result", resultInfo: "result_info" }),
@@ -1314,12 +1326,12 @@ export interface ListResourceSharingsResponse {
1314
1326
  }[]
1315
1327
  | null;
1316
1328
  }[];
1317
- resultInfo: {
1329
+ resultInfo?: {
1318
1330
  count?: number | null;
1319
1331
  page?: number | null;
1320
1332
  perPage?: number | null;
1321
1333
  totalCount?: number | null;
1322
- };
1334
+ } | null;
1323
1335
  }
1324
1336
 
1325
1337
  export const ListResourceSharingsResponse =
@@ -1407,18 +1419,25 @@ export const ListResourceSharingsResponse =
1407
1419
  }),
1408
1420
  ),
1409
1421
  ),
1410
- resultInfo: Schema.Struct({
1411
- count: Schema.optional(Schema.Union([Schema.Number, Schema.Null])),
1412
- page: Schema.optional(Schema.Union([Schema.Number, Schema.Null])),
1413
- perPage: Schema.optional(Schema.Union([Schema.Number, Schema.Null])),
1414
- totalCount: Schema.optional(Schema.Union([Schema.Number, Schema.Null])),
1415
- }).pipe(
1416
- Schema.encodeKeys({
1417
- count: "count",
1418
- page: "page",
1419
- perPage: "per_page",
1420
- totalCount: "total_count",
1421
- }),
1422
+ resultInfo: Schema.optional(
1423
+ Schema.Union([
1424
+ Schema.Struct({
1425
+ count: Schema.optional(Schema.Union([Schema.Number, Schema.Null])),
1426
+ page: Schema.optional(Schema.Union([Schema.Number, Schema.Null])),
1427
+ perPage: Schema.optional(Schema.Union([Schema.Number, Schema.Null])),
1428
+ totalCount: Schema.optional(
1429
+ Schema.Union([Schema.Number, Schema.Null]),
1430
+ ),
1431
+ }).pipe(
1432
+ Schema.encodeKeys({
1433
+ count: "count",
1434
+ page: "page",
1435
+ perPage: "per_page",
1436
+ totalCount: "total_count",
1437
+ }),
1438
+ ),
1439
+ Schema.Null,
1440
+ ]),
1422
1441
  ),
1423
1442
  }).pipe(
1424
1443
  Schema.encodeKeys({ result: "result", resultInfo: "result_info" }),
@@ -655,7 +655,7 @@ export interface ListListItemsResponse {
655
655
  comment?: string | null;
656
656
  }
657
657
  )[];
658
- resultInfo: { cursors?: { after?: string | null } | null };
658
+ resultInfo?: { cursors?: { after?: string | null } | null } | null;
659
659
  }
660
660
 
661
661
  export const ListListItemsResponse = /*@__PURE__*/ /*#__PURE__*/ Schema.Struct({
@@ -764,16 +764,23 @@ export const ListListItemsResponse = /*@__PURE__*/ /*#__PURE__*/ Schema.Struct({
764
764
  ),
765
765
  ]),
766
766
  ),
767
- resultInfo: Schema.Struct({
768
- cursors: Schema.optional(
769
- Schema.Union([
770
- Schema.Struct({
771
- after: Schema.optional(Schema.Union([Schema.String, Schema.Null])),
772
- }),
773
- Schema.Null,
774
- ]),
775
- ),
776
- }),
767
+ resultInfo: Schema.optional(
768
+ Schema.Union([
769
+ Schema.Struct({
770
+ cursors: Schema.optional(
771
+ Schema.Union([
772
+ Schema.Struct({
773
+ after: Schema.optional(
774
+ Schema.Union([Schema.String, Schema.Null]),
775
+ ),
776
+ }),
777
+ Schema.Null,
778
+ ]),
779
+ ),
780
+ }),
781
+ Schema.Null,
782
+ ]),
783
+ ),
777
784
  }).pipe(
778
785
  Schema.encodeKeys({ result: "result", resultInfo: "result_info" }),
779
786
  ) as unknown as Schema.Schema<ListListItemsResponse>;
@@ -27309,11 +27309,11 @@ export interface ListRulesetsResponse {
27309
27309
  version: string;
27310
27310
  description?: string | null;
27311
27311
  }[];
27312
- resultInfo: {
27312
+ resultInfo?: {
27313
27313
  count?: number | null;
27314
27314
  cursor?: string | null;
27315
27315
  perPage?: number | null;
27316
- };
27316
+ } | null;
27317
27317
  }
27318
27318
 
27319
27319
  export const ListRulesetsResponse = /*@__PURE__*/ /*#__PURE__*/ Schema.Struct({
@@ -27362,16 +27362,21 @@ export const ListRulesetsResponse = /*@__PURE__*/ /*#__PURE__*/ Schema.Struct({
27362
27362
  }),
27363
27363
  ),
27364
27364
  ),
27365
- resultInfo: Schema.Struct({
27366
- count: Schema.optional(Schema.Union([Schema.Number, Schema.Null])),
27367
- cursor: Schema.optional(Schema.Union([Schema.String, Schema.Null])),
27368
- perPage: Schema.optional(Schema.Union([Schema.Number, Schema.Null])),
27369
- }).pipe(
27370
- Schema.encodeKeys({
27371
- count: "count",
27372
- cursor: "cursor",
27373
- perPage: "per_page",
27374
- }),
27365
+ resultInfo: Schema.optional(
27366
+ Schema.Union([
27367
+ Schema.Struct({
27368
+ count: Schema.optional(Schema.Union([Schema.Number, Schema.Null])),
27369
+ cursor: Schema.optional(Schema.Union([Schema.String, Schema.Null])),
27370
+ perPage: Schema.optional(Schema.Union([Schema.Number, Schema.Null])),
27371
+ }).pipe(
27372
+ Schema.encodeKeys({
27373
+ count: "count",
27374
+ cursor: "cursor",
27375
+ perPage: "per_page",
27376
+ }),
27377
+ ),
27378
+ Schema.Null,
27379
+ ]),
27375
27380
  ),
27376
27381
  }).pipe(
27377
27382
  Schema.encodeKeys({ result: "result", resultInfo: "result_info" }),