Skip to content

Experience

This reference documents APIs relating to experiences (also known as games and universes) and places within experiences.

rblxopencloud.Experience(id, api_key)

Represents an experience/universe on Roblox.

Parameters:

Name Type Description Default
id int

The experience/universe ID

required
api_key str

The API key created on the Creator Dashboard with access to the experience.

required

Attributes:

Name Type Description
id int

The experience/universe ID

owner Optional[Union[User, Group]]

The experience's owner.

name Optional[str]

The experience's name.

description Optional[str]

The experience's description.

created_at Optional[datetime]

When the experience was created.

updated_at Optional[datetime]

When the experience was last updated.

root_place Optional[Place]

The experience's root/primary place.

public Optional[bool]

Whether the game is public.

voice_chat_enabled Optional[bool]

Whether voice chat is enabled.

age_rating Optional[ExperienceAgeRating]

The experience's age rating.

private_server_price Optional[int]

The price in robux of private servers, will be None if private servers are disabled.

desktop_enabled Optional[bool]

Whether the game can be played on desktop.

mobile_enabled Optional[bool]

Whether the game can be played on phones.

tablet_enabled Optional[bool]

Whether the game can be played on tablets.

console_enabled Optional[bool]

Whether the game can be played on consoles.

vr_enabled Optional[bool]

Wether the game can be played on VR headsets.

facebook_social_link Optional[ExperienceSocialLink]

The Facebook social link, if there is one.

twitter_social_link Optional[ExperienceSocialLink]

The Twitter social link, if there is one.

youtube_social_link Optional[ExperienceSocialLink]

The YouTube social link, if there is one.

twitch_social_link Optional[ExperienceSocialLink]

The Twitch social link, if there is one.

discord_social_link Optional[ExperienceSocialLink]

The Discord social link, if there is one.

group_social_link Optional[ExperienceSocialLink]

The Group social link, if there is one.

guilded_social_link Optional[ExperienceSocialLink]

The Guilded social link, if there is one.

fetch_info()

Fetches the experience's information and fills the experience object parameters.

Returns:

Type Description
Experience

The experience object with parameters filled.

update(voice_chat_enabled=None, private_server_price=None, desktop_enabled=None, mobile_enabled=None, tablet_enabled=None, console_enabled=None, vr_enabled=None, facebook_social_link=None, twitter_social_link=None, youtube_social_link=None, twitch_social_link=None, discord_social_link=None, group_social_link=None, guilded_social_link=None)

Updates the experience information and fills the experience object parameters.

Parameters:

Name Type Description Default
voice_chat_enabled bool

Whether voice chat is enabled.

None
private_server_price Union[int, bool]

The price in robux for the private server. Set this to False to disable private servers.

None
desktop_enabled bool

Whether the experience can be played on desktop.

None
mobile_enabled bool

Whether the experience can be played on phones.

None
console_enabled bool

Wehther the experience can be played on consoles.

None
vr_enabled bool

Whether the experience can be played on VR headsets.

None
facebook_social_link Union[ExperienceSocialLink, bool]

The experience's Facebook social link.

None
twitter_social_link Union[ExperienceSocialLink, bool]

The experience's Twitter social link.

None
youtube_social_link Union[ExperienceSocialLink, bool]

The experience's YouTube social link.

None
twitch_social_link Union[ExperienceSocialLink, bool]

The experience's Twitch social link.

None
discord_social_link Union[ExperienceSocialLink, bool]

The experience's Discord social link.

None
group_social_link Union[ExperienceSocialLink, bool]

The experience's Roblox group social link.

None
guilded_social_link Union[ExperienceSocialLink, bool]

The experience's Guilded social link.

None

Returns:

Type Description
Experience

The experience object with parameters filled.

Tip

To update the experience's name or description use Place.update on the experience's start place.

get_place(place_id)

Creates a Place class for a place within the experience. Does not make any API calls.

Parameters:

Name Type Description Default
place_id int

The ID of the place.

required

Returns:

Type Description
Place

The created place object with all parameters as None except id and experience.

get_datastore(name, scope='global')

Creates a DataStore with the provided name and scope.

Parameters:

Name Type Description Default
name str

The data store name.

required
scope Optional[str]

The data store scope. Use None for scope/key syntax.

'global'

Returns:

Type Description
DataStore

The created data store object with DataStore.created as None.

get_ordered_datastore(name, scope='global')

Creates an OrderedDataStore with the provided name and scope.

Parameters:

Name Type Description Default
name str

The data store name.

required
scope Optional[str]

The data store scope. Use None for scope/key syntax.

'global'

Returns:

Type Description
OrderedDataStore

The created data store object.

list_datastores(prefix=None, limit=None, scope='global', show_deleted=False)

Iterates all data stores in the experience.

Parameters:

Name Type Description Default
prefix str

