Parse list of :class:`TimeResource` objects based on the mementoweb.org.

    Args:
        url (str): Any url.

    Returns:
        list: :class:`TimeResource` objects.

def mementoweb_api_tags(url):
    """
    Parse list of :class:`TimeResource` objects based on the mementoweb.org.

    Args:
        url (str): Any url.

    Returns:
        list: :class:`TimeResource` objects.
    """
    memento_url = "http://labs.mementoweb.org/timemap/json/"

    r = requests.get(memento_url + url)

    if r.status_code != 200:
        return []

    data = r.json().get("mementos", {}).get("list", [])

    if not data:
        return []

    resources = (
        TimeResource(
            url=item.get("uri", ""),
            date=item.get("datetime", ""),
            val=item.get("datetime", "").split("-")[0],
            source="MementoWeb.org",
        )
        for item in data
    )

    # deduplicate the resources
    resource_dict = {
        res.val: res
        for res in resources
    }

    return sorted(resource_dict.values(), key=lambda x: x.val)