@atproto/pds 0.4.28 → 0.4.30

Sign up to get free protection for your applications and to get access to all the features.
Files changed (347) hide show
  1. package/CHANGELOG.md +16 -0
  2. package/dist/account-manager/helpers/account.d.ts +20 -1
  3. package/dist/account-manager/helpers/account.d.ts.map +1 -1
  4. package/dist/account-manager/helpers/account.js +32 -7
  5. package/dist/account-manager/helpers/account.js.map +1 -1
  6. package/dist/account-manager/index.d.ts +7 -2
  7. package/dist/account-manager/index.d.ts.map +1 -1
  8. package/dist/account-manager/index.js +24 -8
  9. package/dist/account-manager/index.js.map +1 -1
  10. package/dist/api/app/bsky/actor/getPreferences.js +1 -1
  11. package/dist/api/app/bsky/actor/getPreferences.js.map +1 -1
  12. package/dist/api/app/bsky/actor/getProfile.js +1 -1
  13. package/dist/api/app/bsky/actor/getProfile.js.map +1 -1
  14. package/dist/api/app/bsky/actor/getProfiles.js +1 -1
  15. package/dist/api/app/bsky/actor/getProfiles.js.map +1 -1
  16. package/dist/api/app/bsky/actor/putPreferences.js +1 -1
  17. package/dist/api/app/bsky/actor/putPreferences.js.map +1 -1
  18. package/dist/api/app/bsky/feed/getActorLikes.js +1 -1
  19. package/dist/api/app/bsky/feed/getActorLikes.js.map +1 -1
  20. package/dist/api/app/bsky/feed/getAuthorFeed.js +1 -1
  21. package/dist/api/app/bsky/feed/getAuthorFeed.js.map +1 -1
  22. package/dist/api/app/bsky/feed/getFeed.js +1 -1
  23. package/dist/api/app/bsky/feed/getFeed.js.map +1 -1
  24. package/dist/api/app/bsky/feed/getPostThread.js +1 -1
  25. package/dist/api/app/bsky/feed/getPostThread.js.map +1 -1
  26. package/dist/api/app/bsky/feed/getTimeline.js +1 -1
  27. package/dist/api/app/bsky/feed/getTimeline.js.map +1 -1
  28. package/dist/api/app/bsky/notification/registerPush.d.ts.map +1 -1
  29. package/dist/api/app/bsky/notification/registerPush.js +4 -1
  30. package/dist/api/app/bsky/notification/registerPush.js.map +1 -1
  31. package/dist/api/chat/index.js +14 -14
  32. package/dist/api/chat/index.js.map +1 -1
  33. package/dist/api/com/atproto/admin/deleteAccount.d.ts.map +1 -1
  34. package/dist/api/com/atproto/admin/deleteAccount.js +4 -2
  35. package/dist/api/com/atproto/admin/deleteAccount.js.map +1 -1
  36. package/dist/api/com/atproto/admin/getAccountInfo.d.ts.map +1 -1
  37. package/dist/api/com/atproto/admin/getAccountInfo.js +1 -0
  38. package/dist/api/com/atproto/admin/getAccountInfo.js.map +1 -1
  39. package/dist/api/com/atproto/admin/getSubjectStatus.d.ts.map +1 -1
  40. package/dist/api/com/atproto/admin/getSubjectStatus.js +4 -3
  41. package/dist/api/com/atproto/admin/getSubjectStatus.js.map +1 -1
  42. package/dist/api/com/atproto/admin/updateAccountHandle.js +1 -1
  43. package/dist/api/com/atproto/admin/updateAccountHandle.js.map +1 -1
  44. package/dist/api/com/atproto/admin/updateSubjectStatus.d.ts.map +1 -1
  45. package/dist/api/com/atproto/admin/updateSubjectStatus.js +2 -0
  46. package/dist/api/com/atproto/admin/updateSubjectStatus.js.map +1 -1
  47. package/dist/api/com/atproto/identity/getRecommendedDidCredentials.js +1 -1
  48. package/dist/api/com/atproto/identity/getRecommendedDidCredentials.js.map +1 -1
  49. package/dist/api/com/atproto/identity/requestPlcOperationSignature.js +1 -1
  50. package/dist/api/com/atproto/identity/requestPlcOperationSignature.js.map +1 -1
  51. package/dist/api/com/atproto/identity/signPlcOperation.js +1 -1
  52. package/dist/api/com/atproto/identity/signPlcOperation.js.map +1 -1
  53. package/dist/api/com/atproto/identity/submitPlcOperation.d.ts.map +1 -1
  54. package/dist/api/com/atproto/identity/submitPlcOperation.js +1 -1
  55. package/dist/api/com/atproto/identity/submitPlcOperation.js.map +1 -1
  56. package/dist/api/com/atproto/identity/updateHandle.js +2 -2
  57. package/dist/api/com/atproto/identity/updateHandle.js.map +1 -1
  58. package/dist/api/com/atproto/repo/applyWrites.d.ts.map +1 -1
  59. package/dist/api/com/atproto/repo/applyWrites.js +4 -1
  60. package/dist/api/com/atproto/repo/applyWrites.js.map +1 -1
  61. package/dist/api/com/atproto/repo/createRecord.d.ts.map +1 -1
  62. package/dist/api/com/atproto/repo/createRecord.js +4 -1
  63. package/dist/api/com/atproto/repo/createRecord.js.map +1 -1
  64. package/dist/api/com/atproto/repo/deleteRecord.d.ts.map +1 -1
  65. package/dist/api/com/atproto/repo/deleteRecord.js +4 -1
  66. package/dist/api/com/atproto/repo/deleteRecord.js.map +1 -1
  67. package/dist/api/com/atproto/repo/describeRepo.d.ts.map +1 -1
  68. package/dist/api/com/atproto/repo/describeRepo.js +2 -4
  69. package/dist/api/com/atproto/repo/describeRepo.js.map +1 -1
  70. package/dist/api/com/atproto/repo/importRepo.d.ts.map +1 -1
  71. package/dist/api/com/atproto/repo/importRepo.js +3 -1
  72. package/dist/api/com/atproto/repo/importRepo.js.map +1 -1
  73. package/dist/api/com/atproto/repo/listMissingBlobs.js +1 -1
  74. package/dist/api/com/atproto/repo/listMissingBlobs.js.map +1 -1
  75. package/dist/api/com/atproto/repo/putRecord.d.ts.map +1 -1
  76. package/dist/api/com/atproto/repo/putRecord.js +4 -1
  77. package/dist/api/com/atproto/repo/putRecord.js.map +1 -1
  78. package/dist/api/com/atproto/repo/uploadBlob.d.ts.map +1 -1
  79. package/dist/api/com/atproto/repo/uploadBlob.js +3 -1
  80. package/dist/api/com/atproto/repo/uploadBlob.js.map +1 -1
  81. package/dist/api/com/atproto/server/activateAccount.d.ts.map +1 -1
  82. package/dist/api/com/atproto/server/activateAccount.js +3 -2
  83. package/dist/api/com/atproto/server/activateAccount.js.map +1 -1
  84. package/dist/api/com/atproto/server/checkAccountStatus.js +1 -1
  85. package/dist/api/com/atproto/server/checkAccountStatus.js.map +1 -1
  86. package/dist/api/com/atproto/server/confirmEmail.js +1 -1
  87. package/dist/api/com/atproto/server/confirmEmail.js.map +1 -1
  88. package/dist/api/com/atproto/server/createAccount.d.ts.map +1 -1
  89. package/dist/api/com/atproto/server/createAccount.js +4 -2
  90. package/dist/api/com/atproto/server/createAccount.js.map +1 -1
  91. package/dist/api/com/atproto/server/createAppPassword.d.ts.map +1 -1
  92. package/dist/api/com/atproto/server/createAppPassword.js +3 -1
  93. package/dist/api/com/atproto/server/createAppPassword.js.map +1 -1
  94. package/dist/api/com/atproto/server/createSession.d.ts.map +1 -1
  95. package/dist/api/com/atproto/server/createSession.js +2 -0
  96. package/dist/api/com/atproto/server/createSession.js.map +1 -1
  97. package/dist/api/com/atproto/server/deactivateAccount.d.ts.map +1 -1
  98. package/dist/api/com/atproto/server/deactivateAccount.js +3 -1
  99. package/dist/api/com/atproto/server/deactivateAccount.js.map +1 -1
  100. package/dist/api/com/atproto/server/deleteAccount.d.ts.map +1 -1
  101. package/dist/api/com/atproto/server/deleteAccount.js +4 -3
  102. package/dist/api/com/atproto/server/deleteAccount.js.map +1 -1
  103. package/dist/api/com/atproto/server/getAccountInviteCodes.js +1 -1
  104. package/dist/api/com/atproto/server/getAccountInviteCodes.js.map +1 -1
  105. package/dist/api/com/atproto/server/getServiceAuth.js +1 -1
  106. package/dist/api/com/atproto/server/getServiceAuth.js.map +1 -1
  107. package/dist/api/com/atproto/server/getSession.d.ts.map +1 -1
  108. package/dist/api/com/atproto/server/getSession.js +7 -2
  109. package/dist/api/com/atproto/server/getSession.js.map +1 -1
  110. package/dist/api/com/atproto/server/listAppPasswords.js +1 -1
  111. package/dist/api/com/atproto/server/listAppPasswords.js.map +1 -1
  112. package/dist/api/com/atproto/server/refreshSession.d.ts.map +1 -1
  113. package/dist/api/com/atproto/server/refreshSession.js +2 -0
  114. package/dist/api/com/atproto/server/refreshSession.js.map +1 -1
  115. package/dist/api/com/atproto/server/requestAccountDelete.js +1 -1
  116. package/dist/api/com/atproto/server/requestAccountDelete.js.map +1 -1
  117. package/dist/api/com/atproto/server/requestEmailConfirmation.js +1 -1
  118. package/dist/api/com/atproto/server/requestEmailConfirmation.js.map +1 -1
  119. package/dist/api/com/atproto/server/requestEmailUpdate.js +1 -1
  120. package/dist/api/com/atproto/server/requestEmailUpdate.js.map +1 -1
  121. package/dist/api/com/atproto/server/revokeAppPassword.js +1 -1
  122. package/dist/api/com/atproto/server/revokeAppPassword.js.map +1 -1
  123. package/dist/api/com/atproto/server/updateEmail.js +1 -1
  124. package/dist/api/com/atproto/server/updateEmail.js.map +1 -1
  125. package/dist/api/com/atproto/server/util.d.ts +1 -0
  126. package/dist/api/com/atproto/server/util.d.ts.map +1 -1
  127. package/dist/api/com/atproto/server/util.js +9 -6
  128. package/dist/api/com/atproto/server/util.js.map +1 -1
  129. package/dist/api/com/atproto/sync/deprecated/getCheckout.d.ts.map +1 -1
  130. package/dist/api/com/atproto/sync/deprecated/getCheckout.js +2 -8
  131. package/dist/api/com/atproto/sync/deprecated/getCheckout.js.map +1 -1
  132. package/dist/api/com/atproto/sync/deprecated/getHead.d.ts.map +1 -1
  133. package/dist/api/com/atproto/sync/deprecated/getHead.js +2 -7
  134. package/dist/api/com/atproto/sync/deprecated/getHead.js.map +1 -1
  135. package/dist/api/com/atproto/sync/getBlob.d.ts.map +1 -1
  136. package/dist/api/com/atproto/sync/getBlob.js +3 -6
  137. package/dist/api/com/atproto/sync/getBlob.js.map +1 -1
  138. package/dist/api/com/atproto/sync/getBlocks.d.ts.map +1 -1
  139. package/dist/api/com/atproto/sync/getBlocks.js +2 -7
  140. package/dist/api/com/atproto/sync/getBlocks.js.map +1 -1
  141. package/dist/api/com/atproto/sync/getLatestCommit.d.ts.map +1 -1
  142. package/dist/api/com/atproto/sync/getLatestCommit.js +2 -7
  143. package/dist/api/com/atproto/sync/getLatestCommit.js.map +1 -1
  144. package/dist/api/com/atproto/sync/getRecord.d.ts.map +1 -1
  145. package/dist/api/com/atproto/sync/getRecord.js +2 -7
  146. package/dist/api/com/atproto/sync/getRecord.js.map +1 -1
  147. package/dist/api/com/atproto/sync/getRepo.d.ts.map +1 -1
  148. package/dist/api/com/atproto/sync/getRepo.js +2 -7
  149. package/dist/api/com/atproto/sync/getRepo.js.map +1 -1
  150. package/dist/api/com/atproto/sync/getRepoStatus.d.ts +4 -0
  151. package/dist/api/com/atproto/sync/getRepoStatus.d.ts.map +1 -0
  152. package/dist/api/com/atproto/sync/getRepoStatus.js +28 -0
  153. package/dist/api/com/atproto/sync/getRepoStatus.js.map +1 -0
  154. package/dist/api/com/atproto/sync/index.d.ts.map +1 -1
  155. package/dist/api/com/atproto/sync/index.js +2 -0
  156. package/dist/api/com/atproto/sync/index.js.map +1 -1
  157. package/dist/api/com/atproto/sync/listBlobs.d.ts.map +1 -1
  158. package/dist/api/com/atproto/sync/listBlobs.js +2 -8
  159. package/dist/api/com/atproto/sync/listBlobs.js.map +1 -1
  160. package/dist/api/com/atproto/sync/listRepos.d.ts.map +1 -1
  161. package/dist/api/com/atproto/sync/listRepos.js +13 -8
  162. package/dist/api/com/atproto/sync/listRepos.js.map +1 -1
  163. package/dist/api/com/atproto/sync/subscribeRepos.d.ts.map +1 -1
  164. package/dist/api/com/atproto/sync/subscribeRepos.js +8 -0
  165. package/dist/api/com/atproto/sync/subscribeRepos.js.map +1 -1
  166. package/dist/api/com/atproto/sync/util.d.ts +4 -0
  167. package/dist/api/com/atproto/sync/util.d.ts.map +1 -0
  168. package/dist/api/com/atproto/sync/util.js +25 -0
  169. package/dist/api/com/atproto/sync/util.js.map +1 -0
  170. package/dist/api/com/atproto/temp/checkSignupQueue.d.ts.map +1 -1
  171. package/dist/api/com/atproto/temp/checkSignupQueue.js +4 -1
  172. package/dist/api/com/atproto/temp/checkSignupQueue.js.map +1 -1
  173. package/dist/auth-verifier.d.ts +13 -7
  174. package/dist/auth-verifier.d.ts.map +1 -1
  175. package/dist/auth-verifier.js +29 -46
  176. package/dist/auth-verifier.js.map +1 -1
  177. package/dist/index.d.ts +1 -0
  178. package/dist/index.d.ts.map +1 -1
  179. package/dist/index.js +3 -1
  180. package/dist/index.js.map +1 -1
  181. package/dist/lexicon/index.d.ts +2 -0
  182. package/dist/lexicon/index.d.ts.map +1 -1
  183. package/dist/lexicon/index.js +4 -0
  184. package/dist/lexicon/index.js.map +1 -1
  185. package/dist/lexicon/lexicons.d.ts +145 -0
  186. package/dist/lexicon/lexicons.d.ts.map +1 -1
  187. package/dist/lexicon/lexicons.js +225 -4
  188. package/dist/lexicon/lexicons.js.map +1 -1
  189. package/dist/lexicon/types/chat/bsky/convo/defs.d.ts +1 -1
  190. package/dist/lexicon/types/com/atproto/admin/defs.d.ts +1 -0
  191. package/dist/lexicon/types/com/atproto/admin/defs.d.ts.map +1 -1
  192. package/dist/lexicon/types/com/atproto/admin/defs.js.map +1 -1
  193. package/dist/lexicon/types/com/atproto/admin/getSubjectStatus.d.ts +1 -0
  194. package/dist/lexicon/types/com/atproto/admin/getSubjectStatus.d.ts.map +1 -1
  195. package/dist/lexicon/types/com/atproto/server/createSession.d.ts +3 -0
  196. package/dist/lexicon/types/com/atproto/server/createSession.d.ts.map +1 -1
  197. package/dist/lexicon/types/com/atproto/server/getSession.d.ts +3 -0
  198. package/dist/lexicon/types/com/atproto/server/getSession.d.ts.map +1 -1
  199. package/dist/lexicon/types/com/atproto/server/refreshSession.d.ts +3 -0
  200. package/dist/lexicon/types/com/atproto/server/refreshSession.d.ts.map +1 -1
  201. package/dist/lexicon/types/com/atproto/sync/getBlob.d.ts +1 -0
  202. package/dist/lexicon/types/com/atproto/sync/getBlob.d.ts.map +1 -1
  203. package/dist/lexicon/types/com/atproto/sync/getBlocks.d.ts +1 -0
  204. package/dist/lexicon/types/com/atproto/sync/getBlocks.d.ts.map +1 -1
  205. package/dist/lexicon/types/com/atproto/sync/getLatestCommit.d.ts +1 -1
  206. package/dist/lexicon/types/com/atproto/sync/getLatestCommit.d.ts.map +1 -1
  207. package/dist/lexicon/types/com/atproto/sync/getRecord.d.ts +1 -0
  208. package/dist/lexicon/types/com/atproto/sync/getRecord.d.ts.map +1 -1
  209. package/dist/lexicon/types/com/atproto/sync/getRepo.d.ts +1 -0
  210. package/dist/lexicon/types/com/atproto/sync/getRepo.d.ts.map +1 -1
  211. package/dist/lexicon/types/com/atproto/sync/getRepoStatus.d.ts +42 -0
  212. package/dist/lexicon/types/com/atproto/sync/getRepoStatus.d.ts.map +1 -0
  213. package/dist/lexicon/types/com/atproto/sync/getRepoStatus.js +3 -0
  214. package/dist/lexicon/types/com/atproto/sync/getRepoStatus.js.map +1 -0
  215. package/dist/lexicon/types/com/atproto/sync/listBlobs.d.ts +1 -0
  216. package/dist/lexicon/types/com/atproto/sync/listBlobs.d.ts.map +1 -1
  217. package/dist/lexicon/types/com/atproto/sync/listRepos.d.ts +3 -0
  218. package/dist/lexicon/types/com/atproto/sync/listRepos.d.ts.map +1 -1
  219. package/dist/lexicon/types/com/atproto/sync/listRepos.js.map +1 -1
  220. package/dist/lexicon/types/com/atproto/sync/subscribeRepos.d.ts +19 -4
  221. package/dist/lexicon/types/com/atproto/sync/subscribeRepos.d.ts.map +1 -1
  222. package/dist/lexicon/types/com/atproto/sync/subscribeRepos.js +11 -1
  223. package/dist/lexicon/types/com/atproto/sync/subscribeRepos.js.map +1 -1
  224. package/dist/lexicon/types/tools/ozone/moderation/defs.d.ts +2 -0
  225. package/dist/lexicon/types/tools/ozone/moderation/defs.d.ts.map +1 -1
  226. package/dist/lexicon/types/tools/ozone/moderation/defs.js.map +1 -1
  227. package/dist/pipethrough.d.ts.map +1 -1
  228. package/dist/pipethrough.js +17 -14
  229. package/dist/pipethrough.js.map +1 -1
  230. package/dist/scripts/index.d.ts +4 -0
  231. package/dist/scripts/index.d.ts.map +1 -0
  232. package/dist/scripts/index.js +8 -0
  233. package/dist/scripts/index.js.map +1 -0
  234. package/dist/scripts/rebuild-repo.d.ts +3 -0
  235. package/dist/scripts/rebuild-repo.d.ts.map +1 -0
  236. package/dist/scripts/rebuild-repo.js +121 -0
  237. package/dist/scripts/rebuild-repo.js.map +1 -0
  238. package/dist/sequencer/db/schema.d.ts +1 -1
  239. package/dist/sequencer/db/schema.d.ts.map +1 -1
  240. package/dist/sequencer/events.d.ts +27 -2
  241. package/dist/sequencer/events.d.ts.map +1 -1
  242. package/dist/sequencer/events.js +35 -2
  243. package/dist/sequencer/events.js.map +1 -1
  244. package/dist/sequencer/sequencer.d.ts +8 -6
  245. package/dist/sequencer/sequencer.d.ts.map +1 -1
  246. package/dist/sequencer/sequencer.js +22 -9
  247. package/dist/sequencer/sequencer.js.map +1 -1
  248. package/package.json +4 -4
  249. package/src/account-manager/helpers/account.ts +38 -6
  250. package/src/account-manager/index.ts +21 -8
  251. package/src/api/app/bsky/actor/getPreferences.ts +1 -1
  252. package/src/api/app/bsky/actor/getProfile.ts +1 -1
  253. package/src/api/app/bsky/actor/getProfiles.ts +1 -1
  254. package/src/api/app/bsky/actor/putPreferences.ts +1 -1
  255. package/src/api/app/bsky/feed/getActorLikes.ts +1 -1
  256. package/src/api/app/bsky/feed/getAuthorFeed.ts +1 -1
  257. package/src/api/app/bsky/feed/getFeed.ts +1 -1
  258. package/src/api/app/bsky/feed/getPostThread.ts +1 -1
  259. package/src/api/app/bsky/feed/getTimeline.ts +1 -1
  260. package/src/api/app/bsky/notification/registerPush.ts +4 -1
  261. package/src/api/chat/index.ts +14 -14
  262. package/src/api/com/atproto/admin/deleteAccount.ts +7 -2
  263. package/src/api/com/atproto/admin/getAccountInfo.ts +1 -0
  264. package/src/api/com/atproto/admin/getSubjectStatus.ts +4 -3
  265. package/src/api/com/atproto/admin/updateAccountHandle.ts +1 -1
  266. package/src/api/com/atproto/admin/updateSubjectStatus.ts +2 -0
  267. package/src/api/com/atproto/identity/getRecommendedDidCredentials.ts +1 -1
  268. package/src/api/com/atproto/identity/requestPlcOperationSignature.ts +1 -1
  269. package/src/api/com/atproto/identity/signPlcOperation.ts +1 -1
  270. package/src/api/com/atproto/identity/submitPlcOperation.ts +2 -1
  271. package/src/api/com/atproto/identity/updateHandle.ts +2 -2
  272. package/src/api/com/atproto/repo/applyWrites.ts +4 -1
  273. package/src/api/com/atproto/repo/createRecord.ts +4 -1
  274. package/src/api/com/atproto/repo/deleteRecord.ts +4 -1
  275. package/src/api/com/atproto/repo/describeRepo.ts +2 -4
  276. package/src/api/com/atproto/repo/importRepo.ts +3 -1
  277. package/src/api/com/atproto/repo/listMissingBlobs.ts +1 -1
  278. package/src/api/com/atproto/repo/putRecord.ts +4 -1
  279. package/src/api/com/atproto/repo/uploadBlob.ts +3 -1
  280. package/src/api/com/atproto/server/activateAccount.ts +3 -2
  281. package/src/api/com/atproto/server/checkAccountStatus.ts +1 -1
  282. package/src/api/com/atproto/server/confirmEmail.ts +1 -1
  283. package/src/api/com/atproto/server/createAccount.ts +6 -3
  284. package/src/api/com/atproto/server/createAppPassword.ts +3 -1
  285. package/src/api/com/atproto/server/createSession.ts +2 -0
  286. package/src/api/com/atproto/server/deactivateAccount.ts +3 -1
  287. package/src/api/com/atproto/server/deleteAccount.ts +7 -3
  288. package/src/api/com/atproto/server/getAccountInviteCodes.ts +1 -1
  289. package/src/api/com/atproto/server/getServiceAuth.ts +1 -1
  290. package/src/api/com/atproto/server/getSession.ts +7 -2
  291. package/src/api/com/atproto/server/listAppPasswords.ts +1 -1
  292. package/src/api/com/atproto/server/refreshSession.ts +2 -0
  293. package/src/api/com/atproto/server/requestAccountDelete.ts +1 -1
  294. package/src/api/com/atproto/server/requestEmailConfirmation.ts +1 -1
  295. package/src/api/com/atproto/server/requestEmailUpdate.ts +1 -1
  296. package/src/api/com/atproto/server/revokeAppPassword.ts +1 -1
  297. package/src/api/com/atproto/server/updateEmail.ts +1 -1
  298. package/src/api/com/atproto/server/util.ts +12 -5
  299. package/src/api/com/atproto/sync/deprecated/getCheckout.ts +6 -8
  300. package/src/api/com/atproto/sync/deprecated/getHead.ts +7 -10
  301. package/src/api/com/atproto/sync/getBlob.ts +8 -6
  302. package/src/api/com/atproto/sync/getBlocks.ts +6 -7
  303. package/src/api/com/atproto/sync/getLatestCommit.ts +7 -10
  304. package/src/api/com/atproto/sync/getRecord.ts +7 -7
  305. package/src/api/com/atproto/sync/getRepo.ts +6 -7
  306. package/src/api/com/atproto/sync/getRepoStatus.ts +31 -0
  307. package/src/api/com/atproto/sync/index.ts +2 -0
  308. package/src/api/com/atproto/sync/listBlobs.ts +6 -8
  309. package/src/api/com/atproto/sync/listRepos.ts +13 -8
  310. package/src/api/com/atproto/sync/subscribeRepos.ts +7 -0
  311. package/src/api/com/atproto/sync/util.ts +36 -0
  312. package/src/api/com/atproto/temp/checkSignupQueue.ts +4 -1
  313. package/src/auth-verifier.ts +62 -47
  314. package/src/index.ts +1 -0
  315. package/src/lexicon/index.ts +12 -0
  316. package/src/lexicon/lexicons.ts +236 -7
  317. package/src/lexicon/types/chat/bsky/convo/defs.ts +1 -1
  318. package/src/lexicon/types/com/atproto/admin/defs.ts +1 -0
  319. package/src/lexicon/types/com/atproto/admin/getSubjectStatus.ts +1 -0
  320. package/src/lexicon/types/com/atproto/server/createSession.ts +3 -0
  321. package/src/lexicon/types/com/atproto/server/getSession.ts +3 -0
  322. package/src/lexicon/types/com/atproto/server/refreshSession.ts +3 -0
  323. package/src/lexicon/types/com/atproto/sync/getBlob.ts +6 -0
  324. package/src/lexicon/types/com/atproto/sync/getBlocks.ts +6 -0
  325. package/src/lexicon/types/com/atproto/sync/getLatestCommit.ts +1 -1
  326. package/src/lexicon/types/com/atproto/sync/getRecord.ts +6 -0
  327. package/src/lexicon/types/com/atproto/sync/getRepo.ts +1 -0
  328. package/src/lexicon/types/com/atproto/sync/getRepoStatus.ts +52 -0
  329. package/src/lexicon/types/com/atproto/sync/listBlobs.ts +1 -0
  330. package/src/lexicon/types/com/atproto/sync/listRepos.ts +3 -0
  331. package/src/lexicon/types/com/atproto/sync/subscribeRepos.ts +30 -3
  332. package/src/lexicon/types/tools/ozone/moderation/defs.ts +2 -0
  333. package/src/pipethrough.ts +5 -4
  334. package/src/scripts/index.ts +5 -0
  335. package/src/scripts/rebuild-repo.ts +143 -0
  336. package/src/sequencer/db/schema.ts +1 -0
  337. package/src/sequencer/events.ts +47 -0
  338. package/src/sequencer/sequencer.ts +35 -14
  339. package/tests/account-deactivation.test.ts +67 -12
  340. package/tests/account-deletion.test.ts +10 -2
  341. package/tests/auth.test.ts +3 -0
  342. package/tests/moderation.test.ts +2 -2
  343. package/tests/proxied/notif.test.ts +1 -0
  344. package/tests/sequencer.test.ts +2 -2
  345. package/tests/sync/list.test.ts +1 -0
  346. package/tests/sync/subscribe-repos.test.ts +224 -40
  347. package/tests/sync/sync.test.ts +48 -4