Filters data stores to those which start with prefix.

None
limit int

The maximum number of Data Stores to iterate.

None
scope Optional[str]

The scope data stores should have. Can be None for key syntax like scope/key.

'global'

Yields:

Type Description
Iterable[DataStore]

DataStore for every datastore in the experience.

snapshot_datastores()

Takes a new snapshot of the data stores in an experience. This means that all current versions are guaranteed to be available for at least 30 days.

Only one snapshot may be taken each UTC day and returns the last time a snapshot was created if one has already been made today.

Returns:

Type Description
tuple[bool, datetime]

A tuple with a boolean of whether a new snapshot was taken and the time of the last snapshot.

get_sorted_map(name)

Creates a SortedMap with the provided name. This function doesn't make an API call so there is no validation.

Parameters:

Name Type Description Default
name str

The memory store sorted map name.

required

Returns:

Type Description
SortedMap

The sorted map with the provided name.

get_memory_store_queue(name)

Creates a MemoryStoreQueue with the provided name. This function doesn't make an API call so there is no validation.

Parameters:

Name Type Description Default
name str

The memory store queue name.

required

Returns:

Type Description
MemoryStoreQueue

The memory store queue with the provided name.

publish_message(topic, data)

Publishes a message to live game servers that can be recieved with MessagingService.

Parameters:

Name Type Description Default
topic str

The topic to publish the message into.

required
data str

The message to send. Open Cloud only supports string data, not dictionaries nor json objects.

required

Note

Messages sent by Open Cloud will only be recieved by live servers. Studio won't recieve thesse messages.

send_notification(user_id, message_id, launch_data=None, analytics_category=None, **message_variables)

Sends an Experience notification to the requested user.

Parameters:

Name Type Description Default
user_id int

The user to recieve the notification.

required
message_id str

The notification string ID.

required
analytics_category str

The category string used for analytics.

None
launch_data str

The launch data used if the player joins.

None
**message_variables dict[str, Union[str, int]]

values to fill variables in the notification string. Message variables for user mentions should be formatted as userid_<key>, where <key> is the variable key.

{}

restart_servers(place_ids=None, exclude_latest_version=False, bleed_servers_minutes=None)

Shuts down all game servers in the experience optionally excluding those on the latest published version. Similar to the Server Management page on the Creator Dashboard and the "Restart Servers" button.

See Introducing Server Management on the DevForum for more information.

Requires universe:write on an API Key or OAuth2 authorization.

Parameters:

Name Type Description Default
place_ids Optional[list[Union[int, str, Place]]]

A list of places to restart servers for. If None, all places in the experience will be restarted.

None
exclude_latest_version bool

Whether to exclude servers which are already on the latest published version. Defaults to False, meaning all servers will be restarted.

False
bleed_servers_minutes Optional[int]

The number of minutes between 1 and 60 to gracefully shutdown servers. Matchmaking will be stopped to the servers and will give time for players to leave.

None
Example

Restarts all out of date servers for an update, while giving players 30 minutes to leave gracefully.

experience.restart_servers(
    exclude_latest_version=True,
    bleed_servers_minutes=30,
)

flush_memory_store()

Flushes all memory store sorted map and queue data.

Returns:

Type Description
Operation[bool]

An Operation to determine when the operation is complete.

fetch_subscription(product_id, user_id)

Fetches information about a user's subscription to a product within the experience.

Parameters:

Name Type Description Default
product_id str

The subscription product ID, starting with EXP-, to consider.

required
user_id int

The subscription ID, which is always the user's ID to fetch subscription information for.

required

Returns:

Type Description
Subscription

The subscription for the product ID and user ID.

list_ban_logs(user_id=None, place_id=None, limit=None)

Lists all ban and unban logs within the universe, optionally filtered to a specific user and/ or place.

Parameters:

Name Type Description Default
user_id int

The user ID to fetch history for.

None
place_id int

Only include ban logs for this specific place ID.

None

Yields:

Type Description
Iterable[UserRestriction]

Restriction information for each ban log found.

list_user_restrictions(place_id=None, limit=None)

Lists all user restrictions for users who have ever been banned within the universe, optionally filtered to a specific place. The difference between this and list_ban_logs() is that this only returns the latest user restriction for each user, while list_ban_logs returns a log of all ban and unban events.

Requires universe.user-restriction:read on an API Key or OAuth2 authorization.

Parameters:

Name Type Description Default
place_id int

Only include user restrictions for this specific place ID.

None
limit int

The maximum number of user restrictions to return. Defaults to no limit.

None

Yields:

Type Description
Iterable[UserRestriction]

Restriction information for each user restriction found.

fetch_user_restriction(user_id)

Fetches the current restriction information for a user universe-wide. (e.g. whether they are banned.)

Parameters:

Name Type Description Default
user_id int

The user ID to fetch restriction information for.

