@backblaze-labs/b2-sdk 0.2.0 → 0.3.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (460) hide show
  1. package/CHANGELOG.md +42 -1
  2. package/README.md +20 -2
  3. package/dist/_virtual/_b2-sdk-version-json.cjs +1 -1
  4. package/dist/_virtual/_b2-sdk-version-json.js +1 -1
  5. package/dist/auth/file.cjs.map +1 -1
  6. package/dist/backup/client.cjs +206 -0
  7. package/dist/backup/client.cjs.map +1 -0
  8. package/dist/backup/client.d.cts +238 -0
  9. package/dist/backup/client.d.cts.map +1 -0
  10. package/dist/backup/client.d.ts +238 -0
  11. package/dist/backup/client.d.ts.map +1 -0
  12. package/dist/backup/client.js +206 -0
  13. package/dist/backup/client.js.map +1 -0
  14. package/dist/backup/index.cjs +15 -0
  15. package/dist/backup/index.d.cts +22 -0
  16. package/dist/backup/index.d.cts.map +1 -0
  17. package/dist/backup/index.d.ts +22 -0
  18. package/dist/backup/index.d.ts.map +1 -0
  19. package/dist/backup/index.js +7 -0
  20. package/dist/backup/raw.cjs +146 -0
  21. package/dist/backup/raw.cjs.map +1 -0
  22. package/dist/backup/raw.d.cts +122 -0
  23. package/dist/backup/raw.d.cts.map +1 -0
  24. package/dist/backup/raw.d.ts +122 -0
  25. package/dist/backup/raw.d.ts.map +1 -0
  26. package/dist/backup/raw.js +146 -0
  27. package/dist/backup/raw.js.map +1 -0
  28. package/dist/bucket.cjs +2 -1
  29. package/dist/bucket.cjs.map +1 -1
  30. package/dist/bucket.js +2 -1
  31. package/dist/bucket.js.map +1 -1
  32. package/dist/copy/large.cjs +5 -3
  33. package/dist/copy/large.cjs.map +1 -1
  34. package/dist/copy/large.d.cts.map +1 -1
  35. package/dist/copy/large.d.ts.map +1 -1
  36. package/dist/copy/large.js +5 -3
  37. package/dist/copy/large.js.map +1 -1
  38. package/dist/download/checksum.cjs +6 -2
  39. package/dist/download/checksum.cjs.map +1 -1
  40. package/dist/download/checksum.js +6 -2
  41. package/dist/download/checksum.js.map +1 -1
  42. package/dist/download/parallel.cjs +52 -15
  43. package/dist/download/parallel.cjs.map +1 -1
  44. package/dist/download/parallel.d.cts +8 -1
  45. package/dist/download/parallel.d.cts.map +1 -1
  46. package/dist/download/parallel.d.ts +8 -1
  47. package/dist/download/parallel.d.ts.map +1 -1
  48. package/dist/download/parallel.js +52 -15
  49. package/dist/download/parallel.js.map +1 -1
  50. package/dist/download/single.cjs +141 -6
  51. package/dist/download/single.cjs.map +1 -1
  52. package/dist/download/single.d.cts.map +1 -1
  53. package/dist/download/single.d.ts.map +1 -1
  54. package/dist/download/single.js +141 -6
  55. package/dist/download/single.js.map +1 -1
  56. package/dist/errors/index.cjs +173 -3
  57. package/dist/errors/index.cjs.map +1 -1
  58. package/dist/errors/index.d.cts +119 -0
  59. package/dist/errors/index.d.cts.map +1 -1
  60. package/dist/errors/index.d.ts +119 -0
  61. package/dist/errors/index.d.ts.map +1 -1
  62. package/dist/errors/index.js +161 -4
  63. package/dist/errors/index.js.map +1 -1
  64. package/dist/http/retry.cjs +1 -1
  65. package/dist/http/retry.cjs.map +1 -1
  66. package/dist/http/retry.js +1 -1
  67. package/dist/http/retry.js.map +1 -1
  68. package/dist/http/transport.cjs +61 -23
  69. package/dist/http/transport.cjs.map +1 -1
  70. package/dist/http/transport.d.cts +25 -3
  71. package/dist/http/transport.d.cts.map +1 -1
  72. package/dist/http/transport.d.ts +25 -3
  73. package/dist/http/transport.d.ts.map +1 -1
  74. package/dist/http/transport.js +59 -22
  75. package/dist/http/transport.js.map +1 -1
  76. package/dist/index.cjs +25 -2
  77. package/dist/index.d.cts +6 -4
  78. package/dist/index.d.cts.map +1 -1
  79. package/dist/index.d.ts +6 -4
  80. package/dist/index.d.ts.map +1 -1
  81. package/dist/index.js +8 -6
  82. package/dist/object.cjs +1 -1
  83. package/dist/object.cjs.map +1 -1
  84. package/dist/object.d.cts +4 -2
  85. package/dist/object.d.cts.map +1 -1
  86. package/dist/object.d.ts +4 -2
  87. package/dist/object.d.ts.map +1 -1
  88. package/dist/object.js +1 -1
  89. package/dist/object.js.map +1 -1
  90. package/dist/partner/account-info.d.cts +43 -0
  91. package/dist/partner/account-info.d.cts.map +1 -0
  92. package/dist/partner/account-info.d.ts +43 -0
  93. package/dist/partner/account-info.d.ts.map +1 -0
  94. package/dist/partner/auth-clone.cjs +64 -0
  95. package/dist/partner/auth-clone.cjs.map +1 -0
  96. package/dist/partner/auth-clone.d.cts +27 -0
  97. package/dist/partner/auth-clone.d.cts.map +1 -0
  98. package/dist/partner/auth-clone.d.ts +27 -0
  99. package/dist/partner/auth-clone.d.ts.map +1 -0
  100. package/dist/partner/auth-clone.js +63 -0
  101. package/dist/partner/auth-clone.js.map +1 -0
  102. package/dist/partner/auth-core.cjs +175 -0
  103. package/dist/partner/auth-core.cjs.map +1 -0
  104. package/dist/partner/auth-core.d.cts +111 -0
  105. package/dist/partner/auth-core.d.cts.map +1 -0
  106. package/dist/partner/auth-core.d.ts +111 -0
  107. package/dist/partner/auth-core.d.ts.map +1 -0
  108. package/dist/partner/auth-core.js +175 -0
  109. package/dist/partner/auth-core.js.map +1 -0
  110. package/dist/partner/auth-shape.cjs +36 -0
  111. package/dist/partner/auth-shape.cjs.map +1 -0
  112. package/dist/partner/auth-shape.d.cts +12 -0
  113. package/dist/partner/auth-shape.d.cts.map +1 -0
  114. package/dist/partner/auth-shape.d.ts +12 -0
  115. package/dist/partner/auth-shape.d.ts.map +1 -0
  116. package/dist/partner/auth-shape.js +36 -0
  117. package/dist/partner/auth-shape.js.map +1 -0
  118. package/dist/partner/client.cjs +255 -0
  119. package/dist/partner/client.cjs.map +1 -0
  120. package/dist/partner/client.d.cts +335 -0
  121. package/dist/partner/client.d.cts.map +1 -0
  122. package/dist/partner/client.d.ts +335 -0
  123. package/dist/partner/client.d.ts.map +1 -0
  124. package/dist/partner/client.js +255 -0
  125. package/dist/partner/client.js.map +1 -0
  126. package/dist/partner/endpoint-url.cjs +108 -0
  127. package/dist/partner/endpoint-url.cjs.map +1 -0
  128. package/dist/partner/endpoint-url.d.cts +72 -0
  129. package/dist/partner/endpoint-url.d.cts.map +1 -0
  130. package/dist/partner/endpoint-url.d.ts +72 -0
  131. package/dist/partner/endpoint-url.d.ts.map +1 -0
  132. package/dist/partner/endpoint-url.js +105 -0
  133. package/dist/partner/endpoint-url.js.map +1 -0
  134. package/dist/partner/in-memory.cjs +135 -0
  135. package/dist/partner/in-memory.cjs.map +1 -0
  136. package/dist/partner/in-memory.d.cts +99 -0
  137. package/dist/partner/in-memory.d.cts.map +1 -0
  138. package/dist/partner/in-memory.d.ts +99 -0
  139. package/dist/partner/in-memory.d.ts.map +1 -0
  140. package/dist/partner/in-memory.js +135 -0
  141. package/dist/partner/in-memory.js.map +1 -0
  142. package/dist/partner/index.cjs +18 -0
  143. package/dist/partner/index.d.cts +23 -0
  144. package/dist/partner/index.d.cts.map +1 -0
  145. package/dist/partner/index.d.ts +23 -0
  146. package/dist/partner/index.d.ts.map +1 -0
  147. package/dist/partner/index.js +7 -0
  148. package/dist/partner/raw.cjs +392 -0
  149. package/dist/partner/raw.cjs.map +1 -0
  150. package/dist/partner/raw.d.cts +223 -0
  151. package/dist/partner/raw.d.cts.map +1 -0
  152. package/dist/partner/raw.d.ts +223 -0
  153. package/dist/partner/raw.d.ts.map +1 -0
  154. package/dist/partner/raw.js +390 -0
  155. package/dist/partner/raw.js.map +1 -0
  156. package/dist/partner/redaction-placeholders.cjs +10 -0
  157. package/dist/partner/redaction-placeholders.cjs.map +1 -0
  158. package/dist/partner/redaction-placeholders.d.cts +5 -0
  159. package/dist/partner/redaction-placeholders.d.cts.map +1 -0
  160. package/dist/partner/redaction-placeholders.d.ts +5 -0
  161. package/dist/partner/redaction-placeholders.d.ts.map +1 -0
  162. package/dist/partner/redaction-placeholders.js +9 -0
  163. package/dist/partner/redaction-placeholders.js.map +1 -0
  164. package/dist/partner/redaction.cjs +267 -0
  165. package/dist/partner/redaction.cjs.map +1 -0
  166. package/dist/partner/redaction.d.cts +124 -0
  167. package/dist/partner/redaction.d.cts.map +1 -0
  168. package/dist/partner/redaction.d.ts +124 -0
  169. package/dist/partner/redaction.d.ts.map +1 -0
  170. package/dist/partner/redaction.js +257 -0
  171. package/dist/partner/redaction.js.map +1 -0
  172. package/dist/raw/index.cjs +81 -19
  173. package/dist/raw/index.cjs.map +1 -1
  174. package/dist/raw/index.d.cts +6 -2
  175. package/dist/raw/index.d.cts.map +1 -1
  176. package/dist/raw/index.d.ts +6 -2
  177. package/dist/raw/index.d.ts.map +1 -1
  178. package/dist/raw/index.js +81 -19
  179. package/dist/raw/index.js.map +1 -1
  180. package/dist/raw/url.cjs +111 -0
  181. package/dist/raw/url.cjs.map +1 -0
  182. package/dist/raw/url.d.cts +41 -0
  183. package/dist/raw/url.d.cts.map +1 -0
  184. package/dist/raw/url.d.ts +41 -0
  185. package/dist/raw/url.d.ts.map +1 -0
  186. package/dist/raw/url.js +110 -0
  187. package/dist/raw/url.js.map +1 -0
  188. package/dist/s3/sigv4.cjs +15 -10
  189. package/dist/s3/sigv4.cjs.map +1 -1
  190. package/dist/s3/sigv4.js +15 -10
  191. package/dist/s3/sigv4.js.map +1 -1
  192. package/dist/simulator/index.cjs +1197 -206
  193. package/dist/simulator/index.cjs.map +1 -1
  194. package/dist/simulator/index.d.cts +109 -11
  195. package/dist/simulator/index.d.cts.map +1 -1
  196. package/dist/simulator/index.d.ts +109 -11
  197. package/dist/simulator/index.d.ts.map +1 -1
  198. package/dist/simulator/index.js +1196 -209
  199. package/dist/simulator/index.js.map +1 -1
  200. package/dist/simulator/partner.cjs +719 -0
  201. package/dist/simulator/partner.cjs.map +1 -0
  202. package/dist/simulator/partner.d.cts +183 -0
  203. package/dist/simulator/partner.d.cts.map +1 -0
  204. package/dist/simulator/partner.d.ts +183 -0
  205. package/dist/simulator/partner.d.ts.map +1 -0
  206. package/dist/simulator/partner.js +718 -0
  207. package/dist/simulator/partner.js.map +1 -0
  208. package/dist/simulator/validation.cjs +577 -0
  209. package/dist/simulator/validation.cjs.map +1 -1
  210. package/dist/simulator/validation.d.cts +117 -0
  211. package/dist/simulator/validation.d.cts.map +1 -1
  212. package/dist/simulator/validation.d.ts +117 -0
  213. package/dist/simulator/validation.d.ts.map +1 -1
  214. package/dist/simulator/validation.js +563 -1
  215. package/dist/simulator/validation.js.map +1 -1
  216. package/dist/streams/file-source.cjs +1 -1
  217. package/dist/streams/file-source.cjs.map +1 -1
  218. package/dist/streams/file-source.js +1 -1
  219. package/dist/streams/file-source.js.map +1 -1
  220. package/dist/streams/index.cjs +1 -1
  221. package/dist/streams/index.js +1 -1
  222. package/dist/streams/source.cjs +2 -1
  223. package/dist/streams/source.cjs.map +1 -1
  224. package/dist/streams/source.js +2 -1
  225. package/dist/streams/source.js.map +1 -1
  226. package/dist/sync/b2-sha1-reader.cjs +6 -2
  227. package/dist/sync/b2-sha1-reader.cjs.map +1 -1
  228. package/dist/sync/b2-sha1-reader.d.cts.map +1 -1
  229. package/dist/sync/b2-sha1-reader.d.ts.map +1 -1
  230. package/dist/sync/b2-sha1-reader.js +6 -2
  231. package/dist/sync/b2-sha1-reader.js.map +1 -1
  232. package/dist/sync/download-staging.cjs +11 -10
  233. package/dist/sync/download-staging.cjs.map +1 -1
  234. package/dist/sync/download-staging.d.cts +2 -1
  235. package/dist/sync/download-staging.d.cts.map +1 -1
  236. package/dist/sync/download-staging.d.ts +2 -1
  237. package/dist/sync/download-staging.d.ts.map +1 -1
  238. package/dist/sync/download-staging.js +11 -10
  239. package/dist/sync/download-staging.js.map +1 -1
  240. package/dist/sync/filters.cjs.map +1 -1
  241. package/dist/sync/filters.js.map +1 -1
  242. package/dist/sync/local-file-io.cjs +11 -6
  243. package/dist/sync/local-file-io.cjs.map +1 -1
  244. package/dist/sync/local-file-io.d.cts +1 -0
  245. package/dist/sync/local-file-io.d.cts.map +1 -1
  246. package/dist/sync/local-file-io.d.ts +1 -0
  247. package/dist/sync/local-file-io.d.ts.map +1 -1
  248. package/dist/sync/local-file-io.js +11 -6
  249. package/dist/sync/local-file-io.js.map +1 -1
  250. package/dist/sync/local-sha1.cjs +6 -15
  251. package/dist/sync/local-sha1.cjs.map +1 -1
  252. package/dist/sync/local-sha1.d.cts +0 -8
  253. package/dist/sync/local-sha1.d.cts.map +1 -1
  254. package/dist/sync/local-sha1.d.ts +0 -8
  255. package/dist/sync/local-sha1.d.ts.map +1 -1
  256. package/dist/sync/local-sha1.js +7 -15
  257. package/dist/sync/local-sha1.js.map +1 -1
  258. package/dist/sync/policies/compare.cjs +5 -3
  259. package/dist/sync/policies/compare.cjs.map +1 -1
  260. package/dist/sync/policies/compare.d.cts.map +1 -1
  261. package/dist/sync/policies/compare.d.ts.map +1 -1
  262. package/dist/sync/policies/compare.js +6 -4
  263. package/dist/sync/policies/compare.js.map +1 -1
  264. package/dist/sync/policies/index.cjs +4 -10
  265. package/dist/sync/policies/index.cjs.map +1 -1
  266. package/dist/sync/policies/index.js +4 -10
  267. package/dist/sync/policies/index.js.map +1 -1
  268. package/dist/sync/scanners/b2.cjs +2 -2
  269. package/dist/sync/scanners/b2.cjs.map +1 -1
  270. package/dist/sync/scanners/b2.js +2 -2
  271. package/dist/sync/scanners/b2.js.map +1 -1
  272. package/dist/sync/scanners/local.cjs.map +1 -1
  273. package/dist/sync/scanners/local.js.map +1 -1
  274. package/dist/sync/synchronizer.cjs +3 -2
  275. package/dist/sync/synchronizer.cjs.map +1 -1
  276. package/dist/sync/synchronizer.js +3 -2
  277. package/dist/sync/synchronizer.js.map +1 -1
  278. package/dist/types/auth.cjs +4 -0
  279. package/dist/types/auth.cjs.map +1 -1
  280. package/dist/types/auth.d.cts +4 -0
  281. package/dist/types/auth.d.cts.map +1 -1
  282. package/dist/types/auth.d.ts +4 -0
  283. package/dist/types/auth.d.ts.map +1 -1
  284. package/dist/types/auth.js +4 -0
  285. package/dist/types/auth.js.map +1 -1
  286. package/dist/types/backup.d.cts +80 -0
  287. package/dist/types/backup.d.cts.map +1 -0
  288. package/dist/types/backup.d.ts +80 -0
  289. package/dist/types/backup.d.ts.map +1 -0
  290. package/dist/types/bucket.cjs.map +1 -1
  291. package/dist/types/bucket.d.cts +4 -2
  292. package/dist/types/bucket.d.cts.map +1 -1
  293. package/dist/types/bucket.d.ts +4 -2
  294. package/dist/types/bucket.d.ts.map +1 -1
  295. package/dist/types/bucket.js.map +1 -1
  296. package/dist/types/download.cjs +62 -0
  297. package/dist/types/download.cjs.map +1 -0
  298. package/dist/types/download.d.cts +98 -0
  299. package/dist/types/download.d.cts.map +1 -1
  300. package/dist/types/download.d.ts +98 -0
  301. package/dist/types/download.d.ts.map +1 -1
  302. package/dist/types/download.js +61 -0
  303. package/dist/types/download.js.map +1 -0
  304. package/dist/types/encryption.cjs +58 -229
  305. package/dist/types/encryption.cjs.map +1 -1
  306. package/dist/types/encryption.d.cts +32 -0
  307. package/dist/types/encryption.d.cts.map +1 -1
  308. package/dist/types/encryption.d.ts +32 -0
  309. package/dist/types/encryption.d.ts.map +1 -1
  310. package/dist/types/encryption.js +56 -229
  311. package/dist/types/encryption.js.map +1 -1
  312. package/dist/types/errors.cjs +9 -0
  313. package/dist/types/errors.cjs.map +1 -1
  314. package/dist/types/errors.d.cts +1 -1
  315. package/dist/types/errors.d.cts.map +1 -1
  316. package/dist/types/errors.d.ts +1 -1
  317. package/dist/types/errors.d.ts.map +1 -1
  318. package/dist/types/errors.js +9 -0
  319. package/dist/types/errors.js.map +1 -1
  320. package/dist/types/file.cjs.map +1 -1
  321. package/dist/types/file.d.cts +15 -2
  322. package/dist/types/file.d.cts.map +1 -1
  323. package/dist/types/file.d.ts +15 -2
  324. package/dist/types/file.d.ts.map +1 -1
  325. package/dist/types/file.js.map +1 -1
  326. package/dist/types/ids.cjs +30 -0
  327. package/dist/types/ids.cjs.map +1 -1
  328. package/dist/types/ids.d.cts +32 -0
  329. package/dist/types/ids.d.cts.map +1 -1
  330. package/dist/types/ids.d.ts +32 -0
  331. package/dist/types/ids.d.ts.map +1 -1
  332. package/dist/types/ids.js +28 -1
  333. package/dist/types/ids.js.map +1 -1
  334. package/dist/types/index.d.cts +10 -6
  335. package/dist/types/index.d.cts.map +1 -1
  336. package/dist/types/index.d.ts +10 -6
  337. package/dist/types/index.d.ts.map +1 -1
  338. package/dist/types/lock.cjs.map +1 -1
  339. package/dist/types/lock.d.cts +14 -0
  340. package/dist/types/lock.d.cts.map +1 -1
  341. package/dist/types/lock.d.ts +14 -0
  342. package/dist/types/lock.d.ts.map +1 -1
  343. package/dist/types/lock.js.map +1 -1
  344. package/dist/types/notifications.cjs +1 -1
  345. package/dist/types/notifications.cjs.map +1 -1
  346. package/dist/types/notifications.d.cts +5 -3
  347. package/dist/types/notifications.d.cts.map +1 -1
  348. package/dist/types/notifications.d.ts +5 -3
  349. package/dist/types/notifications.d.ts.map +1 -1
  350. package/dist/types/notifications.js +1 -1
  351. package/dist/types/notifications.js.map +1 -1
  352. package/dist/types/partner.cjs +32 -0
  353. package/dist/types/partner.cjs.map +1 -0
  354. package/dist/types/partner.d.cts +394 -0
  355. package/dist/types/partner.d.cts.map +1 -0
  356. package/dist/types/partner.d.ts +394 -0
  357. package/dist/types/partner.d.ts.map +1 -0
  358. package/dist/types/partner.js +29 -0
  359. package/dist/types/partner.js.map +1 -0
  360. package/dist/types/upload.d.cts +31 -18
  361. package/dist/types/upload.d.cts.map +1 -1
  362. package/dist/types/upload.d.ts +31 -18
  363. package/dist/types/upload.d.ts.map +1 -1
  364. package/dist/upload/abort-scope.cjs +0 -45
  365. package/dist/upload/abort-scope.cjs.map +1 -1
  366. package/dist/upload/abort-scope.d.cts +0 -22
  367. package/dist/upload/abort-scope.d.cts.map +1 -1
  368. package/dist/upload/abort-scope.d.ts +0 -22
  369. package/dist/upload/abort-scope.d.ts.map +1 -1
  370. package/dist/upload/abort-scope.js +1 -44
  371. package/dist/upload/abort-scope.js.map +1 -1
  372. package/dist/upload/finish.cjs +3 -8
  373. package/dist/upload/finish.cjs.map +1 -1
  374. package/dist/upload/finish.d.cts.map +1 -1
  375. package/dist/upload/finish.d.ts.map +1 -1
  376. package/dist/upload/finish.js +1 -6
  377. package/dist/upload/finish.js.map +1 -1
  378. package/dist/upload/large.cjs +5 -1
  379. package/dist/upload/large.cjs.map +1 -1
  380. package/dist/upload/large.d.cts +16 -2
  381. package/dist/upload/large.d.cts.map +1 -1
  382. package/dist/upload/large.d.ts +16 -2
  383. package/dist/upload/large.d.ts.map +1 -1
  384. package/dist/upload/large.js +5 -1
  385. package/dist/upload/large.js.map +1 -1
  386. package/dist/upload/options.cjs.map +1 -1
  387. package/dist/upload/options.d.cts +12 -0
  388. package/dist/upload/options.d.cts.map +1 -1
  389. package/dist/upload/options.d.ts +12 -0
  390. package/dist/upload/options.d.ts.map +1 -1
  391. package/dist/upload/options.js.map +1 -1
  392. package/dist/upload/resume.cjs +2 -1
  393. package/dist/upload/resume.cjs.map +1 -1
  394. package/dist/upload/resume.d.cts +3 -1
  395. package/dist/upload/resume.d.cts.map +1 -1
  396. package/dist/upload/resume.d.ts +3 -1
  397. package/dist/upload/resume.d.ts.map +1 -1
  398. package/dist/upload/resume.js +2 -1
  399. package/dist/upload/resume.js.map +1 -1
  400. package/dist/upload/retry.cjs +8 -3
  401. package/dist/upload/retry.cjs.map +1 -1
  402. package/dist/upload/retry.js +8 -3
  403. package/dist/upload/retry.js.map +1 -1
  404. package/dist/upload/single.cjs +2 -1
  405. package/dist/upload/single.cjs.map +1 -1
  406. package/dist/upload/single.d.cts +6 -0
  407. package/dist/upload/single.d.cts.map +1 -1
  408. package/dist/upload/single.d.ts +6 -0
  409. package/dist/upload/single.d.ts.map +1 -1
  410. package/dist/upload/single.js +2 -1
  411. package/dist/upload/single.js.map +1 -1
  412. package/dist/upload/stream.cjs +6 -4
  413. package/dist/upload/stream.cjs.map +1 -1
  414. package/dist/upload/stream.d.cts +6 -0
  415. package/dist/upload/stream.d.cts.map +1 -1
  416. package/dist/upload/stream.d.ts +6 -0
  417. package/dist/upload/stream.d.ts.map +1 -1
  418. package/dist/upload/stream.js +3 -1
  419. package/dist/upload/stream.js.map +1 -1
  420. package/dist/util/abort.cjs +114 -0
  421. package/dist/util/abort.cjs.map +1 -0
  422. package/dist/util/abort.d.cts +65 -0
  423. package/dist/util/abort.d.cts.map +1 -0
  424. package/dist/util/abort.d.ts +65 -0
  425. package/dist/util/abort.d.ts.map +1 -0
  426. package/dist/util/abort.js +109 -0
  427. package/dist/util/abort.js.map +1 -0
  428. package/dist/util/defaults.cjs +3 -0
  429. package/dist/util/defaults.cjs.map +1 -1
  430. package/dist/util/defaults.d.cts +2 -0
  431. package/dist/util/defaults.d.cts.map +1 -1
  432. package/dist/util/defaults.d.ts +2 -0
  433. package/dist/util/defaults.d.ts.map +1 -1
  434. package/dist/util/defaults.js +3 -1
  435. package/dist/util/defaults.js.map +1 -1
  436. package/dist/util/md5.cjs +211 -0
  437. package/dist/util/md5.cjs.map +1 -0
  438. package/dist/util/md5.d.cts +43 -0
  439. package/dist/util/md5.d.cts.map +1 -0
  440. package/dist/util/md5.d.ts +43 -0
  441. package/dist/util/md5.d.ts.map +1 -0
  442. package/dist/util/md5.js +209 -0
  443. package/dist/util/md5.js.map +1 -0
  444. package/dist/util/normalize.cjs +5 -5
  445. package/dist/util/normalize.cjs.map +1 -1
  446. package/dist/util/normalize.d.cts +7 -7
  447. package/dist/util/normalize.d.cts.map +1 -1
  448. package/dist/util/normalize.d.ts +7 -7
  449. package/dist/util/normalize.d.ts.map +1 -1
  450. package/dist/util/normalize.js +5 -5
  451. package/dist/util/normalize.js.map +1 -1
  452. package/dist/util/paginator.cjs +7 -1
  453. package/dist/util/paginator.cjs.map +1 -1
  454. package/dist/util/paginator.d.cts +3 -1
  455. package/dist/util/paginator.d.cts.map +1 -1
  456. package/dist/util/paginator.d.ts +3 -1
  457. package/dist/util/paginator.d.ts.map +1 -1
  458. package/dist/util/paginator.js +7 -1
  459. package/dist/util/paginator.js.map +1 -1
  460. package/package.json +38 -16
