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