Skip to content

Commit

Permalink
Update lexicons fetched from 41ee177 committed 2023-09-27T21:08:58Z (#…
Browse files Browse the repository at this point in the history
  • Loading branch information
MarshalX authored Sep 28, 2023
1 parent dab0fd0 commit 31eea9a
Show file tree
Hide file tree
Showing 50 changed files with 1,135 additions and 78 deletions.
18 changes: 18 additions & 0 deletions atproto/xrpc_client/models/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -31,6 +31,7 @@
from atproto.xrpc_client.models.app.bsky.feed import like as AppBskyFeedLike
from atproto.xrpc_client.models.app.bsky.feed import post as AppBskyFeedPost
from atproto.xrpc_client.models.app.bsky.feed import repost as AppBskyFeedRepost
from atproto.xrpc_client.models.app.bsky.feed import search_posts as AppBskyFeedSearchPosts
from atproto.xrpc_client.models.app.bsky.feed import threadgate as AppBskyFeedThreadgate
from atproto.xrpc_client.models.app.bsky.graph import block as AppBskyGraphBlock
from atproto.xrpc_client.models.app.bsky.graph import defs as AppBskyGraphDefs
Expand Down Expand Up @@ -59,11 +60,14 @@
from atproto.xrpc_client.models.app.bsky.notification import update_seen as AppBskyNotificationUpdateSeen
from atproto.xrpc_client.models.app.bsky.richtext import facet as AppBskyRichtextFacet
from atproto.xrpc_client.models.app.bsky.unspecced import apply_labels as AppBskyUnspeccedApplyLabels
from atproto.xrpc_client.models.app.bsky.unspecced import defs as AppBskyUnspeccedDefs
from atproto.xrpc_client.models.app.bsky.unspecced import get_popular as AppBskyUnspeccedGetPopular
from atproto.xrpc_client.models.app.bsky.unspecced import (
get_popular_feed_generators as AppBskyUnspeccedGetPopularFeedGenerators,
)
from atproto.xrpc_client.models.app.bsky.unspecced import get_timeline_skeleton as AppBskyUnspeccedGetTimelineSkeleton
from atproto.xrpc_client.models.app.bsky.unspecced import search_actors_skeleton as AppBskyUnspeccedSearchActorsSkeleton
from atproto.xrpc_client.models.app.bsky.unspecced import search_posts_skeleton as AppBskyUnspeccedSearchPostsSkeleton
from atproto.xrpc_client.models.com.atproto.admin import defs as ComAtprotoAdminDefs
from atproto.xrpc_client.models.com.atproto.admin import disable_account_invites as ComAtprotoAdminDisableAccountInvites
from atproto.xrpc_client.models.com.atproto.admin import disable_invite_codes as ComAtprotoAdminDisableInviteCodes
Expand Down Expand Up @@ -102,6 +106,7 @@
from atproto.xrpc_client.models.com.atproto.repo import put_record as ComAtprotoRepoPutRecord
from atproto.xrpc_client.models.com.atproto.repo import strong_ref as ComAtprotoRepoStrongRef
from atproto.xrpc_client.models.com.atproto.repo import upload_blob as ComAtprotoRepoUploadBlob
from atproto.xrpc_client.models.com.atproto.server import confirm_email as ComAtprotoServerConfirmEmail
from atproto.xrpc_client.models.com.atproto.server import create_account as ComAtprotoServerCreateAccount
from atproto.xrpc_client.models.com.atproto.server import create_app_password as ComAtprotoServerCreateAppPassword
from atproto.xrpc_client.models.com.atproto.server import create_invite_code as ComAtprotoServerCreateInviteCode
Expand All @@ -118,9 +123,14 @@
from atproto.xrpc_client.models.com.atproto.server import list_app_passwords as ComAtprotoServerListAppPasswords
from atproto.xrpc_client.models.com.atproto.server import refresh_session as ComAtprotoServerRefreshSession
from atproto.xrpc_client.models.com.atproto.server import request_account_delete as ComAtprotoServerRequestAccountDelete
from atproto.xrpc_client.models.com.atproto.server import (
request_email_confirmation as ComAtprotoServerRequestEmailConfirmation,
)
from atproto.xrpc_client.models.com.atproto.server import request_email_update as ComAtprotoServerRequestEmailUpdate
from atproto.xrpc_client.models.com.atproto.server import request_password_reset as ComAtprotoServerRequestPasswordReset
from atproto.xrpc_client.models.com.atproto.server import reset_password as ComAtprotoServerResetPassword
from atproto.xrpc_client.models.com.atproto.server import revoke_app_password as ComAtprotoServerRevokeAppPassword
from atproto.xrpc_client.models.com.atproto.server import update_email as ComAtprotoServerUpdateEmail
from atproto.xrpc_client.models.com.atproto.sync import get_blob as ComAtprotoSyncGetBlob
from atproto.xrpc_client.models.com.atproto.sync import get_blocks as ComAtprotoSyncGetBlocks
from atproto.xrpc_client.models.com.atproto.sync import get_checkout as ComAtprotoSyncGetCheckout
Expand Down Expand Up @@ -177,6 +187,7 @@ class _Ids:
AppBskyFeedLike: str = 'app.bsky.feed.like'
AppBskyFeedPost: str = 'app.bsky.feed.post'
AppBskyFeedRepost: str = 'app.bsky.feed.repost'
AppBskyFeedSearchPosts: str = 'app.bsky.feed.searchPosts'
AppBskyFeedThreadgate: str = 'app.bsky.feed.threadgate'
AppBskyGraphBlock: str = 'app.bsky.graph.block'
AppBskyGraphDefs: str = 'app.bsky.graph.defs'
Expand All @@ -203,9 +214,12 @@ class _Ids:
AppBskyNotificationUpdateSeen: str = 'app.bsky.notification.updateSeen'
AppBskyRichtextFacet: str = 'app.bsky.richtext.facet'
AppBskyUnspeccedApplyLabels: str = 'app.bsky.unspecced.applyLabels'
AppBskyUnspeccedDefs: str = 'app.bsky.unspecced.defs'
AppBskyUnspeccedGetPopular: str = 'app.bsky.unspecced.getPopular'
AppBskyUnspeccedGetPopularFeedGenerators: str = 'app.bsky.unspecced.getPopularFeedGenerators'
AppBskyUnspeccedGetTimelineSkeleton: str = 'app.bsky.unspecced.getTimelineSkeleton'
AppBskyUnspeccedSearchActorsSkeleton: str = 'app.bsky.unspecced.searchActorsSkeleton'
AppBskyUnspeccedSearchPostsSkeleton: str = 'app.bsky.unspecced.searchPostsSkeleton'
ComAtprotoAdminDefs: str = 'com.atproto.admin.defs'
ComAtprotoAdminDisableAccountInvites: str = 'com.atproto.admin.disableAccountInvites'
ComAtprotoAdminDisableInviteCodes: str = 'com.atproto.admin.disableInviteCodes'
Expand Down Expand Up @@ -240,6 +254,7 @@ class _Ids:
ComAtprotoRepoPutRecord: str = 'com.atproto.repo.putRecord'
ComAtprotoRepoStrongRef: str = 'com.atproto.repo.strongRef'
ComAtprotoRepoUploadBlob: str = 'com.atproto.repo.uploadBlob'
ComAtprotoServerConfirmEmail: str = 'com.atproto.server.confirmEmail'
ComAtprotoServerCreateAccount: str = 'com.atproto.server.createAccount'
ComAtprotoServerCreateAppPassword: str = 'com.atproto.server.createAppPassword'
ComAtprotoServerCreateInviteCode: str = 'com.atproto.server.createInviteCode'
Expand All @@ -254,9 +269,12 @@ class _Ids:
ComAtprotoServerListAppPasswords: str = 'com.atproto.server.listAppPasswords'
ComAtprotoServerRefreshSession: str = 'com.atproto.server.refreshSession'
ComAtprotoServerRequestAccountDelete: str = 'com.atproto.server.requestAccountDelete'
ComAtprotoServerRequestEmailConfirmation: str = 'com.atproto.server.requestEmailConfirmation'
ComAtprotoServerRequestEmailUpdate: str = 'com.atproto.server.requestEmailUpdate'
ComAtprotoServerRequestPasswordReset: str = 'com.atproto.server.requestPasswordReset'
ComAtprotoServerResetPassword: str = 'com.atproto.server.resetPassword'
ComAtprotoServerRevokeAppPassword: str = 'com.atproto.server.revokeAppPassword'
ComAtprotoServerUpdateEmail: str = 'com.atproto.server.updateEmail'
ComAtprotoSyncGetBlob: str = 'com.atproto.sync.getBlob'
ComAtprotoSyncGetBlocks: str = 'com.atproto.sync.getBlocks'
ComAtprotoSyncGetCheckout: str = 'com.atproto.sync.getCheckout'
Expand Down
36 changes: 36 additions & 0 deletions atproto/xrpc_client/models/app/bsky/actor/defs.py
Original file line number Diff line number Diff line change
Expand Up @@ -96,6 +96,8 @@ class ViewerState(base.ModelBase):
'models.AppBskyActorDefs.ContentLabelPref',
'models.AppBskyActorDefs.SavedFeedsPref',
'models.AppBskyActorDefs.PersonalDetailsPref',
'models.AppBskyActorDefs.FeedViewPref',
'models.AppBskyActorDefs.ThreadViewPref',
],
Field(discriminator='py_type'),
]
Expand Down Expand Up @@ -146,3 +148,37 @@ class PersonalDetailsPref(base.ModelBase):
py_type: te.Literal['app.bsky.actor.defs#personalDetailsPref'] = Field(
default='app.bsky.actor.defs#personalDetailsPref', alias='$type', frozen=True
)


