def parser(response):
    """Parses the json response from CourtListener /opinions endpoint."""
    results = response.get("results")

    if not results:
        return []

    ids = []

    for result in results:
        _id = result.get("id", None)
        if _id is not None:
            ids.append(_id)

    return ids