@@ -68,6 +68,10 @@ exports.schemaDict = {
68
68
  inviteNote: {
69
69
  type: 'string',
70
70
  },
71
+ deactivatedAt: {
72
+ type: 'string',
73
+ format: 'datetime',
74
+ },
71
75
  },
72
76
  },
73
77
  repoRef: {
@@ -363,6 +367,10 @@ exports.schemaDict = {
363
367
  type: 'ref',
364
368
  ref: 'lex:com.atproto.admin.defs#statusAttr',
365
369
  },
370
+ deactivated: {
371
+ type: 'ref',
372
+ ref: 'lex:com.atproto.admin.defs#statusAttr',
373
+ },
366
374
  },
367
375
  },
368
376
  },
@@ -2178,6 +2186,14 @@ exports.schemaDict = {
2178
2186
  emailAuthFactor: {
2179
2187
  type: 'boolean',
2180
2188
  },
2189
+ active: {
2190
+ type: 'boolean',
2191
+ },
2192
+ status: {
2193
+ type: 'string',
2194
+ description: 'If active=false, this optional field indicates a possible reason for why the account is not active. If active=false and no status is supplied, then the host makes no claim for why the repository is no longer being hosted.',
2195
+ knownValues: ['takendown', 'suspended', 'deactivated'],
2196
+ },
2181
2197
  },