@@ -1 +1 @@
1
- {"version":3,"file":"errors.js","names":[],"sources":["../../src/types/errors.ts"],"sourcesContent":["/**\n * B2 API error codes documented by the SDK.\n * This list drives `KnownB2ErrorCode`; `B2ErrorCode` adds a string fallback\n * so callers can receive unknown future server codes while keeping autocomplete\n * for known values.\n */\nexport const KNOWN_B2_ERROR_CODES = [\n 'expired_auth_token',\n 'bad_auth_token',\n 'unauthorized',\n 'bad_request',\n 'bad_bucket_name',\n 'bad_bucket_id',\n 'not_found',\n 'method_not_allowed',\n 'request_timeout',\n 'too_many_requests',\n 'conflict',\n 'duplicate_bucket_name',\n 'too_many_buckets',\n 'too_many_files',\n 'cap_exceeded',\n 'storage_cap_exceeded',\n 'transaction_cap_exceeded',\n 'download_cap_exceeded',\n 'access_denied',\n 'service_unavailable',\n 'internal_error',\n 'bad_json',\n 'invalid_bucket_id',\n 'invalid_bucket_name',\n 'invalid_bucket_info',\n 'file_not_present',\n 'no_such_file',\n 'out_of_range',\n 'range_not_satisfiable',\n 'invalid_file_id',\n 'invalid_file_name',\n 'invalid_file_info',\n 'invalid_part_number',\n 'bad_sha1_checksum',\n] as const\n\n/** B2 error codes documented by the SDK and classified exhaustively. */\nexport type KnownB2ErrorCode = (typeof KNOWN_B2_ERROR_CODES)[number]\n\n/**\n * B2 API error code value.\n * Known codes are enumerated for autocomplete; unknown future server codes are\n * still accepted as strings.\n */\nexport type B2ErrorCode = KnownB2ErrorCode | (string & {})\n\n/** Standard error response body returned by the B2 API on failure. */\nexport interface B2ErrorResponse {\n /** HTTP status code from the B2 API response. */\n readonly status: number\n /** Machine-readable error code identifying the specific failure. */\n readonly code: B2ErrorCode\n /** Human-readable description of the error. */\n readonly message: string\n}\n"],"mappings":";;;;;;;AAMA,IAAa,uBAAuB;CAClC;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;AACF"}
1
+ {"version":3,"file":"errors.js","names":[],"sources":["../../src/types/errors.ts"],"sourcesContent":["/**\n * B2 API error codes documented by the SDK.\n * This list drives `KnownB2ErrorCode`; `B2ErrorCode` adds a string fallback\n * so callers can receive unknown future server codes while keeping autocomplete\n * for known values.\n */\nexport const KNOWN_B2_ERROR_CODES = [\n 'expired_auth_token',\n 'bad_auth_token',\n 'unauthorized',\n 'bad_request',\n 'bad_bucket_name',\n 'bad_bucket_id',\n 'not_found',\n 'method_not_allowed',\n 'request_timeout',\n 'too_many_requests',\n 'conflict',\n 'duplicate_bucket_name',\n 'too_many_buckets',\n 'too_many_files',\n 'too_many_members',\n 'cap_exceeded',\n 'storage_cap_exceeded',\n 'transaction_cap_exceeded',\n 'download_cap_exceeded',\n 'access_denied',\n 'service_unavailable',\n 'internal_error',\n 'bad_json',\n 'invalid_account_id',\n 'invalid_bucket_id',\n 'invalid_bucket_name',\n 'invalid_bucket_info',\n 'invalid_computer_id',\n 'invalid_email',\n 'invalid_group_id',\n 'invalid_member_account_id',\n 'invalid_region',\n 'invalid_sms_phone',\n 'file_not_present',\n 'no_such_file',\n 'out_of_range',\n 'range_not_satisfiable',\n 'invalid_file_id',\n 'invalid_file_name',\n 'invalid_file_info',\n 'invalid_part_number',\n 'method_failure',\n 'bad_sha1_checksum',\n] as const\n\n/** B2 error codes documented by the SDK and classified exhaustively. */\nexport type KnownB2ErrorCode = (typeof KNOWN_B2_ERROR_CODES)[number]\n\n/**\n * B2 API error code value.\n * Known codes are enumerated for autocomplete; unknown future server codes are\n * still accepted as strings.\n */\nexport type B2ErrorCode = KnownB2ErrorCode | (string & {})\n\n/** Standard error response body returned by the B2 API on failure. */\nexport interface B2ErrorResponse {\n /** HTTP status code from the B2 API response. */\n readonly status: number\n /** Machine-readable error code identifying the specific failure. */\n readonly code: B2ErrorCode\n /** Human-readable description of the error. */\n readonly message: string\n}\n"],"mappings":";;;;;;;AAMA,IAAa,uBAAuB;CAClC;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;AACF"}
@@ -1 +1 @@
1
- {"version":3,"file":"file.cjs","names":[],"sources":["../../src/types/file.ts"],"sourcesContent":["import type { EncryptionSetting, PublicEncryptionSetting } from './encryption.ts'\nimport type { AccountId, BucketId, FileId } from './ids.ts'\nimport type { FileRetentionValue, LegalHoldValue } from './lock.ts'\n\n/**\n * Named constants for the action that created a file version.\n *\n * @example\n * ```ts\n * if (file.action === FileAction.Hide) { ... }\n * ```\n */\nexport const FileAction = {\n /** Large file upload started but not yet finished. */\n Start: 'start',\n /** Normal upload (small or finished large file). */\n Upload: 'upload',\n /** Hide marker (soft delete). */\n Hide: 'hide',\n /** Virtual folder marker. */\n Folder: 'folder',\n /** Created via server-side copy. */\n Copy: 'copy',\n} as const\n\n/**\n * The action that created a file version. Derived from {@link FileAction}.\n *\n * - `'start'`: large file upload started but not yet finished.\n * - `'upload'`: file was uploaded normally.\n * - `'hide'`: file was hidden (soft-deleted).\n * - `'folder'`: virtual folder marker.\n * - `'copy'`: file was created via server-side copy.\n */\nexport type FileAction = (typeof FileAction)[keyof typeof FileAction]\n\n/**\n * Complete metadata for a single file version in B2.\n * Returned by `b2_get_file_info`, `b2_list_file_names`, `b2_list_file_versions`,\n * `b2_upload_file`, `b2_copy_file`, and other file-related endpoints.\n */\nexport interface FileVersion {\n /** Account that owns this file. */\n readonly accountId: AccountId\n /** Action that created this file version. */\n readonly action: FileAction\n /** Bucket containing this file. */\n readonly bucketId: BucketId\n /** Size of the file content in bytes. */\n readonly contentLength: number\n /** MD5 checksum of the content, or null if not available. */\n readonly contentMd5: string | null\n /** SHA-1 checksum of the content, or null if not available (e.g., large files). */\n readonly contentSha1: string | null\n /** MIME type of the file content. */\n readonly contentType: string\n /** Unique identifier for this file version. */\n readonly fileId: FileId\n /** User-defined key-value metadata stored with the file. */\n readonly fileInfo: Record<string, string>\n /** Full path and name of the file within the bucket. */\n readonly fileName: string\n /** Object Lock retention settings for this file version. */\n readonly fileRetention: {\n /** Whether the caller is authorized to read retention settings. */\n readonly isClientAuthorizedToRead: boolean\n /** Retention settings, or null if the caller lacks read authorization. */\n readonly value: FileRetentionValue | null\n }\n /** Legal hold status for this file version. */\n readonly legalHold: {\n /** Whether the caller is authorized to read legal hold status. */\n readonly isClientAuthorizedToRead: boolean\n /** Legal hold value, or null if the caller lacks read authorization. */\n readonly value: LegalHoldValue | null\n }\n /** Replication status, or null if replication is not configured. */\n readonly replicationStatus: 'pending' | 'completed' | 'failed' | 'replica' | null\n /** Server-side encryption settings applied to this file version. */\n readonly serverSideEncryption: PublicEncryptionSetting\n /** UTC timestamp (milliseconds) when this version was uploaded. */\n readonly uploadTimestamp: number\n}\n\n/** Request parameters for the `b2_list_file_names` API call. Lists the most recent version of each file in a bucket. */\nexport interface ListFileNamesRequest {\n /** Bucket to list files from. */\n readonly bucketId: BucketId\n /** Return files starting after this name (exclusive). Used for pagination. */\n readonly startFileName?: string\n /** Maximum number of files to return (1 to 10000). */\n readonly maxFileCount?: number\n /** Only return files whose names start with this prefix. */\n readonly prefix?: string\n /** Delimiter for virtual folder grouping (typically `'/'`). */\n readonly delimiter?: string\n}\n\n/** Response from the `b2_list_file_names` API call. */\nexport interface ListFileNamesResponse {\n /** Array of file versions matching the request. */\n readonly files: readonly FileVersion[]\n /** Next file name to use for pagination, or null if all files have been listed. */\n readonly nextFileName: string | null\n}\n\n/** Request parameters for the `b2_list_file_versions` API call. Lists all versions of files in a bucket. */\nexport interface ListFileVersionsRequest {\n /** Bucket to list file versions from. */\n readonly bucketId: BucketId\n /** Return files starting after this name (exclusive). Used for pagination. */\n readonly startFileName?: string\n /** Return file versions starting after this ID. Used with startFileName for pagination. */\n readonly startFileId?: FileId\n /** Maximum number of file versions to return (1 to 10000). */\n readonly maxFileCount?: number\n /** Only return files whose names start with this prefix. */\n readonly prefix?: string\n /** Delimiter for virtual folder grouping (typically `'/'`). */\n readonly delimiter?: string\n}\n\n/** Response from the `b2_list_file_versions` API call. */\nexport interface ListFileVersionsResponse {\n /** Array of file versions matching the request. */\n readonly files: readonly FileVersion[]\n /** Next file name to use for pagination, or null if all versions have been listed. */\n readonly nextFileName: string | null\n /** Next file ID to use for pagination, or null if all versions have been listed. */\n readonly nextFileId: FileId | null\n}\n\n/** Request parameters for the `b2_get_file_info` API call. */\nexport interface GetFileInfoRequest {\n /** ID of the file version to retrieve info for. */\n readonly fileId: FileId\n}\n\n/** Request parameters for the `b2_hide_file` API call. Hides a file so it no longer appears in `b2_list_file_names`. */\nexport interface HideFileRequest {\n /** Bucket containing the file to hide. */\n readonly bucketId: BucketId\n /** Name of the file to hide. */\n readonly fileName: string\n}\n\n/** Request parameters for the `b2_delete_file_version` API call. */\nexport interface DeleteFileVersionRequest {\n /** Name of the file version to delete. */\n readonly fileName: string\n /** ID of the file version to delete. */\n readonly fileId: FileId\n /** If true, bypass governance-mode retention. Requires the `bypassGovernance` capability. */\n readonly bypassGovernance?: boolean\n}\n\n/** Response from the `b2_delete_file_version` API call. */\nexport interface DeleteFileVersionResponse {\n /** ID of the deleted file version. */\n readonly fileId: FileId\n /** Name of the deleted file. */\n readonly fileName: string\n}\n\n/**\n * Named constants for how metadata is handled during a file copy.\n *\n * @example\n * ```ts\n * await bucket.copyFile({ ..., metadataDirective: MetadataDirective.Replace })\n * ```\n */\nexport const MetadataDirective = {\n /** Preserve the source file's contentType and fileInfo. */\n Copy: 'COPY',\n /** Use the values provided in the copy request. */\n Replace: 'REPLACE',\n} as const\n\n/** Controls how metadata is handled during a file copy. Derived from {@link MetadataDirective}. */\nexport type MetadataDirective = (typeof MetadataDirective)[keyof typeof MetadataDirective]\n\n/** Request parameters for the `b2_copy_file` API call. Performs a server-side file copy. */\nexport interface CopyFileRequest {\n /** ID of the source file version to copy from. */\n readonly sourceFileId: FileId\n /** Destination bucket ID. Defaults to the source bucket if omitted. */\n readonly destinationBucketId?: BucketId\n /** Name for the destination file. */\n readonly fileName: string\n /** Byte range to copy (e.g., `'bytes=0-999'`). Omit to copy the entire file. */\n readonly range?: string\n /** Whether to copy or replace the source file's metadata. */\n readonly metadataDirective?: MetadataDirective\n /** MIME type for the destination file (only used when metadataDirective is `'REPLACE'`). */\n readonly contentType?: string\n /** User-defined metadata for the destination file (only used when metadataDirective is `'REPLACE'`). */\n readonly fileInfo?: Record<string, string>\n /** Object Lock retention for the destination file. */\n readonly fileRetention?: FileRetentionValue\n /** Legal hold for the destination file. */\n readonly legalHold?: LegalHoldValue\n /** SSE-C settings for reading the source file, if the source is encrypted with SSE-C. */\n readonly sourceServerSideEncryption?: EncryptionSetting\n /** Server-side encryption to apply to the destination file. */\n readonly destinationServerSideEncryption?: EncryptionSetting\n}\n\n/** Request parameters for the `b2_copy_part` API call. Copies a byte range into a large file part. */\nexport interface CopyPartRequest {\n /** ID of the source file version to copy from. */\n readonly sourceFileId: FileId\n /** ID of the large file being assembled. */\n readonly largeFileId: FileId\n /** Part number (1-based) for this part within the large file. */\n readonly partNumber: number\n /** Byte range to copy from the source (e.g., `'bytes=0-999'`). Omit to copy the entire source. */\n readonly range?: string\n /** SSE-C settings for reading the source file, if the source is encrypted with SSE-C. */\n readonly sourceServerSideEncryption?: EncryptionSetting\n /** Server-side encryption to apply to the destination part. */\n readonly destinationServerSideEncryption?: EncryptionSetting\n}\n\n/** Response from the `b2_copy_part` API call. */\nexport interface CopyPartResponse {\n /** ID of the large file this part belongs to. */\n readonly fileId: FileId\n /** Part number within the large file. */\n readonly partNumber: number\n /** Size of the copied part in bytes. */\n readonly contentLength: number\n /** SHA-1 checksum of the copied part content. */\n readonly contentSha1: string\n}\n"],"mappings":";;;;;;;;;AAYA,IAAa,aAAa;;CAExB,OAAO;;CAEP,QAAQ;;CAER,MAAM;;CAEN,QAAQ;;CAER,MAAM;AACR;;;;;;;;;AAqJA,IAAa,oBAAoB;;CAE/B,MAAM;;CAEN,SAAS;AACX"}
1
+ {"version":3,"file":"file.cjs","names":[],"sources":["../../src/types/file.ts"],"sourcesContent":["import type { EncryptionSetting, PublicEncryptionSetting } from './encryption.ts'\nimport type { AccountId, BucketId, FileId } from './ids.ts'\nimport type { FileRetentionValue, LegalHoldValue } from './lock.ts'\n\n/**\n * Named constants for the action that created a file version.\n *\n * @example\n * ```ts\n * if (file.action === FileAction.Hide) { ... }\n * ```\n */\nexport const FileAction = {\n /** Large file upload started but not yet finished. */\n Start: 'start',\n /** Normal upload (small or finished large file). */\n Upload: 'upload',\n /** Hide marker (soft delete). */\n Hide: 'hide',\n /** Virtual folder marker. */\n Folder: 'folder',\n /** Created via server-side copy. */\n Copy: 'copy',\n} as const\n\n/**\n * The action that created a file version. Derived from {@link FileAction}.\n *\n * - `'start'`: large file upload started but not yet finished.\n * - `'upload'`: file was uploaded normally.\n * - `'hide'`: file was hidden (soft-deleted).\n * - `'folder'`: virtual folder marker.\n * - `'copy'`: file was created via server-side copy.\n */\nexport type FileAction = (typeof FileAction)[keyof typeof FileAction]\n\n/**\n * Replication status for a file version or unfinished large file.\n *\n * B2 returns these uppercase wire values as-is and omits the containing\n * `replicationStatus` field when the file is not covered by a replication rule.\n */\nexport type ReplicationStatus = 'PENDING' | 'COMPLETED' | 'FAILED' | 'REPLICA'\n\n/**\n * Complete metadata for a single file version in B2.\n * Returned by `b2_get_file_info`, `b2_list_file_names`, `b2_list_file_versions`,\n * `b2_upload_file`, `b2_copy_file`, and other file-related endpoints.\n */\nexport interface FileVersion {\n /** Account that owns this file. */\n readonly accountId: AccountId\n /** Action that created this file version. */\n readonly action: FileAction\n /** Bucket containing this file. */\n readonly bucketId: BucketId\n /** Size of the file content in bytes. */\n readonly contentLength: number\n /** MD5 checksum of the content, or null if not available. */\n readonly contentMd5: string | null\n /** SHA-1 checksum of the content, or null if not available (e.g., large files). */\n readonly contentSha1: string | null\n /** MIME type of the file content. */\n readonly contentType: string\n /** Unique identifier for this file version. */\n readonly fileId: FileId\n /** User-defined key-value metadata stored with the file. */\n readonly fileInfo: Record<string, string>\n /** Full path and name of the file within the bucket. */\n readonly fileName: string\n /** Object Lock retention settings for this file version. */\n readonly fileRetention: {\n /** Whether the caller is authorized to read retention settings. */\n readonly isClientAuthorizedToRead: boolean\n /** Retention settings, or null if the caller lacks read authorization. */\n readonly value: FileRetentionValue | null\n }\n /** Legal hold status for this file version. */\n readonly legalHold: {\n /** Whether the caller is authorized to read legal hold status. */\n readonly isClientAuthorizedToRead: boolean\n /** Legal hold value, or null if the caller lacks read authorization. */\n readonly value: LegalHoldValue | null\n }\n /** Replication status when this file is covered by a replication rule. */\n readonly replicationStatus?: ReplicationStatus\n /** Server-side encryption settings applied to this file version. */\n readonly serverSideEncryption: PublicEncryptionSetting\n /** UTC timestamp (milliseconds) when this version was uploaded. */\n readonly uploadTimestamp: number\n}\n\n/** Request parameters for the `b2_list_file_names` API call. Lists the most recent version of each file in a bucket. */\nexport interface ListFileNamesRequest {\n /** Bucket to list files from. */\n readonly bucketId: BucketId\n /** Return files starting after this name (exclusive). Used for pagination. */\n readonly startFileName?: string\n /** Maximum number of files to return (1 to 10000). */\n readonly maxFileCount?: number\n /** Only return files whose names start with this prefix. */\n readonly prefix?: string\n /** Delimiter for virtual folder grouping (typically `'/'`). */\n readonly delimiter?: string\n}\n\n/** Response from the `b2_list_file_names` API call. */\nexport interface ListFileNamesResponse {\n /** Array of file versions matching the request. */\n readonly files: readonly FileVersion[]\n /** Next file name to use for pagination, or null if all files have been listed. */\n readonly nextFileName: string | null\n}\n\n/** Request parameters for the `b2_list_file_versions` API call. Lists all versions of files in a bucket. */\nexport interface ListFileVersionsRequest {\n /** Bucket to list file versions from. */\n readonly bucketId: BucketId\n /** Return files starting after this name (exclusive). Used for pagination. */\n readonly startFileName?: string\n /** Return file versions starting after this ID. Used with startFileName for pagination. */\n readonly startFileId?: FileId\n /** Maximum number of file versions to return (1 to 10000). */\n readonly maxFileCount?: number\n /** Only return files whose names start with this prefix. */\n readonly prefix?: string\n /** Delimiter for virtual folder grouping (typically `'/'`). */\n readonly delimiter?: string\n}\n\n/** Response from the `b2_list_file_versions` API call. */\nexport interface ListFileVersionsResponse {\n /** Array of file versions matching the request. */\n readonly files: readonly FileVersion[]\n /** Next file name to use for pagination, or null if all versions have been listed. */\n readonly nextFileName: string | null\n /** Next file ID to use for pagination, or null if all versions have been listed. */\n readonly nextFileId: FileId | null\n}\n\n/** Request parameters for the `b2_get_file_info` API call. */\nexport interface GetFileInfoRequest {\n /** ID of the file version to retrieve info for. */\n readonly fileId: FileId\n}\n\n/** Request parameters for the `b2_hide_file` API call. Hides a file so it no longer appears in `b2_list_file_names`. */\nexport interface HideFileRequest {\n /** Bucket containing the file to hide. */\n readonly bucketId: BucketId\n /** Name of the file to hide. */\n readonly fileName: string\n}\n\n/** Request parameters for the `b2_delete_file_version` API call. */\nexport interface DeleteFileVersionRequest {\n /** Name of the file version to delete. */\n readonly fileName: string\n /** ID of the file version to delete. */\n readonly fileId: FileId\n /** If true, bypass governance-mode retention. Requires the `bypassGovernance` capability. */\n readonly bypassGovernance?: boolean\n}\n\n/** Response from the `b2_delete_file_version` API call. */\nexport interface DeleteFileVersionResponse {\n /** ID of the deleted file version. */\n readonly fileId: FileId\n /** Name of the deleted file. */\n readonly fileName: string\n}\n\n/**\n * Named constants for how metadata is handled during a file copy.\n *\n * @example\n * ```ts\n * await bucket.copyFile({ ..., metadataDirective: MetadataDirective.Replace })\n * ```\n */\nexport const MetadataDirective = {\n /** Preserve the source file's contentType and fileInfo. */\n Copy: 'COPY',\n /** Use the values provided in the copy request. */\n Replace: 'REPLACE',\n} as const\n\n/** Controls how metadata is handled during a file copy. Derived from {@link MetadataDirective}. */\nexport type MetadataDirective = (typeof MetadataDirective)[keyof typeof MetadataDirective]\n\n/** Request parameters for the `b2_copy_file` API call. Performs a server-side file copy. */\nexport interface CopyFileRequest {\n /** ID of the source file version to copy from. */\n readonly sourceFileId: FileId\n /** Destination bucket ID. Defaults to the source bucket if omitted. */\n readonly destinationBucketId?: BucketId\n /** Name for the destination file. */\n readonly fileName: string\n /** Byte range to copy (e.g., `'bytes=0-999'`). Omit to copy the entire file. */\n readonly range?: string\n /** Whether to copy or replace the source file's metadata. */\n readonly metadataDirective?: MetadataDirective\n /** MIME type for the destination file (only used when metadataDirective is `'REPLACE'`). */\n readonly contentType?: string\n /** User-defined metadata for the destination file (only used when metadataDirective is `'REPLACE'`). */\n readonly fileInfo?: Record<string, string>\n /** Object Lock retention for the destination file. */\n readonly fileRetention?: FileRetentionValue\n /** Legal hold for the destination file. */\n readonly legalHold?: LegalHoldValue\n /** SSE-C settings for reading the source file, if the source is encrypted with SSE-C. */\n readonly sourceServerSideEncryption?: EncryptionSetting\n /** Server-side encryption to apply to the destination file. */\n readonly destinationServerSideEncryption?: EncryptionSetting\n}\n\n/** Request parameters for the `b2_copy_part` API call. Copies a byte range into a large file part. */\nexport interface CopyPartRequest {\n /** ID of the source file version to copy from. */\n readonly sourceFileId: FileId\n /** ID of the large file being assembled. */\n readonly largeFileId: FileId\n /** Part number (1-based) for this part within the large file. */\n readonly partNumber: number\n /** Byte range to copy from the source (e.g., `'bytes=0-999'`). Omit to copy the entire source. */\n readonly range?: string\n /** SSE-C settings for reading the source file, if the source is encrypted with SSE-C. */\n readonly sourceServerSideEncryption?: EncryptionSetting\n /** Server-side encryption to apply to the destination part. */\n readonly destinationServerSideEncryption?: EncryptionSetting\n}\n\n/** Response from the `b2_copy_part` API call. */\nexport interface CopyPartResponse {\n /** ID of the large file this part belongs to. */\n readonly fileId: FileId\n /** Part number within the large file. */\n readonly partNumber: number\n /** Size of the copied part in bytes. */\n readonly contentLength: number\n /** SHA-1 checksum of the copied part content. */\n readonly contentSha1: string\n /** MD5 checksum of the copied part content, or null if not available. */\n readonly contentMd5: string | null\n /** Server-side encryption applied to this copied part. */\n readonly serverSideEncryption: PublicEncryptionSetting\n /** UTC timestamp (milliseconds) when this part was copied. */\n readonly uploadTimestamp: number\n}\n"],"mappings":";;;;;;;;;AAYA,IAAa,aAAa;;CAExB,OAAO;;CAEP,QAAQ;;CAER,MAAM;;CAEN,QAAQ;;CAER,MAAM;AACR;;;;;;;;;AA6JA,IAAa,oBAAoB;;CAE/B,MAAM;;CAEN,SAAS;AACX"}
@@ -31,6 +31,13 @@ export declare const FileAction: {
31
31
  * - `'copy'`: file was created via server-side copy.
32
32
  */
33
33
  export type FileAction = (typeof FileAction)[keyof typeof FileAction];
34
+ /**
35
+ * Replication status for a file version or unfinished large file.
36
+ *
37
+ * B2 returns these uppercase wire values as-is and omits the containing
38
+ * `replicationStatus` field when the file is not covered by a replication rule.
39
+ */
40
+ export type ReplicationStatus = 'PENDING' | 'COMPLETED' | 'FAILED' | 'REPLICA';
34
41
  /**
35
42
  * Complete metadata for a single file version in B2.
36
43
  * Returned by `b2_get_file_info`, `b2_list_file_names`, `b2_list_file_versions`,
@@ -71,8 +78,8 @@ export interface FileVersion {
71
78
  /** Legal hold value, or null if the caller lacks read authorization. */
72
79
  readonly value: LegalHoldValue | null;
73
80
  };
