presence
This module contains classes intended to parse and deal with data from Roblox presence endpoints.
Presence
¶
Represents a user's presence.
Attributes:
Name | Type | Description |
---|---|---|
user_presence_type |
PresenceType
|
The type of the presence. |
last_location |
str
|
A string representing the user's last location. |
place |
Optional[BasePlace]
|
The place the user is playing or editing. |
root_place |
Optional[BasePlace]
|
The root place of the parent universe of the last place the user is playing or editing. |
job |
Optional[BaseJob]
|
The job of the root place that the user is playing or editing. |
universe |
Optional[BaseUniverse]
|
The universe the user is playing or editing. |
last_online |
datetime
|
When the user was last online. |
user |
BaseUser
|
The user this presence belongs to. |
Source code in roblox/presence.py
36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 |
|
__init__(client, data)
¶
Parameters:
Name | Type | Description | Default |
---|---|---|---|
client |
Client
|
Client object. |
required |
data |
dict
|
The data from the request. |
required |
Source code in roblox/presence.py
51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 |
|
PresenceProvider
¶
The PresenceProvider is an object that represents https://presence.roblox.com/ and provides multiple functions for fetching user presence information.
Source code in roblox/presence.py
86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 |
|
get_user_presences(users)
async
¶
Grabs a list of Presence objects corresponding to each user in the list.
Parameters:
Name | Type | Description | Default |
---|---|---|---|
users |
List[UserOrUserId]
|
The list of users you want to get Presences from. |
required |
Returns:
Type | Description |
---|---|
List[Presence]
|
A list of Presences. |
Source code in roblox/presence.py
95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 |
|
PresenceType
¶
Bases: IntEnum
Represents a user's presence type.
Source code in roblox/presence.py
26 27 28 29 30 31 32 33 |
|