def METHOD_NAME(request: Request) -> str:
    # The way this works, is this will return a list of
    # tuples of (mimetype, qvalue) that is acceptable for
    # our request, combining the request and the types
    # that we have passed in.
    #
    # When the request does not have an accept header, then
    # the full list of offers will be returned.
    #
    # When the request has accept headers, but none of them
    # match, it will be an empty list.
    offers = request.accept.acceptable_offers(
        [
            "text/html",
            "application/vnd.pypi.simple.v1+html",
            "application/vnd.pypi.simple.v1+json",
        ]
    )
    # Default case, we want to return whatevr we want to return
    # by default when there is no Accept header.
    if not offers:
        return "text/html"
    # We've selected a list of acceptable offers, so we'll take
    # the first one as our return type.
    else:
        return offers[0][0]