def METHOD_NAME(
    token: str,
    key: str,
    *,  # Force passing optional arguments by keyword
    audience: str | bool | None = None,
    algorithms: list[str] | None = None,
) -> dict[str, JSONData]:
    """Returns the claims (payload) in the JWT token.
    This will raise an exception if the claims can not be validated with the provided key.
    :param token: The JWT token to decode.
    :param key: The key as bytes.  Depending on the algorithm this can have several formats,
       e.g. for HS256 it can be any string of characters, for RS256 it must be PEM formatted
       RSA PRIVATE_KEY.
    :param audience: Set this to the audience you expect to be present in the claims.  Set
       this to ``False`` to disable verifying the audience.
    :param algorithms: The algorithms which should be tried to verify the payload.
    """
    # TODO: We do not currently have type-safety for keys suitable for decoding *and*
    # encoding vs those only suitable for decoding.
    # TODO(flub): The algorithms parameter really does not need to be optional and should be
    # a straight list[str].  However this is used by some unclear code in
    # sentry.integrations.msteams.webhook.verify_signature which isn't checked by mypy yet,
    # and I am too afraid to change this.  One day (hah!) all will be checked by mypy and
    # this can be safely fixed.
    options = {"verify": True}
    kwargs = dict()
    if audience is False:
        options["verify_aud"] = False
    elif audience is True:
        raise ValueError("audience can not be True")
    elif audience is not None:
        kwargs["audience"] = audience
    if algorithms is None:
        algorithms = ["HS256"]
    return pyjwt.METHOD_NAME(token, key, options=options, algorithms=algorithms, **kwargs)