@distilled.cloud/cloudflare 0.0.0-john

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 (562) hide show
  1. package/README.md +59 -0
  2. package/lib/auth.d.ts +14 -0
  3. package/lib/auth.d.ts.map +1 -0
  4. package/lib/auth.js +13 -0
  5. package/lib/auth.js.map +1 -0
  6. package/lib/category.d.ts +2 -0
  7. package/lib/category.d.ts.map +1 -0
  8. package/lib/category.js +2 -0
  9. package/lib/category.js.map +1 -0
  10. package/lib/client/api.d.ts +12 -0
  11. package/lib/client/api.d.ts.map +1 -0
  12. package/lib/client/api.js +292 -0
  13. package/lib/client/api.js.map +1 -0
  14. package/lib/client/index.d.ts +8 -0
  15. package/lib/client/index.d.ts.map +1 -0
  16. package/lib/client/index.js +8 -0
  17. package/lib/client/index.js.map +1 -0
  18. package/lib/credentials.d.ts +68 -0
  19. package/lib/credentials.d.ts.map +1 -0
  20. package/lib/credentials.js +136 -0
  21. package/lib/credentials.js.map +1 -0
  22. package/lib/errors.d.ts +48 -0
  23. package/lib/errors.d.ts.map +1 -0
  24. package/lib/errors.js +31 -0
  25. package/lib/errors.js.map +1 -0
  26. package/lib/index.d.ts +10 -0
  27. package/lib/index.d.ts.map +1 -0
  28. package/lib/index.js +10 -0
  29. package/lib/index.js.map +1 -0
  30. package/lib/retry.d.ts +14 -0
  31. package/lib/retry.d.ts.map +1 -0
  32. package/lib/retry.js +14 -0
  33. package/lib/retry.js.map +1 -0
  34. package/lib/schemas.d.ts +29 -0
  35. package/lib/schemas.d.ts.map +1 -0
  36. package/lib/schemas.js +34 -0
  37. package/lib/schemas.js.map +1 -0
  38. package/lib/sensitive.d.ts +5 -0
  39. package/lib/sensitive.d.ts.map +1 -0
  40. package/lib/sensitive.js +5 -0
  41. package/lib/sensitive.js.map +1 -0
  42. package/lib/services/abuse-reports.d.ts +296 -0
  43. package/lib/services/abuse-reports.d.ts.map +1 -0
  44. package/lib/services/abuse-reports.js +414 -0
  45. package/lib/services/abuse-reports.js.map +1 -0
  46. package/lib/services/accounts.d.ts +766 -0
  47. package/lib/services/accounts.d.ts.map +1 -0
  48. package/lib/services/accounts.js +860 -0
  49. package/lib/services/accounts.js.map +1 -0
  50. package/lib/services/acm.d.ts +73 -0
  51. package/lib/services/acm.d.ts.map +1 -0
  52. package/lib/services/acm.js +80 -0
  53. package/lib/services/acm.js.map +1 -0
  54. package/lib/services/addressing.d.ts +1321 -0
  55. package/lib/services/addressing.d.ts.map +1 -0
  56. package/lib/services/addressing.js +1863 -0
  57. package/lib/services/addressing.js.map +1 -0
  58. package/lib/services/ai-gateway.d.ts +1137 -0
  59. package/lib/services/ai-gateway.d.ts.map +1 -0
  60. package/lib/services/ai-gateway.js +1830 -0
  61. package/lib/services/ai-gateway.js.map +1 -0
  62. package/lib/services/ai.d.ts +297 -0
  63. package/lib/services/ai.d.ts.map +1 -0
  64. package/lib/services/ai.js +352 -0
  65. package/lib/services/ai.js.map +1 -0
  66. package/lib/services/aisearch.d.ts +1069 -0
  67. package/lib/services/aisearch.d.ts.map +1 -0
  68. package/lib/services/aisearch.js +2542 -0
  69. package/lib/services/aisearch.js.map +1 -0
  70. package/lib/services/alerting.d.ts +855 -0
  71. package/lib/services/alerting.d.ts.map +1 -0
  72. package/lib/services/alerting.js +1445 -0
  73. package/lib/services/alerting.js.map +1 -0
  74. package/lib/services/api-gateway.d.ts +1088 -0
  75. package/lib/services/api-gateway.d.ts.map +1 -0
  76. package/lib/services/api-gateway.js +1655 -0
  77. package/lib/services/api-gateway.js.map +1 -0
  78. package/lib/services/argo.d.ts +101 -0
  79. package/lib/services/argo.d.ts.map +1 -0
  80. package/lib/services/argo.js +113 -0
  81. package/lib/services/argo.js.map +1 -0
  82. package/lib/services/audit-logs.d.ts +46 -0
  83. package/lib/services/audit-logs.d.ts.map +1 -0
  84. package/lib/services/audit-logs.js +37 -0
  85. package/lib/services/audit-logs.js.map +1 -0
  86. package/lib/services/billing.d.ts +62 -0
  87. package/lib/services/billing.d.ts.map +1 -0
  88. package/lib/services/billing.js +102 -0
  89. package/lib/services/billing.js.map +1 -0
  90. package/lib/services/bot-management.d.ts +124 -0
  91. package/lib/services/bot-management.d.ts.map +1 -0
  92. package/lib/services/bot-management.js +262 -0
  93. package/lib/services/bot-management.js.map +1 -0
  94. package/lib/services/botnet-feed.d.ts +65 -0
  95. package/lib/services/botnet-feed.d.ts.map +1 -0
  96. package/lib/services/botnet-feed.js +88 -0
  97. package/lib/services/botnet-feed.js.map +1 -0
  98. package/lib/services/brand-protection.d.ts +194 -0
  99. package/lib/services/brand-protection.d.ts.map +1 -0
  100. package/lib/services/brand-protection.js +221 -0
  101. package/lib/services/brand-protection.js.map +1 -0
  102. package/lib/services/browser-rendering.d.ts +857 -0
  103. package/lib/services/browser-rendering.d.ts.map +1 -0
  104. package/lib/services/browser-rendering.js +1142 -0
  105. package/lib/services/browser-rendering.js.map +1 -0
  106. package/lib/services/cache.d.ts +287 -0
  107. package/lib/services/cache.d.ts.map +1 -0
  108. package/lib/services/cache.js +354 -0
  109. package/lib/services/cache.js.map +1 -0
  110. package/lib/services/calls.d.ts +223 -0
  111. package/lib/services/calls.d.ts.map +1 -0
  112. package/lib/services/calls.js +188 -0
  113. package/lib/services/calls.js.map +1 -0
  114. package/lib/services/certificate-authorities.d.ts +40 -0
  115. package/lib/services/certificate-authorities.d.ts.map +1 -0
  116. package/lib/services/certificate-authorities.js +49 -0
  117. package/lib/services/certificate-authorities.js.map +1 -0
  118. package/lib/services/client-certificates.d.ts +288 -0
  119. package/lib/services/client-certificates.d.ts.map +1 -0
  120. package/lib/services/client-certificates.js +379 -0
  121. package/lib/services/client-certificates.js.map +1 -0
  122. package/lib/services/cloud-connector.d.ts +88 -0
  123. package/lib/services/cloud-connector.d.ts.map +1 -0
  124. package/lib/services/cloud-connector.js +97 -0
  125. package/lib/services/cloud-connector.js.map +1 -0
  126. package/lib/services/cloudforce-one.d.ts +1387 -0
  127. package/lib/services/cloudforce-one.d.ts.map +1 -0
  128. package/lib/services/cloudforce-one.js +1741 -0
  129. package/lib/services/cloudforce-one.js.map +1 -0
  130. package/lib/services/connectivity.d.ts +291 -0
  131. package/lib/services/connectivity.d.ts.map +1 -0
  132. package/lib/services/connectivity.js +404 -0
  133. package/lib/services/connectivity.js.map +1 -0
  134. package/lib/services/content-scanning.d.ts +156 -0
  135. package/lib/services/content-scanning.d.ts.map +1 -0
  136. package/lib/services/content-scanning.js +175 -0
  137. package/lib/services/content-scanning.js.map +1 -0
  138. package/lib/services/custom-certificates.d.ts +240 -0
  139. package/lib/services/custom-certificates.d.ts.map +1 -0
  140. package/lib/services/custom-certificates.js +336 -0
  141. package/lib/services/custom-certificates.js.map +1 -0
  142. package/lib/services/custom-hostnames.d.ts +590 -0
  143. package/lib/services/custom-hostnames.d.ts.map +1 -0
  144. package/lib/services/custom-hostnames.js +1204 -0
  145. package/lib/services/custom-hostnames.js.map +1 -0
  146. package/lib/services/custom-nameservers.d.ts +87 -0
  147. package/lib/services/custom-nameservers.d.ts.map +1 -0
  148. package/lib/services/custom-nameservers.js +95 -0
  149. package/lib/services/custom-nameservers.js.map +1 -0
  150. package/lib/services/custom-pages.d.ts +89 -0
  151. package/lib/services/custom-pages.d.ts.map +1 -0
  152. package/lib/services/custom-pages.js +140 -0
  153. package/lib/services/custom-pages.js.map +1 -0
  154. package/lib/services/d1.d.ts +392 -0
  155. package/lib/services/d1.d.ts.map +1 -0
  156. package/lib/services/d1.js +487 -0
  157. package/lib/services/d1.js.map +1 -0
  158. package/lib/services/dcv-delegation.d.ts +24 -0
  159. package/lib/services/dcv-delegation.d.ts.map +1 -0
  160. package/lib/services/dcv-delegation.js +24 -0
  161. package/lib/services/dcv-delegation.js.map +1 -0
  162. package/lib/services/diagnostics.d.ts +208 -0
  163. package/lib/services/diagnostics.d.ts.map +1 -0
  164. package/lib/services/diagnostics.js +288 -0
  165. package/lib/services/diagnostics.js.map +1 -0
  166. package/lib/services/dns-firewall.d.ts +317 -0
  167. package/lib/services/dns-firewall.d.ts.map +1 -0
  168. package/lib/services/dns-firewall.js +400 -0
  169. package/lib/services/dns-firewall.js.map +1 -0
  170. package/lib/services/dns.d.ts +3065 -0
  171. package/lib/services/dns.d.ts.map +1 -0
  172. package/lib/services/dns.js +4627 -0
  173. package/lib/services/dns.js.map +1 -0
  174. package/lib/services/durable-objects.d.ts +92 -0
  175. package/lib/services/durable-objects.d.ts.map +1 -0
  176. package/lib/services/durable-objects.js +103 -0
  177. package/lib/services/durable-objects.js.map +1 -0
  178. package/lib/services/email-routing.d.ts +598 -0
  179. package/lib/services/email-routing.d.ts.map +1 -0
  180. package/lib/services/email-routing.js +715 -0
  181. package/lib/services/email-routing.js.map +1 -0
  182. package/lib/services/email-security.d.ts +1389 -0
  183. package/lib/services/email-security.d.ts.map +1 -0
  184. package/lib/services/email-security.js +2261 -0
  185. package/lib/services/email-security.js.map +1 -0
  186. package/lib/services/filters.d.ts +197 -0
  187. package/lib/services/filters.d.ts.map +1 -0
  188. package/lib/services/filters.js +168 -0
  189. package/lib/services/filters.js.map +1 -0
  190. package/lib/services/firewall.d.ts +1352 -0
  191. package/lib/services/firewall.d.ts.map +1 -0
  192. package/lib/services/firewall.js +2084 -0
  193. package/lib/services/firewall.js.map +1 -0
  194. package/lib/services/healthchecks.d.ts +507 -0
  195. package/lib/services/healthchecks.d.ts.map +1 -0
  196. package/lib/services/healthchecks.js +867 -0
  197. package/lib/services/healthchecks.js.map +1 -0
  198. package/lib/services/hostnames.d.ts +86 -0
  199. package/lib/services/hostnames.d.ts.map +1 -0
  200. package/lib/services/hostnames.js +111 -0
  201. package/lib/services/hostnames.js.map +1 -0
  202. package/lib/services/hyperdrive.d.ts +203 -0
  203. package/lib/services/hyperdrive.d.ts.map +1 -0
  204. package/lib/services/hyperdrive.js +300 -0
  205. package/lib/services/hyperdrive.js.map +1 -0
  206. package/lib/services/iam.d.ts +657 -0
  207. package/lib/services/iam.d.ts.map +1 -0
  208. package/lib/services/iam.js +843 -0
  209. package/lib/services/iam.js.map +1 -0
  210. package/lib/services/images.d.ts +427 -0
  211. package/lib/services/images.d.ts.map +1 -0
  212. package/lib/services/images.js +444 -0
  213. package/lib/services/images.js.map +1 -0
  214. package/lib/services/intel.d.ts +865 -0
  215. package/lib/services/intel.d.ts.map +1 -0
  216. package/lib/services/intel.js +1266 -0
  217. package/lib/services/intel.js.map +1 -0
  218. package/lib/services/ips.d.ts +28 -0
  219. package/lib/services/ips.d.ts.map +1 -0
  220. package/lib/services/ips.js +39 -0
  221. package/lib/services/ips.js.map +1 -0
  222. package/lib/services/keyless-certificates.d.ts +197 -0
  223. package/lib/services/keyless-certificates.d.ts.map +1 -0
  224. package/lib/services/keyless-certificates.js +229 -0
  225. package/lib/services/keyless-certificates.js.map +1 -0
  226. package/lib/services/kv.d.ts +369 -0
  227. package/lib/services/kv.d.ts.map +1 -0
  228. package/lib/services/kv.js +453 -0
  229. package/lib/services/kv.js.map +1 -0
  230. package/lib/services/leaked-credential-checks.d.ts +129 -0
  231. package/lib/services/leaked-credential-checks.d.ts.map +1 -0
  232. package/lib/services/leaked-credential-checks.js +138 -0
  233. package/lib/services/leaked-credential-checks.js.map +1 -0
  234. package/lib/services/load-balancers.d.ts +1973 -0
  235. package/lib/services/load-balancers.d.ts.map +1 -0
  236. package/lib/services/load-balancers.js +3181 -0
  237. package/lib/services/load-balancers.js.map +1 -0
  238. package/lib/services/logpush.d.ts +401 -0
  239. package/lib/services/logpush.d.ts.map +1 -0
  240. package/lib/services/logpush.js +732 -0
  241. package/lib/services/logpush.js.map +1 -0
  242. package/lib/services/logs.d.ts +125 -0
  243. package/lib/services/logs.d.ts.map +1 -0
  244. package/lib/services/logs.js +149 -0
  245. package/lib/services/logs.js.map +1 -0
  246. package/lib/services/magic-cloud-networking.d.ts +1892 -0
  247. package/lib/services/magic-cloud-networking.d.ts.map +1 -0
  248. package/lib/services/magic-cloud-networking.js +5291 -0
  249. package/lib/services/magic-cloud-networking.js.map +1 -0
  250. package/lib/services/magic-network-monitoring.d.ts +379 -0
  251. package/lib/services/magic-network-monitoring.d.ts.map +1 -0
  252. package/lib/services/magic-network-monitoring.js +557 -0
  253. package/lib/services/magic-network-monitoring.js.map +1 -0
  254. package/lib/services/magic-transit.d.ts +3886 -0
  255. package/lib/services/magic-transit.d.ts.map +1 -0
  256. package/lib/services/magic-transit.js +6284 -0
  257. package/lib/services/magic-transit.js.map +1 -0
  258. package/lib/services/managed-transforms.d.ts +79 -0
  259. package/lib/services/managed-transforms.d.ts.map +1 -0
  260. package/lib/services/managed-transforms.js +111 -0
  261. package/lib/services/managed-transforms.js.map +1 -0
  262. package/lib/services/memberships.d.ts +204 -0
  263. package/lib/services/memberships.d.ts.map +1 -0
  264. package/lib/services/memberships.js +308 -0
  265. package/lib/services/memberships.js.map +1 -0
  266. package/lib/services/mtls-certificates.d.ts +164 -0
  267. package/lib/services/mtls-certificates.d.ts.map +1 -0
  268. package/lib/services/mtls-certificates.js +192 -0
  269. package/lib/services/mtls-certificates.js.map +1 -0
  270. package/lib/services/network-interconnects.d.ts +410 -0
  271. package/lib/services/network-interconnects.d.ts.map +1 -0
  272. package/lib/services/network-interconnects.js +583 -0
  273. package/lib/services/network-interconnects.js.map +1 -0
  274. package/lib/services/organizations.d.ts +232 -0
  275. package/lib/services/organizations.d.ts.map +1 -0
  276. package/lib/services/organizations.js +370 -0
  277. package/lib/services/organizations.js.map +1 -0
  278. package/lib/services/origin-ca-certificates.d.ts +119 -0
  279. package/lib/services/origin-ca-certificates.d.ts.map +1 -0
  280. package/lib/services/origin-ca-certificates.js +183 -0
  281. package/lib/services/origin-ca-certificates.js.map +1 -0
  282. package/lib/services/origin-post-quantum-encryption.d.ts +50 -0
  283. package/lib/services/origin-post-quantum-encryption.d.ts.map +1 -0
  284. package/lib/services/origin-post-quantum-encryption.js +64 -0
  285. package/lib/services/origin-post-quantum-encryption.js.map +1 -0
  286. package/lib/services/origin-tls-client-auth.d.ts +308 -0
  287. package/lib/services/origin-tls-client-auth.d.ts.map +1 -0
  288. package/lib/services/origin-tls-client-auth.js +435 -0
  289. package/lib/services/origin-tls-client-auth.js.map +1 -0
  290. package/lib/services/page-rules.d.ts +773 -0
  291. package/lib/services/page-rules.d.ts.map +1 -0
  292. package/lib/services/page-rules.js +1373 -0
  293. package/lib/services/page-rules.js.map +1 -0
  294. package/lib/services/page-shield.d.ts +505 -0
  295. package/lib/services/page-shield.d.ts.map +1 -0
  296. package/lib/services/page-shield.js +520 -0
  297. package/lib/services/page-shield.js.map +1 -0
  298. package/lib/services/pages.d.ts +1949 -0
  299. package/lib/services/pages.d.ts.map +1 -0
  300. package/lib/services/pages.js +3030 -0
  301. package/lib/services/pages.js.map +1 -0
  302. package/lib/services/pipelines.d.ts +1716 -0
  303. package/lib/services/pipelines.d.ts.map +1 -0
  304. package/lib/services/pipelines.js +2991 -0
  305. package/lib/services/pipelines.js.map +1 -0
  306. package/lib/services/queues.d.ts +904 -0
  307. package/lib/services/queues.d.ts.map +1 -0
  308. package/lib/services/queues.js +1250 -0
  309. package/lib/services/queues.js.map +1 -0
  310. package/lib/services/r2-data-catalog.d.ts +341 -0
  311. package/lib/services/r2-data-catalog.d.ts.map +1 -0
  312. package/lib/services/r2-data-catalog.js +513 -0
  313. package/lib/services/r2-data-catalog.js.map +1 -0
  314. package/lib/services/r2.d.ts +1087 -0
  315. package/lib/services/r2.d.ts.map +1 -0
  316. package/lib/services/r2.js +1404 -0
  317. package/lib/services/r2.js.map +1 -0
  318. package/lib/services/radar.d.ts +9365 -0
  319. package/lib/services/radar.d.ts.map +1 -0
  320. package/lib/services/radar.js +20552 -0
  321. package/lib/services/radar.js.map +1 -0
  322. package/lib/services/rate-limits.d.ts +360 -0
  323. package/lib/services/rate-limits.d.ts.map +1 -0
  324. package/lib/services/rate-limits.js +545 -0
  325. package/lib/services/rate-limits.js.map +1 -0
  326. package/lib/services/realtime-kit.d.ts +2728 -0
  327. package/lib/services/realtime-kit.d.ts.map +1 -0
  328. package/lib/services/realtime-kit.js +5402 -0
  329. package/lib/services/realtime-kit.js.map +1 -0
  330. package/lib/services/registrar.d.ts +121 -0
  331. package/lib/services/registrar.d.ts.map +1 -0
  332. package/lib/services/registrar.js +167 -0
  333. package/lib/services/registrar.js.map +1 -0
  334. package/lib/services/request-tracers.d.ts +61 -0
  335. package/lib/services/request-tracers.d.ts.map +1 -0
  336. package/lib/services/request-tracers.js +85 -0
  337. package/lib/services/request-tracers.js.map +1 -0
  338. package/lib/services/resource-sharing.d.ts +622 -0
  339. package/lib/services/resource-sharing.d.ts.map +1 -0
  340. package/lib/services/resource-sharing.js +929 -0
  341. package/lib/services/resource-sharing.js.map +1 -0
  342. package/lib/services/rules.d.ts +346 -0
  343. package/lib/services/rules.d.ts.map +1 -0
  344. package/lib/services/rules.js +431 -0
  345. package/lib/services/rules.js.map +1 -0
  346. package/lib/services/rulesets.d.ts +3345 -0
  347. package/lib/services/rulesets.d.ts.map +1 -0
  348. package/lib/services/rulesets.js +7904 -0
  349. package/lib/services/rulesets.js.map +1 -0
  350. package/lib/services/rum.d.ts +314 -0
  351. package/lib/services/rum.d.ts.map +1 -0
  352. package/lib/services/rum.js +442 -0
  353. package/lib/services/rum.js.map +1 -0
  354. package/lib/services/schema-validation.d.ts +273 -0
  355. package/lib/services/schema-validation.d.ts.map +1 -0
  356. package/lib/services/schema-validation.js +365 -0
  357. package/lib/services/schema-validation.js.map +1 -0
  358. package/lib/services/secrets-store.d.ts +393 -0
  359. package/lib/services/secrets-store.d.ts.map +1 -0
  360. package/lib/services/secrets-store.js +452 -0
  361. package/lib/services/secrets-store.js.map +1 -0
  362. package/lib/services/security-center.d.ts +136 -0
  363. package/lib/services/security-center.d.ts.map +1 -0
  364. package/lib/services/security-center.js +196 -0
  365. package/lib/services/security-center.js.map +1 -0
  366. package/lib/services/security-txt.d.ts +105 -0
  367. package/lib/services/security-txt.d.ts.map +1 -0
  368. package/lib/services/security-txt.js +136 -0
  369. package/lib/services/security-txt.js.map +1 -0
  370. package/lib/services/snippets.d.ts +190 -0
  371. package/lib/services/snippets.d.ts.map +1 -0
  372. package/lib/services/snippets.js +221 -0
  373. package/lib/services/snippets.js.map +1 -0
  374. package/lib/services/spectrum.d.ts +350 -0
  375. package/lib/services/spectrum.d.ts.map +1 -0
  376. package/lib/services/spectrum.js +535 -0
  377. package/lib/services/spectrum.js.map +1 -0
  378. package/lib/services/speed.d.ts +257 -0
  379. package/lib/services/speed.d.ts.map +1 -0
  380. package/lib/services/speed.js +471 -0
  381. package/lib/services/speed.js.map +1 -0
  382. package/lib/services/ssl.d.ts +412 -0
  383. package/lib/services/ssl.d.ts.map +1 -0
  384. package/lib/services/ssl.js +755 -0
  385. package/lib/services/ssl.js.map +1 -0
  386. package/lib/services/stream.d.ts +1110 -0
  387. package/lib/services/stream.d.ts.map +1 -0
  388. package/lib/services/stream.js +1085 -0
  389. package/lib/services/stream.js.map +1 -0
  390. package/lib/services/token-validation.d.ts +662 -0
  391. package/lib/services/token-validation.d.ts.map +1 -0
  392. package/lib/services/token-validation.js +834 -0
  393. package/lib/services/token-validation.js.map +1 -0
  394. package/lib/services/turnstile.d.ts +272 -0
  395. package/lib/services/turnstile.d.ts.map +1 -0
  396. package/lib/services/turnstile.js +339 -0
  397. package/lib/services/turnstile.js.map +1 -0
  398. package/lib/services/url-normalization.d.ts +53 -0
  399. package/lib/services/url-normalization.d.ts.map +1 -0
  400. package/lib/services/url-normalization.js +52 -0
  401. package/lib/services/url-normalization.js.map +1 -0
  402. package/lib/services/url-scanner.d.ts +612 -0
  403. package/lib/services/url-scanner.d.ts.map +1 -0
  404. package/lib/services/url-scanner.js +915 -0
  405. package/lib/services/url-scanner.js.map +1 -0
  406. package/lib/services/user.d.ts +507 -0
  407. package/lib/services/user.d.ts.map +1 -0
  408. package/lib/services/user.js +634 -0
  409. package/lib/services/user.js.map +1 -0
  410. package/lib/services/vectorize.d.ts +297 -0
  411. package/lib/services/vectorize.d.ts.map +1 -0
  412. package/lib/services/vectorize.js +351 -0
  413. package/lib/services/vectorize.js.map +1 -0
  414. package/lib/services/waiting-rooms.d.ts +1149 -0
  415. package/lib/services/waiting-rooms.d.ts.map +1 -0
  416. package/lib/services/waiting-rooms.js +1859 -0
  417. package/lib/services/waiting-rooms.js.map +1 -0
  418. package/lib/services/web3.d.ts +289 -0
  419. package/lib/services/web3.d.ts.map +1 -0
  420. package/lib/services/web3.js +381 -0
  421. package/lib/services/web3.js.map +1 -0
  422. package/lib/services/workers-for-platforms.d.ts +1394 -0
  423. package/lib/services/workers-for-platforms.d.ts.map +1 -0
  424. package/lib/services/workers-for-platforms.js +2121 -0
  425. package/lib/services/workers-for-platforms.js.map +1 -0
  426. package/lib/services/workers.d.ts +3827 -0
  427. package/lib/services/workers.d.ts.map +1 -0
  428. package/lib/services/workers.js +6105 -0
  429. package/lib/services/workers.js.map +1 -0
  430. package/lib/services/workflows.d.ts +442 -0
  431. package/lib/services/workflows.d.ts.map +1 -0
  432. package/lib/services/workflows.js +599 -0
  433. package/lib/services/workflows.js.map +1 -0
  434. package/lib/services/zaraz.d.ts +312 -0
  435. package/lib/services/zaraz.d.ts.map +1 -0
  436. package/lib/services/zaraz.js +305 -0
  437. package/lib/services/zaraz.js.map +1 -0
  438. package/lib/services/zero-trust.d.ts +18235 -0
  439. package/lib/services/zero-trust.d.ts.map +1 -0
  440. package/lib/services/zero-trust.js +30268 -0
  441. package/lib/services/zero-trust.js.map +1 -0
  442. package/lib/services/zones.d.ts +1382 -0
  443. package/lib/services/zones.d.ts.map +1 -0
  444. package/lib/services/zones.js +2477 -0
  445. package/lib/services/zones.js.map +1 -0
  446. package/lib/traits.d.ts +28 -0
  447. package/lib/traits.d.ts.map +1 -0
  448. package/lib/traits.js +26 -0
  449. package/lib/traits.js.map +1 -0
  450. package/package.json +82 -0
  451. package/src/auth.ts +15 -0
  452. package/src/category.ts +1 -0
  453. package/src/client/api.ts +421 -0
  454. package/src/client/index.ts +7 -0
  455. package/src/credentials.ts +271 -0
  456. package/src/errors.ts +73 -0
  457. package/src/index.ts +9 -0
  458. package/src/retry.ts +35 -0
  459. package/src/schemas.ts +51 -0
  460. package/src/sensitive.ts +4 -0
  461. package/src/services/abuse-reports.ts +955 -0
  462. package/src/services/accounts.ts +2152 -0
  463. package/src/services/acm.ts +178 -0
  464. package/src/services/addressing.ts +4262 -0
  465. package/src/services/ai-gateway.ts +3773 -0
  466. package/src/services/ai.ts +901 -0
  467. package/src/services/aisearch.ts +5215 -0
  468. package/src/services/alerting.ts +3303 -0
  469. package/src/services/api-gateway.ts +3890 -0
  470. package/src/services/argo.ts +270 -0
  471. package/src/services/audit-logs.ts +90 -0
  472. package/src/services/billing.ts +176 -0
  473. package/src/services/bot-management.ts +545 -0
  474. package/src/services/botnet-feed.ts +205 -0
  475. package/src/services/brand-protection.ts +575 -0
  476. package/src/services/browser-rendering.ts +2720 -0
  477. package/src/services/cache.ts +877 -0
  478. package/src/services/calls.ts +548 -0
  479. package/src/services/certificate-authorities.ts +114 -0
  480. package/src/services/client-certificates.ts +815 -0
  481. package/src/services/cloud-connector.ts +248 -0
  482. package/src/services/cloudforce-one.ts +4104 -0
  483. package/src/services/connectivity.ts +706 -0
  484. package/src/services/content-scanning.ts +458 -0
  485. package/src/services/custom-certificates.ts +690 -0
  486. package/src/services/custom-hostnames.ts +2641 -0
  487. package/src/services/custom-nameservers.ts +235 -0
  488. package/src/services/custom-pages.ts +311 -0
  489. package/src/services/d1.ts +1208 -0
  490. package/src/services/dcv-delegation.ts +54 -0
  491. package/src/services/diagnostics.ts +677 -0
  492. package/src/services/dns-firewall.ts +904 -0
  493. package/src/services/dns.ts +9277 -0
  494. package/src/services/durable-objects.ts +237 -0
  495. package/src/services/email-routing.ts +1796 -0
  496. package/src/services/email-security.ts +5052 -0
  497. package/src/services/filters.ts +488 -0
  498. package/src/services/firewall.ts +4728 -0
  499. package/src/services/healthchecks.ts +1866 -0
  500. package/src/services/hostnames.ts +254 -0
  501. package/src/services/hyperdrive.ts +595 -0
  502. package/src/services/iam.ts +1969 -0
  503. package/src/services/images.ts +1180 -0
  504. package/src/services/intel.ts +3072 -0
  505. package/src/services/ips.ts +88 -0
  506. package/src/services/keyless-certificates.ts +509 -0
  507. package/src/services/kv.ts +1129 -0
  508. package/src/services/leaked-credential-checks.ts +364 -0
  509. package/src/services/load-balancers.ts +6993 -0
  510. package/src/services/logpush.ts +1695 -0
  511. package/src/services/logs.ts +389 -0
  512. package/src/services/magic-cloud-networking.ts +10747 -0
  513. package/src/services/magic-network-monitoring.ts +1200 -0
  514. package/src/services/magic-transit.ts +13673 -0
  515. package/src/services/managed-transforms.ts +245 -0
  516. package/src/services/memberships.ts +698 -0
  517. package/src/services/mtls-certificates.ts +444 -0
  518. package/src/services/network-interconnects.ts +1253 -0
  519. package/src/services/organizations.ts +738 -0
  520. package/src/services/origin-ca-certificates.ts +369 -0
  521. package/src/services/origin-post-quantum-encryption.ts +136 -0
  522. package/src/services/origin-tls-client-auth.ts +1002 -0
  523. package/src/services/page-rules.ts +2632 -0
  524. package/src/services/page-shield.ts +1371 -0
  525. package/src/services/pages.ts +6167 -0
  526. package/src/services/pipelines.ts +6455 -0
  527. package/src/services/queues.ts +2827 -0
  528. package/src/services/r2-data-catalog.ts +1151 -0
  529. package/src/services/r2.ts +3529 -0
  530. package/src/services/radar.ts +42836 -0
  531. package/src/services/rate-limits.ts +1252 -0
  532. package/src/services/realtime-kit.ts +11080 -0
  533. package/src/services/registrar.ts +390 -0
  534. package/src/services/request-tracers.ts +161 -0
  535. package/src/services/resource-sharing.ts +2082 -0
  536. package/src/services/rules.ts +953 -0
  537. package/src/services/rulesets.ts +15361 -0
  538. package/src/services/rum.ts +994 -0
  539. package/src/services/schema-validation.ts +869 -0
  540. package/src/services/secrets-store.ts +1050 -0
  541. package/src/services/security-center.ts +495 -0
  542. package/src/services/security-txt.ts +317 -0
  543. package/src/services/snippets.ts +562 -0
  544. package/src/services/spectrum.ts +1190 -0
  545. package/src/services/speed.ts +1154 -0
  546. package/src/services/ssl.ts +1714 -0
  547. package/src/services/stream.ts +3008 -0
  548. package/src/services/token-validation.ts +1825 -0
  549. package/src/services/turnstile.ts +725 -0
  550. package/src/services/url-normalization.ts +133 -0
  551. package/src/services/url-scanner.ts +1851 -0
  552. package/src/services/user.ts +1587 -0
  553. package/src/services/vectorize.ts +875 -0
  554. package/src/services/waiting-rooms.ts +4216 -0
  555. package/src/services/web3.ts +899 -0
  556. package/src/services/workers-for-platforms.ts +4134 -0
  557. package/src/services/workers.ts +12298 -0
  558. package/src/services/workflows.ts +1372 -0
  559. package/src/services/zaraz.ts +833 -0
  560. package/src/services/zero-trust.ts +64685 -0
  561. package/src/services/zones.ts +5106 -0
  562. package/src/traits.ts +47 -0