required

Returns:

Type Description
UserRestriction

The current restriction information for the requested user.

ban_user(user_id, duration_seconds, display_reason='', private_reason='', exclude_alt_accounts=False)

Updates the current user restriction for a user on the universe-wide level.

Parameters:

Name Type Description Default
user_id int

The ID of the user to update restrictions for.

required
duration_seconds Optional[int]

The number of seconds the ban should last. Provide None for an indefinite restriction.

required
display_reason str

The reason for the ban shown to the client.

''
private_reason str

The reason for the ban never shown to the client.

''
exclude_alt_accounts bool

Whether the user's detected alt accounts shouldn't be banned as well.

False

Returns:

Type Description
UserRestriction

The updated restriction information for the requested user.

unban_user(user_id)

Removes the current user restriction for a user on the universe-wide level.

Parameters:

Name Type Description Default
user_id int

The ID of the user to remove restrictions for.

required

Returns:

Type Description
UserRestriction

The updated restriction information for the requested user.

list_secrets(limit=None)

Lists all HTTP secrets within the experience.

Parameters:

Name Type Description Default
limit int

The maximum number of secrets to return. Defaults to no limit.

None

Yields:

Type Description
Iterable[Secret]

The secret information including their domain, update time and create time.

fetch_secrets_public_key()

Fetches the public key used to encrypt secrets for this experience. This is used for encrypting secrets manually before sending them to Roblox. This endpoint is not neccessary as the library will handle this when using create_secret and update_secret.

Returns:

Type Description
tuple[str, bytes]

A tuple with the key ID and the public key encoded.

Example

This is an example to manually encode using PyNaCl. This is essentially what the library already does for you.

from nacl import public, encoding

secret_content = 'secret content'
key_id, public_key = experience.fetch_secrets_public_key()

# Create a LibSodium sealed box using PyNaCl
public_key = public.PublicKey(
    public_key, encoding.Base64Encoder()
)
sealed_box = public.SealedBox(public_key)

# Encrypt the secret content
encrypted = sealed_box.encrypt(secret_content.encode("utf-8"))

# Upload the secret to Roblox.
experience.create_secret(
    'secret_id', b64encode(encrypted), key_id=key_id
)

create_secret(id, secret, key_id=None, domain='*')

Creates a new secret for the experience. The secret is encrypted automatically if key_id is not present; make sure key_id is provided if manually encrypted.

Parameters:

Name Type Description Default
id str

The ID of the secret, must be unqiue.

required
secret Union[str, bytes]

The value of the secret. This may be encrypted using your own logic or left unencrypted.

required
key_id str

If encrypted manually using own logic, this must be the key ID provided by Roblox. Do not provide this if the key was not manually encrypted with fetch_secrets_public_key .

None
domain str

The domain this secret is allowed for, optionally starting with a wildcard. Defaults to *, allowing all domains.

'*'

Returns:

Type Description
Secret

The created secret with only the update and create time and id attributes.

update_secret(id, secret, key_id=None, domain=None)

Updates an existing secret for the experience. The secret is encrypted automatically if key_id is not present; make sure key_id is provided if manually encrypted.

Parameters:

Name Type Description Default
id str

The ID of the existing secret.

required
secret Union[str, bytes]

The new value of the secret. This may be encrypted using your own logic or left unencrypted.

required
key_id str

If encrypted manually using own logic, this must be the key ID provided by Roblox. Do not provide this if the key was not manually encrypted with fetch_secrets_public_key .

None
domain str

The domain this secret is allowed for, optionally starting with a wildcard. Defaults to leaving unchanged.

None

Returns:

Type Description
Secret

The updated secret with only the update time and id attributes.

delete_secret(id)

Deletes an existing secret for the experience.

Parameters:

Name Type Description Default
id str

The ID of the secret to delete.

required

generate_speech_asset(text, voice_id='1', pitch=0.0, speed=1.0)

Generates a text-to-speech asset. Supports English only.

Parameters:

Name Type Description Default
text str

The text to convert to speech.

required
voice_id str

The voice ID to use. View voice IDs on the Creator Documentation

'1'
pitch float

The pitch adjustment for the voice.

0.0
speed float

The speed adjustment for the voice.

1.0

Returns:

Type Description
Operation[Asset]

Returns an Operation that can be resolved to an Asset for the generated text-to-speech.

Example
operation = experience.generate_speech_asset(
    "Hello World!", voice_id="1", pitch=0.0, speed=1.0
)

asset = operation.wait()

print(asset)
>>> <rblxopencloud.Asset id=113523671173037 type=AssetType.Audio>

translate_text(text, target_language_codes=None, source_language_code=None)

Translates the provided text into the target language codes.

