def spotify_id_from_url(url: str) -> str:
    """Extract the `Spotify ID`_ from a Spotify URL.

    Args:
        url (str): The URL to extract the `Spotify ID`_ from.

    Returns:
        str: The extracted `Spotify ID`_.
    """

    url = url[::-1]
    url = url.split("/")[0]
    url = url[::-1]
    url = url.split("?")[0]
    return url