2182
2198
  },
2183
2199
  },
@@ -2502,6 +2518,14 @@ exports.schemaDict = {
2502
2518
  didDoc: {
2503
2519
  type: 'unknown',
2504
2520
  },
2521
+ active: {
2522
+ type: 'boolean',
2523
+ },
2524
+ status: {
2525
+ type: 'string',
2526
+ description: 'If active=false, this optional field indicates a possible reason for why the account is not active. If active=false and no status is supplied, then the host makes no claim for why the repository is no longer being hosted.',
2527
+ knownValues: ['takendown', 'suspended', 'deactivated'],
2528
+ },
2505
2529
  },
2506
2530
  },
2507
2531
  },
@@ -2585,6 +2609,14 @@ exports.schemaDict = {
2585
2609
  didDoc: {
2586
2610
  type: 'unknown',
2587
2611
  },
2612
+ active: {
2613
+ type: 'boolean',
2614
+ },
2615
+ status: {
2616
+ type: 'string',
2617
+ description: "Hosting status of the account. If not specified, then assume 'active'.",
2618
+ knownValues: ['takendown', 'suspended', 'deactivated'],
2619
+ },
2588
2620
  },
2589
2621
  },
2590
2622
  },
@@ -2817,6 +2849,23 @@ exports.schemaDict = {
2817
2849
  output: {
2818
2850
  encoding: '*/*',
2819
2851
  },
2852
+ errors: [
2853
+ {
2854
+ name: 'BlobNotFound',
2855
+ },
2856
+ {
2857
+ name: 'RepoNotFound',
2858
+ },
2859
+ {
2860
+ name: 'RepoTakendown',
2861
+ },
2862
+ {
2863
+ name: 'RepoSuspended',
2864
+ },
2865
+ {
2866
+ name: 'RepoDeactivated',
2867
+ },
2868
+ ],
2820
2869
  },
