@atproto/ozone
Version:
Backend service for moderating the Bluesky network.
1,812 lines (1,810 loc) • 519 kB
text/typescript
/**
* GENERATED CODE - DO NOT MODIFY
*/
import {
type LexiconDoc,
Lexicons,
ValidationError,
type ValidationResult,
} from '@atproto/lexicon'
import { type $Typed, is$typed, maybe$typed } from './util.js'
export const schemaDict = {
AppBskyActorDefs: {
lexicon: 1,
id: 'app.bsky.actor.defs',
defs: {
profileViewBasic: {
type: 'object',
required: ['did', 'handle'],
properties: {
did: {
type: 'string',
format: 'did',
},
handle: {
type: 'string',
format: 'handle',
},
displayName: {
type: 'string',
maxGraphemes: 64,
maxLength: 640,
},
avatar: {
type: 'string',
format: 'uri',
},
associated: {
type: 'ref',
ref: 'lex:app.bsky.actor.defs#profileAssociated',
},
viewer: {
type: 'ref',
ref: 'lex:app.bsky.actor.defs#viewerState',
},
labels: {
type: 'array',
items: {
type: 'ref',
ref: 'lex:com.atproto.label.defs#label',
},
},
createdAt: {
type: 'string',
format: 'datetime',
},
verification: {
type: 'ref',
ref: 'lex:app.bsky.actor.defs#verificationState',
},
status: {
type: 'ref',
ref: 'lex:app.bsky.actor.defs#statusView',
},
},
},
profileView: {
type: 'object',
required: ['did', 'handle'],
properties: {
did: {
type: 'string',
format: 'did',
},
handle: {
type: 'string',
format: 'handle',
},
displayName: {
type: 'string',
maxGraphemes: 64,
maxLength: 640,
},
description: {
type: 'string',
maxGraphemes: 256,
maxLength: 2560,
},
avatar: {
type: 'string',
format: 'uri',
},
associated: {
type: 'ref',
ref: 'lex:app.bsky.actor.defs#profileAssociated',
},
indexedAt: {
type: 'string',
format: 'datetime',
},
createdAt: {
type: 'string',
format: 'datetime',
},
viewer: {
type: 'ref',
ref: 'lex:app.bsky.actor.defs#viewerState',
},
labels: {
type: 'array',
items: {
type: 'ref',
ref: 'lex:com.atproto.label.defs#label',
},
},
verification: {
type: 'ref',
ref: 'lex:app.bsky.actor.defs#verificationState',
},
status: {
type: 'ref',
ref: 'lex:app.bsky.actor.defs#statusView',
},
},
},
profileViewDetailed: {
type: 'object',
required: ['did', 'handle'],
properties: {
did: {
type: 'string',
format: 'did',
},
handle: {
type: 'string',
format: 'handle',
},
displayName: {
type: 'string',
maxGraphemes: 64,
maxLength: 640,
},
description: {
type: 'string',
maxGraphemes: 256,
maxLength: 2560,
},
avatar: {
type: 'string',
format: 'uri',
},
banner: {
type: 'string',
format: 'uri',
},
followersCount: {
type: 'integer',
},
followsCount: {
type: 'integer',
},
postsCount: {
type: 'integer',
},
associated: {
type: 'ref',
ref: 'lex:app.bsky.actor.defs#profileAssociated',
},
joinedViaStarterPack: {
type: 'ref',
ref: 'lex:app.bsky.graph.defs#starterPackViewBasic',
},
indexedAt: {
type: 'string',
format: 'datetime',
},
createdAt: {
type: 'string',
format: 'datetime',
},
viewer: {
type: 'ref',
ref: 'lex:app.bsky.actor.defs#viewerState',
},
labels: {
type: 'array',
items: {
type: 'ref',
ref: 'lex:com.atproto.label.defs#label',
},
},
pinnedPost: {
type: 'ref',
ref: 'lex:com.atproto.repo.strongRef',
},
verification: {
type: 'ref',
ref: 'lex:app.bsky.actor.defs#verificationState',
},
status: {
type: 'ref',
ref: 'lex:app.bsky.actor.defs#statusView',
},
},
},
profileAssociated: {
type: 'object',
properties: {
lists: {
type: 'integer',
},
feedgens: {
type: 'integer',
},
starterPacks: {
type: 'integer',
},
labeler: {
type: 'boolean',
},
chat: {
type: 'ref',
ref: 'lex:app.bsky.actor.defs#profileAssociatedChat',
},
activitySubscription: {
type: 'ref',
ref: 'lex:app.bsky.actor.defs#profileAssociatedActivitySubscription',
},
},
},
profileAssociatedChat: {
type: 'object',
required: ['allowIncoming'],
properties: {
allowIncoming: {
type: 'string',
knownValues: ['all', 'none', 'following'],
},
},
},
profileAssociatedActivitySubscription: {
type: 'object',
required: ['allowSubscriptions'],
properties: {
allowSubscriptions: {
type: 'string',
knownValues: ['followers', 'mutuals', 'none'],
},
},
},
viewerState: {
type: 'object',
description:
"Metadata about the requesting account's relationship with the subject account. Only has meaningful content for authed requests.",
properties: {
muted: {
type: 'boolean',
},
mutedByList: {
type: 'ref',
ref: 'lex:app.bsky.graph.defs#listViewBasic',
},
blockedBy: {
type: 'boolean',
},
blocking: {
type: 'string',
format: 'at-uri',
},
blockingByList: {
type: 'ref',
ref: 'lex:app.bsky.graph.defs#listViewBasic',
},
following: {
type: 'string',
format: 'at-uri',
},
followedBy: {
type: 'string',
format: 'at-uri',
},
knownFollowers: {
description:
'This property is present only in selected cases, as an optimization.',
type: 'ref',
ref: 'lex:app.bsky.actor.defs#knownFollowers',
},
activitySubscription: {
description:
'This property is present only in selected cases, as an optimization.',
type: 'ref',
ref: 'lex:app.bsky.notification.defs#activitySubscription',
},
},
},
knownFollowers: {
type: 'object',
description: "The subject's followers whom you also follow",
required: ['count', 'followers'],
properties: {
count: {
type: 'integer',
},
followers: {
type: 'array',
minLength: 0,
maxLength: 5,
items: {
type: 'ref',
ref: 'lex:app.bsky.actor.defs#profileViewBasic',
},
},
},
},
verificationState: {
type: 'object',
description:
'Represents the verification information about the user this object is attached to.',
required: ['verifications', 'verifiedStatus', 'trustedVerifierStatus'],
properties: {
verifications: {
type: 'array',
description:
'All verifications issued by trusted verifiers on behalf of this user. Verifications by untrusted verifiers are not included.',
items: {
type: 'ref',
ref: 'lex:app.bsky.actor.defs#verificationView',
},
},
verifiedStatus: {
type: 'string',
description: "The user's status as a verified account.",
knownValues: ['valid', 'invalid', 'none'],
},
trustedVerifierStatus: {
type: 'string',
description: "The user's status as a trusted verifier.",
knownValues: ['valid', 'invalid', 'none'],
},
},
},
verificationView: {
type: 'object',
description: 'An individual verification for an associated subject.',
required: ['issuer', 'uri', 'isValid', 'createdAt'],
properties: {
issuer: {
type: 'string',
description: 'The user who issued this verification.',
format: 'did',
},
uri: {
type: 'string',
description: 'The AT-URI of the verification record.',
format: 'at-uri',
},
isValid: {
type: 'boolean',
description:
'True if the verification passes validation, otherwise false.',
},
createdAt: {
type: 'string',
description: 'Timestamp when the verification was created.',
format: 'datetime',
},
},
},
preferences: {
type: 'array',
items: {
type: 'union',
refs: [
'lex:app.bsky.actor.defs#adultContentPref',
'lex:app.bsky.actor.defs#contentLabelPref',
'lex:app.bsky.actor.defs#savedFeedsPref',
'lex:app.bsky.actor.defs#savedFeedsPrefV2',
'lex:app.bsky.actor.defs#personalDetailsPref',
'lex:app.bsky.actor.defs#feedViewPref',
'lex:app.bsky.actor.defs#threadViewPref',
'lex:app.bsky.actor.defs#interestsPref',
'lex:app.bsky.actor.defs#mutedWordsPref',
'lex:app.bsky.actor.defs#hiddenPostsPref',
'lex:app.bsky.actor.defs#bskyAppStatePref',
'lex:app.bsky.actor.defs#labelersPref',
'lex:app.bsky.actor.defs#postInteractionSettingsPref',
'lex:app.bsky.actor.defs#verificationPrefs',
],
},
},
adultContentPref: {
type: 'object',
required: ['enabled'],
properties: {
enabled: {
type: 'boolean',
default: false,
},
},
},
contentLabelPref: {
type: 'object',
required: ['label', 'visibility'],
properties: {
labelerDid: {
type: 'string',
description:
'Which labeler does this preference apply to? If undefined, applies globally.',
format: 'did',
},
label: {
type: 'string',
},
visibility: {
type: 'string',
knownValues: ['ignore', 'show', 'warn', 'hide'],
},
},
},
savedFeed: {
type: 'object',
required: ['id', 'type', 'value', 'pinned'],
properties: {
id: {
type: 'string',
},
type: {
type: 'string',
knownValues: ['feed', 'list', 'timeline'],
},
value: {
type: 'string',
},
pinned: {
type: 'boolean',
},
},
},
savedFeedsPrefV2: {
type: 'object',
required: ['items'],
properties: {
items: {
type: 'array',
items: {
type: 'ref',
ref: 'lex:app.bsky.actor.defs#savedFeed',
},
},
},
},
savedFeedsPref: {
type: 'object',
required: ['pinned', 'saved'],
properties: {
pinned: {
type: 'array',
items: {
type: 'string',
format: 'at-uri',
},
},
saved: {
type: 'array',
items: {
type: 'string',
format: 'at-uri',
},
},
timelineIndex: {
type: 'integer',
},
},
},
personalDetailsPref: {
type: 'object',
properties: {
birthDate: {
type: 'string',
format: 'datetime',
description: 'The birth date of account owner.',
},
},
},
feedViewPref: {
type: 'object',
required: ['feed'],
properties: {
feed: {
type: 'string',
description:
'The URI of the feed, or an identifier which describes the feed.',
},
hideReplies: {
type: 'boolean',
description: 'Hide replies in the feed.',
},
hideRepliesByUnfollowed: {
type: 'boolean',
description:
'Hide replies in the feed if they are not by followed users.',
default: true,
},
hideRepliesByLikeCount: {
type: 'integer',
description:
'Hide replies in the feed if they do not have this number of likes.',
},
hideReposts: {
type: 'boolean',
description: 'Hide reposts in the feed.',
},
hideQuotePosts: {
type: 'boolean',
description: 'Hide quote posts in the feed.',
},
},
},
threadViewPref: {
type: 'object',
properties: {
sort: {
type: 'string',
description: 'Sorting mode for threads.',
knownValues: [
'oldest',
'newest',
'most-likes',
'random',
'hotness',
],
},
prioritizeFollowedUsers: {
type: 'boolean',
description: 'Show followed users at the top of all replies.',
},
},
},
interestsPref: {
type: 'object',
required: ['tags'],
properties: {
tags: {
type: 'array',
maxLength: 100,
items: {
type: 'string',
maxLength: 640,
maxGraphemes: 64,
},
description:
"A list of tags which describe the account owner's interests gathered during onboarding.",
},
},
},
mutedWordTarget: {
type: 'string',
knownValues: ['content', 'tag'],
maxLength: 640,
maxGraphemes: 64,
},
mutedWord: {
type: 'object',
description: 'A word that the account owner has muted.',
required: ['value', 'targets'],
properties: {
id: {
type: 'string',
},
value: {
type: 'string',
description: 'The muted word itself.',
maxLength: 10000,
maxGraphemes: 1000,
},
targets: {
type: 'array',
description: 'The intended targets of the muted word.',
items: {
type: 'ref',
ref: 'lex:app.bsky.actor.defs#mutedWordTarget',
},
},
actorTarget: {
type: 'string',
description:
'Groups of users to apply the muted word to. If undefined, applies to all users.',
knownValues: ['all', 'exclude-following'],
default: 'all',
},
expiresAt: {
type: 'string',
format: 'datetime',
description:
'The date and time at which the muted word will expire and no longer be applied.',
},
},
},
mutedWordsPref: {
type: 'object',
required: ['items'],
properties: {
items: {
type: 'array',
items: {
type: 'ref',
ref: 'lex:app.bsky.actor.defs#mutedWord',
},
description: 'A list of words the account owner has muted.',
},
},
},
hiddenPostsPref: {
type: 'object',
required: ['items'],
properties: {
items: {
type: 'array',
items: {
type: 'string',
format: 'at-uri',
},
description:
'A list of URIs of posts the account owner has hidden.',
},
},
},
labelersPref: {
type: 'object',
required: ['labelers'],
properties: {
labelers: {
type: 'array',
items: {
type: 'ref',
ref: 'lex:app.bsky.actor.defs#labelerPrefItem',
},
},
},
},
labelerPrefItem: {
type: 'object',
required: ['did'],
properties: {
did: {
type: 'string',
format: 'did',
},
},
},
bskyAppStatePref: {
description:
"A grab bag of state that's specific to the bsky.app program. Third-party apps shouldn't use this.",
type: 'object',
properties: {
activeProgressGuide: {
type: 'ref',
ref: 'lex:app.bsky.actor.defs#bskyAppProgressGuide',
},
queuedNudges: {
description:
'An array of tokens which identify nudges (modals, popups, tours, highlight dots) that should be shown to the user.',
type: 'array',
maxLength: 1000,
items: {
type: 'string',
maxLength: 100,
},
},
nuxs: {
description: 'Storage for NUXs the user has encountered.',
type: 'array',
maxLength: 100,
items: {
type: 'ref',
ref: 'lex:app.bsky.actor.defs#nux',
},
},
},
},
bskyAppProgressGuide: {
description:
'If set, an active progress guide. Once completed, can be set to undefined. Should have unspecced fields tracking progress.',
type: 'object',
required: ['guide'],
properties: {
guide: {
type: 'string',
maxLength: 100,
},
},
},
nux: {
type: 'object',
description: 'A new user experiences (NUX) storage object',
required: ['id', 'completed'],
properties: {
id: {
type: 'string',
maxLength: 100,
},
completed: {
type: 'boolean',
default: false,
},
data: {
description:
'Arbitrary data for the NUX. The structure is defined by the NUX itself. Limited to 300 characters.',
type: 'string',
maxLength: 3000,
maxGraphemes: 300,
},
expiresAt: {
type: 'string',
format: 'datetime',
description:
'The date and time at which the NUX will expire and should be considered completed.',
},
},
},
verificationPrefs: {
type: 'object',
description: 'Preferences for how verified accounts appear in the app.',
required: [],
properties: {
hideBadges: {
description:
'Hide the blue check badges for verified accounts and trusted verifiers.',
type: 'boolean',
default: false,
},
},
},
postInteractionSettingsPref: {
type: 'object',
description:
'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.',
required: [],
properties: {
threadgateAllowRules: {
description:
'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.',
type: 'array',
maxLength: 5,
items: {
type: 'union',
refs: [
'lex:app.bsky.feed.threadgate#mentionRule',
'lex:app.bsky.feed.threadgate#followerRule',
'lex:app.bsky.feed.threadgate#followingRule',
'lex:app.bsky.feed.threadgate#listRule',
],
},
},
postgateEmbeddingRules: {
description:
'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.',
type: 'array',
maxLength: 5,
items: {
type: 'union',
refs: ['lex:app.bsky.feed.postgate#disableRule'],
},
},
},
},
statusView: {
type: 'object',
required: ['status', 'record'],
properties: {
status: {
type: 'string',
description: 'The status for the account.',
knownValues: ['app.bsky.actor.status#live'],
},
record: {
type: 'unknown',
},
embed: {
type: 'union',
description: 'An optional embed associated with the status.',
refs: ['lex:app.bsky.embed.external#view'],
},
expiresAt: {
type: 'string',
description:
'The date when this status will expire. The application might choose to no longer return the status after expiration.',
format: 'datetime',
},
isActive: {
type: 'boolean',
description:
'True if the status is not expired, false if it is expired. Only present if expiration was set.',
},
},
},
},
},
AppBskyActorGetPreferences: {
lexicon: 1,
id: 'app.bsky.actor.getPreferences',
defs: {
main: {
type: 'query',
description:
'Get private preferences attached to the current account. Expected use is synchronization between multiple devices, and import/export during account migration. Requires auth.',
parameters: {
type: 'params',
properties: {},
},
output: {
encoding: 'application/json',
schema: {
type: 'object',
required: ['preferences'],
properties: {
preferences: {
type: 'ref',
ref: 'lex:app.bsky.actor.defs#preferences',
},
},
},
},
},
},
},
AppBskyActorGetProfile: {
lexicon: 1,
id: 'app.bsky.actor.getProfile',
defs: {
main: {
type: 'query',
description:
'Get detailed profile view of an actor. Does not require auth, but contains relevant metadata with auth.',
parameters: {
type: 'params',
required: ['actor'],
properties: {
actor: {
type: 'string',
format: 'at-identifier',
description: 'Handle or DID of account to fetch profile of.',
},
},
},
output: {
encoding: 'application/json',
schema: {
type: 'ref',
ref: 'lex:app.bsky.actor.defs#profileViewDetailed',
},
},
},
},
},
AppBskyActorGetProfiles: {
lexicon: 1,
id: 'app.bsky.actor.getProfiles',
defs: {
main: {
type: 'query',
description: 'Get detailed profile views of multiple actors.',
parameters: {
type: 'params',
required: ['actors'],
properties: {
actors: {
type: 'array',
items: {
type: 'string',
format: 'at-identifier',
},
maxLength: 25,
},
},
},
output: {
encoding: 'application/json',
schema: {
type: 'object',
required: ['profiles'],
properties: {
profiles: {
type: 'array',
items: {
type: 'ref',
ref: 'lex:app.bsky.actor.defs#profileViewDetailed',
},
},
},
},
},
},
},
},
AppBskyActorGetSuggestions: {
lexicon: 1,
id: 'app.bsky.actor.getSuggestions',
defs: {
main: {
type: 'query',
description:
'Get a list of suggested actors. Expected use is discovery of accounts to follow during new account onboarding.',
parameters: {
type: 'params',
properties: {
limit: {
type: 'integer',
minimum: 1,
maximum: 100,
default: 50,
},
cursor: {
type: 'string',
},
},
},
output: {
encoding: 'application/json',
schema: {
type: 'object',
required: ['actors'],
properties: {
cursor: {
type: 'string',
},
actors: {
type: 'array',
items: {
type: 'ref',
ref: 'lex:app.bsky.actor.defs#profileView',
},
},
recId: {
type: 'integer',
description:
'Snowflake for this recommendation, use when submitting recommendation events.',
},
},
},
},
},
},
},
AppBskyActorProfile: {
lexicon: 1,
id: 'app.bsky.actor.profile',
defs: {
main: {
type: 'record',
description: 'A declaration of a Bluesky account profile.',
key: 'literal:self',
record: {
type: 'object',
properties: {
displayName: {
type: 'string',
maxGraphemes: 64,
maxLength: 640,
},
description: {
type: 'string',
description: 'Free-form profile description text.',
maxGraphemes: 256,
maxLength: 2560,
},
avatar: {
type: 'blob',
description:
"Small image to be displayed next to posts from account. AKA, 'profile picture'",
accept: ['image/png', 'image/jpeg'],
maxSize: 1000000,
},
banner: {
type: 'blob',
description:
'Larger horizontal image to display behind profile view.',
accept: ['image/png', 'image/jpeg'],
maxSize: 1000000,
},
labels: {
type: 'union',
description:
'Self-label values, specific to the Bluesky application, on the overall account.',
refs: ['lex:com.atproto.label.defs#selfLabels'],
},
joinedViaStarterPack: {
type: 'ref',
ref: 'lex:com.atproto.repo.strongRef',
},
pinnedPost: {
type: 'ref',
ref: 'lex:com.atproto.repo.strongRef',
},
createdAt: {
type: 'string',
format: 'datetime',
},
},
},
},
},
},
AppBskyActorPutPreferences: {
lexicon: 1,
id: 'app.bsky.actor.putPreferences',
defs: {
main: {
type: 'procedure',
description: 'Set the private preferences attached to the account.',
input: {
encoding: 'application/json',
schema: {
type: 'object',
required: ['preferences'],
properties: {
preferences: {
type: 'ref',
ref: 'lex:app.bsky.actor.defs#preferences',
},
},
},
},
},
},
},
AppBskyActorSearchActors: {
lexicon: 1,
id: 'app.bsky.actor.searchActors',
defs: {
main: {
type: 'query',
description:
'Find actors (profiles) matching search criteria. Does not require auth.',
parameters: {
type: 'params',
properties: {
term: {
type: 'string',
description: "DEPRECATED: use 'q' instead.",
},
q: {
type: 'string',
description:
'Search query string. Syntax, phrase, boolean, and faceting is unspecified, but Lucene query syntax is recommended.',
},
limit: {
type: 'integer',
minimum: 1,
maximum: 100,
default: 25,
},
cursor: {
type: 'string',
},
},
},
output: {
encoding: 'application/json',
schema: {
type: 'object',
required: ['actors'],
properties: {
cursor: {
type: 'string',
},
actors: {
type: 'array',
items: {
type: 'ref',
ref: 'lex:app.bsky.actor.defs#profileView',
},
},
},
},
},
},
},
},
AppBskyActorSearchActorsTypeahead: {
lexicon: 1,
id: 'app.bsky.actor.searchActorsTypeahead',
defs: {
main: {
type: 'query',
description:
'Find actor suggestions for a prefix search term. Expected use is for auto-completion during text field entry. Does not require auth.',
parameters: {
type: 'params',
properties: {
term: {
type: 'string',
description: "DEPRECATED: use 'q' instead.",
},
q: {
type: 'string',
description: 'Search query prefix; not a full query string.',
},
limit: {
type: 'integer',
minimum: 1,
maximum: 100,
default: 10,
},
},
},
output: {
encoding: 'application/json',
schema: {
type: 'object',
required: ['actors'],
properties: {
actors: {
type: 'array',
items: {
type: 'ref',
ref: 'lex:app.bsky.actor.defs#profileViewBasic',
},
},
},
},
},
},
},
},
AppBskyActorStatus: {
lexicon: 1,
id: 'app.bsky.actor.status',
defs: {
main: {
type: 'record',
description: 'A declaration of a Bluesky account status.',
key: 'literal:self',
record: {
type: 'object',
required: ['status', 'createdAt'],
properties: {
status: {
type: 'string',
description: 'The status for the account.',
knownValues: ['app.bsky.actor.status#live'],
},
embed: {
type: 'union',
description: 'An optional embed associated with the status.',
refs: ['lex:app.bsky.embed.external'],
},
durationMinutes: {
type: 'integer',
description:
'The duration of the status in minutes. Applications can choose to impose minimum and maximum limits.',
minimum: 1,
},
createdAt: {
type: 'string',
format: 'datetime',
},
},
},
},
live: {
type: 'token',
description:
'Advertises an account as currently offering live content.',
},
},
},
AppBskyEmbedDefs: {
lexicon: 1,
id: 'app.bsky.embed.defs',
defs: {
aspectRatio: {
type: 'object',
description:
'width:height represents an aspect ratio. It may be approximate, and may not correspond to absolute dimensions in any given unit.',
required: ['width', 'height'],
properties: {
width: {
type: 'integer',
minimum: 1,
},
height: {
type: 'integer',
minimum: 1,
},
},
},
},
},
AppBskyEmbedExternal: {
lexicon: 1,
id: 'app.bsky.embed.external',
defs: {
main: {
type: 'object',
description:
"A representation of some externally linked content (eg, a URL and 'card'), embedded in a Bluesky record (eg, a post).",
required: ['external'],
properties: {
external: {
type: 'ref',
ref: 'lex:app.bsky.embed.external#external',
},
},
},
external: {
type: 'object',
required: ['uri', 'title', 'description'],
properties: {
uri: {
type: 'string',
format: 'uri',
},
title: {
type: 'string',
},
description: {
type: 'string',
},
thumb: {
type: 'blob',
accept: ['image/*'],
maxSize: 1000000,
},
},
},
view: {
type: 'object',
required: ['external'],
properties: {
external: {
type: 'ref',
ref: 'lex:app.bsky.embed.external#viewExternal',
},
},
},
viewExternal: {
type: 'object',
required: ['uri', 'title', 'description'],
properties: {
uri: {
type: 'string',
format: 'uri',
},
title: {
type: 'string',
},
description: {
type: 'string',
},
thumb: {
type: 'string',
format: 'uri',
},
},
},
},
},
AppBskyEmbedImages: {
lexicon: 1,
id: 'app.bsky.embed.images',
description: 'A set of images embedded in a Bluesky record (eg, a post).',
defs: {
main: {
type: 'object',
required: ['images'],
properties: {
images: {
type: 'array',
items: {
type: 'ref',
ref: 'lex:app.bsky.embed.images#image',
},
maxLength: 4,
},
},
},
image: {
type: 'object',
required: ['image', 'alt'],
properties: {
image: {
type: 'blob',
accept: ['image/*'],
maxSize: 1000000,
},
alt: {
type: 'string',
description:
'Alt text description of the image, for accessibility.',
},
aspectRatio: {
type: 'ref',
ref: 'lex:app.bsky.embed.defs#aspectRatio',
},
},
},
view: {
type: 'object',
required: ['images'],
properties: {
images: {
type: 'array',
items: {
type: 'ref',
ref: 'lex:app.bsky.embed.images#viewImage',
},
maxLength: 4,
},
},
},
viewImage: {
type: 'object',
required: ['thumb', 'fullsize', 'alt'],
properties: {
thumb: {
type: 'string',
format: 'uri',
description:
'Fully-qualified URL where a thumbnail of the image can be fetched. For example, CDN location provided by the App View.',
},
fullsize: {
type: 'string',
format: 'uri',
description:
'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.',
},
alt: {
type: 'string',
description:
'Alt text description of the image, for accessibility.',
},
aspectRatio: {
type: 'ref',
ref: 'lex:app.bsky.embed.defs#aspectRatio',
},
},
},
},
},
AppBskyEmbedRecord: {
lexicon: 1,
id: 'app.bsky.embed.record',
description:
'A representation of a record embedded in a Bluesky record (eg, a post). For example, a quote-post, or sharing a feed generator record.',
defs: {
main: {
type: 'object',
required: ['record'],
properties: {
record: {
type: 'ref',
ref: 'lex:com.atproto.repo.strongRef',
},
},
},
view: {
type: 'object',
required: ['record'],
properties: {
record: {
type: 'union',
refs: [
'lex:app.bsky.embed.record#viewRecord',
'lex:app.bsky.embed.record#viewNotFound',
'lex:app.bsky.embed.record#viewBlocked',
'lex:app.bsky.embed.record#viewDetached',
'lex:app.bsky.feed.defs#generatorView',
'lex:app.bsky.graph.defs#listView',
'lex:app.bsky.labeler.defs#labelerView',
'lex:app.bsky.graph.defs#starterPackViewBasic',
],
},
},
},
viewRecord: {
type: 'object',
required: ['uri', 'cid', 'author', 'value', 'indexedAt'],
properties: {
uri: {
type: 'string',
format: 'at-uri',
},
cid: {
type: 'string',
format: 'cid',
},
author: {
type: 'ref',
ref: 'lex:app.bsky.actor.defs#profileViewBasic',
},
value: {
type: 'unknown',
description: 'The record data itself.',
},
labels: {
type: 'array',
items: {
type: 'ref',
ref: 'lex:com.atproto.label.defs#label',
},
},
replyCount: {
type: 'integer',
},
repostCount: {
type: 'integer',
},
likeCount: {
type: 'integer',
},
quoteCount: {
type: 'integer',
},
embeds: {
type: 'array',
items: {
type: 'union',
refs: [
'lex:app.bsky.embed.images#view',
'lex:app.bsky.embed.video#view',
'lex:app.bsky.embed.external#view',
'lex:app.bsky.embed.record#view',
'lex:app.bsky.embed.recordWithMedia#view',
],
},
},
indexedAt: {
type: 'string',
format: 'datetime',
},
},
},
viewNotFound: {
type: 'object',
required: ['uri', 'notFound'],
properties: {
uri: {
type: 'string',
format: 'at-uri',
},
notFound: {
type: 'boolean',
const: true,
},
},
},
viewBlocked: {
type: 'object',
required: ['uri', 'blocked', 'author'],
properties: {
uri: {
type: 'string',
format: 'at-uri',
},
blocked: {
type: 'boolean',
const: true,
},
author: {
type: 'ref',
ref: 'lex:app.bsky.feed.defs#blockedAuthor',
},
},
},
viewDetached: {
type: 'object',
required: ['uri', 'detached'],
properties: {
uri: {
type: 'string',
format: 'at-uri',
},
detached: {
type: 'boolean',
const: true,
},
},
},
},
},
AppBskyEmbedRecordWithMedia: {
lexicon: 1,
id: 'app.bsky.embed.recordWithMedia',
description:
'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.',
defs: {
main: {
type: 'object',
required: ['record', 'media'],
properties: {
record: {
type: 'ref',
ref: 'lex:app.bsky.embed.record',
},
media: {
type: 'union',
refs: [
'lex:app.bsky.embed.images',
'lex:app.bsky.embed.video',
'lex:app.bsky.embed.external',
],
},
},
},
view: {
type: 'object',
required: ['record', 'media'],
properties: {
record: {
type: 'ref',
ref: 'lex:app.bsky.embed.record#view',
},
media: {
type: 'union',
refs: [
'lex:app.bsky.embed.images#view',
'lex:app.bsky.embed.video#view',
'lex:app.bsky.embed.external#view',
],
},
},
},
},
},
AppBskyEmbedVideo: {
lexicon: 1,
id: 'app.bsky.embed.video',
description: 'A video embedded in a Bluesky record (eg, a post).',
defs: {
main: {
type: 'object',
required: ['video'],
properties: {
video: {
type: 'blob',
description:
'The mp4 video file. May be up to 100mb, formerly limited to 50mb.',
accept: ['video/mp4'],
maxSize: 100000000,
},
captions: {
type: 'array',
items: {
type: 'ref',
ref: 'lex:app.bsky.embed.video#caption',
},
maxLength: 20,
},
alt: {
type: 'string',
description:
'Alt text description of the video, for accessibility.',
maxGraphemes: 1000,
maxLength: 10000,
},
aspectRatio: {
type: 'ref',
ref: 'lex:app.bsky.embed.defs#aspectRatio',
},
},
},
caption: {
type: 'object',
required: ['lang', 'file'],
properties: {
lang: {
type: 'string',
format: 'language',
},
file: {
type: 'blob',
accept: ['text/vtt'],
maxSize: 20000,
},
},
},
view: {
type: 'object',
required: ['cid', 'playlist'],
properties: {
cid: {
type: 'string',
format: 'cid',
},
playlist: {
type: 'string',
format: 'uri',
},
thumbnail: {
type: 'string',
format: 'uri',
},
alt: {
type: 'string',
maxGraphemes: 1000,
maxLength: 10000,
},
aspectRatio: {
type: 'ref',
ref: 'lex:app.bsky.embed.defs#aspectRatio',
},
},
},
},
},
AppBskyFeedDefs: {
lexicon: 1,
id: 'app.bsky.feed.defs',
defs: {
postView: {
type: 'object',
required: ['uri', 'cid', 'author', 'record', 'indexedAt'],
properties: {
uri: {
type: 'string',
format: 'at-uri',
},
cid: {
type: 'string',
format: 'cid',
},
author: {
type: 'ref',
ref: 'lex:app.bsky.actor.defs#profileViewBasic',
},
record: {
type: 'unknown',
},
embed: {
type: 'union',
refs: [
'lex:app.bsky.embed.images#view',
'lex:app.bsky.embed.video#view',
'lex:app.bsky.embed.external#view',
'lex:app.bsky.embed.record#view',
'lex:app.bsky.embed.recordWithMedia#view',
],
},
replyCount: {
type: 'integer',
},
repostCount: {
type: 'integer',
},
likeCount: {
type: 'integer',
},
quoteCount: {
type: 'integer',
},
indexedAt: {
type: 'string',
format: 'datetime',
},
viewer: {
type: 'ref',
ref: 'lex:app.bsky.feed.defs#viewerState',
},
labels: {
type: 'array',
items: {
type: 'ref',
ref: 'lex:com.atproto.label.defs#label',
},
},
threadgate: {
type: 'ref',
ref: 'lex:app.bsky.feed.defs#threadgateView',
},
},
},
viewerState: {
type: 'object',
description:
"Metadata about the requesting account's relationship with the subject content. Only has meaningful content for authed requests.",
properties: {
repost: {
type: 'string',
format: 'at-uri',
},
like: {
type: 'string',
format: 'at-uri',
},
threadMuted: {
type: 'boolean',
},
replyDisabled: {
type: 'boolean',
},
embeddingDisabled: {
type: 'boolean',
},
pinned: {
type: 'boolean',
},
},
},
threadContext: {
type: 'object',
description:
'Metadata about this post within the context of the thread it is in.',
properties: {
rootAuthorLike: {
type: 'string',
format: 'at-uri',
},
},
},
feedViewPost: {
type: 'object',
required: ['post'],
properties: {
post: {
type: 'ref',
ref: 'lex:app.bsky.feed.defs#postView',
},
reply: {
type: 'ref',
ref: 'lex:app.bsky.feed.defs#replyRef',
},
reason: {
type: 'union',
refs: [
'lex:app.bsky.feed.defs#reasonRepost',
'lex:app.bsky.feed.defs#reasonPin',
],
},
feedContext: {
type: 'string',
description:
'Context provided by feed generator that may be passed back alongside interactions.',
maxLength: 2000,
},
reqId: {
type: 'string',
description:
'Unique identifier per request that may be passed back alongside interactions.',
maxLength: 100,
},
},
},
replyRef: {
type: 'object',
required: ['root', 'parent'],
properties: {
root: {
type: 'union',
refs: [
'lex:app.bsky.feed.defs#postView',
'lex:app.bsky.feed.defs#notFoundPost',
'lex:app.bsky.feed.defs#blockedPost',
],
},
parent: {
type: 'union',
refs: [
'lex:app.bsky.feed.defs#postView',
'lex:app.bsky.feed.defs#notFoundPost',
'lex:app.bsky.feed.defs#blockedPost',
],
},
grandparentAuthor: {
type: 'ref',
ref: 'lex:app.bsky.actor.defs#profileViewBasic',
description:
'When parent is a reply to another post, this is the author of that post.',
},
},
},
reasonRepost: {
type: 'object',
required: ['by', 'indexedAt'],
properties: {
by: {
type: 'ref',
ref: 'lex:app.bsky.actor.defs#profileViewBasic',
},
uri: {
type: 'string',
format: 'at-uri',
},
cid: {
type: 'string',
format: 'cid',
},
indexedAt: {
type: 'string',
format: 'datetime',
},
},
},
reasonPin: {
type: 'object',
properties: {},
},
threadViewPost: {
type: 'object',
required: ['post'],
properties: {
post: {
type: 'ref',
ref: 'lex:app.bsky.feed.defs#postView',
},
parent: {
type: 'union',
refs: [
'lex:app.bsky.feed.defs#threadViewPost',
'lex:app.bsky.feed.defs#notFoundPost',
'lex:app.bsky.feed.defs#blockedPost',