Supported language codes include: English (en-us), French (fr-fr), Vietnamese (vi-vn), Thai (th-th), Turkish (tr-tr), Russian (ru-ru), Spanish (es-es), Portuguese (pt-br), Korean (ko-kr), Japanese (ja-jp), Chinese Simplified (zh-cn), Chinese Traditional (zh-tw), German (de-de), Polish (pl-pl), Italian (it-it), Indonesian (id-id)

Parameters:

Name Type Description Default
text str

The text to translate.

required
target_language_codes list[str]

The IETF BCP-47 language codes to translate the text into.

None
source_language_code Optional[str]

The source IETF BCP-47 language code of the text. If not provided, the source language will be auto-detected.

None

Returns:

Type Description
tuple[str, dict[str, str]]

A tuple with the source language code as the first return and a dictionary mapping target language codes to the translated text.

list_developer_products(limit=None)

Lists all developer products within the experience.

Parameters:

Name Type Description Default
limit int

The maximum number of developer products to return. Defaults to no limit.

None

Yields:

Type Description
Iterable[DeveloperProduct]

The developer product information for each developer product.

fetch_developer_product(product_id)

Fetches a specific developer product within the experience.

Parameters:

Name Type Description Default
product_id int

The developer product ID to fetch.

required

Returns:

Type Description
DeveloperProduct

The developer product information.

create_developer_product(name, description=None, price_in_robux=None, regional_pricing_enabled=False, icon_file=None)

Creates a developer product within the experience.

Example
with open("icon.png", "rb") as icon_file:
    developer_product = experience.create_developer_product(
        name="My Developer Product",
        description="This is my developer product.",
        price_in_robux=670,
        regional_pricing_enabled=True,
        icon_file=icon_file,
    )
print(developer_product)
>>> <rblxopencloud.DeveloperProduct id=0000000000 name='My Developer Product'>

Parameters:

Name Type Description Default
name str

The name of the developer product. Must be unique within the experience.

required
description str

The optional description of the developer product.

None
price_in_robux Optional[int]

The price in robux of the developer product. Provide None for it to be off sale.

None
regional_pricing_enabled bool

Whether regional pricing is enabled for the developer product. Must have a price set to enable.

False
icon_file BytesIO

An optional icon file for the developer product as a file opened with rb mode.

None

Returns:

Type Description
DeveloperProduct

The created developer product information.

update_developer_product(product_id, name=None, description=None, price_in_robux=None, regional_pricing_enabled=None, store_page_enabled=None, icon_file=None)

Updates an existing developer product within the experience.

Parameters:

Name Type Description Default
product_id int

The developer product ID to update.

required
name str

The name of the developer product. Must be unique within the experience.

None
description str

The optional description of the developer product. Set to "" to clear any existing description.

None
price_in_robux Union[int, Literal[False]]

The price in robux of the developer product. Provide None for it to be off sale.

None
regional_pricing_enabled bool

Whether regional pricing is enabled for the developer product. Must have a price set to enable.

None
icon_file BytesIO

An optional icon file for the developer product as a file opened with rb mode.

None
Example
with open("icon.png", "rb") as icon_file:
    experience.update_developer_product(
        product_id=0000000000
        name="My Developer Product",
        description="This is my developer product.",
        price_in_robux=670,
        regional_pricing_enabled=True,
        icon_file=icon_file,
    )

list_game_passes(limit=None)

Lists all game passes within the experience.

Parameters:

Name Type Description Default
limit int

The maximum number of game passes to return. Defaults to no limit.

None

Yields:

Type Description
Iterable[GamePass]

The game pass information for each game pass.

fetch_game_pass(pass_id)

Fetches a specific game pass within the experience.

Parameters:

Name Type Description Default
pass_id int

The game pass ID to fetch.

required

Returns:

Type Description
GamePass

The game pass information.

create_game_pass(name, description=None, price_in_robux=None, regional_pricing_enabled=False, icon_file=None)

Creates a game pass within the experience.

Parameters:

Name Type Description Default
name str

The name of the game pass.

required
description str

The description of the game pass.

None
price_in_robux Optional[int]

The price in robux of the game pass. Provide None for it to be off sale.

None
regional_pricing_enabled bool

Whether regional pricing is enabled for the game pass. Must have a price set to enable.

False
icon_file BytesIO

The icon file for the game pass as a file opened with rb mode.

None

Returns:

Type Description
GamePass

The created game pass information.

update_game_pass(pass_id, name=None, description=None, price_in_robux=None, regional_pricing_enabled=False, icon_file=None)

Updates a game pass within the experience.

Parameters:

Name Type Description Default
pass_id int

The game pass ID to update.

required
name str

The new name of the game pass.

None
description str

The new optional description of the game pass. Set to "" to clear any existing description.

None
price_in_robux Union[int, Literal[False]]

The new price in robux of the game pass. Provide None for it to be off sale.

None
regional_pricing_enabled bool