2821
2870
  },
2822
2871
  },
@@ -2848,6 +2897,23 @@ exports.schemaDict = {
2848
2897
  output: {
2849
2898
  encoding: 'application/vnd.ipld.car',
2850
2899
  },
2900
+ errors: [
2901
+ {
2902
+ name: 'BlockNotFound',
2903
+ },
2904
+ {
2905
+ name: 'RepoNotFound',
2906
+ },
2907
+ {
2908
+ name: 'RepoTakendown',
2909
+ },
2910
+ {
2911
+ name: 'RepoSuspended',
2912
+ },
2913
+ {
2914
+ name: 'RepoDeactivated',
2915
+ },
2916
+ ],
2851
2917
  },
2852
2918
  },
2853
2919
  },
@@ -2952,6 +3018,15 @@ exports.schemaDict = {
2952
3018
  {
2953
3019
  name: 'RepoNotFound',
2954
3020
  },
3021
+ {
3022
+ name: 'RepoTakendown',
3023
+ },
3024
+ {
3025
+ name: 'RepoSuspended',
3026
+ },
3027
+ {
3028
+ name: 'RepoDeactivated',
3029
+ },
2955
3030
  ],
2956
3031
  },
2957
3032
  },
@@ -2990,6 +3065,23 @@ exports.schemaDict = {
2990
3065
  output: {
2991
3066
  encoding: 'application/vnd.ipld.car',
2992
3067
  },
3068
+ errors: [
3069
+ {
3070
+ name: 'RecordNotFound',
3071
+ },
3072
+ {
3073
+ name: 'RepoNotFound',
3074
+ },
3075
+ {
3076
+ name: 'RepoTakendown',
3077
+ },
3078
+ {
3079
+ name: 'RepoSuspended',
3080
+ },
3081
+ {
3082
+ name: 'RepoDeactivated',
3083
+ },
3084
+ ],
2993
3085
  },