class FeedViewPref(base.ModelBase):

"""Definition model for :obj:`app.bsky.actor.defs`."""

feed: str #: The URI of the feed, or an identifier which describes the feed.
hide_quote_posts: t.Optional[bool] = Field(default=None, alias='hideQuotePosts') #: Hide quote posts in the feed.
hide_replies: t.Optional[bool] = Field(default=None, alias='hideReplies') #: Hide replies in the feed.
hide_replies_by_like_count: t.Optional[int] = Field(
default=None, alias='hideRepliesByLikeCount'
) #: Hide replies in the feed if they do not have this number of likes.
hide_replies_by_unfollowed: t.Optional[bool] = Field(
default=None, alias='hideRepliesByUnfollowed'
) #: Hide replies in the feed if they are not by followed users.
hide_reposts: t.Optional[bool] = Field(default=None, alias='hideReposts') #: Hide reposts in the feed.

py_type: te.Literal['app.bsky.actor.defs#feedViewPref'] = Field(
default='app.bsky.actor.defs#feedViewPref', alias='$type', frozen=True
)


class ThreadViewPref(base.ModelBase):

"""Definition model for :obj:`app.bsky.actor.defs`."""

prioritize_followed_users: t.Optional[bool] = Field(
default=None, alias='prioritizeFollowedUsers'
) #: Show followed users at the top of all replies.
sort: t.Optional[str] = None #: Sorting mode.