Whether regional pricing is enabled for the game pass. Must have a price set to enable.

False
icon_file BytesIO

An optional new icon file for the game pass as a file opened with rb mode.

None

fetch_badge(badge_id)

Fetchs a badge on Roblox. The badge ID does not necessarily have to be within the experience. root_place and name for this experience will also be populated if the badge is within the experience.

Requires no authorization.

Parameters:

Name Type Description Default
badge_id int

The ID of the badge to fetch.

required

Returns:

Type Description
Badge

The badge information for the requested badge ID.

Legacy API

This endpoint uses the legacy Badges API. Roblox has noted in this DevForum post that these endpoints may change without notice and break your application. Therefore, they should be used with caution.

Please report issues with this endpoint on the GitHub issue tracker or the Discord server.

create_badge(name, icon_file, description=None, enabled=True, expected_robux_price=0, use_group_funds=False)

Creates a new badge within the experience. root_place and name for this experience will also be populated.

Requires legacy-universe.badge:manage-and-spend-robux on an API Key or OAuth2 authorization.

Parameters:

Name Type Description Default
name str

The name of the new badge

required
icon_file BytesIO

The icon for the badge as a file opened with rb mode.

required
description str

The description for the badge.

None
enabled bool

Whether the badge can be awarded and appears on the game page.

True
expected_robux_price int

The amount of robux expected to upload the badge. Will fail if lower than the actual price.

0
use_group_funds bool

Whether to use group funds to pay for the badge creation.

False

Returns:

Type Description
Badge

The created badge.

Legacy API

This endpoint uses the legacy Badges API. Roblox has noted in this DevForum post that these endpoints may change without notice and break your application. Therefore, they should be used with caution.

Please report issues with this endpoint on the GitHub issue tracker or the Discord server.

update_badge(badge_id, name=None, description=None, enabled=None, icon_file=None)

Updates the badge with the requested badge ID.

Requires legacy-universe.badge:write on an API Key or OAuth2 authorization to update enabled, name, and description. Requires legacy-badge:manage on an API Key or OAuth2 authorization to update icon_file.

Parameters:

Name Type Description Default
enabled bool

Whether the badge can be awarded and appears on the game page.

None
name str

The new name for the badge.

None
description str

The new description for the badge.

None
icon_file BytesIO

The new icon for the badge as a file opened with rb mode.

None

Legacy API

This endpoint uses the legacy Badges API. Roblox has noted in this DevForum post that these endpoints may change without notice and break your application. Therefore, they should be used with caution.

Please report issues with this endpoint on the GitHub issue tracker or the Discord server.

Note

This function uses seperate endpoints for updating the badge information and the badge icon. If icon_file is provided, it will make a seperate request to update the icon. This could result in an exception being raised during the icon update resulting in badge information being updated but not the icon.

To ensure that exceptions are catched seperately for each endpoint, the information and icon should be updated in seperate requests.

fetch_published_config()

Fetches the experience configuration for the experience.

Requires universe:read on API Key or OAuth2 authorization.

Returns:

Type Description
CreatorConfig

The experience configuration for the experience.

fetch_draft_config()

Fetches the current draft changes for the experience configuration. A draft configuration will only contain keys that have changes; unchanged keys in the published configuration are omitted.

Requires universe:read on API Key or OAuth2 authorization.

Returns:

Type Description
CreatorConfig

The draft experience configuration for the experience, if it exists.

Raises:

Type Description
NotFound

There are no current draft changes.

publish_draft_config(deployment_strategy=CreatorConfigDeploymentStrategy.Immediate, message=None, draft_hash=None)

Publishes the current draft experience configuration. This will make the draft configuration the new published configuration.

Requires universe:write on API Key or OAuth2 authorization.

Parameters:

Name Type Description Default
deployment_strategy CreatorConfigDeploymentStrategy

The strategy to use when deploying the new configuration and can allow gradual rollouts of new configuration.

Immediate
message str

An optional message describing the changes in this draft.

None
draft_hash str

If provided, only publishes if the current draft matches the provided hash. Used for concurrency control.

None

Returns:

Type Description
int

The new configuration version number after publishing the draft.

update_draft_config(entries, draft_hash=None, overwrite=False)

Updates the staged changes for the experience configuration with the provided entries. Changes will not update in game servers until publish_draft_config is called.

Example

Updates spawn_point to vast_plains and xp_multiplier to 2.0, but the existing starting_coins config remains as-is in the published configuration.

experience.update_draft_config(
    entries={
        "spawn_point": "vast_plains",
        "xp_multiplier": 2.0
    },
    overwrite=False,
)
However, if overwrite is set to True, the existing starting_coins config will be staged for deletion since it is not included in the entries update.

Requires universe:write on API Key or OAuth2 authorization.

Parameters:

Name Type Description Default
entries dict[str, Union[str, float, bool, dict, None]]