2994
3086
  },
2995
3087
  },
@@ -3018,6 +3110,71 @@ exports.schemaDict = {
3018
3110
  output: {
3019
3111
  encoding: 'application/vnd.ipld.car',
3020
3112
  },
3113
+ errors: [
3114
+ {
3115
+ name: 'RepoNotFound',
3116
+ },
3117
+ {
3118
+ name: 'RepoTakendown',
3119
+ },
3120
+ {
3121
+ name: 'RepoSuspended',
3122
+ },
3123
+ {
3124
+ name: 'RepoDeactivated',
3125
+ },
3126
+ ],
3127
+ },
3128
+ },
3129
+ },
3130
+ ComAtprotoSyncGetRepoStatus: {
3131
+ lexicon: 1,
3132
+ id: 'com.atproto.sync.getRepoStatus',
3133
+ defs: {
3134
+ main: {
3135
+ type: 'query',
3136
+ description: 'Get the hosting status for a repository, on this server. Expected to be implemented by PDS and Relay.',
3137
+ parameters: {
3138
+ type: 'params',
3139
+ required: ['did'],
3140
+ properties: {
3141
+ did: {
3142
+ type: 'string',
3143
+ format: 'did',
3144
+ description: 'The DID of the repo.',
3145
+ },
3146
+ },
3147
+ },
3148
+ output: {
3149
+ encoding: 'application/json',
3150
+ schema: {
3151
+ type: 'object',
3152
+ required: ['did', 'active'],
3153
+ properties: {
3154
+ did: {
3155
+ type: 'string',
3156
+ format: 'did',
3157
+ },
3158
+ active: {
3159
+ type: 'boolean',
3160
+ },
3161
+ status: {
3162
+ type: 'string',
3163
+ description: 'If active=false, this optional field indicates a possible reason for why the account is not active. If active=false and no status is supplied, then the host makes no claim for why the repository is no longer being hosted.',
3164
+ knownValues: ['takendown', 'suspended', 'deactivated'],
3165
+ },
3166
+ rev: {
3167
+ type: 'string',
3168
+ description: 'Optional field, the current rev of the repo, if active=true',
3169
+ },
3170
+ },
3171
+ },
3172
+ },
3173
+ errors: [
3174
+ {
3175
+ name: 'RepoNotFound',
3176
+ },
3177
+ ],
3021
3178
  },
3022
3179
  },
3023
3180
  },
