Interface McpContractTest.JsonRpcExchange

Enclosing class:
McpContractTest
Functional Interface:
This is a functional interface and can therefore be used as the assignment target for a lambda expression or method reference.

@FunctionalInterface public static interface McpContractTest.JsonRpcExchange
One JSON-RPC exchange against the target server.
  • Method Summary

    Modifier and Type
    Method
    Description
    send(com.fasterxml.jackson.databind.node.ObjectNode message, String sessionId)
    Send a single JSON-RPC message (request or notification) to the target server.
  • Method Details

    • send

      McpContractTest.ExchangeResult send(com.fasterxml.jackson.databind.node.ObjectNode message, String sessionId)
      Send a single JSON-RPC message (request or notification) to the target server.
      Parameters:
      message - the JSON-RPC message to POST
      sessionId - the MCP session id to echo back in the Mcp-Session-Id header, or null
      Returns:
      the parsed exchange result (never null)