@open-e2ee/signal-protocol-sdk 14.1.0 → 14.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 (401) hide show
  1. package/ADAPTERS.md +5 -5
  2. package/CHANGELOG.md +505 -0
  3. package/README.md +24 -19
  4. package/SECURITY.md +2 -2
  5. package/TROUBLESHOOTING.md +1 -1
  6. package/client/README.md +30 -18
  7. package/device/README.md +6 -5
  8. package/dist/client/client.d.ts +49 -38
  9. package/dist/client/client.d.ts.map +1 -1
  10. package/dist/client/client.js +231 -155
  11. package/dist/client/client.js.map +1 -1
  12. package/dist/client/compose.d.ts +4 -2
  13. package/dist/client/compose.d.ts.map +1 -1
  14. package/dist/client/compose.js +6 -1
  15. package/dist/client/compose.js.map +1 -1
  16. package/dist/client/config.d.ts +15 -6
  17. package/dist/client/config.d.ts.map +1 -1
  18. package/dist/client/config.js.map +1 -1
  19. package/dist/client/content-adapter.d.ts +9 -0
  20. package/dist/client/content-adapter.d.ts.map +1 -1
  21. package/dist/client/content-adapter.js +6 -0
  22. package/dist/client/content-adapter.js.map +1 -1
  23. package/dist/client/delivery-status.d.ts +2 -2
  24. package/dist/client/delivery-status.d.ts.map +1 -1
  25. package/dist/client/delivery-status.js +10 -4
  26. package/dist/client/delivery-status.js.map +1 -1
  27. package/dist/client/device-set-reconciliation.d.ts +23 -15
  28. package/dist/client/device-set-reconciliation.d.ts.map +1 -1
  29. package/dist/client/device-set-reconciliation.js +16 -13
  30. package/dist/client/device-set-reconciliation.js.map +1 -1
  31. package/dist/client/event-hooks.d.ts +15 -5
  32. package/dist/client/event-hooks.d.ts.map +1 -1
  33. package/dist/client/event-hooks.js +39 -4
  34. package/dist/client/event-hooks.js.map +1 -1
  35. package/dist/client/group-device-set.d.ts +1 -1
  36. package/dist/client/group-device-set.d.ts.map +1 -1
  37. package/dist/client/group-key-sync.js +1 -1
  38. package/dist/client/group-key-sync.js.map +1 -1
  39. package/dist/client/group-outbox.d.ts +7 -7
  40. package/dist/client/group-outbox.d.ts.map +1 -1
  41. package/dist/client/group-outbox.js +24 -24
  42. package/dist/client/group-outbox.js.map +1 -1
  43. package/dist/client/group-sealed-sender.d.ts +1 -1
  44. package/dist/client/group-sealed-sender.d.ts.map +1 -1
  45. package/dist/client/group-sender-key-operations.js +1 -1
  46. package/dist/client/group-sender-key-operations.js.map +1 -1
  47. package/dist/client/headless.d.ts +6 -6
  48. package/dist/client/headless.d.ts.map +1 -1
  49. package/dist/client/headless.js +7 -7
  50. package/dist/client/headless.js.map +1 -1
  51. package/dist/client/hosted-anonymous-delivery.d.ts +6 -6
  52. package/dist/client/hosted-anonymous-delivery.d.ts.map +1 -1
  53. package/dist/client/hosted-anonymous-delivery.js +17 -17
  54. package/dist/client/hosted-anonymous-delivery.js.map +1 -1
  55. package/dist/client/hosted-assertion-id.d.ts +1 -1
  56. package/dist/client/hosted-assertion-id.d.ts.map +1 -1
  57. package/dist/client/hosted-assertion-id.js +1 -1
  58. package/dist/client/hosted-assertion-id.js.map +1 -1
  59. package/dist/client/hosted-connection.d.ts +5 -5
  60. package/dist/client/hosted-connection.d.ts.map +1 -1
  61. package/dist/client/hosted-connection.js +32 -32
  62. package/dist/client/hosted-connection.js.map +1 -1
  63. package/dist/client/hosted-device-link-transport.d.ts +2 -2
  64. package/dist/client/hosted-device-link-transport.d.ts.map +1 -1
  65. package/dist/client/hosted-device-link-transport.js +1 -1
  66. package/dist/client/hosted-device-link-transport.js.map +1 -1
  67. package/dist/client/hosted-device-link.d.ts +5 -1
  68. package/dist/client/hosted-device-link.d.ts.map +1 -1
  69. package/dist/client/hosted-device-link.js +7 -4
  70. package/dist/client/hosted-device-link.js.map +1 -1
  71. package/dist/client/hosted-device-standing.d.ts +13 -5
  72. package/dist/client/hosted-device-standing.d.ts.map +1 -1
  73. package/dist/client/hosted-device-standing.js +11 -6
  74. package/dist/client/hosted-device-standing.js.map +1 -1
  75. package/dist/client/hosted-group-authority.d.ts +2 -2
  76. package/dist/client/hosted-group-authority.d.ts.map +1 -1
  77. package/dist/client/hosted-group-authority.js +8 -8
  78. package/dist/client/hosted-group-authority.js.map +1 -1
  79. package/dist/client/hosted-groups.d.ts +4 -4
  80. package/dist/client/hosted-groups.d.ts.map +1 -1
  81. package/dist/client/hosted-groups.js +8 -8
  82. package/dist/client/hosted-groups.js.map +1 -1
  83. package/dist/client/hosted-http-error.d.ts +7 -3
  84. package/dist/client/hosted-http-error.d.ts.map +1 -1
  85. package/dist/client/hosted-http-error.js +6 -3
  86. package/dist/client/hosted-http-error.js.map +1 -1
  87. package/dist/client/hosted-mailbox-subscription.d.ts +10 -10
  88. package/dist/client/hosted-mailbox-subscription.d.ts.map +1 -1
  89. package/dist/client/hosted-mailbox-subscription.js +17 -17
  90. package/dist/client/hosted-mailbox-subscription.js.map +1 -1
  91. package/dist/client/hosted-prekey-publication.d.ts +9 -9
  92. package/dist/client/hosted-prekey-publication.d.ts.map +1 -1
  93. package/dist/client/hosted-prekey-publication.js.map +1 -1
  94. package/dist/client/hosted-presence-frames.d.ts +62 -38
  95. package/dist/client/hosted-presence-frames.d.ts.map +1 -1
  96. package/dist/client/hosted-presence-frames.js +4 -2
  97. package/dist/client/hosted-presence-frames.js.map +1 -1
  98. package/dist/client/hosted-presence.d.ts +22 -14
  99. package/dist/client/hosted-presence.d.ts.map +1 -1
  100. package/dist/client/hosted-presence.js +26 -17
  101. package/dist/client/hosted-presence.js.map +1 -1
  102. package/dist/client/hosted-profile-keys.d.ts +3 -1
  103. package/dist/client/hosted-profile-keys.d.ts.map +1 -1
  104. package/dist/client/hosted-profile-keys.js +19 -15
  105. package/dist/client/hosted-profile-keys.js.map +1 -1
  106. package/dist/client/hosted-push.d.ts +38 -16
  107. package/dist/client/hosted-push.d.ts.map +1 -1
  108. package/dist/client/hosted-push.js +11 -5
  109. package/dist/client/hosted-push.js.map +1 -1
  110. package/dist/client/hosted-resume-error.d.ts +21 -9
  111. package/dist/client/hosted-resume-error.d.ts.map +1 -1
  112. package/dist/client/hosted-resume-error.js +4 -1
  113. package/dist/client/hosted-resume-error.js.map +1 -1
  114. package/dist/client/hosted-resume.d.ts +3 -3
  115. package/dist/client/hosted-resume.d.ts.map +1 -1
  116. package/dist/client/hosted-resume.js +12 -12
  117. package/dist/client/hosted-resume.js.map +1 -1
  118. package/dist/client/hosted-sandbox-identity.d.ts +32 -18
  119. package/dist/client/hosted-sandbox-identity.d.ts.map +1 -1
  120. package/dist/client/hosted-sandbox-identity.js +46 -27
  121. package/dist/client/hosted-sandbox-identity.js.map +1 -1
  122. package/dist/client/hosted-store-records.d.ts +46 -0
  123. package/dist/client/hosted-store-records.d.ts.map +1 -0
  124. package/dist/client/hosted-store-records.js +32 -0
  125. package/dist/client/hosted-store-records.js.map +1 -0
  126. package/dist/client/hosted-transport.d.ts +41 -33
  127. package/dist/client/hosted-transport.d.ts.map +1 -1
  128. package/dist/client/hosted-transport.js +146 -101
  129. package/dist/client/hosted-transport.js.map +1 -1
  130. package/dist/client/hosted-trust.d.ts +1 -1
  131. package/dist/client/hosted-trust.d.ts.map +1 -1
  132. package/dist/client/hosted-trust.js +1 -1
  133. package/dist/client/hosted-trust.js.map +1 -1
  134. package/dist/client/hosted.d.ts +138 -72
  135. package/dist/client/hosted.d.ts.map +1 -1
  136. package/dist/client/hosted.js +102 -60
  137. package/dist/client/hosted.js.map +1 -1
  138. package/dist/client/index.d.ts +4 -4
  139. package/dist/client/index.d.ts.map +1 -1
  140. package/dist/client/index.js +4 -4
  141. package/dist/client/index.js.map +1 -1
  142. package/dist/client/key-rotation-core.d.ts +4 -4
  143. package/dist/client/key-rotation-core.d.ts.map +1 -1
  144. package/dist/client/key-rotation-core.js +8 -8
  145. package/dist/client/key-rotation-core.js.map +1 -1
  146. package/dist/client/key-rotation.js +2 -2
  147. package/dist/client/key-rotation.js.map +1 -1
  148. package/dist/client/messages.d.ts +3 -3
  149. package/dist/client/messages.d.ts.map +1 -1
  150. package/dist/client/messages.js +18 -18
  151. package/dist/client/messages.js.map +1 -1
  152. package/dist/client/one-time-prekey-refill.d.ts +1 -1
  153. package/dist/client/one-time-prekey-refill.d.ts.map +1 -1
  154. package/dist/client/prekeys.js +17 -17
  155. package/dist/client/prekeys.js.map +1 -1
  156. package/dist/client/receive-queue.d.ts +4 -4
  157. package/dist/client/receive-queue.d.ts.map +1 -1
  158. package/dist/client/receive-queue.js +29 -29
  159. package/dist/client/receive-queue.js.map +1 -1
  160. package/dist/client/receive-work-seed.d.ts +6 -2
  161. package/dist/client/receive-work-seed.d.ts.map +1 -1
  162. package/dist/client/receive-work-seed.js.map +1 -1
  163. package/dist/client/recovery-driver.js +7 -7
  164. package/dist/client/recovery-driver.js.map +1 -1
  165. package/dist/client/retry-request-envelope.d.ts +3 -3
  166. package/dist/client/retry-request-envelope.d.ts.map +1 -1
  167. package/dist/client/retry-request-envelope.js +10 -10
  168. package/dist/client/retry-request-envelope.js.map +1 -1
  169. package/dist/client/retry-request-lifecycle.d.ts +1 -1
  170. package/dist/client/retry-request-lifecycle.d.ts.map +1 -1
  171. package/dist/client/retry-request-lifecycle.js +8 -8
  172. package/dist/client/retry-request-lifecycle.js.map +1 -1
  173. package/dist/client/retry-terminal-recovery.js +2 -2
  174. package/dist/client/retry-terminal-recovery.js.map +1 -1
  175. package/dist/client/retry.js +13 -13
  176. package/dist/client/retry.js.map +1 -1
  177. package/dist/client/sealed-sender.d.ts +13 -4
  178. package/dist/client/sealed-sender.d.ts.map +1 -1
  179. package/dist/client/sealed-sender.js +27 -15
  180. package/dist/client/sealed-sender.js.map +1 -1
  181. package/dist/client/send-deadline.d.ts +6 -6
  182. package/dist/client/send-deadline.d.ts.map +1 -1
  183. package/dist/client/send-deadline.js +37 -23
  184. package/dist/client/send-deadline.js.map +1 -1
  185. package/dist/client/send-intent-driver.js +9 -9
  186. package/dist/client/send-intent-driver.js.map +1 -1
  187. package/dist/client/sessions.js +11 -11
  188. package/dist/client/sessions.js.map +1 -1
  189. package/dist/client/{relay-acceptance.d.ts → signal-relay-acceptance.d.ts} +9 -9
  190. package/dist/client/signal-relay-acceptance.d.ts.map +1 -0
  191. package/dist/client/{relay-acceptance.js → signal-relay-acceptance.js} +7 -7
  192. package/dist/client/signal-relay-acceptance.js.map +1 -0
  193. package/dist/client/{relay-device-refusal.d.ts → signal-relay-device-refusal.d.ts} +7 -7
  194. package/dist/client/signal-relay-device-refusal.d.ts.map +1 -0
  195. package/dist/client/{relay-device-refusal.js → signal-relay-device-refusal.js} +9 -9
  196. package/dist/client/signal-relay-device-refusal.js.map +1 -0
  197. package/dist/client/{relay-lifecycle.d.ts → signal-relay-lifecycle.d.ts} +18 -9
  198. package/dist/client/signal-relay-lifecycle.d.ts.map +1 -0
  199. package/dist/client/{relay-lifecycle.js → signal-relay-lifecycle.js} +16 -7
  200. package/dist/client/signal-relay-lifecycle.js.map +1 -0
  201. package/dist/client/{relay-period-close.d.ts → signal-relay-period-close.d.ts} +1 -1
  202. package/dist/client/signal-relay-period-close.d.ts.map +1 -0
  203. package/dist/client/{relay-period-close.js → signal-relay-period-close.js} +1 -1
  204. package/dist/client/signal-relay-period-close.js.map +1 -0
  205. package/dist/client/{relay-protocol.d.ts → signal-relay-protocol.d.ts} +12 -8
  206. package/dist/client/signal-relay-protocol.d.ts.map +1 -0
  207. package/dist/client/{relay-protocol.js → signal-relay-protocol.js} +13 -10
  208. package/dist/client/signal-relay-protocol.js.map +1 -0
  209. package/dist/client/{relay-receipt-intake.d.ts → signal-relay-receipt-intake.d.ts} +12 -12
  210. package/dist/client/signal-relay-receipt-intake.d.ts.map +1 -0
  211. package/dist/client/{relay-receipt-intake.js → signal-relay-receipt-intake.js} +9 -9
  212. package/dist/client/signal-relay-receipt-intake.js.map +1 -0
  213. package/dist/client/{relay-receipt-join.d.ts → signal-relay-receipt-join.d.ts} +8 -8
  214. package/dist/client/signal-relay-receipt-join.d.ts.map +1 -0
  215. package/dist/client/{relay-receipt-join.js → signal-relay-receipt-join.js} +11 -11
  216. package/dist/client/signal-relay-receipt-join.js.map +1 -0
  217. package/dist/client/{relay-request-deadline.d.ts → signal-relay-request-deadline.d.ts} +3 -3
  218. package/dist/client/signal-relay-request-deadline.d.ts.map +1 -0
  219. package/dist/client/{relay-request-deadline.js → signal-relay-request-deadline.js} +4 -4
  220. package/dist/client/signal-relay-request-deadline.js.map +1 -0
  221. package/dist/client/{relay-sealed-route.d.ts → signal-relay-sealed-route.d.ts} +1 -1
  222. package/dist/client/signal-relay-sealed-route.d.ts.map +1 -0
  223. package/dist/client/{relay-sealed-route.js → signal-relay-sealed-route.js} +1 -1
  224. package/dist/client/signal-relay-sealed-route.js.map +1 -0
  225. package/dist/client/{relay-subscription.d.ts → signal-relay-subscription.d.ts} +12 -12
  226. package/dist/client/signal-relay-subscription.d.ts.map +1 -0
  227. package/dist/client/{relay-subscription.js → signal-relay-subscription.js} +23 -23
  228. package/dist/client/signal-relay-subscription.js.map +1 -0
  229. package/dist/client/{relay-work.d.ts → signal-relay-work.d.ts} +7 -7
  230. package/dist/client/signal-relay-work.d.ts.map +1 -0
  231. package/dist/client/{relay-work.js → signal-relay-work.js} +13 -13
  232. package/dist/client/signal-relay-work.js.map +1 -0
  233. package/dist/client/signal-service-cipher.d.ts +10 -8
  234. package/dist/client/signal-service-cipher.d.ts.map +1 -1
  235. package/dist/client/signal-service-cipher.js +102 -97
  236. package/dist/client/signal-service-cipher.js.map +1 -1
  237. package/dist/client/state.d.ts +4 -4
  238. package/dist/client/state.d.ts.map +1 -1
  239. package/dist/client/state.js +3 -3
  240. package/dist/client/state.js.map +1 -1
  241. package/dist/client/types.d.ts +13 -4
  242. package/dist/client/types.d.ts.map +1 -1
  243. package/dist/client/types.js.map +1 -1
  244. package/dist/device/connection.d.ts +10 -4
  245. package/dist/device/connection.d.ts.map +1 -1
  246. package/dist/device/connection.js +8 -3
  247. package/dist/device/connection.js.map +1 -1
  248. package/dist/device/index.d.ts +2 -2
  249. package/dist/device/index.d.ts.map +1 -1
  250. package/dist/device/index.js +1 -1
  251. package/dist/device/index.js.map +1 -1
  252. package/dist/device/types.d.ts +3 -1
  253. package/dist/device/types.d.ts.map +1 -1
  254. package/dist/hooks/index.d.ts +2 -2
  255. package/dist/hooks/index.d.ts.map +1 -1
  256. package/dist/hooks/index.js +2 -2
  257. package/dist/hooks/index.js.map +1 -1
  258. package/dist/hooks/use-signal-relay-connection-state.d.ts +39 -0
  259. package/dist/hooks/use-signal-relay-connection-state.d.ts.map +1 -0
  260. package/dist/hooks/use-signal-relay-connection-state.js +45 -0
  261. package/dist/hooks/use-signal-relay-connection-state.js.map +1 -0
  262. package/dist/hooks/use-signal-relay-lifecycle.d.ts +43 -0
  263. package/dist/hooks/use-signal-relay-lifecycle.d.ts.map +1 -0
  264. package/dist/hooks/use-signal-relay-lifecycle.js +38 -0
  265. package/dist/hooks/use-signal-relay-lifecycle.js.map +1 -0
  266. package/dist/index.d.ts +16 -9
  267. package/dist/index.d.ts.map +1 -1
  268. package/dist/index.js +6 -5
  269. package/dist/index.js.map +1 -1
  270. package/dist/internal/groups/authority-certificate.d.ts +8 -1
  271. package/dist/internal/groups/authority-certificate.d.ts.map +1 -1
  272. package/dist/internal/groups/authority-certificate.js +29 -6
  273. package/dist/internal/groups/authority-certificate.js.map +1 -1
  274. package/dist/internal/protocol/sealed-sender/certificate.js +2 -2
  275. package/dist/internal/protocol/sealed-sender/certificate.js.map +1 -1
  276. package/dist/internal/protocol/sealed-sender/proto/index.d.ts +1 -1
  277. package/dist/internal/protocol/sealed-sender/proto/index.d.ts.map +1 -1
  278. package/dist/internal/protocol/sealed-sender/proto/index.js +5 -5
  279. package/dist/internal/protocol/sealed-sender/proto/index.js.map +1 -1
  280. package/dist/internal/sesame/device-registry.d.ts +13 -13
  281. package/dist/internal/sesame/device-registry.d.ts.map +1 -1
  282. package/dist/internal/sesame/device-registry.js +20 -20
  283. package/dist/internal/sesame/device-registry.js.map +1 -1
  284. package/dist/local/store/receive-work.d.ts +29 -0
  285. package/dist/local/store/receive-work.d.ts.map +1 -1
  286. package/dist/local/store/receive-work.js +58 -1
  287. package/dist/local/store/receive-work.js.map +1 -1
  288. package/dist/local/store/received-content.d.ts +1 -1
  289. package/dist/local/store/received-content.d.ts.map +1 -1
  290. package/dist/local/store/reliability.d.ts +11 -3
  291. package/dist/local/store/reliability.d.ts.map +1 -1
  292. package/dist/local/store/reliability.js +4 -0
  293. package/dist/local/store/reliability.js.map +1 -1
  294. package/dist/local/store/sqlite/key-storage/index.d.ts +3 -9
  295. package/dist/local/store/sqlite/key-storage/index.d.ts.map +1 -1
  296. package/dist/local/store/sqlite/key-storage/index.js.map +1 -1
  297. package/dist/local/store/sqlite/key-storage/signed-prekeys.d.ts +1 -7
  298. package/dist/local/store/sqlite/key-storage/signed-prekeys.d.ts.map +1 -1
  299. package/dist/local/store/sqlite/key-storage/signed-prekeys.js.map +1 -1
  300. package/dist/local/store/sqlite/models/kyber-prekey.d.ts +4 -9
  301. package/dist/local/store/sqlite/models/kyber-prekey.d.ts.map +1 -1
  302. package/dist/local/store/sqlite/models/kyber-prekey.js +4 -1
  303. package/dist/local/store/sqlite/models/kyber-prekey.js.map +1 -1
  304. package/dist/local/store/sqlite/store.d.ts.map +1 -1
  305. package/dist/local/store/sqlite/store.js +1 -2
  306. package/dist/local/store/sqlite/store.js.map +1 -1
  307. package/dist/remote/signal-relay/connection-state.d.ts +16 -0
  308. package/dist/remote/signal-relay/connection-state.d.ts.map +1 -0
  309. package/dist/remote/{relay → signal-relay}/connection-state.js +1 -1
  310. package/dist/remote/signal-relay/connection-state.js.map +1 -0
  311. package/dist/remote/{relay → signal-relay}/device-set.d.ts +3 -3
  312. package/dist/remote/signal-relay/device-set.d.ts.map +1 -0
  313. package/dist/remote/{relay → signal-relay}/device-set.js +7 -7
  314. package/dist/remote/signal-relay/device-set.js.map +1 -0
  315. package/dist/remote/{relay → signal-relay}/index.d.ts +3 -3
  316. package/dist/remote/signal-relay/index.d.ts.map +1 -0
  317. package/dist/remote/{relay → signal-relay}/index.js +2 -2
  318. package/dist/remote/signal-relay/index.js.map +1 -0
  319. package/dist/remote/{relay → signal-relay}/request-admission.d.ts +2 -2
  320. package/dist/remote/signal-relay/request-admission.d.ts.map +1 -0
  321. package/dist/remote/{relay → signal-relay}/request-admission.js +5 -5
  322. package/dist/remote/signal-relay/request-admission.js.map +1 -0
  323. package/dist/remote/{relay → signal-relay}/types.d.ts +29 -10
  324. package/dist/remote/signal-relay/types.d.ts.map +1 -0
  325. package/dist/remote/{relay → signal-relay}/types.js +1 -1
  326. package/dist/remote/signal-relay/types.js.map +1 -0
  327. package/dist/safety/core.d.ts +1 -1
  328. package/dist/safety/core.js +1 -1
  329. package/dist/types/api.d.ts +38 -15
  330. package/dist/types/api.d.ts.map +1 -1
  331. package/dist/types/errors.d.ts +62 -7
  332. package/dist/types/errors.d.ts.map +1 -1
  333. package/dist/types/errors.js +68 -8
  334. package/dist/types/errors.js.map +1 -1
  335. package/dist/types/renamed-member.d.ts +48 -0
  336. package/dist/types/renamed-member.d.ts.map +1 -0
  337. package/dist/types/renamed-member.js +78 -0
  338. package/dist/types/renamed-member.js.map +1 -0
  339. package/dist/utils/bounded-fan-out.d.ts +2 -2
  340. package/dist/utils/bounded-fan-out.d.ts.map +1 -1
  341. package/dist/utils/bounded-fan-out.js +2 -2
  342. package/dist/utils/bounded-fan-out.js.map +1 -1
  343. package/dist/utils/retry.d.ts +3 -3
  344. package/dist/utils/retry.d.ts.map +1 -1
  345. package/dist/utils/retry.js +4 -3
  346. package/dist/utils/retry.js.map +1 -1
  347. package/docs/ASSURANCE.md +9 -9
  348. package/docs/CLIENT_COMPOSITION.md +7 -5
  349. package/docs/DEVIATIONS.md +8 -5
  350. package/docs/ERROR_HANDLING.md +21 -21
  351. package/docs/GETTING_STARTED.md +22 -15
  352. package/docs/INTERFACES.md +3 -3
  353. package/docs/PACKAGE_SURFACE.md +14 -4
  354. package/docs/RECIPES.md +271 -11
  355. package/hooks/README.md +11 -11
  356. package/local/store/key-value/README.md +1 -1
  357. package/local/store/web-sqlite/README.md +1 -1
  358. package/package.json +16 -6
  359. package/remote/README.md +3 -3
  360. package/remote/{relay → signal-relay}/README.md +15 -6
  361. package/dist/client/relay-acceptance.d.ts.map +0 -1
  362. package/dist/client/relay-acceptance.js.map +0 -1
  363. package/dist/client/relay-device-refusal.d.ts.map +0 -1
  364. package/dist/client/relay-device-refusal.js.map +0 -1
  365. package/dist/client/relay-lifecycle.d.ts.map +0 -1
  366. package/dist/client/relay-lifecycle.js.map +0 -1
  367. package/dist/client/relay-period-close.d.ts.map +0 -1
  368. package/dist/client/relay-period-close.js.map +0 -1
  369. package/dist/client/relay-protocol.d.ts.map +0 -1
  370. package/dist/client/relay-protocol.js.map +0 -1
  371. package/dist/client/relay-receipt-intake.d.ts.map +0 -1
  372. package/dist/client/relay-receipt-intake.js.map +0 -1
  373. package/dist/client/relay-receipt-join.d.ts.map +0 -1
  374. package/dist/client/relay-receipt-join.js.map +0 -1
  375. package/dist/client/relay-request-deadline.d.ts.map +0 -1
  376. package/dist/client/relay-request-deadline.js.map +0 -1
  377. package/dist/client/relay-sealed-route.d.ts.map +0 -1
  378. package/dist/client/relay-sealed-route.js.map +0 -1
  379. package/dist/client/relay-subscription.d.ts.map +0 -1
  380. package/dist/client/relay-subscription.js.map +0 -1
  381. package/dist/client/relay-work.d.ts.map +0 -1
  382. package/dist/client/relay-work.js.map +0 -1
  383. package/dist/hooks/use-relay-connection-state.d.ts +0 -32
  384. package/dist/hooks/use-relay-connection-state.d.ts.map +0 -1
  385. package/dist/hooks/use-relay-connection-state.js +0 -31
  386. package/dist/hooks/use-relay-connection-state.js.map +0 -1
  387. package/dist/hooks/use-relay-lifecycle.d.ts +0 -36
  388. package/dist/hooks/use-relay-lifecycle.d.ts.map +0 -1
  389. package/dist/hooks/use-relay-lifecycle.js +0 -35
  390. package/dist/hooks/use-relay-lifecycle.js.map +0 -1
  391. package/dist/remote/relay/connection-state.d.ts +0 -16
  392. package/dist/remote/relay/connection-state.d.ts.map +0 -1
  393. package/dist/remote/relay/connection-state.js.map +0 -1
  394. package/dist/remote/relay/device-set.d.ts.map +0 -1
  395. package/dist/remote/relay/device-set.js.map +0 -1
  396. package/dist/remote/relay/index.d.ts.map +0 -1
  397. package/dist/remote/relay/index.js.map +0 -1
  398. package/dist/remote/relay/request-admission.d.ts.map +0 -1
  399. package/dist/remote/relay/request-admission.js.map +0 -1
  400. package/dist/remote/relay/types.d.ts.map +0 -1
  401. package/dist/remote/relay/types.js.map +0 -1