@@ -3071,6 +3228,20 @@ exports.schemaDict = {
3071
3228
  },
3072
3229
  },
3073
3230
  },
3231
+ errors: [
3232
+ {
3233
+ name: 'RepoNotFound',
3234
+ },
3235
+ {
3236
+ name: 'RepoTakendown',
3237
+ },
3238
+ {
3239
+ name: 'RepoSuspended',
3240
+ },
3241
+ {
3242
+ name: 'RepoDeactivated',
3243
+ },
3244
+ ],
3074
3245
  },
3075
3246
  },
3076
3247
  },
@@ -3131,6 +3302,14 @@ exports.schemaDict = {
3131
3302
  rev: {
3132
3303
  type: 'string',
3133
3304
  },
3305
+ active: {
3306
+ type: 'boolean',
3307
+ },
3308
+ status: {
3309
+ type: 'string',
3310
+ description: 'If active=false, this optional field indicates a possible reason for why the account is not active. If active=false and no status is supplied, then the host makes no claim for why the repository is no longer being hosted.',
3311
+ knownValues: ['takendown', 'suspended', 'deactivated'],
3312
+ },
3134
3313
  },
3135
3314
  },
3136
3315
  },
@@ -3203,6 +3382,7 @@ exports.schemaDict = {
3203
3382
  refs: [
3204
3383
  'lex:com.atproto.sync.subscribeRepos#commit',
3205
3384
  'lex:com.atproto.sync.subscribeRepos#identity',
3385
+ 'lex:com.atproto.sync.subscribeRepos#account',
3206
3386
  'lex:com.atproto.sync.subscribeRepos#handle',
3207
3387
  'lex:com.atproto.sync.subscribeRepos#migrate',
3208
3388
  'lex:com.atproto.sync.subscribeRepos#tombstone',
@@ -3315,11 +3495,43 @@ exports.schemaDict = {
3315
3495
  type: 'string',
3316
3496
  format: 'datetime',
3317
3497
  },
3498
+ handle: {
3499
+ type: 'string',
3500
+ format: 'handle',
3501
+ description: "The current handle for the account, or 'handle.invalid' if validation fails. This field is optional, might have been validated or passed-through from an upstream source. Semantics and behaviors for PDS vs Relay may evolve in the future; see atproto specs for more details.",
3502
+ },
3503
+ },
3504
+ },
3505
+ account: {
3506
+ type: 'object',
3507
+ description: "Represents a change to an account's status on a host (eg, PDS or Relay). The semantics of this event are that the status is at the host which emitted the event, not necessarily that at the currently active PDS. Eg, a Relay takedown would emit a takedown with active=false, even if the PDS is still active.",
3508
+ required: ['seq', 'did', 'time', 'active'],
3509
+ properties: {
3510
+ seq: {
3511
+ type: 'integer',
3512
+ },
3513
+ did: {
3514
+ type: 'string',
3515
+ format: 'did',
3516
+ },
3517
+ time: {
3518
+ type: 'string',
3519
+ format: 'datetime',
3520
+ },
3521
+ active: {
3522
+ type: 'boolean',
3523
+ description: 'Indicates that the account has a repository which can be fetched from the host that emitted this event.',
3524
+ },
3525
+ status: {
3526
+ type: 'string',
3527
+ description: 'If active=false, this optional field indicates a reason for why the account is not active.',
3528
+ knownValues: ['takendown', 'suspended', 'deleted', 'deactivated'],
3529
+ },
3318
3530
  },
3319
3531
  },
