Release 0.1
roblox.py Documentation
Release 0.1.8a2 Patrick Dill
Feb 04, 2018
Contents:
1 API Reference
1
1.1 Client Session . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1
1.2 Roblox Objects . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 5
1.2.1 User . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 6
1.2.2 Asset . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 8
1.2.3 Group . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 9
1.3 Data Classes . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 11
1.3.1 Enums . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 14
1.4 Site Chat . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 14
1.5 Utils . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 17
2 Changelog
19
2.1 0.1.8 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 19
2.2 0.1.7 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 19
2.3 0.1.4 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 19
2.4 0.1.3 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 19
2.5 0.1.2 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 20
2.6 0.1.1 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 20
2.7 0.0.8 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 20
2.8 0.0.6a5 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 20
2.9 0.0.4 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 20
2.10 0.0.3 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 21
3 Getting Started
23
i
ii
1 CHAPTER
API Reference
1.1 Client Session
class roblox.RobloxSession(username=None,
password=None,
proxies=None,
check_login=False) The RobloxSession, often referred to in these docs as the Client, is the interface between the program and
Roblox. Everything should be accessed from the RobloxSession, including users, assets, and groups, instead of
directly creating those objects.
Parameters
? username (str) ? Keyword username to login with. This is not required. If no username & password are given, you can use login() after the session is created.
? password (str) ? Keyword password to login with. Same applies as above.
? proxies (dict) ? Keyword argument telling the session what proxy to use. The proxies should contain the schema.
? check_login (bool) ? Keyword argument. If True, the session will be verified every time a function is used that requires login, with logged_in() . Defaults to False
Proxy example:
proxies = { 'http': '', 'https': '',
}
roblox.py also natively supports the SOCKS protocol. proxies = { `http': `socks5://host:port', `https': `socks5://host:port' }
Or, with auth:
1
roblox.py Documentation, Release 0.1.8a2
proxies = { 'http': 'socks5://user:pass@host:port', 'https': 'socks5://user:pass@host:port'
}
In case you use proxies that may go down, you can change the proxy at any time by changing RobloxSession.http.proxies
This class can also be used as a context manager, if you provide username and password on init.
with roblox.RobloxSession(username="iLoveBricks", password="rawrXD123") as rbx: # create session as rbx
rbx.post_status("i love bricks!") # post status
# session is automatically invalidated once the block is complete
username Optional[str] ? Username of logged in user
password Optional[str] ? Password of logged in user
user_id Optional[int] ? ID of logged in user
me Optional[User] ? User object for logged in user
chat RobloxChatManager ? Chat object, allows communication on roblox site
logged_in If keyword check_login is True, this will check if the client is still logged in. Otherwise, it will just return whether the client has used login()
login(username: str, password: str) Logs the session into Roblox with given info. Parameters ? username (str) ? Username to login with ? password (str) ? Password to login with Raises LoginException ? if login failed. Could be for several reasons Returns True if login successful
logout() Logs out of the signed in account. Resets username, user_id, and user attributes.
create_account(username, password, birthday, gender) Creates a new Roblox account with the username and password given. Parameters ? username (str) ? Username ? password (str) ? Password ? birthday (datetime.date or datetime.datetime) ? Birthday to sign up with
2
Chapter 1. API Reference
roblox.py Documentation, Release 0.1.8a2
? gender (roblox.Gender) ? Gender Returns True if successful
verify_session() Checks if client session is still logged in. Returns True if session is logged in.
get_self() Returns updated class:User for the logged in user. Returns User
is_username_taken(username) Checks if username is taken. Returns boolean
get_user(username=None, user_id=None) Gets user by username or user id. Keyword Arguments ? username (str) ? Username ? user_id (str) ? User ID Returns User
get_asset(asset_id) Gets asset object by its asset id Parameters asset_id (int) ? Asset ID to get asset from. Returns Asset
get_group(group_id) Gets group by its group id (the one in the URL) Parameters group_id (int) ? Group ID to get group from. Returns Group
robux() Gets amount of ROBUX the client user has. Returns int
unread_message_count() Gets client user's unread message count. Returns int
friend_request_count() Gets client user's incoming friend request count. Returns int
block(user) Blocks other user, preventing any direct communication. Parameters user (User) ? User to block Returns True if successful.
unblock(user) Unlocks other user
1.1. Client Session
3
roblox.py Documentation, Release 0.1.8a2
Parameters user (User) ? User to unblock Returns True if successful. post_status(status) Updates user status Parameters status (str) ? New status to set Returns True if successful set_blurb(blurb) Sets profile's blurb/decsription Parameters blurb (str) ? Blurb to set Returns True if successful set_description(description) Alias for RobloxSession.set_blurb()
friend_requests() Generator yielding FriendRequest Returns FriendRequest
send_friend_request(user) Sends friend request to other user. Parameters user (User) ? User to send to friend request to. Returns Friend request that was sent. Return type FriendRequest
accept_friend_request(user) Accepts friend request from user Parameters user (User) ? User to accept friend request from. Returns True if successful
decline_friend_request(user) Declines friend request from user Parameters user (User) ? User to decline friend request from. Returns True if successful
unfriend(user) Unfriends user Parameters user (User) ? User to unfriend Returns True if successful
follow_user(user) Follows other user Parameters user (User) ? User to follow Returns True if successful
unfollow_user(user) Unfollows user Parameters user (User) ? User to unfollow
4
Chapter 1. API Reference
................
................
In order to avoid copyright disputes, this page is only a partial summary.
To fulfill the demand for quickly locating and searching documents.
It is intelligent file search solution for home and business.
Related searches
- 1 or 2 374 374 1 0 0 0 1 168 1 1 default username and password
- 1 or 3 374 374 1 0 0 0 1 168 1 1 default username and password
- 1 or 2 711 711 1 0 0 0 1 168 1 1 default username and password
- 1 or 3 711 711 1 0 0 0 1 168 1 1 default username and password
- 1 or 2 693 693 1 0 0 0 1 168 1 1 default username and password
- 1 or 3 693 693 1 0 0 0 1 168 1 1 default username and password
- 1 or 2 593 593 1 0 0 0 1 or 2dvchrbu 168 1 1 default username and password
- 1 or 3 593 593 1 0 0 0 1 or 2dvchrbu 168 1 1 default username and password
- 1 or 2 910 910 1 0 0 0 1 168 1 1 default username and password
- 1 or 3 910 910 1 0 0 0 1 168 1 1 default username and password
- 192 1 or 2 33 33 1 0 0 0 1 1 1 default username and password
- 1 or 2 364 364 1 0 0 0 1 168 1 1 admin username and password