setLoggingLevel method

Future<void> setLoggingLevel(
  1. McpLogLevel level
)

Set the logging level for the server

Implementation

Future<void> setLoggingLevel(McpLogLevel level) async {
  if (!_initialized) {
    throw McpError('Client is not initialized');
  }

  // Spec method name is camelCase: `logging/setLevel`.
  await _sendRequest('logging/setLevel', {'level': level.name});
}