py_type: te.Literal['app.bsky.actor.defs#threadViewPref'] = Field(
default='app.bsky.actor.defs#threadViewPref', alias='$type', frozen=True
)
12 changes: 9 additions & 3 deletions atproto/xrpc_client/models/app/bsky/actor/search_actors.py
Original file line number Diff line number Diff line change
Expand Up @@ -20,14 +20,20 @@ class Params(base.ParamsModelBase):
"""Parameters model for :obj:`app.bsky.actor.searchActors`."""

cursor: t.Optional[str] = None #: Cursor.
limit: t.Optional[int] = Field(default=50, ge=1, le=100) #: Limit.
term: t.Optional[str] = None #: Term.
limit: t.Optional[int] = Field(default=25, ge=1, le=100) #: Limit.
q: t.Optional[
str
] = None #: search query string; syntax, phrase, boolean, and faceting is unspecified, but Lucene query syntax is recommended.
term: t.Optional[str] = None #: DEPRECATED: use 'q' instead.


class ParamsDict(te.TypedDict):
cursor: te.NotRequired[t.Optional[str]] #: Cursor.
limit: te.NotRequired[t.Optional[int]] #: Limit.
term: te.NotRequired[t.Optional[str]] #: Term.
q: te.NotRequired[
t.Optional[str]
] #: search query string; syntax, phrase, boolean, and faceting is unspecified, but Lucene query syntax is recommended.
term: te.NotRequired[t.Optional[str]] #: DEPRECATED: use 'q' instead.


class Response(base.ResponseModelBase):
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -19,13 +19,15 @@ class Params(base.ParamsModelBase):

"""Parameters model for :obj:`app.bsky.actor.searchActorsTypeahead`."""

limit: t.Optional[int] = Field(default=50, ge=1, le=100) #: Limit.
term: t.Optional[str] = None #: Term.
limit: t.Optional[int] = Field(default=10, ge=1, le=100) #: Limit.
q: t.Optional[str] = None #: search query prefix; not a full query string.
term: t.Optional[str] = None #: DEPRECATED: use 'q' instead.


class ParamsDict(te.TypedDict):
limit: te.NotRequired[t.Optional[int]] #: Limit.
term: te.NotRequired[t.Optional[str]] #: Term.
q: te.NotRequired[t.Optional[str]] #: search query prefix; not a full query string.
term: te.NotRequired[t.Optional[str]] #: DEPRECATED: use 'q' instead.