@@ -0,0 +1,1252 @@
1
+ /**
2
+ * Cloudflare RATE-LIMITS API
3
+ *
4
+ * Generated from Cloudflare TypeScript SDK.
5
+ * DO NOT EDIT - regenerate with: bun scripts/generate.ts --service rate-limits
6
+ */
7
+
8
+ import * as stream from "effect/Stream";
9
+ import * as Schema from "effect/Schema";
10
+ import type * as HttpClient from "effect/unstable/http/HttpClient";
11
+ import * as API from "../client/api.ts";
12
+ import * as T from "../traits.ts";
13
+ import type { Credentials } from "../credentials.ts";
14
+ import { type DefaultErrors } from "../errors.ts";
15
+
16
+ // =============================================================================
17
+ // RateLimit
18
+ // =============================================================================
19
+
20
+ export interface GetRateLimitRequest {
21
+ rateLimitId: string;
22
+ /** Defines an identifier. */
23
+ zoneId: string;
24
+ }
25
+
26
+ export const GetRateLimitRequest = /*@__PURE__*/ /*#__PURE__*/ Schema.Struct({
27
+ rateLimitId: Schema.String.pipe(T.HttpPath("rateLimitId")),
28
+ zoneId: Schema.String.pipe(T.HttpPath("zone_id")),
29
+ }).pipe(
30
+ T.Http({ method: "GET", path: "/zones/{zone_id}/rate_limits/{rateLimitId}" }),
31
+ ) as unknown as Schema.Schema<GetRateLimitRequest>;
32
+
33
+ export interface GetRateLimitResponse {
34
+ /** The unique identifier of the rate limit. */
35
+ id?: string | null;
36
+ /** The action to perform when the threshold of matched traffic within the configured period is exceeded. */
37
+ action?: {
38
+ mode?:
39
+ | "simulate"
40
+ | "ban"
41
+ | "challenge"
42
+ | "js_challenge"
43
+ | "managed_challenge"
44
+ | null;
45
+ response?: { body?: string | null; contentType?: string | null } | null;
46
+ timeout?: number | null;
47
+ } | null;
48
+ /** Criteria specifying when the current rate limit should be bypassed. You can specify that the rate limit should not apply to one or more URLs. */
49
+ bypass?: { name?: "url" | null; value?: string | null }[] | null;
50
+ /** An informative summary of the rule. This value is sanitized and any tags will be removed. */
51
+ description?: string | null;
52
+ /** When true, indicates that the rate limit is currently disabled. */
53
+ disabled?: boolean | null;
54
+ /** Determines which traffic the rate limit counts towards the threshold. */
55
+ match?: {
56
+ headers?:
57
+ | {
58
+ name?: string | null;
59
+ op?: "eq" | "ne" | null;
60
+ value?: string | null;
61
+ }[]
62
+ | null;
63
+ request?: {
64
+ methods?:
65
+ | ("GET" | "POST" | "PUT" | "DELETE" | "PATCH" | "HEAD" | "_ALL_")[]
66
+ | null;
67
+ schemes?: string[] | null;
68
+ url?: string | null;
69
+ } | null;
70
+ response?: { originTraffic?: boolean | null } | null;
71
+ } | null;
72
+ /** The time in seconds (an integer value) to count matching traffic. If the count exceeds the configured threshold within this period, Cloudflare will perform the configured action. */
73
+ period?: number | null;
74
+ /** The threshold that will trigger the configured mitigation action. Configure this value along with the `period` property to establish a threshold per period. */
75
+ threshold?: number | null;
76
+ }
77
+
78
+ export const GetRateLimitResponse = /*@__PURE__*/ /*#__PURE__*/ Schema.Struct({
79
+ id: Schema.optional(Schema.Union([Schema.String, Schema.Null])),
80
+ action: Schema.optional(
81
+ Schema.Union([
82
+ Schema.Struct({
83
+ mode: Schema.optional(
84
+ Schema.Union([
85
+ Schema.Literals([
86
+ "simulate",
87
+ "ban",
88
+ "challenge",
89
+ "js_challenge",
90
+ "managed_challenge",
91
+ ]),
92
+ Schema.Null,
93
+ ]),
94
+ ),
95
+ response: Schema.optional(
96
+ Schema.Union([
97
+ Schema.Struct({
98
+ body: Schema.optional(Schema.Union([Schema.String, Schema.Null])),
99
+ contentType: Schema.optional(
100
+ Schema.Union([Schema.String, Schema.Null]),
101
+ ),
102
+ }).pipe(
103
+ Schema.encodeKeys({ body: "body", contentType: "content_type" }),
104
+ ),
105
+ Schema.Null,
106
+ ]),
107
+ ),
108
+ timeout: Schema.optional(Schema.Union([Schema.Number, Schema.Null])),
109
+ }),
110
+ Schema.Null,
111
+ ]),
112
+ ),
113
+ bypass: Schema.optional(
114
+ Schema.Union([
115
+ Schema.Array(
116
+ Schema.Struct({
117
+ name: Schema.optional(
118
+ Schema.Union([Schema.Literal("url"), Schema.Null]),
119
+ ),
120
+ value: Schema.optional(Schema.Union([Schema.String, Schema.Null])),
121
+ }),
122
+ ),
123
+ Schema.Null,
124
+ ]),
125
+ ),
126
+ description: Schema.optional(Schema.Union([Schema.String, Schema.Null])),
127
+ disabled: Schema.optional(Schema.Union([Schema.Boolean, Schema.Null])),
128
+ match: Schema.optional(
129
+ Schema.Union([
130
+ Schema.Struct({
131
+ headers: Schema.optional(
132
+ Schema.Union([
133
+ Schema.Array(
134
+ Schema.Struct({
135
+ name: Schema.optional(
136
+ Schema.Union([Schema.String, Schema.Null]),
137
+ ),
138
+ op: Schema.optional(
139
+ Schema.Union([Schema.Literals(["eq", "ne"]), Schema.Null]),
140
+ ),
141
+ value: Schema.optional(
142
+ Schema.Union([Schema.String, Schema.Null]),
143
+ ),
144
+ }),
145
+ ),
146
+ Schema.Null,
147
+ ]),
148
+ ),
149
+ request: Schema.optional(
150
+ Schema.Union([
151
+ Schema.Struct({
152
+ methods: Schema.optional(
153
+ Schema.Union([
154
+ Schema.Array(
155
+ Schema.Literals([
156
+ "GET",
157
+ "POST",
158
+ "PUT",
159
+ "DELETE",
160
+ "PATCH",
161
+ "HEAD",
162
+ "_ALL_",
163
+ ]),
164
+ ),
165
+ Schema.Null,
166
+ ]),
167
+ ),
168
+ schemes: Schema.optional(
169
+ Schema.Union([Schema.Array(Schema.String), Schema.Null]),
170
+ ),
171
+ url: Schema.optional(Schema.Union([Schema.String, Schema.Null])),
172
+ }),
173
+ Schema.Null,
174
+ ]),
175
+ ),
176
+ response: Schema.optional(
177
+ Schema.Union([
178
+ Schema.Struct({
179
+ originTraffic: Schema.optional(
180
+ Schema.Union([Schema.Boolean, Schema.Null]),
181
+ ),
182
+ }).pipe(Schema.encodeKeys({ originTraffic: "origin_traffic" })),
183
+ Schema.Null,
184
+ ]),
185
+ ),
186
+ }),
187
+ Schema.Null,
188
+ ]),
189
+ ),
190
+ period: Schema.optional(Schema.Union([Schema.Number, Schema.Null])),
191
+ threshold: Schema.optional(Schema.Union([Schema.Number, Schema.Null])),
192
+ }).pipe(
193
+ T.ResponsePath("result"),
194
+ ) as unknown as Schema.Schema<GetRateLimitResponse>;
195
+
196
+ export type GetRateLimitError = DefaultErrors;
197
+
198
+ export const getRateLimit: API.OperationMethod<
199
+ GetRateLimitRequest,
200
+ GetRateLimitResponse,
201
+ GetRateLimitError,
202
+ Credentials | HttpClient.HttpClient
203
+ > = /*@__PURE__*/ /*#__PURE__*/ API.make(() => ({
204
+ input: GetRateLimitRequest,
205
+ output: GetRateLimitResponse,
206
+ errors: [],
207
+ }));
208
+
209
+ export interface ListRateLimitsRequest {
210
+ /** Path param: Defines an identifier. */
211
+ zoneId: string;
212
+ }
213
+
214
+ export const ListRateLimitsRequest = /*@__PURE__*/ /*#__PURE__*/ Schema.Struct({
215
+ zoneId: Schema.String.pipe(T.HttpPath("zone_id")),
216
+ }).pipe(
217
+ T.Http({ method: "GET", path: "/zones/{zone_id}/rate_limits" }),
218
+ ) as unknown as Schema.Schema<ListRateLimitsRequest>;
219
+
220
+ export interface ListRateLimitsResponse {
221
+ result: {
222
+ id?: string | null;
223
+ action?: {
224
+ mode?:
225
+ | "simulate"
226
+ | "ban"
227
+ | "challenge"
228
+ | "js_challenge"
229
+ | "managed_challenge"
230
+ | null;
231
+ response?: { body?: string | null; contentType?: string | null } | null;
232
+ timeout?: number | null;
233
+ } | null;
234
+ bypass?: { name?: "url" | null; value?: string | null }[] | null;
235
+ description?: string | null;
236
+ disabled?: boolean | null;
237
+ match?: {
238
+ headers?:
239
+ | {
240
+ name?: string | null;
241
+ op?: "eq" | "ne" | null;
242
+ value?: string | null;
243
+ }[]
244
+ | null;
245
+ request?: {
246
+ methods?:
247
+ | ("GET" | "POST" | "PUT" | "DELETE" | "PATCH" | "HEAD" | "_ALL_")[]
248
+ | null;
249
+ schemes?: string[] | null;
250
+ url?: string | null;
251
+ } | null;
252
+ response?: { originTraffic?: boolean | null } | null;
253
+ } | null;
254
+ period?: number | null;
255
+ threshold?: number | null;
256
+ }[];
257
+ resultInfo: {
258
+ count?: number | null;
259
+ page?: number | null;
260
+ perPage?: number | null;
261
+ totalCount?: number | null;
262
+ };
263
+ }
264
+
265
+ export const ListRateLimitsResponse = /*@__PURE__*/ /*#__PURE__*/ Schema.Struct(
266
+ {
267
+ result: Schema.Array(
268
+ Schema.Struct({
269
+ id: Schema.optional(Schema.Union([Schema.String, Schema.Null])),
270
+ action: Schema.optional(
271
+ Schema.Union([
272
+ Schema.Struct({
273
+ mode: Schema.optional(
274
+ Schema.Union([
275
+ Schema.Literals([
276
+ "simulate",
277
+ "ban",
278
+ "challenge",
279
+ "js_challenge",
280
+ "managed_challenge",
281
+ ]),
282
+ Schema.Null,
283
+ ]),
284
+ ),
285
+ response: Schema.optional(
286
+ Schema.Union([
287
+ Schema.Struct({
288
+ body: Schema.optional(
289
+ Schema.Union([Schema.String, Schema.Null]),
290
+ ),
291
+ contentType: Schema.optional(
292
+ Schema.Union([Schema.String, Schema.Null]),
293
+ ),
294
+ }).pipe(
295
+ Schema.encodeKeys({
296
+ body: "body",
297
+ contentType: "content_type",
298
+ }),
299
+ ),
300
+ Schema.Null,
301
+ ]),
302
+ ),
303
+ timeout: Schema.optional(
304
+ Schema.Union([Schema.Number, Schema.Null]),
305
+ ),
306
+ }),
307
+ Schema.Null,
308
+ ]),
309
+ ),
310
+ bypass: Schema.optional(
311
+ Schema.Union([
312
+ Schema.Array(
313
+ Schema.Struct({
314
+ name: Schema.optional(
315
+ Schema.Union([Schema.Literal("url"), Schema.Null]),
316
+ ),
317
+ value: Schema.optional(
318
+ Schema.Union([Schema.String, Schema.Null]),
319
+ ),
320
+ }),
321
+ ),
322
+ Schema.Null,
323
+ ]),
324
+ ),
325
+ description: Schema.optional(
326
+ Schema.Union([Schema.String, Schema.Null]),
327
+ ),
328
+ disabled: Schema.optional(Schema.Union([Schema.Boolean, Schema.Null])),
329
+ match: Schema.optional(
330
+ Schema.Union([
331
+ Schema.Struct({
332
+ headers: Schema.optional(
333
+ Schema.Union([
334
+ Schema.Array(
335
+ Schema.Struct({
336
+ name: Schema.optional(
337
+ Schema.Union([Schema.String, Schema.Null]),
338
+ ),
339
+ op: Schema.optional(
340
+ Schema.Union([
341
+ Schema.Literals(["eq", "ne"]),
342
+ Schema.Null,
343
+ ]),
344
+ ),
345
+ value: Schema.optional(
346
+ Schema.Union([Schema.String, Schema.Null]),
347
+ ),
348
+ }),
349
+ ),
350
+ Schema.Null,
351
+ ]),
352
+ ),
353
+ request: Schema.optional(
354
+ Schema.Union([
355
+ Schema.Struct({
356
+ methods: Schema.optional(
357
+ Schema.Union([
358
+ Schema.Array(
359
+ Schema.Literals([
360
+ "GET",
361
+ "POST",
362
+ "PUT",
363
+ "DELETE",
364
+ "PATCH",
365
+ "HEAD",
366
+ "_ALL_",
367
+ ]),
368
+ ),
369
+ Schema.Null,
370
+ ]),
371
+ ),
372
+ schemes: Schema.optional(
373
+ Schema.Union([Schema.Array(Schema.String), Schema.Null]),
374
+ ),
375
+ url: Schema.optional(
376
+ Schema.Union([Schema.String, Schema.Null]),
377
+ ),
378
+ }),
379
+ Schema.Null,
380
+ ]),
381
+ ),
382
+ response: Schema.optional(
383
+ Schema.Union([
384
+ Schema.Struct({
385
+ originTraffic: Schema.optional(
386
+ Schema.Union([Schema.Boolean, Schema.Null]),
387
+ ),
388
+ }).pipe(
389
+ Schema.encodeKeys({ originTraffic: "origin_traffic" }),
390
+ ),
391
+ Schema.Null,
392
+ ]),
393
+ ),
394
+ }),
395
+ Schema.Null,
396
+ ]),
397
+ ),
398
+ period: Schema.optional(Schema.Union([Schema.Number, Schema.Null])),
399
+ threshold: Schema.optional(Schema.Union([Schema.Number, Schema.Null])),
400
+ }),
401
+ ),
402
+ resultInfo: Schema.Struct({
403
+ count: Schema.optional(Schema.Union([Schema.Number, Schema.Null])),
404
+ page: Schema.optional(Schema.Union([Schema.Number, Schema.Null])),
405
+ perPage: Schema.optional(Schema.Union([Schema.Number, Schema.Null])),
406
+ totalCount: Schema.optional(Schema.Union([Schema.Number, Schema.Null])),
407
+ }).pipe(
408
+ Schema.encodeKeys({
409
+ count: "count",
410
+ page: "page",
411
+ perPage: "per_page",
412
+ totalCount: "total_count",
413
+ }),
414
+ ),
415
+ },
416
+ ).pipe(
417
+ Schema.encodeKeys({ result: "result", resultInfo: "result_info" }),
418
+ ) as unknown as Schema.Schema<ListRateLimitsResponse>;
419
+
420
+ export type ListRateLimitsError = DefaultErrors;
421
+
422
+ export const listRateLimits: API.PaginatedOperationMethod<
423
+ ListRateLimitsRequest,
424
+ ListRateLimitsResponse,
425
+ ListRateLimitsError,
426
+ Credentials | HttpClient.HttpClient
427
+ > & {
428
+ pages: (
429
+ input: ListRateLimitsRequest,
430
+ ) => stream.Stream<
431
+ ListRateLimitsResponse,
432
+ ListRateLimitsError,
433
+ Credentials | HttpClient.HttpClient
434
+ >;
435
+ items: (input: ListRateLimitsRequest) => stream.Stream<
436
+ {
437
+ id?: string | null;
438
+ action?: {
439
+ mode?:
440
+ | "simulate"
441
+ | "ban"
442
+ | "challenge"
443
+ | "js_challenge"
444
+ | "managed_challenge"
445
+ | null;
446
+ response?: { body?: string | null; contentType?: string | null } | null;
447
+ timeout?: number | null;
448
+ } | null;
449
+ bypass?: { name?: "url" | null; value?: string | null }[] | null;
450
+ description?: string | null;
451
+ disabled?: boolean | null;
452
+ match?: {
453
+ headers?:
454
+ | {
455
+ name?: string | null;
456
+ op?: "eq" | "ne" | null;
457
+ value?: string | null;
458
+ }[]
459
+ | null;
460
+ request?: {
461
+ methods?:
462
+ | ("GET" | "POST" | "PUT" | "DELETE" | "PATCH" | "HEAD" | "_ALL_")[]
463
+ | null;
464
+ schemes?: string[] | null;
465
+ url?: string | null;
466
+ } | null;
467
+ response?: { originTraffic?: boolean | null } | null;
468
+ } | null;
469
+ period?: number | null;
470
+ threshold?: number | null;
471
+ },
472
+ ListRateLimitsError,
473
+ Credentials | HttpClient.HttpClient
474
+ >;
475
+ } = /*@__PURE__*/ /*#__PURE__*/ API.makePaginated(() => ({
476
+ input: ListRateLimitsRequest,
477
+ output: ListRateLimitsResponse,
478
+ errors: [],
479
+ pagination: {
480
+ mode: "page",
481
+ inputToken: "page",
482
+ outputToken: "resultInfo.page",
483
+ items: "result",
484
+ pageSize: "perPage",
485
+ } as const,
486
+ }));
487
+
488
+ export interface CreateRateLimitRequest {
489
+ /** Path param: Defines an identifier. */
490
+ zoneId: string;
491
+ /** Body param: The action to perform when the threshold of matched traffic within the configured period is exceeded. */
492
+ action: {
493
+ mode?:
494
+ | "simulate"
495
+ | "ban"
496
+ | "challenge"
497
+ | "js_challenge"
498
+ | "managed_challenge";
499
+ response?: { body?: string; contentType?: string };
500
+ timeout?: number;
501
+ };
502
+ /** Body param: Determines which traffic the rate limit counts towards the threshold. */
503
+ match: {
504
+ headers?: { name?: string; op?: "eq" | "ne"; value?: string }[];
505
+ request?: {
506
+ methods?: (
507
+ | "GET"
508
+ | "POST"
509
+ | "PUT"
510
+ | "DELETE"
511
+ | "PATCH"
512
+ | "HEAD"
513
+ | "_ALL_"
514
+ )[];
515
+ schemes?: string[];
516
+ url?: string;
517
+ };
518
+ response?: { originTraffic?: boolean };
519
+ };
520
+ /** Body param: The time in seconds (an integer value) to count matching traffic. If the count exceeds the configured threshold within this period, Cloudflare will perform the configured action. */
521
+ period: number;
522
+ /** Body param: The threshold that will trigger the configured mitigation action. Configure this value along with the `period` property to establish a threshold per period. */
523
+ threshold: number;
524
+ }
525
+
526
+ export const CreateRateLimitRequest = /*@__PURE__*/ /*#__PURE__*/ Schema.Struct(
527
+ {
528
+ zoneId: Schema.String.pipe(T.HttpPath("zone_id")),
529
+ action: Schema.Struct({
530
+ mode: Schema.optional(
531
+ Schema.Literals([
532
+ "simulate",
533
+ "ban",
534
+ "challenge",
535
+ "js_challenge",
536
+ "managed_challenge",
537
+ ]),
538
+ ),
539
+ response: Schema.optional(
540
+ Schema.Struct({
541
+ body: Schema.optional(Schema.String),
542
+ contentType: Schema.optional(Schema.String),
543
+ }).pipe(
544
+ Schema.encodeKeys({ body: "body", contentType: "content_type" }),
545
+ ),
546
+ ),
547
+ timeout: Schema.optional(Schema.Number),
548
+ }),
549
+ match: Schema.Struct({
550
+ headers: Schema.optional(
551
+ Schema.Array(
552
+ Schema.Struct({
553
+ name: Schema.optional(Schema.String),
554
+ op: Schema.optional(Schema.Literals(["eq", "ne"])),
555
+ value: Schema.optional(Schema.String),
556
+ }),
557
+ ),
558
+ ),
559
+ request: Schema.optional(
560
+ Schema.Struct({
561
+ methods: Schema.optional(
562
+ Schema.Array(
563
+ Schema.Literals([
564
+ "GET",
565
+ "POST",
566
+ "PUT",
567
+ "DELETE",
568
+ "PATCH",
569
+ "HEAD",
570
+ "_ALL_",
571
+ ]),
572
+ ),
573
+ ),
574
+ schemes: Schema.optional(Schema.Array(Schema.String)),
575
+ url: Schema.optional(Schema.String),
576
+ }),
577
+ ),
578
+ response: Schema.optional(
579
+ Schema.Struct({
580
+ originTraffic: Schema.optional(Schema.Boolean),
581
+ }).pipe(Schema.encodeKeys({ originTraffic: "origin_traffic" })),
582
+ ),
583
+ }),
584
+ period: Schema.Number,
585
+ threshold: Schema.Number,
586
+ },
587
+ ).pipe(
588
+ T.Http({ method: "POST", path: "/zones/{zone_id}/rate_limits" }),
589
+ ) as unknown as Schema.Schema<CreateRateLimitRequest>;
590
+
591
+ export interface CreateRateLimitResponse {
592
+ /** The unique identifier of the rate limit. */
593
+ id?: string | null;
594
+ /** The action to perform when the threshold of matched traffic within the configured period is exceeded. */
595
+ action?: {
596
+ mode?:
597
+ | "simulate"
598
+ | "ban"
599
+ | "challenge"
600
+ | "js_challenge"
601
+ | "managed_challenge"
602
+ | null;
603
+ response?: { body?: string | null; contentType?: string | null } | null;
604
+ timeout?: number | null;
605
+ } | null;
606
+ /** Criteria specifying when the current rate limit should be bypassed. You can specify that the rate limit should not apply to one or more URLs. */
607
+ bypass?: { name?: "url" | null; value?: string | null }[] | null;
608
+ /** An informative summary of the rule. This value is sanitized and any tags will be removed. */
609
+ description?: string | null;
610
+ /** When true, indicates that the rate limit is currently disabled. */
611
+ disabled?: boolean | null;
612
+ /** Determines which traffic the rate limit counts towards the threshold. */
613
+ match?: {
614
+ headers?:
615
+ | {
616
+ name?: string | null;
617
+ op?: "eq" | "ne" | null;
618
+ value?: string | null;
619
+ }[]
620
+ | null;
621
+ request?: {
622
+ methods?:
623
+ | ("GET" | "POST" | "PUT" | "DELETE" | "PATCH" | "HEAD" | "_ALL_")[]
624
+ | null;
625
+ schemes?: string[] | null;
626
+ url?: string | null;
627
+ } | null;
628
+ response?: { originTraffic?: boolean | null } | null;
629
+ } | null;
630
+ /** The time in seconds (an integer value) to count matching traffic. If the count exceeds the configured threshold within this period, Cloudflare will perform the configured action. */
631
+ period?: number | null;
632
+ /** The threshold that will trigger the configured mitigation action. Configure this value along with the `period` property to establish a threshold per period. */
633
+ threshold?: number | null;
634
+ }
635
+
636
+ export const CreateRateLimitResponse =
637
+ /*@__PURE__*/ /*#__PURE__*/ Schema.Struct({
638
+ id: Schema.optional(Schema.Union([Schema.String, Schema.Null])),
639
+ action: Schema.optional(
640
+ Schema.Union([
641
+ Schema.Struct({
642
+ mode: Schema.optional(
643
+ Schema.Union([
644
+ Schema.Literals([
645
+ "simulate",
646
+ "ban",
647
+ "challenge",
648
+ "js_challenge",
649
+ "managed_challenge",
650
+ ]),
651
+ Schema.Null,
652
+ ]),
653
+ ),
654
+ response: Schema.optional(
655
+ Schema.Union([
656
+ Schema.Struct({
657
+ body: Schema.optional(
658
+ Schema.Union([Schema.String, Schema.Null]),
659
+ ),
660
+ contentType: Schema.optional(
661
+ Schema.Union([Schema.String, Schema.Null]),
662
+ ),
663
+ }).pipe(
664
+ Schema.encodeKeys({
665
+ body: "body",
666
+ contentType: "content_type",
667
+ }),
668
+ ),
669
+ Schema.Null,
670
+ ]),
671
+ ),
672
+ timeout: Schema.optional(Schema.Union([Schema.Number, Schema.Null])),
673
+ }),
674
+ Schema.Null,
675
+ ]),
676
+ ),
677
+ bypass: Schema.optional(
678
+ Schema.Union([
679
+ Schema.Array(
680
+ Schema.Struct({
681
+ name: Schema.optional(
682
+ Schema.Union([Schema.Literal("url"), Schema.Null]),
683
+ ),
684
+ value: Schema.optional(Schema.Union([Schema.String, Schema.Null])),
685
+ }),
686
+ ),
687
+ Schema.Null,
688
+ ]),
689
+ ),
690
+ description: Schema.optional(Schema.Union([Schema.String, Schema.Null])),
691
+ disabled: Schema.optional(Schema.Union([Schema.Boolean, Schema.Null])),
692
+ match: Schema.optional(
693
+ Schema.Union([
694
+ Schema.Struct({
695
+ headers: Schema.optional(
696
+ Schema.Union([
697
+ Schema.Array(
698
+ Schema.Struct({
699
+ name: Schema.optional(
700
+ Schema.Union([Schema.String, Schema.Null]),
701
+ ),
702
+ op: Schema.optional(
703
+ Schema.Union([Schema.Literals(["eq", "ne"]), Schema.Null]),
704
+ ),
705
+ value: Schema.optional(
706
+ Schema.Union([Schema.String, Schema.Null]),
707
+ ),
708
+ }),
709
+ ),
710
+ Schema.Null,
711
+ ]),
712
+ ),
713
+ request: Schema.optional(
714
+ Schema.Union([
715
+ Schema.Struct({
716
+ methods: Schema.optional(
717
+ Schema.Union([
718
+ Schema.Array(
719
+ Schema.Literals([
720
+ "GET",
721
+ "POST",
722
+ "PUT",
723
+ "DELETE",
724
+ "PATCH",
725
+ "HEAD",
726
+ "_ALL_",
727
+ ]),
728
+ ),
729
+ Schema.Null,
730
+ ]),
731
+ ),
732
+ schemes: Schema.optional(
733
+ Schema.Union([Schema.Array(Schema.String), Schema.Null]),
734
+ ),
735
+ url: Schema.optional(
736
+ Schema.Union([Schema.String, Schema.Null]),
737
+ ),
738
+ }),
739
+ Schema.Null,
740
+ ]),
741
+ ),
742
+ response: Schema.optional(
743
+ Schema.Union([
744
+ Schema.Struct({
745
+ originTraffic: Schema.optional(
746
+ Schema.Union([Schema.Boolean, Schema.Null]),
747
+ ),
748
+ }).pipe(Schema.encodeKeys({ originTraffic: "origin_traffic" })),
749
+ Schema.Null,
750
+ ]),
751
+ ),
752
+ }),
753
+ Schema.Null,
754
+ ]),
755
+ ),
756
+ period: Schema.optional(Schema.Union([Schema.Number, Schema.Null])),
757
+ threshold: Schema.optional(Schema.Union([Schema.Number, Schema.Null])),
758
+ }).pipe(
759
+ T.ResponsePath("result"),
760
+ ) as unknown as Schema.Schema<CreateRateLimitResponse>;
761
+
762
+ export type CreateRateLimitError = DefaultErrors;
763
+
764
+ export const createRateLimit: API.OperationMethod<
765
+ CreateRateLimitRequest,
766
+ CreateRateLimitResponse,
767
+ CreateRateLimitError,
768
+ Credentials | HttpClient.HttpClient
769
+ > = /*@__PURE__*/ /*#__PURE__*/ API.make(() => ({
770
+ input: CreateRateLimitRequest,
771
+ output: CreateRateLimitResponse,
772
+ errors: [],
773
+ }));
774
+
775
+ export interface DeleteRateLimitRequest {
776
+ rateLimitId: string;
777
+ /** Defines an identifier. */
778
+ zoneId: string;
779
+ }
780
+
781
+ export const DeleteRateLimitRequest = /*@__PURE__*/ /*#__PURE__*/ Schema.Struct(
782
+ {
783
+ rateLimitId: Schema.String.pipe(T.HttpPath("rateLimitId")),
784
+ zoneId: Schema.String.pipe(T.HttpPath("zone_id")),
785
+ },
786
+ ).pipe(
787
+ T.Http({
788
+ method: "DELETE",
789
+ path: "/zones/{zone_id}/rate_limits/{rateLimitId}",
790
+ }),
791
+ ) as unknown as Schema.Schema<DeleteRateLimitRequest>;
792
+
793
+ export interface DeleteRateLimitResponse {
794
+ /** The unique identifier of the rate limit. */
795
+ id?: string | null;
796
+ /** The action to perform when the threshold of matched traffic within the configured period is exceeded. */
797
+ action?: {
798
+ mode?:
799
+ | "simulate"
800
+ | "ban"
801
+ | "challenge"
802
+ | "js_challenge"
803
+ | "managed_challenge"
804
+ | null;
805
+ response?: { body?: string | null; contentType?: string | null } | null;
806
+ timeout?: number | null;
807
+ } | null;
808
+ /** Criteria specifying when the current rate limit should be bypassed. You can specify that the rate limit should not apply to one or more URLs. */
809
+ bypass?: { name?: "url" | null; value?: string | null }[] | null;
810
+ /** An informative summary of the rule. This value is sanitized and any tags will be removed. */
811
+ description?: string | null;
812
+ /** When true, indicates that the rate limit is currently disabled. */
813
+ disabled?: boolean | null;
814
+ /** Determines which traffic the rate limit counts towards the threshold. */
815
+ match?: {
816
+ headers?:
817
+ | {
818
+ name?: string | null;
819
+ op?: "eq" | "ne" | null;
820
+ value?: string | null;
821
+ }[]
822
+ | null;
823
+ request?: {
824
+ methods?:
825
+ | ("GET" | "POST" | "PUT" | "DELETE" | "PATCH" | "HEAD" | "_ALL_")[]
826
+ | null;
827
+ schemes?: string[] | null;
828
+ url?: string | null;
829
+ } | null;
830
+ response?: { originTraffic?: boolean | null } | null;
831
+ } | null;
832
+ /** The time in seconds (an integer value) to count matching traffic. If the count exceeds the configured threshold within this period, Cloudflare will perform the configured action. */
833
+ period?: number | null;
834
+ /** The threshold that will trigger the configured mitigation action. Configure this value along with the `period` property to establish a threshold per period. */
835
+ threshold?: number | null;
836
+ }
837
+
838
+ export const DeleteRateLimitResponse =
839
+ /*@__PURE__*/ /*#__PURE__*/ Schema.Struct({
840
+ id: Schema.optional(Schema.Union([Schema.String, Schema.Null])),
841
+ action: Schema.optional(
842
+ Schema.Union([
843
+ Schema.Struct({
844
+ mode: Schema.optional(
845
+ Schema.Union([
846
+ Schema.Literals([
847
+ "simulate",
848
+ "ban",
849
+ "challenge",
850
+ "js_challenge",
851
+ "managed_challenge",
852
+ ]),
853
+ Schema.Null,
854
+ ]),
855
+ ),
856
+ response: Schema.optional(
857
+ Schema.Union([
858
+ Schema.Struct({
859
+ body: Schema.optional(
860
+ Schema.Union([Schema.String, Schema.Null]),
861
+ ),
862
+ contentType: Schema.optional(
863
+ Schema.Union([Schema.String, Schema.Null]),
864
+ ),
865
+ }).pipe(
866
+ Schema.encodeKeys({
867
+ body: "body",
868
+ contentType: "content_type",
869
+ }),
870
+ ),
871
+ Schema.Null,
872
+ ]),
873
+ ),
874
+ timeout: Schema.optional(Schema.Union([Schema.Number, Schema.Null])),
875
+ }),
876
+ Schema.Null,
877
+ ]),
878
+ ),
879
+ bypass: Schema.optional(
880
+ Schema.Union([
881
+ Schema.Array(
882
+ Schema.Struct({
883
+ name: Schema.optional(
884
+ Schema.Union([Schema.Literal("url"), Schema.Null]),
885
+ ),
886
+ value: Schema.optional(Schema.Union([Schema.String, Schema.Null])),
887
+ }),
888
+ ),
889
+ Schema.Null,
890
+ ]),
891
+ ),
892
+ description: Schema.optional(Schema.Union([Schema.String, Schema.Null])),
893
+ disabled: Schema.optional(Schema.Union([Schema.Boolean, Schema.Null])),
894
+ match: Schema.optional(
895
+ Schema.Union([
896
+ Schema.Struct({
897
+ headers: Schema.optional(
898
+ Schema.Union([
899
+ Schema.Array(
900
+ Schema.Struct({
901
+ name: Schema.optional(
902
+ Schema.Union([Schema.String, Schema.Null]),
903
+ ),
904
+ op: Schema.optional(
905
+ Schema.Union([Schema.Literals(["eq", "ne"]), Schema.Null]),
906
+ ),
907
+ value: Schema.optional(
908
+ Schema.Union([Schema.String, Schema.Null]),
909
+ ),
910
+ }),
911
+ ),
912
+ Schema.Null,
913
+ ]),
914
+ ),
915
+ request: Schema.optional(
916
+ Schema.Union([
917
+ Schema.Struct({
918
+ methods: Schema.optional(
919
+ Schema.Union([
920
+ Schema.Array(
921
+ Schema.Literals([
922
+ "GET",
923
+ "POST",
924
+ "PUT",
925
+ "DELETE",
926
+ "PATCH",
927
+ "HEAD",
928
+ "_ALL_",
929
+ ]),
930
+ ),
931
+ Schema.Null,
932
+ ]),
933
+ ),
934
+ schemes: Schema.optional(
935
+ Schema.Union([Schema.Array(Schema.String), Schema.Null]),
936
+ ),
937
+ url: Schema.optional(
938
+ Schema.Union([Schema.String, Schema.Null]),
939
+ ),
940
+ }),
941
+ Schema.Null,
942
+ ]),
943
+ ),
944
+ response: Schema.optional(
945
+ Schema.Union([
946
+ Schema.Struct({
947
+ originTraffic: Schema.optional(
948
+ Schema.Union([Schema.Boolean, Schema.Null]),
949
+ ),
950
+ }).pipe(Schema.encodeKeys({ originTraffic: "origin_traffic" })),
951
+ Schema.Null,
952
+ ]),
953
+ ),
954
+ }),
955
+ Schema.Null,
956
+ ]),
957
+ ),
958
+ period: Schema.optional(Schema.Union([Schema.Number, Schema.Null])),
959
+ threshold: Schema.optional(Schema.Union([Schema.Number, Schema.Null])),
960
+ }).pipe(
961
+ T.ResponsePath("result"),
962
+ ) as unknown as Schema.Schema<DeleteRateLimitResponse>;
963
+
964
+ export type DeleteRateLimitError = DefaultErrors;
965
+
966
+ export const deleteRateLimit: API.OperationMethod<
967
+ DeleteRateLimitRequest,
968
+ DeleteRateLimitResponse,
969
+ DeleteRateLimitError,
970
+ Credentials | HttpClient.HttpClient
971
+ > = /*@__PURE__*/ /*#__PURE__*/ API.make(() => ({
972
+ input: DeleteRateLimitRequest,
973
+ output: DeleteRateLimitResponse,
974
+ errors: [],
975
+ }));
976
+
977
+ export interface EditRateLimitRequest {
978
+ rateLimitId: string;
979
+ /** Path param: Defines an identifier. */
980
+ zoneId: string;
981
+ /** Body param: The action to perform when the threshold of matched traffic within the configured period is exceeded. */
982
+ action: {
983
+ mode?:
984
+ | "simulate"
985
+ | "ban"
986
+ | "challenge"
987
+ | "js_challenge"
988
+ | "managed_challenge";
989
+ response?: { body?: string; contentType?: string };
990
+ timeout?: number;
991
+ };
992
+ /** Body param: Determines which traffic the rate limit counts towards the threshold. */
993
+ match: {
994
+ headers?: { name?: string; op?: "eq" | "ne"; value?: string }[];
995
+ request?: {
996
+ methods?: (
997
+ | "GET"
998
+ | "POST"
999
+ | "PUT"
1000
+ | "DELETE"
1001
+ | "PATCH"
1002
+ | "HEAD"
1003
+ | "_ALL_"
1004
+ )[];
1005
+ schemes?: string[];
1006
+ url?: string;
1007
+ };
1008
+ response?: { originTraffic?: boolean };
1009
+ };
1010
+ /** Body param: The time in seconds (an integer value) to count matching traffic. If the count exceeds the configured threshold within this period, Cloudflare will perform the configured action. */
1011
+ period: number;
1012
+ /** Body param: The threshold that will trigger the configured mitigation action. Configure this value along with the `period` property to establish a threshold per period. */
1013
+ threshold: number;
1014
+ }
1015
+
1016
+ export const EditRateLimitRequest = /*@__PURE__*/ /*#__PURE__*/ Schema.Struct({
1017
+ rateLimitId: Schema.String.pipe(T.HttpPath("rateLimitId")),
1018
+ zoneId: Schema.String.pipe(T.HttpPath("zone_id")),
1019
+ action: Schema.Struct({
1020
+ mode: Schema.optional(
1021
+ Schema.Literals([
1022
+ "simulate",
1023
+ "ban",
1024
+ "challenge",
1025
+ "js_challenge",
1026
+ "managed_challenge",
1027
+ ]),
1028
+ ),
1029
+ response: Schema.optional(
1030
+ Schema.Struct({
1031
+ body: Schema.optional(Schema.String),
1032
+ contentType: Schema.optional(Schema.String),
1033
+ }).pipe(Schema.encodeKeys({ body: "body", contentType: "content_type" })),
1034
+ ),
1035
+ timeout: Schema.optional(Schema.Number),
1036
+ }),
1037
+ match: Schema.Struct({
1038
+ headers: Schema.optional(
1039
+ Schema.Array(
1040
+ Schema.Struct({
1041
+ name: Schema.optional(Schema.String),
1042
+ op: Schema.optional(Schema.Literals(["eq", "ne"])),
1043
+ value: Schema.optional(Schema.String),
1044
+ }),
1045
+ ),
1046
+ ),
1047
+ request: Schema.optional(
1048
+ Schema.Struct({
1049
+ methods: Schema.optional(
1050
+ Schema.Array(
1051
+ Schema.Literals([
1052
+ "GET",
1053
+ "POST",
1054
+ "PUT",
1055
+ "DELETE",
1056
+ "PATCH",
1057
+ "HEAD",
1058
+ "_ALL_",
1059
+ ]),
1060
+ ),
1061
+ ),
1062
+ schemes: Schema.optional(Schema.Array(Schema.String)),
1063
+ url: Schema.optional(Schema.String),
1064
+ }),
1065
+ ),
1066
+ response: Schema.optional(
1067
+ Schema.Struct({
1068
+ originTraffic: Schema.optional(Schema.Boolean),
1069
+ }).pipe(Schema.encodeKeys({ originTraffic: "origin_traffic" })),
1070
+ ),
1071
+ }),
1072
+ period: Schema.Number,
1073
+ threshold: Schema.Number,
1074
+ }).pipe(
1075
+ T.Http({ method: "PUT", path: "/zones/{zone_id}/rate_limits/{rateLimitId}" }),
1076
+ ) as unknown as Schema.Schema<EditRateLimitRequest>;
1077
+
1078
+ export interface EditRateLimitResponse {
1079
+ /** The unique identifier of the rate limit. */
1080
+ id?: string | null;
1081
+ /** The action to perform when the threshold of matched traffic within the configured period is exceeded. */
1082
+ action?: {
1083
+ mode?:
1084
+ | "simulate"
1085
+ | "ban"
1086
+ | "challenge"
1087
+ | "js_challenge"
1088
+ | "managed_challenge"
1089
+ | null;
1090
+ response?: { body?: string | null; contentType?: string | null } | null;
1091
+ timeout?: number | null;
1092
+ } | null;
1093
+ /** Criteria specifying when the current rate limit should be bypassed. You can specify that the rate limit should not apply to one or more URLs. */
1094
+ bypass?: { name?: "url" | null; value?: string | null }[] | null;
1095
+ /** An informative summary of the rule. This value is sanitized and any tags will be removed. */
1096
+ description?: string | null;
1097
+ /** When true, indicates that the rate limit is currently disabled. */
1098
+ disabled?: boolean | null;
1099
+ /** Determines which traffic the rate limit counts towards the threshold. */
1100
+ match?: {
1101
+ headers?:
1102
+ | {
1103
+ name?: string | null;
1104
+ op?: "eq" | "ne" | null;
1105
+ value?: string | null;
1106
+ }[]
1107
+ | null;
1108
+ request?: {
1109
+ methods?:
1110
+ | ("GET" | "POST" | "PUT" | "DELETE" | "PATCH" | "HEAD" | "_ALL_")[]
1111
+ | null;
1112
+ schemes?: string[] | null;
1113
+ url?: string | null;
1114
+ } | null;
1115
+ response?: { originTraffic?: boolean | null } | null;
1116
+ } | null;
1117
+ /** The time in seconds (an integer value) to count matching traffic. If the count exceeds the configured threshold within this period, Cloudflare will perform the configured action. */
1118
+ period?: number | null;
1119
+ /** The threshold that will trigger the configured mitigation action. Configure this value along with the `period` property to establish a threshold per period. */
1120
+ threshold?: number | null;
1121
+ }
1122
+
1123
+ export const EditRateLimitResponse = /*@__PURE__*/ /*#__PURE__*/ Schema.Struct({
1124
+ id: Schema.optional(Schema.Union([Schema.String, Schema.Null])),
1125
+ action: Schema.optional(
1126
+ Schema.Union([
1127
+ Schema.Struct({
1128
+ mode: Schema.optional(
1129
+ Schema.Union([
1130
+ Schema.Literals([
1131
+ "simulate",
1132
+ "ban",
1133
+ "challenge",
1134
+ "js_challenge",
1135
+ "managed_challenge",
1136
+ ]),
1137
+ Schema.Null,
1138
+ ]),
1139
+ ),
1140
+ response: Schema.optional(
1141
+ Schema.Union([
1142
+ Schema.Struct({
1143
+ body: Schema.optional(Schema.Union([Schema.String, Schema.Null])),
1144
+ contentType: Schema.optional(
1145
+ Schema.Union([Schema.String, Schema.Null]),
1146
+ ),
1147
+ }).pipe(
1148
+ Schema.encodeKeys({ body: "body", contentType: "content_type" }),
1149
+ ),
1150
+ Schema.Null,
1151
+ ]),
1152
+ ),
1153
+ timeout: Schema.optional(Schema.Union([Schema.Number, Schema.Null])),
1154
+ }),
1155
+ Schema.Null,
1156
+ ]),
1157
+ ),
1158
+ bypass: Schema.optional(
1159
+ Schema.Union([
1160
+ Schema.Array(
1161
+ Schema.Struct({
1162
+ name: Schema.optional(
1163
+ Schema.Union([Schema.Literal("url"), Schema.Null]),
1164
+ ),
1165
+ value: Schema.optional(Schema.Union([Schema.String, Schema.Null])),
1166
+ }),
1167
+ ),
1168
+ Schema.Null,
1169
+ ]),
1170
+ ),
1171
+ description: Schema.optional(Schema.Union([Schema.String, Schema.Null])),
1172
+ disabled: Schema.optional(Schema.Union([Schema.Boolean, Schema.Null])),
1173
+ match: Schema.optional(
1174
+ Schema.Union([
1175
+ Schema.Struct({
1176
+ headers: Schema.optional(
1177
+ Schema.Union([
1178
+ Schema.Array(
1179
+ Schema.Struct({
1180
+ name: Schema.optional(
1181
+ Schema.Union([Schema.String, Schema.Null]),
1182
+ ),
1183
+ op: Schema.optional(
1184
+ Schema.Union([Schema.Literals(["eq", "ne"]), Schema.Null]),
1185
+ ),
1186
+ value: Schema.optional(
1187
+ Schema.Union([Schema.String, Schema.Null]),
1188
+ ),
1189
+ }),
1190
+ ),
1191
+ Schema.Null,
1192
+ ]),
1193
+ ),
1194
+ request: Schema.optional(
1195
+ Schema.Union([
1196
+ Schema.Struct({
1197
+ methods: Schema.optional(
1198
+ Schema.Union([
1199
+ Schema.Array(
1200
+ Schema.Literals([
1201
+ "GET",
1202
+ "POST",
1203
+ "PUT",
1204
+ "DELETE",
1205
+ "PATCH",
1206
+ "HEAD",
1207
+ "_ALL_",
1208
+ ]),
1209
+ ),
1210
+ Schema.Null,
1211
+ ]),
1212
+ ),
1213
+ schemes: Schema.optional(
1214
+ Schema.Union([Schema.Array(Schema.String), Schema.Null]),
1215
+ ),
1216
+ url: Schema.optional(Schema.Union([Schema.String, Schema.Null])),
1217
+ }),
1218
+ Schema.Null,
1219
+ ]),
1220
+ ),
1221
+ response: Schema.optional(
1222
+ Schema.Union([
1223
+ Schema.Struct({
1224
+ originTraffic: Schema.optional(
1225
+ Schema.Union([Schema.Boolean, Schema.Null]),
1226
+ ),
1227
+ }).pipe(Schema.encodeKeys({ originTraffic: "origin_traffic" })),
1228
+ Schema.Null,
1229
+ ]),
1230
+ ),
1231
+ }),
1232
+ Schema.Null,
1233
+ ]),
1234
+ ),
1235
+ period: Schema.optional(Schema.Union([Schema.Number, Schema.Null])),
1236
+ threshold: Schema.optional(Schema.Union([Schema.Number, Schema.Null])),
1237
+ }).pipe(
1238
+ T.ResponsePath("result"),
1239
+ ) as unknown as Schema.Schema<EditRateLimitResponse>;
1240
+
1241
+ export type EditRateLimitError = DefaultErrors;
1242
+
1243
+ export const editRateLimit: API.OperationMethod<
1244
+ EditRateLimitRequest,
1245
+ EditRateLimitResponse,
1246
+ EditRateLimitError,
1247
+ Credentials | HttpClient.HttpClient
1248
+ > = /*@__PURE__*/ /*#__PURE__*/ API.make(() => ({
1249
+ input: EditRateLimitRequest,
1250
+ output: EditRateLimitResponse,
1251
+ errors: [],
1252
+ }));