handleSetLevel method

FutureOr<EmptyResult> handleSetLevel(
  1. SetLevelRequest request
)

Handle a client request to change the logging level.

Registered for logging/setLevel on the revisions that still have the method, and not on 2026-07-28. handleStreamableHttpRequest answers it with 404 on that revision anyway, so this is what a transport calling handleRequestScopedMessage on its own gets instead.

Implementation

FutureOr<EmptyResult> handleSetLevel(SetLevelRequest request) {
  loggingLevel = request.level;
  return EmptyResult();
}