class Response(base.ResponseModelBase):
Expand Down
3 changes: 3 additions & 0 deletions atproto/xrpc_client/models/app/bsky/feed/post.py
Original file line number Diff line number Diff line change
Expand Up @@ -78,5 +78,8 @@ class Main(base.RecordModelBase):
] = None #: Labels.
langs: t.Optional[t.List[str]] = Field(default=None, max_length=3) #: Langs.
reply: t.Optional['models.AppBskyFeedPost.ReplyRef'] = None #: Reply.
tags: t.Optional[t.List[str]] = Field(
default=None, max_length=8
) #: Additional non-inline tags describing this post.

py_type: te.Literal['app.bsky.feed.post'] = Field(default='app.bsky.feed.post', alias='$type', frozen=True)
45 changes: 45 additions & 0 deletions atproto/xrpc_client/models/app/bsky/feed/search_posts.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,45 @@
##################################################################
# THIS IS THE AUTO-GENERATED CODE. DON'T EDIT IT BY HANDS!
# Copyright (C) 2023 Ilya (Marshal) <https://github.com/MarshalX>.
# This file is part of Python atproto SDK. Licenced under MIT.
##################################################################


import typing as t

import typing_extensions as te
from pydantic import Field

if t.TYPE_CHECKING:
from atproto.xrpc_client import models
from atproto.xrpc_client.models import base


class Params(base.ParamsModelBase):

"""Parameters model for :obj:`app.bsky.feed.searchPosts`."""

q: str #: search query string; syntax, phrase, boolean, and faceting is unspecified, but Lucene query syntax is recommended.
cursor: t.Optional[
str
] = None #: optional pagination mechanism; may not necessarily allow scrolling through entire result set.
limit: t.Optional[int] = Field(default=25, ge=1, le=100) #: Limit.


class ParamsDict(te.TypedDict):
q: str #: search query string; syntax, phrase, boolean, and faceting is unspecified, but Lucene query syntax is recommended.
cursor: te.NotRequired[
t.Optional[str]
] #: optional pagination mechanism; may not necessarily allow scrolling through entire result set.
limit: te.NotRequired[t.Optional[int]] #: Limit.


class Response(base.ResponseModelBase):

"""Output data model for :obj:`app.bsky.feed.searchPosts`."""

posts: t.List['models.AppBskyFeedDefs.PostView'] #: Posts.
cursor: t.Optional[str] = None #: Cursor.
hits_total: t.Optional[int] = Field(
default=None, alias='hitsTotal'
) #: count of search hits. optional, may be rounded/truncated, and may not be possible to paginate through all hits.
17 changes: 16 additions & 1 deletion atproto/xrpc_client/models/app/bsky/richtext/facet.py
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,11 @@ class Main(base.ModelBase):

features: t.List[
te.Annotated[
t.Union['models.AppBskyRichtextFacet.Mention', 'models.AppBskyRichtextFacet.Link'],
t.Union[
'models.AppBskyRichtextFacet.Mention',
'models.AppBskyRichtextFacet.Link',
'models.AppBskyRichtextFacet.Tag',
],
Field(discriminator='py_type'),
]
] #: Features.
Expand Down Expand Up @@ -54,6 +58,17 @@ class Link(base.ModelBase):
)


class Tag(base.ModelBase):

"""Definition model for :obj:`app.bsky.richtext.facet`. A hashtag."""

tag: str = Field(max_length=640) #: Tag.

py_type: te.Literal['app.bsky.richtext.facet#tag'] = Field(
default='app.bsky.richtext.facet#tag', alias='$type', frozen=True
)


class ByteSlice(base.ModelBase):

"""Definition model for :obj:`app.bsky.richtext.facet`. A text segment. Start is inclusive, end is exclusive. Indices are for utf8-encoded strings."""
Expand Down
37 changes: 37 additions & 0 deletions atproto/xrpc_client/models/app/bsky/unspecced/defs.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,37 @@
##################################################################
# THIS IS THE AUTO-GENERATED CODE. DON'T EDIT IT BY HANDS!
# Copyright (C) 2023 Ilya (Marshal) <https://github.com/MarshalX>.
# This file is part of Python atproto SDK. Licenced under MIT.
##################################################################


import typing as t

import typing_extensions as te
from pydantic import Field

if t.TYPE_CHECKING:
pass
from atproto.xrpc_client.models import base


class SkeletonSearchPost(base.ModelBase):

"""Definition model for :obj:`app.bsky.unspecced.defs`."""

uri: str #: Uri.

