···11+FROM denoland/deno:2.2.3 AS builder
22+33+WORKDIR /app
44+55+COPY . .
66+77+# Give ownership to deno user and cache dependencies
88+RUN chown -R deno:deno /app && \
99+ deno cache ./main.tsx
1010+1111+FROM denoland/deno:alpine-2.2.3
1212+1313+COPY --from=flyio/litefs:0.5 /usr/local/bin/litefs /usr/local/bin/litefs
1414+COPY litefs.yml /etc/litefs.yml
1515+1616+# libstdc++ is needed for @gfx/canvas
1717+RUN apk add --no-cache ca-certificates fuse3 libstdc++ sqlite
1818+1919+WORKDIR /app
2020+2121+# Needed for @gfx/canvas
2222+RUN mkdir -p /usr/share/fonts
2323+2424+COPY --from=builder $DENO_DIR $DENO_DIR
2525+COPY --from=builder /app .
2626+2727+# Run LiteFS as the entrypoint. After it has connected and sync'd with the
2828+# cluster, it will run the commands listed in the "exec" field of the config.
2929+ENTRYPOINT ["litefs", "mount"]
+211
__generated__/index.ts
···11+/**
22+ * GENERATED CODE - DO NOT MODIFY
33+ */
44+import {
55+ createServer as createXrpcServer,
66+ Server as XrpcServer,
77+ type Options as XrpcOptions,
88+ type AuthVerifier,
99+ type StreamAuthVerifier,
1010+} from "npm:@atproto/xrpc-server"
1111+import { schemas } from './lexicons.ts'
1212+1313+export const APP_BSKY_GRAPH = {
1414+ DefsModlist: 'app.bsky.graph.defs#modlist',
1515+ DefsCuratelist: 'app.bsky.graph.defs#curatelist',
1616+ DefsReferencelist: 'app.bsky.graph.defs#referencelist',
1717+}
1818+export const APP_BSKY_FEED = {
1919+ DefsRequestLess: 'app.bsky.feed.defs#requestLess',
2020+ DefsRequestMore: 'app.bsky.feed.defs#requestMore',
2121+ DefsInteractionLike: 'app.bsky.feed.defs#interactionLike',
2222+ DefsInteractionSeen: 'app.bsky.feed.defs#interactionSeen',
2323+ DefsClickthroughItem: 'app.bsky.feed.defs#clickthroughItem',
2424+ DefsContentModeVideo: 'app.bsky.feed.defs#contentModeVideo',
2525+ DefsInteractionQuote: 'app.bsky.feed.defs#interactionQuote',
2626+ DefsInteractionReply: 'app.bsky.feed.defs#interactionReply',
2727+ DefsInteractionShare: 'app.bsky.feed.defs#interactionShare',
2828+ DefsClickthroughEmbed: 'app.bsky.feed.defs#clickthroughEmbed',
2929+ DefsInteractionRepost: 'app.bsky.feed.defs#interactionRepost',
3030+ DefsClickthroughAuthor: 'app.bsky.feed.defs#clickthroughAuthor',
3131+ DefsClickthroughReposter: 'app.bsky.feed.defs#clickthroughReposter',
3232+ DefsContentModeUnspecified: 'app.bsky.feed.defs#contentModeUnspecified',
3333+}
3434+3535+export function createServer(options?: XrpcOptions): Server {
3636+ return new Server(options)
3737+}
3838+3939+export class Server {
4040+ xrpc: XrpcServer
4141+ app: AppNS
4242+ social: SocialNS
4343+ com: ComNS
4444+4545+ constructor(options?: XrpcOptions) {
4646+ this.xrpc = createXrpcServer(schemas, options)
4747+ this.app = new AppNS(this)
4848+ this.social = new SocialNS(this)
4949+ this.com = new ComNS(this)
5050+ }
5151+}
5252+5353+export class AppNS {
5454+ _server: Server
5555+ bsky: AppBskyNS
5656+5757+ constructor(server: Server) {
5858+ this._server = server
5959+ this.bsky = new AppBskyNS(server)
6060+ }
6161+}
6262+6363+export class AppBskyNS {
6464+ _server: Server
6565+ embed: AppBskyEmbedNS
6666+ feed: AppBskyFeedNS
6767+ richtext: AppBskyRichtextNS
6868+ actor: AppBskyActorNS
6969+7070+ constructor(server: Server) {
7171+ this._server = server
7272+ this.embed = new AppBskyEmbedNS(server)
7373+ this.feed = new AppBskyFeedNS(server)
7474+ this.richtext = new AppBskyRichtextNS(server)
7575+ this.actor = new AppBskyActorNS(server)
7676+ }
7777+}
7878+7979+export class AppBskyEmbedNS {
8080+ _server: Server
8181+8282+ constructor(server: Server) {
8383+ this._server = server
8484+ }
8585+}
8686+8787+export class AppBskyFeedNS {
8888+ _server: Server
8989+9090+ constructor(server: Server) {
9191+ this._server = server
9292+ }
9393+}
9494+9595+export class AppBskyRichtextNS {
9696+ _server: Server
9797+9898+ constructor(server: Server) {
9999+ this._server = server
100100+ }
101101+}
102102+103103+export class AppBskyActorNS {
104104+ _server: Server
105105+106106+ constructor(server: Server) {
107107+ this._server = server
108108+ }
109109+}
110110+111111+export class SocialNS {
112112+ _server: Server
113113+ grain: SocialGrainNS
114114+115115+ constructor(server: Server) {
116116+ this._server = server
117117+ this.grain = new SocialGrainNS(server)
118118+ }
119119+}
120120+121121+export class SocialGrainNS {
122122+ _server: Server
123123+ v0: SocialGrainV0NS
124124+125125+ constructor(server: Server) {
126126+ this._server = server
127127+ this.v0 = new SocialGrainV0NS(server)
128128+ }
129129+}
130130+131131+export class SocialGrainV0NS {
132132+ _server: Server
133133+ gallery: SocialGrainV0GalleryNS
134134+ actor: SocialGrainV0ActorNS
135135+136136+ constructor(server: Server) {
137137+ this._server = server
138138+ this.gallery = new SocialGrainV0GalleryNS(server)
139139+ this.actor = new SocialGrainV0ActorNS(server)
140140+ }
141141+}
142142+143143+export class SocialGrainV0GalleryNS {
144144+ _server: Server
145145+146146+ constructor(server: Server) {
147147+ this._server = server
148148+ }
149149+}
150150+151151+export class SocialGrainV0ActorNS {
152152+ _server: Server
153153+154154+ constructor(server: Server) {
155155+ this._server = server
156156+ }
157157+}
158158+159159+export class ComNS {
160160+ _server: Server
161161+ atproto: ComAtprotoNS
162162+163163+ constructor(server: Server) {
164164+ this._server = server
165165+ this.atproto = new ComAtprotoNS(server)
166166+ }
167167+}
168168+169169+export class ComAtprotoNS {
170170+ _server: Server
171171+ repo: ComAtprotoRepoNS
172172+173173+ constructor(server: Server) {
174174+ this._server = server
175175+ this.repo = new ComAtprotoRepoNS(server)
176176+ }
177177+}
178178+179179+export class ComAtprotoRepoNS {
180180+ _server: Server
181181+182182+ constructor(server: Server) {
183183+ this._server = server
184184+ }
185185+}
186186+187187+type SharedRateLimitOpts<T> = {
188188+ name: string
189189+ calcKey?: (ctx: T) => string | null
190190+ calcPoints?: (ctx: T) => number
191191+}
192192+type RouteRateLimitOpts<T> = {
193193+ durationMs: number
194194+ points: number
195195+ calcKey?: (ctx: T) => string | null
196196+ calcPoints?: (ctx: T) => number
197197+}
198198+type HandlerOpts = { blobLimit?: number }
199199+type HandlerRateLimitOpts<T> = SharedRateLimitOpts<T> | RouteRateLimitOpts<T>
200200+type ConfigOf<Auth, Handler, ReqCtx> =
201201+ | Handler
202202+ | {
203203+ auth?: Auth
204204+ opts?: HandlerOpts
205205+ rateLimit?: HandlerRateLimitOpts<ReqCtx> | HandlerRateLimitOpts<ReqCtx>[]
206206+ handler: Handler
207207+ }
208208+type ExtractAuth<AV extends AuthVerifier | StreamAuthVerifier> = Extract<
209209+ Awaited<ReturnType<AV>>,
210210+ { credentials: unknown }
211211+>
···11+/**
22+ * GENERATED CODE - DO NOT MODIFY
33+ */
44+import { type ValidationResult, BlobRef } from "npm:@atproto/lexicon"
55+import { CID } from "npm:multiformats/cid"
66+import { validate as _validate } from '../../../../lexicons.ts'
77+import {
88+ type $Typed,
99+ is$typed as _is$typed,
1010+ type OmitKey,
1111+} from '../../../../util.ts'
1212+import type * as ComAtprotoLabelDefs from '../../../com/atproto/label/defs.ts'
1313+import type * as AppBskyGraphDefs from '../graph/defs.ts'
1414+import type * as ComAtprotoRepoStrongRef from '../../../com/atproto/repo/strongRef.ts'
1515+import type * as AppBskyFeedThreadgate from '../feed/threadgate.ts'
1616+import type * as AppBskyFeedPostgate from '../feed/postgate.ts'
1717+1818+const is$typed = _is$typed,
1919+ validate = _validate
2020+const id = 'app.bsky.actor.defs'
2121+2222+/** A new user experiences (NUX) storage object */
2323+export interface Nux {
2424+ $type?: 'app.bsky.actor.defs#nux'
2525+ id: string
2626+ /** Arbitrary data for the NUX. The structure is defined by the NUX itself. Limited to 300 characters. */
2727+ data?: string
2828+ completed: boolean
2929+ /** The date and time at which the NUX will expire and should be considered completed. */
3030+ expiresAt?: string
3131+}
3232+3333+const hashNux = 'nux'
3434+3535+export function isNux<V>(v: V) {
3636+ return is$typed(v, id, hashNux)
3737+}
3838+3939+export function validateNux<V>(v: V) {
4040+ return validate<Nux & V>(v, id, hashNux)
4141+}
4242+4343+/** A word that the account owner has muted. */
4444+export interface MutedWord {
4545+ $type?: 'app.bsky.actor.defs#mutedWord'
4646+ id?: string
4747+ /** The muted word itself. */
4848+ value: string
4949+ /** The intended targets of the muted word. */
5050+ targets: MutedWordTarget[]
5151+ /** The date and time at which the muted word will expire and no longer be applied. */
5252+ expiresAt?: string
5353+ /** Groups of users to apply the muted word to. If undefined, applies to all users. */
5454+ actorTarget: 'all' | 'exclude-following' | (string & {})
5555+}
5656+5757+const hashMutedWord = 'mutedWord'
5858+5959+export function isMutedWord<V>(v: V) {
6060+ return is$typed(v, id, hashMutedWord)
6161+}
6262+6363+export function validateMutedWord<V>(v: V) {
6464+ return validate<MutedWord & V>(v, id, hashMutedWord)
6565+}
6666+6767+export interface SavedFeed {
6868+ $type?: 'app.bsky.actor.defs#savedFeed'
6969+ id: string
7070+ type: 'feed' | 'list' | 'timeline' | (string & {})
7171+ value: string
7272+ pinned: boolean
7373+}
7474+7575+const hashSavedFeed = 'savedFeed'
7676+7777+export function isSavedFeed<V>(v: V) {
7878+ return is$typed(v, id, hashSavedFeed)
7979+}
8080+8181+export function validateSavedFeed<V>(v: V) {
8282+ return validate<SavedFeed & V>(v, id, hashSavedFeed)
8383+}
8484+8585+export type Preferences = (
8686+ | $Typed<AdultContentPref>
8787+ | $Typed<ContentLabelPref>
8888+ | $Typed<SavedFeedsPref>
8989+ | $Typed<SavedFeedsPrefV2>
9090+ | $Typed<PersonalDetailsPref>
9191+ | $Typed<FeedViewPref>
9292+ | $Typed<ThreadViewPref>
9393+ | $Typed<InterestsPref>
9494+ | $Typed<MutedWordsPref>
9595+ | $Typed<HiddenPostsPref>
9696+ | $Typed<BskyAppStatePref>
9797+ | $Typed<LabelersPref>
9898+ | $Typed<PostInteractionSettingsPref>
9999+ | { $type: string }
100100+)[]
101101+102102+export interface ProfileView {
103103+ $type?: 'app.bsky.actor.defs#profileView'
104104+ did: string
105105+ avatar?: string
106106+ handle: string
107107+ labels?: ComAtprotoLabelDefs.Label[]
108108+ viewer?: ViewerState
109109+ createdAt?: string
110110+ indexedAt?: string
111111+ associated?: ProfileAssociated
112112+ description?: string
113113+ displayName?: string
114114+}
115115+116116+const hashProfileView = 'profileView'
117117+118118+export function isProfileView<V>(v: V) {
119119+ return is$typed(v, id, hashProfileView)
120120+}
121121+122122+export function validateProfileView<V>(v: V) {
123123+ return validate<ProfileView & V>(v, id, hashProfileView)
124124+}
125125+126126+/** Metadata about the requesting account's relationship with the subject account. Only has meaningful content for authed requests. */
127127+export interface ViewerState {
128128+ $type?: 'app.bsky.actor.defs#viewerState'
129129+ muted?: boolean
130130+ blocking?: string
131131+ blockedBy?: boolean
132132+ following?: string
133133+ followedBy?: string
134134+ mutedByList?: AppBskyGraphDefs.ListViewBasic
135135+ blockingByList?: AppBskyGraphDefs.ListViewBasic
136136+ knownFollowers?: KnownFollowers
137137+}
138138+139139+const hashViewerState = 'viewerState'
140140+141141+export function isViewerState<V>(v: V) {
142142+ return is$typed(v, id, hashViewerState)
143143+}
144144+145145+export function validateViewerState<V>(v: V) {
146146+ return validate<ViewerState & V>(v, id, hashViewerState)
147147+}
148148+149149+export interface FeedViewPref {
150150+ $type?: 'app.bsky.actor.defs#feedViewPref'
151151+ /** The URI of the feed, or an identifier which describes the feed. */
152152+ feed: string
153153+ /** Hide replies in the feed. */
154154+ hideReplies?: boolean
155155+ /** Hide reposts in the feed. */
156156+ hideReposts?: boolean
157157+ /** Hide quote posts in the feed. */
158158+ hideQuotePosts?: boolean
159159+ /** Hide replies in the feed if they do not have this number of likes. */
160160+ hideRepliesByLikeCount?: number
161161+ /** Hide replies in the feed if they are not by followed users. */
162162+ hideRepliesByUnfollowed: boolean
163163+}
164164+165165+const hashFeedViewPref = 'feedViewPref'
166166+167167+export function isFeedViewPref<V>(v: V) {
168168+ return is$typed(v, id, hashFeedViewPref)
169169+}
170170+171171+export function validateFeedViewPref<V>(v: V) {
172172+ return validate<FeedViewPref & V>(v, id, hashFeedViewPref)
173173+}
174174+175175+export interface LabelersPref {
176176+ $type?: 'app.bsky.actor.defs#labelersPref'
177177+ labelers: LabelerPrefItem[]
178178+}
179179+180180+const hashLabelersPref = 'labelersPref'
181181+182182+export function isLabelersPref<V>(v: V) {
183183+ return is$typed(v, id, hashLabelersPref)
184184+}
185185+186186+export function validateLabelersPref<V>(v: V) {
187187+ return validate<LabelersPref & V>(v, id, hashLabelersPref)
188188+}
189189+190190+export interface InterestsPref {
191191+ $type?: 'app.bsky.actor.defs#interestsPref'
192192+ /** A list of tags which describe the account owner's interests gathered during onboarding. */
193193+ tags: string[]
194194+}
195195+196196+const hashInterestsPref = 'interestsPref'
197197+198198+export function isInterestsPref<V>(v: V) {
199199+ return is$typed(v, id, hashInterestsPref)
200200+}
201201+202202+export function validateInterestsPref<V>(v: V) {
203203+ return validate<InterestsPref & V>(v, id, hashInterestsPref)
204204+}
205205+206206+/** The subject's followers whom you also follow */
207207+export interface KnownFollowers {
208208+ $type?: 'app.bsky.actor.defs#knownFollowers'
209209+ count: number
210210+ followers: ProfileViewBasic[]
211211+}
212212+213213+const hashKnownFollowers = 'knownFollowers'
214214+215215+export function isKnownFollowers<V>(v: V) {
216216+ return is$typed(v, id, hashKnownFollowers)
217217+}
218218+219219+export function validateKnownFollowers<V>(v: V) {
220220+ return validate<KnownFollowers & V>(v, id, hashKnownFollowers)
221221+}
222222+223223+export interface MutedWordsPref {
224224+ $type?: 'app.bsky.actor.defs#mutedWordsPref'
225225+ /** A list of words the account owner has muted. */
226226+ items: MutedWord[]
227227+}
228228+229229+const hashMutedWordsPref = 'mutedWordsPref'
230230+231231+export function isMutedWordsPref<V>(v: V) {
232232+ return is$typed(v, id, hashMutedWordsPref)
233233+}
234234+235235+export function validateMutedWordsPref<V>(v: V) {
236236+ return validate<MutedWordsPref & V>(v, id, hashMutedWordsPref)
237237+}
238238+239239+export interface SavedFeedsPref {
240240+ $type?: 'app.bsky.actor.defs#savedFeedsPref'
241241+ saved: string[]
242242+ pinned: string[]
243243+ timelineIndex?: number
244244+}
245245+246246+const hashSavedFeedsPref = 'savedFeedsPref'
247247+248248+export function isSavedFeedsPref<V>(v: V) {
249249+ return is$typed(v, id, hashSavedFeedsPref)
250250+}
251251+252252+export function validateSavedFeedsPref<V>(v: V) {
253253+ return validate<SavedFeedsPref & V>(v, id, hashSavedFeedsPref)
254254+}
255255+256256+export interface ThreadViewPref {
257257+ $type?: 'app.bsky.actor.defs#threadViewPref'
258258+ /** Sorting mode for threads. */
259259+ sort?:
260260+ | 'oldest'
261261+ | 'newest'
262262+ | 'most-likes'
263263+ | 'random'
264264+ | 'hotness'
265265+ | (string & {})
266266+ /** Show followed users at the top of all replies. */
267267+ prioritizeFollowedUsers?: boolean
268268+}
269269+270270+const hashThreadViewPref = 'threadViewPref'
271271+272272+export function isThreadViewPref<V>(v: V) {
273273+ return is$typed(v, id, hashThreadViewPref)
274274+}
275275+276276+export function validateThreadViewPref<V>(v: V) {
277277+ return validate<ThreadViewPref & V>(v, id, hashThreadViewPref)
278278+}
279279+280280+export interface HiddenPostsPref {
281281+ $type?: 'app.bsky.actor.defs#hiddenPostsPref'
282282+ /** A list of URIs of posts the account owner has hidden. */
283283+ items: string[]
284284+}
285285+286286+const hashHiddenPostsPref = 'hiddenPostsPref'
287287+288288+export function isHiddenPostsPref<V>(v: V) {
289289+ return is$typed(v, id, hashHiddenPostsPref)
290290+}
291291+292292+export function validateHiddenPostsPref<V>(v: V) {
293293+ return validate<HiddenPostsPref & V>(v, id, hashHiddenPostsPref)
294294+}
295295+296296+export interface LabelerPrefItem {
297297+ $type?: 'app.bsky.actor.defs#labelerPrefItem'
298298+ did: string
299299+}
300300+301301+const hashLabelerPrefItem = 'labelerPrefItem'
302302+303303+export function isLabelerPrefItem<V>(v: V) {
304304+ return is$typed(v, id, hashLabelerPrefItem)
305305+}
306306+307307+export function validateLabelerPrefItem<V>(v: V) {
308308+ return validate<LabelerPrefItem & V>(v, id, hashLabelerPrefItem)
309309+}
310310+311311+export type MutedWordTarget = 'content' | 'tag' | (string & {})
312312+313313+export interface AdultContentPref {
314314+ $type?: 'app.bsky.actor.defs#adultContentPref'
315315+ enabled: boolean
316316+}
317317+318318+const hashAdultContentPref = 'adultContentPref'
319319+320320+export function isAdultContentPref<V>(v: V) {
321321+ return is$typed(v, id, hashAdultContentPref)
322322+}
323323+324324+export function validateAdultContentPref<V>(v: V) {
325325+ return validate<AdultContentPref & V>(v, id, hashAdultContentPref)
326326+}
327327+328328+/** A grab bag of state that's specific to the bsky.app program. Third-party apps shouldn't use this. */
329329+export interface BskyAppStatePref {
330330+ $type?: 'app.bsky.actor.defs#bskyAppStatePref'
331331+ /** Storage for NUXs the user has encountered. */
332332+ nuxs?: Nux[]
333333+ /** An array of tokens which identify nudges (modals, popups, tours, highlight dots) that should be shown to the user. */
334334+ queuedNudges?: string[]
335335+ activeProgressGuide?: BskyAppProgressGuide
336336+}
337337+338338+const hashBskyAppStatePref = 'bskyAppStatePref'
339339+340340+export function isBskyAppStatePref<V>(v: V) {
341341+ return is$typed(v, id, hashBskyAppStatePref)
342342+}
343343+344344+export function validateBskyAppStatePref<V>(v: V) {
345345+ return validate<BskyAppStatePref & V>(v, id, hashBskyAppStatePref)
346346+}
347347+348348+export interface ContentLabelPref {
349349+ $type?: 'app.bsky.actor.defs#contentLabelPref'
350350+ label: string
351351+ /** Which labeler does this preference apply to? If undefined, applies globally. */
352352+ labelerDid?: string
353353+ visibility: 'ignore' | 'show' | 'warn' | 'hide' | (string & {})
354354+}
355355+356356+const hashContentLabelPref = 'contentLabelPref'
357357+358358+export function isContentLabelPref<V>(v: V) {
359359+ return is$typed(v, id, hashContentLabelPref)
360360+}
361361+362362+export function validateContentLabelPref<V>(v: V) {
363363+ return validate<ContentLabelPref & V>(v, id, hashContentLabelPref)
364364+}
365365+366366+export interface ProfileViewBasic {
367367+ $type?: 'app.bsky.actor.defs#profileViewBasic'
368368+ did: string
369369+ avatar?: string
370370+ handle: string
371371+ labels?: ComAtprotoLabelDefs.Label[]
372372+ viewer?: ViewerState
373373+ createdAt?: string
374374+ associated?: ProfileAssociated
375375+ displayName?: string
376376+}
377377+378378+const hashProfileViewBasic = 'profileViewBasic'
379379+380380+export function isProfileViewBasic<V>(v: V) {
381381+ return is$typed(v, id, hashProfileViewBasic)
382382+}
383383+384384+export function validateProfileViewBasic<V>(v: V) {
385385+ return validate<ProfileViewBasic & V>(v, id, hashProfileViewBasic)
386386+}
387387+388388+export interface SavedFeedsPrefV2 {
389389+ $type?: 'app.bsky.actor.defs#savedFeedsPrefV2'
390390+ items: SavedFeed[]
391391+}
392392+393393+const hashSavedFeedsPrefV2 = 'savedFeedsPrefV2'
394394+395395+export function isSavedFeedsPrefV2<V>(v: V) {
396396+ return is$typed(v, id, hashSavedFeedsPrefV2)
397397+}
398398+399399+export function validateSavedFeedsPrefV2<V>(v: V) {
400400+ return validate<SavedFeedsPrefV2 & V>(v, id, hashSavedFeedsPrefV2)
401401+}
402402+403403+export interface ProfileAssociated {
404404+ $type?: 'app.bsky.actor.defs#profileAssociated'
405405+ chat?: ProfileAssociatedChat
406406+ lists?: number
407407+ labeler?: boolean
408408+ feedgens?: number
409409+ starterPacks?: number
410410+}
411411+412412+const hashProfileAssociated = 'profileAssociated'
413413+414414+export function isProfileAssociated<V>(v: V) {
415415+ return is$typed(v, id, hashProfileAssociated)
416416+}
417417+418418+export function validateProfileAssociated<V>(v: V) {
419419+ return validate<ProfileAssociated & V>(v, id, hashProfileAssociated)
420420+}
421421+422422+export interface PersonalDetailsPref {
423423+ $type?: 'app.bsky.actor.defs#personalDetailsPref'
424424+ /** The birth date of account owner. */
425425+ birthDate?: string
426426+}
427427+428428+const hashPersonalDetailsPref = 'personalDetailsPref'
429429+430430+export function isPersonalDetailsPref<V>(v: V) {
431431+ return is$typed(v, id, hashPersonalDetailsPref)
432432+}
433433+434434+export function validatePersonalDetailsPref<V>(v: V) {
435435+ return validate<PersonalDetailsPref & V>(v, id, hashPersonalDetailsPref)
436436+}
437437+438438+export interface ProfileViewDetailed {
439439+ $type?: 'app.bsky.actor.defs#profileViewDetailed'
440440+ did: string
441441+ avatar?: string
442442+ banner?: string
443443+ handle: string
444444+ labels?: ComAtprotoLabelDefs.Label[]
445445+ viewer?: ViewerState
446446+ createdAt?: string
447447+ indexedAt?: string
448448+ associated?: ProfileAssociated
449449+ pinnedPost?: ComAtprotoRepoStrongRef.Main
450450+ postsCount?: number
451451+ description?: string
452452+ displayName?: string
453453+ followsCount?: number
454454+ followersCount?: number
455455+ joinedViaStarterPack?: AppBskyGraphDefs.StarterPackViewBasic
456456+}
457457+458458+const hashProfileViewDetailed = 'profileViewDetailed'
459459+460460+export function isProfileViewDetailed<V>(v: V) {
461461+ return is$typed(v, id, hashProfileViewDetailed)
462462+}
463463+464464+export function validateProfileViewDetailed<V>(v: V) {
465465+ return validate<ProfileViewDetailed & V>(v, id, hashProfileViewDetailed)
466466+}
467467+468468+/** If set, an active progress guide. Once completed, can be set to undefined. Should have unspecced fields tracking progress. */
469469+export interface BskyAppProgressGuide {
470470+ $type?: 'app.bsky.actor.defs#bskyAppProgressGuide'
471471+ guide: string
472472+}
473473+474474+const hashBskyAppProgressGuide = 'bskyAppProgressGuide'
475475+476476+export function isBskyAppProgressGuide<V>(v: V) {
477477+ return is$typed(v, id, hashBskyAppProgressGuide)
478478+}
479479+480480+export function validateBskyAppProgressGuide<V>(v: V) {
481481+ return validate<BskyAppProgressGuide & V>(v, id, hashBskyAppProgressGuide)
482482+}
483483+484484+export interface ProfileAssociatedChat {
485485+ $type?: 'app.bsky.actor.defs#profileAssociatedChat'
486486+ allowIncoming: 'all' | 'none' | 'following' | (string & {})
487487+}
488488+489489+const hashProfileAssociatedChat = 'profileAssociatedChat'
490490+491491+export function isProfileAssociatedChat<V>(v: V) {
492492+ return is$typed(v, id, hashProfileAssociatedChat)
493493+}
494494+495495+export function validateProfileAssociatedChat<V>(v: V) {
496496+ return validate<ProfileAssociatedChat & V>(v, id, hashProfileAssociatedChat)
497497+}
498498+499499+/** Default post interaction settings for the account. These values should be applied as default values when creating new posts. These refs should mirror the threadgate and postgate records exactly. */
500500+export interface PostInteractionSettingsPref {
501501+ $type?: 'app.bsky.actor.defs#postInteractionSettingsPref'
502502+ /** Matches threadgate record. List of rules defining who can reply to this users posts. If value is an empty array, no one can reply. If value is undefined, anyone can reply. */
503503+ threadgateAllowRules?: (
504504+ | $Typed<AppBskyFeedThreadgate.MentionRule>
505505+ | $Typed<AppBskyFeedThreadgate.FollowerRule>
506506+ | $Typed<AppBskyFeedThreadgate.FollowingRule>
507507+ | $Typed<AppBskyFeedThreadgate.ListRule>
508508+ | { $type: string }
509509+ )[]
510510+ /** Matches postgate record. List of rules defining who can embed this users posts. If value is an empty array or is undefined, no particular rules apply and anyone can embed. */
511511+ postgateEmbeddingRules?: (
512512+ | $Typed<AppBskyFeedPostgate.DisableRule>
513513+ | { $type: string }
514514+ )[]
515515+}
516516+517517+const hashPostInteractionSettingsPref = 'postInteractionSettingsPref'
518518+519519+export function isPostInteractionSettingsPref<V>(v: V) {
520520+ return is$typed(v, id, hashPostInteractionSettingsPref)
521521+}
522522+523523+export function validatePostInteractionSettingsPref<V>(v: V) {
524524+ return validate<PostInteractionSettingsPref & V>(
525525+ v,
526526+ id,
527527+ hashPostInteractionSettingsPref,
528528+ )
529529+}
+43
__generated__/types/app/bsky/actor/profile.ts
···11+/**
22+ * GENERATED CODE - DO NOT MODIFY
33+ */
44+import { type ValidationResult, BlobRef } from "npm:@atproto/lexicon"
55+import { CID } from "npm:multiformats/cid"
66+import { validate as _validate } from '../../../../lexicons.ts'
77+import {
88+ type $Typed,
99+ is$typed as _is$typed,
1010+ type OmitKey,
1111+} from '../../../../util.ts'
1212+import type * as ComAtprotoLabelDefs from '../../../com/atproto/label/defs.ts'
1313+import type * as ComAtprotoRepoStrongRef from '../../../com/atproto/repo/strongRef.ts'
1414+1515+const is$typed = _is$typed,
1616+ validate = _validate
1717+const id = 'app.bsky.actor.profile'
1818+1919+export interface Record {
2020+ $type: 'app.bsky.actor.profile'
2121+ /** Small image to be displayed next to posts from account. AKA, 'profile picture' */
2222+ avatar?: BlobRef
2323+ /** Larger horizontal image to display behind profile view. */
2424+ banner?: BlobRef
2525+ labels?: $Typed<ComAtprotoLabelDefs.SelfLabels> | { $type: string }
2626+ createdAt?: string
2727+ pinnedPost?: ComAtprotoRepoStrongRef.Main
2828+ /** Free-form profile description text. */
2929+ description?: string
3030+ displayName?: string
3131+ joinedViaStarterPack?: ComAtprotoRepoStrongRef.Main
3232+ [k: string]: unknown
3333+}
3434+3535+const hashRecord = 'main'
3636+3737+export function isRecord<V>(v: V) {
3838+ return is$typed(v, id, hashRecord)
3939+}
4040+4141+export function validateRecord<V>(v: V) {
4242+ return validate<Record & V>(v, id, hashRecord, true)
4343+}
+32
__generated__/types/app/bsky/embed/defs.ts
···11+/**
22+ * GENERATED CODE - DO NOT MODIFY
33+ */
44+import { type ValidationResult, BlobRef } from "npm:@atproto/lexicon"
55+import { CID } from "npm:multiformats/cid"
66+import { validate as _validate } from '../../../../lexicons.ts'
77+import {
88+ type $Typed,
99+ is$typed as _is$typed,
1010+ type OmitKey,
1111+} from '../../../../util.ts'
1212+1313+const is$typed = _is$typed,
1414+ validate = _validate
1515+const id = 'app.bsky.embed.defs'
1616+1717+/** width:height represents an aspect ratio. It may be approximate, and may not correspond to absolute dimensions in any given unit. */
1818+export interface AspectRatio {
1919+ $type?: 'app.bsky.embed.defs#aspectRatio'
2020+ width: number
2121+ height: number
2222+}
2323+2424+const hashAspectRatio = 'aspectRatio'
2525+2626+export function isAspectRatio<V>(v: V) {
2727+ return is$typed(v, id, hashAspectRatio)
2828+}
2929+3030+export function validateAspectRatio<V>(v: V) {
3131+ return validate<AspectRatio & V>(v, id, hashAspectRatio)
3232+}
+82
__generated__/types/app/bsky/embed/external.ts
···11+/**
22+ * GENERATED CODE - DO NOT MODIFY
33+ */
44+import { type ValidationResult, BlobRef } from "npm:@atproto/lexicon"
55+import { CID } from "npm:multiformats/cid"
66+import { validate as _validate } from '../../../../lexicons.ts'
77+import {
88+ type $Typed,
99+ is$typed as _is$typed,
1010+ type OmitKey,
1111+} from '../../../../util.ts'
1212+1313+const is$typed = _is$typed,
1414+ validate = _validate
1515+const id = 'app.bsky.embed.external'
1616+1717+/** A representation of some externally linked content (eg, a URL and 'card'), embedded in a Bluesky record (eg, a post). */
1818+export interface Main {
1919+ $type?: 'app.bsky.embed.external'
2020+ external: External
2121+}
2222+2323+const hashMain = 'main'
2424+2525+export function isMain<V>(v: V) {
2626+ return is$typed(v, id, hashMain)
2727+}
2828+2929+export function validateMain<V>(v: V) {
3030+ return validate<Main & V>(v, id, hashMain)
3131+}
3232+3333+export interface View {
3434+ $type?: 'app.bsky.embed.external#view'
3535+ external: ViewExternal
3636+}
3737+3838+const hashView = 'view'
3939+4040+export function isView<V>(v: V) {
4141+ return is$typed(v, id, hashView)
4242+}
4343+4444+export function validateView<V>(v: V) {
4545+ return validate<View & V>(v, id, hashView)
4646+}
4747+4848+export interface External {
4949+ $type?: 'app.bsky.embed.external#external'
5050+ uri: string
5151+ thumb?: BlobRef
5252+ title: string
5353+ description: string
5454+}
5555+5656+const hashExternal = 'external'
5757+5858+export function isExternal<V>(v: V) {
5959+ return is$typed(v, id, hashExternal)
6060+}
6161+6262+export function validateExternal<V>(v: V) {
6363+ return validate<External & V>(v, id, hashExternal)
6464+}
6565+6666+export interface ViewExternal {
6767+ $type?: 'app.bsky.embed.external#viewExternal'
6868+ uri: string
6969+ thumb?: string
7070+ title: string
7171+ description: string
7272+}
7373+7474+const hashViewExternal = 'viewExternal'
7575+7676+export function isViewExternal<V>(v: V) {
7777+ return is$typed(v, id, hashViewExternal)
7878+}
7979+8080+export function validateViewExternal<V>(v: V) {
8181+ return validate<ViewExternal & V>(v, id, hashViewExternal)
8282+}
+85
__generated__/types/app/bsky/embed/images.ts
···11+/**
22+ * GENERATED CODE - DO NOT MODIFY
33+ */
44+import { type ValidationResult, BlobRef } from "npm:@atproto/lexicon"
55+import { CID } from "npm:multiformats/cid"
66+import { validate as _validate } from '../../../../lexicons.ts'
77+import {
88+ type $Typed,
99+ is$typed as _is$typed,
1010+ type OmitKey,
1111+} from '../../../../util.ts'
1212+import type * as AppBskyEmbedDefs from './defs.ts'
1313+1414+const is$typed = _is$typed,
1515+ validate = _validate
1616+const id = 'app.bsky.embed.images'
1717+1818+export interface Main {
1919+ $type?: 'app.bsky.embed.images'
2020+ images: Image[]
2121+}
2222+2323+const hashMain = 'main'
2424+2525+export function isMain<V>(v: V) {
2626+ return is$typed(v, id, hashMain)
2727+}
2828+2929+export function validateMain<V>(v: V) {
3030+ return validate<Main & V>(v, id, hashMain)
3131+}
3232+3333+export interface View {
3434+ $type?: 'app.bsky.embed.images#view'
3535+ images: ViewImage[]
3636+}
3737+3838+const hashView = 'view'
3939+4040+export function isView<V>(v: V) {
4141+ return is$typed(v, id, hashView)
4242+}
4343+4444+export function validateView<V>(v: V) {
4545+ return validate<View & V>(v, id, hashView)
4646+}
4747+4848+export interface Image {
4949+ $type?: 'app.bsky.embed.images#image'
5050+ /** Alt text description of the image, for accessibility. */
5151+ alt: string
5252+ image: BlobRef
5353+ aspectRatio?: AppBskyEmbedDefs.AspectRatio
5454+}
5555+5656+const hashImage = 'image'
5757+5858+export function isImage<V>(v: V) {
5959+ return is$typed(v, id, hashImage)
6060+}
6161+6262+export function validateImage<V>(v: V) {
6363+ return validate<Image & V>(v, id, hashImage)
6464+}
6565+6666+export interface ViewImage {
6767+ $type?: 'app.bsky.embed.images#viewImage'
6868+ /** Alt text description of the image, for accessibility. */
6969+ alt: string
7070+ /** Fully-qualified URL where a thumbnail of the image can be fetched. For example, CDN location provided by the App View. */
7171+ thumb: string
7272+ /** Fully-qualified URL where a large version of the image can be fetched. May or may not be the exact original blob. For example, CDN location provided by the App View. */
7373+ fullsize: string
7474+ aspectRatio?: AppBskyEmbedDefs.AspectRatio
7575+}
7676+7777+const hashViewImage = 'viewImage'
7878+7979+export function isViewImage<V>(v: V) {
8080+ return is$typed(v, id, hashViewImage)
8181+}
8282+8383+export function validateViewImage<V>(v: V) {
8484+ return validate<ViewImage & V>(v, id, hashViewImage)
8585+}
+146
__generated__/types/app/bsky/embed/record.ts
···11+/**
22+ * GENERATED CODE - DO NOT MODIFY
33+ */
44+import { type ValidationResult, BlobRef } from "npm:@atproto/lexicon"
55+import { CID } from "npm:multiformats/cid"
66+import { validate as _validate } from '../../../../lexicons.ts'
77+import {
88+ type $Typed,
99+ is$typed as _is$typed,
1010+ type OmitKey,
1111+} from '../../../../util.ts'
1212+import type * as ComAtprotoRepoStrongRef from '../../../com/atproto/repo/strongRef.ts'
1313+import type * as AppBskyFeedDefs from '../feed/defs.ts'
1414+import type * as AppBskyGraphDefs from '../graph/defs.ts'
1515+import type * as AppBskyLabelerDefs from '../labeler/defs.ts'
1616+import type * as AppBskyActorDefs from '../actor/defs.ts'
1717+import type * as AppBskyEmbedImages from './images.ts'
1818+import type * as AppBskyEmbedVideo from './video.ts'
1919+import type * as AppBskyEmbedExternal from './external.ts'
2020+import type * as AppBskyEmbedRecordWithMedia from './recordWithMedia.ts'
2121+import type * as ComAtprotoLabelDefs from '../../../com/atproto/label/defs.ts'
2222+2323+const is$typed = _is$typed,
2424+ validate = _validate
2525+const id = 'app.bsky.embed.record'
2626+2727+export interface Main {
2828+ $type?: 'app.bsky.embed.record'
2929+ record: ComAtprotoRepoStrongRef.Main
3030+}
3131+3232+const hashMain = 'main'
3333+3434+export function isMain<V>(v: V) {
3535+ return is$typed(v, id, hashMain)
3636+}
3737+3838+export function validateMain<V>(v: V) {
3939+ return validate<Main & V>(v, id, hashMain)
4040+}
4141+4242+export interface View {
4343+ $type?: 'app.bsky.embed.record#view'
4444+ record:
4545+ | $Typed<ViewRecord>
4646+ | $Typed<ViewNotFound>
4747+ | $Typed<ViewBlocked>
4848+ | $Typed<ViewDetached>
4949+ | $Typed<AppBskyFeedDefs.GeneratorView>
5050+ | $Typed<AppBskyGraphDefs.ListView>
5151+ | $Typed<AppBskyLabelerDefs.LabelerView>
5252+ | $Typed<AppBskyGraphDefs.StarterPackViewBasic>
5353+ | { $type: string }
5454+}
5555+5656+const hashView = 'view'
5757+5858+export function isView<V>(v: V) {
5959+ return is$typed(v, id, hashView)
6060+}
6161+6262+export function validateView<V>(v: V) {
6363+ return validate<View & V>(v, id, hashView)
6464+}
6565+6666+export interface ViewRecord {
6767+ $type?: 'app.bsky.embed.record#viewRecord'
6868+ cid: string
6969+ uri: string
7070+ /** The record data itself. */
7171+ value: { [_ in string]: unknown }
7272+ author: AppBskyActorDefs.ProfileViewBasic
7373+ embeds?: (
7474+ | $Typed<AppBskyEmbedImages.View>
7575+ | $Typed<AppBskyEmbedVideo.View>
7676+ | $Typed<AppBskyEmbedExternal.View>
7777+ | $Typed<View>
7878+ | $Typed<AppBskyEmbedRecordWithMedia.View>
7979+ | { $type: string }
8080+ )[]
8181+ labels?: ComAtprotoLabelDefs.Label[]
8282+ indexedAt: string
8383+ likeCount?: number
8484+ quoteCount?: number
8585+ replyCount?: number
8686+ repostCount?: number
8787+}
8888+8989+const hashViewRecord = 'viewRecord'
9090+9191+export function isViewRecord<V>(v: V) {
9292+ return is$typed(v, id, hashViewRecord)
9393+}
9494+9595+export function validateViewRecord<V>(v: V) {
9696+ return validate<ViewRecord & V>(v, id, hashViewRecord)
9797+}
9898+9999+export interface ViewBlocked {
100100+ $type?: 'app.bsky.embed.record#viewBlocked'
101101+ uri: string
102102+ author: AppBskyFeedDefs.BlockedAuthor
103103+ blocked: true
104104+}
105105+106106+const hashViewBlocked = 'viewBlocked'
107107+108108+export function isViewBlocked<V>(v: V) {
109109+ return is$typed(v, id, hashViewBlocked)
110110+}
111111+112112+export function validateViewBlocked<V>(v: V) {
113113+ return validate<ViewBlocked & V>(v, id, hashViewBlocked)
114114+}
115115+116116+export interface ViewDetached {
117117+ $type?: 'app.bsky.embed.record#viewDetached'
118118+ uri: string
119119+ detached: true
120120+}
121121+122122+const hashViewDetached = 'viewDetached'
123123+124124+export function isViewDetached<V>(v: V) {
125125+ return is$typed(v, id, hashViewDetached)
126126+}
127127+128128+export function validateViewDetached<V>(v: V) {
129129+ return validate<ViewDetached & V>(v, id, hashViewDetached)
130130+}
131131+132132+export interface ViewNotFound {
133133+ $type?: 'app.bsky.embed.record#viewNotFound'
134134+ uri: string
135135+ notFound: true
136136+}
137137+138138+const hashViewNotFound = 'viewNotFound'
139139+140140+export function isViewNotFound<V>(v: V) {
141141+ return is$typed(v, id, hashViewNotFound)
142142+}
143143+144144+export function validateViewNotFound<V>(v: V) {
145145+ return validate<ViewNotFound & V>(v, id, hashViewNotFound)
146146+}
···11+/**
22+ * GENERATED CODE - DO NOT MODIFY
33+ */
44+import { type ValidationResult, BlobRef } from "npm:@atproto/lexicon"
55+import { CID } from "npm:multiformats/cid"
66+import { validate as _validate } from '../../../../lexicons.ts'
77+import {
88+ type $Typed,
99+ is$typed as _is$typed,
1010+ type OmitKey,
1111+} from '../../../../util.ts'
1212+import type * as AppBskyEmbedImages from './images.ts'
1313+import type * as AppBskyEmbedVideo from './video.ts'
1414+import type * as AppBskyEmbedExternal from './external.ts'
1515+import type * as AppBskyEmbedRecord from './record.ts'
1616+1717+const is$typed = _is$typed,
1818+ validate = _validate
1919+const id = 'app.bsky.embed.recordWithMedia'
2020+2121+export interface Main {
2222+ $type?: 'app.bsky.embed.recordWithMedia'
2323+ media:
2424+ | $Typed<AppBskyEmbedImages.Main>
2525+ | $Typed<AppBskyEmbedVideo.Main>
2626+ | $Typed<AppBskyEmbedExternal.Main>
2727+ | { $type: string }
2828+ record: AppBskyEmbedRecord.Main
2929+}
3030+3131+const hashMain = 'main'
3232+3333+export function isMain<V>(v: V) {
3434+ return is$typed(v, id, hashMain)
3535+}
3636+3737+export function validateMain<V>(v: V) {
3838+ return validate<Main & V>(v, id, hashMain)
3939+}
4040+4141+export interface View {
4242+ $type?: 'app.bsky.embed.recordWithMedia#view'
4343+ media:
4444+ | $Typed<AppBskyEmbedImages.View>
4545+ | $Typed<AppBskyEmbedVideo.View>
4646+ | $Typed<AppBskyEmbedExternal.View>
4747+ | { $type: string }
4848+ record: AppBskyEmbedRecord.View
4949+}
5050+5151+const hashView = 'view'
5252+5353+export function isView<V>(v: V) {
5454+ return is$typed(v, id, hashView)
5555+}
5656+5757+export function validateView<V>(v: V) {
5858+ return validate<View & V>(v, id, hashView)
5959+}
+70
__generated__/types/app/bsky/embed/video.ts
···11+/**
22+ * GENERATED CODE - DO NOT MODIFY
33+ */
44+import { type ValidationResult, BlobRef } from "npm:@atproto/lexicon"
55+import { CID } from "npm:multiformats/cid"
66+import { validate as _validate } from '../../../../lexicons.ts'
77+import {
88+ type $Typed,
99+ is$typed as _is$typed,
1010+ type OmitKey,
1111+} from '../../../../util.ts'
1212+import type * as AppBskyEmbedDefs from './defs.ts'
1313+1414+const is$typed = _is$typed,
1515+ validate = _validate
1616+const id = 'app.bsky.embed.video'
1717+1818+export interface Main {
1919+ $type?: 'app.bsky.embed.video'
2020+ /** Alt text description of the video, for accessibility. */
2121+ alt?: string
2222+ video: BlobRef
2323+ captions?: Caption[]
2424+ aspectRatio?: AppBskyEmbedDefs.AspectRatio
2525+}
2626+2727+const hashMain = 'main'
2828+2929+export function isMain<V>(v: V) {
3030+ return is$typed(v, id, hashMain)
3131+}
3232+3333+export function validateMain<V>(v: V) {
3434+ return validate<Main & V>(v, id, hashMain)
3535+}
3636+3737+export interface View {
3838+ $type?: 'app.bsky.embed.video#view'
3939+ alt?: string
4040+ cid: string
4141+ playlist: string
4242+ thumbnail?: string
4343+ aspectRatio?: AppBskyEmbedDefs.AspectRatio
4444+}
4545+4646+const hashView = 'view'
4747+4848+export function isView<V>(v: V) {
4949+ return is$typed(v, id, hashView)
5050+}
5151+5252+export function validateView<V>(v: V) {
5353+ return validate<View & V>(v, id, hashView)
5454+}
5555+5656+export interface Caption {
5757+ $type?: 'app.bsky.embed.video#caption'
5858+ file: BlobRef
5959+ lang: string
6060+}
6161+6262+const hashCaption = 'caption'
6363+6464+export function isCaption<V>(v: V) {
6565+ return is$typed(v, id, hashCaption)
6666+}
6767+6868+export function validateCaption<V>(v: V) {
6969+ return validate<Caption & V>(v, id, hashCaption)
7070+}
+422
__generated__/types/app/bsky/feed/defs.ts
···11+/**
22+ * GENERATED CODE - DO NOT MODIFY
33+ */
44+import { type ValidationResult, BlobRef } from "npm:@atproto/lexicon"
55+import { CID } from "npm:multiformats/cid"
66+import { validate as _validate } from '../../../../lexicons.ts'
77+import {
88+ type $Typed,
99+ is$typed as _is$typed,
1010+ type OmitKey,
1111+} from '../../../../util.ts'
1212+import type * as AppBskyEmbedImages from '../embed/images.ts'
1313+import type * as AppBskyEmbedVideo from '../embed/video.ts'
1414+import type * as AppBskyEmbedExternal from '../embed/external.ts'
1515+import type * as AppBskyEmbedRecord from '../embed/record.ts'
1616+import type * as AppBskyEmbedRecordWithMedia from '../embed/recordWithMedia.ts'
1717+import type * as AppBskyActorDefs from '../actor/defs.ts'
1818+import type * as ComAtprotoLabelDefs from '../../../com/atproto/label/defs.ts'
1919+import type * as AppBskyRichtextFacet from '../richtext/facet.ts'
2020+import type * as AppBskyGraphDefs from '../graph/defs.ts'
2121+2222+const is$typed = _is$typed,
2323+ validate = _validate
2424+const id = 'app.bsky.feed.defs'
2525+2626+export interface PostView {
2727+ $type?: 'app.bsky.feed.defs#postView'
2828+ cid: string
2929+ uri: string
3030+ embed?:
3131+ | $Typed<AppBskyEmbedImages.View>
3232+ | $Typed<AppBskyEmbedVideo.View>
3333+ | $Typed<AppBskyEmbedExternal.View>
3434+ | $Typed<AppBskyEmbedRecord.View>
3535+ | $Typed<AppBskyEmbedRecordWithMedia.View>
3636+ | { $type: string }
3737+ author: AppBskyActorDefs.ProfileViewBasic
3838+ labels?: ComAtprotoLabelDefs.Label[]
3939+ record: { [_ in string]: unknown }
4040+ viewer?: ViewerState
4141+ indexedAt: string
4242+ likeCount?: number
4343+ quoteCount?: number
4444+ replyCount?: number
4545+ threadgate?: ThreadgateView
4646+ repostCount?: number
4747+}
4848+4949+const hashPostView = 'postView'
5050+5151+export function isPostView<V>(v: V) {
5252+ return is$typed(v, id, hashPostView)
5353+}
5454+5555+export function validatePostView<V>(v: V) {
5656+ return validate<PostView & V>(v, id, hashPostView)
5757+}
5858+5959+export interface ReplyRef {
6060+ $type?: 'app.bsky.feed.defs#replyRef'
6161+ root:
6262+ | $Typed<PostView>
6363+ | $Typed<NotFoundPost>
6464+ | $Typed<BlockedPost>
6565+ | { $type: string }
6666+ parent:
6767+ | $Typed<PostView>
6868+ | $Typed<NotFoundPost>
6969+ | $Typed<BlockedPost>
7070+ | { $type: string }
7171+ grandparentAuthor?: AppBskyActorDefs.ProfileViewBasic
7272+}
7373+7474+const hashReplyRef = 'replyRef'
7575+7676+export function isReplyRef<V>(v: V) {
7777+ return is$typed(v, id, hashReplyRef)
7878+}
7979+8080+export function validateReplyRef<V>(v: V) {
8181+ return validate<ReplyRef & V>(v, id, hashReplyRef)
8282+}
8383+8484+export interface ReasonPin {
8585+ $type?: 'app.bsky.feed.defs#reasonPin'
8686+}
8787+8888+const hashReasonPin = 'reasonPin'
8989+9090+export function isReasonPin<V>(v: V) {
9191+ return is$typed(v, id, hashReasonPin)
9292+}
9393+9494+export function validateReasonPin<V>(v: V) {
9595+ return validate<ReasonPin & V>(v, id, hashReasonPin)
9696+}
9797+9898+export interface BlockedPost {
9999+ $type?: 'app.bsky.feed.defs#blockedPost'
100100+ uri: string
101101+ author: BlockedAuthor
102102+ blocked: true
103103+}
104104+105105+const hashBlockedPost = 'blockedPost'
106106+107107+export function isBlockedPost<V>(v: V) {
108108+ return is$typed(v, id, hashBlockedPost)
109109+}
110110+111111+export function validateBlockedPost<V>(v: V) {
112112+ return validate<BlockedPost & V>(v, id, hashBlockedPost)
113113+}
114114+115115+export interface Interaction {
116116+ $type?: 'app.bsky.feed.defs#interaction'
117117+ item?: string
118118+ event?:
119119+ | 'app.bsky.feed.defs#requestLess'
120120+ | 'app.bsky.feed.defs#requestMore'
121121+ | 'app.bsky.feed.defs#clickthroughItem'
122122+ | 'app.bsky.feed.defs#clickthroughAuthor'
123123+ | 'app.bsky.feed.defs#clickthroughReposter'
124124+ | 'app.bsky.feed.defs#clickthroughEmbed'
125125+ | 'app.bsky.feed.defs#interactionSeen'
126126+ | 'app.bsky.feed.defs#interactionLike'
127127+ | 'app.bsky.feed.defs#interactionRepost'
128128+ | 'app.bsky.feed.defs#interactionReply'
129129+ | 'app.bsky.feed.defs#interactionQuote'
130130+ | 'app.bsky.feed.defs#interactionShare'
131131+ | (string & {})
132132+ /** Context on a feed item that was originally supplied by the feed generator on getFeedSkeleton. */
133133+ feedContext?: string
134134+}
135135+136136+const hashInteraction = 'interaction'
137137+138138+export function isInteraction<V>(v: V) {
139139+ return is$typed(v, id, hashInteraction)
140140+}
141141+142142+export function validateInteraction<V>(v: V) {
143143+ return validate<Interaction & V>(v, id, hashInteraction)
144144+}
145145+146146+/** Request that less content like the given feed item be shown in the feed */
147147+export const REQUESTLESS = `${id}#requestLess`
148148+/** Request that more content like the given feed item be shown in the feed */
149149+export const REQUESTMORE = `${id}#requestMore`
150150+151151+/** Metadata about the requesting account's relationship with the subject content. Only has meaningful content for authed requests. */
152152+export interface ViewerState {
153153+ $type?: 'app.bsky.feed.defs#viewerState'
154154+ like?: string
155155+ pinned?: boolean
156156+ repost?: string
157157+ threadMuted?: boolean
158158+ replyDisabled?: boolean
159159+ embeddingDisabled?: boolean
160160+}
161161+162162+const hashViewerState = 'viewerState'
163163+164164+export function isViewerState<V>(v: V) {
165165+ return is$typed(v, id, hashViewerState)
166166+}
167167+168168+export function validateViewerState<V>(v: V) {
169169+ return validate<ViewerState & V>(v, id, hashViewerState)
170170+}
171171+172172+export interface FeedViewPost {
173173+ $type?: 'app.bsky.feed.defs#feedViewPost'
174174+ post: PostView
175175+ reply?: ReplyRef
176176+ reason?: $Typed<ReasonRepost> | $Typed<ReasonPin> | { $type: string }
177177+ /** Context provided by feed generator that may be passed back alongside interactions. */
178178+ feedContext?: string
179179+}
180180+181181+const hashFeedViewPost = 'feedViewPost'
182182+183183+export function isFeedViewPost<V>(v: V) {
184184+ return is$typed(v, id, hashFeedViewPost)
185185+}
186186+187187+export function validateFeedViewPost<V>(v: V) {
188188+ return validate<FeedViewPost & V>(v, id, hashFeedViewPost)
189189+}
190190+191191+export interface NotFoundPost {
192192+ $type?: 'app.bsky.feed.defs#notFoundPost'
193193+ uri: string
194194+ notFound: true
195195+}
196196+197197+const hashNotFoundPost = 'notFoundPost'
198198+199199+export function isNotFoundPost<V>(v: V) {
200200+ return is$typed(v, id, hashNotFoundPost)
201201+}
202202+203203+export function validateNotFoundPost<V>(v: V) {
204204+ return validate<NotFoundPost & V>(v, id, hashNotFoundPost)
205205+}
206206+207207+export interface ReasonRepost {
208208+ $type?: 'app.bsky.feed.defs#reasonRepost'
209209+ by: AppBskyActorDefs.ProfileViewBasic
210210+ indexedAt: string
211211+}
212212+213213+const hashReasonRepost = 'reasonRepost'
214214+215215+export function isReasonRepost<V>(v: V) {
216216+ return is$typed(v, id, hashReasonRepost)
217217+}
218218+219219+export function validateReasonRepost<V>(v: V) {
220220+ return validate<ReasonRepost & V>(v, id, hashReasonRepost)
221221+}
222222+223223+export interface BlockedAuthor {
224224+ $type?: 'app.bsky.feed.defs#blockedAuthor'
225225+ did: string
226226+ viewer?: AppBskyActorDefs.ViewerState
227227+}
228228+229229+const hashBlockedAuthor = 'blockedAuthor'
230230+231231+export function isBlockedAuthor<V>(v: V) {
232232+ return is$typed(v, id, hashBlockedAuthor)
233233+}
234234+235235+export function validateBlockedAuthor<V>(v: V) {
236236+ return validate<BlockedAuthor & V>(v, id, hashBlockedAuthor)
237237+}
238238+239239+export interface GeneratorView {
240240+ $type?: 'app.bsky.feed.defs#generatorView'
241241+ cid: string
242242+ did: string
243243+ uri: string
244244+ avatar?: string
245245+ labels?: ComAtprotoLabelDefs.Label[]
246246+ viewer?: GeneratorViewerState
247247+ creator: AppBskyActorDefs.ProfileView
248248+ indexedAt: string
249249+ likeCount?: number
250250+ contentMode?:
251251+ | 'app.bsky.feed.defs#contentModeUnspecified'
252252+ | 'app.bsky.feed.defs#contentModeVideo'
253253+ | (string & {})
254254+ description?: string
255255+ displayName: string
256256+ descriptionFacets?: AppBskyRichtextFacet.Main[]
257257+ acceptsInteractions?: boolean
258258+}
259259+260260+const hashGeneratorView = 'generatorView'
261261+262262+export function isGeneratorView<V>(v: V) {
263263+ return is$typed(v, id, hashGeneratorView)
264264+}
265265+266266+export function validateGeneratorView<V>(v: V) {
267267+ return validate<GeneratorView & V>(v, id, hashGeneratorView)
268268+}
269269+270270+/** Metadata about this post within the context of the thread it is in. */
271271+export interface ThreadContext {
272272+ $type?: 'app.bsky.feed.defs#threadContext'
273273+ rootAuthorLike?: string
274274+}
275275+276276+const hashThreadContext = 'threadContext'
277277+278278+export function isThreadContext<V>(v: V) {
279279+ return is$typed(v, id, hashThreadContext)
280280+}
281281+282282+export function validateThreadContext<V>(v: V) {
283283+ return validate<ThreadContext & V>(v, id, hashThreadContext)
284284+}
285285+286286+export interface ThreadViewPost {
287287+ $type?: 'app.bsky.feed.defs#threadViewPost'
288288+ post: PostView
289289+ parent?:
290290+ | $Typed<ThreadViewPost>
291291+ | $Typed<NotFoundPost>
292292+ | $Typed<BlockedPost>
293293+ | { $type: string }
294294+ replies?: (
295295+ | $Typed<ThreadViewPost>
296296+ | $Typed<NotFoundPost>
297297+ | $Typed<BlockedPost>
298298+ | { $type: string }
299299+ )[]
300300+ threadContext?: ThreadContext
301301+}
302302+303303+const hashThreadViewPost = 'threadViewPost'
304304+305305+export function isThreadViewPost<V>(v: V) {
306306+ return is$typed(v, id, hashThreadViewPost)
307307+}
308308+309309+export function validateThreadViewPost<V>(v: V) {
310310+ return validate<ThreadViewPost & V>(v, id, hashThreadViewPost)
311311+}
312312+313313+export interface ThreadgateView {
314314+ $type?: 'app.bsky.feed.defs#threadgateView'
315315+ cid?: string
316316+ uri?: string
317317+ lists?: AppBskyGraphDefs.ListViewBasic[]
318318+ record?: { [_ in string]: unknown }
319319+}
320320+321321+const hashThreadgateView = 'threadgateView'
322322+323323+export function isThreadgateView<V>(v: V) {
324324+ return is$typed(v, id, hashThreadgateView)
325325+}
326326+327327+export function validateThreadgateView<V>(v: V) {
328328+ return validate<ThreadgateView & V>(v, id, hashThreadgateView)
329329+}
330330+331331+/** User liked the feed item */
332332+export const INTERACTIONLIKE = `${id}#interactionLike`
333333+/** Feed item was seen by user */
334334+export const INTERACTIONSEEN = `${id}#interactionSeen`
335335+/** User clicked through to the feed item */
336336+export const CLICKTHROUGHITEM = `${id}#clickthroughItem`
337337+/** Declares the feed generator returns posts containing app.bsky.embed.video embeds. */
338338+export const CONTENTMODEVIDEO = `${id}#contentModeVideo`
339339+/** User quoted the feed item */
340340+export const INTERACTIONQUOTE = `${id}#interactionQuote`
341341+/** User replied to the feed item */
342342+export const INTERACTIONREPLY = `${id}#interactionReply`
343343+/** User shared the feed item */
344344+export const INTERACTIONSHARE = `${id}#interactionShare`
345345+346346+export interface SkeletonFeedPost {
347347+ $type?: 'app.bsky.feed.defs#skeletonFeedPost'
348348+ post: string
349349+ reason?:
350350+ | $Typed<SkeletonReasonRepost>
351351+ | $Typed<SkeletonReasonPin>
352352+ | { $type: string }
353353+ /** Context that will be passed through to client and may be passed to feed generator back alongside interactions. */
354354+ feedContext?: string
355355+}
356356+357357+const hashSkeletonFeedPost = 'skeletonFeedPost'
358358+359359+export function isSkeletonFeedPost<V>(v: V) {
360360+ return is$typed(v, id, hashSkeletonFeedPost)
361361+}
362362+363363+export function validateSkeletonFeedPost<V>(v: V) {
364364+ return validate<SkeletonFeedPost & V>(v, id, hashSkeletonFeedPost)
365365+}
366366+367367+/** User clicked through to the embedded content of the feed item */
368368+export const CLICKTHROUGHEMBED = `${id}#clickthroughEmbed`
369369+/** User reposted the feed item */
370370+export const INTERACTIONREPOST = `${id}#interactionRepost`
371371+372372+export interface SkeletonReasonPin {
373373+ $type?: 'app.bsky.feed.defs#skeletonReasonPin'
374374+}
375375+376376+const hashSkeletonReasonPin = 'skeletonReasonPin'
377377+378378+export function isSkeletonReasonPin<V>(v: V) {
379379+ return is$typed(v, id, hashSkeletonReasonPin)
380380+}
381381+382382+export function validateSkeletonReasonPin<V>(v: V) {
383383+ return validate<SkeletonReasonPin & V>(v, id, hashSkeletonReasonPin)
384384+}
385385+386386+/** User clicked through to the author of the feed item */
387387+export const CLICKTHROUGHAUTHOR = `${id}#clickthroughAuthor`
388388+/** User clicked through to the reposter of the feed item */
389389+export const CLICKTHROUGHREPOSTER = `${id}#clickthroughReposter`
390390+391391+export interface GeneratorViewerState {
392392+ $type?: 'app.bsky.feed.defs#generatorViewerState'
393393+ like?: string
394394+}
395395+396396+const hashGeneratorViewerState = 'generatorViewerState'
397397+398398+export function isGeneratorViewerState<V>(v: V) {
399399+ return is$typed(v, id, hashGeneratorViewerState)
400400+}
401401+402402+export function validateGeneratorViewerState<V>(v: V) {
403403+ return validate<GeneratorViewerState & V>(v, id, hashGeneratorViewerState)
404404+}
405405+406406+export interface SkeletonReasonRepost {
407407+ $type?: 'app.bsky.feed.defs#skeletonReasonRepost'
408408+ repost: string
409409+}
410410+411411+const hashSkeletonReasonRepost = 'skeletonReasonRepost'
412412+413413+export function isSkeletonReasonRepost<V>(v: V) {
414414+ return is$typed(v, id, hashSkeletonReasonRepost)
415415+}
416416+417417+export function validateSkeletonReasonRepost<V>(v: V) {
418418+ return validate<SkeletonReasonRepost & V>(v, id, hashSkeletonReasonRepost)
419419+}
420420+421421+/** Declares the feed generator returns any types of posts. */
422422+export const CONTENTMODEUNSPECIFIED = `${id}#contentModeUnspecified`
+52
__generated__/types/app/bsky/feed/postgate.ts
···11+/**
22+ * GENERATED CODE - DO NOT MODIFY
33+ */
44+import { type ValidationResult, BlobRef } from "npm:@atproto/lexicon"
55+import { CID } from "npm:multiformats/cid"
66+import { validate as _validate } from '../../../../lexicons.ts'
77+import {
88+ type $Typed,
99+ is$typed as _is$typed,
1010+ type OmitKey,
1111+} from '../../../../util.ts'
1212+1313+const is$typed = _is$typed,
1414+ validate = _validate
1515+const id = 'app.bsky.feed.postgate'
1616+1717+export interface Record {
1818+ $type: 'app.bsky.feed.postgate'
1919+ /** Reference (AT-URI) to the post record. */
2020+ post: string
2121+ createdAt: string
2222+ /** List of rules defining who can embed this post. If value is an empty array or is undefined, no particular rules apply and anyone can embed. */
2323+ embeddingRules?: ($Typed<DisableRule> | { $type: string })[]
2424+ /** List of AT-URIs embedding this post that the author has detached from. */
2525+ detachedEmbeddingUris?: string[]
2626+ [k: string]: unknown
2727+}
2828+2929+const hashRecord = 'main'
3030+3131+export function isRecord<V>(v: V) {
3232+ return is$typed(v, id, hashRecord)
3333+}
3434+3535+export function validateRecord<V>(v: V) {
3636+ return validate<Record & V>(v, id, hashRecord, true)
3737+}
3838+3939+/** Disables embedding of this post. */
4040+export interface DisableRule {
4141+ $type?: 'app.bsky.feed.postgate#disableRule'
4242+}
4343+4444+const hashDisableRule = 'disableRule'
4545+4646+export function isDisableRule<V>(v: V) {
4747+ return is$typed(v, id, hashDisableRule)
4848+}
4949+5050+export function validateDisableRule<V>(v: V) {
5151+ return validate<DisableRule & V>(v, id, hashDisableRule)
5252+}
+104
__generated__/types/app/bsky/feed/threadgate.ts
···11+/**
22+ * GENERATED CODE - DO NOT MODIFY
33+ */
44+import { type ValidationResult, BlobRef } from "npm:@atproto/lexicon"
55+import { CID } from "npm:multiformats/cid"
66+import { validate as _validate } from '../../../../lexicons.ts'
77+import {
88+ type $Typed,
99+ is$typed as _is$typed,
1010+ type OmitKey,
1111+} from '../../../../util.ts'
1212+1313+const is$typed = _is$typed,
1414+ validate = _validate
1515+const id = 'app.bsky.feed.threadgate'
1616+1717+export interface Record {
1818+ $type: 'app.bsky.feed.threadgate'
1919+ /** Reference (AT-URI) to the post record. */
2020+ post: string
2121+ /** List of rules defining who can reply to this post. If value is an empty array, no one can reply. If value is undefined, anyone can reply. */
2222+ allow?: (
2323+ | $Typed<MentionRule>
2424+ | $Typed<FollowerRule>
2525+ | $Typed<FollowingRule>
2626+ | $Typed<ListRule>
2727+ | { $type: string }
2828+ )[]
2929+ createdAt: string
3030+ /** List of hidden reply URIs. */
3131+ hiddenReplies?: string[]
3232+ [k: string]: unknown
3333+}
3434+3535+const hashRecord = 'main'
3636+3737+export function isRecord<V>(v: V) {
3838+ return is$typed(v, id, hashRecord)
3939+}
4040+4141+export function validateRecord<V>(v: V) {
4242+ return validate<Record & V>(v, id, hashRecord, true)
4343+}
4444+4545+/** Allow replies from actors on a list. */
4646+export interface ListRule {
4747+ $type?: 'app.bsky.feed.threadgate#listRule'
4848+ list: string
4949+}
5050+5151+const hashListRule = 'listRule'
5252+5353+export function isListRule<V>(v: V) {
5454+ return is$typed(v, id, hashListRule)
5555+}
5656+5757+export function validateListRule<V>(v: V) {
5858+ return validate<ListRule & V>(v, id, hashListRule)
5959+}
6060+6161+/** Allow replies from actors mentioned in your post. */
6262+export interface MentionRule {
6363+ $type?: 'app.bsky.feed.threadgate#mentionRule'
6464+}
6565+6666+const hashMentionRule = 'mentionRule'
6767+6868+export function isMentionRule<V>(v: V) {
6969+ return is$typed(v, id, hashMentionRule)
7070+}
7171+7272+export function validateMentionRule<V>(v: V) {
7373+ return validate<MentionRule & V>(v, id, hashMentionRule)
7474+}
7575+7676+/** Allow replies from actors who follow you. */
7777+export interface FollowerRule {
7878+ $type?: 'app.bsky.feed.threadgate#followerRule'
7979+}
8080+8181+const hashFollowerRule = 'followerRule'
8282+8383+export function isFollowerRule<V>(v: V) {
8484+ return is$typed(v, id, hashFollowerRule)
8585+}
8686+8787+export function validateFollowerRule<V>(v: V) {
8888+ return validate<FollowerRule & V>(v, id, hashFollowerRule)
8989+}
9090+9191+/** Allow replies from actors you follow. */
9292+export interface FollowingRule {
9393+ $type?: 'app.bsky.feed.threadgate#followingRule'
9494+}
9595+9696+const hashFollowingRule = 'followingRule'
9797+9898+export function isFollowingRule<V>(v: V) {
9999+ return is$typed(v, id, hashFollowingRule)
100100+}
101101+102102+export function validateFollowingRule<V>(v: V) {
103103+ return validate<FollowingRule & V>(v, id, hashFollowingRule)
104104+}
+199
__generated__/types/app/bsky/graph/defs.ts
···11+/**
22+ * GENERATED CODE - DO NOT MODIFY
33+ */
44+import { type ValidationResult, BlobRef } from "npm:@atproto/lexicon"
55+import { CID } from "npm:multiformats/cid"
66+import { validate as _validate } from '../../../../lexicons.ts'
77+import {
88+ type $Typed,
99+ is$typed as _is$typed,
1010+ type OmitKey,
1111+} from '../../../../util.ts'
1212+import type * as ComAtprotoLabelDefs from '../../../com/atproto/label/defs.ts'
1313+import type * as AppBskyActorDefs from '../actor/defs.ts'
1414+import type * as AppBskyRichtextFacet from '../richtext/facet.ts'
1515+import type * as AppBskyFeedDefs from '../feed/defs.ts'
1616+1717+const is$typed = _is$typed,
1818+ validate = _validate
1919+const id = 'app.bsky.graph.defs'
2020+/** A list of actors to apply an aggregate moderation action (mute/block) on. */
2121+export const MODLIST = `${id}#modlist`
2222+2323+export interface ListView {
2424+ $type?: 'app.bsky.graph.defs#listView'
2525+ cid: string
2626+ uri: string
2727+ name: string
2828+ avatar?: string
2929+ labels?: ComAtprotoLabelDefs.Label[]
3030+ viewer?: ListViewerState
3131+ creator: AppBskyActorDefs.ProfileView
3232+ purpose: ListPurpose
3333+ indexedAt: string
3434+ description?: string
3535+ listItemCount?: number
3636+ descriptionFacets?: AppBskyRichtextFacet.Main[]
3737+}
3838+3939+const hashListView = 'listView'
4040+4141+export function isListView<V>(v: V) {
4242+ return is$typed(v, id, hashListView)
4343+}
4444+4545+export function validateListView<V>(v: V) {
4646+ return validate<ListView & V>(v, id, hashListView)
4747+}
4848+4949+/** A list of actors used for curation purposes such as list feeds or interaction gating. */
5050+export const CURATELIST = `${id}#curatelist`
5151+5252+export type ListPurpose =
5353+ | 'app.bsky.graph.defs#modlist'
5454+ | 'app.bsky.graph.defs#curatelist'
5555+ | 'app.bsky.graph.defs#referencelist'
5656+ | (string & {})
5757+5858+export interface ListItemView {
5959+ $type?: 'app.bsky.graph.defs#listItemView'
6060+ uri: string
6161+ subject: AppBskyActorDefs.ProfileView
6262+}
6363+6464+const hashListItemView = 'listItemView'
6565+6666+export function isListItemView<V>(v: V) {
6767+ return is$typed(v, id, hashListItemView)
6868+}
6969+7070+export function validateListItemView<V>(v: V) {
7171+ return validate<ListItemView & V>(v, id, hashListItemView)
7272+}
7373+7474+/** lists the bi-directional graph relationships between one actor (not indicated in the object), and the target actors (the DID included in the object) */
7575+export interface Relationship {
7676+ $type?: 'app.bsky.graph.defs#relationship'
7777+ did: string
7878+ /** if the actor follows this DID, this is the AT-URI of the follow record */
7979+ following?: string
8080+ /** if the actor is followed by this DID, contains the AT-URI of the follow record */
8181+ followedBy?: string
8282+}
8383+8484+const hashRelationship = 'relationship'
8585+8686+export function isRelationship<V>(v: V) {
8787+ return is$typed(v, id, hashRelationship)
8888+}
8989+9090+export function validateRelationship<V>(v: V) {
9191+ return validate<Relationship & V>(v, id, hashRelationship)
9292+}
9393+9494+export interface ListViewBasic {
9595+ $type?: 'app.bsky.graph.defs#listViewBasic'
9696+ cid: string
9797+ uri: string
9898+ name: string
9999+ avatar?: string
100100+ labels?: ComAtprotoLabelDefs.Label[]
101101+ viewer?: ListViewerState
102102+ purpose: ListPurpose
103103+ indexedAt?: string
104104+ listItemCount?: number
105105+}
106106+107107+const hashListViewBasic = 'listViewBasic'
108108+109109+export function isListViewBasic<V>(v: V) {
110110+ return is$typed(v, id, hashListViewBasic)
111111+}
112112+113113+export function validateListViewBasic<V>(v: V) {
114114+ return validate<ListViewBasic & V>(v, id, hashListViewBasic)
115115+}
116116+117117+/** indicates that a handle or DID could not be resolved */
118118+export interface NotFoundActor {
119119+ $type?: 'app.bsky.graph.defs#notFoundActor'
120120+ actor: string
121121+ notFound: true
122122+}
123123+124124+const hashNotFoundActor = 'notFoundActor'
125125+126126+export function isNotFoundActor<V>(v: V) {
127127+ return is$typed(v, id, hashNotFoundActor)
128128+}
129129+130130+export function validateNotFoundActor<V>(v: V) {
131131+ return validate<NotFoundActor & V>(v, id, hashNotFoundActor)
132132+}
133133+134134+/** A list of actors used for only for reference purposes such as within a starter pack. */
135135+export const REFERENCELIST = `${id}#referencelist`
136136+137137+export interface ListViewerState {
138138+ $type?: 'app.bsky.graph.defs#listViewerState'
139139+ muted?: boolean
140140+ blocked?: string
141141+}
142142+143143+const hashListViewerState = 'listViewerState'
144144+145145+export function isListViewerState<V>(v: V) {
146146+ return is$typed(v, id, hashListViewerState)
147147+}
148148+149149+export function validateListViewerState<V>(v: V) {
150150+ return validate<ListViewerState & V>(v, id, hashListViewerState)
151151+}
152152+153153+export interface StarterPackView {
154154+ $type?: 'app.bsky.graph.defs#starterPackView'
155155+ cid: string
156156+ uri: string
157157+ list?: ListViewBasic
158158+ feeds?: AppBskyFeedDefs.GeneratorView[]
159159+ labels?: ComAtprotoLabelDefs.Label[]
160160+ record: { [_ in string]: unknown }
161161+ creator: AppBskyActorDefs.ProfileViewBasic
162162+ indexedAt: string
163163+ joinedWeekCount?: number
164164+ listItemsSample?: ListItemView[]
165165+ joinedAllTimeCount?: number
166166+}
167167+168168+const hashStarterPackView = 'starterPackView'
169169+170170+export function isStarterPackView<V>(v: V) {
171171+ return is$typed(v, id, hashStarterPackView)
172172+}
173173+174174+export function validateStarterPackView<V>(v: V) {
175175+ return validate<StarterPackView & V>(v, id, hashStarterPackView)
176176+}
177177+178178+export interface StarterPackViewBasic {
179179+ $type?: 'app.bsky.graph.defs#starterPackViewBasic'
180180+ cid: string
181181+ uri: string
182182+ labels?: ComAtprotoLabelDefs.Label[]
183183+ record: { [_ in string]: unknown }
184184+ creator: AppBskyActorDefs.ProfileViewBasic
185185+ indexedAt: string
186186+ listItemCount?: number
187187+ joinedWeekCount?: number
188188+ joinedAllTimeCount?: number
189189+}
190190+191191+const hashStarterPackViewBasic = 'starterPackViewBasic'
192192+193193+export function isStarterPackViewBasic<V>(v: V) {
194194+ return is$typed(v, id, hashStarterPackViewBasic)
195195+}
196196+197197+export function validateStarterPackViewBasic<V>(v: V) {
198198+ return validate<StarterPackViewBasic & V>(v, id, hashStarterPackViewBasic)
199199+}
+93
__generated__/types/app/bsky/labeler/defs.ts
···11+/**
22+ * GENERATED CODE - DO NOT MODIFY
33+ */
44+import { type ValidationResult, BlobRef } from "npm:@atproto/lexicon"
55+import { CID } from "npm:multiformats/cid"
66+import { validate as _validate } from '../../../../lexicons.ts'
77+import {
88+ type $Typed,
99+ is$typed as _is$typed,
1010+ type OmitKey,
1111+} from '../../../../util.ts'
1212+import type * as ComAtprotoLabelDefs from '../../../com/atproto/label/defs.ts'
1313+import type * as AppBskyActorDefs from '../actor/defs.ts'
1414+1515+const is$typed = _is$typed,
1616+ validate = _validate
1717+const id = 'app.bsky.labeler.defs'
1818+1919+export interface LabelerView {
2020+ $type?: 'app.bsky.labeler.defs#labelerView'
2121+ cid: string
2222+ uri: string
2323+ labels?: ComAtprotoLabelDefs.Label[]
2424+ viewer?: LabelerViewerState
2525+ creator: AppBskyActorDefs.ProfileView
2626+ indexedAt: string
2727+ likeCount?: number
2828+}
2929+3030+const hashLabelerView = 'labelerView'
3131+3232+export function isLabelerView<V>(v: V) {
3333+ return is$typed(v, id, hashLabelerView)
3434+}
3535+3636+export function validateLabelerView<V>(v: V) {
3737+ return validate<LabelerView & V>(v, id, hashLabelerView)
3838+}
3939+4040+export interface LabelerPolicies {
4141+ $type?: 'app.bsky.labeler.defs#labelerPolicies'
4242+ /** The label values which this labeler publishes. May include global or custom labels. */
4343+ labelValues: ComAtprotoLabelDefs.LabelValue[]
4444+ /** Label values created by this labeler and scoped exclusively to it. Labels defined here will override global label definitions for this labeler. */
4545+ labelValueDefinitions?: ComAtprotoLabelDefs.LabelValueDefinition[]
4646+}
4747+4848+const hashLabelerPolicies = 'labelerPolicies'
4949+5050+export function isLabelerPolicies<V>(v: V) {
5151+ return is$typed(v, id, hashLabelerPolicies)
5252+}
5353+5454+export function validateLabelerPolicies<V>(v: V) {
5555+ return validate<LabelerPolicies & V>(v, id, hashLabelerPolicies)
5656+}
5757+5858+export interface LabelerViewerState {
5959+ $type?: 'app.bsky.labeler.defs#labelerViewerState'
6060+ like?: string
6161+}
6262+6363+const hashLabelerViewerState = 'labelerViewerState'
6464+6565+export function isLabelerViewerState<V>(v: V) {
6666+ return is$typed(v, id, hashLabelerViewerState)
6767+}
6868+6969+export function validateLabelerViewerState<V>(v: V) {
7070+ return validate<LabelerViewerState & V>(v, id, hashLabelerViewerState)
7171+}
7272+7373+export interface LabelerViewDetailed {
7474+ $type?: 'app.bsky.labeler.defs#labelerViewDetailed'
7575+ cid: string
7676+ uri: string
7777+ labels?: ComAtprotoLabelDefs.Label[]
7878+ viewer?: LabelerViewerState
7979+ creator: AppBskyActorDefs.ProfileView
8080+ policies: LabelerPolicies
8181+ indexedAt: string
8282+ likeCount?: number
8383+}
8484+8585+const hashLabelerViewDetailed = 'labelerViewDetailed'
8686+8787+export function isLabelerViewDetailed<V>(v: V) {
8888+ return is$typed(v, id, hashLabelerViewDetailed)
8989+}
9090+9191+export function validateLabelerViewDetailed<V>(v: V) {
9292+ return validate<LabelerViewDetailed & V>(v, id, hashLabelerViewDetailed)
9393+}
+97
__generated__/types/app/bsky/richtext/facet.ts
···11+/**
22+ * GENERATED CODE - DO NOT MODIFY
33+ */
44+import { type ValidationResult, BlobRef } from "npm:@atproto/lexicon"
55+import { CID } from "npm:multiformats/cid"
66+import { validate as _validate } from '../../../../lexicons.ts'
77+import {
88+ type $Typed,
99+ is$typed as _is$typed,
1010+ type OmitKey,
1111+} from '../../../../util.ts'
1212+1313+const is$typed = _is$typed,
1414+ validate = _validate
1515+const id = 'app.bsky.richtext.facet'
1616+1717+/** Facet feature for a hashtag. The text usually includes a '#' prefix, but the facet reference should not (except in the case of 'double hash tags'). */
1818+export interface Tag {
1919+ $type?: 'app.bsky.richtext.facet#tag'
2020+ tag: string
2121+}
2222+2323+const hashTag = 'tag'
2424+2525+export function isTag<V>(v: V) {
2626+ return is$typed(v, id, hashTag)
2727+}
2828+2929+export function validateTag<V>(v: V) {
3030+ return validate<Tag & V>(v, id, hashTag)
3131+}
3232+3333+/** Facet feature for a URL. The text URL may have been simplified or truncated, but the facet reference should be a complete URL. */
3434+export interface Link {
3535+ $type?: 'app.bsky.richtext.facet#link'
3636+ uri: string
3737+}
3838+3939+const hashLink = 'link'
4040+4141+export function isLink<V>(v: V) {
4242+ return is$typed(v, id, hashLink)
4343+}
4444+4545+export function validateLink<V>(v: V) {
4646+ return validate<Link & V>(v, id, hashLink)
4747+}
4848+4949+/** Annotation of a sub-string within rich text. */
5050+export interface Main {
5151+ $type?: 'app.bsky.richtext.facet'
5252+ index: ByteSlice
5353+ features: ($Typed<Mention> | $Typed<Link> | $Typed<Tag> | { $type: string })[]
5454+}
5555+5656+const hashMain = 'main'
5757+5858+export function isMain<V>(v: V) {
5959+ return is$typed(v, id, hashMain)
6060+}
6161+6262+export function validateMain<V>(v: V) {
6363+ return validate<Main & V>(v, id, hashMain)
6464+}
6565+6666+/** Facet feature for mention of another account. The text is usually a handle, including a '@' prefix, but the facet reference is a DID. */
6767+export interface Mention {
6868+ $type?: 'app.bsky.richtext.facet#mention'
6969+ did: string
7070+}
7171+7272+const hashMention = 'mention'
7373+7474+export function isMention<V>(v: V) {
7575+ return is$typed(v, id, hashMention)
7676+}
7777+7878+export function validateMention<V>(v: V) {
7979+ return validate<Mention & V>(v, id, hashMention)
8080+}
8181+8282+/** Specifies the sub-string range a facet feature applies to. Start index is inclusive, end index is exclusive. Indices are zero-indexed, counting bytes of the UTF-8 encoded text. NOTE: some languages, like Javascript, use UTF-16 or Unicode codepoints for string slice indexing; in these languages, convert to byte arrays before working with facets. */
8383+export interface ByteSlice {
8484+ $type?: 'app.bsky.richtext.facet#byteSlice'
8585+ byteEnd: number
8686+ byteStart: number
8787+}
8888+8989+const hashByteSlice = 'byteSlice'
9090+9191+export function isByteSlice<V>(v: V) {
9292+ return is$typed(v, id, hashByteSlice)
9393+}
9494+9595+export function validateByteSlice<V>(v: V) {
9696+ return validate<ByteSlice & V>(v, id, hashByteSlice)
9797+}
+146
__generated__/types/com/atproto/label/defs.ts
···11+/**
22+ * GENERATED CODE - DO NOT MODIFY
33+ */
44+import { type ValidationResult, BlobRef } from "npm:@atproto/lexicon"
55+import { CID } from "npm:multiformats/cid"
66+import { validate as _validate } from '../../../../lexicons.ts'
77+import {
88+ type $Typed,
99+ is$typed as _is$typed,
1010+ type OmitKey,
1111+} from '../../../../util.ts'
1212+1313+const is$typed = _is$typed,
1414+ validate = _validate
1515+const id = 'com.atproto.label.defs'
1616+1717+/** Metadata tag on an atproto resource (eg, repo or record). */
1818+export interface Label {
1919+ $type?: 'com.atproto.label.defs#label'
2020+ /** Optionally, CID specifying the specific version of 'uri' resource this label applies to. */
2121+ cid?: string
2222+ /** Timestamp when this label was created. */
2323+ cts: string
2424+ /** Timestamp at which this label expires (no longer applies). */
2525+ exp?: string
2626+ /** If true, this is a negation label, overwriting a previous label. */
2727+ neg?: boolean
2828+ /** Signature of dag-cbor encoded label. */
2929+ sig?: Uint8Array
3030+ /** DID of the actor who created this label. */
3131+ src: string
3232+ /** AT URI of the record, repository (account), or other resource that this label applies to. */
3333+ uri: string
3434+ /** The short string name of the value or type of this label. */
3535+ val: string
3636+ /** The AT Protocol version of the label object. */
3737+ ver?: number
3838+}
3939+4040+const hashLabel = 'label'
4141+4242+export function isLabel<V>(v: V) {
4343+ return is$typed(v, id, hashLabel)
4444+}
4545+4646+export function validateLabel<V>(v: V) {
4747+ return validate<Label & V>(v, id, hashLabel)
4848+}
4949+5050+/** Metadata tag on an atproto record, published by the author within the record. Note that schemas should use #selfLabels, not #selfLabel. */
5151+export interface SelfLabel {
5252+ $type?: 'com.atproto.label.defs#selfLabel'
5353+ /** The short string name of the value or type of this label. */
5454+ val: string
5555+}
5656+5757+const hashSelfLabel = 'selfLabel'
5858+5959+export function isSelfLabel<V>(v: V) {
6060+ return is$typed(v, id, hashSelfLabel)
6161+}
6262+6363+export function validateSelfLabel<V>(v: V) {
6464+ return validate<SelfLabel & V>(v, id, hashSelfLabel)
6565+}
6666+6767+export type LabelValue =
6868+ | '!hide'
6969+ | '!no-promote'
7070+ | '!warn'
7171+ | '!no-unauthenticated'
7272+ | 'dmca-violation'
7373+ | 'doxxing'
7474+ | 'porn'
7575+ | 'sexual'
7676+ | 'nudity'
7777+ | 'nsfl'
7878+ | 'gore'
7979+ | (string & {})
8080+8181+/** Metadata tags on an atproto record, published by the author within the record. */
8282+export interface SelfLabels {
8383+ $type?: 'com.atproto.label.defs#selfLabels'
8484+ values: SelfLabel[]
8585+}
8686+8787+const hashSelfLabels = 'selfLabels'
8888+8989+export function isSelfLabels<V>(v: V) {
9090+ return is$typed(v, id, hashSelfLabels)
9191+}
9292+9393+export function validateSelfLabels<V>(v: V) {
9494+ return validate<SelfLabels & V>(v, id, hashSelfLabels)
9595+}
9696+9797+/** Declares a label value and its expected interpretations and behaviors. */
9898+export interface LabelValueDefinition {
9999+ $type?: 'com.atproto.label.defs#labelValueDefinition'
100100+ /** 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. */
101101+ blurs: 'content' | 'media' | 'none' | (string & {})
102102+ locales: LabelValueDefinitionStrings[]
103103+ /** How should a client visually convey this label? 'inform' means neutral and informational; 'alert' means negative and warning; 'none' means show nothing. */
104104+ severity: 'inform' | 'alert' | 'none' | (string & {})
105105+ /** Does the user need to have adult content enabled in order to configure this label? */
106106+ adultOnly?: boolean
107107+ /** The value of the label being defined. Must only include lowercase ascii and the '-' character ([a-z-]+). */
108108+ identifier: string
109109+ /** The default setting for this label. */
110110+ defaultSetting: 'ignore' | 'warn' | 'hide' | (string & {})
111111+}
112112+113113+const hashLabelValueDefinition = 'labelValueDefinition'
114114+115115+export function isLabelValueDefinition<V>(v: V) {
116116+ return is$typed(v, id, hashLabelValueDefinition)
117117+}
118118+119119+export function validateLabelValueDefinition<V>(v: V) {
120120+ return validate<LabelValueDefinition & V>(v, id, hashLabelValueDefinition)
121121+}
122122+123123+/** Strings which describe the label in the UI, localized into a specific language. */
124124+export interface LabelValueDefinitionStrings {
125125+ $type?: 'com.atproto.label.defs#labelValueDefinitionStrings'
126126+ /** The code of the language these strings are written in. */
127127+ lang: string
128128+ /** A short human-readable name for the label. */
129129+ name: string
130130+ /** A longer description of what the label means and why it might be applied. */
131131+ description: string
132132+}
133133+134134+const hashLabelValueDefinitionStrings = 'labelValueDefinitionStrings'
135135+136136+export function isLabelValueDefinitionStrings<V>(v: V) {
137137+ return is$typed(v, id, hashLabelValueDefinitionStrings)
138138+}
139139+140140+export function validateLabelValueDefinitionStrings<V>(v: V) {
141141+ return validate<LabelValueDefinitionStrings & V>(
142142+ v,
143143+ id,
144144+ hashLabelValueDefinitionStrings,
145145+ )
146146+}
+31
__generated__/types/com/atproto/repo/strongRef.ts
···11+/**
22+ * GENERATED CODE - DO NOT MODIFY
33+ */
44+import { type ValidationResult, BlobRef } from "npm:@atproto/lexicon"
55+import { CID } from "npm:multiformats/cid"
66+import { validate as _validate } from '../../../../lexicons.ts'
77+import {
88+ type $Typed,
99+ is$typed as _is$typed,
1010+ type OmitKey,
1111+} from '../../../../util.ts'
1212+1313+const is$typed = _is$typed,
1414+ validate = _validate
1515+const id = 'com.atproto.repo.strongRef'
1616+1717+export interface Main {
1818+ $type?: 'com.atproto.repo.strongRef'
1919+ cid: string
2020+ uri: string
2121+}
2222+2323+const hashMain = 'main'
2424+2525+export function isMain<V>(v: V) {
2626+ return is$typed(v, id, hashMain)
2727+}
2828+2929+export function validateMain<V>(v: V) {
3030+ return validate<Main & V>(v, id, hashMain)
3131+}
+35
__generated__/types/social/grain/v0/actor/defs.ts
···11+/**
22+ * GENERATED CODE - DO NOT MODIFY
33+ */
44+import { type ValidationResult, BlobRef } from "npm:@atproto/lexicon"
55+import { CID } from "npm:multiformats/cid"
66+import { validate as _validate } from '../../../../../lexicons.ts'
77+import {
88+ type $Typed,
99+ is$typed as _is$typed,
1010+ type OmitKey,
1111+} from '../../../../../util.ts'
1212+1313+const is$typed = _is$typed,
1414+ validate = _validate
1515+const id = 'social.grain.v0.actor.defs'
1616+1717+export interface ProfileView {
1818+ $type?: 'social.grain.v0.actor.defs#profileView'
1919+ did: string
2020+ handle: string
2121+ displayName?: string
2222+ description?: string
2323+ avatar?: string
2424+ createdAt?: string
2525+}
2626+2727+const hashProfileView = 'profileView'
2828+2929+export function isProfileView<V>(v: V) {
3030+ return is$typed(v, id, hashProfileView)
3131+}
3232+3333+export function validateProfileView<V>(v: V) {
3434+ return validate<ProfileView & V>(v, id, hashProfileView)
3535+}
···11+/**
22+ * GENERATED CODE - DO NOT MODIFY
33+ */
44+import { type ValidationResult, BlobRef } from "npm:@atproto/lexicon"
55+import { CID } from "npm:multiformats/cid"
66+import { validate as _validate } from '../../../../../lexicons.ts'
77+import {
88+ type $Typed,
99+ is$typed as _is$typed,
1010+ type OmitKey,
1111+} from '../../../../../util.ts'
1212+import type * as SocialGrainV0ActorDefs from '../actor/defs.ts'
1313+1414+const is$typed = _is$typed,
1515+ validate = _validate
1616+const id = 'social.grain.v0.gallery.defs'
1717+1818+/** width:height represents an aspect ratio. It may be approximate, and may not correspond to absolute dimensions in any given unit. */
1919+export interface AspectRatio {
2020+ $type?: 'social.grain.v0.gallery.defs#aspectRatio'
2121+ width: number
2222+ height: number
2323+}
2424+2525+const hashAspectRatio = 'aspectRatio'
2626+2727+export function isAspectRatio<V>(v: V) {
2828+ return is$typed(v, id, hashAspectRatio)
2929+}
3030+3131+export function validateAspectRatio<V>(v: V) {
3232+ return validate<AspectRatio & V>(v, id, hashAspectRatio)
3333+}
3434+3535+export interface GalleryView {
3636+ $type?: 'social.grain.v0.gallery.defs#galleryView'
3737+ uri: string
3838+ cid: string
3939+ creator: SocialGrainV0ActorDefs.ProfileView
4040+ record: { [_ in string]: unknown }
4141+ images?: ViewImage[]
4242+ indexedAt: string
4343+}
4444+4545+const hashGalleryView = 'galleryView'
4646+4747+export function isGalleryView<V>(v: V) {
4848+ return is$typed(v, id, hashGalleryView)
4949+}
5050+5151+export function validateGalleryView<V>(v: V) {
5252+ return validate<GalleryView & V>(v, id, hashGalleryView)
5353+}
5454+5555+export interface Image {
5656+ $type?: 'social.grain.v0.gallery.defs#image'
5757+ image: BlobRef
5858+ /** Alt text description of the image, for accessibility. */
5959+ alt: string
6060+ aspectRatio?: AspectRatio
6161+}
6262+6363+const hashImage = 'image'
6464+6565+export function isImage<V>(v: V) {
6666+ return is$typed(v, id, hashImage)
6767+}
6868+6969+export function validateImage<V>(v: V) {
7070+ return validate<Image & V>(v, id, hashImage)
7171+}
7272+7373+export interface ViewImage {
7474+ $type?: 'social.grain.v0.gallery.defs#viewImage'
7575+ cid: string
7676+ /** Fully-qualified URL where a thumbnail of the image can be fetched. For example, CDN location provided by the App View. */
7777+ thumb: string
7878+ /** Fully-qualified URL where a large version of the image can be fetched. May or may not be the exact original blob. For example, CDN location provided by the App View. */
7979+ fullsize: string
8080+ /** Alt text description of the image, for accessibility. */
8181+ alt: string
8282+ aspectRatio?: AspectRatio
8383+}
8484+8585+const hashViewImage = 'viewImage'
8686+8787+export function isViewImage<V>(v: V) {
8888+ return is$typed(v, id, hashViewImage)
8989+}
9090+9191+export function validateViewImage<V>(v: V) {
9292+ return validate<ViewImage & V>(v, id, hashViewImage)
9393+}
···11+{
22+ "lexicon": 1,
33+ "id": "app.bsky.feed.postgate",
44+ "defs": {
55+ "main": {
66+ "key": "tid",
77+ "type": "record",
88+ "record": {
99+ "type": "object",
1010+ "required": [
1111+ "post",
1212+ "createdAt"
1313+ ],
1414+ "properties": {
1515+ "post": {
1616+ "type": "string",
1717+ "format": "at-uri",
1818+ "description": "Reference (AT-URI) to the post record."
1919+ },
2020+ "createdAt": {
2121+ "type": "string",
2222+ "format": "datetime"
2323+ },
2424+ "embeddingRules": {
2525+ "type": "array",
2626+ "items": {
2727+ "refs": [
2828+ "#disableRule"
2929+ ],
3030+ "type": "union"
3131+ },
3232+ "maxLength": 5,
3333+ "description": "List of rules defining who can embed this post. If value is an empty array or is undefined, no particular rules apply and anyone can embed."
3434+ },
3535+ "detachedEmbeddingUris": {
3636+ "type": "array",
3737+ "items": {
3838+ "type": "string",
3939+ "format": "at-uri"
4040+ },
4141+ "maxLength": 50,
4242+ "description": "List of AT-URIs embedding this post that the author has detached from."
4343+ }
4444+ }
4545+ },
4646+ "description": "Record defining interaction rules for a post. The record key (rkey) of the postgate record must match the record key of the post, and that record must be in the same repository."
4747+ },
4848+ "disableRule": {
4949+ "type": "object",
5050+ "properties": {},
5151+ "description": "Disables embedding of this post."
5252+ }
5353+ }
5454+}
+80
lexicons/app/bsky/feed/threadgate.json
···11+{
22+ "lexicon": 1,
33+ "id": "app.bsky.feed.threadgate",
44+ "defs": {
55+ "main": {
66+ "key": "tid",
77+ "type": "record",
88+ "record": {
99+ "type": "object",
1010+ "required": [
1111+ "post",
1212+ "createdAt"
1313+ ],
1414+ "properties": {
1515+ "post": {
1616+ "type": "string",
1717+ "format": "at-uri",
1818+ "description": "Reference (AT-URI) to the post record."
1919+ },
2020+ "allow": {
2121+ "type": "array",
2222+ "items": {
2323+ "refs": [
2424+ "#mentionRule",
2525+ "#followerRule",
2626+ "#followingRule",
2727+ "#listRule"
2828+ ],
2929+ "type": "union"
3030+ },
3131+ "maxLength": 5,
3232+ "description": "List of rules defining who can reply to this post. If value is an empty array, no one can reply. If value is undefined, anyone can reply."
3333+ },
3434+ "createdAt": {
3535+ "type": "string",
3636+ "format": "datetime"
3737+ },
3838+ "hiddenReplies": {
3939+ "type": "array",
4040+ "items": {
4141+ "type": "string",
4242+ "format": "at-uri"
4343+ },
4444+ "maxLength": 50,
4545+ "description": "List of hidden reply URIs."
4646+ }
4747+ }
4848+ },
4949+ "description": "Record defining interaction gating rules for a thread (aka, reply controls). The record key (rkey) of the threadgate record must match the record key of the thread's root post, and that record must be in the same repository."
5050+ },
5151+ "listRule": {
5252+ "type": "object",
5353+ "required": [
5454+ "list"
5555+ ],
5656+ "properties": {
5757+ "list": {
5858+ "type": "string",
5959+ "format": "at-uri"
6060+ }
6161+ },
6262+ "description": "Allow replies from actors on a list."
6363+ },
6464+ "mentionRule": {
6565+ "type": "object",
6666+ "properties": {},
6767+ "description": "Allow replies from actors mentioned in your post."
6868+ },
6969+ "followerRule": {
7070+ "type": "object",
7171+ "properties": {},
7272+ "description": "Allow replies from actors who follow you."
7373+ },
7474+ "followingRule": {
7575+ "type": "object",
7676+ "properties": {},
7777+ "description": "Allow replies from actors you follow."
7878+ }
7979+ }
8080+}
···11+{
22+ "lexicon": 1,
33+ "id": "app.bsky.richtext.facet",
44+ "defs": {
55+ "tag": {
66+ "type": "object",
77+ "required": [
88+ "tag"
99+ ],
1010+ "properties": {
1111+ "tag": {
1212+ "type": "string",
1313+ "maxLength": 640,
1414+ "maxGraphemes": 64
1515+ }
1616+ },
1717+ "description": "Facet feature for a hashtag. The text usually includes a '#' prefix, but the facet reference should not (except in the case of 'double hash tags')."
1818+ },
1919+ "link": {
2020+ "type": "object",
2121+ "required": [
2222+ "uri"
2323+ ],
2424+ "properties": {
2525+ "uri": {
2626+ "type": "string",
2727+ "format": "uri"
2828+ }
2929+ },
3030+ "description": "Facet feature for a URL. The text URL may have been simplified or truncated, but the facet reference should be a complete URL."
3131+ },
3232+ "main": {
3333+ "type": "object",
3434+ "required": [
3535+ "index",
3636+ "features"
3737+ ],
3838+ "properties": {
3939+ "index": {
4040+ "ref": "#byteSlice",
4141+ "type": "ref"
4242+ },
4343+ "features": {
4444+ "type": "array",
4545+ "items": {
4646+ "refs": [
4747+ "#mention",
4848+ "#link",
4949+ "#tag"
5050+ ],
5151+ "type": "union"
5252+ }
5353+ }
5454+ },
5555+ "description": "Annotation of a sub-string within rich text."
5656+ },
5757+ "mention": {
5858+ "type": "object",
5959+ "required": [
6060+ "did"
6161+ ],
6262+ "properties": {
6363+ "did": {
6464+ "type": "string",
6565+ "format": "did"
6666+ }
6767+ },
6868+ "description": "Facet feature for mention of another account. The text is usually a handle, including a '@' prefix, but the facet reference is a DID."
6969+ },
7070+ "byteSlice": {
7171+ "type": "object",
7272+ "required": [
7373+ "byteStart",
7474+ "byteEnd"
7575+ ],
7676+ "properties": {
7777+ "byteEnd": {
7878+ "type": "integer",
7979+ "minimum": 0
8080+ },
8181+ "byteStart": {
8282+ "type": "integer",
8383+ "minimum": 0
8484+ }
8585+ },
8686+ "description": "Specifies the sub-string range a facet feature applies to. Start index is inclusive, end index is exclusive. Indices are zero-indexed, counting bytes of the UTF-8 encoded text. NOTE: some languages, like Javascript, use UTF-16 or Unicode codepoints for string slice indexing; in these languages, convert to byte arrays before working with facets."
8787+ }
8888+ }
8989+}
+192
lexicons/com/atproto/label/defs.json
···11+{
22+ "lexicon": 1,
33+ "id": "com.atproto.label.defs",
44+ "defs": {
55+ "label": {
66+ "type": "object",
77+ "required": [
88+ "src",
99+ "uri",
1010+ "val",
1111+ "cts"
1212+ ],
1313+ "properties": {
1414+ "cid": {
1515+ "type": "string",
1616+ "format": "cid",
1717+ "description": "Optionally, CID specifying the specific version of 'uri' resource this label applies to."
1818+ },
1919+ "cts": {
2020+ "type": "string",
2121+ "format": "datetime",
2222+ "description": "Timestamp when this label was created."
2323+ },
2424+ "exp": {
2525+ "type": "string",
2626+ "format": "datetime",
2727+ "description": "Timestamp at which this label expires (no longer applies)."
2828+ },
2929+ "neg": {
3030+ "type": "boolean",
3131+ "description": "If true, this is a negation label, overwriting a previous label."
3232+ },
3333+ "sig": {
3434+ "type": "bytes",
3535+ "description": "Signature of dag-cbor encoded label."
3636+ },
3737+ "src": {
3838+ "type": "string",
3939+ "format": "did",
4040+ "description": "DID of the actor who created this label."
4141+ },
4242+ "uri": {
4343+ "type": "string",
4444+ "format": "uri",
4545+ "description": "AT URI of the record, repository (account), or other resource that this label applies to."
4646+ },
4747+ "val": {
4848+ "type": "string",
4949+ "maxLength": 128,
5050+ "description": "The short string name of the value or type of this label."
5151+ },
5252+ "ver": {
5353+ "type": "integer",
5454+ "description": "The AT Protocol version of the label object."
5555+ }
5656+ },
5757+ "description": "Metadata tag on an atproto resource (eg, repo or record)."
5858+ },
5959+ "selfLabel": {
6060+ "type": "object",
6161+ "required": [
6262+ "val"
6363+ ],
6464+ "properties": {
6565+ "val": {
6666+ "type": "string",
6767+ "maxLength": 128,
6868+ "description": "The short string name of the value or type of this label."
6969+ }
7070+ },
7171+ "description": "Metadata tag on an atproto record, published by the author within the record. Note that schemas should use #selfLabels, not #selfLabel."
7272+ },
7373+ "labelValue": {
7474+ "type": "string",
7575+ "knownValues": [
7676+ "!hide",
7777+ "!no-promote",
7878+ "!warn",
7979+ "!no-unauthenticated",
8080+ "dmca-violation",
8181+ "doxxing",
8282+ "porn",
8383+ "sexual",
8484+ "nudity",
8585+ "nsfl",
8686+ "gore"
8787+ ]
8888+ },
8989+ "selfLabels": {
9090+ "type": "object",
9191+ "required": [
9292+ "values"
9393+ ],
9494+ "properties": {
9595+ "values": {
9696+ "type": "array",
9797+ "items": {
9898+ "ref": "#selfLabel",
9999+ "type": "ref"
100100+ },
101101+ "maxLength": 10
102102+ }
103103+ },
104104+ "description": "Metadata tags on an atproto record, published by the author within the record."
105105+ },
106106+ "labelValueDefinition": {
107107+ "type": "object",
108108+ "required": [
109109+ "identifier",
110110+ "severity",
111111+ "blurs",
112112+ "locales"
113113+ ],
114114+ "properties": {
115115+ "blurs": {
116116+ "type": "string",
117117+ "description": "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.",
118118+ "knownValues": [
119119+ "content",
120120+ "media",
121121+ "none"
122122+ ]
123123+ },
124124+ "locales": {
125125+ "type": "array",
126126+ "items": {
127127+ "ref": "#labelValueDefinitionStrings",
128128+ "type": "ref"
129129+ }
130130+ },
131131+ "severity": {
132132+ "type": "string",
133133+ "description": "How should a client visually convey this label? 'inform' means neutral and informational; 'alert' means negative and warning; 'none' means show nothing.",
134134+ "knownValues": [
135135+ "inform",
136136+ "alert",
137137+ "none"
138138+ ]
139139+ },
140140+ "adultOnly": {
141141+ "type": "boolean",
142142+ "description": "Does the user need to have adult content enabled in order to configure this label?"
143143+ },
144144+ "identifier": {
145145+ "type": "string",
146146+ "maxLength": 100,
147147+ "description": "The value of the label being defined. Must only include lowercase ascii and the '-' character ([a-z-]+).",
148148+ "maxGraphemes": 100
149149+ },
150150+ "defaultSetting": {
151151+ "type": "string",
152152+ "default": "warn",
153153+ "description": "The default setting for this label.",
154154+ "knownValues": [
155155+ "ignore",
156156+ "warn",
157157+ "hide"
158158+ ]
159159+ }
160160+ },
161161+ "description": "Declares a label value and its expected interpretations and behaviors."
162162+ },
163163+ "labelValueDefinitionStrings": {
164164+ "type": "object",
165165+ "required": [
166166+ "lang",
167167+ "name",
168168+ "description"
169169+ ],
170170+ "properties": {
171171+ "lang": {
172172+ "type": "string",
173173+ "format": "language",
174174+ "description": "The code of the language these strings are written in."
175175+ },
176176+ "name": {
177177+ "type": "string",
178178+ "maxLength": 640,
179179+ "description": "A short human-readable name for the label.",
180180+ "maxGraphemes": 64
181181+ },
182182+ "description": {
183183+ "type": "string",
184184+ "maxLength": 100000,
185185+ "description": "A longer description of what the label means and why it might be applied.",
186186+ "maxGraphemes": 10000
187187+ }
188188+ },
189189+ "description": "Strings which describe the label in the UI, localized into a specific language."
190190+ }
191191+ }
192192+}
···11+# The fuse section describes settings for the FUSE file system. This file system
22+# is used as a thin layer between the SQLite client in your application and the
33+# storage on disk. It intercepts disk writes to determine transaction boundaries
44+# so that those transactions can be saved and shipped to replicas.
55+fuse:
66+ dir: "/litefs"
77+88+# The data section describes settings for the internal LiteFS storage. We'll
99+# mount a volume to the data directory so it can be persisted across restarts.
1010+# However, this data should not be accessed directly by the user application.
1111+data:
1212+ dir: "/var/lib/litefs"
1313+1414+# This flag ensure that LiteFS continues to run if there is an issue on starup.
1515+# It makes it easy to ssh in and debug any issues you might be having rather
1616+# than continually restarting on initialization failure.
1717+exit-on-error: false
1818+1919+# This section defines settings for the option HTTP proxy.
2020+# This proxy can handle primary forwarding & replica consistency
2121+# for applications that use a single SQLite database.
2222+proxy:
2323+ addr: ":8080"
2424+ target: "localhost:8081"
2525+ db: "sqlite.db"
2626+ passthrough:
2727+ - "*.ico"
2828+ - "*.png"
2929+3030+# This section defines a list of commands to run after LiteFS has connected
3131+# and sync'd with the cluster. You can run multiple commands but LiteFS expects
3232+# the last command to be long-running (e.g. an application server). When the
3333+# last command exits, LiteFS is shut down.
3434+exec:
3535+ - cmd: "deno run -A --unstable-kv --unstable-ffi main.tsx"
3636+3737+# The lease section specifies how the cluster will be managed. We're using the
3838+# "consul" lease type so that our application can dynamically change the primary.
3939+#
4040+# These environment variables will be available in your Fly.io application.
4141+lease:
4242+ type: "consul"
4343+ advertise-url: "http://${HOSTNAME}.vm.${FLY_APP_NAME}.internal:20202"
4444+ candidate: ${FLY_REGION == PRIMARY_REGION}
4545+ promote: true
4646+4747+ consul:
4848+ url: "${FLY_CONSUL_URL}"
4949+ key: "litefs/${FLY_APP_NAME}-v1"