3320
3532
  handle: {
3321
3533
  type: 'object',
3322
- description: "Represents an update of the account's handle, or transition to/from invalid state. NOTE: Will be deprecated in favor of #identity.",
3534
+ description: 'DEPRECATED -- Use #identity event instead',
3323
3535
  required: ['seq', 'did', 'handle', 'time'],
3324
3536
  properties: {
3325
3537
  seq: {
@@ -3341,7 +3553,7 @@ exports.schemaDict = {
3341
3553
  },
3342
3554
  migrate: {
3343
3555
  type: 'object',
3344
- description: 'Represents an account moving from one PDS instance to another. NOTE: not implemented; account migration uses #identity instead',
3556
+ description: 'DEPRECATED -- Use #account event instead',
3345
3557
  required: ['seq', 'did', 'migrateTo', 'time'],
3346
3558
  nullable: ['migrateTo'],
3347
3559
  properties: {
@@ -3363,7 +3575,7 @@ exports.schemaDict = {
3363
3575
  },
3364
3576
  tombstone: {
3365
3577
  type: 'object',
3366
- description: 'Indicates that an account has been deleted. NOTE: may be deprecated in favor of #identity or a future #account event',
3578
+ description: 'DEPRECATED -- Use #account event instead',
3367
3579
  required: ['seq', 'did', 'time'],
3368
3580
  properties: {
3369
3581
  seq: {
@@ -8118,7 +8330,7 @@ exports.schemaDict = {
8118
8330
  },
8119
8331
  embed: {
8120
8332
  type: 'union',
8121
- refs: ['lex:app.bsky.embed.record'],
8333
+ refs: ['lex:app.bsky.embed.record#view'],
8122
8334
  },
8123
8335
  sender: {
8124
8336
  type: 'ref',
@@ -9534,6 +9746,10 @@ exports.schemaDict = {
9534
9746
  inviteNote: {
9535
9747
  type: 'string',
9536
9748
  },
9749
+ deactivatedAt: {
9750
+ type: 'string',
9751
+ format: 'datetime',
9752
+ },
9537
9753
  },
9538
9754
  },
9539
9755
  repoViewDetail: {
@@ -9599,6 +9815,10 @@ exports.schemaDict = {
9599
9815
  type: 'string',
9600
9816
  format: 'datetime',
9601
9817
  },
9818
+ deactivatedAt: {
9819
+ type: 'string',
9820
+ format: 'datetime',
9821
+ },
9602
9822
  },
9603
9823
  },
9604
9824
  repoViewNotFound: {
@@ -10324,6 +10544,7 @@ exports.ids = {
10324
10544
  ComAtprotoSyncGetLatestCommit: 'com.atproto.sync.getLatestCommit',
10325
10545
  ComAtprotoSyncGetRecord: 'com.atproto.sync.getRecord',
10326
10546
  ComAtprotoSyncGetRepo: 'com.atproto.sync.getRepo',
10547
+ ComAtprotoSyncGetRepoStatus: 'com.atproto.sync.getRepoStatus',
10327
10548
  ComAtprotoSyncListBlobs: 'com.atproto.sync.listBlobs',
10328
10549
  ComAtprotoSyncListRepos: 'com.atproto.sync.listRepos',
10329
10550
  ComAtprotoSyncNotifyOfUpdate: 'com.atproto.sync.notifyOfUpdate',