@@ -0,0 +1,48 @@
1
+ /**
2
+ * Reads of a member that has a role name, such as `relay`, and a deprecated
3
+ * `signalProtocolRelay*` name, such as `signalProtocolRelay`.
4
+ *
5
+ * SDK 14.2.0 added the `signalProtocolRelay*` names after the role names, so
6
+ * this module calls the `signalProtocolRelay*` name the new name and the role
7
+ * name the earlier name. SDK 14.3.0 deprecates the new names, and the role
8
+ * names are the names to use.
9
+ *
10
+ * SDK 14 accepts both names of each such option and member. An option read
11
+ * takes the new name first and the earlier name second. A member read takes
12
+ * the name that the nearest level of the object defines, so a subclass
13
+ * override of either name wins. SDK 15.0.0 removes the new names and this
14
+ * module.
15
+ *
16
+ * The module is not in a package entry point.
17
+ */
18
+ /** The two names of one member, and the operation that reads it. */
19
+ export interface RenamedMember {
20
+ /** The deprecated `signalProtocolRelay*` name. */
21
+ readonly newName: string;
22
+ /** The role name. */
23
+ readonly earlierName: string;
24
+ readonly operation: string;
25
+ }
26
+ /**
27
+ * Returns the value of an option that the caller sets by either name.
28
+ *
29
+ * The new name wins. Two values with the same identity, or two byte arrays
30
+ * with the same bytes, are the same value. Undefined means not set.
31
+ *
32
+ * @throws SignalProtocolRelayNameConflictError when both names hold values
33
+ * that are not the same.
34
+ */
35
+ export declare function readRenamedOption<T>(newValue: T | undefined, earlierValue: T | undefined, member: RenamedMember): T | undefined;
36
+ /**
37
+ * Returns the member of an object that the caller implements under either
38
+ * name, such as a `SignalProtocolRelayServer`.
39
+ *
40
+ * The name that the nearest level of the object defines wins, and the new
41
+ * name wins when one level defines both. An SDK class defines both names, so
42
+ * a subclass that overrides only one name gives its override. When the
43
+ * chosen name holds no value, the read takes the other name. A method comes
44
+ * back bound to its object. The read does not compare the two members,
45
+ * because an SDK class keeps one name as a forward to the other.
46
+ */
47
+ export declare function readRenamedImplementation<T extends object, K extends keyof T, E extends keyof T>(source: T, newName: K, earlierName: E): NonNullable<T[K]> | NonNullable<T[E]> | undefined;
48
+ //# sourceMappingURL=renamed-member.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"renamed-member.d.ts","sourceRoot":"","sources":["../../types/renamed-member.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;GAgBG;AAIH,oEAAoE;AACpE,MAAM,WAAW,aAAa;IAC5B,kDAAkD;IAClD,QAAQ,CAAC,OAAO,EAAE,MAAM,CAAC;IACzB,qBAAqB;IACrB,QAAQ,CAAC,WAAW,EAAE,MAAM,CAAC;IAC7B,QAAQ,CAAC,SAAS,EAAE,MAAM,CAAC;CAC5B;AAUD;;;;;;;;GAQG;AACH,wBAAgB,iBAAiB,CAAC,CAAC,EACjC,QAAQ,EAAE,CAAC,GAAG,SAAS,EACvB,YAAY,EAAE,CAAC,GAAG,SAAS,EAC3B,MAAM,EAAE,aAAa,GACpB,CAAC,GAAG,SAAS,CASf;AAuBD;;;;;;;;;;GAUG;AACH,wBAAgB,yBAAyB,CAAC,CAAC,SAAS,MAAM,EAAE,CAAC,SAAS,MAAM,CAAC,EAAE,CAAC,SAAS,MAAM,CAAC,EAC9F,MAAM,EAAE,CAAC,EACT,OAAO,EAAE,CAAC,EACV,WAAW,EAAE,CAAC,GACb,WAAW,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,GAAG,WAAW,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,GAAG,SAAS,CASnD"}
@@ -0,0 +1,78 @@
1
+ /**
2
+ * Reads of a member that has a role name, such as `relay`, and a deprecated
3
+ * `signalProtocolRelay*` name, such as `signalProtocolRelay`.
4
+ *
5
+ * SDK 14.2.0 added the `signalProtocolRelay*` names after the role names, so
6
+ * this module calls the `signalProtocolRelay*` name the new name and the role
7
+ * name the earlier name. SDK 14.3.0 deprecates the new names, and the role
8
+ * names are the names to use.
9
+ *
10
+ * SDK 14 accepts both names of each such option and member. An option read
11
+ * takes the new name first and the earlier name second. A member read takes
12
+ * the name that the nearest level of the object defines, so a subclass
13
+ * override of either name wins. SDK 15.0.0 removes the new names and this
14
+ * module.
15
+ *
16
+ * The module is not in a package entry point.
17
+ */
18
+ import { SignalProtocolRelayNameConflictError } from './errors.js';
19
+ function sameValue(a, b) {
20
+ if (Object.is(a, b))
21
+ return true;
22
+ if (!(a instanceof Uint8Array) || !(b instanceof Uint8Array) || a.length !== b.length) {
23
+ return false;
24
+ }
25
+ return a.every((byte, index) => byte === b[index]);
26
+ }
27
+ /**
28
+ * Returns the value of an option that the caller sets by either name.
29
+ *
30
+ * The new name wins. Two values with the same identity, or two byte arrays
31
+ * with the same bytes, are the same value. Undefined means not set.
32
+ *
33
+ * @throws SignalProtocolRelayNameConflictError when both names hold values
34
+ * that are not the same.
35
+ */
36
+ export function readRenamedOption(newValue, earlierValue, member) {
37
+ if (newValue !== undefined && earlierValue !== undefined && !sameValue(newValue, earlierValue)) {
38
+ throw new SignalProtocolRelayNameConflictError(member.newName, member.earlierName, member.operation);
39
+ }
40
+ return newValue !== undefined ? newValue : earlierValue;
41
+ }
42
+ /**
43
+ * Returns the name that the nearest level of an object defines, where a
44
+ * level is the object itself or one of its prototypes. The new name wins
45
+ * when one level defines both names.
46
+ */
47
+ function nearestRenamedName(source, newName, earlierName) {
48
+ for (let level = source; level !== null && level !== Object.prototype; level = Object.getPrototypeOf(level)) {
49
+ if (Object.prototype.hasOwnProperty.call(level, newName))
50
+ return newName;
51
+ if (Object.prototype.hasOwnProperty.call(level, earlierName))
52
+ return earlierName;
53
+ }
54
+ return newName;
55
+ }
56
+ /**
57
+ * Returns the member of an object that the caller implements under either
58
+ * name, such as a `SignalProtocolRelayServer`.
59
+ *
60
+ * The name that the nearest level of the object defines wins, and the new
61
+ * name wins when one level defines both. An SDK class defines both names, so
62
+ * a subclass that overrides only one name gives its override. When the
63
+ * chosen name holds no value, the read takes the other name. A method comes
64
+ * back bound to its object. The read does not compare the two members,
65
+ * because an SDK class keeps one name as a forward to the other.
66
+ */
67
+ export function readRenamedImplementation(source, newName, earlierName) {
68
+ const first = nearestRenamedName(source, newName, earlierName);
69
+ const second = first === newName ? earlierName : newName;
70
+ const member = source[first] ?? source[second];
71
+ if (member === undefined || member === null)
72
+ return undefined;
73
+ if (typeof member === 'function') {
74
+ return member.bind(source);
75
+ }
76
+ return member;
77
+ }
78
+ //# sourceMappingURL=renamed-member.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"renamed-member.js","sourceRoot":"","sources":["../../types/renamed-member.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;GAgBG;AAEH,OAAO,EAAE,oCAAoC,EAAE,MAAM,UAAU,CAAC;AAWhE,SAAS,SAAS,CAAC,CAAU,EAAE,CAAU;IACvC,IAAI,MAAM,CAAC,EAAE,CAAC,CAAC,EAAE,CAAC,CAAC;QAAE,OAAO,IAAI,CAAC;IACjC,IAAI,CAAC,CAAC,CAAC,YAAY,UAAU,CAAC,IAAI,CAAC,CAAC,CAAC,YAAY,UAAU,CAAC,IAAI,CAAC,CAAC,MAAM,KAAK,CAAC,CAAC,MAAM,EAAE,CAAC;QACtF,OAAO,KAAK,CAAC;IACf,CAAC;IACD,OAAO,CAAC,CAAC,KAAK,CAAC,CAAC,IAAI,EAAE,KAAK,EAAE,EAAE,CAAC,IAAI,KAAK,CAAC,CAAC,KAAK,CAAC,CAAC,CAAC;AACrD,CAAC;AAED;;;;;;;;GAQG;AACH,MAAM,UAAU,iBAAiB,CAC/B,QAAuB,EACvB,YAA2B,EAC3B,MAAqB;IAErB,IAAI,QAAQ,KAAK,SAAS,IAAI,YAAY,KAAK,SAAS,IAAI,CAAC,SAAS,CAA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;QACjC,OAAQ,MAA0C,CAAC,IAAI,CAAC,MAAM,CAA0C,CAAC;IAC3G,CAAC;IACD,OAAO,MAA+C,CAAC;AACzD,CAAC"}
@@ -21,10 +21,10 @@
21
21
  * `stopped` option.
