A server sends notifications/message entries on the response stream of a tools/call request whose _meta contains no io.modelcontextprotocol/logLevel field. Is this allowed?
Select an answer to reveal the explanation.
Short Explanation
Logging in 2026-07-28 is strictly opt-in, request by request. No logLevel in _meta means the client didn't ask, so you don't talk. There's no default level to fall back on, and logging/setLevel is gone.
Full Explanation
Under revision 2026-07-28, clients control logging verbosity per request by including io.modelcontextprotocol/logLevel in the request's _meta. The logging specification says the server MUST NOT emit notifications/message for a request that does not include this field; when the field is present, the server MAY send notifications at or above that level on the response stream of that request, before the final response. Declaring the logging capability tells the client the server can emit log notifications, but it does not create a default level that overrides the per-request opt-in. Moving the notifications to a subscriptions/listen stream is also forbidden, because notifications/message is request-scoped and must never be delivered on a listen stream or any stream other than the one carrying that request's response. logging/setLevel was removed in this revision, so it cannot be a prerequisite. An unrecognized logLevel value SHOULD be rejected with -32602. Exam caveat: the entire Logging feature is deprecated and new servers should log to stderr or OpenTelemetry instead, but servers that still implement it must follow these rules during the deprecation window. Operational check: send identical tools/call requests with and without logLevel in _meta and confirm log notifications appear only on the response stream of the one that set it.