@clioplaylists/clio 0.1.4 → 0.1.6
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.
- package/dist/api/com/clioplaylists/alpha/actor/getProfile.d.ts +0 -0
- package/dist/api/com/clioplaylists/alpha/actor/getProfile.js +37 -0
- package/dist/api/com/clioplaylists/alpha/feed/getSongs.d.ts +0 -0
- package/dist/api/com/clioplaylists/alpha/feed/getSongs.js +37 -0
- package/dist/api/health.d.ts +3 -0
- package/dist/api/health.js +32 -0
- package/dist/api/index.d.ts +4 -0
- package/dist/api/index.js +43 -0
- package/dist/api/util.d.ts +9 -0
- package/dist/api/util.js +17 -0
- package/dist/auth-verifier.d.ts +92 -0
- package/dist/auth-verifier.js +473 -0
- package/dist/client.d.ts +9 -0
- package/dist/client.js +40 -0
- package/dist/config.d.ts +21 -0
- package/dist/config.js +65 -0
- package/dist/context.d.ts +11 -0
- package/dist/context.js +19 -0
- package/dist/dataplane/client.d.ts +27 -0
- package/dist/dataplane/client.js +165 -0
- package/dist/dataplane/index.d.ts +2 -0
- package/dist/dataplane/index.js +18 -0
- package/dist/dataplane/server/background.d.ts +13 -0
- package/dist/dataplane/server/background.js +51 -0
- package/dist/dataplane/server/db/database-schema.d.ts +13 -0
- package/dist/dataplane/server/db/database-schema.js +2 -0
- package/dist/dataplane/server/db/db.d.ts +32 -0
- package/dist/dataplane/server/db/db.js +228 -0
- package/dist/dataplane/server/db/index.d.ts +1 -0
- package/dist/dataplane/server/db/index.js +17 -0
- package/dist/dataplane/server/db/migrations/20230309T045948368Z-init.d.ts +3 -0
- package/dist/dataplane/server/db/migrations/20230309T045948368Z-init.js +117 -0
- package/dist/dataplane/server/db/migrations/20230420T211446071Z-did-cache.d.ts +3 -0
- package/dist/dataplane/server/db/migrations/20230420T211446071Z-did-cache.js +15 -0
- package/dist/dataplane/server/db/migrations/index.d.ts +2 -0
- package/dist/dataplane/server/db/migrations/index.js +41 -0
- package/dist/dataplane/server/db/migrations/provider.d.ts +11 -0
- package/dist/dataplane/server/db/migrations/provider.js +31 -0
- package/dist/dataplane/server/db/pagination.d.ts +86 -0
- package/dist/dataplane/server/db/pagination.js +144 -0
- package/dist/dataplane/server/db/tables/actor-sync.d.ts +9 -0
- package/dist/dataplane/server/db/tables/actor-sync.js +4 -0
- package/dist/dataplane/server/db/tables/actor.d.ts +11 -0
- package/dist/dataplane/server/db/tables/actor.js +4 -0
- package/dist/dataplane/server/db/tables/artist-list-item.d.ts +11 -0
- package/dist/dataplane/server/db/tables/artist-list-item.js +4 -0
- package/dist/dataplane/server/db/tables/artist.d.ts +10 -0
- package/dist/dataplane/server/db/tables/artist.js +4 -0
- package/dist/dataplane/server/db/tables/playlist-idea.d.ts +14 -0
- package/dist/dataplane/server/db/tables/playlist-idea.js +4 -0
- package/dist/dataplane/server/db/tables/playlist-item.d.ts +11 -0
- package/dist/dataplane/server/db/tables/playlist-item.js +4 -0
- package/dist/dataplane/server/db/tables/playlist.d.ts +10 -0
- package/dist/dataplane/server/db/tables/playlist.js +4 -0
- package/dist/dataplane/server/db/tables/profile.d.ts +15 -0
- package/dist/dataplane/server/db/tables/profile.js +4 -0
- package/dist/dataplane/server/db/tables/record.d.ts +12 -0
- package/dist/dataplane/server/db/tables/record.js +4 -0
- package/dist/dataplane/server/db/tables/song.d.ts +12 -0
- package/dist/dataplane/server/db/tables/song.js +4 -0
- package/dist/dataplane/server/db/types.d.ts +9 -0
- package/dist/dataplane/server/db/types.js +2 -0
- package/dist/dataplane/server/db/util.d.ts +20 -0
- package/dist/dataplane/server/db/util.js +48 -0
- package/dist/dataplane/server/index.d.ts +11 -0
- package/dist/dataplane/server/index.js +52 -0
- package/dist/dataplane/server/indexing/index.d.ts +32 -0
- package/dist/dataplane/server/indexing/index.js +321 -0
- package/dist/dataplane/server/indexing/plugins/playlist-idea.d.ts +14 -0
- package/dist/dataplane/server/indexing/plugins/playlist-idea.js +163 -0
- package/dist/dataplane/server/indexing/plugins/profile.d.ts +8 -0
- package/dist/dataplane/server/indexing/plugins/profile.js +81 -0
- package/dist/dataplane/server/indexing/processor.d.ts +22 -0
- package/dist/dataplane/server/indexing/processor.js +90 -0
- package/dist/dataplane/server/routes/identity.d.ts +6 -0
- package/dist/dataplane/server/routes/identity.js +56 -0
- package/dist/dataplane/server/routes/index.d.ts +5 -0
- package/dist/dataplane/server/routes/index.js +19 -0
- package/dist/dataplane/server/routes/profile.d.ts +5 -0
- package/dist/dataplane/server/routes/profile.js +61 -0
- package/dist/dataplane/server/routes/records.d.ts +11 -0
- package/dist/dataplane/server/routes/records.js +88 -0
- package/dist/dataplane/server/routes/sync.d.ts +5 -0
- package/dist/dataplane/server/routes/sync.js +14 -0
- package/dist/dataplane/server/subscription.d.ts +25 -0
- package/dist/dataplane/server/subscription.js +114 -0
- package/dist/error.d.ts +2 -0
- package/dist/error.js +14 -0
- package/dist/index.d.ts +20 -0
- package/dist/index.js +115 -0
- package/dist/lexicons/index.d.ts +278 -0
- package/dist/lexicons/index.js +638 -0
- package/dist/lexicons/lexicons.d.ts +8466 -0
- package/dist/lexicons/lexicons.js +4551 -0
- package/dist/lexicons/types/com/atproto/admin/defs.d.ts +50 -0
- package/dist/lexicons/types/com/atproto/admin/defs.js +54 -0
- package/dist/lexicons/types/com/atproto/admin/deleteAccount.d.ts +29 -0
- package/dist/lexicons/types/com/atproto/admin/deleteAccount.js +2 -0
- package/dist/lexicons/types/com/atproto/admin/disableAccountInvites.d.ts +31 -0
- package/dist/lexicons/types/com/atproto/admin/disableAccountInvites.js +2 -0
- package/dist/lexicons/types/com/atproto/admin/disableInviteCodes.d.ts +30 -0
- package/dist/lexicons/types/com/atproto/admin/disableInviteCodes.js +2 -0
- package/dist/lexicons/types/com/atproto/admin/enableAccountInvites.d.ts +31 -0
- package/dist/lexicons/types/com/atproto/admin/enableAccountInvites.js +2 -0
- package/dist/lexicons/types/com/atproto/admin/getAccountInfo.d.ts +33 -0
- package/dist/lexicons/types/com/atproto/admin/getAccountInfo.js +2 -0
- package/dist/lexicons/types/com/atproto/admin/getAccountInfos.d.ts +36 -0
- package/dist/lexicons/types/com/atproto/admin/getAccountInfos.js +2 -0
- package/dist/lexicons/types/com/atproto/admin/getInviteCodes.d.ts +39 -0
- package/dist/lexicons/types/com/atproto/admin/getInviteCodes.js +2 -0
- package/dist/lexicons/types/com/atproto/admin/getSubjectStatus.d.ts +44 -0
- package/dist/lexicons/types/com/atproto/admin/getSubjectStatus.js +2 -0
- package/dist/lexicons/types/com/atproto/admin/searchAccounts.d.ts +39 -0
- package/dist/lexicons/types/com/atproto/admin/searchAccounts.js +2 -0
- package/dist/lexicons/types/com/atproto/admin/sendEmail.d.ts +45 -0
- package/dist/lexicons/types/com/atproto/admin/sendEmail.js +2 -0
- package/dist/lexicons/types/com/atproto/admin/updateAccountEmail.d.ts +31 -0
- package/dist/lexicons/types/com/atproto/admin/updateAccountEmail.js +2 -0
- package/dist/lexicons/types/com/atproto/admin/updateAccountHandle.d.ts +30 -0
- package/dist/lexicons/types/com/atproto/admin/updateAccountHandle.js +2 -0
- package/dist/lexicons/types/com/atproto/admin/updateAccountPassword.d.ts +30 -0
- package/dist/lexicons/types/com/atproto/admin/updateAccountPassword.js +2 -0
- package/dist/lexicons/types/com/atproto/admin/updateSubjectStatus.d.ts +51 -0
- package/dist/lexicons/types/com/atproto/admin/updateSubjectStatus.js +2 -0
- package/dist/lexicons/types/com/atproto/identity/defs.d.ts +14 -0
- package/dist/lexicons/types/com/atproto/identity/defs.js +14 -0
- package/dist/lexicons/types/com/atproto/identity/getRecommendedDidCredentials.d.ts +38 -0
- package/dist/lexicons/types/com/atproto/identity/getRecommendedDidCredentials.js +2 -0
- package/dist/lexicons/types/com/atproto/identity/refreshIdentity.d.ts +39 -0
- package/dist/lexicons/types/com/atproto/identity/refreshIdentity.js +2 -0
- package/dist/lexicons/types/com/atproto/identity/requestPlcOperationSignature.d.ts +23 -0
- package/dist/lexicons/types/com/atproto/identity/requestPlcOperationSignature.js +2 -0
- package/dist/lexicons/types/com/atproto/identity/resolveDid.d.ts +38 -0
- package/dist/lexicons/types/com/atproto/identity/resolveDid.js +2 -0
- package/dist/lexicons/types/com/atproto/identity/resolveHandle.d.ts +37 -0
- package/dist/lexicons/types/com/atproto/identity/resolveHandle.js +2 -0
- package/dist/lexicons/types/com/atproto/identity/resolveIdentity.d.ts +35 -0
- package/dist/lexicons/types/com/atproto/identity/resolveIdentity.js +2 -0
- package/dist/lexicons/types/com/atproto/identity/signPlcOperation.d.ts +46 -0
- package/dist/lexicons/types/com/atproto/identity/signPlcOperation.js +2 -0
- package/dist/lexicons/types/com/atproto/identity/submitPlcOperation.d.ts +29 -0
- package/dist/lexicons/types/com/atproto/identity/submitPlcOperation.js +2 -0
- package/dist/lexicons/types/com/atproto/identity/updateHandle.d.ts +30 -0
- package/dist/lexicons/types/com/atproto/identity/updateHandle.js +2 -0
- package/dist/lexicons/types/com/atproto/label/defs.d.ts +73 -0
- package/dist/lexicons/types/com/atproto/label/defs.js +54 -0
- package/dist/lexicons/types/com/atproto/label/queryLabels.d.ts +42 -0
- package/dist/lexicons/types/com/atproto/label/queryLabels.js +2 -0
- package/dist/lexicons/types/com/atproto/label/subscribeLabels.d.ts +38 -0
- package/dist/lexicons/types/com/atproto/label/subscribeLabels.js +24 -0
- package/dist/lexicons/types/com/atproto/lexicon/schema.d.ts +11 -0
- package/dist/lexicons/types/com/atproto/lexicon/schema.js +15 -0
- package/dist/lexicons/types/com/atproto/moderation/createReport.d.ts +57 -0
- package/dist/lexicons/types/com/atproto/moderation/createReport.js +2 -0
- package/dist/lexicons/types/com/atproto/moderation/defs.d.ts +20 -0
- package/dist/lexicons/types/com/atproto/moderation/defs.js +20 -0
- package/dist/lexicons/types/com/atproto/repo/applyWrites.d.ts +98 -0
- package/dist/lexicons/types/com/atproto/repo/applyWrites.js +64 -0
- package/dist/lexicons/types/com/atproto/repo/createRecord.d.ts +56 -0
- package/dist/lexicons/types/com/atproto/repo/createRecord.js +2 -0
- package/dist/lexicons/types/com/atproto/repo/defs.d.ts +11 -0
- package/dist/lexicons/types/com/atproto/repo/defs.js +14 -0
- package/dist/lexicons/types/com/atproto/repo/deleteRecord.d.ts +51 -0
- package/dist/lexicons/types/com/atproto/repo/deleteRecord.js +2 -0
- package/dist/lexicons/types/com/atproto/repo/describeRepo.d.ts +43 -0
- package/dist/lexicons/types/com/atproto/repo/describeRepo.js +2 -0
- package/dist/lexicons/types/com/atproto/repo/getRecord.d.ts +45 -0
- package/dist/lexicons/types/com/atproto/repo/getRecord.js +2 -0
- package/dist/lexicons/types/com/atproto/repo/importRepo.d.ts +27 -0
- package/dist/lexicons/types/com/atproto/repo/importRepo.js +2 -0
- package/dist/lexicons/types/com/atproto/repo/listMissingBlobs.d.ts +45 -0
- package/dist/lexicons/types/com/atproto/repo/listMissingBlobs.js +14 -0
- package/dist/lexicons/types/com/atproto/repo/listRecords.d.ts +53 -0
- package/dist/lexicons/types/com/atproto/repo/listRecords.js +14 -0
- package/dist/lexicons/types/com/atproto/repo/putRecord.d.ts +58 -0
- package/dist/lexicons/types/com/atproto/repo/putRecord.js +2 -0
- package/dist/lexicons/types/com/atproto/repo/strongRef.d.ts +11 -0
- package/dist/lexicons/types/com/atproto/repo/strongRef.js +15 -0
- package/dist/lexicons/types/com/atproto/repo/uploadBlob.d.ts +39 -0
- package/dist/lexicons/types/com/atproto/repo/uploadBlob.js +2 -0
- package/dist/lexicons/types/com/atproto/server/activateAccount.d.ts +23 -0
- package/dist/lexicons/types/com/atproto/server/activateAccount.js +2 -0
- package/dist/lexicons/types/com/atproto/server/checkAccountStatus.d.ts +42 -0
- package/dist/lexicons/types/com/atproto/server/checkAccountStatus.js +2 -0
- package/dist/lexicons/types/com/atproto/server/confirmEmail.d.ts +31 -0
- package/dist/lexicons/types/com/atproto/server/confirmEmail.js +2 -0
- package/dist/lexicons/types/com/atproto/server/createAccount.d.ts +61 -0
- package/dist/lexicons/types/com/atproto/server/createAccount.js +2 -0
- package/dist/lexicons/types/com/atproto/server/createAppPassword.d.ts +51 -0
- package/dist/lexicons/types/com/atproto/server/createAppPassword.js +14 -0
- package/dist/lexicons/types/com/atproto/server/createInviteCode.d.ts +41 -0
- package/dist/lexicons/types/com/atproto/server/createInviteCode.js +2 -0
- package/dist/lexicons/types/com/atproto/server/createInviteCodes.d.ts +50 -0
- package/dist/lexicons/types/com/atproto/server/createInviteCodes.js +14 -0
- package/dist/lexicons/types/com/atproto/server/createSession.d.ts +56 -0
- package/dist/lexicons/types/com/atproto/server/createSession.js +2 -0
- package/dist/lexicons/types/com/atproto/server/deactivateAccount.d.ts +30 -0
- package/dist/lexicons/types/com/atproto/server/deactivateAccount.js +2 -0
- package/dist/lexicons/types/com/atproto/server/defs.d.ts +23 -0
- package/dist/lexicons/types/com/atproto/server/defs.js +24 -0
- package/dist/lexicons/types/com/atproto/server/deleteAccount.d.ts +32 -0
- package/dist/lexicons/types/com/atproto/server/deleteAccount.js +2 -0
- package/dist/lexicons/types/com/atproto/server/deleteSession.d.ts +23 -0
- package/dist/lexicons/types/com/atproto/server/deleteSession.js +2 -0
- package/dist/lexicons/types/com/atproto/server/describeServer.d.ts +56 -0
- package/dist/lexicons/types/com/atproto/server/describeServer.js +24 -0
- package/dist/lexicons/types/com/atproto/server/getAccountInviteCodes.d.ts +39 -0
- package/dist/lexicons/types/com/atproto/server/getAccountInviteCodes.js +2 -0
- package/dist/lexicons/types/com/atproto/server/getServiceAuth.d.ts +41 -0
- package/dist/lexicons/types/com/atproto/server/getServiceAuth.js +2 -0
- package/dist/lexicons/types/com/atproto/server/getSession.d.ts +42 -0
- package/dist/lexicons/types/com/atproto/server/getSession.js +2 -0
- package/dist/lexicons/types/com/atproto/server/listAppPasswords.d.ts +44 -0
- package/dist/lexicons/types/com/atproto/server/listAppPasswords.js +14 -0
- package/dist/lexicons/types/com/atproto/server/refreshSession.d.ts +42 -0
- package/dist/lexicons/types/com/atproto/server/refreshSession.js +2 -0
- package/dist/lexicons/types/com/atproto/server/requestAccountDelete.d.ts +23 -0
- package/dist/lexicons/types/com/atproto/server/requestAccountDelete.js +2 -0
- package/dist/lexicons/types/com/atproto/server/requestEmailConfirmation.d.ts +23 -0
- package/dist/lexicons/types/com/atproto/server/requestEmailConfirmation.js +2 -0
- package/dist/lexicons/types/com/atproto/server/requestEmailUpdate.d.ts +34 -0
- package/dist/lexicons/types/com/atproto/server/requestEmailUpdate.js +2 -0
- package/dist/lexicons/types/com/atproto/server/requestPasswordReset.d.ts +29 -0
- package/dist/lexicons/types/com/atproto/server/requestPasswordReset.js +2 -0
- package/dist/lexicons/types/com/atproto/server/reserveSigningKey.d.ts +42 -0
- package/dist/lexicons/types/com/atproto/server/reserveSigningKey.js +2 -0
- package/dist/lexicons/types/com/atproto/server/resetPassword.d.ts +31 -0
- package/dist/lexicons/types/com/atproto/server/resetPassword.js +2 -0
- package/dist/lexicons/types/com/atproto/server/revokeAppPassword.d.ts +29 -0
- package/dist/lexicons/types/com/atproto/server/revokeAppPassword.js +2 -0
- package/dist/lexicons/types/com/atproto/server/updateEmail.d.ts +33 -0
- package/dist/lexicons/types/com/atproto/server/updateEmail.js +2 -0
- package/dist/lexicons/types/com/atproto/sync/getBlob.d.ts +36 -0
- package/dist/lexicons/types/com/atproto/sync/getBlob.js +2 -0
- package/dist/lexicons/types/com/atproto/sync/getBlocks.d.ts +35 -0
- package/dist/lexicons/types/com/atproto/sync/getBlocks.js +2 -0
- package/dist/lexicons/types/com/atproto/sync/getCheckout.d.ts +33 -0
- package/dist/lexicons/types/com/atproto/sync/getCheckout.js +2 -0
- package/dist/lexicons/types/com/atproto/sync/getHead.d.ts +37 -0
- package/dist/lexicons/types/com/atproto/sync/getHead.js +2 -0
- package/dist/lexicons/types/com/atproto/sync/getLatestCommit.d.ts +38 -0
- package/dist/lexicons/types/com/atproto/sync/getLatestCommit.js +2 -0
- package/dist/lexicons/types/com/atproto/sync/getRecord.d.ts +37 -0
- package/dist/lexicons/types/com/atproto/sync/getRecord.js +2 -0
- package/dist/lexicons/types/com/atproto/sync/getRepo.d.ts +36 -0
- package/dist/lexicons/types/com/atproto/sync/getRepo.js +2 -0
- package/dist/lexicons/types/com/atproto/sync/getRepoStatus.d.ts +42 -0
- package/dist/lexicons/types/com/atproto/sync/getRepoStatus.js +2 -0
- package/dist/lexicons/types/com/atproto/sync/listBlobs.d.ts +42 -0
- package/dist/lexicons/types/com/atproto/sync/listBlobs.js +2 -0
- package/dist/lexicons/types/com/atproto/sync/listRepos.d.ts +50 -0
- package/dist/lexicons/types/com/atproto/sync/listRepos.js +14 -0
- package/dist/lexicons/types/com/atproto/sync/listReposByCollection.d.ts +46 -0
- package/dist/lexicons/types/com/atproto/sync/listReposByCollection.js +14 -0
- package/dist/lexicons/types/com/atproto/sync/notifyOfUpdate.d.ts +30 -0
- package/dist/lexicons/types/com/atproto/sync/notifyOfUpdate.js +2 -0
- package/dist/lexicons/types/com/atproto/sync/requestCrawl.d.ts +30 -0
- package/dist/lexicons/types/com/atproto/sync/requestCrawl.js +2 -0
- package/dist/lexicons/types/com/atproto/sync/subscribeRepos.d.ts +111 -0
- package/dist/lexicons/types/com/atproto/sync/subscribeRepos.js +64 -0
- package/dist/lexicons/types/com/atproto/temp/addReservedHandle.d.ts +39 -0
- package/dist/lexicons/types/com/atproto/temp/addReservedHandle.js +2 -0
- package/dist/lexicons/types/com/atproto/temp/checkSignupQueue.d.ts +36 -0
- package/dist/lexicons/types/com/atproto/temp/checkSignupQueue.js +2 -0
- package/dist/lexicons/types/com/atproto/temp/fetchLabels.d.ts +37 -0
- package/dist/lexicons/types/com/atproto/temp/fetchLabels.js +2 -0
- package/dist/lexicons/types/com/atproto/temp/requestPhoneVerification.d.ts +29 -0
- package/dist/lexicons/types/com/atproto/temp/requestPhoneVerification.js +2 -0
- package/dist/lexicons/types/com/clioplaylists/alpha/actor/profile.d.ts +19 -0
- package/dist/lexicons/types/com/clioplaylists/alpha/actor/profile.js +15 -0
- package/dist/lexicons/types/com/clioplaylists/alpha/feed/defs.d.ts +32 -0
- package/dist/lexicons/types/com/clioplaylists/alpha/feed/defs.js +24 -0
- package/dist/lexicons/types/com/clioplaylists/alpha/feed/getSongs.d.ts +37 -0
- package/dist/lexicons/types/com/clioplaylists/alpha/feed/getSongs.js +2 -0
- package/dist/lexicons/types/com/clioplaylists/alpha/feed/playlistIdea.d.ts +32 -0
- package/dist/lexicons/types/com/clioplaylists/alpha/feed/playlistIdea.js +35 -0
- package/dist/lexicons/util.d.ts +5 -0
- package/dist/lexicons/util.js +13 -0
- package/dist/logger.d.ts +6 -0
- package/dist/logger.js +26 -0
- package/dist/rpc/clio_connect.d.ts +103 -0
- package/dist/rpc/clio_connect.js +110 -0
- package/dist/rpc/clio_pb.d.ts +457 -0
- package/dist/rpc/clio_pb.js +1365 -0
- package/dist/start.d.ts +1 -0
- package/dist/util/retry.d.ts +2 -0
- package/dist/util/retry.js +16 -0
- package/dist/util/uris.d.ts +1 -0
- package/dist/util/uris.js +7 -0
- package/dist/util.d.ts +23 -0
- package/dist/util.js +119 -0
- package/package.json +7 -7
- /package/{start.js → dist/start.js} +0 -0
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* GENERATED CODE - DO NOT MODIFY
|
|
3
|
+
*/
|
|
4
|
+
import { ValidationResult } from '@atproto/lexicon';
|
|
5
|
+
export interface IdentityInfo {
|
|
6
|
+
did: string;
|
|
7
|
+
/** The validated handle of the account; or 'handle.invalid' if the handle did not bi-directionally match the DID document. */
|
|
8
|
+
handle: string;
|
|
9
|
+
/** The complete DID document for the identity. */
|
|
10
|
+
didDoc: {};
|
|
11
|
+
[k: string]: unknown;
|
|
12
|
+
}
|
|
13
|
+
export declare function isIdentityInfo(v: unknown): v is IdentityInfo;
|
|
14
|
+
export declare function validateIdentityInfo(v: unknown): ValidationResult;
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.isIdentityInfo = isIdentityInfo;
|
|
4
|
+
exports.validateIdentityInfo = validateIdentityInfo;
|
|
5
|
+
const lexicons_1 = require("../../../../lexicons");
|
|
6
|
+
const util_1 = require("../../../../util");
|
|
7
|
+
function isIdentityInfo(v) {
|
|
8
|
+
return ((0, util_1.isObj)(v) &&
|
|
9
|
+
(0, util_1.hasProp)(v, '$type') &&
|
|
10
|
+
v.$type === 'com.atproto.identity.defs#identityInfo');
|
|
11
|
+
}
|
|
12
|
+
function validateIdentityInfo(v) {
|
|
13
|
+
return lexicons_1.lexicons.validate('com.atproto.identity.defs#identityInfo', v);
|
|
14
|
+
}
|
|
@@ -0,0 +1,38 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* GENERATED CODE - DO NOT MODIFY
|
|
3
|
+
*/
|
|
4
|
+
import { HandlerAuth, HandlerPipeThrough } from '@atproto/xrpc-server';
|
|
5
|
+
import express from 'express';
|
|
6
|
+
export interface QueryParams {
|
|
7
|
+
}
|
|
8
|
+
export type InputSchema = undefined;
|
|
9
|
+
export interface OutputSchema {
|
|
10
|
+
/** Recommended rotation keys for PLC dids. Should be undefined (or ignored) for did:webs. */
|
|
11
|
+
rotationKeys?: string[];
|
|
12
|
+
alsoKnownAs?: string[];
|
|
13
|
+
verificationMethods?: {};
|
|
14
|
+
services?: {};
|
|
15
|
+
[k: string]: unknown;
|
|
16
|
+
}
|
|
17
|
+
export type HandlerInput = undefined;
|
|
18
|
+
export interface HandlerSuccess {
|
|
19
|
+
encoding: 'application/json';
|
|
20
|
+
body: OutputSchema;
|
|
21
|
+
headers?: {
|
|
22
|
+
[key: string]: string;
|
|
23
|
+
};
|
|
24
|
+
}
|
|
25
|
+
export interface HandlerError {
|
|
26
|
+
status: number;
|
|
27
|
+
message?: string;
|
|
28
|
+
}
|
|
29
|
+
export type HandlerOutput = HandlerError | HandlerSuccess | HandlerPipeThrough;
|
|
30
|
+
export type HandlerReqCtx<HA extends HandlerAuth = never> = {
|
|
31
|
+
auth: HA;
|
|
32
|
+
params: QueryParams;
|
|
33
|
+
input: HandlerInput;
|
|
34
|
+
req: express.Request;
|
|
35
|
+
res: express.Response;
|
|
36
|
+
resetRouteRateLimits: () => Promise<void>;
|
|
37
|
+
};
|
|
38
|
+
export type Handler<HA extends HandlerAuth = never> = (ctx: HandlerReqCtx<HA>) => Promise<HandlerOutput> | HandlerOutput;
|
|
@@ -0,0 +1,39 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* GENERATED CODE - DO NOT MODIFY
|
|
3
|
+
*/
|
|
4
|
+
import { HandlerAuth, HandlerPipeThrough } from '@atproto/xrpc-server';
|
|
5
|
+
import express from 'express';
|
|
6
|
+
import * as ComAtprotoIdentityDefs from './defs';
|
|
7
|
+
export interface QueryParams {
|
|
8
|
+
}
|
|
9
|
+
export interface InputSchema {
|
|
10
|
+
identifier: string;
|
|
11
|
+
[k: string]: unknown;
|
|
12
|
+
}
|
|
13
|
+
export type OutputSchema = ComAtprotoIdentityDefs.IdentityInfo;
|
|
14
|
+
export interface HandlerInput {
|
|
15
|
+
encoding: 'application/json';
|
|
16
|
+
body: InputSchema;
|
|
17
|
+
}
|
|
18
|
+
export interface HandlerSuccess {
|
|
19
|
+
encoding: 'application/json';
|
|
20
|
+
body: OutputSchema;
|
|
21
|
+
headers?: {
|
|
22
|
+
[key: string]: string;
|
|
23
|
+
};
|
|
24
|
+
}
|
|
25
|
+
export interface HandlerError {
|
|
26
|
+
status: number;
|
|
27
|
+
message?: string;
|
|
28
|
+
error?: 'HandleNotFound' | 'DidNotFound' | 'DidDeactivated';
|
|
29
|
+
}
|
|
30
|
+
export type HandlerOutput = HandlerError | HandlerSuccess | HandlerPipeThrough;
|
|
31
|
+
export type HandlerReqCtx<HA extends HandlerAuth = never> = {
|
|
32
|
+
auth: HA;
|
|
33
|
+
params: QueryParams;
|
|
34
|
+
input: HandlerInput;
|
|
35
|
+
req: express.Request;
|
|
36
|
+
res: express.Response;
|
|
37
|
+
resetRouteRateLimits: () => Promise<void>;
|
|
38
|
+
};
|
|
39
|
+
export type Handler<HA extends HandlerAuth = never> = (ctx: HandlerReqCtx<HA>) => Promise<HandlerOutput> | HandlerOutput;
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* GENERATED CODE - DO NOT MODIFY
|
|
3
|
+
*/
|
|
4
|
+
import { HandlerAuth } from '@atproto/xrpc-server';
|
|
5
|
+
import express from 'express';
|
|
6
|
+
export interface QueryParams {
|
|
7
|
+
}
|
|
8
|
+
export type InputSchema = undefined;
|
|
9
|
+
export type HandlerInput = undefined;
|
|
10
|
+
export interface HandlerError {
|
|
11
|
+
status: number;
|
|
12
|
+
message?: string;
|
|
13
|
+
}
|
|
14
|
+
export type HandlerOutput = HandlerError | void;
|
|
15
|
+
export type HandlerReqCtx<HA extends HandlerAuth = never> = {
|
|
16
|
+
auth: HA;
|
|
17
|
+
params: QueryParams;
|
|
18
|
+
input: HandlerInput;
|
|
19
|
+
req: express.Request;
|
|
20
|
+
res: express.Response;
|
|
21
|
+
resetRouteRateLimits: () => Promise<void>;
|
|
22
|
+
};
|
|
23
|
+
export type Handler<HA extends HandlerAuth = never> = (ctx: HandlerReqCtx<HA>) => Promise<HandlerOutput> | HandlerOutput;
|
|
@@ -0,0 +1,38 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* GENERATED CODE - DO NOT MODIFY
|
|
3
|
+
*/
|
|
4
|
+
import { HandlerAuth, HandlerPipeThrough } from '@atproto/xrpc-server';
|
|
5
|
+
import express from 'express';
|
|
6
|
+
export interface QueryParams {
|
|
7
|
+
/** DID to resolve. */
|
|
8
|
+
did: string;
|
|
9
|
+
}
|
|
10
|
+
export type InputSchema = undefined;
|
|
11
|
+
export interface OutputSchema {
|
|
12
|
+
/** The complete DID document for the identity. */
|
|
13
|
+
didDoc: {};
|
|
14
|
+
[k: string]: unknown;
|
|
15
|
+
}
|
|
16
|
+
export type HandlerInput = undefined;
|
|
17
|
+
export interface HandlerSuccess {
|
|
18
|
+
encoding: 'application/json';
|
|
19
|
+
body: OutputSchema;
|
|
20
|
+
headers?: {
|
|
21
|
+
[key: string]: string;
|
|
22
|
+
};
|
|
23
|
+
}
|
|
24
|
+
export interface HandlerError {
|
|
25
|
+
status: number;
|
|
26
|
+
message?: string;
|
|
27
|
+
error?: 'DidNotFound' | 'DidDeactivated';
|
|
28
|
+
}
|
|
29
|
+
export type HandlerOutput = HandlerError | HandlerSuccess | HandlerPipeThrough;
|
|
30
|
+
export type HandlerReqCtx<HA extends HandlerAuth = never> = {
|
|
31
|
+
auth: HA;
|
|
32
|
+
params: QueryParams;
|
|
33
|
+
input: HandlerInput;
|
|
34
|
+
req: express.Request;
|
|
35
|
+
res: express.Response;
|
|
36
|
+
resetRouteRateLimits: () => Promise<void>;
|
|
37
|
+
};
|
|
38
|
+
export type Handler<HA extends HandlerAuth = never> = (ctx: HandlerReqCtx<HA>) => Promise<HandlerOutput> | HandlerOutput;
|
|
@@ -0,0 +1,37 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* GENERATED CODE - DO NOT MODIFY
|
|
3
|
+
*/
|
|
4
|
+
import { HandlerAuth, HandlerPipeThrough } from '@atproto/xrpc-server';
|
|
5
|
+
import express from 'express';
|
|
6
|
+
export interface QueryParams {
|
|
7
|
+
/** The handle to resolve. */
|
|
8
|
+
handle: string;
|
|
9
|
+
}
|
|
10
|
+
export type InputSchema = undefined;
|
|
11
|
+
export interface OutputSchema {
|
|
12
|
+
did: string;
|
|
13
|
+
[k: string]: unknown;
|
|
14
|
+
}
|
|
15
|
+
export type HandlerInput = undefined;
|
|
16
|
+
export interface HandlerSuccess {
|
|
17
|
+
encoding: 'application/json';
|
|
18
|
+
body: OutputSchema;
|
|
19
|
+
headers?: {
|
|
20
|
+
[key: string]: string;
|
|
21
|
+
};
|
|
22
|
+
}
|
|
23
|
+
export interface HandlerError {
|
|
24
|
+
status: number;
|
|
25
|
+
message?: string;
|
|
26
|
+
error?: 'HandleNotFound';
|
|
27
|
+
}
|
|
28
|
+
export type HandlerOutput = HandlerError | HandlerSuccess | HandlerPipeThrough;
|
|
29
|
+
export type HandlerReqCtx<HA extends HandlerAuth = never> = {
|
|
30
|
+
auth: HA;
|
|
31
|
+
params: QueryParams;
|
|
32
|
+
input: HandlerInput;
|
|
33
|
+
req: express.Request;
|
|
34
|
+
res: express.Response;
|
|
35
|
+
resetRouteRateLimits: () => Promise<void>;
|
|
36
|
+
};
|
|
37
|
+
export type Handler<HA extends HandlerAuth = never> = (ctx: HandlerReqCtx<HA>) => Promise<HandlerOutput> | HandlerOutput;
|
|
@@ -0,0 +1,35 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* GENERATED CODE - DO NOT MODIFY
|
|
3
|
+
*/
|
|
4
|
+
import { HandlerAuth, HandlerPipeThrough } from '@atproto/xrpc-server';
|
|
5
|
+
import express from 'express';
|
|
6
|
+
import * as ComAtprotoIdentityDefs from './defs';
|
|
7
|
+
export interface QueryParams {
|
|
8
|
+
/** Handle or DID to resolve. */
|
|
9
|
+
identifier: string;
|
|
10
|
+
}
|
|
11
|
+
export type InputSchema = undefined;
|
|
12
|
+
export type OutputSchema = ComAtprotoIdentityDefs.IdentityInfo;
|
|
13
|
+
export type HandlerInput = undefined;
|
|
14
|
+
export interface HandlerSuccess {
|
|
15
|
+
encoding: 'application/json';
|
|
16
|
+
body: OutputSchema;
|
|
17
|
+
headers?: {
|
|
18
|
+
[key: string]: string;
|
|
19
|
+
};
|
|
20
|
+
}
|
|
21
|
+
export interface HandlerError {
|
|
22
|
+
status: number;
|
|
23
|
+
message?: string;
|
|
24
|
+
error?: 'HandleNotFound' | 'DidNotFound' | 'DidDeactivated';
|
|
25
|
+
}
|
|
26
|
+
export type HandlerOutput = HandlerError | HandlerSuccess | HandlerPipeThrough;
|
|
27
|
+
export type HandlerReqCtx<HA extends HandlerAuth = never> = {
|
|
28
|
+
auth: HA;
|
|
29
|
+
params: QueryParams;
|
|
30
|
+
input: HandlerInput;
|
|
31
|
+
req: express.Request;
|
|
32
|
+
res: express.Response;
|
|
33
|
+
resetRouteRateLimits: () => Promise<void>;
|
|
34
|
+
};
|
|
35
|
+
export type Handler<HA extends HandlerAuth = never> = (ctx: HandlerReqCtx<HA>) => Promise<HandlerOutput> | HandlerOutput;
|
|
@@ -0,0 +1,46 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* GENERATED CODE - DO NOT MODIFY
|
|
3
|
+
*/
|
|
4
|
+
import { HandlerAuth, HandlerPipeThrough } from '@atproto/xrpc-server';
|
|
5
|
+
import express from 'express';
|
|
6
|
+
export interface QueryParams {
|
|
7
|
+
}
|
|
8
|
+
export interface InputSchema {
|
|
9
|
+
/** A token received through com.atproto.identity.requestPlcOperationSignature */
|
|
10
|
+
token?: string;
|
|
11
|
+
rotationKeys?: string[];
|
|
12
|
+
alsoKnownAs?: string[];
|
|
13
|
+
verificationMethods?: {};
|
|
14
|
+
services?: {};
|
|
15
|
+
[k: string]: unknown;
|
|
16
|
+
}
|
|
17
|
+
export interface OutputSchema {
|
|
18
|
+
/** A signed DID PLC operation. */
|
|
19
|
+
operation: {};
|
|
20
|
+
[k: string]: unknown;
|
|
21
|
+
}
|
|
22
|
+
export interface HandlerInput {
|
|
23
|
+
encoding: 'application/json';
|
|
24
|
+
body: InputSchema;
|
|
25
|
+
}
|
|
26
|
+
export interface HandlerSuccess {
|
|
27
|
+
encoding: 'application/json';
|
|
28
|
+
body: OutputSchema;
|
|
29
|
+
headers?: {
|
|
30
|
+
[key: string]: string;
|
|
31
|
+
};
|
|
32
|
+
}
|
|
33
|
+
export interface HandlerError {
|
|
34
|
+
status: number;
|
|
35
|
+
message?: string;
|
|
36
|
+
}
|
|
37
|
+
export type HandlerOutput = HandlerError | HandlerSuccess | HandlerPipeThrough;
|
|
38
|
+
export type HandlerReqCtx<HA extends HandlerAuth = never> = {
|
|
39
|
+
auth: HA;
|
|
40
|
+
params: QueryParams;
|
|
41
|
+
input: HandlerInput;
|
|
42
|
+
req: express.Request;
|
|
43
|
+
res: express.Response;
|
|
44
|
+
resetRouteRateLimits: () => Promise<void>;
|
|
45
|
+
};
|
|
46
|
+
export type Handler<HA extends HandlerAuth = never> = (ctx: HandlerReqCtx<HA>) => Promise<HandlerOutput> | HandlerOutput;
|
|
@@ -0,0 +1,29 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* GENERATED CODE - DO NOT MODIFY
|
|
3
|
+
*/
|
|
4
|
+
import { HandlerAuth } from '@atproto/xrpc-server';
|
|
5
|
+
import express from 'express';
|
|
6
|
+
export interface QueryParams {
|
|
7
|
+
}
|
|
8
|
+
export interface InputSchema {
|
|
9
|
+
operation: {};
|
|
10
|
+
[k: string]: unknown;
|
|
11
|
+
}
|
|
12
|
+
export interface HandlerInput {
|
|
13
|
+
encoding: 'application/json';
|
|
14
|
+
body: InputSchema;
|
|
15
|
+
}
|
|
16
|
+
export interface HandlerError {
|
|
17
|
+
status: number;
|
|
18
|
+
message?: string;
|
|
19
|
+
}
|
|
20
|
+
export type HandlerOutput = HandlerError | void;
|
|
21
|
+
export type HandlerReqCtx<HA extends HandlerAuth = never> = {
|
|
22
|
+
auth: HA;
|
|
23
|
+
params: QueryParams;
|
|
24
|
+
input: HandlerInput;
|
|
25
|
+
req: express.Request;
|
|
26
|
+
res: express.Response;
|
|
27
|
+
resetRouteRateLimits: () => Promise<void>;
|
|
28
|
+
};
|
|
29
|
+
export type Handler<HA extends HandlerAuth = never> = (ctx: HandlerReqCtx<HA>) => Promise<HandlerOutput> | HandlerOutput;
|
|
@@ -0,0 +1,30 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* GENERATED CODE - DO NOT MODIFY
|
|
3
|
+
*/
|
|
4
|
+
import { HandlerAuth } from '@atproto/xrpc-server';
|
|
5
|
+
import express from 'express';
|
|
6
|
+
export interface QueryParams {
|
|
7
|
+
}
|
|
8
|
+
export interface InputSchema {
|
|
9
|
+
/** The new handle. */
|
|
10
|
+
handle: string;
|
|
11
|
+
[k: string]: unknown;
|
|
12
|
+
}
|
|
13
|
+
export interface HandlerInput {
|
|
14
|
+
encoding: 'application/json';
|
|
15
|
+
body: InputSchema;
|
|
16
|
+
}
|
|
17
|
+
export interface HandlerError {
|
|
18
|
+
status: number;
|
|
19
|
+
message?: string;
|
|
20
|
+
}
|
|
21
|
+
export type HandlerOutput = HandlerError | void;
|
|
22
|
+
export type HandlerReqCtx<HA extends HandlerAuth = never> = {
|
|
23
|
+
auth: HA;
|
|
24
|
+
params: QueryParams;
|
|
25
|
+
input: HandlerInput;
|
|
26
|
+
req: express.Request;
|
|
27
|
+
res: express.Response;
|
|
28
|
+
resetRouteRateLimits: () => Promise<void>;
|
|
29
|
+
};
|
|
30
|
+
export type Handler<HA extends HandlerAuth = never> = (ctx: HandlerReqCtx<HA>) => Promise<HandlerOutput> | HandlerOutput;
|
|
@@ -0,0 +1,73 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* GENERATED CODE - DO NOT MODIFY
|
|
3
|
+
*/
|
|
4
|
+
import { ValidationResult } from '@atproto/lexicon';
|
|
5
|
+
/** Metadata tag on an atproto resource (eg, repo or record). */
|
|
6
|
+
export interface Label {
|
|
7
|
+
/** The AT Protocol version of the label object. */
|
|
8
|
+
ver?: number;
|
|
9
|
+
/** DID of the actor who created this label. */
|
|
10
|
+
src: string;
|
|
11
|
+
/** AT URI of the record, repository (account), or other resource that this label applies to. */
|
|
12
|
+
uri: string;
|
|
13
|
+
/** Optionally, CID specifying the specific version of 'uri' resource this label applies to. */
|
|
14
|
+
cid?: string;
|
|
15
|
+
/** The short string name of the value or type of this label. */
|
|
16
|
+
val: string;
|
|
17
|
+
/** If true, this is a negation label, overwriting a previous label. */
|
|
18
|
+
neg?: boolean;
|
|
19
|
+
/** Timestamp when this label was created. */
|
|
20
|
+
cts: string;
|
|
21
|
+
/** Timestamp at which this label expires (no longer applies). */
|
|
22
|
+
exp?: string;
|
|
23
|
+
/** Signature of dag-cbor encoded label. */
|
|
24
|
+
sig?: Uint8Array;
|
|
25
|
+
[k: string]: unknown;
|
|
26
|
+
}
|
|
27
|
+
export declare function isLabel(v: unknown): v is Label;
|
|
28
|
+
export declare function validateLabel(v: unknown): ValidationResult;
|
|
29
|
+
/** Metadata tags on an atproto record, published by the author within the record. */
|
|
30
|
+
export interface SelfLabels {
|
|
31
|
+
values: SelfLabel[];
|
|
32
|
+
[k: string]: unknown;
|
|
33
|
+
}
|
|
34
|
+
export declare function isSelfLabels(v: unknown): v is SelfLabels;
|
|
35
|
+
export declare function validateSelfLabels(v: unknown): ValidationResult;
|
|
36
|
+
/** Metadata tag on an atproto record, published by the author within the record. Note that schemas should use #selfLabels, not #selfLabel. */
|
|
37
|
+
export interface SelfLabel {
|
|
38
|
+
/** The short string name of the value or type of this label. */
|
|
39
|
+
val: string;
|
|
40
|
+
[k: string]: unknown;
|
|
41
|
+
}
|
|
42
|
+
export declare function isSelfLabel(v: unknown): v is SelfLabel;
|
|
43
|
+
export declare function validateSelfLabel(v: unknown): ValidationResult;
|
|
44
|
+
/** Declares a label value and its expected interpretations and behaviors. */
|
|
45
|
+
export interface LabelValueDefinition {
|
|
46
|
+
/** The value of the label being defined. Must only include lowercase ascii and the '-' character ([a-z-]+). */
|
|
47
|
+
identifier: string;
|
|
48
|
+
/** How should a client visually convey this label? 'inform' means neutral and informational; 'alert' means negative and warning; 'none' means show nothing. */
|
|
49
|
+
severity: 'inform' | 'alert' | 'none' | (string & {});
|
|
50
|
+
/** What should this label hide in the UI, if applied? 'content' hides all of the target; 'media' hides the images/video/audio; 'none' hides nothing. */
|
|
51
|
+
blurs: 'content' | 'media' | 'none' | (string & {});
|
|
52
|
+
/** The default setting for this label. */
|
|
53
|
+
defaultSetting: 'ignore' | 'warn' | 'hide' | (string & {});
|
|
54
|
+
/** Does the user need to have adult content enabled in order to configure this label? */
|
|
55
|
+
adultOnly?: boolean;
|
|
56
|
+
locales: LabelValueDefinitionStrings[];
|
|
57
|
+
[k: string]: unknown;
|
|
58
|
+
}
|
|
59
|
+
export declare function isLabelValueDefinition(v: unknown): v is LabelValueDefinition;
|
|
60
|
+
export declare function validateLabelValueDefinition(v: unknown): ValidationResult;
|
|
61
|
+
/** Strings which describe the label in the UI, localized into a specific language. */
|
|
62
|
+
export interface LabelValueDefinitionStrings {
|
|
63
|
+
/** The code of the language these strings are written in. */
|
|
64
|
+
lang: string;
|
|
65
|
+
/** A short human-readable name for the label. */
|
|
66
|
+
name: string;
|
|
67
|
+
/** A longer description of what the label means and why it might be applied. */
|
|
68
|
+
description: string;
|
|
69
|
+
[k: string]: unknown;
|
|
70
|
+
}
|
|
71
|
+
export declare function isLabelValueDefinitionStrings(v: unknown): v is LabelValueDefinitionStrings;
|
|
72
|
+
export declare function validateLabelValueDefinitionStrings(v: unknown): ValidationResult;
|
|
73
|
+
export type LabelValue = '!hide' | '!no-promote' | '!warn' | '!no-unauthenticated' | 'dmca-violation' | 'doxxing' | 'porn' | 'sexual' | 'nudity' | 'nsfl' | 'gore' | (string & {});
|
|
@@ -0,0 +1,54 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.isLabel = isLabel;
|
|
4
|
+
exports.validateLabel = validateLabel;
|
|
5
|
+
exports.isSelfLabels = isSelfLabels;
|
|
6
|
+
exports.validateSelfLabels = validateSelfLabels;
|
|
7
|
+
exports.isSelfLabel = isSelfLabel;
|
|
8
|
+
exports.validateSelfLabel = validateSelfLabel;
|
|
9
|
+
exports.isLabelValueDefinition = isLabelValueDefinition;
|
|
10
|
+
exports.validateLabelValueDefinition = validateLabelValueDefinition;
|
|
11
|
+
exports.isLabelValueDefinitionStrings = isLabelValueDefinitionStrings;
|
|
12
|
+
exports.validateLabelValueDefinitionStrings = validateLabelValueDefinitionStrings;
|
|
13
|
+
const lexicons_1 = require("../../../../lexicons");
|
|
14
|
+
const util_1 = require("../../../../util");
|
|
15
|
+
function isLabel(v) {
|
|
16
|
+
return ((0, util_1.isObj)(v) &&
|
|
17
|
+
(0, util_1.hasProp)(v, '$type') &&
|
|
18
|
+
v.$type === 'com.atproto.label.defs#label');
|
|
19
|
+
}
|
|
20
|
+
function validateLabel(v) {
|
|
21
|
+
return lexicons_1.lexicons.validate('com.atproto.label.defs#label', v);
|
|
22
|
+
}
|
|
23
|
+
function isSelfLabels(v) {
|
|
24
|
+
return ((0, util_1.isObj)(v) &&
|
|
25
|
+
(0, util_1.hasProp)(v, '$type') &&
|
|
26
|
+
v.$type === 'com.atproto.label.defs#selfLabels');
|
|
27
|
+
}
|
|
28
|
+
function validateSelfLabels(v) {
|
|
29
|
+
return lexicons_1.lexicons.validate('com.atproto.label.defs#selfLabels', v);
|
|
30
|
+
}
|
|
31
|
+
function isSelfLabel(v) {
|
|
32
|
+
return ((0, util_1.isObj)(v) &&
|
|
33
|
+
(0, util_1.hasProp)(v, '$type') &&
|
|
34
|
+
v.$type === 'com.atproto.label.defs#selfLabel');
|
|
35
|
+
}
|
|
36
|
+
function validateSelfLabel(v) {
|
|
37
|
+
return lexicons_1.lexicons.validate('com.atproto.label.defs#selfLabel', v);
|
|
38
|
+
}
|
|
39
|
+
function isLabelValueDefinition(v) {
|
|
40
|
+
return ((0, util_1.isObj)(v) &&
|
|
41
|
+
(0, util_1.hasProp)(v, '$type') &&
|
|
42
|
+
v.$type === 'com.atproto.label.defs#labelValueDefinition');
|
|
43
|
+
}
|
|
44
|
+
function validateLabelValueDefinition(v) {
|
|
45
|
+
return lexicons_1.lexicons.validate('com.atproto.label.defs#labelValueDefinition', v);
|
|
46
|
+
}
|
|
47
|
+
function isLabelValueDefinitionStrings(v) {
|
|
48
|
+
return ((0, util_1.isObj)(v) &&
|
|
49
|
+
(0, util_1.hasProp)(v, '$type') &&
|
|
50
|
+
v.$type === 'com.atproto.label.defs#labelValueDefinitionStrings');
|
|
51
|
+
}
|
|
52
|
+
function validateLabelValueDefinitionStrings(v) {
|
|
53
|
+
return lexicons_1.lexicons.validate('com.atproto.label.defs#labelValueDefinitionStrings', v);
|
|
54
|
+
}
|
|
@@ -0,0 +1,42 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* GENERATED CODE - DO NOT MODIFY
|
|
3
|
+
*/
|
|
4
|
+
import { HandlerAuth, HandlerPipeThrough } from '@atproto/xrpc-server';
|
|
5
|
+
import express from 'express';
|
|
6
|
+
import * as ComAtprotoLabelDefs from './defs';
|
|
7
|
+
export interface QueryParams {
|
|
8
|
+
/** List of AT URI patterns to match (boolean 'OR'). Each may be a prefix (ending with '*'; will match inclusive of the string leading to '*'), or a full URI. */
|
|
9
|
+
uriPatterns: string[];
|
|
10
|
+
/** Optional list of label sources (DIDs) to filter on. */
|
|
11
|
+
sources?: string[];
|
|
12
|
+
limit: number;
|
|
13
|
+
cursor?: string;
|
|
14
|
+
}
|
|
15
|
+
export type InputSchema = undefined;
|
|
16
|
+
export interface OutputSchema {
|
|
17
|
+
cursor?: string;
|
|
18
|
+
labels: ComAtprotoLabelDefs.Label[];
|
|
19
|
+
[k: string]: unknown;
|
|
20
|
+
}
|
|
21
|
+
export type HandlerInput = undefined;
|
|
22
|
+
export interface HandlerSuccess {
|
|
23
|
+
encoding: 'application/json';
|
|
24
|
+
body: OutputSchema;
|
|
25
|
+
headers?: {
|
|
26
|
+
[key: string]: string;
|
|
27
|
+
};
|
|
28
|
+
}
|
|
29
|
+
export interface HandlerError {
|
|
30
|
+
status: number;
|
|
31
|
+
message?: string;
|
|
32
|
+
}
|
|
33
|
+
export type HandlerOutput = HandlerError | HandlerSuccess | HandlerPipeThrough;
|
|
34
|
+
export type HandlerReqCtx<HA extends HandlerAuth = never> = {
|
|
35
|
+
auth: HA;
|
|
36
|
+
params: QueryParams;
|
|
37
|
+
input: HandlerInput;
|
|
38
|
+
req: express.Request;
|
|
39
|
+
res: express.Response;
|
|
40
|
+
resetRouteRateLimits: () => Promise<void>;
|
|
41
|
+
};
|
|
42
|
+
export type Handler<HA extends HandlerAuth = never> = (ctx: HandlerReqCtx<HA>) => Promise<HandlerOutput> | HandlerOutput;
|
|
@@ -0,0 +1,38 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* GENERATED CODE - DO NOT MODIFY
|
|
3
|
+
*/
|
|
4
|
+
import { ValidationResult } from '@atproto/lexicon';
|
|
5
|
+
import { ErrorFrame, HandlerAuth } from '@atproto/xrpc-server';
|
|
6
|
+
import { IncomingMessage } from 'http';
|
|
7
|
+
import * as ComAtprotoLabelDefs from './defs';
|
|
8
|
+
export interface QueryParams {
|
|
9
|
+
/** The last known event seq number to backfill from. */
|
|
10
|
+
cursor?: number;
|
|
11
|
+
}
|
|
12
|
+
export type OutputSchema = Labels | Info | {
|
|
13
|
+
$type: string;
|
|
14
|
+
[k: string]: unknown;
|
|
15
|
+
};
|
|
16
|
+
export type HandlerError = ErrorFrame<'FutureCursor'>;
|
|
17
|
+
export type HandlerOutput = HandlerError | OutputSchema;
|
|
18
|
+
export type HandlerReqCtx<HA extends HandlerAuth = never> = {
|
|
19
|
+
auth: HA;
|
|
20
|
+
params: QueryParams;
|
|
21
|
+
req: IncomingMessage;
|
|
22
|
+
signal: AbortSignal;
|
|
23
|
+
};
|
|
24
|
+
export type Handler<HA extends HandlerAuth = never> = (ctx: HandlerReqCtx<HA>) => AsyncIterable<HandlerOutput>;
|
|
25
|
+
export interface Labels {
|
|
26
|
+
seq: number;
|
|
27
|
+
labels: ComAtprotoLabelDefs.Label[];
|
|
28
|
+
[k: string]: unknown;
|
|
29
|
+
}
|
|
30
|
+
export declare function isLabels(v: unknown): v is Labels;
|
|
31
|
+
export declare function validateLabels(v: unknown): ValidationResult;
|
|
32
|
+
export interface Info {
|
|
33
|
+
name: 'OutdatedCursor' | (string & {});
|
|
34
|
+
message?: string;
|
|
35
|
+
[k: string]: unknown;
|
|
36
|
+
}
|
|
37
|
+
export declare function isInfo(v: unknown): v is Info;
|
|
38
|
+
export declare function validateInfo(v: unknown): ValidationResult;
|
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.isLabels = isLabels;
|
|
4
|
+
exports.validateLabels = validateLabels;
|
|
5
|
+
exports.isInfo = isInfo;
|
|
6
|
+
exports.validateInfo = validateInfo;
|
|
7
|
+
const lexicons_1 = require("../../../../lexicons");
|
|
8
|
+
const util_1 = require("../../../../util");
|
|
9
|
+
function isLabels(v) {
|
|
10
|
+
return ((0, util_1.isObj)(v) &&
|
|
11
|
+
(0, util_1.hasProp)(v, '$type') &&
|
|
12
|
+
v.$type === 'com.atproto.label.subscribeLabels#labels');
|
|
13
|
+
}
|
|
14
|
+
function validateLabels(v) {
|
|
15
|
+
return lexicons_1.lexicons.validate('com.atproto.label.subscribeLabels#labels', v);
|
|
16
|
+
}
|
|
17
|
+
function isInfo(v) {
|
|
18
|
+
return ((0, util_1.isObj)(v) &&
|
|
19
|
+
(0, util_1.hasProp)(v, '$type') &&
|
|
20
|
+
v.$type === 'com.atproto.label.subscribeLabels#info');
|
|
21
|
+
}
|
|
22
|
+
function validateInfo(v) {
|
|
23
|
+
return lexicons_1.lexicons.validate('com.atproto.label.subscribeLabels#info', v);
|
|
24
|
+
}
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* GENERATED CODE - DO NOT MODIFY
|
|
3
|
+
*/
|
|
4
|
+
import { ValidationResult } from '@atproto/lexicon';
|
|
5
|
+
export interface Record {
|
|
6
|
+
/** Indicates the 'version' of the Lexicon language. Must be '1' for the current atproto/Lexicon schema system. */
|
|
7
|
+
lexicon: number;
|
|
8
|
+
[k: string]: unknown;
|
|
9
|
+
}
|
|
10
|
+
export declare function isRecord(v: unknown): v is Record;
|
|
11
|
+
export declare function validateRecord(v: unknown): ValidationResult;
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.isRecord = isRecord;
|
|
4
|
+
exports.validateRecord = validateRecord;
|
|
5
|
+
const lexicons_1 = require("../../../../lexicons");
|
|
6
|
+
const util_1 = require("../../../../util");
|
|
7
|
+
function isRecord(v) {
|
|
8
|
+
return ((0, util_1.isObj)(v) &&
|
|
9
|
+
(0, util_1.hasProp)(v, '$type') &&
|
|
10
|
+
(v.$type === 'com.atproto.lexicon.schema#main' ||
|
|
11
|
+
v.$type === 'com.atproto.lexicon.schema'));
|
|
12
|
+
}
|
|
13
|
+
function validateRecord(v) {
|
|
14
|
+
return lexicons_1.lexicons.validate('com.atproto.lexicon.schema#main', v);
|
|
15
|
+
}
|