74
- /** Replication status, or null if replication is not configured. */
75
- readonly replicationStatus: 'pending' | 'completed' | 'failed' | 'replica' | null;
81
+ /** Replication status when this file is covered by a replication rule. */
82
+ readonly replicationStatus?: ReplicationStatus;
76
83
  /** Server-side encryption settings applied to this file version. */
77
84
  readonly serverSideEncryption: PublicEncryptionSetting;
78
85
  /** UTC timestamp (milliseconds) when this version was uploaded. */
@@ -216,5 +223,11 @@ export interface CopyPartResponse {
216
223
  readonly contentLength: number;
217
224
  /** SHA-1 checksum of the copied part content. */
218
225
  readonly contentSha1: string;
226
+ /** MD5 checksum of the copied part content, or null if not available. */
227
+ readonly contentMd5: string | null;
228
+ /** Server-side encryption applied to this copied part. */
229
+ readonly serverSideEncryption: PublicEncryptionSetting;
230
+ /** UTC timestamp (milliseconds) when this part was copied. */
231
+ readonly uploadTimestamp: number;
219
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AU,EAAE,MAAM,GAAG,IAAI,CAAA;IAClC,0DAA0D;IAC1D,QAAQ,CAAC,oBAAoB,EAAE,uBAAuB,CAAA;IACtD,8DAA8D;IAC9D,QAAQ,CAAC,eAAe,EAAE,MAAM,CAAA;CACjC"}
@@ -31,6 +31,13 @@ export declare const FileAction: {
31
31
  * - `'copy'`: file was created via server-side copy.
32
32
  */
33
33
  export type FileAction = (typeof FileAction)[keyof typeof FileAction];
34
+ /**
35
+ * Replication status for a file version or unfinished large file.
36
+ *
37
+ * B2 returns these uppercase wire values as-is and omits the containing
38
+ * `replicationStatus` field when the file is not covered by a replication rule.
39
+ */
40
+ export type ReplicationStatus = 'PENDING' | 'COMPLETED' | 'FAILED' | 'REPLICA';
34
41
  /**
35
42
  * Complete metadata for a single file version in B2.
36
43
  * Returned by `b2_get_file_info`, `b2_list_file_names`, `b2_list_file_versions`,
@@ -71,8 +78,8 @@ export interface FileVersion {
71
78
  /** Legal hold value, or null if the caller lacks read authorization. */
72
79
  readonly value: LegalHoldValue | null;
73
80
  };
74
- /** Replication status, or null if replication is not configured. */
75
- readonly replicationStatus: 'pending' | 'completed' | 'failed' | 'replica' | null;
81
+ /** Replication status when this file is covered by a replication rule. */
82
+ readonly replicationStatus?: ReplicationStatus;
76
83
  /** Server-side encryption settings applied to this file version. */
77
84
  readonly serverSideEncryption: PublicEncryptionSetting;
78
85
  /** UTC timestamp (milliseconds) when this version was uploaded. */
@@ -216,5 +223,11 @@ export interface CopyPartResponse {
216
223
  readonly contentLength: number;
217
224
  /** SHA-1 checksum of the copied part content. */
218
225
  readonly contentSha1: string;
226
+ /** MD5 checksum of the copied part content, or null if not available. */
227
+ readonly contentMd5: string | null;
228
+ /** Server-side encryption applied to this copied part. */
229
+ readonly serverSideEncryption: PublicEncryptionSetting;
230
+ /** UTC timestamp (milliseconds) when this part was copied. */
231
+ readonly uploadTimestamp: number;
219
232
  }
220
233
  //# sourceMappingURL=file.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"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CAAC,oBAAoB,EAAE,uBAAuB,CAAA;IACtD,8DAA8D;IAC9D,QAAQ,CAAC,eAAe,EAAE,MAAM,CAAA;CACjC"}
@@ -1 +1 @@
1
- {"version":3,"file":"file.js","names":[],"sources":["../../src/types/file.ts"],"sourcesContent":["import type { EncryptionSetting, PublicEncryptionSetting } from './encryption.ts'\nimport type { AccountId, BucketId, FileId } from './ids.ts'\nimport type { FileRetentionValue, LegalHoldValue } from './lock.ts'\n\n/**\n * Named constants for the action that created a file version.\n *\n * @example\n * ```ts\n * if (file.action === FileAction.Hide) { ... }\n * ```\n */\nexport const FileAction = {\n /** Large file upload started but not yet finished. */\n Start: 'start',\n /** Normal upload (small or finished large file). */\n Upload: 'upload',\n /** Hide marker (soft delete). */\n Hide: 'hide',\n /** Virtual folder marker. */\n Folder: 'folder',\n /** Created via server-side copy. */\n Copy: 'copy',\n} as const\n\n/**\n * The action that created a file version. Derived from {@link FileAction}.\n *\n * - `'start'`: large file upload started but not yet finished.\n * - `'upload'`: file was uploaded normally.\n * - `'hide'`: file was hidden (soft-deleted).\n * - `'folder'`: virtual folder marker.\n * - `'copy'`: file was created via server-side copy.\n */\nexport type FileAction = (typeof FileAction)[keyof typeof FileAction]\n\n/**\n * Complete metadata for a single file version in B2.\n * Returned by `b2_get_file_info`, `b2_list_file_names`, `b2_list_file_versions`,\n * `b2_upload_file`, `b2_copy_file`, and other file-related endpoints.\n */\nexport interface FileVersion {\n /** Account that owns this file. */\n readonly accountId: AccountId\n /** Action that created this file version. */\n readonly action: FileAction\n /** Bucket containing this file. */\n readonly bucketId: BucketId\n /** Size of the file content in bytes. */\n readonly contentLength: number\n /** MD5 checksum of the content, or null if not available. */\n readonly contentMd5: string | null\n /** SHA-1 checksum of the content, or null if not available (e.g., large files). */\n readonly contentSha1: string | null\n /** MIME type of the file content. */\n readonly contentType: string\n /** Unique identifier for this file version. */\n readonly fileId: FileId\n /** User-defined key-value metadata stored with the file. */\n readonly fileInfo: Record<string, string>\n /** Full path and name of the file within the bucket. */\n readonly fileName: string\n /** Object Lock retention settings for this file version. */\n readonly fileRetention: {\n /** Whether the caller is authorized to read retention settings. */\n readonly isClientAuthorizedToRead: boolean\n /** Retention settings, or null if the caller lacks read authorization. */\n readonly value: FileRetentionValue | null\n }\n /** Legal hold status for this file version. */\n readonly legalHold: {\n /** Whether the caller is authorized to read legal hold status. */\n readonly isClientAuthorizedToRead: boolean\n /** Legal hold value, or null if the caller lacks read authorization. */\n readonly value: LegalHoldValue | null\n }\n /** Replication status, or null if replication is not configured. */\n readonly replicationStatus: 'pending' | 'completed' | 'failed' | 'replica' | null\n /** Server-side encryption settings applied to this file version. */\n readonly serverSideEncryption: PublicEncryptionSetting\n /** UTC timestamp (milliseconds) when this version was uploaded. */\n readonly uploadTimestamp: number\n}\n\n/** Request parameters for the `b2_list_file_names` API call. Lists the most recent version of each file in a bucket. */\nexport interface ListFileNamesRequest {\n /** Bucket to list files from. */\n readonly bucketId: BucketId\n /** Return files starting after this name (exclusive). Used for pagination. */\n readonly startFileName?: string\n /** Maximum number of files to return (1 to 10000). */\n readonly maxFileCount?: number\n /** Only return files whose names start with this prefix. */\n readonly prefix?: string\n /** Delimiter for virtual folder grouping (typically `'/'`). */\n readonly delimiter?: string\n}\n\n/** Response from the `b2_list_file_names` API call. */\nexport interface ListFileNamesResponse {\n /** Array of file versions matching the request. */\n readonly files: readonly FileVersion[]\n /** Next file name to use for pagination, or null if all files have been listed. */\n readonly nextFileName: string | null\n}\n\n/** Request parameters for the `b2_list_file_versions` API call. Lists all versions of files in a bucket. */\nexport interface ListFileVersionsRequest {\n /** Bucket to list file versions from. */\n readonly bucketId: BucketId\n /** Return files starting after this name (exclusive). Used for pagination. */\n readonly startFileName?: string\n /** Return file versions starting after this ID. Used with startFileName for pagination. */\n readonly startFileId?: FileId\n /** Maximum number of file versions to return (1 to 10000). */\n readonly maxFileCount?: number\n /** Only return files whose names start with this prefix. */\n readonly prefix?: string\n /** Delimiter for virtual folder grouping (typically `'/'`). */\n readonly delimiter?: string\n}\n\n/** Response from the `b2_list_file_versions` API call. */\nexport interface ListFileVersionsResponse {\n /** Array of file versions matching the request. */\n readonly files: readonly FileVersion[]\n /** Next file name to use for pagination, or null if all versions have been listed. */\n readonly nextFileName: string | null\n /** Next file ID to use for pagination, or null if all versions have been listed. */\n readonly nextFileId: FileId | null\n}\n\n/** Request parameters for the `b2_get_file_info` API call. */\nexport interface GetFileInfoRequest {\n /** ID of the file version to retrieve info for. */\n readonly fileId: FileId\n}\n\n/** Request parameters for the `b2_hide_file` API call. Hides a file so it no longer appears in `b2_list_file_names`. */\nexport interface HideFileRequest {\n /** Bucket containing the file to hide. */\n readonly bucketId: BucketId\n /** Name of the file to hide. */\n readonly fileName: string\n}\n\n/** Request parameters for the `b2_delete_file_version` API call. */\nexport interface DeleteFileVersionRequest {\n /** Name of the file version to delete. */\n readonly fileName: string\n /** ID of the file version to delete. */\n readonly fileId: FileId\n /** If true, bypass governance-mode retention. Requires the `bypassGovernance` capability. */\n readonly bypassGovernance?: boolean\n}\n\n/** Response from the `b2_delete_file_version` API call. */\nexport interface DeleteFileVersionResponse {\n /** ID of the deleted file version. */\n readonly fileId: FileId\n /** Name of the deleted file. */\n readonly fileName: string\n}\n\n/**\n * Named constants for how metadata is handled during a file copy.\n *\n * @example\n * ```ts\n * await bucket.copyFile({ ..., metadataDirective: MetadataDirective.Replace })\n * ```\n */\nexport const MetadataDirective = {\n /** Preserve the source file's contentType and fileInfo. */\n Copy: 'COPY',\n /** Use the values provided in the copy request. */\n Replace: 'REPLACE',\n} as const\n\n/** Controls how metadata is handled during a file copy. Derived from {@link MetadataDirective}. */\nexport type MetadataDirective = (typeof MetadataDirective)[keyof typeof MetadataDirective]\n\n/** Request parameters for the `b2_copy_file` API call. Performs a server-side file copy. */\nexport interface CopyFileRequest {\n /** ID of the source file version to copy from. */\n readonly sourceFileId: FileId\n /** Destination bucket ID. Defaults to the source bucket if omitted. */\n readonly destinationBucketId?: BucketId\n /** Name for the destination file. */\n readonly fileName: string\n /** Byte range to copy (e.g., `'bytes=0-999'`). Omit to copy the entire file. */\n readonly range?: string\n /** Whether to copy or replace the source file's metadata. */\n readonly metadataDirective?: MetadataDirective\n /** MIME type for the destination file (only used when metadataDirective is `'REPLACE'`). */\n readonly contentType?: string\n /** User-defined metadata for the destination file (only used when metadataDirective is `'REPLACE'`). */\n readonly fileInfo?: Record<string, string>\n /** Object Lock retention for the destination file. */\n readonly fileRetention?: FileRetentionValue\n /** Legal hold for the destination file. */\n readonly legalHold?: LegalHoldValue\n /** SSE-C settings for reading the source file, if the source is encrypted with SSE-C. */\n readonly sourceServerSideEncryption?: EncryptionSetting\n /** Server-side encryption to apply to the destination file. */\n readonly destinationServerSideEncryption?: EncryptionSetting\n}\n\n/** Request parameters for the `b2_copy_part` API call. Copies a byte range into a large file part. */\nexport interface CopyPartRequest {\n /** ID of the source file version to copy from. */\n readonly sourceFileId: FileId\n /** ID of the large file being assembled. */\n readonly largeFileId: FileId\n /** Part number (1-based) for this part within the large file. */\n readonly partNumber: number\n /** Byte range to copy from the source (e.g., `'bytes=0-999'`). Omit to copy the entire source. */\n readonly range?: string\n /** SSE-C settings for reading the source file, if the source is encrypted with SSE-C. */\n readonly sourceServerSideEncryption?: EncryptionSetting\n /** Server-side encryption to apply to the destination part. */\n readonly destinationServerSideEncryption?: EncryptionSetting\n}\n\n/** Response from the `b2_copy_part` API call. */\nexport interface CopyPartResponse {\n /** ID of the large file this part belongs to. */\n readonly fileId: FileId\n /** Part number within the large file. */\n readonly partNumber: number\n /** Size of the copied part in bytes. */\n readonly contentLength: number\n /** SHA-1 checksum of the copied part content. */\n readonly contentSha1: string\n}\n"],"mappings":";;;;;;;;;AAYA,IAAa,aAAa;;CAExB,OAAO;;CAEP,QAAQ;;CAER,MAAM;;CAEN,QAAQ;;CAER,MAAM;AACR;;;;;;;;;AAqJA,IAAa,oBAAoB;;CAE/B,MAAM;;CAEN,SAAS;AACX"}
1
+ {"version":3,"file":"file.js","names":[],"sources":["../../src/types/file.ts"],"sourcesContent":["import type { EncryptionSetting, PublicEncryptionSetting } from './encryption.ts'\nimport type { AccountId, BucketId, FileId } from './ids.ts'\nimport type { FileRetentionValue, LegalHoldValue } from './lock.ts'\n\n/**\n * Named constants for the action that created a file version.\n *\n * @example\n * ```ts\n * if (file.action === FileAction.Hide) { ... }\n * ```\n */\nexport const FileAction = {\n /** Large file upload started but not yet finished. */\n Start: 'start',\n /** Normal upload (small or finished large file). */\n Upload: 'upload',\n /** Hide marker (soft delete). */\n Hide: 'hide',\n /** Virtual folder marker. */\n Folder: 'folder',\n /** Created via server-side copy. */\n Copy: 'copy',\n} as const\n\n/**\n * The action that created a file version. Derived from {@link FileAction}.\n *\n * - `'start'`: large file upload started but not yet finished.\n * - `'upload'`: file was uploaded normally.\n * - `'hide'`: file was hidden (soft-deleted).\n * - `'folder'`: virtual folder marker.\n * - `'copy'`: file was created via server-side copy.\n */\nexport type FileAction = (typeof FileAction)[keyof typeof FileAction]\n\n/**\n * Replication status for a file version or unfinished large file.\n *\n * B2 returns these uppercase wire values as-is and omits the containing\n * `replicationStatus` field when the file is not covered by a replication rule.\n */\nexport type ReplicationStatus = 'PENDING' | 'COMPLETED' | 'FAILED' | 'REPLICA'\n\n/**\n * Complete metadata for a single file version in B2.\n * Returned by `b2_get_file_info`, `b2_list_file_names`, `b2_list_file_versions`,\n * `b2_upload_file`, `b2_copy_file`, and other file-related endpoints.\n */\nexport interface FileVersion {\n /** Account that owns this file. */\n readonly accountId: AccountId\n /** Action that created this file version. */\n readonly action: FileAction\n /** Bucket containing this file. */\n readonly bucketId: BucketId\n /** Size of the file content in bytes. */\n readonly contentLength: number\n /** MD5 checksum of the content, or null if not available. */\n readonly contentMd5: string | null\n /** SHA-1 checksum of the content, or null if not available (e.g., large files). */\n readonly contentSha1: string | null\n /** MIME type of the file content. */\n readonly contentType: string\n /** Unique identifier for this file version. */\n readonly fileId: FileId\n /** User-defined key-value metadata stored with the file. */\n readonly fileInfo: Record<string, string>\n /** Full path and name of the file within the bucket. */\n readonly fileName: string\n /** Object Lock retention settings for this file version. */\n readonly fileRetention: {\n /** Whether the caller is authorized to read retention settings. */\n readonly isClientAuthorizedToRead: boolean\n /** Retention settings, or null if the caller lacks read authorization. */\n readonly value: FileRetentionValue | null\n }\n /** Legal hold status for this file version. */\n readonly legalHold: {\n /** Whether the caller is authorized to read legal hold status. */\n readonly isClientAuthorizedToRead: boolean\n /** Legal hold value, or null if the caller lacks read authorization. */\n readonly value: LegalHoldValue | null\n }\n /** Replication status when this file is covered by a replication rule. */\n readonly replicationStatus?: ReplicationStatus\n /** Server-side encryption settings applied to this file version. */\n readonly serverSideEncryption: PublicEncryptionSetting\n /** UTC timestamp (milliseconds) when this version was uploaded. */\n readonly uploadTimestamp: number\n}\n\n/** Request parameters for the `b2_list_file_names` API call. Lists the most recent version of each file in a bucket. */\nexport interface ListFileNamesRequest {\n /** Bucket to list files from. */\n readonly bucketId: BucketId\n /** Return files starting after this name (exclusive). Used for pagination. */\n readonly startFileName?: string\n /** Maximum number of files to return (1 to 10000). */\n readonly maxFileCount?: number\n /** Only return files whose names start with this prefix. */\n readonly prefix?: string\n /** Delimiter for virtual folder grouping (typically `'/'`). */\n readonly delimiter?: string\n}\n\n/** Response from the `b2_list_file_names` API call. */\nexport interface ListFileNamesResponse {\n /** Array of file versions matching the request. */\n readonly files: readonly FileVersion[]\n /** Next file name to use for pagination, or null if all files have been listed. */\n readonly nextFileName: string | null\n}\n\n/** Request parameters for the `b2_list_file_versions` API call. Lists all versions of files in a bucket. */\nexport interface ListFileVersionsRequest {\n /** Bucket to list file versions from. */\n readonly bucketId: BucketId\n /** Return files starting after this name (exclusive). Used for pagination. */\n readonly startFileName?: string\n /** Return file versions starting after this ID. Used with startFileName for pagination. */\n readonly startFileId?: FileId\n /** Maximum number of file versions to return (1 to 10000). */\n readonly maxFileCount?: number\n /** Only return files whose names start with this prefix. */\n readonly prefix?: string\n /** Delimiter for virtual folder grouping (typically `'/'`). */\n readonly delimiter?: string\n}\n\n/** Response from the `b2_list_file_versions` API call. */\nexport interface ListFileVersionsResponse {\n /** Array of file versions matching the request. */\n readonly files: readonly FileVersion[]\n /** Next file name to use for pagination, or null if all versions have been listed. */\n readonly nextFileName: string | null\n /** Next file ID to use for pagination, or null if all versions have been listed. */\n readonly nextFileId: FileId | null\n}\n\n/** Request parameters for the `b2_get_file_info` API call. */\nexport interface GetFileInfoRequest {\n /** ID of the file version to retrieve info for. */\n readonly fileId: FileId\n}\n\n/** Request parameters for the `b2_hide_file` API call. Hides a file so it no longer appears in `b2_list_file_names`. */\nexport interface HideFileRequest {\n /** Bucket containing the file to hide. */\n readonly bucketId: BucketId\n /** Name of the file to hide. */\n readonly fileName: string\n}\n\n/** Request parameters for the `b2_delete_file_version` API call. */\nexport interface DeleteFileVersionRequest {\n /** Name of the file version to delete. */\n readonly fileName: string\n /** ID of the file version to delete. */\n readonly fileId: FileId\n /** If true, bypass governance-mode retention. Requires the `bypassGovernance` capability. */\n readonly bypassGovernance?: boolean\n}\n\n/** Response from the `b2_delete_file_version` API call. */\nexport interface DeleteFileVersionResponse {\n /** ID of the deleted file version. */\n readonly fileId: FileId\n /** Name of the deleted file. */\n readonly fileName: string\n}\n\n/**\n * Named constants for how metadata is handled during a file copy.\n *\n * @example\n * ```ts\n * await bucket.copyFile({ ..., metadataDirective: MetadataDirective.Replace })\n * ```\n */\nexport const MetadataDirective = {\n /** Preserve the source file's contentType and fileInfo. */\n Copy: 'COPY',\n /** Use the values provided in the copy request. */\n Replace: 'REPLACE',\n} as const\n\n/** Controls how metadata is handled during a file copy. Derived from {@link MetadataDirective}. */\nexport type MetadataDirective = (typeof MetadataDirective)[keyof typeof MetadataDirective]\n\n/** Request parameters for the `b2_copy_file` API call. Performs a server-side file copy. */\nexport interface CopyFileRequest {\n /** ID of the source file version to copy from. */\n readonly sourceFileId: FileId\n /** Destination bucket ID. Defaults to the source bucket if omitted. */\n readonly destinationBucketId?: BucketId\n /** Name for the destination file. */\n readonly fileName: string\n /** Byte range to copy (e.g., `'bytes=0-999'`). Omit to copy the entire file. */\n readonly range?: string\n /** Whether to copy or replace the source file's metadata. */\n readonly metadataDirective?: MetadataDirective\n /** MIME type for the destination file (only used when metadataDirective is `'REPLACE'`). */\n readonly contentType?: string\n /** User-defined metadata for the destination file (only used when metadataDirective is `'REPLACE'`). */\n readonly fileInfo?: Record<string, string>\n /** Object Lock retention for the destination file. */\n readonly fileRetention?: FileRetentionValue\n /** Legal hold for the destination file. */\n readonly legalHold?: LegalHoldValue\n /** SSE-C settings for reading the source file, if the source is encrypted with SSE-C. */\n readonly sourceServerSideEncryption?: EncryptionSetting\n /** Server-side encryption to apply to the destination file. */\n readonly destinationServerSideEncryption?: EncryptionSetting\n}\n\n/** Request parameters for the `b2_copy_part` API call. Copies a byte range into a large file part. */\nexport interface CopyPartRequest {\n /** ID of the source file version to copy from. */\n readonly sourceFileId: FileId\n /** ID of the large file being assembled. */\n readonly largeFileId: FileId\n /** Part number (1-based) for this part within the large file. */\n readonly partNumber: number\n /** Byte range to copy from the source (e.g., `'bytes=0-999'`). Omit to copy the entire source. */\n readonly range?: string\n /** SSE-C settings for reading the source file, if the source is encrypted with SSE-C. */\n readonly sourceServerSideEncryption?: EncryptionSetting\n /** Server-side encryption to apply to the destination part. */\n readonly destinationServerSideEncryption?: EncryptionSetting\n}\n\n/** Response from the `b2_copy_part` API call. */\nexport interface CopyPartResponse {\n /** ID of the large file this part belongs to. */\n readonly fileId: FileId\n /** Part number within the large file. */\n readonly partNumber: number\n /** Size of the copied part in bytes. */\n readonly contentLength: number\n /** SHA-1 checksum of the copied part content. */\n readonly contentSha1: string\n /** MD5 checksum of the copied part content, or null if not available. */\n readonly contentMd5: string | null\n /** Server-side encryption applied to this copied part. */\n readonly serverSideEncryption: PublicEncryptionSetting\n /** UTC timestamp (milliseconds) when this part was copied. */\n readonly uploadTimestamp: number\n}\n"],"mappings":";;;;;;;;;AAYA,IAAa,aAAa;;CAExB,OAAO;;CAEP,QAAQ;;CAER,MAAM;;CAEN,QAAQ;;CAER,MAAM;AACR;;;;;;;;;AA6JA,IAAa,oBAAoB;;CAE/B,MAAM;;CAEN,SAAS;AACX"}
@@ -45,6 +45,33 @@ function applicationKeyId(raw) {
45
45
  return raw;
46
46
  }
47
47
  /**
48
+ * Creates a branded {@link GroupId} from a raw string.
49
+ * @param raw - The raw group ID string from the Partner API.
50
+ *
51
+ * @returns A branded GroupId value.
52
+ */
53
+ function groupId(raw) {
54
+ return raw;
55
+ }
56
+ /**
57
+ * Creates a branded {@link ComputerId} from a raw string.
58
+ * @param raw - The raw computer ID string from the Computer Backup API.
59
+ *
60
+ * @returns A branded ComputerId value.
61
+ */
62
+ function computerId(raw) {
63
+ return raw;
64
+ }
65
+ /**
66
+ * Creates a branded {@link PartnerToken} from a raw authorization token string.
67
+ * @param raw - The raw Partner/Backup authorization token from the B2 API.
68
+ *
69
+ * @returns A branded PartnerToken value.
70
+ */
71
+ function partnerToken(raw) {
72
+ return raw;
73
+ }
74
+ /**
48
75
  * Creates a branded {@link LargeFileId} from a raw string.
49
76
  *
50
77
  * `LargeFileId` is the same wire-level shape as `FileId` but is a
@@ -64,8 +91,11 @@ function largeFileId(raw) {
64
91
  exports.accountId = accountId;
65
92
  exports.applicationKeyId = applicationKeyId;
66
93
  exports.bucketId = bucketId;
94
+ exports.computerId = computerId;
67
95
  exports.fileId = fileId;
96
+ exports.groupId = groupId;
68
97
  exports.keyId = keyId;
69
98
  exports.largeFileId = largeFileId;
99
+ exports.partnerToken = partnerToken;
70
100
 
71
101
  //# sourceMappingURL=ids.cjs.map
@@ -1 +1 @@
1
- {"version":3,"file":"ids.cjs","names":[],"sources":["../../src/types/ids.ts"],"sourcesContent":["/**\n * Unique symbol used to brand string types, preventing accidental mixing of different ID types.\n */\ndeclare const __brand: unique symbol\n\n/** Compile-time brand tag interface. Never instantiated at runtime. */\nexport interface BrandTag<B extends string> {\n /** Discriminant tag that makes branded types structurally incompatible. */\n readonly [__brand]: B\n}\n\n/**\n * Utility type that intersects a base type with a branded tag.\n * This pattern ensures that branded types are structurally incompatible with each other\n * even though they share the same underlying representation.\n */\nexport type Brand<T, B extends string> = T & BrandTag<B>\n\n/** Unique identifier for a B2 account. Branded to prevent mixing with other string IDs. */\nexport type AccountId = Brand<string, 'AccountId'>\n\n/** Unique identifier for a B2 bucket. Branded to prevent mixing with other string IDs. */\nexport type BucketId = Brand<string, 'BucketId'>\n\n/** Unique identifier for a B2 file version. Branded to prevent mixing with other string IDs. */\nexport type FileId = Brand<string, 'FileId'>\n\n/** Unique identifier for a B2 application key. Branded to prevent mixing with other string IDs. */\nexport type KeyId = Brand<string, 'KeyId'>\n\n/** Unique identifier for a B2 application key, as returned by the API. Branded to prevent mixing with other string IDs. */\nexport type ApplicationKeyId = Brand<string, 'ApplicationKeyId'>\n\n/** Pre-signed URL for uploading files to a specific bucket. Branded to prevent misuse as a regular string. */\nexport type UploadUrl = Brand<string, 'UploadUrl'>\n\n/** Authorization token scoped to a specific upload URL. Branded to prevent mixing with other tokens. */\nexport type UploadAuthToken = Brand<string, 'UploadAuthToken'>\n\n/** Authorization token for B2 API requests. Branded to prevent mixing with other string values. */\nexport type AuthToken = Brand<string, 'AuthToken'>\n\n/** Unique identifier for a large file upload in progress. Branded to prevent mixing with regular FileId values. */\nexport type LargeFileId = Brand<string, 'LargeFileId'>\n\n/**\n * Creates a branded {@link AccountId} from a raw string.\n * @param raw - The raw account ID string from the B2 API.\n *\n * @returns A branded AccountId value.\n */\nexport function accountId(raw: string): AccountId {\n return raw as AccountId\n}\n\n/**\n * Creates a branded {@link BucketId} from a raw string.\n * @param raw - The raw bucket ID string from the B2 API.\n *\n * @returns A branded BucketId value.\n */\nexport function bucketId(raw: string): BucketId {\n return raw as BucketId\n}\n\n/**\n * Creates a branded {@link FileId} from a raw string.\n * @param raw - The raw file ID string from the B2 API.\n *\n * @returns A branded FileId value.\n */\nexport function fileId(raw: string): FileId {\n return raw as FileId\n}\n\n/**\n * Creates a branded {@link KeyId} from a raw string.\n * @param raw - The raw key ID string from the B2 API.\n *\n * @returns A branded KeyId value.\n */\nexport function keyId(raw: string): KeyId {\n return raw as KeyId\n}\n\n/**\n * Creates a branded {@link ApplicationKeyId} from a raw string.\n * @param raw - The raw application key ID string from the B2 API.\n *\n * @returns A branded ApplicationKeyId value.\n */\nexport function applicationKeyId(raw: string): ApplicationKeyId {\n return raw as ApplicationKeyId\n}\n\n/**\n * Creates a branded {@link LargeFileId} from a raw string.\n *\n * `LargeFileId` is the same wire-level shape as `FileId` but is a\n * distinct brand so that \"ID of an in-progress multipart upload\" and\n * \"ID of a committed file version\" don't get mixed up by accident.\n * `b2_start_large_file` returns one; `b2_finish_large_file` consumes it\n * and produces a regular `FileId`.\n *\n * @param raw - The raw large-file ID string from the B2 API.\n *\n * @returns A branded LargeFileId value.\n */\nexport function largeFileId(raw: string): LargeFileId {\n return raw as LargeFileId\n}\n"],"mappings":";;;;;;;AAmDA,SAAgB,UAAU,KAAwB;CAChD,OAAO;AACT;;;;;;;AAQA,SAAgB,SAAS,KAAuB;CAC9C,OAAO;AACT;;;;;;;AAQA,SAAgB,OAAO,KAAqB;CAC1C,OAAO;AACT;;;;;;;AAQA,SAAgB,MAAM,KAAoB;CACxC,OAAO;AACT;;;;;;;AAQA,SAAgB,iBAAiB,KAA+B;CAC9D,OAAO;AACT;;;;;;;;;;;;;;AAeA,SAAgB,YAAY,KAA0B;CACpD,OAAO;AACT"}
1
+ {"version":3,"file":"ids.cjs","names":[],"sources":["../../src/types/ids.ts"],"sourcesContent":["/**\n * Unique symbol used to brand string types, preventing accidental mixing of different ID types.\n */\ndeclare const __brand: unique symbol\n\n/** Compile-time brand tag interface. Never instantiated at runtime. */\nexport interface BrandTag<B extends string> {\n /** Discriminant tag that makes branded types structurally incompatible. */\n readonly [__brand]: B\n}\n\n/**\n * Utility type that intersects a base type with a branded tag.\n * This pattern ensures that branded types are structurally incompatible with each other\n * even though they share the same underlying representation.\n */\nexport type Brand<T, B extends string> = T & BrandTag<B>\n\n/** Unique identifier for a B2 account. Branded to prevent mixing with other string IDs. */\nexport type AccountId = Brand<string, 'AccountId'>\n\n/** Unique identifier for a B2 bucket. Branded to prevent mixing with other string IDs. */\nexport type BucketId = Brand<string, 'BucketId'>\n\n/** Unique identifier for a B2 file version. Branded to prevent mixing with other string IDs. */\nexport type FileId = Brand<string, 'FileId'>\n\n/** Unique identifier for a B2 application key. Branded to prevent mixing with other string IDs. */\nexport type KeyId = Brand<string, 'KeyId'>\n\n/** Unique identifier for a B2 application key, as returned by the API. Branded to prevent mixing with other string IDs. */\nexport type ApplicationKeyId = Brand<string, 'ApplicationKeyId'>\n\n/**\n * Unique identifier for a Partner API group. Branded to prevent mixing with other string IDs.\n *\n * Group IDs look numeric in some examples, but the Partner API returns them\n * as JSON strings. The SDK preserves the wire value as a branded string.\n */\nexport type GroupId = Brand<string, 'GroupId'>\n\n/** Unique identifier for a Computer Backup computer. Branded to prevent mixing with other string IDs. */\nexport type ComputerId = Brand<string, 'ComputerId'>\n\n/** Pre-signed URL for uploading files to a specific bucket. Branded to prevent misuse as a regular string. */\nexport type UploadUrl = Brand<string, 'UploadUrl'>\n\n/** Authorization token scoped to a specific upload URL. Branded to prevent mixing with other tokens. */\nexport type UploadAuthToken = Brand<string, 'UploadAuthToken'>\n\n/** Authorization token for B2 API requests. Branded to prevent mixing with other string values. */\nexport type AuthToken = Brand<string, 'AuthToken'>\n\n/** Authorization token for Partner API and Computer Backup API requests. */\nexport type PartnerToken = Brand<string, 'PartnerToken'>\n\n/** Unique identifier for a large file upload in progress. Branded to prevent mixing with regular FileId values. */\nexport type LargeFileId = Brand<string, 'LargeFileId'>\n\n/**\n * Creates a branded {@link AccountId} from a raw string.\n * @param raw - The raw account ID string from the B2 API.\n *\n * @returns A branded AccountId value.\n */\nexport function accountId(raw: string): AccountId {\n return raw as AccountId\n}\n\n/**\n * Creates a branded {@link BucketId} from a raw string.\n * @param raw - The raw bucket ID string from the B2 API.\n *\n * @returns A branded BucketId value.\n */\nexport function bucketId(raw: string): BucketId {\n return raw as BucketId\n}\n\n/**\n * Creates a branded {@link FileId} from a raw string.\n * @param raw - The raw file ID string from the B2 API.\n *\n * @returns A branded FileId value.\n */\nexport function fileId(raw: string): FileId {\n return raw as FileId\n}\n\n/**\n * Creates a branded {@link KeyId} from a raw string.\n * @param raw - The raw key ID string from the B2 API.\n *\n * @returns A branded KeyId value.\n */\nexport function keyId(raw: string): KeyId {\n return raw as KeyId\n}\n\n/**\n * Creates a branded {@link ApplicationKeyId} from a raw string.\n * @param raw - The raw application key ID string from the B2 API.\n *\n * @returns A branded ApplicationKeyId value.\n */\nexport function applicationKeyId(raw: string): ApplicationKeyId {\n return raw as ApplicationKeyId\n}\n\n/**\n * Creates a branded {@link GroupId} from a raw string.\n * @param raw - The raw group ID string from the Partner API.\n *\n * @returns A branded GroupId value.\n */\nexport function groupId(raw: string): GroupId {\n return raw as GroupId\n}\n\n/**\n * Creates a branded {@link ComputerId} from a raw string.\n * @param raw - The raw computer ID string from the Computer Backup API.\n *\n * @returns A branded ComputerId value.\n */\nexport function computerId(raw: string): ComputerId {\n return raw as ComputerId\n}\n\n/**\n * Creates a branded {@link PartnerToken} from a raw authorization token string.\n * @param raw - The raw Partner/Backup authorization token from the B2 API.\n *\n * @returns A branded PartnerToken value.\n */\nexport function partnerToken(raw: string): PartnerToken {\n return raw as PartnerToken\n}\n\n/**\n * Creates a branded {@link LargeFileId} from a raw string.\n *\n * `LargeFileId` is the same wire-level shape as `FileId` but is a\n * distinct brand so that \"ID of an in-progress multipart upload\" and\n * \"ID of a committed file version\" don't get mixed up by accident.\n * `b2_start_large_file` returns one; `b2_finish_large_file` consumes it\n * and produces a regular `FileId`.\n *\n * @param raw - The raw large-file ID string from the B2 API.\n *\n * @returns A branded LargeFileId value.\n */\nexport function largeFileId(raw: string): LargeFileId {\n return raw as LargeFileId\n}\n"],"mappings":";;;;;;;AAiEA,SAAgB,UAAU,KAAwB;CAChD,OAAO;AACT;;;;;;;AAQA,SAAgB,SAAS,KAAuB;CAC9C,OAAO;AACT;;;;;;;AAQA,SAAgB,OAAO,KAAqB;CAC1C,OAAO;AACT;;;;;;;AAQA,SAAgB,MAAM,KAAoB;CACxC,OAAO;AACT;;;;;;;AAQA,SAAgB,iBAAiB,KAA+B;CAC9D,OAAO;AACT;;;;;;;AAQA,SAAgB,QAAQ,KAAsB;CAC5C,OAAO;AACT;;;;;;;AAQA,SAAgB,WAAW,KAAyB;CAClD,OAAO;AACT;;;;;;;AAQA,SAAgB,aAAa,KAA2B;CACtD,OAAO;AACT;;;;;;;;;;;;;;AAeA,SAAgB,YAAY,KAA0B;CACpD,OAAO;AACT"}
@@ -23,12 +23,23 @@ export type FileId = Brand<string, 'FileId'>;
23
23
  export type KeyId = Brand<string, 'KeyId'>;
24
24
  /** Unique identifier for a B2 application key, as returned by the API. Branded to prevent mixing with other string IDs. */
25
25
  export type ApplicationKeyId = Brand<string, 'ApplicationKeyId'>;
26
+ /**
27
+ * Unique identifier for a Partner API group. Branded to prevent mixing with other string IDs.
28
+ *
29
+ * Group IDs look numeric in some examples, but the Partner API returns them
30
+ * as JSON strings. The SDK preserves the wire value as a branded string.
31
+ */
32
+ export type GroupId = Brand<string, 'GroupId'>;
33
+ /** Unique identifier for a Computer Backup computer. Branded to prevent mixing with other string IDs. */
34
+ export type ComputerId = Brand<string, 'ComputerId'>;
26
35
  /** Pre-signed URL for uploading files to a specific bucket. Branded to prevent misuse as a regular string. */
27
36
  export type UploadUrl = Brand<string, 'UploadUrl'>;
28
37
  /** Authorization token scoped to a specific upload URL. Branded to prevent mixing with other tokens. */
29
38
  export type UploadAuthToken = Brand<string, 'UploadAuthToken'>;
30
39
  /** Authorization token for B2 API requests. Branded to prevent mixing with other string values. */
31
40
  export type AuthToken = Brand<string, 'AuthToken'>;
41
+ /** Authorization token for Partner API and Computer Backup API requests. */
42
+ export type PartnerToken = Brand<string, 'PartnerToken'>;
32
43
  /** Unique identifier for a large file upload in progress. Branded to prevent mixing with regular FileId values. */
33
44
  export type LargeFileId = Brand<string, 'LargeFileId'>;
34
45
  /**
@@ -66,6 +77,27 @@ export declare function keyId(raw: string): KeyId;
66
77
  * @returns A branded ApplicationKeyId value.
67
78
  */
68
79
  export declare function applicationKeyId(raw: string): ApplicationKeyId;
80
+ /**
81
+ * Creates a branded {@link GroupId} from a raw string.
82
+ * @param raw - The raw group ID string from the Partner API.
83
+ *
84
+ * @returns A branded GroupId value.
85
+ */
86
+ export declare function groupId(raw: string): GroupId;
87
+ /**
88
+ * Creates a branded {@link ComputerId} from a raw string.
89
+ * @param raw - The raw computer ID string from the Computer Backup API.
90
+ *
91
+ * @returns A branded ComputerId value.
92
+ */
93
+ export declare function computerId(raw: string): ComputerId;
94
+ /**
95
+ * Creates a branded {@link PartnerToken} from a raw authorization token string.
96
+ * @param raw - The raw Partner/Backup authorization token from the B2 API.
97
+ *
98
+ * @returns A branded PartnerToken value.
99
+ */
100
+ export declare function partnerToken(raw: string): PartnerToken;
69
101
  /**
70
102
  * Creates a branded {@link LargeFileId} from a raw string.
71
103
  *
@@ -1 +1 @@
1
- {"version":3,"file":"ids.d.ts","sourceRoot":"","sources":["../../src/types/ids.js"],"names":[],"mappings":"AAAA;;GAEG;AACH,OAAO,CAAC,MAAM,OAAO,EAAE,OAAO,MAAM,CAAA;AAEpC,uEAAuE;AACvE,MAAM,WAAW,QAAQ,CAAC,CAAC,SAAS,MAAM;IACxC,2EAA2E;IAC3E,QAAQ,CAAC,CAAC,OAAO,CAAC,EAAE,CAAC,CAAA;CACtB;AAED;;;;GAIG;AACH,MAAM,MAAM,KAAK,CAAC,CAAC,EAAE,CAAC,SAAS,MAAM,IAAI,CAAC,GAAG,QAAQ,CAAC,CAAC,CAAC,CAAA;AAExD,2FAA2F;AAC3F,MAAM,MAAM,SAAS,GAAG,KAAK,CAAC,MAAM,EAAE,WAAW,CAAC,CAAA;AAElD,0FAA0F;AAC1F,MAAM,MAAM,QAAQ,GAAG,KAA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AAM,MAAM,YAAY,GAAG,KAAK,CAAC,MAAM,EAAE,cAAc,CAAC,CAAA;AAExD,mHAAmH;AACnH,MAAM,MAAM,WAAW,GAAG,KAAK,CAAC,MAAM,EAAE,aAAa,CAAC,CAAA;AAEtD;;;;;GAKG;AACH,wBAAgB,SAAS,CAAC,GAAG,EAAE,MAAM,GAAG,SAAS,CAEhD;AAED;;;;;GAKG;AACH,wBAAgB,QAAQ,CAAC,GAAG,EAAE,MAAM,GAAG,QAAQ,CAE9C;AAED;;;;;GAKG;AACH,wBAAgB,MAAM,CAAC,GAAG,EAAE,MAAM,GAAG,MAAM,CAE1C;AAED;;;;;GAKG;AACH,wBAAgB,KAAK,CAAC,GAAG,EAAE,MAAM,GAAG,KAAK,CAExC;AAED;;;;;GAKG;AACH,wBAAgB,gBAAgB,CAAC,GAAG,EAAE,MAAM,GAAG,gBAAgB,CAE9D;AAED;;;;;GAKG;AACH,wBAAgB,OAAO,CAAC,GAAG,EAAE,MAAM,GAAG,OAAO,CAE5C;AAED;;;;;GAKG;AACH,wBAAgB,UAAU,CAAC,GAAG,EAAE,MAAM,GAAG,UAAU,CAElD;AAED;;;;;GAKG;AACH,wBAAgB,YAAY,CAAC,GAAG,EAAE,MAAM,GAAG,YAAY,CAEtD;AAED;;;;;;;;;;;;GAYG;AACH,wBAAgB,WAAW,CAAC,GAAG,EAAE,MAAM,GAAG,WAAW,CAEpD"}
@@ -23,12 +23,23 @@ export type FileId = Brand<string, 'FileId'>;
23
23
  export type KeyId = Brand<string, 'KeyId'>;
24
24
  /** Unique identifier for a B2 application key, as returned by the API. Branded to prevent mixing with other string IDs. */
25
25
  export type ApplicationKeyId = Brand<string, 'ApplicationKeyId'>;
26
+ /**
27
+ * Unique identifier for a Partner API group. Branded to prevent mixing with other string IDs.
28
+ *
29
+ * Group IDs look numeric in some examples, but the Partner API returns them
30
+ * as JSON strings. The SDK preserves the wire value as a branded string.
31
+ */
32
+ export type GroupId = Brand<string, 'GroupId'>;
33
+ /** Unique identifier for a Computer Backup computer. Branded to prevent mixing with other string IDs. */
34
+ export type ComputerId = Brand<string, 'ComputerId'>;
26
35
  /** Pre-signed URL for uploading files to a specific bucket. Branded to prevent misuse as a regular string. */
27
36
  export type UploadUrl = Brand<string, 'UploadUrl'>;
28
37
  /** Authorization token scoped to a specific upload URL. Branded to prevent mixing with other tokens. */
29
38
  export type UploadAuthToken = Brand<string, 'UploadAuthToken'>;
30
39
  /** Authorization token for B2 API requests. Branded to prevent mixing with other string values. */
31
40
  export type AuthToken = Brand<string, 'AuthToken'>;
41
+ /** Authorization token for Partner API and Computer Backup API requests. */
42
+ export type PartnerToken = Brand<string, 'PartnerToken'>;
32
43
  /** Unique identifier for a large file upload in progress. Branded to prevent mixing with regular FileId values. */
33
44
  export type LargeFileId = Brand<string, 'LargeFileId'>;
34
45
  /**
@@ -66,6 +77,27 @@ export declare function keyId(raw: string): KeyId;
66
77
  * @returns A branded ApplicationKeyId value.
67
78
  */
68
79
  export declare function applicationKeyId(raw: string): ApplicationKeyId;
80
+ /**
81
+ * Creates a branded {@link GroupId} from a raw string.
82
+ * @param raw - The raw group ID string from the Partner API.
83
+ *
84
+ * @returns A branded GroupId value.
85
+ */
86
+ export declare function groupId(raw: string): GroupId;
87
+ /**
88
+ * Creates a branded {@link ComputerId} from a raw string.
89
+ * @param raw - The raw computer ID string from the Computer Backup API.
90
+ *
91
+ * @returns A branded ComputerId value.
92
+ */
93
+ export declare function computerId(raw: string): ComputerId;
94
+ /**
95
+ * Creates a branded {@link PartnerToken} from a raw authorization token string.
96
+ * @param raw - The raw Partner/Backup authorization token from the B2 API.
97
+ *
98
+ * @returns A branded PartnerToken value.
99
+ */
100
+ export declare function partnerToken(raw: string): PartnerToken;
69
101
  /**
70
102
  * Creates a branded {@link LargeFileId} from a raw string.
71
103
  *
@@ -1 +1 @@
1
- {"version":3,"file":"ids.d.ts","sourceRoot":"","sources":["../../src/types/ids.js"],"names":[],"mappings":"AAAA;;GAEG;AACH,OAAO,CA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;;;;;;;;;;;GAYG;AACH,wBAAgB,WAAW,CAAC,GAAG,EAAE,MAAM,GAAG,WAAW,CAEpD"}
package/dist/types/ids.js CHANGED
@@ -45,6 +45,33 @@ function applicationKeyId(raw) {
45
45
  return raw;
46
46
  }
47
47
  /**
48
+ * Creates a branded {@link GroupId} from a raw string.
49
+ * @param raw - The raw group ID string from the Partner API.
50
+ *
51
+ * @returns A branded GroupId value.
52
+ */
53
+ function groupId(raw) {
54
+ return raw;
55
+ }
56
+ /**
57
+ * Creates a branded {@link ComputerId} from a raw string.
58
+ * @param raw - The raw computer ID string from the Computer Backup API.
59
+ *
60
+ * @returns A branded ComputerId value.
61
+ */
62
+ function computerId(raw) {
63
+ return raw;
64
+ }
65
+ /**
66
+ * Creates a branded {@link PartnerToken} from a raw authorization token string.
67
+ * @param raw - The raw Partner/Backup authorization token from the B2 API.
68
+ *
69
+ * @returns A branded PartnerToken value.
70
+ */
71
+ function partnerToken(raw) {
72
+ return raw;
73
+ }
74
+ /**
48
75
  * Creates a branded {@link LargeFileId} from a raw string.
49
76
  *
50
77
  * `LargeFileId` is the same wire-level shape as `FileId` but is a
@@ -61,6 +88,6 @@ function largeFileId(raw) {
61
88
  return raw;
62
89
  }
63
90
  //#endregion
64
- export { accountId, applicationKeyId, bucketId, fileId, keyId, largeFileId };
91
+ export { accountId, applicationKeyId, bucketId, computerId, fileId, groupId, keyId, largeFileId, partnerToken };
65
92
 
66
93
  //# sourceMappingURL=ids.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"ids.js","names":[],"sources":["../../src/types/ids.ts"],"sourcesContent":["/**\n * Unique symbol used to brand string types, preventing accidental mixing of different ID types.\n */\ndeclare const __brand: unique symbol\n\n/** Compile-time brand tag interface. Never instantiated at runtime. */\nexport interface BrandTag<B extends string> {\n /** Discriminant tag that makes branded types structurally incompatible. */\n readonly [__brand]: B\n}\n\n/**\n * Utility type that intersects a base type with a branded tag.\n * This pattern ensures that branded types are structurally incompatible with each other\n * even though they share the same underlying representation.\n */\nexport type Brand<T, B extends string> = T & BrandTag<B>\n\n/** Unique identifier for a B2 account. Branded to prevent mixing with other string IDs. */\nexport type AccountId = Brand<string, 'AccountId'>\n\n/** Unique identifier for a B2 bucket. Branded to prevent mixing with other string IDs. */\nexport type BucketId = Brand<string, 'BucketId'>\n\n/** Unique identifier for a B2 file version. Branded to prevent mixing with other string IDs. */\nexport type FileId = Brand<string, 'FileId'>\n\n/** Unique identifier for a B2 application key. Branded to prevent mixing with other string IDs. */\nexport type KeyId = Brand<string, 'KeyId'>\n\n/** Unique identifier for a B2 application key, as returned by the API. Branded to prevent mixing with other string IDs. */\nexport type ApplicationKeyId = Brand<string, 'ApplicationKeyId'>\n\n/** Pre-signed URL for uploading files to a specific bucket. Branded to prevent misuse as a regular string. */\nexport type UploadUrl = Brand<string, 'UploadUrl'>\n\n/** Authorization token scoped to a specific upload URL. Branded to prevent mixing with other tokens. */\nexport type UploadAuthToken = Brand<string, 'UploadAuthToken'>\n\n/** Authorization token for B2 API requests. Branded to prevent mixing with other string values. */\nexport type AuthToken = Brand<string, 'AuthToken'>\n\n/** Unique identifier for a large file upload in progress. Branded to prevent mixing with regular FileId values. */\nexport type LargeFileId = Brand<string, 'LargeFileId'>\n\n/**\n * Creates a branded {@link AccountId} from a raw string.\n * @param raw - The raw account ID string from the B2 API.\n *\n * @returns A branded AccountId value.\n */\nexport function accountId(raw: string): AccountId {\n return raw as AccountId\n}\n\n/**\n * Creates a branded {@link BucketId} from a raw string.\n * @param raw - The raw bucket ID string from the B2 API.\n *\n * @returns A branded BucketId value.\n */\nexport function bucketId(raw: string): BucketId {\n return raw as BucketId\n}\n\n/**\n * Creates a branded {@link FileId} from a raw string.\n * @param raw - The raw file ID string from the B2 API.\n *\n * @returns A branded FileId value.\n */\nexport function fileId(raw: string): FileId {\n return raw as FileId\n}\n\n/**\n * Creates a branded {@link KeyId} from a raw string.\n * @param raw - The raw key ID string from the B2 API.\n *\n * @returns A branded KeyId value.\n */\nexport function keyId(raw: string): KeyId {\n return raw as KeyId\n}\n\n/**\n * Creates a branded {@link ApplicationKeyId} from a raw string.\n * @param raw - The raw application key ID string from the B2 API.\n *\n * @returns A branded ApplicationKeyId value.\n */\nexport function applicationKeyId(raw: string): ApplicationKeyId {\n return raw as ApplicationKeyId\n}\n\n/**\n * Creates a branded {@link LargeFileId} from a raw string.\n *\n * `LargeFileId` is the same wire-level shape as `FileId` but is a\n * distinct brand so that \"ID of an in-progress multipart upload\" and\n * \"ID of a committed file version\" don't get mixed up by accident.\n * `b2_start_large_file` returns one; `b2_finish_large_file` consumes it\n * and produces a regular `FileId`.\n *\n * @param raw - The raw large-file ID string from the B2 API.\n *\n * @returns A branded LargeFileId value.\n */\nexport function largeFileId(raw: string): LargeFileId {\n return raw as LargeFileId\n}\n"],"mappings":";;;;;;;AAmDA,SAAgB,UAAU,KAAwB;CAChD,OAAO;AACT;;;;;;;AAQA,SAAgB,SAAS,KAAuB;CAC9C,OAAO;AACT;;;;;;;AAQA,SAAgB,OAAO,KAAqB;CAC1C,OAAO;AACT;;;;;;;AAQA,SAAgB,MAAM,KAAoB;CACxC,OAAO;AACT;;;;;;;AAQA,SAAgB,iBAAiB,KAA+B;CAC9D,OAAO;AACT;;;;;;;;;;;;;;AAeA,SAAgB,YAAY,KAA0B;CACpD,OAAO;AACT"}
1
+ {"version":3,"file":"ids.js","names":[],"sources":["../../src/types/ids.ts"],"sourcesContent":["/**\n * Unique symbol used to brand string types, preventing accidental mixing of different ID types.\n */\ndeclare const __brand: unique symbol\n\n/** Compile-time brand tag interface. Never instantiated at runtime. */\nexport interface BrandTag<B extends string> {\n /** Discriminant tag that makes branded types structurally incompatible. */\n readonly [__brand]: B\n}\n\n/**\n * Utility type that intersects a base type with a branded tag.\n * This pattern ensures that branded types are structurally incompatible with each other\n * even though they share the same underlying representation.\n */\nexport type Brand<T, B extends string> = T & BrandTag<B>\n\n/** Unique identifier for a B2 account. Branded to prevent mixing with other string IDs. */\nexport type AccountId = Brand<string, 'AccountId'>\n\n/** Unique identifier for a B2 bucket. Branded to prevent mixing with other string IDs. */\nexport type BucketId = Brand<string, 'BucketId'>\n\n/** Unique identifier for a B2 file version. Branded to prevent mixing with other string IDs. */\nexport type FileId = Brand<string, 'FileId'>\n\n/** Unique identifier for a B2 application key. Branded to prevent mixing with other string IDs. */\nexport type KeyId = Brand<string, 'KeyId'>\n\n/** Unique identifier for a B2 application key, as returned by the API. Branded to prevent mixing with other string IDs. */\nexport type ApplicationKeyId = Brand<string, 'ApplicationKeyId'>\n\n/**\n * Unique identifier for a Partner API group. Branded to prevent mixing with other string IDs.\n *\n * Group IDs look numeric in some examples, but the Partner API returns them\n * as JSON strings. The SDK preserves the wire value as a branded string.\n */\nexport type GroupId = Brand<string, 'GroupId'>\n\n/** Unique identifier for a Computer Backup computer. Branded to prevent mixing with other string IDs. */\nexport type ComputerId = Brand<string, 'ComputerId'>\n\n/** Pre-signed URL for uploading files to a specific bucket. Branded to prevent misuse as a regular string. */\nexport type UploadUrl = Brand<string, 'UploadUrl'>\n\n/** Authorization token scoped to a specific upload URL. Branded to prevent mixing with other tokens. */\nexport type UploadAuthToken = Brand<string, 'UploadAuthToken'>\n\n/** Authorization token for B2 API requests. Branded to prevent mixing with other string values. */\nexport type AuthToken = Brand<string, 'AuthToken'>\n\n/** Authorization token for Partner API and Computer Backup API requests. */\nexport type PartnerToken = Brand<string, 'PartnerToken'>\n\n/** Unique identifier for a large file upload in progress. Branded to prevent mixing with regular FileId values. */\nexport type LargeFileId = Brand<string, 'LargeFileId'>\n\n/**\n * Creates a branded {@link AccountId} from a raw string.\n * @param raw - The raw account ID string from the B2 API.\n *\n * @returns A branded AccountId value.\n */\nexport function accountId(raw: string): AccountId {\n return raw as AccountId\n}\n\n/**\n * Creates a branded {@link BucketId} from a raw string.\n * @param raw - The raw bucket ID string from the B2 API.\n *\n * @returns A branded BucketId value.\n */\nexport function bucketId(raw: string): BucketId {\n return raw as BucketId\n}\n\n/**\n * Creates a branded {@link FileId} from a raw string.\n * @param raw - The raw file ID string from the B2 API.\n *\n * @returns A branded FileId value.\n */\nexport function fileId(raw: string): FileId {\n return raw as FileId\n}\n\n/**\n * Creates a branded {@link KeyId} from a raw string.\n * @param raw - The raw key ID string from the B2 API.\n *\n * @returns A branded KeyId value.\n */\nexport function keyId(raw: string): KeyId {\n return raw as KeyId\n}\n\n/**\n * Creates a branded {@link ApplicationKeyId} from a raw string.\n * @param raw - The raw application key ID string from the B2 API.\n *\n * @returns A branded ApplicationKeyId value.\n */\nexport function applicationKeyId(raw: string): ApplicationKeyId {\n return raw as ApplicationKeyId\n}\n\n/**\n * Creates a branded {@link GroupId} from a raw string.\n * @param raw - The raw group ID string from the Partner API.\n *\n * @returns A branded GroupId value.\n */\nexport function groupId(raw: string): GroupId {\n return raw as GroupId\n}\n\n/**\n * Creates a branded {@link ComputerId} from a raw string.\n * @param raw - The raw computer ID string from the Computer Backup API.\n *\n * @returns A branded ComputerId value.\n */\nexport function computerId(raw: string): ComputerId {\n return raw as ComputerId\n}\n\n/**\n * Creates a branded {@link PartnerToken} from a raw authorization token string.\n * @param raw - The raw Partner/Backup authorization token from the B2 API.\n *\n * @returns A branded PartnerToken value.\n */\nexport function partnerToken(raw: string): PartnerToken {\n return raw as PartnerToken\n}\n\n/**\n * Creates a branded {@link LargeFileId} from a raw string.\n *\n * `LargeFileId` is the same wire-level shape as `FileId` but is a\n * distinct brand so that \"ID of an in-progress multipart upload\" and\n * \"ID of a committed file version\" don't get mixed up by accident.\n * `b2_start_large_file` returns one; `b2_finish_large_file` consumes it\n * and produces a regular `FileId`.\n *\n * @param raw - The raw large-file ID string from the B2 API.\n *\n * @returns A branded LargeFileId value.\n */\nexport function largeFileId(raw: string): LargeFileId {\n return raw as LargeFileId\n}\n"],"mappings":";;;;;;;AAiEA,SAAgB,UAAU,KAAwB;CAChD,OAAO;AACT;;;;;;;AAQA,SAAgB,SAAS,KAAuB;CAC9C,OAAO;AACT;;;;;;;AAQA,SAAgB,OAAO,KAAqB;CAC1C,OAAO;AACT;;;;;;;AAQA,SAAgB,MAAM,KAAoB;CACxC,OAAO;AACT;;;;;;;AAQA,SAAgB,iBAAiB,KAA+B;CAC9D,OAAO;AACT;;;;;;;AAQA,SAAgB,QAAQ,KAAsB;CAC5C,OAAO;AACT;;;;;;;AAQA,SAAgB,WAAW,KAAyB;CAClD,OAAO;AACT;;;;;;;AAQA,SAAgB,aAAa,KAA2B;CACtD,OAAO;AACT;;;;;;;;;;;;;;AAeA,SAAgB,YAAY,KAA0B;CACpD,OAAO;AACT"}
@@ -5,22 +5,26 @@
5
5
  */
6
6
  export type { AllowedBucket, AllowedInfo, ApiInfo, AuthorizeAccountRequest, AuthorizeAccountResponse, GroupsApiInfo, StorageApiInfo, } from './auth.js';
7
7
  export { Capability } from './auth.js';
8
+ export type { ComputerBackup, DeleteComputerRequest, DeleteComputerResponse, DeleteComputerResult, ListComputersRequest, ListComputersResponse, ListComputersResult, } from './backup.js';
8
9
  export type { BucketInfo, BucketRetentionPolicy, CorsRule, CreateBucketRequest, DeleteBucketRequest, LifecycleRule, ListBucketsRequest, ListBucketsResponse, RetentionPeriod, UpdateBucketRequest, } from './bucket.js';
9
10
  export { BucketRetentionMode, BucketType, CorsOperation } from './bucket.js';
10
- export type { DownloadAuthorizationRequest, DownloadAuthorizationResponse, DownloadByIdRequest, DownloadByNameRequest, DownloadHeaders, } from './download.js';
11
+ export type { DownloadAuthorizationRequest, DownloadAuthorizationResponse, DownloadByIdRequest, DownloadByNameRequest, DownloadHeaderParseIssue, DownloadHeaders, DownloadServerSideEncryption, SseCDownloadSetting, } from './download.js';
12
+ export { DownloadClientUnauthorizedToReadMarker, DownloadHeaderName } from './download.js';
11
13
  export type { EncryptionSetting, NoEncryption, NoEncryptionWireSetting, PublicEncryptionSetting, SseB2Setting, SseCCustomerSetting, SseCPublicSetting, } from './encryption.js';
12
14
  export { EncryptionAlgorithm, EncryptionKey, EncryptionMode, SSE_B2, SSE_NONE, sseCustomer, } from './encryption.js';
13
15
  export type { B2ErrorCode, B2ErrorResponse, KnownB2ErrorCode } from './errors.js';
14
16
  export { KNOWN_B2_ERROR_CODES } from './errors.js';
15
- export type { CopyFileRequest, CopyPartRequest, CopyPartResponse, DeleteFileVersionRequest, DeleteFileVersionResponse, FileVersion, GetFileInfoRequest, HideFileRequest, ListFileNamesRequest, ListFileNamesResponse, ListFileVersionsRequest, ListFileVersionsResponse, } from './file.js';
17
+ export type { CopyFileRequest, CopyPartRequest, CopyPartResponse, DeleteFileVersionRequest, DeleteFileVersionResponse, FileVersion, GetFileInfoRequest, HideFileRequest, ListFileNamesRequest, ListFileNamesResponse, ListFileVersionsRequest, ListFileVersionsResponse, ReplicationStatus, } from './file.js';
16
18
  export { FileAction, MetadataDirective } from './file.js';
17
- export type { AccountId, ApplicationKeyId, AuthToken, Brand, BrandTag, BucketId, FileId, KeyId, LargeFileId, UploadAuthToken, UploadUrl, } from './ids.js';
18
- export { accountId, applicationKeyId, bucketId, fileId, keyId, largeFileId } from './ids.js';
19
+ export type { AccountId, ApplicationKeyId, AuthToken, Brand, BrandTag, BucketId, ComputerId, FileId, GroupId, KeyId, LargeFileId, PartnerToken, UploadAuthToken, UploadUrl, } from './ids.js';
20
+ export { accountId, applicationKeyId, bucketId, computerId, fileId, groupId, keyId, largeFileId, partnerToken, } from './ids.js';
19
21
  export type { ApplicationKey, CreateKeyBucketScope, CreateKeyOptions, CreateKeyOptionsBase, CreateKeyRequest, DeleteKeyRequest, FullApplicationKey, ListKeysRequest, ListKeysResponse, } from './key.js';
20
- export type { FileRetentionValue, UpdateFileLegalHoldRequest, UpdateFileLegalHoldResponse, UpdateFileRetentionRequest, UpdateFileRetentionResponse, } from './lock.js';
22
+ export type { FileRetentionValue, ReadableFileRetention, ReadableLegalHold, UpdateFileLegalHoldRequest, UpdateFileLegalHoldResponse, UpdateFileRetentionRequest, UpdateFileRetentionResponse, } from './lock.js';
21
23
  export { LegalHoldValue, RetentionMode } from './lock.js';
22
24
  export type { EventNotificationRule, GetBucketNotificationRulesRequest, GetBucketNotificationRulesResponse, SetBucketNotificationRulesRequest, SetBucketNotificationRulesResponse, } from './notifications.js';
23
25
  export { EventType } from './notifications.js';
26
+ export type { CreateGroupMemberRequest, CreateGroupMemberResponse, CreateGroupMemberResult, EjectGroupMemberRequest, EjectGroupMemberResponse, EjectGroupMemberResult, ListedGroupMember, ListGroupMembersRequest, ListGroupMembersResponse, ListGroupMembersResult, ListGroupsRequest, ListGroupsResponse, ListGroupsResult, PartnerAccountStandingDetails, PartnerApiInfo, PartnerAuthorizeResponse, PartnerB2Stats, PartnerBackupApiInfo, PartnerGroup, PartnerGroupMember, PartnerGroupStats, PartnerGroupsApiInfo, PartnerStorageApiInfo, ReserveTrialCreateAccountRequest, ReserveTrialCreateAccountRequestEntry, ReserveTrialCreateAccountResponse, ReserveTrialCreateAccountResult, } from './partner.js';
27
+ export { PartnerCapability, Region } from './partner.js';
24
28
  export type { ReplicationConfiguration, ReplicationDestination, ReplicationRule, ReplicationSource, } from './replication.js';
25
- export type { CancelLargeFileRequest, CancelLargeFileResponse, FinishLargeFileRequest, GetUploadPartUrlRequest, GetUploadPartUrlResponse, GetUploadUrlRequest, GetUploadUrlResponse, ListPartsRequest, ListPartsResponse, ListUnfinishedLargeFilesRequest, ListUnfinishedLargeFilesResponse, PartInfo, ReadableFileRetention, ReadableLegalHold, StartLargeFileRequest, StartLargeFileResponse, UnfinishedLargeFile, UnfinishedLargeFileMetadata, UploadFileHeaders, UploadPartHeaders, UploadPartResponse, } from './upload.js';
29
+ export type { CancelLargeFileRequest, CancelLargeFileResponse, FinishLargeFileRequest, GetUploadPartUrlRequest, GetUploadPartUrlResponse, GetUploadUrlRequest, GetUploadUrlResponse, ListPartsRequest, ListPartsResponse, ListUnfinishedLargeFilesRequest, ListUnfinishedLargeFilesResponse, PartInfo, StartLargeFileRequest, StartLargeFileResponse, UnfinishedLargeFile, UnfinishedLargeFileMetadata, UploadFileHeaders, UploadPartHeaders, UploadPartResponse, } from './upload.js';
26
30
  //# sourceMappingURL=index.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/types/index.js"],"names":[],"mappings":"AAAA;;;;GAIG;AAEH,YAAY,EACV,aAAa,EACb,WAAW,EACX,OAAO,EACP,uBAAuB,EACvB,wBAAwB,EACxB,aAAa,EACb,cAAc,GACf,MAAM,WAAW,CAAA;AAGlB,OAAO,EAAE,UAAU,EAAE,MAAM,WAAW,CAAA;AACtC,YAAY,EACV,UAAU,EACV,qBAAqB,EACrB,QAAQ,EACR,mBAAmB,EACnB,mBAAmB,EACnB,aAAa,EACb,kBAAkB,EAClB,mBAAmB,EACnB,eAAe,EACf,mBAAmB,GACpB,MAAM,aAAa,CAAA;AAGpB,OAAO,EAAE,mBAAmB,EAAE,UAAU,EAAE,aAAa,EAAE,MAAM,aAAa,CAAA;AAC5E,YAAY,EACV,4BAA4B,EAC5B,6BAA6B,EAC7B,mBAAmB,EACnB,qBAAqB,EACrB,eAAe,GAChB,MAAM,eAAe,CAAA;AACtB,YAAY,EACV,iBAAiB,EACjB,YAAY,EACZ,uBAAuB,EACvB,uBAAuB,EACvB,YAAY,EACZ,mBAAmB,EACnB,iBAAiB,GAClB,MAAM,iBAAiB,CAAA;AAExB,OAAO,EACL,mBAAmB,EACnB,aAAa,EACb,cAAc,EACd,MAAM,EACN,QAAQ,EACR,WAAW,GACZ,MAAM,iBAAiB,CAAA;AACxB,YAAY,EAAE,WAAW,EAAE,eAAe,EAAE,gBAAgB,EAAE,MAAM,aAAa,CAAA;AACjF,OAAO,EAAE,oBAAoB,EAAE,MAAM,aAAa,CAAA;AAClD,YAAY,EACV,eAAe,EACf,eAAe,EACf,gBAAgB,EAChB,wBAAwB,EACxB,yBAAyB,EACzB,WAAW,EACX,kBAAkB,EAClB,eAAe,EACf,oBAAoB,EACpB,qBAAqB,EACrB,uBAAuB,EACvB,wBAAwB,GACzB,MAAM,WAAW,CAAA;AAElB,OAAO,EAAE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a,CAAA"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/types/index.js"],"names":[],"mappings":"AAAA;;;;GAIG;AAEH,YAAY,EACV,aAAa,EACb,WAAW,EACX,OAAO,EACP,uBAAuB,EACvB,wBAAwB,EACxB,aAAa,EACb,cAAc,GACf,MAAM,WAAW,CAAA;AAGlB,OAAO,EAAE,UAAU,EAAE,MAAM,WAAW,CAAA;AACtC,YAAY,EACV,cAAc,EACd,qBAAqB,EACrB,sBAAsB,EACtB,oBAAoB,EACpB,oBAAoB,EACpB,qBAAqB,EACrB,mBAAmB,GACpB,MAAM,aAAa,CAAA;AACpB,YAAY,EACV,UAAU,EACV,qBAAqB,EACrB,QAAQ,EACR,mBAAmB,EACnB,mBAAmB,EACnB,aAAa,EACb,kBAAkB,EAClB,mBAAmB,EACnB,eAAe,EACf,mBAAmB,GACpB,MAAM,aAAa,CAAA;AAGpB,OAAO,EAAE,mBAAmB,EAAE,UAAU,EAAE,aAAa,EAAE,MAAM,aAAa,CAAA;AAC5E,YAAY,EACV,4BAA4B,EAC5B,6BAA6B,EAC7B,mBAAmB,EACnB,qBAAqB,EACrB,wBAAwB,EACxB,eAAe,EACf,4BAA4B,EAC5B,mBAAmB,GACpB,MAAM,eAAe,CAAA;AAGtB,OAAO,EAAE,sCAAsC,EAAE,kBAAkB,EAAE,MAAM,eAAe,CAAA;AAC1F,YAAY,EACV,iBAAiB,EACjB,YAAY,EACZ,uBAAuB,EACvB,uBAAuB,EACvB,YAAY,EACZ,mBAAmB,EACnB,iBAAiB,GAClB,MAAM,iBAAiB,CAAA;AAExB,OAAO,EACL,mBAAmB,EACnB,aAAa,EACb,cAAc,EACd,MAAM,EACN,QAAQ,EACR,WAAW,GACZ,MAAM,iBAAiB,CAAA;AACxB,YAAY,EAAE,WAAW,EAAE,eAAe,EAAE,gBAAgB,EAAE,MAAM,aAAa,CAAA;AACjF,OAAO,EAAE,oBAAoB,EAAE,MAAM,aAAa,CAAA;AAClD,YAAY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