an attempt to make a lightweight, easily self-hostable, scoped bluesky appview
1/**
2 * GENERATED CODE - DO NOT MODIFY
3 */
4import {
5 type LexiconDoc,
6 Lexicons,
7 ValidationError,
8 type ValidationResult,
9} from 'npm:@atproto/lexicon'
10import { type $Typed, is$typed, maybe$typed } from './util.ts'
11
12export const schemaDict = {
13 AppBskyActorDefs: {
14 lexicon: 1,
15 id: 'app.bsky.actor.defs',
16 defs: {
17 profileViewBasic: {
18 type: 'object',
19 required: ['did', 'handle'],
20 properties: {
21 did: {
22 type: 'string',
23 format: 'did',
24 },
25 handle: {
26 type: 'string',
27 format: 'handle',
28 },
29 displayName: {
30 type: 'string',
31 maxGraphemes: 64,
32 maxLength: 640,
33 },
34 avatar: {
35 type: 'string',
36 format: 'uri',
37 },
38 associated: {
39 type: 'ref',
40 ref: 'lex:app.bsky.actor.defs#profileAssociated',
41 },
42 viewer: {
43 type: 'ref',
44 ref: 'lex:app.bsky.actor.defs#viewerState',
45 },
46 labels: {
47 type: 'array',
48 items: {
49 type: 'ref',
50 ref: 'lex:com.atproto.label.defs#label',
51 },
52 },
53 createdAt: {
54 type: 'string',
55 format: 'datetime',
56 },
57 verification: {
58 type: 'ref',
59 ref: 'lex:app.bsky.actor.defs#verificationState',
60 },
61 status: {
62 type: 'ref',
63 ref: 'lex:app.bsky.actor.defs#statusView',
64 },
65 },
66 },
67 profileView: {
68 type: 'object',
69 required: ['did', 'handle'],
70 properties: {
71 did: {
72 type: 'string',
73 format: 'did',
74 },
75 handle: {
76 type: 'string',
77 format: 'handle',
78 },
79 displayName: {
80 type: 'string',
81 maxGraphemes: 64,
82 maxLength: 640,
83 },
84 description: {
85 type: 'string',
86 maxGraphemes: 256,
87 maxLength: 2560,
88 },
89 avatar: {
90 type: 'string',
91 format: 'uri',
92 },
93 associated: {
94 type: 'ref',
95 ref: 'lex:app.bsky.actor.defs#profileAssociated',
96 },
97 indexedAt: {
98 type: 'string',
99 format: 'datetime',
100 },
101 createdAt: {
102 type: 'string',
103 format: 'datetime',
104 },
105 viewer: {
106 type: 'ref',
107 ref: 'lex:app.bsky.actor.defs#viewerState',
108 },
109 labels: {
110 type: 'array',
111 items: {
112 type: 'ref',
113 ref: 'lex:com.atproto.label.defs#label',
114 },
115 },
116 verification: {
117 type: 'ref',
118 ref: 'lex:app.bsky.actor.defs#verificationState',
119 },
120 status: {
121 type: 'ref',
122 ref: 'lex:app.bsky.actor.defs#statusView',
123 },
124 },
125 },
126 profileViewDetailed: {
127 type: 'object',
128 required: ['did', 'handle'],
129 properties: {
130 did: {
131 type: 'string',
132 format: 'did',
133 },
134 handle: {
135 type: 'string',
136 format: 'handle',
137 },
138 displayName: {
139 type: 'string',
140 maxGraphemes: 64,
141 maxLength: 640,
142 },
143 description: {
144 type: 'string',
145 maxGraphemes: 256,
146 maxLength: 2560,
147 },
148 avatar: {
149 type: 'string',
150 format: 'uri',
151 },
152 banner: {
153 type: 'string',
154 format: 'uri',
155 },
156 followersCount: {
157 type: 'integer',
158 },
159 followsCount: {
160 type: 'integer',
161 },
162 postsCount: {
163 type: 'integer',
164 },
165 associated: {
166 type: 'ref',
167 ref: 'lex:app.bsky.actor.defs#profileAssociated',
168 },
169 joinedViaStarterPack: {
170 type: 'ref',
171 ref: 'lex:app.bsky.graph.defs#starterPackViewBasic',
172 },
173 indexedAt: {
174 type: 'string',
175 format: 'datetime',
176 },
177 createdAt: {
178 type: 'string',
179 format: 'datetime',
180 },
181 viewer: {
182 type: 'ref',
183 ref: 'lex:app.bsky.actor.defs#viewerState',
184 },
185 labels: {
186 type: 'array',
187 items: {
188 type: 'ref',
189 ref: 'lex:com.atproto.label.defs#label',
190 },
191 },
192 pinnedPost: {
193 type: 'ref',
194 ref: 'lex:com.atproto.repo.strongRef',
195 },
196 verification: {
197 type: 'ref',
198 ref: 'lex:app.bsky.actor.defs#verificationState',
199 },
200 status: {
201 type: 'ref',
202 ref: 'lex:app.bsky.actor.defs#statusView',
203 },
204 },
205 },
206 profileAssociated: {
207 type: 'object',
208 properties: {
209 lists: {
210 type: 'integer',
211 },
212 feedgens: {
213 type: 'integer',
214 },
215 starterPacks: {
216 type: 'integer',
217 },
218 labeler: {
219 type: 'boolean',
220 },
221 chat: {
222 type: 'ref',
223 ref: 'lex:app.bsky.actor.defs#profileAssociatedChat',
224 },
225 activitySubscription: {
226 type: 'ref',
227 ref: 'lex:app.bsky.actor.defs#profileAssociatedActivitySubscription',
228 },
229 },
230 },
231 profileAssociatedChat: {
232 type: 'object',
233 required: ['allowIncoming'],
234 properties: {
235 allowIncoming: {
236 type: 'string',
237 knownValues: ['all', 'none', 'following'],
238 },
239 },
240 },
241 profileAssociatedActivitySubscription: {
242 type: 'object',
243 required: ['allowSubscriptions'],
244 properties: {
245 allowSubscriptions: {
246 type: 'string',
247 knownValues: ['followers', 'mutuals', 'none'],
248 },
249 },
250 },
251 viewerState: {
252 type: 'object',
253 description:
254 "Metadata about the requesting account's relationship with the subject account. Only has meaningful content for authed requests.",
255 properties: {
256 muted: {
257 type: 'boolean',
258 },
259 mutedByList: {
260 type: 'ref',
261 ref: 'lex:app.bsky.graph.defs#listViewBasic',
262 },
263 blockedBy: {
264 type: 'boolean',
265 },
266 blocking: {
267 type: 'string',
268 format: 'at-uri',
269 },
270 blockingByList: {
271 type: 'ref',
272 ref: 'lex:app.bsky.graph.defs#listViewBasic',
273 },
274 following: {
275 type: 'string',
276 format: 'at-uri',
277 },
278 followedBy: {
279 type: 'string',
280 format: 'at-uri',
281 },
282 knownFollowers: {
283 description:
284 'This property is present only in selected cases, as an optimization.',
285 type: 'ref',
286 ref: 'lex:app.bsky.actor.defs#knownFollowers',
287 },
288 activitySubscription: {
289 description:
290 'This property is present only in selected cases, as an optimization.',
291 type: 'ref',
292 ref: 'lex:app.bsky.notification.defs#activitySubscription',
293 },
294 },
295 },
296 knownFollowers: {
297 type: 'object',
298 description: "The subject's followers whom you also follow",
299 required: ['count', 'followers'],
300 properties: {
301 count: {
302 type: 'integer',
303 },
304 followers: {
305 type: 'array',
306 minLength: 0,
307 maxLength: 5,
308 items: {
309 type: 'ref',
310 ref: 'lex:app.bsky.actor.defs#profileViewBasic',
311 },
312 },
313 },
314 },
315 verificationState: {
316 type: 'object',
317 description:
318 'Represents the verification information about the user this object is attached to.',
319 required: ['verifications', 'verifiedStatus', 'trustedVerifierStatus'],
320 properties: {
321 verifications: {
322 type: 'array',
323 description:
324 'All verifications issued by trusted verifiers on behalf of this user. Verifications by untrusted verifiers are not included.',
325 items: {
326 type: 'ref',
327 ref: 'lex:app.bsky.actor.defs#verificationView',
328 },
329 },
330 verifiedStatus: {
331 type: 'string',
332 description: "The user's status as a verified account.",
333 knownValues: ['valid', 'invalid', 'none'],
334 },
335 trustedVerifierStatus: {
336 type: 'string',
337 description: "The user's status as a trusted verifier.",
338 knownValues: ['valid', 'invalid', 'none'],
339 },
340 },
341 },
342 verificationView: {
343 type: 'object',
344 description: 'An individual verification for an associated subject.',
345 required: ['issuer', 'uri', 'isValid', 'createdAt'],
346 properties: {
347 issuer: {
348 type: 'string',
349 description: 'The user who issued this verification.',
350 format: 'did',
351 },
352 uri: {
353 type: 'string',
354 description: 'The AT-URI of the verification record.',
355 format: 'at-uri',
356 },
357 isValid: {
358 type: 'boolean',
359 description:
360 'True if the verification passes validation, otherwise false.',
361 },
362 createdAt: {
363 type: 'string',
364 description: 'Timestamp when the verification was created.',
365 format: 'datetime',
366 },
367 },
368 },
369 preferences: {
370 type: 'array',
371 items: {
372 type: 'union',
373 refs: [
374 'lex:app.bsky.actor.defs#adultContentPref',
375 'lex:app.bsky.actor.defs#contentLabelPref',
376 'lex:app.bsky.actor.defs#savedFeedsPref',
377 'lex:app.bsky.actor.defs#savedFeedsPrefV2',
378 'lex:app.bsky.actor.defs#personalDetailsPref',
379 'lex:app.bsky.actor.defs#feedViewPref',
380 'lex:app.bsky.actor.defs#threadViewPref',
381 'lex:app.bsky.actor.defs#interestsPref',
382 'lex:app.bsky.actor.defs#mutedWordsPref',
383 'lex:app.bsky.actor.defs#hiddenPostsPref',
384 'lex:app.bsky.actor.defs#bskyAppStatePref',
385 'lex:app.bsky.actor.defs#labelersPref',
386 'lex:app.bsky.actor.defs#postInteractionSettingsPref',
387 'lex:app.bsky.actor.defs#verificationPrefs',
388 ],
389 },
390 },
391 adultContentPref: {
392 type: 'object',
393 required: ['enabled'],
394 properties: {
395 enabled: {
396 type: 'boolean',
397 default: false,
398 },
399 },
400 },
401 contentLabelPref: {
402 type: 'object',
403 required: ['label', 'visibility'],
404 properties: {
405 labelerDid: {
406 type: 'string',
407 description:
408 'Which labeler does this preference apply to? If undefined, applies globally.',
409 format: 'did',
410 },
411 label: {
412 type: 'string',
413 },
414 visibility: {
415 type: 'string',
416 knownValues: ['ignore', 'show', 'warn', 'hide'],
417 },
418 },
419 },
420 savedFeed: {
421 type: 'object',
422 required: ['id', 'type', 'value', 'pinned'],
423 properties: {
424 id: {
425 type: 'string',
426 },
427 type: {
428 type: 'string',
429 knownValues: ['feed', 'list', 'timeline'],
430 },
431 value: {
432 type: 'string',
433 },
434 pinned: {
435 type: 'boolean',
436 },
437 },
438 },
439 savedFeedsPrefV2: {
440 type: 'object',
441 required: ['items'],
442 properties: {
443 items: {
444 type: 'array',
445 items: {
446 type: 'ref',
447 ref: 'lex:app.bsky.actor.defs#savedFeed',
448 },
449 },
450 },
451 },
452 savedFeedsPref: {
453 type: 'object',
454 required: ['pinned', 'saved'],
455 properties: {
456 pinned: {
457 type: 'array',
458 items: {
459 type: 'string',
460 format: 'at-uri',
461 },
462 },
463 saved: {
464 type: 'array',
465 items: {
466 type: 'string',
467 format: 'at-uri',
468 },
469 },
470 timelineIndex: {
471 type: 'integer',
472 },
473 },
474 },
475 personalDetailsPref: {
476 type: 'object',
477 properties: {
478 birthDate: {
479 type: 'string',
480 format: 'datetime',
481 description: 'The birth date of account owner.',
482 },
483 },
484 },
485 feedViewPref: {
486 type: 'object',
487 required: ['feed'],
488 properties: {
489 feed: {
490 type: 'string',
491 description:
492 'The URI of the feed, or an identifier which describes the feed.',
493 },
494 hideReplies: {
495 type: 'boolean',
496 description: 'Hide replies in the feed.',
497 },
498 hideRepliesByUnfollowed: {
499 type: 'boolean',
500 description:
501 'Hide replies in the feed if they are not by followed users.',
502 default: true,
503 },
504 hideRepliesByLikeCount: {
505 type: 'integer',
506 description:
507 'Hide replies in the feed if they do not have this number of likes.',
508 },
509 hideReposts: {
510 type: 'boolean',
511 description: 'Hide reposts in the feed.',
512 },
513 hideQuotePosts: {
514 type: 'boolean',
515 description: 'Hide quote posts in the feed.',
516 },
517 },
518 },
519 threadViewPref: {
520 type: 'object',
521 properties: {
522 sort: {
523 type: 'string',
524 description: 'Sorting mode for threads.',
525 knownValues: [
526 'oldest',
527 'newest',
528 'most-likes',
529 'random',
530 'hotness',
531 ],
532 },
533 prioritizeFollowedUsers: {
534 type: 'boolean',
535 description: 'Show followed users at the top of all replies.',
536 },
537 },
538 },
539 interestsPref: {
540 type: 'object',
541 required: ['tags'],
542 properties: {
543 tags: {
544 type: 'array',
545 maxLength: 100,
546 items: {
547 type: 'string',
548 maxLength: 640,
549 maxGraphemes: 64,
550 },
551 description:
552 "A list of tags which describe the account owner's interests gathered during onboarding.",
553 },
554 },
555 },
556 mutedWordTarget: {
557 type: 'string',
558 knownValues: ['content', 'tag'],
559 maxLength: 640,
560 maxGraphemes: 64,
561 },
562 mutedWord: {
563 type: 'object',
564 description: 'A word that the account owner has muted.',
565 required: ['value', 'targets'],
566 properties: {
567 id: {
568 type: 'string',
569 },
570 value: {
571 type: 'string',
572 description: 'The muted word itself.',
573 maxLength: 10000,
574 maxGraphemes: 1000,
575 },
576 targets: {
577 type: 'array',
578 description: 'The intended targets of the muted word.',
579 items: {
580 type: 'ref',
581 ref: 'lex:app.bsky.actor.defs#mutedWordTarget',
582 },
583 },
584 actorTarget: {
585 type: 'string',
586 description:
587 'Groups of users to apply the muted word to. If undefined, applies to all users.',
588 knownValues: ['all', 'exclude-following'],
589 default: 'all',
590 },
591 expiresAt: {
592 type: 'string',
593 format: 'datetime',
594 description:
595 'The date and time at which the muted word will expire and no longer be applied.',
596 },
597 },
598 },
599 mutedWordsPref: {
600 type: 'object',
601 required: ['items'],
602 properties: {
603 items: {
604 type: 'array',
605 items: {
606 type: 'ref',
607 ref: 'lex:app.bsky.actor.defs#mutedWord',
608 },
609 description: 'A list of words the account owner has muted.',
610 },
611 },
612 },
613 hiddenPostsPref: {
614 type: 'object',
615 required: ['items'],
616 properties: {
617 items: {
618 type: 'array',
619 items: {
620 type: 'string',
621 format: 'at-uri',
622 },
623 description:
624 'A list of URIs of posts the account owner has hidden.',
625 },
626 },
627 },
628 labelersPref: {
629 type: 'object',
630 required: ['labelers'],
631 properties: {
632 labelers: {
633 type: 'array',
634 items: {
635 type: 'ref',
636 ref: 'lex:app.bsky.actor.defs#labelerPrefItem',
637 },
638 },
639 },
640 },
641 labelerPrefItem: {
642 type: 'object',
643 required: ['did'],
644 properties: {
645 did: {
646 type: 'string',
647 format: 'did',
648 },
649 },
650 },
651 bskyAppStatePref: {
652 description:
653 "A grab bag of state that's specific to the bsky.app program. Third-party apps shouldn't use this.",
654 type: 'object',
655 properties: {
656 activeProgressGuide: {
657 type: 'ref',
658 ref: 'lex:app.bsky.actor.defs#bskyAppProgressGuide',
659 },
660 queuedNudges: {
661 description:
662 'An array of tokens which identify nudges (modals, popups, tours, highlight dots) that should be shown to the user.',
663 type: 'array',
664 maxLength: 1000,
665 items: {
666 type: 'string',
667 maxLength: 100,
668 },
669 },
670 nuxs: {
671 description: 'Storage for NUXs the user has encountered.',
672 type: 'array',
673 maxLength: 100,
674 items: {
675 type: 'ref',
676 ref: 'lex:app.bsky.actor.defs#nux',
677 },
678 },
679 },
680 },
681 bskyAppProgressGuide: {
682 description:
683 'If set, an active progress guide. Once completed, can be set to undefined. Should have unspecced fields tracking progress.',
684 type: 'object',
685 required: ['guide'],
686 properties: {
687 guide: {
688 type: 'string',
689 maxLength: 100,
690 },
691 },
692 },
693 nux: {
694 type: 'object',
695 description: 'A new user experiences (NUX) storage object',
696 required: ['id', 'completed'],
697 properties: {
698 id: {
699 type: 'string',
700 maxLength: 100,
701 },
702 completed: {
703 type: 'boolean',
704 default: false,
705 },
706 data: {
707 description:
708 'Arbitrary data for the NUX. The structure is defined by the NUX itself. Limited to 300 characters.',
709 type: 'string',
710 maxLength: 3000,
711 maxGraphemes: 300,
712 },
713 expiresAt: {
714 type: 'string',
715 format: 'datetime',
716 description:
717 'The date and time at which the NUX will expire and should be considered completed.',
718 },
719 },
720 },
721 verificationPrefs: {
722 type: 'object',
723 description: 'Preferences for how verified accounts appear in the app.',
724 required: [],
725 properties: {
726 hideBadges: {
727 description:
728 'Hide the blue check badges for verified accounts and trusted verifiers.',
729 type: 'boolean',
730 default: false,
731 },
732 },
733 },
734 postInteractionSettingsPref: {
735 type: 'object',
736 description:
737 '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.',
738 required: [],
739 properties: {
740 threadgateAllowRules: {
741 description:
742 '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.',
743 type: 'array',
744 maxLength: 5,
745 items: {
746 type: 'union',
747 refs: [
748 'lex:app.bsky.feed.threadgate#mentionRule',
749 'lex:app.bsky.feed.threadgate#followerRule',
750 'lex:app.bsky.feed.threadgate#followingRule',
751 'lex:app.bsky.feed.threadgate#listRule',
752 ],
753 },
754 },
755 postgateEmbeddingRules: {
756 description:
757 '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.',
758 type: 'array',
759 maxLength: 5,
760 items: {
761 type: 'union',
762 refs: ['lex:app.bsky.feed.postgate#disableRule'],
763 },
764 },
765 },
766 },
767 statusView: {
768 type: 'object',
769 required: ['status', 'record'],
770 properties: {
771 status: {
772 type: 'string',
773 description: 'The status for the account.',
774 knownValues: ['app.bsky.actor.status#live'],
775 },
776 record: {
777 type: 'unknown',
778 },
779 embed: {
780 type: 'union',
781 description: 'An optional embed associated with the status.',
782 refs: ['lex:app.bsky.embed.external#view'],
783 },
784 expiresAt: {
785 type: 'string',
786 description:
787 'The date when this status will expire. The application might choose to no longer return the status after expiration.',
788 format: 'datetime',
789 },
790 isActive: {
791 type: 'boolean',
792 description:
793 'True if the status is not expired, false if it is expired. Only present if expiration was set.',
794 },
795 },
796 },
797 },
798 },
799 AppBskyActorGetProfile: {
800 lexicon: 1,
801 id: 'app.bsky.actor.getProfile',
802 defs: {
803 main: {
804 type: 'query',
805 description:
806 'Get detailed profile view of an actor. Does not require auth, but contains relevant metadata with auth.',
807 parameters: {
808 type: 'params',
809 required: ['actor'],
810 properties: {
811 actor: {
812 type: 'string',
813 format: 'at-identifier',
814 description: 'Handle or DID of account to fetch profile of.',
815 },
816 },
817 },
818 output: {
819 encoding: 'application/json',
820 schema: {
821 type: 'ref',
822 ref: 'lex:app.bsky.actor.defs#profileViewDetailed',
823 },
824 },
825 },
826 },
827 },
828 AppBskyActorGetProfiles: {
829 lexicon: 1,
830 id: 'app.bsky.actor.getProfiles',
831 defs: {
832 main: {
833 type: 'query',
834 description: 'Get detailed profile views of multiple actors.',
835 parameters: {
836 type: 'params',
837 required: ['actors'],
838 properties: {
839 actors: {
840 type: 'array',
841 items: {
842 type: 'string',
843 format: 'at-identifier',
844 },
845 maxLength: 25,
846 },
847 },
848 },
849 output: {
850 encoding: 'application/json',
851 schema: {
852 type: 'object',
853 required: ['profiles'],
854 properties: {
855 profiles: {
856 type: 'array',
857 items: {
858 type: 'ref',
859 ref: 'lex:app.bsky.actor.defs#profileViewDetailed',
860 },
861 },
862 },
863 },
864 },
865 },
866 },
867 },
868 AppBskyEmbedDefs: {
869 lexicon: 1,
870 id: 'app.bsky.embed.defs',
871 defs: {
872 aspectRatio: {
873 type: 'object',
874 description:
875 'width:height represents an aspect ratio. It may be approximate, and may not correspond to absolute dimensions in any given unit.',
876 required: ['width', 'height'],
877 properties: {
878 width: {
879 type: 'integer',
880 minimum: 1,
881 },
882 height: {
883 type: 'integer',
884 minimum: 1,
885 },
886 },
887 },
888 },
889 },
890 AppBskyEmbedExternal: {
891 lexicon: 1,
892 id: 'app.bsky.embed.external',
893 defs: {
894 main: {
895 type: 'object',
896 description:
897 "A representation of some externally linked content (eg, a URL and 'card'), embedded in a Bluesky record (eg, a post).",
898 required: ['external'],
899 properties: {
900 external: {
901 type: 'ref',
902 ref: 'lex:app.bsky.embed.external#external',
903 },
904 },
905 },
906 external: {
907 type: 'object',
908 required: ['uri', 'title', 'description'],
909 properties: {
910 uri: {
911 type: 'string',
912 format: 'uri',
913 },
914 title: {
915 type: 'string',
916 },
917 description: {
918 type: 'string',
919 },
920 thumb: {
921 type: 'blob',
922 accept: ['image/*'],
923 maxSize: 1000000,
924 },
925 },
926 },
927 view: {
928 type: 'object',
929 required: ['external'],
930 properties: {
931 external: {
932 type: 'ref',
933 ref: 'lex:app.bsky.embed.external#viewExternal',
934 },
935 },
936 },
937 viewExternal: {
938 type: 'object',
939 required: ['uri', 'title', 'description'],
940 properties: {
941 uri: {
942 type: 'string',
943 format: 'uri',
944 },
945 title: {
946 type: 'string',
947 },
948 description: {
949 type: 'string',
950 },
951 thumb: {
952 type: 'string',
953 format: 'uri',
954 },
955 },
956 },
957 },
958 },
959 AppBskyEmbedImages: {
960 lexicon: 1,
961 id: 'app.bsky.embed.images',
962 description: 'A set of images embedded in a Bluesky record (eg, a post).',
963 defs: {
964 main: {
965 type: 'object',
966 required: ['images'],
967 properties: {
968 images: {
969 type: 'array',
970 items: {
971 type: 'ref',
972 ref: 'lex:app.bsky.embed.images#image',
973 },
974 maxLength: 4,
975 },
976 },
977 },
978 image: {
979 type: 'object',
980 required: ['image', 'alt'],
981 properties: {
982 image: {
983 type: 'blob',
984 accept: ['image/*'],
985 maxSize: 1000000,
986 },
987 alt: {
988 type: 'string',
989 description:
990 'Alt text description of the image, for accessibility.',
991 },
992 aspectRatio: {
993 type: 'ref',
994 ref: 'lex:app.bsky.embed.defs#aspectRatio',
995 },
996 },
997 },
998 view: {
999 type: 'object',
1000 required: ['images'],
1001 properties: {
1002 images: {
1003 type: 'array',
1004 items: {
1005 type: 'ref',
1006 ref: 'lex:app.bsky.embed.images#viewImage',
1007 },
1008 maxLength: 4,
1009 },
1010 },
1011 },
1012 viewImage: {
1013 type: 'object',
1014 required: ['thumb', 'fullsize', 'alt'],
1015 properties: {
1016 thumb: {
1017 type: 'string',
1018 format: 'uri',
1019 description:
1020 'Fully-qualified URL where a thumbnail of the image can be fetched. For example, CDN location provided by the App View.',
1021 },
1022 fullsize: {
1023 type: 'string',
1024 format: 'uri',
1025 description:
1026 '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.',
1027 },
1028 alt: {
1029 type: 'string',
1030 description:
1031 'Alt text description of the image, for accessibility.',
1032 },
1033 aspectRatio: {
1034 type: 'ref',
1035 ref: 'lex:app.bsky.embed.defs#aspectRatio',
1036 },
1037 },
1038 },
1039 },
1040 },
1041 AppBskyEmbedRecord: {
1042 lexicon: 1,
1043 id: 'app.bsky.embed.record',
1044 description:
1045 'A representation of a record embedded in a Bluesky record (eg, a post). For example, a quote-post, or sharing a feed generator record.',
1046 defs: {
1047 main: {
1048 type: 'object',
1049 required: ['record'],
1050 properties: {
1051 record: {
1052 type: 'ref',
1053 ref: 'lex:com.atproto.repo.strongRef',
1054 },
1055 },
1056 },
1057 view: {
1058 type: 'object',
1059 required: ['record'],
1060 properties: {
1061 record: {
1062 type: 'union',
1063 refs: [
1064 'lex:app.bsky.embed.record#viewRecord',
1065 'lex:app.bsky.embed.record#viewNotFound',
1066 'lex:app.bsky.embed.record#viewBlocked',
1067 'lex:app.bsky.embed.record#viewDetached',
1068 'lex:app.bsky.feed.defs#generatorView',
1069 'lex:app.bsky.graph.defs#listView',
1070 'lex:app.bsky.labeler.defs#labelerView',
1071 'lex:app.bsky.graph.defs#starterPackViewBasic',
1072 ],
1073 },
1074 },
1075 },
1076 viewRecord: {
1077 type: 'object',
1078 required: ['uri', 'cid', 'author', 'value', 'indexedAt'],
1079 properties: {
1080 uri: {
1081 type: 'string',
1082 format: 'at-uri',
1083 },
1084 cid: {
1085 type: 'string',
1086 format: 'cid',
1087 },
1088 author: {
1089 type: 'ref',
1090 ref: 'lex:app.bsky.actor.defs#profileViewBasic',
1091 },
1092 value: {
1093 type: 'unknown',
1094 description: 'The record data itself.',
1095 },
1096 labels: {
1097 type: 'array',
1098 items: {
1099 type: 'ref',
1100 ref: 'lex:com.atproto.label.defs#label',
1101 },
1102 },
1103 replyCount: {
1104 type: 'integer',
1105 },
1106 repostCount: {
1107 type: 'integer',
1108 },
1109 likeCount: {
1110 type: 'integer',
1111 },
1112 quoteCount: {
1113 type: 'integer',
1114 },
1115 embeds: {
1116 type: 'array',
1117 items: {
1118 type: 'union',
1119 refs: [
1120 'lex:app.bsky.embed.images#view',
1121 'lex:app.bsky.embed.video#view',
1122 'lex:app.bsky.embed.external#view',
1123 'lex:app.bsky.embed.record#view',
1124 'lex:app.bsky.embed.recordWithMedia#view',
1125 ],
1126 },
1127 },
1128 indexedAt: {
1129 type: 'string',
1130 format: 'datetime',
1131 },
1132 },
1133 },
1134 viewNotFound: {
1135 type: 'object',
1136 required: ['uri', 'notFound'],
1137 properties: {
1138 uri: {
1139 type: 'string',
1140 format: 'at-uri',
1141 },
1142 notFound: {
1143 type: 'boolean',
1144 const: true,
1145 },
1146 },
1147 },
1148 viewBlocked: {
1149 type: 'object',
1150 required: ['uri', 'blocked', 'author'],
1151 properties: {
1152 uri: {
1153 type: 'string',
1154 format: 'at-uri',
1155 },
1156 blocked: {
1157 type: 'boolean',
1158 const: true,
1159 },
1160 author: {
1161 type: 'ref',
1162 ref: 'lex:app.bsky.feed.defs#blockedAuthor',
1163 },
1164 },
1165 },
1166 viewDetached: {
1167 type: 'object',
1168 required: ['uri', 'detached'],
1169 properties: {
1170 uri: {
1171 type: 'string',
1172 format: 'at-uri',
1173 },
1174 detached: {
1175 type: 'boolean',
1176 const: true,
1177 },
1178 },
1179 },
1180 },
1181 },
1182 AppBskyEmbedRecordWithMedia: {
1183 lexicon: 1,
1184 id: 'app.bsky.embed.recordWithMedia',
1185 description:
1186 'A representation of a record embedded in a Bluesky record (eg, a post), alongside other compatible embeds. For example, a quote post and image, or a quote post and external URL card.',
1187 defs: {
1188 main: {
1189 type: 'object',
1190 required: ['record', 'media'],
1191 properties: {
1192 record: {
1193 type: 'ref',
1194 ref: 'lex:app.bsky.embed.record',
1195 },
1196 media: {
1197 type: 'union',
1198 refs: [
1199 'lex:app.bsky.embed.images',
1200 'lex:app.bsky.embed.video',
1201 'lex:app.bsky.embed.external',
1202 ],
1203 },
1204 },
1205 },
1206 view: {
1207 type: 'object',
1208 required: ['record', 'media'],
1209 properties: {
1210 record: {
1211 type: 'ref',
1212 ref: 'lex:app.bsky.embed.record#view',
1213 },
1214 media: {
1215 type: 'union',
1216 refs: [
1217 'lex:app.bsky.embed.images#view',
1218 'lex:app.bsky.embed.video#view',
1219 'lex:app.bsky.embed.external#view',
1220 ],
1221 },
1222 },
1223 },
1224 },
1225 },
1226 AppBskyEmbedVideo: {
1227 lexicon: 1,
1228 id: 'app.bsky.embed.video',
1229 description: 'A video embedded in a Bluesky record (eg, a post).',
1230 defs: {
1231 main: {
1232 type: 'object',
1233 required: ['video'],
1234 properties: {
1235 video: {
1236 type: 'blob',
1237 description:
1238 'The mp4 video file. May be up to 100mb, formerly limited to 50mb.',
1239 accept: ['video/mp4'],
1240 maxSize: 100000000,
1241 },
1242 captions: {
1243 type: 'array',
1244 items: {
1245 type: 'ref',
1246 ref: 'lex:app.bsky.embed.video#caption',
1247 },
1248 maxLength: 20,
1249 },
1250 alt: {
1251 type: 'string',
1252 description:
1253 'Alt text description of the video, for accessibility.',
1254 maxGraphemes: 1000,
1255 maxLength: 10000,
1256 },
1257 aspectRatio: {
1258 type: 'ref',
1259 ref: 'lex:app.bsky.embed.defs#aspectRatio',
1260 },
1261 },
1262 },
1263 caption: {
1264 type: 'object',
1265 required: ['lang', 'file'],
1266 properties: {
1267 lang: {
1268 type: 'string',
1269 format: 'language',
1270 },
1271 file: {
1272 type: 'blob',
1273 accept: ['text/vtt'],
1274 maxSize: 20000,
1275 },
1276 },
1277 },
1278 view: {
1279 type: 'object',
1280 required: ['cid', 'playlist'],
1281 properties: {
1282 cid: {
1283 type: 'string',
1284 format: 'cid',
1285 },
1286 playlist: {
1287 type: 'string',
1288 format: 'uri',
1289 },
1290 thumbnail: {
1291 type: 'string',
1292 format: 'uri',
1293 },
1294 alt: {
1295 type: 'string',
1296 maxGraphemes: 1000,
1297 maxLength: 10000,
1298 },
1299 aspectRatio: {
1300 type: 'ref',
1301 ref: 'lex:app.bsky.embed.defs#aspectRatio',
1302 },
1303 },
1304 },
1305 },
1306 },
1307 AppBskyFeedDefs: {
1308 lexicon: 1,
1309 id: 'app.bsky.feed.defs',
1310 defs: {
1311 postView: {
1312 type: 'object',
1313 required: ['uri', 'cid', 'author', 'record', 'indexedAt'],
1314 properties: {
1315 uri: {
1316 type: 'string',
1317 format: 'at-uri',
1318 },
1319 cid: {
1320 type: 'string',
1321 format: 'cid',
1322 },
1323 author: {
1324 type: 'ref',
1325 ref: 'lex:app.bsky.actor.defs#profileViewBasic',
1326 },
1327 record: {
1328 type: 'unknown',
1329 },
1330 embed: {
1331 type: 'union',
1332 refs: [
1333 'lex:app.bsky.embed.images#view',
1334 'lex:app.bsky.embed.video#view',
1335 'lex:app.bsky.embed.external#view',
1336 'lex:app.bsky.embed.record#view',
1337 'lex:app.bsky.embed.recordWithMedia#view',
1338 ],
1339 },
1340 replyCount: {
1341 type: 'integer',
1342 },
1343 repostCount: {
1344 type: 'integer',
1345 },
1346 likeCount: {
1347 type: 'integer',
1348 },
1349 quoteCount: {
1350 type: 'integer',
1351 },
1352 indexedAt: {
1353 type: 'string',
1354 format: 'datetime',
1355 },
1356 viewer: {
1357 type: 'ref',
1358 ref: 'lex:app.bsky.feed.defs#viewerState',
1359 },
1360 labels: {
1361 type: 'array',
1362 items: {
1363 type: 'ref',
1364 ref: 'lex:com.atproto.label.defs#label',
1365 },
1366 },
1367 threadgate: {
1368 type: 'ref',
1369 ref: 'lex:app.bsky.feed.defs#threadgateView',
1370 },
1371 },
1372 },
1373 viewerState: {
1374 type: 'object',
1375 description:
1376 "Metadata about the requesting account's relationship with the subject content. Only has meaningful content for authed requests.",
1377 properties: {
1378 repost: {
1379 type: 'string',
1380 format: 'at-uri',
1381 },
1382 like: {
1383 type: 'string',
1384 format: 'at-uri',
1385 },
1386 threadMuted: {
1387 type: 'boolean',
1388 },
1389 replyDisabled: {
1390 type: 'boolean',
1391 },
1392 embeddingDisabled: {
1393 type: 'boolean',
1394 },
1395 pinned: {
1396 type: 'boolean',
1397 },
1398 },
1399 },
1400 threadContext: {
1401 type: 'object',
1402 description:
1403 'Metadata about this post within the context of the thread it is in.',
1404 properties: {
1405 rootAuthorLike: {
1406 type: 'string',
1407 format: 'at-uri',
1408 },
1409 },
1410 },
1411 feedViewPost: {
1412 type: 'object',
1413 required: ['post'],
1414 properties: {
1415 post: {
1416 type: 'ref',
1417 ref: 'lex:app.bsky.feed.defs#postView',
1418 },
1419 reply: {
1420 type: 'ref',
1421 ref: 'lex:app.bsky.feed.defs#replyRef',
1422 },
1423 reason: {
1424 type: 'union',
1425 refs: [
1426 'lex:app.bsky.feed.defs#reasonRepost',
1427 'lex:app.bsky.feed.defs#reasonPin',
1428 ],
1429 },
1430 feedContext: {
1431 type: 'string',
1432 description:
1433 'Context provided by feed generator that may be passed back alongside interactions.',
1434 maxLength: 2000,
1435 },
1436 reqId: {
1437 type: 'string',
1438 description:
1439 'Unique identifier per request that may be passed back alongside interactions.',
1440 maxLength: 100,
1441 },
1442 },
1443 },
1444 replyRef: {
1445 type: 'object',
1446 required: ['root', 'parent'],
1447 properties: {
1448 root: {
1449 type: 'union',
1450 refs: [
1451 'lex:app.bsky.feed.defs#postView',
1452 'lex:app.bsky.feed.defs#notFoundPost',
1453 'lex:app.bsky.feed.defs#blockedPost',
1454 ],
1455 },
1456 parent: {
1457 type: 'union',
1458 refs: [
1459 'lex:app.bsky.feed.defs#postView',
1460 'lex:app.bsky.feed.defs#notFoundPost',
1461 'lex:app.bsky.feed.defs#blockedPost',
1462 ],
1463 },
1464 grandparentAuthor: {
1465 type: 'ref',
1466 ref: 'lex:app.bsky.actor.defs#profileViewBasic',
1467 description:
1468 'When parent is a reply to another post, this is the author of that post.',
1469 },
1470 },
1471 },
1472 reasonRepost: {
1473 type: 'object',
1474 required: ['by', 'indexedAt'],
1475 properties: {
1476 by: {
1477 type: 'ref',
1478 ref: 'lex:app.bsky.actor.defs#profileViewBasic',
1479 },
1480 uri: {
1481 type: 'string',
1482 format: 'at-uri',
1483 },
1484 cid: {
1485 type: 'string',
1486 format: 'cid',
1487 },
1488 indexedAt: {
1489 type: 'string',
1490 format: 'datetime',
1491 },
1492 },
1493 },
1494 reasonPin: {
1495 type: 'object',
1496 properties: {},
1497 },
1498 threadViewPost: {
1499 type: 'object',
1500 required: ['post'],
1501 properties: {
1502 post: {
1503 type: 'ref',
1504 ref: 'lex:app.bsky.feed.defs#postView',
1505 },
1506 parent: {
1507 type: 'union',
1508 refs: [
1509 'lex:app.bsky.feed.defs#threadViewPost',
1510 'lex:app.bsky.feed.defs#notFoundPost',
1511 'lex:app.bsky.feed.defs#blockedPost',
1512 ],
1513 },
1514 replies: {
1515 type: 'array',
1516 items: {
1517 type: 'union',
1518 refs: [
1519 'lex:app.bsky.feed.defs#threadViewPost',
1520 'lex:app.bsky.feed.defs#notFoundPost',
1521 'lex:app.bsky.feed.defs#blockedPost',
1522 ],
1523 },
1524 },
1525 threadContext: {
1526 type: 'ref',
1527 ref: 'lex:app.bsky.feed.defs#threadContext',
1528 },
1529 },
1530 },
1531 notFoundPost: {
1532 type: 'object',
1533 required: ['uri', 'notFound'],
1534 properties: {
1535 uri: {
1536 type: 'string',
1537 format: 'at-uri',
1538 },
1539 notFound: {
1540 type: 'boolean',
1541 const: true,
1542 },
1543 },
1544 },
1545 blockedPost: {
1546 type: 'object',
1547 required: ['uri', 'blocked', 'author'],
1548 properties: {
1549 uri: {
1550 type: 'string',
1551 format: 'at-uri',
1552 },
1553 blocked: {
1554 type: 'boolean',
1555 const: true,
1556 },
1557 author: {
1558 type: 'ref',
1559 ref: 'lex:app.bsky.feed.defs#blockedAuthor',
1560 },
1561 },
1562 },
1563 blockedAuthor: {
1564 type: 'object',
1565 required: ['did'],
1566 properties: {
1567 did: {
1568 type: 'string',
1569 format: 'did',
1570 },
1571 viewer: {
1572 type: 'ref',
1573 ref: 'lex:app.bsky.actor.defs#viewerState',
1574 },
1575 },
1576 },
1577 generatorView: {
1578 type: 'object',
1579 required: ['uri', 'cid', 'did', 'creator', 'displayName', 'indexedAt'],
1580 properties: {
1581 uri: {
1582 type: 'string',
1583 format: 'at-uri',
1584 },
1585 cid: {
1586 type: 'string',
1587 format: 'cid',
1588 },
1589 did: {
1590 type: 'string',
1591 format: 'did',
1592 },
1593 creator: {
1594 type: 'ref',
1595 ref: 'lex:app.bsky.actor.defs#profileView',
1596 },
1597 displayName: {
1598 type: 'string',
1599 },
1600 description: {
1601 type: 'string',
1602 maxGraphemes: 300,
1603 maxLength: 3000,
1604 },
1605 descriptionFacets: {
1606 type: 'array',
1607 items: {
1608 type: 'ref',
1609 ref: 'lex:app.bsky.richtext.facet',
1610 },
1611 },
1612 avatar: {
1613 type: 'string',
1614 format: 'uri',
1615 },
1616 likeCount: {
1617 type: 'integer',
1618 minimum: 0,
1619 },
1620 acceptsInteractions: {
1621 type: 'boolean',
1622 },
1623 labels: {
1624 type: 'array',
1625 items: {
1626 type: 'ref',
1627 ref: 'lex:com.atproto.label.defs#label',
1628 },
1629 },
1630 viewer: {
1631 type: 'ref',
1632 ref: 'lex:app.bsky.feed.defs#generatorViewerState',
1633 },
1634 contentMode: {
1635 type: 'string',
1636 knownValues: [
1637 'app.bsky.feed.defs#contentModeUnspecified',
1638 'app.bsky.feed.defs#contentModeVideo',
1639 ],
1640 },
1641 indexedAt: {
1642 type: 'string',
1643 format: 'datetime',
1644 },
1645 },
1646 },
1647 generatorViewerState: {
1648 type: 'object',
1649 properties: {
1650 like: {
1651 type: 'string',
1652 format: 'at-uri',
1653 },
1654 },
1655 },
1656 skeletonFeedPost: {
1657 type: 'object',
1658 required: ['post'],
1659 properties: {
1660 post: {
1661 type: 'string',
1662 format: 'at-uri',
1663 },
1664 reason: {
1665 type: 'union',
1666 refs: [
1667 'lex:app.bsky.feed.defs#skeletonReasonRepost',
1668 'lex:app.bsky.feed.defs#skeletonReasonPin',
1669 ],
1670 },
1671 feedContext: {
1672 type: 'string',
1673 description:
1674 'Context that will be passed through to client and may be passed to feed generator back alongside interactions.',
1675 maxLength: 2000,
1676 },
1677 },
1678 },
1679 skeletonReasonRepost: {
1680 type: 'object',
1681 required: ['repost'],
1682 properties: {
1683 repost: {
1684 type: 'string',
1685 format: 'at-uri',
1686 },
1687 },
1688 },
1689 skeletonReasonPin: {
1690 type: 'object',
1691 properties: {},
1692 },
1693 threadgateView: {
1694 type: 'object',
1695 properties: {
1696 uri: {
1697 type: 'string',
1698 format: 'at-uri',
1699 },
1700 cid: {
1701 type: 'string',
1702 format: 'cid',
1703 },
1704 record: {
1705 type: 'unknown',
1706 },
1707 lists: {
1708 type: 'array',
1709 items: {
1710 type: 'ref',
1711 ref: 'lex:app.bsky.graph.defs#listViewBasic',
1712 },
1713 },
1714 },
1715 },
1716 interaction: {
1717 type: 'object',
1718 properties: {
1719 item: {
1720 type: 'string',
1721 format: 'at-uri',
1722 },
1723 event: {
1724 type: 'string',
1725 knownValues: [
1726 'app.bsky.feed.defs#requestLess',
1727 'app.bsky.feed.defs#requestMore',
1728 'app.bsky.feed.defs#clickthroughItem',
1729 'app.bsky.feed.defs#clickthroughAuthor',
1730 'app.bsky.feed.defs#clickthroughReposter',
1731 'app.bsky.feed.defs#clickthroughEmbed',
1732 'app.bsky.feed.defs#interactionSeen',
1733 'app.bsky.feed.defs#interactionLike',
1734 'app.bsky.feed.defs#interactionRepost',
1735 'app.bsky.feed.defs#interactionReply',
1736 'app.bsky.feed.defs#interactionQuote',
1737 'app.bsky.feed.defs#interactionShare',
1738 ],
1739 },
1740 feedContext: {
1741 type: 'string',
1742 description:
1743 'Context on a feed item that was originally supplied by the feed generator on getFeedSkeleton.',
1744 maxLength: 2000,
1745 },
1746 reqId: {
1747 type: 'string',
1748 description:
1749 'Unique identifier per request that may be passed back alongside interactions.',
1750 maxLength: 100,
1751 },
1752 },
1753 },
1754 requestLess: {
1755 type: 'token',
1756 description:
1757 'Request that less content like the given feed item be shown in the feed',
1758 },
1759 requestMore: {
1760 type: 'token',
1761 description:
1762 'Request that more content like the given feed item be shown in the feed',
1763 },
1764 clickthroughItem: {
1765 type: 'token',
1766 description: 'User clicked through to the feed item',
1767 },
1768 clickthroughAuthor: {
1769 type: 'token',
1770 description: 'User clicked through to the author of the feed item',
1771 },
1772 clickthroughReposter: {
1773 type: 'token',
1774 description: 'User clicked through to the reposter of the feed item',
1775 },
1776 clickthroughEmbed: {
1777 type: 'token',
1778 description:
1779 'User clicked through to the embedded content of the feed item',
1780 },
1781 contentModeUnspecified: {
1782 type: 'token',
1783 description: 'Declares the feed generator returns any types of posts.',
1784 },
1785 contentModeVideo: {
1786 type: 'token',
1787 description:
1788 'Declares the feed generator returns posts containing app.bsky.embed.video embeds.',
1789 },
1790 interactionSeen: {
1791 type: 'token',
1792 description: 'Feed item was seen by user',
1793 },
1794 interactionLike: {
1795 type: 'token',
1796 description: 'User liked the feed item',
1797 },
1798 interactionRepost: {
1799 type: 'token',
1800 description: 'User reposted the feed item',
1801 },
1802 interactionReply: {
1803 type: 'token',
1804 description: 'User replied to the feed item',
1805 },
1806 interactionQuote: {
1807 type: 'token',
1808 description: 'User quoted the feed item',
1809 },
1810 interactionShare: {
1811 type: 'token',
1812 description: 'User shared the feed item',
1813 },
1814 },
1815 },
1816 AppBskyFeedGetActorFeeds: {
1817 lexicon: 1,
1818 id: 'app.bsky.feed.getActorFeeds',
1819 defs: {
1820 main: {
1821 type: 'query',
1822 description:
1823 "Get a list of feeds (feed generator records) created by the actor (in the actor's repo).",
1824 parameters: {
1825 type: 'params',
1826 required: ['actor'],
1827 properties: {
1828 actor: {
1829 type: 'string',
1830 format: 'at-identifier',
1831 },
1832 limit: {
1833 type: 'integer',
1834 minimum: 1,
1835 maximum: 100,
1836 default: 50,
1837 },
1838 cursor: {
1839 type: 'string',
1840 },
1841 },
1842 },
1843 output: {
1844 encoding: 'application/json',
1845 schema: {
1846 type: 'object',
1847 required: ['feeds'],
1848 properties: {
1849 cursor: {
1850 type: 'string',
1851 },
1852 feeds: {
1853 type: 'array',
1854 items: {
1855 type: 'ref',
1856 ref: 'lex:app.bsky.feed.defs#generatorView',
1857 },
1858 },
1859 },
1860 },
1861 },
1862 },
1863 },
1864 },
1865 AppBskyFeedGetFeedGenerator: {
1866 lexicon: 1,
1867 id: 'app.bsky.feed.getFeedGenerator',
1868 defs: {
1869 main: {
1870 type: 'query',
1871 description:
1872 'Get information about a feed generator. Implemented by AppView.',
1873 parameters: {
1874 type: 'params',
1875 required: ['feed'],
1876 properties: {
1877 feed: {
1878 type: 'string',
1879 format: 'at-uri',
1880 description: 'AT-URI of the feed generator record.',
1881 },
1882 },
1883 },
1884 output: {
1885 encoding: 'application/json',
1886 schema: {
1887 type: 'object',
1888 required: ['view', 'isOnline', 'isValid'],
1889 properties: {
1890 view: {
1891 type: 'ref',
1892 ref: 'lex:app.bsky.feed.defs#generatorView',
1893 },
1894 isOnline: {
1895 type: 'boolean',
1896 description:
1897 'Indicates whether the feed generator service has been online recently, or else seems to be inactive.',
1898 },
1899 isValid: {
1900 type: 'boolean',
1901 description:
1902 'Indicates whether the feed generator service is compatible with the record declaration.',
1903 },
1904 },
1905 },
1906 },
1907 },
1908 },
1909 },
1910 AppBskyFeedGetFeedGenerators: {
1911 lexicon: 1,
1912 id: 'app.bsky.feed.getFeedGenerators',
1913 defs: {
1914 main: {
1915 type: 'query',
1916 description: 'Get information about a list of feed generators.',
1917 parameters: {
1918 type: 'params',
1919 required: ['feeds'],
1920 properties: {
1921 feeds: {
1922 type: 'array',
1923 items: {
1924 type: 'string',
1925 format: 'at-uri',
1926 },
1927 },
1928 },
1929 },
1930 output: {
1931 encoding: 'application/json',
1932 schema: {
1933 type: 'object',
1934 required: ['feeds'],
1935 properties: {
1936 feeds: {
1937 type: 'array',
1938 items: {
1939 type: 'ref',
1940 ref: 'lex:app.bsky.feed.defs#generatorView',
1941 },
1942 },
1943 },
1944 },
1945 },
1946 },
1947 },
1948 },
1949 AppBskyFeedGetPosts: {
1950 lexicon: 1,
1951 id: 'app.bsky.feed.getPosts',
1952 defs: {
1953 main: {
1954 type: 'query',
1955 description:
1956 "Gets post views for a specified list of posts (by AT-URI). This is sometimes referred to as 'hydrating' a 'feed skeleton'.",
1957 parameters: {
1958 type: 'params',
1959 required: ['uris'],
1960 properties: {
1961 uris: {
1962 type: 'array',
1963 description: 'List of post AT-URIs to return hydrated views for.',
1964 items: {
1965 type: 'string',
1966 format: 'at-uri',
1967 },
1968 maxLength: 25,
1969 },
1970 },
1971 },
1972 output: {
1973 encoding: 'application/json',
1974 schema: {
1975 type: 'object',
1976 required: ['posts'],
1977 properties: {
1978 posts: {
1979 type: 'array',
1980 items: {
1981 type: 'ref',
1982 ref: 'lex:app.bsky.feed.defs#postView',
1983 },
1984 },
1985 },
1986 },
1987 },
1988 },
1989 },
1990 },
1991 AppBskyFeedPostgate: {
1992 lexicon: 1,
1993 id: 'app.bsky.feed.postgate',
1994 defs: {
1995 main: {
1996 type: 'record',
1997 key: 'tid',
1998 description:
1999 '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.',
2000 record: {
2001 type: 'object',
2002 required: ['post', 'createdAt'],
2003 properties: {
2004 createdAt: {
2005 type: 'string',
2006 format: 'datetime',
2007 },
2008 post: {
2009 type: 'string',
2010 format: 'at-uri',
2011 description: 'Reference (AT-URI) to the post record.',
2012 },
2013 detachedEmbeddingUris: {
2014 type: 'array',
2015 maxLength: 50,
2016 items: {
2017 type: 'string',
2018 format: 'at-uri',
2019 },
2020 description:
2021 'List of AT-URIs embedding this post that the author has detached from.',
2022 },
2023 embeddingRules: {
2024 description:
2025 '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.',
2026 type: 'array',
2027 maxLength: 5,
2028 items: {
2029 type: 'union',
2030 refs: ['lex:app.bsky.feed.postgate#disableRule'],
2031 },
2032 },
2033 },
2034 },
2035 },
2036 disableRule: {
2037 type: 'object',
2038 description: 'Disables embedding of this post.',
2039 properties: {},
2040 },
2041 },
2042 },
2043 AppBskyFeedThreadgate: {
2044 lexicon: 1,
2045 id: 'app.bsky.feed.threadgate',
2046 defs: {
2047 main: {
2048 type: 'record',
2049 key: 'tid',
2050 description:
2051 "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.",
2052 record: {
2053 type: 'object',
2054 required: ['post', 'createdAt'],
2055 properties: {
2056 post: {
2057 type: 'string',
2058 format: 'at-uri',
2059 description: 'Reference (AT-URI) to the post record.',
2060 },
2061 allow: {
2062 description:
2063 '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.',
2064 type: 'array',
2065 maxLength: 5,
2066 items: {
2067 type: 'union',
2068 refs: [
2069 'lex:app.bsky.feed.threadgate#mentionRule',
2070 'lex:app.bsky.feed.threadgate#followerRule',
2071 'lex:app.bsky.feed.threadgate#followingRule',
2072 'lex:app.bsky.feed.threadgate#listRule',
2073 ],
2074 },
2075 },
2076 createdAt: {
2077 type: 'string',
2078 format: 'datetime',
2079 },
2080 hiddenReplies: {
2081 type: 'array',
2082 maxLength: 50,
2083 items: {
2084 type: 'string',
2085 format: 'at-uri',
2086 },
2087 description: 'List of hidden reply URIs.',
2088 },
2089 },
2090 },
2091 },
2092 mentionRule: {
2093 type: 'object',
2094 description: 'Allow replies from actors mentioned in your post.',
2095 properties: {},
2096 },
2097 followerRule: {
2098 type: 'object',
2099 description: 'Allow replies from actors who follow you.',
2100 properties: {},
2101 },
2102 followingRule: {
2103 type: 'object',
2104 description: 'Allow replies from actors you follow.',
2105 properties: {},
2106 },
2107 listRule: {
2108 type: 'object',
2109 description: 'Allow replies from actors on a list.',
2110 required: ['list'],
2111 properties: {
2112 list: {
2113 type: 'string',
2114 format: 'at-uri',
2115 },
2116 },
2117 },
2118 },
2119 },
2120 AppBskyGraphDefs: {
2121 lexicon: 1,
2122 id: 'app.bsky.graph.defs',
2123 defs: {
2124 listViewBasic: {
2125 type: 'object',
2126 required: ['uri', 'cid', 'name', 'purpose'],
2127 properties: {
2128 uri: {
2129 type: 'string',
2130 format: 'at-uri',
2131 },
2132 cid: {
2133 type: 'string',
2134 format: 'cid',
2135 },
2136 name: {
2137 type: 'string',
2138 maxLength: 64,
2139 minLength: 1,
2140 },
2141 purpose: {
2142 type: 'ref',
2143 ref: 'lex:app.bsky.graph.defs#listPurpose',
2144 },
2145 avatar: {
2146 type: 'string',
2147 format: 'uri',
2148 },
2149 listItemCount: {
2150 type: 'integer',
2151 minimum: 0,
2152 },
2153 labels: {
2154 type: 'array',
2155 items: {
2156 type: 'ref',
2157 ref: 'lex:com.atproto.label.defs#label',
2158 },
2159 },
2160 viewer: {
2161 type: 'ref',
2162 ref: 'lex:app.bsky.graph.defs#listViewerState',
2163 },
2164 indexedAt: {
2165 type: 'string',
2166 format: 'datetime',
2167 },
2168 },
2169 },
2170 listView: {
2171 type: 'object',
2172 required: ['uri', 'cid', 'creator', 'name', 'purpose', 'indexedAt'],
2173 properties: {
2174 uri: {
2175 type: 'string',
2176 format: 'at-uri',
2177 },
2178 cid: {
2179 type: 'string',
2180 format: 'cid',
2181 },
2182 creator: {
2183 type: 'ref',
2184 ref: 'lex:app.bsky.actor.defs#profileView',
2185 },
2186 name: {
2187 type: 'string',
2188 maxLength: 64,
2189 minLength: 1,
2190 },
2191 purpose: {
2192 type: 'ref',
2193 ref: 'lex:app.bsky.graph.defs#listPurpose',
2194 },
2195 description: {
2196 type: 'string',
2197 maxGraphemes: 300,
2198 maxLength: 3000,
2199 },
2200 descriptionFacets: {
2201 type: 'array',
2202 items: {
2203 type: 'ref',
2204 ref: 'lex:app.bsky.richtext.facet',
2205 },
2206 },
2207 avatar: {
2208 type: 'string',
2209 format: 'uri',
2210 },
2211 listItemCount: {
2212 type: 'integer',
2213 minimum: 0,
2214 },
2215 labels: {
2216 type: 'array',
2217 items: {
2218 type: 'ref',
2219 ref: 'lex:com.atproto.label.defs#label',
2220 },
2221 },
2222 viewer: {
2223 type: 'ref',
2224 ref: 'lex:app.bsky.graph.defs#listViewerState',
2225 },
2226 indexedAt: {
2227 type: 'string',
2228 format: 'datetime',
2229 },
2230 },
2231 },
2232 listItemView: {
2233 type: 'object',
2234 required: ['uri', 'subject'],
2235 properties: {
2236 uri: {
2237 type: 'string',
2238 format: 'at-uri',
2239 },
2240 subject: {
2241 type: 'ref',
2242 ref: 'lex:app.bsky.actor.defs#profileView',
2243 },
2244 },
2245 },
2246 starterPackView: {
2247 type: 'object',
2248 required: ['uri', 'cid', 'record', 'creator', 'indexedAt'],
2249 properties: {
2250 uri: {
2251 type: 'string',
2252 format: 'at-uri',
2253 },
2254 cid: {
2255 type: 'string',
2256 format: 'cid',
2257 },
2258 record: {
2259 type: 'unknown',
2260 },
2261 creator: {
2262 type: 'ref',
2263 ref: 'lex:app.bsky.actor.defs#profileViewBasic',
2264 },
2265 list: {
2266 type: 'ref',
2267 ref: 'lex:app.bsky.graph.defs#listViewBasic',
2268 },
2269 listItemsSample: {
2270 type: 'array',
2271 maxLength: 12,
2272 items: {
2273 type: 'ref',
2274 ref: 'lex:app.bsky.graph.defs#listItemView',
2275 },
2276 },
2277 feeds: {
2278 type: 'array',
2279 maxLength: 3,
2280 items: {
2281 type: 'ref',
2282 ref: 'lex:app.bsky.feed.defs#generatorView',
2283 },
2284 },
2285 joinedWeekCount: {
2286 type: 'integer',
2287 minimum: 0,
2288 },
2289 joinedAllTimeCount: {
2290 type: 'integer',
2291 minimum: 0,
2292 },
2293 labels: {
2294 type: 'array',
2295 items: {
2296 type: 'ref',
2297 ref: 'lex:com.atproto.label.defs#label',
2298 },
2299 },
2300 indexedAt: {
2301 type: 'string',
2302 format: 'datetime',
2303 },
2304 },
2305 },
2306 starterPackViewBasic: {
2307 type: 'object',
2308 required: ['uri', 'cid', 'record', 'creator', 'indexedAt'],
2309 properties: {
2310 uri: {
2311 type: 'string',
2312 format: 'at-uri',
2313 },
2314 cid: {
2315 type: 'string',
2316 format: 'cid',
2317 },
2318 record: {
2319 type: 'unknown',
2320 },
2321 creator: {
2322 type: 'ref',
2323 ref: 'lex:app.bsky.actor.defs#profileViewBasic',
2324 },
2325 listItemCount: {
2326 type: 'integer',
2327 minimum: 0,
2328 },
2329 joinedWeekCount: {
2330 type: 'integer',
2331 minimum: 0,
2332 },
2333 joinedAllTimeCount: {
2334 type: 'integer',
2335 minimum: 0,
2336 },
2337 labels: {
2338 type: 'array',
2339 items: {
2340 type: 'ref',
2341 ref: 'lex:com.atproto.label.defs#label',
2342 },
2343 },
2344 indexedAt: {
2345 type: 'string',
2346 format: 'datetime',
2347 },
2348 },
2349 },
2350 listPurpose: {
2351 type: 'string',
2352 knownValues: [
2353 'app.bsky.graph.defs#modlist',
2354 'app.bsky.graph.defs#curatelist',
2355 'app.bsky.graph.defs#referencelist',
2356 ],
2357 },
2358 modlist: {
2359 type: 'token',
2360 description:
2361 'A list of actors to apply an aggregate moderation action (mute/block) on.',
2362 },
2363 curatelist: {
2364 type: 'token',
2365 description:
2366 'A list of actors used for curation purposes such as list feeds or interaction gating.',
2367 },
2368 referencelist: {
2369 type: 'token',
2370 description:
2371 'A list of actors used for only for reference purposes such as within a starter pack.',
2372 },
2373 listViewerState: {
2374 type: 'object',
2375 properties: {
2376 muted: {
2377 type: 'boolean',
2378 },
2379 blocked: {
2380 type: 'string',
2381 format: 'at-uri',
2382 },
2383 },
2384 },
2385 notFoundActor: {
2386 type: 'object',
2387 description: 'indicates that a handle or DID could not be resolved',
2388 required: ['actor', 'notFound'],
2389 properties: {
2390 actor: {
2391 type: 'string',
2392 format: 'at-identifier',
2393 },
2394 notFound: {
2395 type: 'boolean',
2396 const: true,
2397 },
2398 },
2399 },
2400 relationship: {
2401 type: 'object',
2402 description:
2403 'lists the bi-directional graph relationships between one actor (not indicated in the object), and the target actors (the DID included in the object)',
2404 required: ['did'],
2405 properties: {
2406 did: {
2407 type: 'string',
2408 format: 'did',
2409 },
2410 following: {
2411 type: 'string',
2412 format: 'at-uri',
2413 description:
2414 'if the actor follows this DID, this is the AT-URI of the follow record',
2415 },
2416 followedBy: {
2417 type: 'string',
2418 format: 'at-uri',
2419 description:
2420 'if the actor is followed by this DID, contains the AT-URI of the follow record',
2421 },
2422 },
2423 },
2424 },
2425 },
2426 AppBskyNotificationDefs: {
2427 lexicon: 1,
2428 id: 'app.bsky.notification.defs',
2429 defs: {
2430 recordDeleted: {
2431 type: 'object',
2432 properties: {},
2433 },
2434 chatPreference: {
2435 type: 'object',
2436 required: ['include', 'push'],
2437 properties: {
2438 include: {
2439 type: 'string',
2440 knownValues: ['all', 'accepted'],
2441 },
2442 push: {
2443 type: 'boolean',
2444 },
2445 },
2446 },
2447 filterablePreference: {
2448 type: 'object',
2449 required: ['include', 'list', 'push'],
2450 properties: {
2451 include: {
2452 type: 'string',
2453 knownValues: ['all', 'follows'],
2454 },
2455 list: {
2456 type: 'boolean',
2457 },
2458 push: {
2459 type: 'boolean',
2460 },
2461 },
2462 },
2463 preference: {
2464 type: 'object',
2465 required: ['list', 'push'],
2466 properties: {
2467 list: {
2468 type: 'boolean',
2469 },
2470 push: {
2471 type: 'boolean',
2472 },
2473 },
2474 },
2475 preferences: {
2476 type: 'object',
2477 required: [
2478 'chat',
2479 'follow',
2480 'like',
2481 'likeViaRepost',
2482 'mention',
2483 'quote',
2484 'reply',
2485 'repost',
2486 'repostViaRepost',
2487 'starterpackJoined',
2488 'subscribedPost',
2489 'unverified',
2490 'verified',
2491 ],
2492 properties: {
2493 chat: {
2494 type: 'ref',
2495 ref: 'lex:app.bsky.notification.defs#chatPreference',
2496 },
2497 follow: {
2498 type: 'ref',
2499 ref: 'lex:app.bsky.notification.defs#filterablePreference',
2500 },
2501 like: {
2502 type: 'ref',
2503 ref: 'lex:app.bsky.notification.defs#filterablePreference',
2504 },
2505 likeViaRepost: {
2506 type: 'ref',
2507 ref: 'lex:app.bsky.notification.defs#filterablePreference',
2508 },
2509 mention: {
2510 type: 'ref',
2511 ref: 'lex:app.bsky.notification.defs#filterablePreference',
2512 },
2513 quote: {
2514 type: 'ref',
2515 ref: 'lex:app.bsky.notification.defs#filterablePreference',
2516 },
2517 reply: {
2518 type: 'ref',
2519 ref: 'lex:app.bsky.notification.defs#filterablePreference',
2520 },
2521 repost: {
2522 type: 'ref',
2523 ref: 'lex:app.bsky.notification.defs#filterablePreference',
2524 },
2525 repostViaRepost: {
2526 type: 'ref',
2527 ref: 'lex:app.bsky.notification.defs#filterablePreference',
2528 },
2529 starterpackJoined: {
2530 type: 'ref',
2531 ref: 'lex:app.bsky.notification.defs#preference',
2532 },
2533 subscribedPost: {
2534 type: 'ref',
2535 ref: 'lex:app.bsky.notification.defs#preference',
2536 },
2537 unverified: {
2538 type: 'ref',
2539 ref: 'lex:app.bsky.notification.defs#preference',
2540 },
2541 verified: {
2542 type: 'ref',
2543 ref: 'lex:app.bsky.notification.defs#preference',
2544 },
2545 },
2546 },
2547 activitySubscription: {
2548 type: 'object',
2549 required: ['post', 'reply'],
2550 properties: {
2551 post: {
2552 type: 'boolean',
2553 },
2554 reply: {
2555 type: 'boolean',
2556 },
2557 },
2558 },
2559 subjectActivitySubscription: {
2560 description:
2561 'Object used to store activity subscription data in stash.',
2562 type: 'object',
2563 required: ['subject', 'activitySubscription'],
2564 properties: {
2565 subject: {
2566 type: 'string',
2567 format: 'did',
2568 },
2569 activitySubscription: {
2570 type: 'ref',
2571 ref: 'lex:app.bsky.notification.defs#activitySubscription',
2572 },
2573 },
2574 },
2575 },
2576 },
2577 AppBskyRichtextFacet: {
2578 lexicon: 1,
2579 id: 'app.bsky.richtext.facet',
2580 defs: {
2581 main: {
2582 type: 'object',
2583 description: 'Annotation of a sub-string within rich text.',
2584 required: ['index', 'features'],
2585 properties: {
2586 index: {
2587 type: 'ref',
2588 ref: 'lex:app.bsky.richtext.facet#byteSlice',
2589 },
2590 features: {
2591 type: 'array',
2592 items: {
2593 type: 'union',
2594 refs: [
2595 'lex:app.bsky.richtext.facet#mention',
2596 'lex:app.bsky.richtext.facet#link',
2597 'lex:app.bsky.richtext.facet#tag',
2598 ],
2599 },
2600 },
2601 },
2602 },
2603 mention: {
2604 type: 'object',
2605 description:
2606 "Facet feature for mention of another account. The text is usually a handle, including a '@' prefix, but the facet reference is a DID.",
2607 required: ['did'],
2608 properties: {
2609 did: {
2610 type: 'string',
2611 format: 'did',
2612 },
2613 },
2614 },
2615 link: {
2616 type: 'object',
2617 description:
2618 'Facet feature for a URL. The text URL may have been simplified or truncated, but the facet reference should be a complete URL.',
2619 required: ['uri'],
2620 properties: {
2621 uri: {
2622 type: 'string',
2623 format: 'uri',
2624 },
2625 },
2626 },
2627 tag: {
2628 type: 'object',
2629 description:
2630 "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').",
2631 required: ['tag'],
2632 properties: {
2633 tag: {
2634 type: 'string',
2635 maxLength: 640,
2636 maxGraphemes: 64,
2637 },
2638 },
2639 },
2640 byteSlice: {
2641 type: 'object',
2642 description:
2643 '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.',
2644 required: ['byteStart', 'byteEnd'],
2645 properties: {
2646 byteStart: {
2647 type: 'integer',
2648 minimum: 0,
2649 },
2650 byteEnd: {
2651 type: 'integer',
2652 minimum: 0,
2653 },
2654 },
2655 },
2656 },
2657 },
2658 ComAtprotoLabelDefs: {
2659 lexicon: 1,
2660 id: 'com.atproto.label.defs',
2661 defs: {
2662 label: {
2663 type: 'object',
2664 description:
2665 'Metadata tag on an atproto resource (eg, repo or record).',
2666 required: ['src', 'uri', 'val', 'cts'],
2667 properties: {
2668 ver: {
2669 type: 'integer',
2670 description: 'The AT Protocol version of the label object.',
2671 },
2672 src: {
2673 type: 'string',
2674 format: 'did',
2675 description: 'DID of the actor who created this label.',
2676 },
2677 uri: {
2678 type: 'string',
2679 format: 'uri',
2680 description:
2681 'AT URI of the record, repository (account), or other resource that this label applies to.',
2682 },
2683 cid: {
2684 type: 'string',
2685 format: 'cid',
2686 description:
2687 "Optionally, CID specifying the specific version of 'uri' resource this label applies to.",
2688 },
2689 val: {
2690 type: 'string',
2691 maxLength: 128,
2692 description:
2693 'The short string name of the value or type of this label.',
2694 },
2695 neg: {
2696 type: 'boolean',
2697 description:
2698 'If true, this is a negation label, overwriting a previous label.',
2699 },
2700 cts: {
2701 type: 'string',
2702 format: 'datetime',
2703 description: 'Timestamp when this label was created.',
2704 },
2705 exp: {
2706 type: 'string',
2707 format: 'datetime',
2708 description:
2709 'Timestamp at which this label expires (no longer applies).',
2710 },
2711 sig: {
2712 type: 'bytes',
2713 description: 'Signature of dag-cbor encoded label.',
2714 },
2715 },
2716 },
2717 selfLabels: {
2718 type: 'object',
2719 description:
2720 'Metadata tags on an atproto record, published by the author within the record.',
2721 required: ['values'],
2722 properties: {
2723 values: {
2724 type: 'array',
2725 items: {
2726 type: 'ref',
2727 ref: 'lex:com.atproto.label.defs#selfLabel',
2728 },
2729 maxLength: 10,
2730 },
2731 },
2732 },
2733 selfLabel: {
2734 type: 'object',
2735 description:
2736 'Metadata tag on an atproto record, published by the author within the record. Note that schemas should use #selfLabels, not #selfLabel.',
2737 required: ['val'],
2738 properties: {
2739 val: {
2740 type: 'string',
2741 maxLength: 128,
2742 description:
2743 'The short string name of the value or type of this label.',
2744 },
2745 },
2746 },
2747 labelValueDefinition: {
2748 type: 'object',
2749 description:
2750 'Declares a label value and its expected interpretations and behaviors.',
2751 required: ['identifier', 'severity', 'blurs', 'locales'],
2752 properties: {
2753 identifier: {
2754 type: 'string',
2755 description:
2756 "The value of the label being defined. Must only include lowercase ascii and the '-' character ([a-z-]+).",
2757 maxLength: 100,
2758 maxGraphemes: 100,
2759 },
2760 severity: {
2761 type: 'string',
2762 description:
2763 "How should a client visually convey this label? 'inform' means neutral and informational; 'alert' means negative and warning; 'none' means show nothing.",
2764 knownValues: ['inform', 'alert', 'none'],
2765 },
2766 blurs: {
2767 type: 'string',
2768 description:
2769 "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.",
2770 knownValues: ['content', 'media', 'none'],
2771 },
2772 defaultSetting: {
2773 type: 'string',
2774 description: 'The default setting for this label.',
2775 knownValues: ['ignore', 'warn', 'hide'],
2776 default: 'warn',
2777 },
2778 adultOnly: {
2779 type: 'boolean',
2780 description:
2781 'Does the user need to have adult content enabled in order to configure this label?',
2782 },
2783 locales: {
2784 type: 'array',
2785 items: {
2786 type: 'ref',
2787 ref: 'lex:com.atproto.label.defs#labelValueDefinitionStrings',
2788 },
2789 },
2790 },
2791 },
2792 labelValueDefinitionStrings: {
2793 type: 'object',
2794 description:
2795 'Strings which describe the label in the UI, localized into a specific language.',
2796 required: ['lang', 'name', 'description'],
2797 properties: {
2798 lang: {
2799 type: 'string',
2800 description:
2801 'The code of the language these strings are written in.',
2802 format: 'language',
2803 },
2804 name: {
2805 type: 'string',
2806 description: 'A short human-readable name for the label.',
2807 maxGraphemes: 64,
2808 maxLength: 640,
2809 },
2810 description: {
2811 type: 'string',
2812 description:
2813 'A longer description of what the label means and why it might be applied.',
2814 maxGraphemes: 10000,
2815 maxLength: 100000,
2816 },
2817 },
2818 },
2819 labelValue: {
2820 type: 'string',
2821 knownValues: [
2822 '!hide',
2823 '!no-promote',
2824 '!warn',
2825 '!no-unauthenticated',
2826 'dmca-violation',
2827 'doxxing',
2828 'porn',
2829 'sexual',
2830 'nudity',
2831 'nsfl',
2832 'gore',
2833 ],
2834 },
2835 },
2836 },
2837 ComAtprotoRepoStrongRef: {
2838 lexicon: 1,
2839 id: 'com.atproto.repo.strongRef',
2840 description: 'A URI with a content-hash fingerprint.',
2841 defs: {
2842 main: {
2843 type: 'object',
2844 required: ['uri', 'cid'],
2845 properties: {
2846 uri: {
2847 type: 'string',
2848 format: 'at-uri',
2849 },
2850 cid: {
2851 type: 'string',
2852 format: 'cid',
2853 },
2854 },
2855 },
2856 },
2857 },
2858 PartyWheyAppBskyActorDefs: {
2859 lexicon: 1,
2860 id: 'party.whey.app.bsky.actor.defs',
2861 defs: {
2862 profileViewBasicRef: {
2863 type: 'object',
2864 required: ['did'],
2865 properties: {
2866 did: {
2867 type: 'string',
2868 format: 'did',
2869 },
2870 },
2871 },
2872 profileViewRef: {
2873 type: 'object',
2874 required: ['did'],
2875 properties: {
2876 did: {
2877 type: 'string',
2878 format: 'did',
2879 },
2880 },
2881 },
2882 profileViewDetailedRef: {
2883 type: 'object',
2884 required: ['did'],
2885 properties: {
2886 did: {
2887 type: 'string',
2888 format: 'did',
2889 },
2890 },
2891 },
2892 },
2893 },
2894 PartyWheyAppBskyFeedDefs: {
2895 lexicon: 1,
2896 id: 'party.whey.app.bsky.feed.defs',
2897 defs: {
2898 postViewRef: {
2899 type: 'object',
2900 description: 'A pointer to a app.bsky.feed.defs#postView',
2901 required: ['uri', 'cid'],
2902 properties: {
2903 uri: {
2904 type: 'string',
2905 format: 'at-uri',
2906 },
2907 cid: {
2908 type: 'string',
2909 format: 'cid',
2910 },
2911 },
2912 },
2913 feedViewPostRef: {
2914 type: 'object',
2915 required: ['post'],
2916 properties: {
2917 post: {
2918 type: 'union',
2919 refs: [
2920 'lex:app.bsky.feed.defs#postView',
2921 'lex:party.whey.app.bsky.feed.defs#postViewRef',
2922 ],
2923 },
2924 reply: {
2925 type: 'union',
2926 refs: [
2927 'lex:app.bsky.feed.defs#replyRef',
2928 'lex:party.whey.app.bsky.feed.defs#replyRef',
2929 ],
2930 },
2931 reason: {
2932 type: 'union',
2933 refs: [
2934 'lex:app.bsky.feed.defs#reasonRepost',
2935 'lex:app.bsky.feed.defs#reasonPin',
2936 ],
2937 },
2938 feedContext: {
2939 type: 'string',
2940 description:
2941 'Context provided by feed generator that may be passed back alongside interactions.',
2942 maxLength: 2000,
2943 },
2944 reqId: {
2945 type: 'string',
2946 description:
2947 'Unique identifier per request that may be passed back alongside interactions.',
2948 maxLength: 100,
2949 },
2950 },
2951 },
2952 replyRef: {
2953 type: 'object',
2954 required: ['root', 'parent'],
2955 properties: {
2956 root: {
2957 type: 'union',
2958 refs: [
2959 'lex:party.whey.app.bsky.feed.defs#postViewRef',
2960 'lex:app.bsky.feed.defs#postView',
2961 'lex:app.bsky.feed.defs#notFoundPost',
2962 'lex:app.bsky.feed.defs#blockedPost',
2963 ],
2964 },
2965 parent: {
2966 type: 'union',
2967 refs: [
2968 'lex:party.whey.app.bsky.feed.defs#postViewRef',
2969 'lex:app.bsky.feed.defs#postView',
2970 'lex:app.bsky.feed.defs#notFoundPost',
2971 'lex:app.bsky.feed.defs#blockedPost',
2972 ],
2973 },
2974 grandparentAuthor: {
2975 type: 'union',
2976 refs: [
2977 'lex:party.whey.app.bsky.actor.defs#profileViewBasicRef',
2978 'lex:app.bsky.actor.defs#profileViewBasic',
2979 ],
2980 description:
2981 'When parent is a reply to another post, this is the author of that post.',
2982 },
2983 },
2984 },
2985 threadViewPostRef: {
2986 type: 'object',
2987 required: ['post'],
2988 properties: {
2989 post: {
2990 type: 'union',
2991 refs: [
2992 'lex:party.whey.app.bsky.feed.defs#postViewRef',
2993 'lex:app.bsky.feed.defs#postView',
2994 ],
2995 },
2996 parent: {
2997 type: 'union',
2998 refs: [
2999 'lex:party.whey.app.bsky.feed.defs#threadViewPostRef',
3000 'lex:app.bsky.feed.defs#threadViewPost',
3001 'lex:app.bsky.feed.defs#notFoundPost',
3002 'lex:app.bsky.feed.defs#blockedPost',
3003 ],
3004 },
3005 replies: {
3006 type: 'array',
3007 items: {
3008 type: 'union',
3009 refs: [
3010 'lex:party.whey.app.bsky.feed.defs#threadViewPostRef',
3011 'lex:app.bsky.feed.defs#threadViewPost',
3012 'lex:app.bsky.feed.defs#notFoundPost',
3013 'lex:app.bsky.feed.defs#blockedPost',
3014 ],
3015 },
3016 },
3017 threadContext: {
3018 type: 'ref',
3019 ref: 'lex:app.bsky.feed.defs#threadContext',
3020 },
3021 },
3022 },
3023 },
3024 },
3025 PartyWheyAppBskyFeedGetActorLikesPartial: {
3026 lexicon: 1,
3027 id: 'party.whey.app.bsky.feed.getActorLikesPartial',
3028 defs: {
3029 main: {
3030 type: 'query',
3031 description:
3032 'Get a list of posts liked by an actor. May require auth, (if so, actor must be the requesting account).',
3033 parameters: {
3034 type: 'params',
3035 required: ['actor'],
3036 properties: {
3037 actor: {
3038 type: 'string',
3039 format: 'at-identifier',
3040 },
3041 limit: {
3042 type: 'integer',
3043 minimum: 1,
3044 maximum: 100,
3045 default: 50,
3046 },
3047 cursor: {
3048 type: 'string',
3049 },
3050 },
3051 },
3052 output: {
3053 encoding: 'application/json',
3054 schema: {
3055 type: 'object',
3056 required: ['feed'],
3057 properties: {
3058 cursor: {
3059 type: 'string',
3060 },
3061 feed: {
3062 type: 'array',
3063 items: {
3064 type: 'union',
3065 refs: [
3066 'lex:party.whey.app.bsky.feed.defs#feedViewPostRef',
3067 'lex:app.bsky.feed.defs#feedViewPost',
3068 ],
3069 },
3070 },
3071 },
3072 },
3073 },
3074 errors: [
3075 {
3076 name: 'BlockedActor',
3077 },
3078 {
3079 name: 'BlockedByActor',
3080 },
3081 ],
3082 },
3083 },
3084 },
3085 PartyWheyAppBskyFeedGetAuthorFeedPartial: {
3086 lexicon: 1,
3087 id: 'party.whey.app.bsky.feed.getAuthorFeedPartial',
3088 defs: {
3089 main: {
3090 type: 'query',
3091 description:
3092 "Get a view of an actor's 'author feed' (post and reposts by the author). Does not require auth.",
3093 parameters: {
3094 type: 'params',
3095 required: ['actor'],
3096 properties: {
3097 actor: {
3098 type: 'string',
3099 format: 'at-identifier',
3100 },
3101 limit: {
3102 type: 'integer',
3103 minimum: 1,
3104 maximum: 100,
3105 default: 50,
3106 },
3107 cursor: {
3108 type: 'string',
3109 },
3110 filter: {
3111 type: 'string',
3112 description:
3113 'Combinations of post/repost types to include in response.',
3114 knownValues: [
3115 'posts_with_replies',
3116 'posts_no_replies',
3117 'posts_with_media',
3118 'posts_and_author_threads',
3119 'posts_with_video',
3120 ],
3121 default: 'posts_with_replies',
3122 },
3123 includePins: {
3124 type: 'boolean',
3125 default: false,
3126 },
3127 },
3128 },
3129 output: {
3130 encoding: 'application/json',
3131 schema: {
3132 type: 'object',
3133 required: ['feed'],
3134 properties: {
3135 cursor: {
3136 type: 'string',
3137 },
3138 feed: {
3139 type: 'array',
3140 items: {
3141 type: 'union',
3142 refs: [
3143 'lex:party.whey.app.bsky.feed.defs#feedViewPostRef',
3144 'lex:app.bsky.feed.defs#feedViewPost',
3145 ],
3146 },
3147 },
3148 },
3149 },
3150 },
3151 errors: [
3152 {
3153 name: 'BlockedActor',
3154 },
3155 {
3156 name: 'BlockedByActor',
3157 },
3158 ],
3159 },
3160 },
3161 },
3162 PartyWheyAppBskyFeedGetLikesPartial: {
3163 lexicon: 1,
3164 id: 'party.whey.app.bsky.feed.getLikesPartial',
3165 defs: {
3166 main: {
3167 type: 'query',
3168 description:
3169 'Get like records which reference a subject (by AT-URI and CID).',
3170 parameters: {
3171 type: 'params',
3172 required: ['uri'],
3173 properties: {
3174 uri: {
3175 type: 'string',
3176 format: 'at-uri',
3177 description: 'AT-URI of the subject (eg, a post record).',
3178 },
3179 cid: {
3180 type: 'string',
3181 format: 'cid',
3182 description:
3183 'CID of the subject record (aka, specific version of record), to filter likes.',
3184 },
3185 limit: {
3186 type: 'integer',
3187 minimum: 1,
3188 maximum: 100,
3189 default: 50,
3190 },
3191 cursor: {
3192 type: 'string',
3193 },
3194 },
3195 },
3196 output: {
3197 encoding: 'application/json',
3198 schema: {
3199 type: 'object',
3200 required: ['uri', 'likes'],
3201 properties: {
3202 uri: {
3203 type: 'string',
3204 format: 'at-uri',
3205 },
3206 cid: {
3207 type: 'string',
3208 format: 'cid',
3209 },
3210 cursor: {
3211 type: 'string',
3212 },
3213 likes: {
3214 type: 'array',
3215 items: {
3216 type: 'ref',
3217 ref: 'lex:party.whey.app.bsky.feed.getLikesPartial#like',
3218 },
3219 },
3220 },
3221 },
3222 },
3223 },
3224 like: {
3225 type: 'object',
3226 required: ['indexedAt', 'createdAt', 'actor'],
3227 properties: {
3228 indexedAt: {
3229 type: 'string',
3230 format: 'datetime',
3231 },
3232 createdAt: {
3233 type: 'string',
3234 format: 'datetime',
3235 },
3236 actor: {
3237 type: 'ref',
3238 ref: 'lex:party.whey.app.bsky.actor.defs#profileViewRef',
3239 },
3240 },
3241 },
3242 },
3243 },
3244 PartyWheyAppBskyFeedGetListFeedPartial: {
3245 lexicon: 1,
3246 id: 'party.whey.app.bsky.feed.getListFeedPartial',
3247 defs: {
3248 main: {
3249 type: 'query',
3250 description:
3251 'Get a feed of recent posts from a list (posts and reposts from any actors on the list). Does not require auth.',
3252 parameters: {
3253 type: 'params',
3254 required: ['list'],
3255 properties: {
3256 list: {
3257 type: 'string',
3258 format: 'at-uri',
3259 description: 'Reference (AT-URI) to the list record.',
3260 },
3261 limit: {
3262 type: 'integer',
3263 minimum: 1,
3264 maximum: 100,
3265 default: 50,
3266 },
3267 cursor: {
3268 type: 'string',
3269 },
3270 },
3271 },
3272 output: {
3273 encoding: 'application/json',
3274 schema: {
3275 type: 'object',
3276 required: ['feed'],
3277 properties: {
3278 cursor: {
3279 type: 'string',
3280 },
3281 feed: {
3282 type: 'array',
3283 items: {
3284 type: 'ref',
3285 ref: 'lex:party.whey.app.bsky.feed.defs#feedViewPostRef',
3286 },
3287 },
3288 },
3289 },
3290 },
3291 errors: [
3292 {
3293 name: 'UnknownList',
3294 },
3295 ],
3296 },
3297 },
3298 },
3299 PartyWheyAppBskyFeedGetPostThreadPartial: {
3300 lexicon: 1,
3301 id: 'party.whey.app.bsky.feed.getPostThreadPartial',
3302 defs: {
3303 main: {
3304 type: 'query',
3305 description:
3306 'Get posts in a thread. Does not require auth, but additional metadata and filtering will be applied for authed requests.',
3307 parameters: {
3308 type: 'params',
3309 required: ['uri'],
3310 properties: {
3311 uri: {
3312 type: 'string',
3313 format: 'at-uri',
3314 description: 'Reference (AT-URI) to post record.',
3315 },
3316 depth: {
3317 type: 'integer',
3318 description:
3319 'How many levels of reply depth should be included in response.',
3320 default: 6,
3321 minimum: 0,
3322 maximum: 1000,
3323 },
3324 parentHeight: {
3325 type: 'integer',
3326 description:
3327 'How many levels of parent (and grandparent, etc) post to include.',
3328 default: 80,
3329 minimum: 0,
3330 maximum: 1000,
3331 },
3332 },
3333 },
3334 output: {
3335 encoding: 'application/json',
3336 schema: {
3337 type: 'object',
3338 required: ['thread'],
3339 properties: {
3340 thread: {
3341 type: 'union',
3342 refs: [
3343 'lex:party.whey.app.bsky.feed.defs#threadViewPostRef',
3344 'lex:app.bsky.feed.defs#threadViewPost',
3345 'lex:app.bsky.feed.defs#notFoundPost',
3346 'lex:app.bsky.feed.defs#blockedPost',
3347 ],
3348 },
3349 threadgate: {
3350 type: 'ref',
3351 ref: 'lex:app.bsky.feed.defs#threadgateView',
3352 },
3353 },
3354 },
3355 },
3356 errors: [
3357 {
3358 name: 'NotFound',
3359 },
3360 ],
3361 },
3362 },
3363 },
3364 PartyWheyAppBskyFeedGetQuotesPartial: {
3365 lexicon: 1,
3366 id: 'party.whey.app.bsky.feed.getQuotesPartial',
3367 defs: {
3368 main: {
3369 type: 'query',
3370 description: 'Get a list of quotes for a given post.',
3371 parameters: {
3372 type: 'params',
3373 required: ['uri'],
3374 properties: {
3375 uri: {
3376 type: 'string',
3377 format: 'at-uri',
3378 description: 'Reference (AT-URI) of post record',
3379 },
3380 cid: {
3381 type: 'string',
3382 format: 'cid',
3383 description:
3384 'If supplied, filters to quotes of specific version (by CID) of the post record.',
3385 },
3386 limit: {
3387 type: 'integer',
3388 minimum: 1,
3389 maximum: 100,
3390 default: 50,
3391 },
3392 cursor: {
3393 type: 'string',
3394 },
3395 },
3396 },
3397 output: {
3398 encoding: 'application/json',
3399 schema: {
3400 type: 'object',
3401 required: ['uri', 'posts'],
3402 properties: {
3403 uri: {
3404 type: 'string',
3405 format: 'at-uri',
3406 },
3407 cid: {
3408 type: 'string',
3409 format: 'cid',
3410 },
3411 cursor: {
3412 type: 'string',
3413 },
3414 posts: {
3415 type: 'array',
3416 items: {
3417 type: 'union',
3418 refs: [
3419 'lex:party.whey.app.bsky.feed.defs#postViewRef',
3420 'lex:app.bsky.feed.defs#postView',
3421 ],
3422 },
3423 },
3424 },
3425 },
3426 },
3427 },
3428 },
3429 },
3430 PartyWheyAppBskyFeedGetRepostedByPartial: {
3431 lexicon: 1,
3432 id: 'party.whey.app.bsky.feed.getRepostedByPartial',
3433 defs: {
3434 main: {
3435 type: 'query',
3436 description: 'Get a list of reposts for a given post.',
3437 parameters: {
3438 type: 'params',
3439 required: ['uri'],
3440 properties: {
3441 uri: {
3442 type: 'string',
3443 format: 'at-uri',
3444 description: 'Reference (AT-URI) of post record',
3445 },
3446 cid: {
3447 type: 'string',
3448 format: 'cid',
3449 description:
3450 'If supplied, filters to reposts of specific version (by CID) of the post record.',
3451 },
3452 limit: {
3453 type: 'integer',
3454 minimum: 1,
3455 maximum: 100,
3456 default: 50,
3457 },
3458 cursor: {
3459 type: 'string',
3460 },
3461 },
3462 },
3463 output: {
3464 encoding: 'application/json',
3465 schema: {
3466 type: 'object',
3467 required: ['uri', 'repostedBy'],
3468 properties: {
3469 uri: {
3470 type: 'string',
3471 format: 'at-uri',
3472 },
3473 cid: {
3474 type: 'string',
3475 format: 'cid',
3476 },
3477 cursor: {
3478 type: 'string',
3479 },
3480 repostedBy: {
3481 type: 'array',
3482 items: {
3483 type: 'union',
3484 refs: [
3485 'lex:party.whey.app.bsky.actor.defs#profileViewRef',
3486 'lex:app.bsky.actor.defs#profileView',
3487 ],
3488 },
3489 },
3490 },
3491 },
3492 },
3493 },
3494 },
3495 },
3496} as const satisfies Record<string, LexiconDoc>
3497export const schemas = Object.values(schemaDict) satisfies LexiconDoc[]
3498export const lexicons: Lexicons = new Lexicons(schemas)
3499
3500export function validate<T extends { $type: string }>(
3501 v: unknown,
3502 id: string,
3503 hash: string,
3504 requiredType: true,
3505): ValidationResult<T>
3506export function validate<T extends { $type?: string }>(
3507 v: unknown,
3508 id: string,
3509 hash: string,
3510 requiredType?: false,
3511): ValidationResult<T>
3512export function validate(
3513 v: unknown,
3514 id: string,
3515 hash: string,
3516 requiredType?: boolean,
3517): ValidationResult {
3518 return (requiredType ? is$typed : maybe$typed)(v, id, hash)
3519 ? lexicons.validate(`${id}#${hash}`, v)
3520 : {
3521 success: false,
3522 error: new ValidationError(
3523 `Must be an object with "${hash === 'main' ? id : `${id}#${hash}`}" $type property`,
3524 ),
3525 }
3526}
3527
3528export const ids = {
3529 AppBskyActorDefs: 'app.bsky.actor.defs',
3530 AppBskyActorGetProfile: 'app.bsky.actor.getProfile',
3531 AppBskyActorGetProfiles: 'app.bsky.actor.getProfiles',
3532 AppBskyEmbedDefs: 'app.bsky.embed.defs',
3533 AppBskyEmbedExternal: 'app.bsky.embed.external',
3534 AppBskyEmbedImages: 'app.bsky.embed.images',
3535 AppBskyEmbedRecord: 'app.bsky.embed.record',
3536 AppBskyEmbedRecordWithMedia: 'app.bsky.embed.recordWithMedia',
3537 AppBskyEmbedVideo: 'app.bsky.embed.video',
3538 AppBskyFeedDefs: 'app.bsky.feed.defs',
3539 AppBskyFeedGetActorFeeds: 'app.bsky.feed.getActorFeeds',
3540 AppBskyFeedGetFeedGenerator: 'app.bsky.feed.getFeedGenerator',
3541 AppBskyFeedGetFeedGenerators: 'app.bsky.feed.getFeedGenerators',
3542 AppBskyFeedGetPosts: 'app.bsky.feed.getPosts',
3543 AppBskyFeedPostgate: 'app.bsky.feed.postgate',
3544 AppBskyFeedThreadgate: 'app.bsky.feed.threadgate',
3545 AppBskyGraphDefs: 'app.bsky.graph.defs',
3546 AppBskyNotificationDefs: 'app.bsky.notification.defs',
3547 AppBskyRichtextFacet: 'app.bsky.richtext.facet',
3548 ComAtprotoLabelDefs: 'com.atproto.label.defs',
3549 ComAtprotoRepoStrongRef: 'com.atproto.repo.strongRef',
3550 PartyWheyAppBskyActorDefs: 'party.whey.app.bsky.actor.defs',
3551 PartyWheyAppBskyFeedDefs: 'party.whey.app.bsky.feed.defs',
3552 PartyWheyAppBskyFeedGetActorLikesPartial:
3553 'party.whey.app.bsky.feed.getActorLikesPartial',
3554 PartyWheyAppBskyFeedGetAuthorFeedPartial:
3555 'party.whey.app.bsky.feed.getAuthorFeedPartial',
3556 PartyWheyAppBskyFeedGetLikesPartial:
3557 'party.whey.app.bsky.feed.getLikesPartial',
3558 PartyWheyAppBskyFeedGetListFeedPartial:
3559 'party.whey.app.bsky.feed.getListFeedPartial',
3560 PartyWheyAppBskyFeedGetPostThreadPartial:
3561 'party.whey.app.bsky.feed.getPostThreadPartial',
3562 PartyWheyAppBskyFeedGetQuotesPartial:
3563 'party.whey.app.bsky.feed.getQuotesPartial',
3564 PartyWheyAppBskyFeedGetRepostedByPartial:
3565 'party.whey.app.bsky.feed.getRepostedByPartial',
3566} as const