A dictionary of configuration keys to update with their new values. If a value is None, the key will be staged to be deleted.

required
draft_hash str

If provided, only updates the draft if the current draft matches the provided hash. Used for concurrency control.

None
overwrite bool

If True, the entries field will update the draft so that when published, the published configuration will exactly match entries. Any keys excluded from entries will be staged to be deleted.

False

Returns:

Type Description
str

The new draft hash after updating the draft.

delete_draft_config(draft_hash=None)

Discards any drafted changes for the experience configuration.

Requires universe:write on API Key or OAuth2 authorization.

Parameters:

Name Type Description Default
draft_hash str

If provided, only updates the draft if the current draft matches the provided hash. Used for concurrency control.

None

Returns:

Type Description
str

The new draft hash after updating the draft.

Non-creatable Dataclasses

rblxopencloud.Badge

Represents a badge within an experience on Roblox.

Attributes:

Name Type Description
id int

The badge's ID.

experience Optional[Experience]

The experience this badge belongs to.

name str

The badge's name.

description str

The badge's description.

icon_asset_id int

The Roblox image asset ID of the badge's icon.

enabled bool

Whether the badge is currently enabled, meaning it can be awarded to users and is visible on the experience detail page.

created_at datetime

The time the badge was created.

updated_at datetime

The time the badge was last updated.

awarded_past_day int

The number of times this badge was awarded in the past day.

awarded_total int

The total number of times this badge has been awarded.

win_rate_percentage float

The percentage of players awarded this badge as a number between 0 and 1.

experience Optional[Experience]

The experience this badge belongs to. If the badge experience is the same as the experience used to fetch it, it will return the same experience object, otherwise a new experience object will be created. name and root_place should be populated.

rblxopencloud.CreatorConfig

Bases: dict

Represents the creator configuration for an experience on Roblox. Roblox indicates that these will have further purposes in the future.

Example

This example will list all the keys and output their values and when the value was last accessed

config = experience.fetch_published_config()

### List all the keys and output their values and when they were last accessed
for key, entry in config.full_config.items():
    print(f"The config '{key}' has the value {repr(entry.value)} and was last accessed {entry.accessed_at}")        
To get only a value of a key, the following dictionary syntaxes are also supported:
value = config["key"]
value = config.get("key", "default")
Note this dictionary allows write access, and can be written to and passed to functions that expect a dictionary. For instance
import json

result = json.dumps(config, indent=2)
>>> """{
>>>   "spawn_point": "monster_cave",
>>>   "xp_multiplier": 1.5,
>>>   "starting_coins": 6700
>>> }"""

Further, dict can be used to get only the dictionary object:

config_dict = dict(config)

Attributes:

Name Type Description
version_number Optional[int]

The version number of this configuration.

full_config dict[str, CreatorConfigEntry]

A key-metadata dictionary with each config value.

draft_hash Optional[str]

The hash of the draft configuration, not included if the config is published.

Methods:

Name Description
__dict__

A key-value dictionary of the configuration keys and their current values.

rblxopencloud.CreatorConfigEntry

Represents a single entry in an experience's configuration.

Attributes:

Name Type Description
key str

The key of this configuration entry.

value Union[Union[str, float, bool, dict]]

The value of this configuration entry.

description Optional[str]

The description of this configuration entry, if provided. The description cannot be updated with Open Cloud, only on the Creator Dashboard.

updated_at Optional[datetime]

The time this configuration entry was last updated.

accessed_at Optional[datetime]

The time this configuration entry was last accessed by a game server.

rblxopencloud.DeveloperProduct

Represents a developer product within an experience on Roblox.

Attributes:

Name Type Description
id int

The developer product's ID.

experience Experience

The experience this developer product belongs to.

name str

The developer product's name.

description str

The developer product's description.

icon_asset_id int

The Roblox image asset ID of the developer product's icon.

is_for_sale bool

Whether the developer product is currently for sale.

store_page_enabled bool

Whether the developer product can be purchased on the experience's store page.

regional_pricing_enabled bool

Whether the developer product has regional pricing enabled.

price_in_robux Optional[int]

The price of the developer product in Robux.

created_at datetime

The time the developer product was created.

updated_at datetime

The time the developer product was last updated.

Represents a social link in an experience.

Parameters:

Name Type Description Default
title str

The text displayed for the social link.

required
uri str

The URI of the social link.

required

Attributes:

Name Type Description
title

The text displayed for the social link.

uri

The URI of the social link.

rblxopencloud.GamePass

Represents a game pass within an experience on Roblox.

Attributes:

Name Type Description
id int

The game pass's ID.

experience Experience

The experience this game pass belongs to.

name str

The game pass's name.

description str

The game pass's description.

icon_asset_id int

The Roblox image asset ID of the game pass's icon.

is_for_sale bool

