def resource_is_list(resource):
    """Check if the resource is a list."""
    if resource:
        return (
            "kind" in resource
            and "apiVersion" in resource
            and resource["kind"].endswith("List")
        )
    return False