Skip to content

sociallinks

Contains objects related to Roblox social links.

Represents a universe or group's social links.

Attributes:

Name Type Description
id int

The social link's ID.

title str

The social link's title.

url str

The social link's URL.

type SocialLinkType

The social link's type.

Source code in roblox/sociallinks.py
class SocialLink(BaseUniverseSocialLink):
    """
    Represents a universe or group's social links.

    Attributes:
        id: The social link's ID.
        title: The social link's title.
        url: The social link's URL.
        type: The social link's type.
    """

    def __init__(self, client: Client, data: dict):
        self._client: Client = client
        self.id: int = data["id"]
        super().__init__(client=self._client, social_link_id=self.id)
        self.title: str = data["title"]
        self.url: str = data["url"]
        self.type: SocialLinkType = SocialLinkType(data["type"])

    def __repr__(self):
        return f"<{self.__class__.__name__} id={self.id} url={self.url!r} type={self.type!r} title={self.title!r}"

__init__(self, client: Client, data: dict) special

Source code in roblox/sociallinks.py
def __init__(self, client: Client, data: dict):
    self._client: Client = client
    self.id: int = data["id"]
    super().__init__(client=self._client, social_link_id=self.id)
    self.title: str = data["title"]
    self.url: str = data["url"]
    self.type: SocialLinkType = SocialLinkType(data["type"])

__repr__(self) special

Source code in roblox/sociallinks.py
def __repr__(self):
    return f"<{self.__class__.__name__} id={self.id} url={self.url!r} type={self.type!r} title={self.title!r}"

SocialLinkType (Enum)

Represents a type of social link.

Source code in roblox/sociallinks.py
class SocialLinkType(Enum):
    """
    Represents a type of social link.
    """

    facebook = "Facebook"
    twitter = "Twitter"
    youtube = "YouTube"
    twitch = "Twitch"
    discord = "Discord"
    roblox_group = "RobloxGroup"

discord

facebook

roblox_group

twitch

twitter

youtube