py_type: te.Literal['app.bsky.unspecced.defs#skeletonSearchPost'] = Field(
default='app.bsky.unspecced.defs#skeletonSearchPost', alias='$type', frozen=True
)


class SkeletonSearchActor(base.ModelBase):

"""Definition model for :obj:`app.bsky.unspecced.defs`."""

did: str #: Did.

py_type: te.Literal['app.bsky.unspecced.defs#skeletonSearchActor'] = Field(
default='app.bsky.unspecced.defs#skeletonSearchActor', alias='$type', frozen=True
)
Original file line number Diff line number Diff line change
@@ -0,0 +1,47 @@
##################################################################
# THIS IS THE AUTO-GENERATED CODE. DON'T EDIT IT BY HANDS!
# Copyright (C) 2023 Ilya (Marshal) <https://github.com/MarshalX>.
# This file is part of Python atproto SDK. Licenced under MIT.
##################################################################


import typing as t

import typing_extensions as te
from pydantic import Field

if t.TYPE_CHECKING:
from atproto.xrpc_client import models
from atproto.xrpc_client.models import base


class Params(base.ParamsModelBase):

"""Parameters model for :obj:`app.bsky.unspecced.searchActorsSkeleton`."""

q: str #: search query string; syntax, phrase, boolean, and faceting is unspecified, but Lucene query syntax is recommended. For typeahead search, only simple term match is supported, not full syntax.
cursor: t.Optional[
str
] = None #: optional pagination mechanism; may not necessarily allow scrolling through entire result set.
limit: t.Optional[int] = Field(default=25, ge=1, le=100) #: Limit.
typeahead: t.Optional[bool] = None #: if true, acts as fast/simple 'typeahead' query.


class ParamsDict(te.TypedDict):
q: str #: search query string; syntax, phrase, boolean, and faceting is unspecified, but Lucene query syntax is recommended. For typeahead search, only simple term match is supported, not full syntax.
cursor: te.NotRequired[
t.Optional[str]
] #: optional pagination mechanism; may not necessarily allow scrolling through entire result set.
limit: te.NotRequired[t.Optional[int]] #: Limit.
typeahead: te.NotRequired[t.Optional[bool]] #: if true, acts as fast/simple 'typeahead' query.


class Response(base.ResponseModelBase):

"""Output data model for :obj:`app.bsky.unspecced.searchActorsSkeleton`."""

actors: t.List['models.AppBskyUnspeccedDefs.SkeletonSearchActor'] #: Actors.
cursor: t.Optional[str] = None #: Cursor.
hits_total: t.Optional[int] = Field(
default=None, alias='hitsTotal'
) #: count of search hits. optional, may be rounded/truncated, and may not be possible to paginate through all hits.
Original file line number Diff line number Diff line change
@@ -0,0 +1,45 @@
##################################################################
# THIS IS THE AUTO-GENERATED CODE. DON'T EDIT IT BY HANDS!
# Copyright (C) 2023 Ilya (Marshal) <https://github.com/MarshalX>.
# This file is part of Python atproto SDK. Licenced under MIT.
##################################################################


import typing as t

import typing_extensions as te
from pydantic import Field

if t.TYPE_CHECKING:
from atproto.xrpc_client import models
from atproto.xrpc_client.models import base


class Params(base.ParamsModelBase):

"""Parameters model for :obj:`app.bsky.unspecced.searchPostsSkeleton`."""

q: str #: search query string; syntax, phrase, boolean, and faceting is unspecified, but Lucene query syntax is recommended.
cursor: t.Optional[
str
] = None #: optional pagination mechanism; may not necessarily allow scrolling through entire result set.
limit: t.Optional[int] = Field(default=25, ge=1, le=100) #: Limit.


class ParamsDict(te.TypedDict):
q: str #: search query string; syntax, phrase, boolean, and faceting is unspecified, but Lucene query syntax is recommended.
cursor: te.NotRequired[
t.Optional[str]
] #: optional pagination mechanism; may not necessarily allow scrolling through entire result set.
limit: te.NotRequired[t.Optional[int]] #: Limit.


class Response(base.ResponseModelBase):

"""Output data model for :obj:`app.bsky.unspecced.searchPostsSkeleton`."""

posts: t.List['models.AppBskyUnspeccedDefs.SkeletonSearchPost'] #: Posts.
cursor: t.Optional[str] = None #: Cursor.
hits_total: t.Optional[int] = Field(
default=None, alias='hitsTotal'
) #: count of search hits. optional, may be rounded/truncated, and may not be possible to paginate through all hits.
Loading

0 comments on commit 31eea9a

Please sign in to comment.