def METHOD_NAME(app: Flask) -> None:
    global ALLOWED_CLIENTS
    clients = app.config.get("OAUTH2_CLIENTS", [])
    schema = class_schema(OAuth2Client)()
    clients_obj: list[OAuth2Client] = [schema.load(c) for c in clients]
    ALLOWED_CLIENTS = {c.client_id: c for c in clients_obj}
    auth_server.init_app(app)
    auth_server.register_grant(AuthorizationCodeGrant)
    auth_server.register_grant(RefreshTokenGrant)
    # TODO: Do we need to support revocation?
    from timApp.auth.oauth2.routes import oauth
    app.register_blueprint(oauth)
    bearer_cls = create_bearer_token_validator(db.session, OAuth2Token)
    require_oauth.register_token_validator(bearer_cls())