Whether the game pass is currently for sale.

regional_pricing_enabled bool

Whether the game pass has regional pricing enabled.

price_in_robux Optional[int]

The price of the game pass in Robux.

created_at datetime

The time the game pass was created.

updated_at datetime

The time the game pass was last updated.

rblxopencloud.Place

Represents a place within an experience on Roblox.

Attributes:

Name Type Description
id int

The place's ID.

experience Experience

The experience this place is a part of.

name Optional[str]

The place's name.

description Optional[str]

The place's description.

created_at Optional[datetime]

The time the place was created.

updated_at Optional[datetime]

The time the place was last updated.

server_size Optional[str]

The number of players the can be in a single server.

is_root_place bool

Whether this place is the primary place of its universe/experience.

is_universe_runtime_creation bool

Whether this place was created using AssetService:CreatePlaceAsync().

fetch_info()

Fetches the places's information and fills the Place object parameters.

Returns:

Type Description
Place

The place object with parameters filled.

update(name=None, description=None, server_size=None)

Updates information for the place and fills the empty parameters.

Parameters:

Name Type Description Default
name str

The new name for the place.

None
description str

The new description for the place.

None
server_size int

The new server size for the place.

None

Returns:

Type Description
Place

The place object with the empty parameters filled.

upload_place_file(file, publish=False)

Uploads the place file to Roblox, optionally choosing to publish it.

Parameters:

Name Type Description Default
file BytesIO

The place file to upload, opened in bytes.

required
publish bool

Wether to publish the new place file.

False

Returns:

Type Description
int

The place's new version ID.

get_asset()

Creates a partial Asset representing this place. This exposes endpoints related to assets, such as versioning and rollback.

Returns:

Type Description
Asset

The asset representing the place, where moderation_status, revision_id, and revision_time are not populated. Further, name and description are only populated from the place if previously fetched.

Warning

If the place's experience has not been fetched, the asset's creator will be blank and not represent the actual creator of the place. In this case, do not attempt to use the returned asset's creator to upload new assets.

Tip

Use Place.fetch_asset to ensure a fully populated asset is returned.

fetch_asset()

Fetches a fully populated Asset representing this place. This exposes endpoints related to assets, such as versioning and rollback. If the place's experience's info has not been fetched, the library will automatically do that first.

Returns:

Type Description
Asset

The asset representing the place.

Tip

Use Place.get_asset to get a partial asset without making additional requests. This is useful if you do not require the additional asset information.

list_user_restrictions(limit=None)

Lists all user restrictions for users who have ever been banned within the place.

Requires universe.user-restriction:read on an API Key or OAuth2 authorization.

Parameters:

Name Type Description Default
limit Optional[int]

The maximum number of user restrictions to return. Defaults to no limit.

None

Yields:

Type Description
Iterable[UserRestriction]

Restriction information for each user restriction found.

fetch_user_restriction(user_id)

Fetches the current restriction information for the specific place.

Parameters:

Name Type Description Default
user_id int

The user ID to fetch restriction information for.

required

Returns:

Type Description
UserRestriction

The current restriction information for the requested user.

ban_user(user_id, duration_seconds, display_reason='', private_reason='', exclude_alt_accounts=False)

Updates the current user restriction for a user within the place.

Parameters:

Name Type Description Default
user_id int

The ID of the user to update restrictions for.

required
duration_seconds Optional[int]

The number of seconds the ban should last. Provide None for an indefinite restriction.

required
display_reason str

The reason for the ban shown to the client.

''
private_reason str

The reason for the ban never shown to the client.

''
exclude_alt_accounts bool

Whether the user's detected alt accounts shouldn't be banned as well.

False

Returns:

Type Description
UserRestriction

The updated restriction information for the requested user.

unban_user(user_id)

Removes the current user restriction for a user within the place.

Parameters:

Name Type Description Default
user_id int

The ID of the user to remove restrictions for.

required

Returns:

Type Description
UserRestriction

The updated restriction information for the requested user.

rblxopencloud.Secret

Represents a secret in an experience. Secrets can be accessed in game servers using HttpService:GetSecret().

Attributes:

Name Type Description
id str

The id or key of this secret. This is unique accross the experience and is used by game servers to fetch its value.

domain str

The domain the secret can be used with. * means it may be used with any domain. Depending on how this secret was obtained, this may be None.

created_at Optional[datetime]

The time this secret was created. Depending on how this secret was obtained, this may be None.

updated_at Optional[datetime]

The time this secret was last updated. Depending on how this secret was obtained, this may be None.

experience Experience

The experience this key belongs to.

update(secret, key_id=None, domain=None)

Updates the secret. The secret is encrypted automatically if key_id is not present; make sure key_id is provided if manually encrypted.

Parameters:

Name Type Description Default
secret Union[str, bytes]

The new value of the secret. This may be encrypted using your own logic or left unencrypted.

