Dataclasses#
- class recnetpy.dataclasses.Account(client: Client, id: int, data: Optional[RT] = None)#
This dataclass represents a RecNet account.
- banner_image: Optional[str] = None#
This is the file of an account’s banner image.
- bio: Optional[str] = None#
This is a users bio.
- created_at: int#
This is the date the account was created as a Unix integer.
- created_rooms: Optional[List[Room]] = None#
This is a list of room objects that represent rooms created by the player.
- display_name: str#
This is what appears in bold above the username on an account’s page on RecNet. The display name is not unique unlike the username.
- events: Optional[List[Event]] = None#
This is a list of event objects that represent events created by the player.
- feed: Optional[List[Image]] = None#
This is a list of image objects that represent images the player can be seen in.
- async get_bio(force: bool = False) str#
Fetches this player’s bio. Returns a cached result, if this function has been already called.
- Parameters
force – If true, fetches new data.
- Returns
The player’s bio.
- async get_created_rooms(force: bool = False) List[Room]#
Fetches a list of rooms created by this player. Returns a cached result, if this function has been already called.
- Parameters
force – If true, fetches new data.
- Returns
A list of rooms.
- async get_events(take: int = 16, skip: int = 0, force: bool = False) List[Event]#
Fetches a list of events made by this player. Returns a cached result, if this function has been already called.
- Parameters
take – The number of results to return.
skip – The number of results to skip.
force – If true, fetches new data.
- Returns
A list of events.
- async get_feed(take: int = 16, skip: int = 0, force: bool = False) List[Image]#
Fetches a list of images taken of this player. Returns a cached result, if this function has been already called.
- Parameters
take – The number of results to return.
skip – The number of results to skip.
force – If true, fetches new data.
- Returns
A list of images.
- async get_images(take: int = 16, skip: int = 0, sort: int = 0, force: bool = False) List[Image]#
Fetches a list of images taken by this player. Returns a cached result, if this function has been already called.
- Parameters
take – The number of results to return.
skip – The number of results to skip.
sort – An integer that describes how the results are to be sorted.
force – If true, fetches new data.
- Returns
A list of images.
- async get_is_influencer(force: bool = False) bool#
Fetches whether this player is an influencer. Returns a cached result, if this function has been already called.
- Parameters
force – If true, fetches new data.
- Returns
This player’s subscriber count.
- async get_level(force: bool = False) Progression#
Fetches this player’s level as a progression object. Returns a cached result, if this function has been already called.
- Parameters
force – If true, fetches new data.
- Returns
This player’s level.
- async get_owned_rooms(force: bool = False) List[Room]#
Fetches a list of rooms owned by this player. Returns a cached result, if this function has been already called.
- Parameters
force – If true, fetches new data.
- Returns
A list of rooms.
- async get_showcased_rooms(force: bool = False) List[Room]#
Fetches a list of rooms featured by this player. Returns a cached result, if this function has been already called.
- Parameters
force – If true, fetches new data.
- Returns
A list of rooms.
- async get_subscriber_count(force: bool = False) int#
Fetches this players subscriber count. Returns a cached result, if this function has been already called.
- Parameters
force – If true, fetches new data.
- Returns
This player’s subscriber count.
- id: int#
This is an account’s unique identifier
- identity_flags: List[str]#
This is a list of a user’s gender identities. It has these possible values
['LGBTQIA', 'Transgender', 'Bisexual', 'Lesbian', 'Pansexual', 'Asexual', 'Intersex', 'Genderqueer', 'Nonbinary', 'Aromantic'].
- images: Optional[List[Image]] = None#
This is a list of image objects that represent images created by the player.
- is_influencer: Optional[bool] = None#
This is true if the user is an influencer, false if the account is not.
- is_junior: bool#
This is true if the account is a junior account, false if the account is a non-junior account.
- level: Optional[Progression] = None#
This is a progression object that represents a users current level and xp.
- owned_rooms: Optional[List[Room]] = None#
THis is a list of room objects that represent rooms the player has ownership of.
- patch_data(data: AccountResponse) None#
Sets properties corresponding to data for an api account response.
- Parameters
data – Data from the api.
- personal_pronouns: List[str]#
This is the list of pronouns a user goes by. It has these possible values
['She / her', 'He / him', 'They / them', 'Ze / hir', 'Ze / zir', 'Xe / xem'].
- platforms: List[str]#
This is a list of platforms a user plays on. It has these possible values
['Steam', 'Meta', 'PlayStation', 'Xbox', 'RecNet', 'iOS', 'Android', 'Standalone'].
- profile_image: str#
This is the file name of an account’s profile picture.
- subscriber_count: Optional[int] = None#
This is the total number of subscribers a user has.
- username: str#
This is the unique name of the player.
- class recnetpy.dataclasses.BaseDataClass(client: Client, id: int, data: Optional[RT] = None)#
The base class used for all dataclasses. This class is inteded to be inherited, and shouldn’t be created directly.
- classmethod create_from_id_list(client: Client, ids: List[int])#
Creates a list of dataclasses from a list of ids.
- data: Optional[RT] = None#
Data returned by an API request.
- rec_net: RouteManager#
This is an interface for the HTTP manager.
- class recnetpy.dataclasses.Comment(data: CommentResponse)#
This class represents a comment left under an image.
- comment: str#
This is the comment made on the image.
- player: Optional[Account]#
This is a player object the represents the player who create the comment.
- player_id: int#
This is the id of the player who created the comment.
- saved_image_comment_id: int#
This is a comments unique identifier.
- saved_image_id: int#
This is the id of the image the comment was left under.
- class recnetpy.dataclasses.EventInteraction(data: EventResponseResponse)#
This class represents a user’s interaction with an event.
- created_at: int#
This is the date the interation happened as an Unix integer.
- player_event_id: int#
This is the id of the event the player is responding to.
- player_id: int#
This is the id of the interacting player.
- type: str#
This is the type of interation which as the possible values of
[None, 'Attending', 'May Attend', 'Not Attending', 'Pending']
- class recnetpy.dataclasses.Event(client: Client, id: int, data: Optional[RT] = None)#
This class represents a RecNet event.
- accessibility: str#
This is the visibility of the event which has the possible values of
['Private', 'Public', 'Unlisted'].
- attendee_count: int#
This is the number of people attending the event.
- can_request_broadcast_permissions: str#
This defines who can request to broadcast which has the possible values of
[None, 'Room Owners', 'All']
- club: Optional[int]#
This is the id of the club that the event is being hosted by.
- creator_player: Optional[Account] = None#
This is an account object which represents who created the event.
- creator_player_id: int#
This is the id of the player who created the event.
- default_broadcast_permissions: str#
This defines who has broadcasting permissions which has the possible values of
[None, 'Room Owners', 'All']
- description: str#
This is the description of the event.
- end_time: int#
This is the date the event will end represented as an Unix integer.
- async get_creator_player(force: bool = False) Account#
Fetches the creator of this event. Returns a cached result, if this function has been already called.
- Parameters
force – If true, fetches new data.
- Returns
An account object.
- async get_images(take: int = 16, skip: int = 0, force: bool = False) List[Image]#
Fetches a list of images during this event. Returns a cached result, if this function has been already called.
- Parameters
take – The number of results to return.
skip – The number of results to skip.
force – If true, fetches new data.
- Returns
A list of images.
- async get_responses(force: bool = False) List[EventInteraction]#
Fetches the event responses for this event. Returns a cached result, if this function has been already called.
- Parameters
force – If true, fetches new data
- Returns
A list of event interaction objects.
- async get_room(include: int = 0, force: bool = False) Optional[Room]#
Fetches the room this event is happening in. Returns a cached result, if this function has been already called. If the room is private, nothing will be returned.
Include param values:Value
Resolve
2
Subrooms
4
Roles
8
Tags
32
Promotional content
64
Scores
256
Loading screens
- Parameters
include – An integer that add additional information to the response.
force – If true, fetches new data.
- Returns
A room object.
- id: int#
This is an event’s unique identifier.
- image_name: Optional[str]#
This is the file name of the event thumbnail.
- images: Optional[List[Image]] = None#
This is a list of image objects that represent images taken during the event.
- is_multi_instance: bool#
This is true if the event supports broadcasting, false if it doesn’t.
- name: str#
This is the name of the event.
- patch_data(data: EventResponse) None#
Sets properties corresponding to data for an api event response.
- Parameters
data – Data from the api.
- async resolve_responders(force: bool = False) List[EventInteraction]#
Resolves the players who responded to the event. This function will make an api call every time its used. It should only be used when updating the response player attribute.
- Parameters
force – Forces new responses to be fetched.
- Returns
A list of event interation objects.
- responses: Optional[List[EventInteraction]] = None#
This is a list of event interaction objects which represents the event responses.
- room: Optional[Room] = None#
This is a room object which represents the room where the event is taking place.
- room_id: int#
This is the id of the room where the event is taking place.
- start_time: int#
This is the date the event will start represented as an Unix integer.
- subroom_id: Optional[int]#
This is the id of the subroom where the event ts taking place.
- support_multi_instance_room_chat: bool#
This is true if the event has cross-instance chat enabled, false if it doesn’t.
- class recnetpy.dataclasses.Image(client: Client, id: int, data: Optional[RT] = None)#
This class represents a RecNet image.
- accessibility: str#
This is the visibilty of the image which has the possible value of
['Private', 'Public', 'Unlisted'].
- accessibility_locked: bool#
This is true if the accessiblity of the image is fixed, false if its able to able to be changed.
- cheer_count: int#
This is the number of cheers the image has recieved.
- cheer_player_ids: Optional[List[int]] = None#
This is a list of player ids who cheered the image.
- cheer_players: Optional[List[Account]] = None#
This is a list of account objects that represents players who cheered the image.
- comment_count: int#
This is the number of comments the post has recieved.
- comments: Optional[List[Comment]] = None#
This is a list of comment objects that represent comments left on the image.
- created_at: int#
This is the date the image was taken on represented as an Unix integer.
- description: Optional[str]#
This is the description of the image.
- async get_cheers(force: bool = False) List[int]#
Fetches a list of players’ ids who cheered the post. Returns a cached result, if this function has been already called.
- Parameters
force – If true, fetches new data.
- Returns
A list of account ids.
- async get_comments(force: bool = False) List[Comment]#
Fetches a list of comments made on the image. Returns a cached result, if this function has been already called.
- Parameters
force – If true, fetches new data.
- Returns
An list of comment objects.
- async get_player(force: bool = False) Account#
Fetches the creator of the image. Returns a cached result, if this function has been already called.
- Parameters
force – If true, fetches new data.
- Returns
An account object.
- async get_player_event(force: bool = False) Optional[Event]#
Fetches the event the image was taken in. Returns a cached result, if this function has been already called.
- Parameters
force – If true, fetches new data.
- Returns
An event object, or None if the image wasn’t taken in an event.
- async get_room(include: int = 0, force: bool = False) Room#
Fetches the room the image was taked in. Returns a cached result, if this function has been already called.
Include param values:Value
Resolve
2
Subrooms
4
Roles
8
Tags
32
Promotional content
64
Scores
256
Loading screens
- Parameters
force – If true, fetches new data.
- Returns
A room object.
- async get_tagged_players(force: bool = False) List[Account]#
Fetches account data for the player who appeared in the Image. Returns a cached result, if this function has been already called.
- Parameters
force – If true, fetches new data.
- Returns
A list of account objects.
- id: int#
This is an image’s unique identifier.
- image_name: str#
This is the file name of the image itself.
- patch_data(data: ImageResponse) None#
Sets properties corresponding to data for an api event response.
- Parameters
data – Data from the api.
- player: Optional[Account] = None#
This is an account object representing the player who took the image.
- player_event: Optional[Event] = None#
This is an event object which represents the event the image was taken during.
- player_event_id: Optional[int]#
This is the event the image was taken during.
- player_id: int#
This is the id of the player who took the image.
- async resolve_cheers(force: bool = False) List[Account]#
Fetches a list of player objects who cheered the post. Returns a cached result, if this function has been already called.
- Parameters
force – If true, fetches new data.
- Returns
A list of account objects.
- async resolve_commenters(force: bool = False) List[Comment]#
Resolves the players who commented on an image. This function will make an api call every time its used. It should only be used when updating the comment player attribute.
- Parameters
force – Forces new responses to be fetched.
- Returns
A list of comment objects.
- room: Optional[Room] = None#
This is a room object which represents the room the image was taken in.
- room_id: Optional[int]#
This is the id of the room the image was taken it.
- tagged_player_ids: List[int]#
This is a list of player id’s who were tagged in the image.
- tagged_players: Optional[List[Account]] = None#
This is a list of account objects that represent the player who can be seen in the image.
- type: str#
This is the type of image which has the possible value of
[None, 'Share Camera', 'Outfit Thumbnail', 'Room Thumbnail', 'Profile Thumbnail', 'Invention Thumbnail', 'Player Event Thumbnail', 'Room Load Screen'].
- class recnetpy.dataclasses.InventionVersion(data: CurrentVersion)#
This object is an invention partial that represents a version of an invention.
- chips_cost: int#
This is the CV2 cost for the invention.
- cloud_variables_cost: int#
This is the amount of clould variable resources required.
- instantiation_cost: float#
This is the precentage of ink an invention requires.
- invention_id: int#
This is the invention’s unique identifier.
- lights_cost: int#
This is the light cost for the invention.
- version_number: int#
This is an integer that represents a version of the invention.
- class recnetpy.dataclasses.Invention(client: Client, id: int, data: Optional[RT] = None)#
This class represents an invention.
- accessibility: str#
This is the visibilty of the invention which has the possible value of
['Private', 'Public', 'Unlisted'].
- allow_trial: bool#
If true this invention allows a trial use.
- cheer_count: int#
This is the number of cheers the invention has recieved.
- created_at: int#
This is the date the invention was created represented as an Unix integer.
- creation_room: Optional[Room] = None#
This is a room object that represents the room the invention was created in.
- creation_room_id: int#
This is the id of the room the invention was created in.
- creator_permission: str#
This the permission level of the creator which has the possible values of
['Unassigned', 'Limited One Use Only', 'Disallow Key Lock', 'Use Only', 'Edit and Save', 'Publish', 'Charge', 'Unlimited'].
- creator_player: Optional[Account] = None#
This is an account object that represents the player who created the invention.
- creator_player_id: int#
This is the id of the player who created the invention.
- current_version: InventionVersion#
This is an invention version object that represents the current version of the invention.
- current_version_number: int#
This is an integer that represents the current version of the invention.
- description: str#
This is the description of the invention.
- first_published_at: int#
This is the date the invention was first published to the store represented as an Unix integer.
- general_permission: str#
This the general permission level of the invention which has the possible values of
['Unassigned', 'Limited One Use Only', 'Disallow Key Lock', 'Use Only', 'Edit and Save', 'Publish', 'Charge', 'Unlimited'].
- async get_creation_room(include: int = 0, force: bool = False) Room#
Fetches the room this invention was created in. Returns a cached result, if this function has been already called.
Include param values:Value
Resolve
2
Subrooms
4
Roles
8
Tags
32
Promotional content
64
Scores
256
Loading screens
- Parameters
include – An integer that add additional information to the response.
force – If true, fetches new data.
- Returns
A room object.
- async get_creator_player(force: bool = False) Account#
Fetches the creator of this invention. Returns a cached result, if this function has been already called.
- Parameters
force – If true, fetches new data.
- Returns
An account object.
- async get_tags(force: bool = False) List[Tag]#
Fetches the tags for this invention. Returns a cached result, if this function has been already called.
- Parameters
force – If true, fetches new data
- Returns
A list of tag objects.
- hide_from_player: bool#
If true this invention is hidden from the player.
- image_name: str#
This is the file name of the invention thumbnail.
- is_ag_invention: bool#
If true this is an invention that is from RecRoomInc.
- is_certified_invention: bool#
If true this invention has been certified.
- is_featured: bool#
If true the invention has been featured.
- is_published: bool#
If true the invention has been published to the store.
- modified_at: int#
This is the date the invention was last modified represented as an Unix integer.
- name: str#
This is the name of the invention.
- num_downloads: int#
This is the number of players who have downloaded the invention.
- num_players_have_used_in_room: int#
This is the number of players who have used the invention in one of their rooms.
- patch_data(data: InventionResponse) None#
Sets properties corresponding to data for an api invention response.
- Parameters
data – Data from the api.
- price: int#
This is the number of tokens required to purchace the invention.
- class recnetpy.dataclasses.LoadScreen(data: LoadScreenResponse)#
This class represents the data for a room loading screen.
- image_name: str#
This is the file name of the load screen image.
- subtitle: Optional[str]#
This is the subtitle of the load scree.
- title: Optional[str]#
This is the title text that appears on the load screen.
- class recnetpy.dataclasses.Progression(data: ProgressionResponse)#
This class represents a players current level.
- level: int#
This is the current level of the player:
- player_id: int#
This is the id for the player who’s level this object represents.
- xp: int#
This is how much xp the player has gained since they last leveled up.
- class recnetpy.dataclasses.PromoExternalContent(data: PromoExternalContentResponse)#
This class represent a room’s promotional youtube videos.
- reference: str#
This is a part of a url that refers to the location of the content. Usally the last part of a YouTube video.
- type: str#
This is the type of content which is only YouTube right now.
- class recnetpy.dataclasses.Role(data: RoleResponse)#
This class represents a room’s player roles.
- account_id: int#
This is the id of the player who owns this role.
- id: int#
This is the id of the role which has the possible values of
{0: 'None', 10: 'Member', 20: 'Moderator', 30: 'Co-Owner', 255: 'Owner'}.
- invited_role: str#
This is the role the player was invited to take.
- last_changed_by_account: Optional[Account]#
This is an account object which represents player that updated this role.
- last_changed_by_account_id: Optional[int]#
This is the id of the account who updated the player’s role.
- name: str#
This is the name of the role the player owns which has the possible values of
['None', 'Member', 'Moderator', 'Co-Owner', 'Owner']
- class recnetpy.dataclasses.Room(client: Client, id: int, data: Optional[RT] = None)#
This class represents a player created room.
- accessibility: str#
This is the visibilty of the room which has the possible value of
['Private', 'Public', 'Unlisted'].
- cheer_count: int#
This is the number of players that cheered the room.
- cloning_allowed: bool#
If true players can clone this room.
- created_at: int#
This is the date the room was created represented as an Unix integer.
- creator_account: Optional[Account] = None#
This is an account object which represents the player who created the room.
- creator_account_id: int#
This is the id of the player who created the room.
- custom_warning: Optional[str]#
This is a custom warning for the room.
- description: str#
This is the room’s description.
- disable_mic_auto_mute: bool#
If true mic auto mute is disabled.
- disable_room_comments: bool#
If true room comments are disabled.
- encrypted_voice_chat: bool#
If true voice chat is encrypted
- favorite_count: int#
This is the number of players who have the room favorited.
- async get_creator_player(force: bool = False) Account#
Fetches the creator of the room. Returns a cached result, if this function has been already called.
- Parameters
force – If true, fetches new data.
- Returns
An account object.
- async get_events(take: int = 16, skip: int = 0, force: bool = False) List[Event]#
Fetches a list of events happening in this room. Returns a cached result, if this function has been already called.
- Parameters
take – The number of results to return.
skip – The number of results to skip.
force – If true, fetches new data.
- Returns
A list of events.
- async get_images(take: int = 16, skip: int = 0, sort: int = 0, force: bool = False) List[Image]#
Fetches a list of images taken in this room. Returns a cached result, if this function has been already called.
- Parameters
take – The number of results to return.
skip – The number of results to skip.
sort – An integer that describes how the results are to be sorted
force – If true, fetches new data.
- Returns
A list of images.
- id: int#
This is a room’s unique identifier.
- image_name: Optional[str]#
This is the file name of the rooms thumbnail.
- is_dorm: int#
If true this room is a player’s dorm.
- is_rro: bool#
If true the room was published by coach.
- load_screen_locked: bool#
If true the load screen is locked.
- load_screens: Optional[List[LoadScreen]] = None#
This is a list of load screen objects that represents a room’s loading screens.
- max_player_calculation_mode: str#
Determines how the max number of players is calculated which has the possible values
['All Subrooms', 'Only Entry Subrooms'].
- max_players: int#
This is the max number of players allowed to join the room.
- min_level: int#
This is the minimum level requried to join the room.
- name: str#
This is the name of the room.
- patch_data(data: RoomResponse) None#
Sets properties corresponding to data for an api room response.
- Parameters
data – Data from the api.
- promo_external_content: Optional[List[PromoExternalContent]] = None#
This is a list of promotional content objects that represent’s a rooms promo content.
- promo_images: Optional[List[str]] = None#
This is a list of file names for a room’s promotional images.
- async resolve_role_owners() Optional[List[Role]]#
Resolves the role owner for this room. This function will make an api call every time its used. It should only be used when updating the role account attribute.
- Returns
A list of role objects, or None if roles is None
- roles: Optional[List[Role]] = None#
This a list of role objects which represents the room’s player roles.
- scores: Optional[List[Score]] = None#
This is a list of score objects that represents a room’s ranking.
- state: str#
This is the current state of the room which has the possible values of
['Active', 'Junior Pending', 'Moderation Pending', 'Moderation Closed', 'Moderation Banned', 'Marked For Delete'].
- subrooms: Optional[List[SubRoom]] = None#
This a list of subroom objects which represents the room’s subrooms.
- supports_juniors: bool#
If true junior players can join the room.
- supports_level_voting: bool#
If true players can vote on the next level.
- supports_mobile: bool#
If true mobile players can join the room.
- supports_quest_two: bool#
If true Quest 2 players can join the room.
- supports_screens: bool#
If true screen mode players can join the room.
- supports_teleport_vr: bool#
If true teleport vr players can join the room.
- supports_vr_low: bool#
If true vr low players can join the room.
- supports_walk_vr: bool#
If true walk vr players can join the room.
- visit_count: int#
This in the number of times players have joined the room.
- visitor_count: int#
This is the number of unique visits the room has.
- voice_moderated: bool#
If true the room uses voice moderation.
- warnings: List[str]#
This is a list of warnings for the room that can have any of these possible valuess
["Custom", "Spooky/scary themes", "Mature themes", "Bright/flashing lights", "Intense motion", "Gore/violence"]
- class recnetpy.dataclasses.Score(data: ScoreResponse)#
This class represents a room’s score on a particular platform. Not much is understood about what the score means.
- backup_score: Optional[int]#
This is a backup score.
- room_id: int#
This is the id of the room the tag belongs to.
- score: int#
This is the scores value.
- visit_type: int#
This is possibly the type of the platform for the score.
- class recnetpy.dataclasses.SubRoom(data: SubRoomResponse)#
This class represents a room’s subroom.
- accessibility: str#
This is the visibilty of the image which has the possible value of
['Private', 'Public', 'Unlisted'].
- is_sandbox: bool#
If true the room is a sandbox..
- max_players: int#
This is the max number of players allowed to join the rooom.
- room_id: int#
This is the id of the room this subroom belongs to.
- subroom_id: int#
This is a subrooms unique identifier.
- supports_join_in_progress: bool#
If true players are able to join an in-progress game.
- use_age_based_matchmaking: bool#
If true juniors will be matched with juniors, and vice versa.
- use_level_based_matchmaking: bool#
If true players are matched with others of similat level.
- use_rec_royale_matchmaking: bool#
If true the match making algorithm used in RecRoyal will be used.