@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.
- package/CHANGELOG.md +16 -0
- package/dist/account-manager/helpers/account.d.ts +20 -1
- package/dist/account-manager/helpers/account.d.ts.map +1 -1
- package/dist/account-manager/helpers/account.js +32 -7
- package/dist/account-manager/helpers/account.js.map +1 -1
- package/dist/account-manager/index.d.ts +7 -2
- package/dist/account-manager/index.d.ts.map +1 -1
- package/dist/account-manager/index.js +24 -8
- package/dist/account-manager/index.js.map +1 -1
- package/dist/api/app/bsky/actor/getPreferences.js +1 -1
- package/dist/api/app/bsky/actor/getPreferences.js.map +1 -1
- package/dist/api/app/bsky/actor/getProfile.js +1 -1
- package/dist/api/app/bsky/actor/getProfile.js.map +1 -1
- package/dist/api/app/bsky/actor/getProfiles.js +1 -1
- package/dist/api/app/bsky/actor/getProfiles.js.map +1 -1
- package/dist/api/app/bsky/actor/putPreferences.js +1 -1
- package/dist/api/app/bsky/actor/putPreferences.js.map +1 -1
- package/dist/api/app/bsky/feed/getActorLikes.js +1 -1
- package/dist/api/app/bsky/feed/getActorLikes.js.map +1 -1
- package/dist/api/app/bsky/feed/getAuthorFeed.js +1 -1
- package/dist/api/app/bsky/feed/getAuthorFeed.js.map +1 -1
- package/dist/api/app/bsky/feed/getFeed.js +1 -1
- package/dist/api/app/bsky/feed/getFeed.js.map +1 -1
- package/dist/api/app/bsky/feed/getPostThread.js +1 -1
- package/dist/api/app/bsky/feed/getPostThread.js.map +1 -1
- package/dist/api/app/bsky/feed/getTimeline.js +1 -1
- package/dist/api/app/bsky/feed/getTimeline.js.map +1 -1
- package/dist/api/app/bsky/notification/registerPush.d.ts.map +1 -1
- package/dist/api/app/bsky/notification/registerPush.js +4 -1
- package/dist/api/app/bsky/notification/registerPush.js.map +1 -1
- package/dist/api/chat/index.js +14 -14
- package/dist/api/chat/index.js.map +1 -1
- package/dist/api/com/atproto/admin/deleteAccount.d.ts.map +1 -1
- package/dist/api/com/atproto/admin/deleteAccount.js +4 -2
- package/dist/api/com/atproto/admin/deleteAccount.js.map +1 -1
- package/dist/api/com/atproto/admin/getAccountInfo.d.ts.map +1 -1
- package/dist/api/com/atproto/admin/getAccountInfo.js +1 -0
- package/dist/api/com/atproto/admin/getAccountInfo.js.map +1 -1
- package/dist/api/com/atproto/admin/getSubjectStatus.d.ts.map +1 -1
- package/dist/api/com/atproto/admin/getSubjectStatus.js +4 -3
- package/dist/api/com/atproto/admin/getSubjectStatus.js.map +1 -1
- package/dist/api/com/atproto/admin/updateAccountHandle.js +1 -1
- package/dist/api/com/atproto/admin/updateAccountHandle.js.map +1 -1
- package/dist/api/com/atproto/admin/updateSubjectStatus.d.ts.map +1 -1
- package/dist/api/com/atproto/admin/updateSubjectStatus.js +2 -0
- package/dist/api/com/atproto/admin/updateSubjectStatus.js.map +1 -1
- package/dist/api/com/atproto/identity/getRecommendedDidCredentials.js +1 -1
- package/dist/api/com/atproto/identity/getRecommendedDidCredentials.js.map +1 -1
- package/dist/api/com/atproto/identity/requestPlcOperationSignature.js +1 -1
- package/dist/api/com/atproto/identity/requestPlcOperationSignature.js.map +1 -1
- package/dist/api/com/atproto/identity/signPlcOperation.js +1 -1
- package/dist/api/com/atproto/identity/signPlcOperation.js.map +1 -1
- package/dist/api/com/atproto/identity/submitPlcOperation.d.ts.map +1 -1
- package/dist/api/com/atproto/identity/submitPlcOperation.js +1 -1
- package/dist/api/com/atproto/identity/submitPlcOperation.js.map +1 -1
- package/dist/api/com/atproto/identity/updateHandle.js +2 -2
- package/dist/api/com/atproto/identity/updateHandle.js.map +1 -1
- package/dist/api/com/atproto/repo/applyWrites.d.ts.map +1 -1
- package/dist/api/com/atproto/repo/applyWrites.js +4 -1
- package/dist/api/com/atproto/repo/applyWrites.js.map +1 -1
- package/dist/api/com/atproto/repo/createRecord.d.ts.map +1 -1
- package/dist/api/com/atproto/repo/createRecord.js +4 -1
- package/dist/api/com/atproto/repo/createRecord.js.map +1 -1
- package/dist/api/com/atproto/repo/deleteRecord.d.ts.map +1 -1
- package/dist/api/com/atproto/repo/deleteRecord.js +4 -1
- package/dist/api/com/atproto/repo/deleteRecord.js.map +1 -1
- package/dist/api/com/atproto/repo/describeRepo.d.ts.map +1 -1
- package/dist/api/com/atproto/repo/describeRepo.js +2 -4
- package/dist/api/com/atproto/repo/describeRepo.js.map +1 -1
- package/dist/api/com/atproto/repo/importRepo.d.ts.map +1 -1
- package/dist/api/com/atproto/repo/importRepo.js +3 -1
- package/dist/api/com/atproto/repo/importRepo.js.map +1 -1
- package/dist/api/com/atproto/repo/listMissingBlobs.js +1 -1
- package/dist/api/com/atproto/repo/listMissingBlobs.js.map +1 -1
- package/dist/api/com/atproto/repo/putRecord.d.ts.map +1 -1
- package/dist/api/com/atproto/repo/putRecord.js +4 -1
- package/dist/api/com/atproto/repo/putRecord.js.map +1 -1
- package/dist/api/com/atproto/repo/uploadBlob.d.ts.map +1 -1
- package/dist/api/com/atproto/repo/uploadBlob.js +3 -1
- package/dist/api/com/atproto/repo/uploadBlob.js.map +1 -1
- package/dist/api/com/atproto/server/activateAccount.d.ts.map +1 -1
- package/dist/api/com/atproto/server/activateAccount.js +3 -2
- package/dist/api/com/atproto/server/activateAccount.js.map +1 -1
- package/dist/api/com/atproto/server/checkAccountStatus.js +1 -1
- package/dist/api/com/atproto/server/checkAccountStatus.js.map +1 -1
- package/dist/api/com/atproto/server/confirmEmail.js +1 -1
- package/dist/api/com/atproto/server/confirmEmail.js.map +1 -1
- package/dist/api/com/atproto/server/createAccount.d.ts.map +1 -1
- package/dist/api/com/atproto/server/createAccount.js +4 -2
- package/dist/api/com/atproto/server/createAccount.js.map +1 -1
- package/dist/api/com/atproto/server/createAppPassword.d.ts.map +1 -1
- package/dist/api/com/atproto/server/createAppPassword.js +3 -1
- package/dist/api/com/atproto/server/createAppPassword.js.map +1 -1
- package/dist/api/com/atproto/server/createSession.d.ts.map +1 -1
- package/dist/api/com/atproto/server/createSession.js +2 -0
- package/dist/api/com/atproto/server/createSession.js.map +1 -1
- package/dist/api/com/atproto/server/deactivateAccount.d.ts.map +1 -1
- package/dist/api/com/atproto/server/deactivateAccount.js +3 -1
- package/dist/api/com/atproto/server/deactivateAccount.js.map +1 -1
- package/dist/api/com/atproto/server/deleteAccount.d.ts.map +1 -1
- package/dist/api/com/atproto/server/deleteAccount.js +4 -3
- package/dist/api/com/atproto/server/deleteAccount.js.map +1 -1
- package/dist/api/com/atproto/server/getAccountInviteCodes.js +1 -1
- package/dist/api/com/atproto/server/getAccountInviteCodes.js.map +1 -1
- package/dist/api/com/atproto/server/getServiceAuth.js +1 -1
- package/dist/api/com/atproto/server/getServiceAuth.js.map +1 -1
- package/dist/api/com/atproto/server/getSession.d.ts.map +1 -1
- package/dist/api/com/atproto/server/getSession.js +7 -2
- package/dist/api/com/atproto/server/getSession.js.map +1 -1
- package/dist/api/com/atproto/server/listAppPasswords.js +1 -1
- package/dist/api/com/atproto/server/listAppPasswords.js.map +1 -1
- package/dist/api/com/atproto/server/refreshSession.d.ts.map +1 -1
- package/dist/api/com/atproto/server/refreshSession.js +2 -0
- package/dist/api/com/atproto/server/refreshSession.js.map +1 -1
- package/dist/api/com/atproto/server/requestAccountDelete.js +1 -1
- package/dist/api/com/atproto/server/requestAccountDelete.js.map +1 -1
- package/dist/api/com/atproto/server/requestEmailConfirmation.js +1 -1
- package/dist/api/com/atproto/server/requestEmailConfirmation.js.map +1 -1
- package/dist/api/com/atproto/server/requestEmailUpdate.js +1 -1
- package/dist/api/com/atproto/server/requestEmailUpdate.js.map +1 -1
- package/dist/api/com/atproto/server/revokeAppPassword.js +1 -1
- package/dist/api/com/atproto/server/revokeAppPassword.js.map +1 -1
- package/dist/api/com/atproto/server/updateEmail.js +1 -1
- package/dist/api/com/atproto/server/updateEmail.js.map +1 -1
- package/dist/api/com/atproto/server/util.d.ts +1 -0
- package/dist/api/com/atproto/server/util.d.ts.map +1 -1
- package/dist/api/com/atproto/server/util.js +9 -6
- package/dist/api/com/atproto/server/util.js.map +1 -1
- package/dist/api/com/atproto/sync/deprecated/getCheckout.d.ts.map +1 -1
- package/dist/api/com/atproto/sync/deprecated/getCheckout.js +2 -8
- package/dist/api/com/atproto/sync/deprecated/getCheckout.js.map +1 -1
- package/dist/api/com/atproto/sync/deprecated/getHead.d.ts.map +1 -1
- package/dist/api/com/atproto/sync/deprecated/getHead.js +2 -7
- package/dist/api/com/atproto/sync/deprecated/getHead.js.map +1 -1
- package/dist/api/com/atproto/sync/getBlob.d.ts.map +1 -1
- package/dist/api/com/atproto/sync/getBlob.js +3 -6
- package/dist/api/com/atproto/sync/getBlob.js.map +1 -1
- package/dist/api/com/atproto/sync/getBlocks.d.ts.map +1 -1
- package/dist/api/com/atproto/sync/getBlocks.js +2 -7
- package/dist/api/com/atproto/sync/getBlocks.js.map +1 -1
- package/dist/api/com/atproto/sync/getLatestCommit.d.ts.map +1 -1
- package/dist/api/com/atproto/sync/getLatestCommit.js +2 -7
- package/dist/api/com/atproto/sync/getLatestCommit.js.map +1 -1
- package/dist/api/com/atproto/sync/getRecord.d.ts.map +1 -1
- package/dist/api/com/atproto/sync/getRecord.js +2 -7
- package/dist/api/com/atproto/sync/getRecord.js.map +1 -1
- package/dist/api/com/atproto/sync/getRepo.d.ts.map +1 -1
- package/dist/api/com/atproto/sync/getRepo.js +2 -7
- package/dist/api/com/atproto/sync/getRepo.js.map +1 -1
- package/dist/api/com/atproto/sync/getRepoStatus.d.ts +4 -0
- package/dist/api/com/atproto/sync/getRepoStatus.d.ts.map +1 -0
- package/dist/api/com/atproto/sync/getRepoStatus.js +28 -0
- package/dist/api/com/atproto/sync/getRepoStatus.js.map +1 -0
- package/dist/api/com/atproto/sync/index.d.ts.map +1 -1
- package/dist/api/com/atproto/sync/index.js +2 -0
- package/dist/api/com/atproto/sync/index.js.map +1 -1
- package/dist/api/com/atproto/sync/listBlobs.d.ts.map +1 -1
- package/dist/api/com/atproto/sync/listBlobs.js +2 -8
- package/dist/api/com/atproto/sync/listBlobs.js.map +1 -1
- package/dist/api/com/atproto/sync/listRepos.d.ts.map +1 -1
- package/dist/api/com/atproto/sync/listRepos.js +13 -8
- package/dist/api/com/atproto/sync/listRepos.js.map +1 -1
- package/dist/api/com/atproto/sync/subscribeRepos.d.ts.map +1 -1
- package/dist/api/com/atproto/sync/subscribeRepos.js +8 -0
- package/dist/api/com/atproto/sync/subscribeRepos.js.map +1 -1
- package/dist/api/com/atproto/sync/util.d.ts +4 -0
- package/dist/api/com/atproto/sync/util.d.ts.map +1 -0
- package/dist/api/com/atproto/sync/util.js +25 -0
- package/dist/api/com/atproto/sync/util.js.map +1 -0
- package/dist/api/com/atproto/temp/checkSignupQueue.d.ts.map +1 -1
- package/dist/api/com/atproto/temp/checkSignupQueue.js +4 -1
- package/dist/api/com/atproto/temp/checkSignupQueue.js.map +1 -1
- package/dist/auth-verifier.d.ts +13 -7
- package/dist/auth-verifier.d.ts.map +1 -1
- package/dist/auth-verifier.js +29 -46
- package/dist/auth-verifier.js.map +1 -1
- package/dist/index.d.ts +1 -0
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +3 -1
- package/dist/index.js.map +1 -1
- package/dist/lexicon/index.d.ts +2 -0
- package/dist/lexicon/index.d.ts.map +1 -1
- package/dist/lexicon/index.js +4 -0
- package/dist/lexicon/index.js.map +1 -1
- package/dist/lexicon/lexicons.d.ts +145 -0
- package/dist/lexicon/lexicons.d.ts.map +1 -1
- package/dist/lexicon/lexicons.js +225 -4
- package/dist/lexicon/lexicons.js.map +1 -1
- package/dist/lexicon/types/chat/bsky/convo/defs.d.ts +1 -1
- package/dist/lexicon/types/com/atproto/admin/defs.d.ts +1 -0
- package/dist/lexicon/types/com/atproto/admin/defs.d.ts.map +1 -1
- package/dist/lexicon/types/com/atproto/admin/defs.js.map +1 -1
- package/dist/lexicon/types/com/atproto/admin/getSubjectStatus.d.ts +1 -0
- package/dist/lexicon/types/com/atproto/admin/getSubjectStatus.d.ts.map +1 -1
- package/dist/lexicon/types/com/atproto/server/createSession.d.ts +3 -0
- package/dist/lexicon/types/com/atproto/server/createSession.d.ts.map +1 -1
- package/dist/lexicon/types/com/atproto/server/getSession.d.ts +3 -0
- package/dist/lexicon/types/com/atproto/server/getSession.d.ts.map +1 -1
- package/dist/lexicon/types/com/atproto/server/refreshSession.d.ts +3 -0
- package/dist/lexicon/types/com/atproto/server/refreshSession.d.ts.map +1 -1
- package/dist/lexicon/types/com/atproto/sync/getBlob.d.ts +1 -0
- package/dist/lexicon/types/com/atproto/sync/getBlob.d.ts.map +1 -1
- package/dist/lexicon/types/com/atproto/sync/getBlocks.d.ts +1 -0
- package/dist/lexicon/types/com/atproto/sync/getBlocks.d.ts.map +1 -1
- package/dist/lexicon/types/com/atproto/sync/getLatestCommit.d.ts +1 -1
- package/dist/lexicon/types/com/atproto/sync/getLatestCommit.d.ts.map +1 -1
- package/dist/lexicon/types/com/atproto/sync/getRecord.d.ts +1 -0
- package/dist/lexicon/types/com/atproto/sync/getRecord.d.ts.map +1 -1
- package/dist/lexicon/types/com/atproto/sync/getRepo.d.ts +1 -0
- package/dist/lexicon/types/com/atproto/sync/getRepo.d.ts.map +1 -1
- package/dist/lexicon/types/com/atproto/sync/getRepoStatus.d.ts +42 -0
- package/dist/lexicon/types/com/atproto/sync/getRepoStatus.d.ts.map +1 -0
- package/dist/lexicon/types/com/atproto/sync/getRepoStatus.js +3 -0
- package/dist/lexicon/types/com/atproto/sync/getRepoStatus.js.map +1 -0
- package/dist/lexicon/types/com/atproto/sync/listBlobs.d.ts +1 -0
- package/dist/lexicon/types/com/atproto/sync/listBlobs.d.ts.map +1 -1
- package/dist/lexicon/types/com/atproto/sync/listRepos.d.ts +3 -0
- package/dist/lexicon/types/com/atproto/sync/listRepos.d.ts.map +1 -1
- package/dist/lexicon/types/com/atproto/sync/listRepos.js.map +1 -1
- package/dist/lexicon/types/com/atproto/sync/subscribeRepos.d.ts +19 -4
- package/dist/lexicon/types/com/atproto/sync/subscribeRepos.d.ts.map +1 -1
- package/dist/lexicon/types/com/atproto/sync/subscribeRepos.js +11 -1
- package/dist/lexicon/types/com/atproto/sync/subscribeRepos.js.map +1 -1
- package/dist/lexicon/types/tools/ozone/moderation/defs.d.ts +2 -0
- package/dist/lexicon/types/tools/ozone/moderation/defs.d.ts.map +1 -1
- package/dist/lexicon/types/tools/ozone/moderation/defs.js.map +1 -1
- package/dist/pipethrough.d.ts.map +1 -1
- package/dist/pipethrough.js +17 -14
- package/dist/pipethrough.js.map +1 -1
- package/dist/scripts/index.d.ts +4 -0
- package/dist/scripts/index.d.ts.map +1 -0
- package/dist/scripts/index.js +8 -0
- package/dist/scripts/index.js.map +1 -0
- package/dist/scripts/rebuild-repo.d.ts +3 -0
- package/dist/scripts/rebuild-repo.d.ts.map +1 -0
- package/dist/scripts/rebuild-repo.js +121 -0
- package/dist/scripts/rebuild-repo.js.map +1 -0
- package/dist/sequencer/db/schema.d.ts +1 -1
- package/dist/sequencer/db/schema.d.ts.map +1 -1
- package/dist/sequencer/events.d.ts +27 -2
- package/dist/sequencer/events.d.ts.map +1 -1
- package/dist/sequencer/events.js +35 -2
- package/dist/sequencer/events.js.map +1 -1
- package/dist/sequencer/sequencer.d.ts +8 -6
- package/dist/sequencer/sequencer.d.ts.map +1 -1
- package/dist/sequencer/sequencer.js +22 -9
- package/dist/sequencer/sequencer.js.map +1 -1
- package/package.json +4 -4
- package/src/account-manager/helpers/account.ts +38 -6
- package/src/account-manager/index.ts +21 -8
- package/src/api/app/bsky/actor/getPreferences.ts +1 -1
- package/src/api/app/bsky/actor/getProfile.ts +1 -1
- package/src/api/app/bsky/actor/getProfiles.ts +1 -1
- package/src/api/app/bsky/actor/putPreferences.ts +1 -1
- package/src/api/app/bsky/feed/getActorLikes.ts +1 -1
- package/src/api/app/bsky/feed/getAuthorFeed.ts +1 -1
- package/src/api/app/bsky/feed/getFeed.ts +1 -1
- package/src/api/app/bsky/feed/getPostThread.ts +1 -1
- package/src/api/app/bsky/feed/getTimeline.ts +1 -1
- package/src/api/app/bsky/notification/registerPush.ts +4 -1
- package/src/api/chat/index.ts +14 -14
- package/src/api/com/atproto/admin/deleteAccount.ts +7 -2
- package/src/api/com/atproto/admin/getAccountInfo.ts +1 -0
- package/src/api/com/atproto/admin/getSubjectStatus.ts +4 -3
- package/src/api/com/atproto/admin/updateAccountHandle.ts +1 -1
- package/src/api/com/atproto/admin/updateSubjectStatus.ts +2 -0
- package/src/api/com/atproto/identity/getRecommendedDidCredentials.ts +1 -1
- package/src/api/com/atproto/identity/requestPlcOperationSignature.ts +1 -1
- package/src/api/com/atproto/identity/signPlcOperation.ts +1 -1
- package/src/api/com/atproto/identity/submitPlcOperation.ts +2 -1
- package/src/api/com/atproto/identity/updateHandle.ts +2 -2
- package/src/api/com/atproto/repo/applyWrites.ts +4 -1
- package/src/api/com/atproto/repo/createRecord.ts +4 -1
- package/src/api/com/atproto/repo/deleteRecord.ts +4 -1
- package/src/api/com/atproto/repo/describeRepo.ts +2 -4
- package/src/api/com/atproto/repo/importRepo.ts +3 -1
- package/src/api/com/atproto/repo/listMissingBlobs.ts +1 -1
- package/src/api/com/atproto/repo/putRecord.ts +4 -1
- package/src/api/com/atproto/repo/uploadBlob.ts +3 -1
- package/src/api/com/atproto/server/activateAccount.ts +3 -2
- package/src/api/com/atproto/server/checkAccountStatus.ts +1 -1
- package/src/api/com/atproto/server/confirmEmail.ts +1 -1
- package/src/api/com/atproto/server/createAccount.ts +6 -3
- package/src/api/com/atproto/server/createAppPassword.ts +3 -1
- package/src/api/com/atproto/server/createSession.ts +2 -0
- package/src/api/com/atproto/server/deactivateAccount.ts +3 -1
- package/src/api/com/atproto/server/deleteAccount.ts +7 -3
- package/src/api/com/atproto/server/getAccountInviteCodes.ts +1 -1
- package/src/api/com/atproto/server/getServiceAuth.ts +1 -1
- package/src/api/com/atproto/server/getSession.ts +7 -2
- package/src/api/com/atproto/server/listAppPasswords.ts +1 -1
- package/src/api/com/atproto/server/refreshSession.ts +2 -0
- package/src/api/com/atproto/server/requestAccountDelete.ts +1 -1
- package/src/api/com/atproto/server/requestEmailConfirmation.ts +1 -1
- package/src/api/com/atproto/server/requestEmailUpdate.ts +1 -1
- package/src/api/com/atproto/server/revokeAppPassword.ts +1 -1
- package/src/api/com/atproto/server/updateEmail.ts +1 -1
- package/src/api/com/atproto/server/util.ts +12 -5
- package/src/api/com/atproto/sync/deprecated/getCheckout.ts +6 -8
- package/src/api/com/atproto/sync/deprecated/getHead.ts +7 -10
- package/src/api/com/atproto/sync/getBlob.ts +8 -6
- package/src/api/com/atproto/sync/getBlocks.ts +6 -7
- package/src/api/com/atproto/sync/getLatestCommit.ts +7 -10
- package/src/api/com/atproto/sync/getRecord.ts +7 -7
- package/src/api/com/atproto/sync/getRepo.ts +6 -7
- package/src/api/com/atproto/sync/getRepoStatus.ts +31 -0
- package/src/api/com/atproto/sync/index.ts +2 -0
- package/src/api/com/atproto/sync/listBlobs.ts +6 -8
- package/src/api/com/atproto/sync/listRepos.ts +13 -8
- package/src/api/com/atproto/sync/subscribeRepos.ts +7 -0
- package/src/api/com/atproto/sync/util.ts +36 -0
- package/src/api/com/atproto/temp/checkSignupQueue.ts +4 -1
- package/src/auth-verifier.ts +62 -47
- package/src/index.ts +1 -0
- package/src/lexicon/index.ts +12 -0
- package/src/lexicon/lexicons.ts +236 -7
- package/src/lexicon/types/chat/bsky/convo/defs.ts +1 -1
- package/src/lexicon/types/com/atproto/admin/defs.ts +1 -0
- package/src/lexicon/types/com/atproto/admin/getSubjectStatus.ts +1 -0
- package/src/lexicon/types/com/atproto/server/createSession.ts +3 -0
- package/src/lexicon/types/com/atproto/server/getSession.ts +3 -0
- package/src/lexicon/types/com/atproto/server/refreshSession.ts +3 -0
- package/src/lexicon/types/com/atproto/sync/getBlob.ts +6 -0
- package/src/lexicon/types/com/atproto/sync/getBlocks.ts +6 -0
- package/src/lexicon/types/com/atproto/sync/getLatestCommit.ts +1 -1
- package/src/lexicon/types/com/atproto/sync/getRecord.ts +6 -0
- package/src/lexicon/types/com/atproto/sync/getRepo.ts +1 -0
- package/src/lexicon/types/com/atproto/sync/getRepoStatus.ts +52 -0
- package/src/lexicon/types/com/atproto/sync/listBlobs.ts +1 -0
- package/src/lexicon/types/com/atproto/sync/listRepos.ts +3 -0
- package/src/lexicon/types/com/atproto/sync/subscribeRepos.ts +30 -3
- package/src/lexicon/types/tools/ozone/moderation/defs.ts +2 -0
- package/src/pipethrough.ts +5 -4
- package/src/scripts/index.ts +5 -0
- package/src/scripts/rebuild-repo.ts +143 -0
- package/src/sequencer/db/schema.ts +1 -0
- package/src/sequencer/events.ts +47 -0
- package/src/sequencer/sequencer.ts +35 -14
- package/tests/account-deactivation.test.ts +67 -12
- package/tests/account-deletion.test.ts +10 -2
- package/tests/auth.test.ts +3 -0
- package/tests/moderation.test.ts +2 -2
- package/tests/proxied/notif.test.ts +1 -0
- package/tests/sequencer.test.ts +2 -2
- package/tests/sync/list.test.ts +1 -0
- package/tests/sync/subscribe-repos.test.ts +224 -40
- package/tests/sync/sync.test.ts +48 -4
package/dist/pipethrough.js
CHANGED
@@ -36,20 +36,23 @@ const xrpc_1 = require("@atproto/xrpc");
|
|
36
36
|
const lexicons_1 = require("./lexicon/lexicons");
|
37
37
|
const logger_1 = require("./logger");
|
38
38
|
const common_1 = require("@atproto/common");
|
39
|
-
const proxyHandler = (ctx) =>
|
40
|
-
|
41
|
-
|
42
|
-
|
43
|
-
|
44
|
-
|
45
|
-
|
46
|
-
|
47
|
-
|
48
|
-
|
49
|
-
|
50
|
-
|
51
|
-
|
52
|
-
|
39
|
+
const proxyHandler = (ctx) => {
|
40
|
+
const accessStandard = ctx.authVerifier.accessStandard();
|
41
|
+
return async (req, res, next) => {
|
42
|
+
try {
|
43
|
+
const { url, aud } = await (0, exports.formatUrlAndAud)(ctx, req);
|
44
|
+
const auth = await accessStandard({ req });
|
45
|
+
const headers = await (0, exports.formatHeaders)(ctx, req, aud, auth.credentials.did);
|
46
|
+
const body = node_stream_1.default.Readable.toWeb(req);
|
47
|
+
const reqInit = formatReqInit(req, headers, body);
|
48
|
+
const proxyRes = await (0, exports.makeRequest)(url, reqInit);
|
49
|
+
await (0, exports.pipeProxyRes)(proxyRes, res);
|
50
|
+
}
|
51
|
+
catch (err) {
|
52
|
+
return next(err);
|
53
|
+
}
|
54
|
+
return next();
|
55
|
+
};
|
53
56
|
};
|
54
57
|
exports.proxyHandler = proxyHandler;
|
55
58
|
const pipethrough = async (ctx, req, requester, audOverride) => {
|
package/dist/pipethrough.js.map
CHANGED
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"pipethrough.js","sourceRoot":"","sources":["../src/pipethrough.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;AACA,iDAAkC;AAClC,wDAA0B;AAC1B,8DAAgC;AAEhC,8CAAoE;AACpE,sDAI6B;AAC7B,wCAAuD;AACvD,iDAAkD;AAClD,qCAAqC;AACrC,4CAAqE;AAG9D,MAAM,YAAY,
|
1
|
+
{"version":3,"file":"pipethrough.js","sourceRoot":"","sources":["../src/pipethrough.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;AACA,iDAAkC;AAClC,wDAA0B;AAC1B,8DAAgC;AAEhC,8CAAoE;AACpE,sDAI6B;AAC7B,wCAAuD;AACvD,iDAAkD;AAClD,qCAAqC;AACrC,4CAAqE;AAG9D,MAAM,YAAY,GAAG,CAAC,GAAe,EAAmB,EAAE;IAC/D,MAAM,cAAc,GAAG,GAAG,CAAC,YAAY,CAAC,cAAc,EAAE,CAAA;IACxD,OAAO,KAAK,EAAE,GAAG,EAAE,GAAG,EAAE,IAAI,EAAE,EAAE;QAC9B,IAAI,CAAC;YACH,MAAM,EAAE,GAAG,EAAE,GAAG,EAAE,GAAG,MAAM,IAAA,uBAAe,EAAC,GAAG,EAAE,GAAG,CAAC,CAAA;YACpD,MAAM,IAAI,GAAG,MAAM,cAAc,CAAC,EAAE,GAAG,EAAE,CAAC,CAAA;YAC1C,MAAM,OAAO,GAAG,MAAM,IAAA,qBAAa,EAAC,GAA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AAa,GAAG,CAAC,IAAY,EAAW,EAAE;IAC9C,IAAI,CAAC;QACH,OAAO,IAAI,CAAC,KAAK,CAAC,IAAI,CAAC,CAAA;IACzB,CAAC;IAAC,MAAM,CAAC;QACP,OAAO,IAAI,CAAA;IACb,CAAC;AACH,CAAC,CAAA;AAED,MAAM,aAAa,GAAG,CAAC,OAAgB,EAA0B,EAAE;IACjE,MAAM,MAAM,GAAG,EAAE,CAAA;IACjB,KAAK,MAAM,CAAC,GAAG,EAAE,GAAG,CAAC,IAAI,OAAO,EAAE,CAAC;QACjC,MAAM,CAAC,GAAG,CAAC,GAAG,GAAG,CAAA;IACnB,CAAC;IACD,OAAO,MAAM,CAAA;AACf,CAAC,CAAA"}
|
@@ -0,0 +1 @@
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/scripts/index.ts"],"names":[],"mappings":"AAEA,eAAO,MAAM,OAAO;;CAEnB,CAAA"}
|
@@ -0,0 +1,8 @@
|
|
1
|
+
"use strict";
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
3
|
+
exports.scripts = void 0;
|
4
|
+
const rebuild_repo_1 = require("./rebuild-repo");
|
5
|
+
exports.scripts = {
|
6
|
+
'rebuild-repo': rebuild_repo_1.rebuildRepo,
|
7
|
+
};
|
8
|
+
//# sourceMappingURL=index.js.map
|
@@ -0,0 +1 @@
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/scripts/index.ts"],"names":[],"mappings":";;;AAAA,iDAA4C;AAE/B,QAAA,OAAO,GAAG;IACrB,cAAc,EAAE,0BAAW;CAC5B,CAAA"}
|
@@ -0,0 +1 @@
|
|
1
|
+
{"version":3,"file":"rebuild-repo.d.ts","sourceRoot":"","sources":["../../src/scripts/rebuild-repo.ts"],"names":[],"mappings":"AAaA,OAAO,UAAU,MAAM,YAAY,CAAA;AAEnC,eAAO,MAAM,WAAW,QAAe,UAAU,QAAQ,MAAM,EAAE,kBAiEhE,CAAA"}
|
@@ -0,0 +1,121 @@
|
|
1
|
+
"use strict";
|
2
|
+
var __importDefault = (this && this.__importDefault) || function (mod) {
|
3
|
+
return (mod && mod.__esModule) ? mod : { "default": mod };
|
4
|
+
};
|
5
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
6
|
+
exports.rebuildRepo = void 0;
|
7
|
+
const promises_1 = __importDefault(require("node:readline/promises"));
|
8
|
+
const cid_1 = require("multiformats/cid");
|
9
|
+
const repo_1 = require("@atproto/repo");
|
10
|
+
const syntax_1 = require("@atproto/syntax");
|
11
|
+
const common_1 = require("@atproto/common");
|
12
|
+
const rebuildRepo = async (ctx, args) => {
|
13
|
+
const did = args[0];
|
14
|
+
if (!did || !did.startsWith('did:')) {
|
15
|
+
throw new Error('Expected DID as argument');
|
16
|
+
}
|
17
|
+
const memoryStore = new repo_1.MemoryBlockstore();
|
18
|
+
const rev = common_1.TID.nextStr();
|
19
|
+
const commit = await ctx.actorStore.transact(did, async (store) => {
|
20
|
+
const [records, existingCids] = await Promise.all([
|
21
|
+
listAllRecords(store),
|
22
|
+
listExistingBlocks(store),
|
23
|
+
]);
|
24
|
+
let mst = await repo_1.MST.create(memoryStore);
|
25
|
+
for (const record of records) {
|
26
|
+
mst = await mst.add(record.path, record.cid);
|
27
|
+
}
|
28
|
+
const newBlocks = new repo_1.BlockMap();
|
29
|
+
for await (const node of mst.walk()) {
|
30
|
+
if (node.isTree()) {
|
31
|
+
const pointer = await node.getPointer();
|
32
|
+
if (!existingCids.has(pointer)) {
|
33
|
+
const serialized = await node.serialize();
|
34
|
+
newBlocks.set(serialized.cid, serialized.bytes);
|
35
|
+
}
|
36
|
+
}
|
37
|
+
}
|
38
|
+
const mstCids = await mst.allCids();
|
39
|
+
const toDelete = new repo_1.CidSet(existingCids.toList()).subtractSet(mstCids);
|
40
|
+
const newCommit = await (0, repo_1.signCommit)({
|
41
|
+
did,
|
42
|
+
version: 3,
|
43
|
+
rev,
|
44
|
+
prev: null,
|
45
|
+
data: await mst.getPointer(),
|
46
|
+
}, store.repo.signingKey);
|
47
|
+
const commitCid = await newBlocks.add(newCommit);
|
48
|
+
console.log('Record count: ', records.length);
|
49
|
+
console.log('Existing blocks: ', existingCids.toList().length);
|
50
|
+
console.log('Deleting blocks:', toDelete.toList().length);
|
51
|
+
console.log('Adding blocks: ', newBlocks.size);
|
52
|
+
const shouldContinue = await promptContinue();
|
53
|
+
if (!shouldContinue) {
|
54
|
+
throw new Error('Aborted');
|
55
|
+
}
|
56
|
+
await store.repo.storage.deleteMany(toDelete.toList());
|
57
|
+
await store.repo.storage.putMany(newBlocks, rev);
|
58
|
+
await store.repo.storage.updateRoot(commitCid, rev);
|
59
|
+
return {
|
60
|
+
cid: commitCid,
|
61
|
+
rev,
|
62
|
+
since: null,
|
63
|
+
prev: null,
|
64
|
+
newBlocks,
|
65
|
+
removedCids: toDelete,
|
66
|
+
};
|
67
|
+
});
|
68
|
+
await ctx.accountManager.updateRepoRoot(did, commit.cid, rev);
|
69
|
+
await ctx.sequencer.sequenceCommit(did, commit, []);
|
70
|
+
};
|
71
|
+
exports.rebuildRepo = rebuildRepo;
|
72
|
+
const listExistingBlocks = async (store) => {
|
73
|
+
const cids = new repo_1.CidSet();
|
74
|
+
let cursor = '';
|
75
|
+
while (cursor !== undefined) {
|
76
|
+
const res = await store.db.db
|
77
|
+
.selectFrom('repo_block')
|
78
|
+
.select('cid')
|
79
|
+
.where('cid', '>', cursor)
|
80
|
+
.orderBy('cid', 'asc')
|
81
|
+
.limit(1000)
|
82
|
+
.execute();
|
83
|
+
for (const row of res) {
|
84
|
+
cids.add(cid_1.CID.parse(row.cid));
|
85
|
+
}
|
86
|
+
cursor = res.at(-1)?.cid;
|
87
|
+
}
|
88
|
+
return cids;
|
89
|
+
};
|
90
|
+
const listAllRecords = async (store) => {
|
91
|
+
const records = [];
|
92
|
+
let cursor = '';
|
93
|
+
while (cursor !== undefined) {
|
94
|
+
const res = await store.db.db
|
95
|
+
.selectFrom('record')
|
96
|
+
.select(['uri', 'cid'])
|
97
|
+
.where('uri', '>', cursor)
|
98
|
+
.orderBy('uri', 'asc')
|
99
|
+
.limit(1000)
|
100
|
+
.execute();
|
101
|
+
for (const row of res) {
|
102
|
+
const parsed = new syntax_1.AtUri(row.uri);
|
103
|
+
records.push({
|
104
|
+
uri: row.uri,
|
105
|
+
path: (0, repo_1.formatDataKey)(parsed.collection, parsed.rkey),
|
106
|
+
cid: cid_1.CID.parse(row.cid),
|
107
|
+
});
|
108
|
+
}
|
109
|
+
cursor = res.at(-1)?.uri;
|
110
|
+
}
|
111
|
+
return records;
|
112
|
+
};
|
113
|
+
const promptContinue = async () => {
|
114
|
+
const rl = promises_1.default.createInterface({
|
115
|
+
input: process.stdin,
|
116
|
+
output: process.stdout,
|
117
|
+
});
|
118
|
+
const answer = await rl.question('Continue? y/n ');
|
119
|
+
return answer === '';
|
120
|
+
};
|
121
|
+
//# sourceMappingURL=rebuild-repo.js.map
|
@@ -0,0 +1 @@
|
|
1
|
+
{"version":3,"file":"rebuild-repo.js","sourceRoot":"","sources":["../../src/scripts/rebuild-repo.ts"],"names":[],"mappings":";;;;;;AAAA,sEAA6C;AAC7C,0CAAsC;AACtC,wCAOsB;AACtB,4CAAuC;AACvC,4CAAqC;AAI9B,MAAM,WAAW,GAAG,KAAK,EAAE,GAAe,EAAE,IAAc,EAAE,EAAE;IACnE,MAAM,GAAG,GAAG,IAAI,CAAC,CAAC,CAAC,CAAA;IACnB,IAAI,CAAC,GAAG,IAAI,CAAC,GAAG,CAAC,UAAU,CAAC,MAAM,CAAC,EAAE,CAAC;QACpC,MAAM,IAAI,KAAK,CAAC,0BAA0B,CAAC,CAAA;IAC7C,CAAC;IAED,MAAM,WAAW,GAAG,IAAI,uBAAgB,EAAE,CAAA;IAC1C,MAAM,GAAG,GAAG,YAAG,CAAC,OAAO,EAAE,CAAA;IACzB,MAAM,MAAM,GAAG,MAAM,GAAG,CAAC,UAAU,CAAC,QAAQ,CAAC,GAAG,EAAE,KAAK,E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IAAI,CAAC;aACX,OAAO,EAAE,CAAA;QACZ,KAAK,MAAM,GAAG,IAAI,GAAG,EAAE,CAAC;YACtB,MAAM,MAAM,GAAG,IAAI,cAAK,CAAC,GAAG,CAAC,GAAG,CAAC,CAAA;YACjC,OAAO,CAAC,IAAI,CAAC;gBACX,GAAG,EAAE,GAAG,CAAC,GAAG;gBACZ,IAAI,EAAE,IAAA,oBAAa,EAAC,MAAM,CAAC,UAAU,EAAE,MAAM,CAAC,IAAI,CAAC;gBACnD,GAAG,EAAE,SAAG,CAAC,KAAK,CAAC,GAAG,CAAC,GAAG,CAAC;aACxB,CAAC,CAAA;QACJ,CAAC;QACD,MAAM,GAAG,GAAG,CAAC,EAAE,CAAC,CAAC,CAAC,CAAC,EAAE,GAAG,CAAA;IAC1B,CAAC;IACD,OAAO,OAAO,CAAA;AAChB,CAAC,CAAA;AAED,MAAM,cAAc,GAAG,KAAK,IAAsB,EAAE;IAClD,MAAM,EAAE,GAAG,kBAAQ,CAAC,eAAe,CAAC;QAClC,KAAK,EAAE,OAAO,CAAC,KAAK;QACpB,MAAM,EAAE,OAAO,CAAC,MAAM;KACvB,CAAC,CAAA;IACF,MAAM,MAAM,GAAG,MAAM,EAAE,CAAC,QAAQ,CAAC,gBAAgB,CAAC,CAAA;IAClD,OAAO,MAAM,KAAK,EAAE,CAAA;AACtB,CAAC,CAAA"}
|
@@ -1,5 +1,5 @@
|
|
1
1
|
import { Generated, GeneratedAlways, Insertable, Selectable } from 'kysely';
|
2
|
-
export type RepoSeqEventType = 'append' | 'rebase' | 'handle' | 'migrate' | 'identity' | 'tombstone';
|
2
|
+
export type RepoSeqEventType = 'append' | 'rebase' | 'handle' | 'migrate' | 'identity' | 'account' | 'tombstone';
|
3
3
|
export interface RepoSeq {
|
4
4
|
seq: GeneratedAlways<number>;
|
5
5
|
did: string;
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"schema.d.ts","sourceRoot":"","sources":["../../../src/sequencer/db/schema.ts"],"names":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GAAG,UAAU,CAAC,OAAO,CAAC,CAAA;AAC/C,MAAM,MAAM,YAAY,GAAG,UAAU,CAAC,OAAO,CAAC,CAAA;AAE9C,MAAM,MAAM,iBAAiB,GAAG;IAC9B,QAAQ,EAAE,OAAO,CAAA;CAClB,CAAA"}
|
@@ -3,9 +3,11 @@ import { CommitData } from '@atproto/repo';
|
|
3
3
|
import { PreparedWrite } from '../repo';
|
4
4
|
import { CID } from 'multiformats/cid';
|
5
5
|
import { RepoSeqInsert } from './db';
|
6
|
+
import { AccountStatus } from '../account-manager';
|
6
7
|
export declare const formatSeqCommit: (did: string, commitData: CommitData, writes: PreparedWrite[]) => Promise<RepoSeqInsert>;
|
7
8
|
export declare const formatSeqHandleUpdate: (did: string, handle: string) => Promise<RepoSeqInsert>;
|
8
|
-
export declare const formatSeqIdentityEvt: (did: string) => Promise<RepoSeqInsert>;
|
9
|
+
export declare const formatSeqIdentityEvt: (did: string, handle?: string) => Promise<RepoSeqInsert>;
|
10
|
+
export declare const formatSeqAccountEvt: (did: string, status: AccountStatus) => Promise<RepoSeqInsert>;
|
9
11
|
export declare const formatSeqTombstone: (did: string) => Promise<RepoSeqInsert>;
|
10
12
|
export declare const commitEvtOp: z.ZodObject<{
|
11
13
|
action: z.ZodUnion<[z.ZodLiteral<"create">, z.ZodLiteral<"update">, z.ZodLiteral<"delete">]>;
|
@@ -89,12 +91,29 @@ export declare const handleEvt: z.ZodObject<{
|
|
89
91
|
export type HandleEvt = z.infer<typeof handleEvt>;
|
90
92
|
export declare const identityEvt: z.ZodObject<{
|
91
93
|
did: z.ZodString;
|
94
|
+
handle: z.ZodOptional<z.ZodString>;
|
92
95
|
}, "strip", z.ZodTypeAny, {
|
93
96
|
did: string;
|
97
|
+
handle?: string | undefined;
|
94
98
|
}, {
|
95
99
|
did: string;
|
100
|
+
handle?: string | undefined;
|
96
101
|
}>;
|
97
102
|
export type IdentityEvt = z.infer<typeof identityEvt>;
|
103
|
+
export declare const accountEvt: z.ZodObject<{
|
104
|
+
did: z.ZodString;
|
105
|
+
active: z.ZodBoolean;
|
106
|
+
status: z.ZodOptional<z.ZodEnum<[AccountStatus.Takendown, AccountStatus.Suspended, AccountStatus.Deleted, AccountStatus.Deactivated]>>;
|
107
|
+
}, "strip", z.ZodTypeAny, {
|
108
|
+
did: string;
|
109
|
+
active: boolean;
|
110
|
+
status?: AccountStatus.Takendown | AccountStatus.Suspended | AccountStatus.Deleted | AccountStatus.Deactivated | undefined;
|
111
|
+
}, {
|
112
|
+
did: string;
|
113
|
+
active: boolean;
|
114
|
+
status?: AccountStatus.Takendown | AccountStatus.Suspended | AccountStatus.Deleted | AccountStatus.Deactivated | undefined;
|
115
|
+
}>;
|
116
|
+
export type AccountEvt = z.infer<typeof accountEvt>;
|
98
117
|
export declare const tombstoneEvt: z.ZodObject<{
|
99
118
|
did: z.ZodString;
|
100
119
|
}, "strip", z.ZodTypeAny, {
|
@@ -121,12 +140,18 @@ type TypedIdentityEvt = {
|
|
121
140
|
time: string;
|
122
141
|
evt: IdentityEvt;
|
123
142
|
};
|
143
|
+
type TypedAccountEvt = {
|
144
|
+
type: 'account';
|
145
|
+
seq: number;
|
146
|
+
time: string;
|
147
|
+
evt: AccountEvt;
|
148
|
+
};
|
124
149
|
type TypedTombstoneEvt = {
|
125
150
|
type: 'tombstone';
|
126
151
|
seq: number;
|
127
152
|
time: string;
|
128
153
|
evt: TombstoneEvt;
|
129
154
|
};
|
130
|
-
export type SeqEvt = TypedCommitEvt | TypedHandleEvt | TypedIdentityEvt | TypedTombstoneEvt;
|
155
|
+
export type SeqEvt = TypedCommitEvt | TypedHandleEvt | TypedIdentityEvt | TypedAccountEvt | TypedTombstoneEvt;
|
131
156
|
export {};
|
132
157
|
//# sourceMappingURL=events.d.ts.map
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"events.d.ts","sourceRoot":"","sources":["../../src/sequencer/events.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CA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,EAAE,MAAM,CAAA;IACX,IAAI,EAAE,MAAM,CAAA;IACZ,GAAG,EAAE,YAAY,CAAA;CAClB,CAAA;AACD,MAAM,MAAM,MAAM,GACd,cAAc,GACd,cAAc,GACd,gBAAgB,GAChB,eAAe,GACf,iBAAiB,CAAA"}
|
package/dist/sequencer/events.js
CHANGED
@@ -1,9 +1,10 @@
|
|
1
1
|
"use strict";
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
3
|
-
exports.tombstoneEvt = exports.identityEvt = exports.handleEvt = exports.commitEvt = exports.commitEvtOp = exports.formatSeqTombstone = exports.formatSeqIdentityEvt = exports.formatSeqHandleUpdate = exports.formatSeqCommit = void 0;
|
3
|
+
exports.tombstoneEvt = exports.accountEvt = exports.identityEvt = exports.handleEvt = exports.commitEvt = exports.commitEvtOp = exports.formatSeqTombstone = exports.formatSeqAccountEvt = exports.formatSeqIdentityEvt = exports.formatSeqHandleUpdate = exports.formatSeqCommit = void 0;
|
4
4
|
const zod_1 = require("zod");
|
5
5
|
const common_1 = require("@atproto/common");
|
6
6
|
const repo_1 = require("@atproto/repo");
|
7
|
+
const account_manager_1 = require("../account-manager");
|
7
8
|
const formatSeqCommit = async (did, commitData, writes) => {
|
8
9
|
let tooBig;
|
9
10
|
const ops = [];
|
@@ -67,10 +68,13 @@ const formatSeqHandleUpdate = async (did, handle) => {
|
|
67
68
|
};
|
68
69
|
};
|
69
70
|
exports.formatSeqHandleUpdate = formatSeqHandleUpdate;
|
70
|
-
const formatSeqIdentityEvt = async (did) => {
|
71
|
+
const formatSeqIdentityEvt = async (did, handle) => {
|
71
72
|
const evt = {
|
72
73
|
did,
|
73
74
|
};
|
75
|
+
if (handle) {
|
76
|
+
evt.handle = handle;
|
77
|
+
}
|
74
78
|
return {
|
75
79
|
did,
|
76
80
|
eventType: 'identity',
|
@@ -79,6 +83,22 @@ const formatSeqIdentityEvt = async (did) => {
|
|
79
83
|
};
|
80
84
|
};
|
81
85
|
exports.formatSeqIdentityEvt = formatSeqIdentityEvt;
|
86
|
+
const formatSeqAccountEvt = async (did, status) => {
|
87
|
+
const evt = {
|
88
|
+
did,
|
89
|
+
active: status === 'active',
|
90
|
+
};
|
91
|
+
if (status !== account_manager_1.AccountStatus.Active) {
|
92
|
+
evt.status = status;
|
93
|
+
}
|
94
|
+
return {
|
95
|
+
did,
|
96
|
+
eventType: 'account',
|
97
|
+
event: (0, common_1.cborEncode)(evt),
|
98
|
+
sequencedAt: new Date().toISOString(),
|
99
|
+
};
|
100
|
+
};
|
101
|
+
exports.formatSeqAccountEvt = formatSeqAccountEvt;
|
82
102
|
const formatSeqTombstone = async (did) => {
|
83
103
|
const evt = {
|
84
104
|
did,
|
@@ -118,6 +138,19 @@ exports.handleEvt = zod_1.z.object({
|
|
118
138
|
});
|
119
139
|
exports.identityEvt = zod_1.z.object({
|
120
140
|
did: zod_1.z.string(),
|
141
|
+
handle: zod_1.z.string().optional(),
|
142
|
+
});
|
143
|
+
exports.accountEvt = zod_1.z.object({
|
144
|
+
did: zod_1.z.string(),
|
145
|
+
active: zod_1.z.boolean(),
|
146
|
+
status: zod_1.z
|
147
|
+
.enum([
|
148
|
+
account_manager_1.AccountStatus.Takendown,
|
149
|
+
account_manager_1.AccountStatus.Suspended,
|
150
|
+
account_manager_1.AccountStatus.Deleted,
|
151
|
+
account_manager_1.AccountStatus.Deactivated,
|
152
|
+
])
|
153
|
+
.optional(),
|
121
154
|
});
|
122
155
|
exports.tombstoneEvt = zod_1.z.object({
|
123
156
|
did: zod_1.z.string(),
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"events.js","sourceRoot":"","sources":["../../src/sequencer/events.ts"],"names":[],"mappings":";;;AAAA,6BAAuB;AACvB,4CAAoD;AACpD,wCAMsB;
|
1
|
+
{"version":3,"file":"events.js","sourceRoot":"","sources":["../../src/sequencer/events.ts"],"names":[],"mappings":";;;AAAA,6BAAuB;AACvB,4CAAoD;AACpD,wCAMsB;AAItB,wDAAkD;AAE3C,MAAM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AC;SACD,QAAQ,EAAE;CACd,CAAC,CAAA;AAGW,QAAA,YAAY,GAAG,OAAC,CAAC,MAAM,CAAC;IACnC,GAAG,EAAE,OAAC,CAAC,MAAM,EAAE;CAChB,CAAC,CAAA"}
|
@@ -4,6 +4,7 @@ import { SeqEvt } from './events';
|
|
4
4
|
import { SequencerDb, RepoSeqEntry, RepoSeqInsert } from './db';
|
5
5
|
import { PreparedWrite } from '../repo';
|
6
6
|
import { Crawlers } from '../crawlers';
|
7
|
+
import { AccountStatus } from '../account-manager/helpers/account';
|
7
8
|
export * from './events';
|
8
9
|
declare const Sequencer_base: new () => SequencerEmitter;
|
9
10
|
export declare class Sequencer extends Sequencer_base {
|
@@ -27,12 +28,13 @@ export declare class Sequencer extends Sequencer_base {
|
|
27
28
|
}): Promise<SeqEvt[]>;
|
28
29
|
private pollDb;
|
29
30
|
private exponentialBackoff;
|
30
|
-
sequenceEvt(evt: RepoSeqInsert): Promise<
|
31
|
-
sequenceCommit(did: string, commitData: CommitData, writes: PreparedWrite[]): Promise<
|
32
|
-
sequenceHandleUpdate(did: string, handle: string): Promise<
|
33
|
-
sequenceIdentityEvt(did: string): Promise<
|
34
|
-
|
35
|
-
|
31
|
+
sequenceEvt(evt: RepoSeqInsert): Promise<number>;
|
32
|
+
sequenceCommit(did: string, commitData: CommitData, writes: PreparedWrite[]): Promise<number>;
|
33
|
+
sequenceHandleUpdate(did: string, handle: string): Promise<number>;
|
34
|
+
sequenceIdentityEvt(did: string, handle?: string): Promise<number>;
|
35
|
+
sequenceAccountEvt(did: string, status: AccountStatus): Promise<number>;
|
36
|
+
sequenceTombstone(did: string): Promise<number>;
|
37
|
+
deleteAllForUser(did: string, excludingSeqs?: number[]): Promise<void>;
|
36
38
|
}
|
37
39
|
type SeqRow = RepoSeqEntry;
|
38
40
|
type SequencerEvents = {
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"sequencer.d.ts","sourceRoot":"","sources":["../../src/sequencer/sequencer.ts"],"names":[],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,MAAM,CAAA;QACrB,KAAK,CAAC,EAAE,MAAM,CAAA;KACf,GAAG,OAAO,CAAC,MAAM,EAAE,CAAC;YA0EP,MAAM;YAwBN,kBAAkB;IAM1B,WAAW,CAAC,GAAG,EAAE,aAAa,GAAG,OAAO,CAAC,MAAM,CAAC;IAQhD,cAAc,CAClB,GAAG,EAAE,MAAM,EACX,UAAU,EAAE,UAAU,EACtB,MAAM,EAAE,aAAa,EAAE,GACtB,OAAO,CAAC,MAAM,CAAC;IAKZ,oBAAoB,CAAC,GAAG,EAAE,MAAM,EAAE,MAAM,EAAE,MAAM,GAAG,OAAO,CAAC,MAAM,CAAC;IAKlE,mBAAmB,CAAC,GAAG,EAAE,MAAM,EAAE,MAAM,CAAC,EAAE,MAAM,GAAG,OAAO,CAAC,MAAM,CAAC;IAKlE,kBAAkB,CACtB,GAAG,EAAE,MAAM,EACX,MAAM,EAAE,aAAa,GACpB,OAAO,CAAC,MAAM,CAAC;IAKZ,iBAAiB,CAAC,GAAG,EAAE,MAAM,GAAG,OAAO,CAAC,MAAM,CAAC;IAK/C,gBAAgB,CAAC,GAAG,EAAE,MAAM,EAAE,aAAa,GAAE,MAAM,EAAO;CAUjE;AAED,KAAK,MAAM,GAAG,YAAY,CAAA;AAE1B,KAAK,eAAe,GAAG;IACrB,MAAM,EAAE,CAAC,IAAI,EAAE,MAAM,EAAE,KAAK,IAAI,CAAA;IAChC,KAAK,EAAE,MAAM,IAAI,CAAA;CAClB,CAAA;AAED,MAAM,MAAM,gBAAgB,GAAG,YAAY,CAAC,eAAe,CAAC,CAAA;AAE5D,eAAe,SAAS,CAAA"}
|
@@ -167,6 +167,14 @@ class Sequencer extends events_1.default {
|
|
167
167
|
evt: evt,
|
168
168
|
});
|
169
169
|
}
|
170
|
+
else if (row.eventType === 'account') {
|
171
|
+
seqEvts.push({
|
172
|
+
type: 'account',
|
173
|
+
seq: row.seq,
|
174
|
+
time: row.sequencedAt,
|
175
|
+
evt: evt,
|
176
|
+
});
|
177
|
+
}
|
170
178
|
else if (row.eventType === 'tombstone') {
|
171
179
|
seqEvts.push({
|
172
180
|
type: 'tombstone',
|
@@ -210,30 +218,35 @@ class Sequencer extends events_1.default {
|
|
210
218
|
await (0, common_1.wait)(waitTime);
|
211
219
|
}
|
212
220
|
async sequenceEvt(evt) {
|
213
|
-
await this.db.executeWithRetry(this.db.db.insertInto('repo_seq').values(evt));
|
221
|
+
const res = await this.db.executeWithRetry(this.db.db.insertInto('repo_seq').values(evt).returningAll());
|
214
222
|
this.crawlers.notifyOfUpdate();
|
223
|
+
return res[0].seq;
|
215
224
|
}
|
216
225
|
async sequenceCommit(did, commitData, writes) {
|
217
226
|
const evt = await (0, events_2.formatSeqCommit)(did, commitData, writes);
|
218
|
-
await this.sequenceEvt(evt);
|
227
|
+
return await this.sequenceEvt(evt);
|
219
228
|
}
|
220
229
|
async sequenceHandleUpdate(did, handle) {
|
221
230
|
const evt = await (0, events_2.formatSeqHandleUpdate)(did, handle);
|
222
|
-
await this.sequenceEvt(evt);
|
231
|
+
return await this.sequenceEvt(evt);
|
232
|
+
}
|
233
|
+
async sequenceIdentityEvt(did, handle) {
|
234
|
+
const evt = await (0, events_2.formatSeqIdentityEvt)(did, handle);
|
235
|
+
return await this.sequenceEvt(evt);
|
223
236
|
}
|
224
|
-
async
|
225
|
-
const evt = await (0, events_2.
|
226
|
-
await this.sequenceEvt(evt);
|
237
|
+
async sequenceAccountEvt(did, status) {
|
238
|
+
const evt = await (0, events_2.formatSeqAccountEvt)(did, status);
|
239
|
+
return await this.sequenceEvt(evt);
|
227
240
|
}
|
228
241
|
async sequenceTombstone(did) {
|
229
242
|
const evt = await (0, events_2.formatSeqTombstone)(did);
|
230
|
-
await this.sequenceEvt(evt);
|
243
|
+
return await this.sequenceEvt(evt);
|
231
244
|
}
|
232
|
-
async deleteAllForUser(did) {
|
245
|
+
async deleteAllForUser(did, excludingSeqs = []) {
|
233
246
|
await this.db.executeWithRetry(this.db.db
|
234
247
|
.deleteFrom('repo_seq')
|
235
248
|
.where('did', '=', did)
|
236
|
-
.where('
|
249
|
+
.if(excludingSeqs.length > 0, (qb) => qb.where('seq', 'not in', excludingSeqs)));
|
237
250
|
}
|
238
251
|
}
|
239
252
|
exports.Sequencer = Sequencer;
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"sequencer.js","sourceRoot":"","sources":["../../src/sequencer/sequencer.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;AAAA,oDAAiC;AAEjC,sCAA4C;AAC5C,4CAA0D;AAE1D,
|
1
|
+
{"version":3,"file":"sequencer.js","sourceRoot":"","sources":["../../src/sequencer/sequencer.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;AAAA,oDAAiC;AAEjC,sCAA4C;AAC5C,4CAA0D;AAE1D,qCAYiB;AACjB,6BAMa;AAKb,2CAAwB;AAExB,MAAa,SAAU,SAAS,gBAA2C;IAMzE,YACE,UAAkB,EACX,QAAkB,EAClB,WAAW,CAAC,EACnB,wBAAwB,GAAG,KAAK;QAEhC,KAAK,EAAE,CAAA;QAJP;;;;mBAAO,QAAQ;WAAU;QACzB;;;;mBAAO,QAAQ;WAAI;QARrB;;;;;WAAe;QACf;;;;mBAAY,KAAK;WAAA;QACjB;;;;mBAAoC,IAAI;WAAA;QACxC;;;;mBAAqB,CAAC;WAAA;QASpB,0EAA0E;QAC1E,IAAI,CAAC,eAAe,CAAC,GAAG,CAAC,CAAA;QACzB,IAAI,CAAC,EAAE,GAAG,IAAA,UAAK,EAAC,UAAU,EAAE,wBAAwB,CAAC,CAAA;IACvD,CAAC;IAED,KAAK,CAAC,KAAK;QACT,MAAM,IAAI,CAAC,EAAE,CAAC,SAAS,EAAE,CAAA;QACzB,MAAM,QAAQ,GAAG,IAAA,gBAAW,EAAC,IAAI,CAAC,EAAE,CAAC,CAAA;QACrC,MAAM,QAAQ,CAAC,sBAAsB,EAAE,CAAA;QACvC,MAAM,IAAI,GAAG,MAAM,IAAI,CAAC,IAAI,EA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B,CACtB,GAAW,EACX,MAAqB;QAErB,MAAM,GAAG,GAAG,MAAM,IAAA,4BAAmB,EAAC,GAAG,EAAE,MAAM,CAAC,CAAA;QAClD,OAAO,MAAM,IAAI,CAAC,WAAW,CAAC,GAAG,CAAC,CAAA;IACpC,CAAC;IAED,KAAK,CAAC,iBAAiB,CAAC,GAAW;QACjC,MAAM,GAAG,GAAG,MAAM,IAAA,2BAAkB,EAAC,GAAG,CAAC,CAAA;QACzC,OAAO,MAAM,IAAI,CAAC,WAAW,CAAC,GAAG,CAAC,CAAA;IACpC,CAAC;IAED,KAAK,CAAC,gBAAgB,CAAC,GAAW,EAAE,gBAA0B,EAAE;QAC9D,MAAM,IAAI,CAAC,EAAE,CAAC,gBAAgB,CAC5B,IAAI,CAAC,EAAE,CAAC,EAAE;aACP,UAAU,CAAC,UAAU,CAAC;aACtB,KAAK,CAAC,KAAK,EAAE,GAAG,EAAE,GAAG,CAAC;aACtB,EAAE,CAAC,aAAa,CAAC,MAAM,GAAG,CAAC,EAAE,CAAC,EAAE,EAAE,EAAE,CACnC,EAAE,CAAC,KAAK,CAAC,KAAK,EAAE,QAAQ,EAAE,aAAa,CAAC,CACzC,CACJ,CAAA;IACH,CAAC;CACF;AApOD,8BAoOC;AAWD,kBAAe,SAAS,CAAA"}
|
package/package.json
CHANGED
@@ -1,6 +1,6 @@
|
|
1
1
|
{
|
2
2
|
"name": "@atproto/pds",
|
3
|
-
"version": "0.4.
|
3
|
+
"version": "0.4.30",
|
4
4
|
"license": "MIT",
|
5
5
|
"description": "Reference implementation of atproto Personal Data Server (PDS)",
|
6
6
|
"keywords": [
|
@@ -43,7 +43,7 @@
|
|
43
43
|
"typed-emitter": "^2.1.0",
|
44
44
|
"uint8arrays": "3.0.0",
|
45
45
|
"zod": "^3.21.4",
|
46
|
-
"@atproto/api": "^0.12.
|
46
|
+
"@atproto/api": "^0.12.15",
|
47
47
|
"@atproto/aws": "^0.2.0",
|
48
48
|
"@atproto/common": "^0.4.0",
|
49
49
|
"@atproto/crypto": "^0.4.0",
|
@@ -70,8 +70,8 @@
|
|
70
70
|
"jest": "^28.1.2",
|
71
71
|
"ts-node": "^10.8.2",
|
72
72
|
"ws": "^8.12.0",
|
73
|
-
"@atproto/api": "^0.12.
|
74
|
-
"@atproto/bsky": "^0.0.
|
73
|
+
"@atproto/api": "^0.12.15",
|
74
|
+
"@atproto/bsky": "^0.0.58",
|
75
75
|
"@atproto/lex-cli": "^0.4.0"
|
76
76
|
},
|
77
77
|
"scripts": {
|