required
key_id str

If encrypted manually using own logic, this must be the key ID provided by Roblox. Do not provide this if the key was not manually encrypted with fetch_secrets_public_key .

None
domain str

The domain this secret is allowed for, optionally starting with a wildcard. Defaults to leaving unchanged.

None

Returns:

Type Description
Secret

The Secret itself with updated values.

delete()

Deletes the secret for this secret.

rblxopencloud.Subscription

Represents a subscription to a subscription product.

Attributes:

Name Type Description
user_id int

The user ID, or the subscription ID of this subscription.

product_id str

The ID of the subscription product.

active bool

Wether the subscription is currently active (not expired).

will_renew bool

Wether the subscription will renew after period_end_at.

state SubscriptionState

The subscriptions's current state.

created_at datetime

The time the subscription was created at (subscribed at).

updated_at datetime

The time the subscription was last updated at.

last_billed_at datetime

The time the user last payed for the subscription.

period_end_at datetime

The time the current billing period ends at. If active this is when the subscription will renew at and if not active is when the subscription will expire at.

payment_provider PaymentProvider

The user's payment provider for this subscription.

purchase_platform Platform

The platform the subscription was started on.

expiration_reason Optional[SubscriptionExpirationReason]

The reason the subscription expired.

rblxopencloud.UserRestriction

Represents a user restriction (or ban) within an experience or place on Roblox.

Attributes:

Name Type Description
place Optional[Place]

The place object this restriction belongs to. None if it is universe-wide.

user User

The user object that this restriction relates to.

active bool

Whether the restriction is currently active.

display_reason str

The reason for this restriction shown to the client.

private_reason str

The reason for this restriction never shwon to the client. Can be used to store sensitive information about the ban.

inherited Optional[bool]

For bans specific to a place, whether the ban was inherited from a universe-wide ban.

exclude_alt_accounts bool

Whether the ban should not attempt to prevent alternate accounts.

duration_seconds Optional[float]

The number of seconds this restriction is for. None means it is indefinite or not active.

start_timestamp Optional[datetime]

The timestamp this restriction started at.

issuer_user_id Optional[int]

Only for Experience.list_ban_logs, the user ID identified to have issued the ban. None if issued by a game script.

Enums

rblxopencloud.CreatorConfigDeploymentStrategy

Bases: Enum

Enum representing the deployment strategy to use when publishing a CreatorConfig.

Attributes:

Name Type Description
Immediate 0

Deploy the new configuration to game servers immediately.

GradualRollout 1

Deploy the new configuration to game servers over a 15 minute period.

rblxopencloud.ExperienceAgeRating

Bases: Enum

Enum representing an experience's age rating.

Attributes:

Name Type Description
Unknown 0

The experience age rating is unknown or not implemented.

Unspecified 1

The experience has not provided an age rating.

Minimal 2

The experience is marked as Minimal. Renders on the Roblox website as 5+.

Mild 3

The experience is marked as Mild. Renders on the Roblox website as 5+.

Moderate 4

The experience is marked as Moderate. Renders on the Roblox website as 13+.

Restricted 5

The experience is marked as Restricted. Renders on the Roblox website as 18+.

AllAges 2

Deprecated in favor of Minimal.

NinePlus 3

Deprecated in favor of Mild.

ThirteenPlus 4

Deprecated in favor of Moderate.

SeventeenPlus 5

Deprecated in favor of Restricted.

rblxopencloud.SubscriptionExpirationReason

Bases: Enum

Enum representing the reason why a Subscription expired.

Attributes:

Name Type Description
Unknown 0

The expiration reason is unknown or not specified.

Cancelled 1

The subscribing user cancelled the subscription.

Refunded 2

The subscribing user requested a refund for the subscription.

Lapsed 3

Payment was not recieved when the subscription was renewed.

ProductInactive 4

The subscription product was set to inactive.

ProductDeleted 5

The subscription product was deleted.

rblxopencloud.SubscriptionState

Bases: Enum

Enum representing the current state of a Subscription.

Attributes:

Name Type Description
Unknown 0

The current state is unknown or unspecified.

Active 1

The subscription is active and set to renew.

PendingCancelation 2

The subscription is active but will not renew.

PendingRenewal 3

The subscription is currently in the grace period and pending payment confirmation.

Expired 4

The subscription has expired.

rblxopencloud.PaymentProvider

Bases: Enum

Enum representing a payment provider, currently used for Subscription.

Attributes:

Name Type Description
Unknown 0

The provider is unknown or not specified.

RobloxCredit 1
Stripe 2
Google 3
Apple 4

rblxopencloud.Platform

Bases: Enum

Enum representing a platform, currently used for Subscription.

Attributes:

Name Type Description
Unknown 0

The platform is unknown or not specified.

Desktop 1
Mobile 2