22
22
  */
23
23
  /** Relay requests that one client has in flight at most. */
24
- export declare const RELAY_REQUESTS_IN_FLIGHT = 4;
24
+ export declare const SIGNAL_RELAY_REQUESTS_IN_FLIGHT = 4;
25
25
  /** The options of a BoundedFanOut. */
26
26
  export interface BoundedFanOutOptions {
27
- /** Relay requests in flight at most. Default: RELAY_REQUESTS_IN_FLIGHT */
27
+ /** Relay requests in flight at most. Default: SIGNAL_RELAY_REQUESTS_IN_FLIGHT */
28
28
  limit?: number;
29
29
  /** The error for work that a stop signal ended. */
30
30
  stopped: () => Error;
@@ -1 +1 @@
1
- {"version":3,"file":"bounded-fan-out.d.ts","sourceRoot":"","sources":["../../utils/bounded-fan-out.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;GAqBG;AAEH,4DAA4D;AAC5D,eAAO,MAAM,wBAAwB,IAAI,CAAC;AAE1C,sCAAsC;AACtC,MAAM,WAAW,oBAAoB;IACnC,0EAA0E;IAC1E,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,mDAAmD;IACnD,OAAO,EAAE,MAAM,KAAK,CAAC;CACtB;AAED,4CAA4C;AAC5C,MAAM,MAAM,aAAa,CAAC,CAAC,IACvB;IAAE,QAAQ,CAAC,EAAE,EAAE,IAAI,CAAC;IAAC,QAAQ,CAAC,KAAK,EAAE,CAAC,CAAA;CAAE,GACxC;IAAE,QAAQ,CAAC,EAAE,EAAE,KAAK,CAAC;IAAC,QAAQ,CAAC,KAAK,EAAE,OAAO,CAAA;CAAE,CAAC;AAEpD;;GAEG;AACH,qBAAa,WAAW,CAAC,CAAC,GAAG,OAAO,CAAE,SAAQ,KAAK;IACjD,qDAAqD;IACrD,QAAQ,CAAC,MAAM,EAAE,SAAS,OAAO,EAAE,CAAC;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AAyE;IACzE,GAAG,CAAC,CAAC,EAAE,CAAC,EAAE,KAAK,EAAE,SAAS,CAAC,EAAE,EAAE,IAAI,EAAE,CAAC,IAAI,EAAE,CAAC,EAAE,KAAK,EAAE,MAAM,KAAK,OAAO,CAAC,CAAC,CAAC,GAAG,OAAO,CAAC,CAAC,EAAE,CAAC,CAEzF;IAED,oEAAoE;IAC9D,GAAG,CAAC,CAAC,EAAE,KAAK,EAAE,MAAM,OAAO,CAAC,CAAC,CAAC,GAAG,OAAO,CAAC,CAAC,CAAC,CAiBhD;CACF"}
@@ -21,7 +21,7 @@
21
21
  * `stopped` option.
22
22
  */
23
23
  /** Relay requests that one client has in flight at most. */
24
- export const RELAY_REQUESTS_IN_FLIGHT = 4;
24
+ export const SIGNAL_RELAY_REQUESTS_IN_FLIGHT = 4;
25
25
  /**
26
26
  * One or more items of a fan-out failed. Every item settled before this error.
27
27
  */
@@ -57,7 +57,7 @@ export class BoundedFanOut {
57
57
  inFlight = 0;
58
58
  waiting = [];
59
59
  constructor(options) {
60
- const limit = options.limit ?? RELAY_REQUESTS_IN_FLIGHT;
60
+ const limit = options.limit ?? SIGNAL_RELAY_REQUESTS_IN_FLIGHT;
61
61
  if (!Number.isInteger(limit) || limit < 1) {
62
62
  throw new RangeError(`The fan-out limit must be a positive integer, not ${limit}`);
63
63
  }
@@ -1 +1 @@
1
- {"version":3,"file":"bounded-fan-out.js","sourceRoot":"","sources":["../../utils/bounded-fan-out.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;GAqBG;AAEH,4DAA4D;AAC5D,MAAM,CAAC,MAAM,wBAAwB,GAAG,CAAC,CAAC;AAe1C;;GAEG;AACH,MAAM,OAAO,WAAyB,SAAQ,KAAK;IACjD,qDAAqD;IAC5C,MAAM,CAAqB;IAEpC,gDAAgD;IACvC,QAAQ,CAA8B;IAE/C,YAAY,QAAqC;QAC/C,MAAM,MAAM,GAAG,QAAQ,CAAC,OAAO,CAAC,CAAC,OAAO,E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AAC;YACH,MAAM,MAAM,GAAG,MAAM,KAAK,EAAE,CAAC;YAC7B,IAAI,CAAC,KAAK,GAAG,OAAO,CAAC;YACrB,OAAO,MAAM,CAAC;QAChB,CAAC;QAAC,OAAO,KAAK,EAAE,CAAC;YACf,IAAI,CAAC,KAAK,GAAG,QAAQ,CAAC;YACtB,MAAM,KAAK,CAAC;QACd,CAAC;IACH,CAAC;CACF"}
@@ -33,9 +33,9 @@ export interface SignalProtocolRetryConfig {
33
33
  * Non-retryable:
34
34
  * - The eight codes in NON_RETRYABLE_ERROR_CODES (invalid prekey bundle,
35
35
  * untrusted identity, and the rest)
36
- * - The Relay code UPGRADE_REQUIRED (HostedRelayUpgradeRequiredError)
37
- * - The Relay code DEVICE_REVOKED (HostedRelayDeviceRevokedError)
38
- * - An unknown device (HostedRelayDeviceUnknownError)
36
+ * - The Relay code UPGRADE_REQUIRED (HostedSignalProtocolRelayUpgradeRequiredError)
37
+ * - The Relay code DEVICE_REVOKED (HostedSignalProtocolRelayDeviceRevokedError)
38
+ * - An unknown device (HostedSignalProtocolRelayDeviceUnknownError)
39
39
  *
40
40
  * Retryable:
41
41
  * - Network/timeout errors
@@ -1 +1 @@
1
- {"version":3,"file":"retry.d.ts","sourceRoot":"","sources":["../../utils/retry.ts"],"names":[],"mappings":"AAAA;;;;;;;;GAQG;AAIH;;;;GAIG;AACH,OAAO,EAAE,CAAC;AACV,MAAM,WAAW,yBAAyB;IACxC,qFAAqF;IACrF,UAAU,CAAC,EAAE,MAAM,CAAC;IACpB,yDAAyD;IACzD,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,8DAA8D;IAC9D,YAAY,CAAC,EAAE,OAAO,CAAC;IACvB,8CAA8C;IAC9C,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB,iCAAiC;IACjC,aAAa,CAAC,EAAE,MAAM,CAAC;IACvB,uFAAuF;IACvF,WAAW,CAAC,EAAE,CAAC,KAAK,EAAE,KAAK,KAAK,OAAO,CAAC;CACzC;AAsFD;;;;;;;;;;;;;;;GAeG;AACH,wBAAgB,gBAAgB,CAAC,KAAK,EAAE,KAAK,GAAG,OAAO,CAqCtD;AAED;;;;;;;;;;;;;;;;;GAiBG;AACH,wBAAsB,SAAS,CAAC,CAAC,EAC/B,EAAE,EAAE,MAAM,OAAO,CAAC,CAAC,CAAC,EACpB,MAAM,GAAE,yBAA8B,GACrC,OAAO,CAAC,CAAC,CAAC,CAyCZ"}
1
+ {"version":3,"file":"retry.d.ts","sourceRoot":"","sources":["../../utils/retry.ts"],"names":[],"mappings":"AAAA;;;;;;;;GAQG;AAIH;;;;GAIG;AACH,OAAO,EAAE,CAAC;AACV,MAAM,WAAW,yBAAyB;IACxC,qFAAqF;IACrF,UAAU,CAAC,EAAE,MAAM,CAAC;IACpB,yDAAyD;IACzD,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,8DAA8D;IAC9D,YAAY,CAAC,EAAE,OAAO,CAAC;IACvB,8CAA8C;IAC9C,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB,iCAAiC;IACjC,aAAa,CAAC,EAAE,MAAM,CAAC;IACvB,uFAAuF;IACvF,WAAW,CAAC,EAAE,CAAC,KAAK,EAAE,KAAK,KAAK,OAAO,CAAC;CACzC;AAsFD;;;;;;;;;;;;;;;GAeG;AACH,wBAAgB,gBAAgB,CAAC,KAAK,EAAE,KAAK,GAAG,OAAO,CAsCtD;AAED;;;;;;;;;;;;;;;;;GAiBG;AACH,wBAAsB,SAAS,CAAC,CAAC,EAC/B,EAAE,EAAE,MAAM,OAAO,CAAC,CAAC,CAAC,EACpB,MAAM,GAAE,yBAA8B,GACrC,OAAO,CAAC,CAAC,CAAC,CAyCZ"}
@@ -85,9 +85,9 @@ function isRaceConditionError(error) {
85
85
  * Non-retryable:
86
86
  * - The eight codes in NON_RETRYABLE_ERROR_CODES (invalid prekey bundle,
87
87
  * untrusted identity, and the rest)
88
- * - The Relay code UPGRADE_REQUIRED (HostedRelayUpgradeRequiredError)
89
- * - The Relay code DEVICE_REVOKED (HostedRelayDeviceRevokedError)
90
- * - An unknown device (HostedRelayDeviceUnknownError)
88
+ * - The Relay code UPGRADE_REQUIRED (HostedSignalProtocolRelayUpgradeRequiredError)
89
+ * - The Relay code DEVICE_REVOKED (HostedSignalProtocolRelayDeviceRevokedError)
90
+ * - An unknown device (HostedSignalProtocolRelayDeviceUnknownError)
91
91
  *
92
92
  * Retryable:
93
93
  * - Network/timeout errors
@@ -108,6 +108,7 @@ export function isRetryableError(error) {
108
108
  }
109
109
  // The Relay refuses this device for good. The error name identifies an
110
110
  // unknown device, because its code NOT_FOUND also names other failures.
111
+ // The error keeps its earlier name until SDK 15.0.0.
111
112
  if (code === 'DEVICE_REVOKED' || error.name === 'HostedRelayDeviceUnknownError') {
112
113
  return false;
113
114
  }
@@ -1 +1 @@
1
- {"version":3,"file":"retry.js","sourceRoot":"","sources":["../../utils/retry.ts"],"names":[],"mappings":"AAAA;;;;;;;;GAQG;AAEH,OAAO,EAAE,mBAAmB,EAAE,MAAM,UAAU,CAAC;AAuB/C,MAAM,mBAAmB,GAAG;IAC1B,UAAU,EAAE,CAAC;IACb,SAAS,EAAE,IAAI;IACf,QAAQ,EAAE,KAAK;IACf,iBAAiB,EAAE,CAAC;IACpB,YAAY,EAAE,IAAI;CACnB,CAAC;AAEF;;;;;;;;;;;;;;;GAeG;AACH,MAAM,yBAAyB,GAAG,IAAI,GAAG,CAAC;IACxC,mBAAmB,CAAC,qBAAqB;IACzC,mBAAmB,CAAC,iBAAiB;IACrC,mBAAmB,CAAC,yBAAyB;IAC7C,mBAAmB,CAAC,iBAAiB;IAErC,mBAAmB,CAAC,kBAAkB;IACtC,mBAAmB,CAAC,6BAA6B;IACjD,mBAAmB,CAAC,wBAAwB;IAC5C,mBAAmB,CAAC,yBAAyB;CAC9C,CAAC,CAAC;AAEH,SAAS,KAAK,CAAC,EAAU;IACvB,OAAO,IAAI,OAAO,CAAC,CAAC,OAAO,EAAE,EAAE,CAAC,UAAU,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,QAAQ,GAAG,KAAK,EAChB,aAAa,GAAG,mBAAmB,EACnC,WAAW,GAAG,GAAG,EAAE,CAAC,IAAI,GACzB,GAAG,MAAM,CAAC;IAEX,MAAM,aAAa,GAAG,UAAU,GAAG,CAAC,CAAC;IACrC,IAAI,SAAS,GAAiB,IAAI,CAAC;IAEnC,KAAK,IAAI,OAAO,GAAG,CAAC,EAAE,OAAO,GAAG,aAAa,EAAE,OAAO,EAAE,EAAE,CAAC;QACzD,IAAI,CAAC;YACH,OAAO,MAAM,EAAE,EAAE,CAAC;QACpB,CAAC;QAAC,OAAO,KAAK,EAAE,CAAC;YACf,MAAM,eAAe,GACnB,KAAK,YAAY,KAAK,CAAC,CAAC,CAAC,KAAK,CAAC,CAAC,CAAC,IAAI,KAAK,CAAC,GAAG,aAAa,YAAY,MAAM,CAAC,KAAK,CAAC,EAAE,CAAC,CAAC;YAC1F,SAAS,GAAG,eAAe,CAAC;YAE5B,IACE,OAAO,KAAK,aAAa,GAAG,CAAC;gBAC7B,CAAC,gBAAgB,CAAC,eAAe,CAAC;gBAClC,CAAC,WAAW,CAAC,eAAe,CAAC,EAC7B,CAAC;gBACD,MAAM;YACR,CAAC;YAED,MAAM,KAAK,GAAG,qBAAqB,CACjC,OAAO,EACP,SAAS,EACT,QAAQ,EACR,mBAAmB,CAAC,iBAAiB,EACrC,YAAY,CACb,CAAC;YACF,MAAM,KAAK,CAAC,KAAK,CAAC,CAAC;QACrB,CAAC;IACH,CAAC;IAED,MAAM,SAAS,IAAI,IAAI,KAAK,CAAC,GAAG,aAAa,gCAAgC,CAAC,CAAC;AACjF,CAAC"}
package/docs/ASSURANCE.md CHANGED
@@ -16,16 +16,16 @@ Private testing also exists in other open-source projects. [SQLite publishes som
16
16
 
17
17
  Engineering CI runs the default automated checks on pull requests that are ready for review and on changes to the main branch. Release preparation requires a passing run.
18
18
 
19
- Most recent full run on 2026-11-05:
19
+ Most recent full run on 2026-11-10:
20
20
 
21
21
  | | |
22
22
  |---|---|
23
- | Test modules | 607 |
24
- | Test cases | 12,725 |
25
- | Passed | 12,721 |
23
+ | Test modules | 615 |
24
+ | Test cases | 12,967 |
25
+ | Passed | 12,963 |
26
26
  | Skipped | 4 |
27
27
  | Failed | 0 |
28
- | Wall time | 1513 s |
28
+ | Wall time | 830 s |
29
29
 
30
30
  The total counts test cases. One test case can contain several assertions. Separate commands run the longer performance and endurance checks.
31
31
 
@@ -40,9 +40,9 @@ Release tooling generates this table from a completed run. It refuses results fr
40
40
  - **Storage contracts:** check persistence, concurrency, interruption, recovery, and storage pressure at adapter boundaries.
41
41
  - **Runtime behavior:** run the browser storage contracts in Chromium, Firefox, and WebKit. Run each public flow on the Hermes V1 command-line engine that React Native 0.86 uses. Use only the globals of a bare React Native app. A committed list records each flow step that fails on that engine and its error. The job fails when a result differs from that list.
42
42
 
43
- Run release builds of the Expo example and the bare React Native example on an Android emulator. Both use Hermes V1. The Expo build uses Expo SDK 57 and React Native 0.86. The bare build uses React Native 0.87.1.
43
+ Run release builds of the Expo example and the bare React Native example on an Android emulator. Both use Hermes V1. The Expo build uses Expo SDK 58 and React Native 0.88. The bare build uses React Native 0.87.1.
44
44
  - **Public API:** check exported types, import paths, documented calls, and expected example output against the packed package.
45
- - **React Native hosts:** add the packed package to React Native and Expo projects without an override of peer conflicts. The projects cover React Native 0.83, 0.85, 0.86, and 0.87. They also cover the Expo SDK 55, 56, and 57 lines. Build the Expo example's Hermes bundle on Expo SDK 55 and 57.
45
+ - **React Native hosts:** add the packed package to React Native and Expo projects without an override of peer conflicts. The projects cover React Native 0.83, 0.85, 0.86, and 0.87. They also cover the Expo SDK 55, 56, 57, and 58 lines. Build the Expo example's Hermes bundle on Expo SDK 55 and 58.
46
46
  - **Errors:** check construction sites for exported error classes and codes. Reject unresolved code forwarding.
47
47
 
48
48
  The browser storage job also runs 2,000 open, write, read, and close cycles of the IndexedDB store. It also runs a soak of the web SQLite store. Each checks for upward memory and latency drift.
@@ -92,8 +92,8 @@ The check replaced version 1.0.0 with an ad-hoc signed copy of version 1.0.1 of
92
92
  | A conversion keeps the rows and the schema version, and leaves no pending key. A fault in the copy, after the commit point, or in the copy back leaves a store that the next open finishes. Without the option, the open fails as a key mismatch and names `convertPlaintext`. A build without SQLCipher refuses the option before any write. | Default automated checks: Linux, Node 26 | The same JavaScript layer. This check runs no SQLCipher, so it proves the steps of the conversion and not its encryption. |
93
93
  | A release build of the Expo example stores its state with SQLCipher on Android and keeps it across a process restart. | Android emulator job | A release APK on Hermes V1, run twice on an Android API 36 x86_64 emulator. Each run must log a SQLCipher version and a database header that is not the SQLite header. The second run must resume the stored identity and complete an exchange. This job runs on a change to the main branch that can reach the React Native runtime, and on demand. It does not run on a pull request. |
94
94
  | A release build of the Expo example converts a plaintext database with SQLCipher on Android. The rows and the schema version stay, the file has no SQLite header, and the vault holds one key that opens it. | Android emulator job | The release APK of the row above. Each run must log the number of rows and the schema version that the conversion kept. The same trigger rules apply. |
95
- | The Expo example, which imports this entry, bundles with the Hermes compiler that React Native pins. | Engineering CI | The Android bundle of the Expo example with the packed package, on Expo SDK 55 and Expo SDK 57. |
96
- | In an Expo web build, an encrypted open and a reset fail with `SqliteEncryptionUnavailableError` (`KEY_STORAGE_ERROR`) before they use the vault. With `encryptionAtRest: false`, the store opens and keeps its data across a page load. | Browser storage job: Chromium on Linux | An `expo export --platform web` of an Expo SDK 57 app that installs the packed package, loaded in Chromium. The page reads no `PRAGMA cipher_version` row, and Expo SecureStore reports that it is not available. The check does not open a store with `./local/store/web-sqlite` in the Expo web build. |
95
+ | The Expo example, which imports this entry, bundles with the Hermes compiler that React Native pins. | Engineering CI | The Android bundle of the Expo example with the packed package, on Expo SDK 55 and Expo SDK 58. |
96
+ | In an Expo web build, an encrypted open and a reset fail with `SqliteEncryptionUnavailableError` (`KEY_STORAGE_ERROR`) before they use the vault. With `encryptionAtRest: false`, the store opens and keeps its data across a page load. | Browser storage job: Chromium on Linux | An `expo export --platform web` of an Expo SDK 58 app that installs the packed package, loaded in Chromium. The page reads no `PRAGMA cipher_version` row, and Expo SecureStore reports that it is not available. The check does not open a store with `./local/store/web-sqlite` in the Expo web build. |
97
97
 
98
98
  The Hermes flow job does not load a SQLite store. Its flows use the memory and key-value stores. The Android emulator job is the only CI job that runs the Expo store on Hermes. No check runs the conversion on iOS, so no check verifies it there.
99
99
 
@@ -34,10 +34,12 @@ const signal = await createSignalProtocolClient({
34
34
  the environment connection URL to your application configuration.
35
35
  `getIdentityAssertion` returns a short-lived signed assertion. The hosted
36
36
  factory uses it for device registration and authentication. In a Sandbox
37
- environment, `hostedRelaySandboxIdentity(storage)` supplies it. In a production
38
- project in device-owned mode, `hostedRelayDeviceOwnedIdentity(storage)`
37
+ environment, `hostedSignalProtocolRelaySandboxIdentity(storage)` supplies it. In a production
38
+ project in device-owned mode, `hostedSignalProtocolRelayDeviceOwnedIdentity(storage)`
39
39
  supplies it. In a production project in application-bound mode, it returns an
40
- assertion for the signed-in user from your backend.
40
+ assertion for the signed-in user from your backend. With a
41
+ [native Clerk or Firebase profile](./RECIPES.md#native-provider-profiles), it
42
+ returns the provider token instead.
41
43
 
42
44
  <!-- doc-snippet:skip requires-external-context -->
43
45
  ```ts
@@ -51,7 +53,7 @@ const signal = await createHostedSignalProtocolClient({
51
53
  },
52
54
  hosted: {
53
55
  // The environment-scoped connection URL from the OpenE2EE console.
54
- relayUrl: process.env.EXPO_PUBLIC_OPEN_E2EE_RELAY_URL!,
56
+ relayUrl: process.env.EXPO_PUBLIC_OPEN_E2EE_SIGNAL_RELAY_URL ?? process.env.EXPO_PUBLIC_OPEN_E2EE_RELAY_URL!,
55
57
  // Returns a short-lived signed assertion for the signed-in user.
56
58
  getIdentityAssertion,
57
59
  },
@@ -112,7 +114,7 @@ developer-facing protocol config:
112
114
  import { DefaultSignalProtocolClient } from "@open-e2ee/signal-protocol-sdk";
113
115
 
114
116
  const signal = await DefaultSignalProtocolClient.create(userId, {
115
- // Low-level creation uses the same storage/relay/protocol concepts.
117
+ // Low-level creation uses the same storage, Relay, and protocol concepts.
116
118
  storage,
117
119
  relay,
118
120
  protocol: { postQuantum: "required", braid: "required" },
@@ -98,7 +98,7 @@ model and what is out of scope.
98
98
  | **Delivery receipt lifespan** | Signal's Android client | **Faithful.** A stored receipt is sent only within 1 day after it becomes owed, as Android's receipt job lives for 1 day. The receipt is durable across a restart, as on Android | — | A receipt that cannot go out within 1 day is not sent, and no hook reports it (§8.3) |
99
99
  | **Receive admission bounds** | Signal's Desktop client | **Extension.** Before a decrypt, the receive queue checks `maxItems`, `maxBytes`, and the group share `blockedGroupShare`. The defaults are provisional. Desktop decrypts each envelope as it arrives and bounds stored content only by age and attempts | The SDK shares a storage budget with the application in a browser and on mobile | A refused envelope is not acknowledged. It stays at the Relay and expires there with no local hook. The messages behind it still arrive (§8.5) |
100
100
  | **Legacy received content** | Signal's job migration of a retired format | **Faithful** for unreadable rows: the open deletes them and logs a count. **Deviation** for readable rows: the open deletes each readable SDK 11 row too, and counts it in a separate field. Signal converts each readable pending item to the new format | A founder ruling deletes the readable rows. The constraint is Relay retention: the Relay keeps an undelivered envelope for at most 30 days in production, and a readable row is in a store that SDK 12.0.0 or later never opened | Where the constraint holds, the content of such a row never reaches the application. A device that received the content on SDK 11 inside the last 30 days is not covered: 13.x would complete that row on redelivery, and the sweep does not restore it. The count line holds no key and no value (§8.6) |
101
- | **Relay socket authentication** | Signal's Android client `OkHttpWebSocketConnection`; `libsignal` `chat.rs`; Signal's server `WebSocketDisconnectionRequestListener` | **Faithful.** The mailbox socket sends its credential once, at the handshake, and stays open until the server closes it or it fails. The Relay closes it with 4401 when the authority must be checked again, as Signal's server does. **Deviation** in detail. The handshake credential is a device token that expires after 15 minutes, and the open socket outlives it. The Relay also closes the socket with 4401 at the start of each UTC month | The Relay keeps its device credential short-lived for HTTP requests, and it counts monthly activity at the handshake | A renewal touches only HTTP requests and the next reconnect. An authority change reaches an open socket only through the 4401 close (§9.1) |
101
+ | **Relay socket authentication** | Signal's Android client `OkHttpWebSocketConnection`; `libsignal` `chat.rs`; Signal's server `WebSocketDisconnectionRequestListener` | **Faithful.** The mailbox socket sends its credential once, at the handshake, and stays open until the server closes it or it fails. The Relay closes it with 4401 when the authority must be checked again, as Signal's server does. **Deviation** in detail. The handshake credential is a device token that expires after 15 minutes, and the open socket outlives it. The Relay also closes the socket with 4401 at the end of each usage period | The Relay keeps its device credential short-lived for HTTP requests, and it counts monthly activity at the handshake | A renewal touches only HTTP requests and the next reconnect. An authority change reaches an open socket only through the 4401 close (§9.1) |
102
102
  | **zkgroup / zkcredential** | `libsignal` `zkgroup`, `zkcredential`, `poksho` | **Faithful** port of the Ristretto255 KVAC and Sigma-protocol system, verified against `libsignal`'s known-answer vectors. **Deviation:** server parameter derivation is structured as four labeled derivations rather than one seeded derivation | Server keys are the deploying operator's own trust root (each deployment generates its own seed), not Signal Messenger's | The zero-knowledge properties are real. Credentials are not interchangeable with Signal Messenger's |
103
103
  | **Registration IDs** | `libsignal` `sealed_sender.rs` | **Faithful.** Generated in `[1, 16383]`, strictly inside the 14 bits the wire format reserves | — | — |
104
104
  | **Linked-device registration IDs** | Signal's device linking | **Faithful** for a new link: the linked device gets its own fresh registration ID. **Deviation:** a device that a 12.0.x release linked keeps the ID of its active device, and a link that a 12.0.x release began keeps its stored ID (§5.7) | A changed ID on a live device fails its next prekey sync. A fresh ID on a link already begun can reserve a second device | Two devices of one account can share a registration ID. The sender-key handoff ledger keys each row by the device, so they stay apart |
@@ -779,7 +779,7 @@ removal clause is strict: the cleanup deletes the record only when
779
779
  removal is therefore gone from the Relay before `maxLatency` passes after the
780
780
  removal, and the record outlives it. The §3.1 guarantee for messages in flight
781
781
  thus holds without a fetch of the whole mailbox. The Convex relay keeps a
782
- message for 7 days (`remote/relay/convex/component/messages.ts:18`), so the
782
+ message for 7 days (`remote/signal-relay/convex/component/messages.ts:18`), so the
783
783
  bound holds there too.
784
784
 
785
785
  Two caveats limit the bound:
@@ -996,7 +996,7 @@ A retry request has its own posting deadline, in row P9. The following details d
996
996
 
997
997
  | ID | Deviation | Constraint | Why Signal's form does not fit | Guarantee test |
998
998
  |---|---|---|---|---|
999
- | P1 | The deadline is the earlier of 24 hours after the SDK first stores the send and 24 hours after its `clientTimestamp` | The epoch of each post is the send timestamp, and the Relay admits an epoch at most 24 hours behind its clock. A founder ruling sets this term | Signal has no caller timestamp and no admission window | A send backdated by 23 hours posts inside the remaining hour and posts nothing after it. A send backdated by 24 hours posts nothing and throws `SendNeverAcceptedByRelayError` |
999
+ | P1 | The deadline is the earlier of 24 hours after the SDK first stores the send and 24 hours after its `clientTimestamp` | The epoch of each post is the send timestamp, and the Relay admits an epoch at most 24 hours behind its clock. A founder ruling sets this term | Signal has no caller timestamp and no admission window | A send backdated by 23 hours posts inside the remaining hour and posts nothing after it. A send backdated by 24 hours posts nothing and throws `SendNeverAcceptedBySignalProtocolRelayError` |
1000
1000
  | P2 | The deadline has no message-expiry term | The SDK has no message expiry. `SendOptions.expiresIn` is a future feature. The founder ruling "DA1 F1 posting window terms: the 24-hour terms only, no expiry term until a message expiry feature exists (2026-10-28, founder)" sets this term. When that feature ships, its timer starts after acceptance and controls local deletion only, and it never ends a pending post | Signal starts its expiry timer after the send | The stored deadline is 24 hours after the clock read that first stores the send, with no other term. At `deadlineAt` plus 1 ms, a replay of a declared or an undeclared send posts nothing and throws `SendAcceptanceUnknownError` |
1001
1001
  | P3 | A replay, a restart or a repair never moves the deadline | The deadline bounds the age of the kept epoch, and the Relay refuses an older epoch. A founder ruling says that retries and restarts never reset it | Signal's Android client starts a new job for a pending send | The deadline after a replay, a restart and a repair equals the first stored value. The deadline read after a restart equals the stored value |
1002
1002
  | P4 | A device whose Relay answer is lost, or whose answer follows an uncertain request, ends acceptance-unknown, not failed | The Relay can accept a post whose answer the SDK does not get, and a later post under the same ID can add one charged unit | Signal's Desktop client shows such a send as failed | An unanswered post and then an `OPERATION_EXPIRED` refusal end with `SendAcceptanceUnknownError`. A replay with no stored evidence for a device does not count that device as refused |
@@ -1713,8 +1713,11 @@ purpose (`WebSocketDisconnectionRequestListener.java:31`).
1713
1713
  password. The Relay credential is a device token that expires 15 minutes
1714
1714
  after it is issued. The open socket outlives the token. The hosted transport
1715
1715
  renews the token only when an HTTP request or a reconnect needs it. The Relay
1716
- also closes the socket with 4401 at the start of each UTC month, so that a
1717
- long-lived socket counts once in the monthly activity of the new month.
1716
+ also closes the socket with 4401 at the end of the usage period that the
1717
+ handshake counted in, which is the end of the billing period for a paid
1718
+ Production project and the start of the next UTC month for other projects, so
1719
+ that a long-lived socket counts once in the monthly activity of the next
1720
+ period.
1718
1721
 
1719
1722
  The constraint is that the Relay issues a short-lived device token and checks
1720
1723
  it on each HTTP request. A device that only receives sends no pull, so the
@@ -85,7 +85,7 @@ holds each member to a production construction site.
85
85
  | `ENCRYPTION_FAILED` | The SDK could not encrypt the message. | Inspect the session state and `originalError`. |
86
86
  | `INVALID_SEND_TIMESTAMP` | A new send carries a `timestamp`, or a sync to linked devices carries an application time, that is not a safe positive integer, or that is more than 5 minutes ahead of or more than 24 hours behind the SDK clock. A new send also gets it for a `timestamp` that a different send of the device used. The SDK's own sends, the profile key offer and the sender key distribution, reserve from the same index of the device, so an application that passes `timestamp: Date.now()` can get `already_used` when it did not use the value again itself. The SDK throws `InvalidSendTimestampError` from `@open-e2ee/signal-protocol-sdk/types` and stores or posts nothing for the send. The `reason` is `not_safe_positive_integer`, `too_far_ahead`, `too_old` or `already_used`. `earliest` and `latest` give the window, and are absent for `already_used`. | Omit `timestamp`, so that the SDK picks a free value. On `already_used`, send again with no timestamp. Otherwise send again with a timestamp in the window that no other send used. |
87
87
  | `SEND_ACCEPTANCE_UNKNOWN` | The posting deadline of a direct or group send ended, and the Relay acceptance of a device is not known. The SDK throws `SendAcceptanceUnknownError` from `@open-e2ee/signal-protocol-sdk/types`. The message might have arrived. | Tell the user that the message might already have arrived. Do not replay the send. |
88
- | `SEND_NEVER_ACCEPTED` | The posting deadline of a direct or group send ended, the call raised no refusal (a thrown refusal or a refusal in the receipt of a shared body), and no refused device has a stored refusal code. The SDK throws `SendNeverAcceptedByRelayError` from `@open-e2ee/signal-protocol-sdk/types`. | Tell the user which devices did not get the message. |
88
+ | `SEND_NEVER_ACCEPTED` | The posting deadline of a direct or group send ended, the call raised no refusal (a thrown refusal or a refusal in the receipt of a shared body), and no refused device has a stored refusal code. The SDK throws `SendNeverAcceptedBySignalProtocolRelayError` from `@open-e2ee/signal-protocol-sdk/types`. | Tell the user which devices did not get the message. |
89
89
  | `MESSAGE_DUPLICATE` | The session processed this message before. | Discard the duplicate. |
90
90
  | `TOO_MANY_SKIPPED_MESSAGES` | The message exceeded the skipped-key bound. | Reset the affected session. |
91
91
  | `REPLAY_DETECTED` | Envelope and encrypted-content timestamps differ. | Reject the message as a replay. |
@@ -162,7 +162,7 @@ that set. Neither is an `EncryptionError`.
162
162
 
163
163
  | Error | Cause | Application response |
164
164
  |---|---|---|
165
- | `HostedRelayUpgradeRequiredError` | The Relay no longer serves the version that the client sent. The message names that version. `code` is `UPGRADE_REQUIRED`, `status` is the HTTP status (426), and `retryable` is false. | Ship a newer SDK. The same request fails again, so do not retry it. |
165
+ | `HostedSignalProtocolRelayUpgradeRequiredError` | The Relay no longer serves the version that the client sent. The message names that version. `code` is `UPGRADE_REQUIRED`, `status` is the HTTP status (426), and `retryable` is false. | Ship a newer SDK. The same request fails again, so do not retry it. |
166
166
  | `PROTOCOL_UNSUPPORTED` | The Relay does not serve version 2. The request fails with status 400, the `code` `PROTOCOL_UNSUPPORTED`, and `retryable` true. A send keeps the device open until its posting deadline. | Retry later. The Relay never rolls back below a version that a published SDK sends, so this is a transient fault, not a planned state. |
167
167
 
168
168
  Version 2 adds one Relay code, `DELIVERY_ALREADY_ACCEPTED`. The Relay gives it
@@ -185,7 +185,7 @@ cannot count the answer as an acceptance. Handle it as `RETRY_CONFLICT`.
185
185
 
186
186
  The SDK does not retry an HTTP request that `UPGRADE_REQUIRED` refuses. Each
187
187
  Relay route that answers with a JSON body throws
188
- `HostedRelayUpgradeRequiredError`. An attachment download does not read the
188
+ `HostedSignalProtocolRelayUpgradeRequiredError`. An attachment download does not read the
189
189
  response body, so it reports the 426 as a
190
190
  [`MediaAttachmentError`](./api/namespaces/media/classes/MediaAttachmentError.md)
191
191
  with the code `download-failed` and the `status` 426.
@@ -193,7 +193,7 @@ with the code `download-failed` and the `status` 426.
193
193
  The mailbox subscription stops for the same refusal on its socket, with the
194
194
  state `stopped` and the reason `upgrade-required`. It does not reconnect and
195
195
  does not pull. For `PROTOCOL_UNSUPPORTED` on its socket, the subscription
196
- reconnects with its usual backoff. See [`RelayConnectionReason`](./api/type-aliases/RelayConnectionReason.md).
196
+ reconnects with its usual backoff. See [`SignalProtocolRelayConnectionReason`](./api/type-aliases/SignalProtocolRelayConnectionReason.md).
197
197
 
198
198
  The subscription also stops when the Relay refuses its socket token request or
199
199
  a pull conclusively. The refusal has `retryable` false and the code
@@ -201,8 +201,8 @@ a pull conclusively. The refusal has `retryable` false and the code
201
201
  and the reason is `authority-refused`. A refusal with `retryable` true, for
202
202
  example a missing Relay binding, goes to the retry schedule. A `NOT_FOUND` on
203
203
  the socket token request is a refusal of this device instead, as
204
- [Relay Device Errors](#relay-device-errors) describes. See
205
- [`RelayConnectionState`](./api/interfaces/RelayConnectionState.md).
204
+ [Signal Protocol Relay Device Errors](#signal-protocol-relay-device-errors) describes. See
205
+ [`SignalProtocolRelayConnectionState`](./api/interfaces/SignalProtocolRelayConnectionState.md).
206
206
 
207
207
  A client call can wrap the error in an `EncryptionError`. It is then the
208
208
  `originalError`.
@@ -211,14 +211,14 @@ A client call can wrap the error in an `EncryptionError`. It is then the
211
211
  ```typescript
212
212
  import {
213
213
  EncryptionError,
214
- HostedRelayUpgradeRequiredError,
214
+ HostedSignalProtocolRelayUpgradeRequiredError,
215
215
  } from '@open-e2ee/signal-protocol-sdk';
216
216
 
217
217
  function upgradeRequired(error: unknown): boolean {
218
218
  return (
219
- error instanceof HostedRelayUpgradeRequiredError ||
219
+ error instanceof HostedSignalProtocolRelayUpgradeRequiredError ||
220
220
  (error instanceof EncryptionError &&
221
- error.originalError instanceof HostedRelayUpgradeRequiredError)
221
+ error.originalError instanceof HostedSignalProtocolRelayUpgradeRequiredError)
222
222
  );
223
223
  }
224
224
 
@@ -366,7 +366,7 @@ the rule below. The two deadline classes come from
366
366
  | Error | Cause | Application response |
367
367
  |---|---|---|
368
368
  | `SendAcceptanceUnknownError` | The Relay acceptance of a device is not known. An answer was lost, or it followed an uncertain request | Tell the user that the message might already have arrived. Do not replay the send |
369
- | `SendNeverAcceptedByRelayError` | The Relay accepted no request for an open device, the call raised no refusal, and no refused device has a stored refusal code. No request started before the deadline, or each answer was a refusal for now, such as `QUOTA_EXCEEDED` | Tell the user which devices did not get the message |
369
+ | `SendNeverAcceptedBySignalProtocolRelayError` | The Relay accepted no request for an open device, the call raised no refusal, and no refused device has a stored refusal code. No request started before the deadline, or each answer was a refusal for now, such as `QUOTA_EXCEEDED` | Tell the user which devices did not get the message |
370
370
 
371
371
  When no device has an unknown acceptance, the send ends failed, and one rule
372
372
  gives its error:
@@ -377,7 +377,7 @@ gives its error:
377
377
  receipt is an `Error` with the `code` of that refusal.
378
378
  2. Otherwise, the error is an `Error` with the stored `code` of the first
379
379
  refused device that has one, in the order of the destinations.
380
- 3. Otherwise, the error is `SendNeverAcceptedByRelayError` with code
380
+ 3. Otherwise, the error is `SendNeverAcceptedBySignalProtocolRelayError` with code
381
381
  `SEND_NEVER_ACCEPTED`.
382
382
 
383
383
  A replay of the ended send raises no refusal, so its error comes from case 2
@@ -433,7 +433,7 @@ device, the replay completes the send and returns the result without
433
433
  The Relay marks each accepted declared post with `deviceSetChecked`. When an
434
434
  accepted post has no mark, the Relay did not compare its device set. The send
435
435
  is delivered and its result does not change. The client reports a
436
- [`RelayProtocolError`](./api/classes/RelayProtocolError.md) with the code
436
+ [`SignalProtocolRelayProtocolError`](./api/classes/SignalProtocolRelayProtocolError.md) with the code
437
437
  `DEVICE_SET_UNCHECKED` once for the send through the `onRelayProtocolError`
438
438
  hook. Its `route` names the post route. A sync copy to another own device is
439
439
  an `identified-direct` post. A sync payload of a method such as
@@ -446,7 +446,7 @@ A relay that does not compare device sets gets no declaration. The Convex
446
446
  relay is one. With it, the SDK reads the device lists as before, and none of
447
447
  these errors occur.
448
448
 
449
- ## Relay Device Errors
449
+ ## Signal Protocol Relay Device Errors
450
450
 
451
451
  The Relay can refuse this device, and a managed device link can refuse its
452
452
  linked store. Three errors name these refusals. None is an `EncryptionError`,
@@ -454,16 +454,16 @@ and the SDK retries none of them.
454
454
 
455
455
  | Error | Cause | Application response |
456
456
  |---|---|---|
457
- | [`HostedRelayDeviceRevokedError`](./api/classes/HostedRelayDeviceRevokedError.md) | An account recovery revoked this device. `code` is `DEVICE_REVOKED`, `status` is 403, and `retryable` is false. | Sign the user out of this device. The Relay refuses a registration with the revoked key, so a re-registration fails too. |
458
- | [`HostedRelayDeviceUnknownError`](./api/classes/HostedRelayDeviceUnknownError.md) | The Relay has no device for the stored session. `code` is `NOT_FOUND`, `status` is 404, and `retryable` is false. The message is the Relay's own message. | Ask the user to confirm a re-registration of this device. Do not re-register without that confirmation. |
459
- | [`HostedRelayDeviceLinkError`](./api/classes/HostedRelayDeviceLinkError.md) | `linkHostedRelayDevice` found state in the linked store that the link did not write: a group in the linked group store, or a device-authentication key for this Relay connection with no registration of this link. `code` is `DEVICE_LINK_STORE_NOT_EMPTY`, and `retryable` is false. The link wrote nothing. | Link the device again with a new, empty store. The same store is refused again. |
457
+ | [`HostedSignalProtocolRelayDeviceRevokedError`](./api/classes/HostedSignalProtocolRelayDeviceRevokedError.md) | An account recovery revoked this device. `code` is `DEVICE_REVOKED`, `status` is 403, and `retryable` is false. | Sign the user out of this device. The Relay refuses a registration with the revoked key, so a re-registration fails too. |
458
+ | [`HostedSignalProtocolRelayDeviceUnknownError`](./api/classes/HostedSignalProtocolRelayDeviceUnknownError.md) | The Relay has no device for the stored session. `code` is `NOT_FOUND`, `status` is 404, and `retryable` is false. The message is the Relay's own message. | Ask the user to confirm a re-registration of this device. Do not re-register without that confirmation. |
459
+ | [`HostedSignalProtocolRelayDeviceLinkError`](./api/classes/HostedSignalProtocolRelayDeviceLinkError.md) | `linkHostedSignalProtocolRelayDevice` found state in the linked store that the link did not write: a group in the linked group store, or a device-authentication key for this Relay connection with no registration of this link. `code` is `DEVICE_LINK_STORE_NOT_EMPTY`, and `retryable` is false. The link wrote nothing. | Link the device again with a new, empty store. The same store is refused again. |
460
460
 
461
461
  `createHostedSignalProtocolClient` throws the first two errors when the stored
462
462
  session cannot get a device token. It does not register a new device in their
463
463
  place. A running client throws them from its Relay calls. A client call can
464
464
  wrap them in an `EncryptionError`, as the `originalError`. The mailbox subscription
465
465
  stops with the reason `device-revoked` or `device-unknown`. See
466
- [`RelayConnectionReason`](./api/type-aliases/RelayConnectionReason.md).
466
+ [`SignalProtocolRelayConnectionReason`](./api/type-aliases/SignalProtocolRelayConnectionReason.md).
467
467
 
468
468
  To re-register, create the client again with `assertionPurpose: 'reregister'`.
469
469
  It keeps the stored identity and device key, and it asks for a `register`
@@ -485,18 +485,18 @@ A re-registration has these effects:
485
485
  <!-- doc-snippet:skip requires-existing-client -->
486
486
  ```typescript
487
487
  import {
488
- HostedRelayDeviceRevokedError,
489
- HostedRelayDeviceUnknownError,
488
+ HostedSignalProtocolRelayDeviceRevokedError,
489
+ HostedSignalProtocolRelayDeviceUnknownError,
490
490
  createHostedSignalProtocolClient,
491
491
  } from '@open-e2ee/signal-protocol-sdk';
492
492
 
493
493
  try {
494
494
  signal = await createHostedSignalProtocolClient(options);
495
495
  } catch (error) {
496
- if (error instanceof HostedRelayDeviceRevokedError) {
496
+ if (error instanceof HostedSignalProtocolRelayDeviceRevokedError) {
497
497
  signOutThisDevice();
498
498
  } else if (
499
- error instanceof HostedRelayDeviceUnknownError &&
499
+ error instanceof HostedSignalProtocolRelayDeviceUnknownError &&
500
500
  (await confirmReregistration())
501
501
  ) {
502
502
  signal = await createHostedSignalProtocolClient({