Skip to content

0.1.0

Choose a tag to compare

@jwcarman jwcarman released this 14 Apr 00:20
· 496 commits to main since this release

Mocapi 0.1.0

First public release of Mocapi — a Spring Boot framework for building Model Context Protocol (MCP) servers in Java.

Highlights

  • MCP 2025-11-25 compliance — passes the official @modelcontextprotocol/conformance test suite
  • Annotation-driven tools — define tools with @ToolService and @ToolMethod
  • Interactive features — progress notifications, structured logging, form-based elicitation, LLM sampling
  • Fluent elicitation schema builder — type-safe schema construction with RequestedSchemaBuilder
  • Streamable HTTP transport — SSE streaming for tool calls, synchronous JSON for all other methods
  • Pluggable session storage — in-memory, Redis, PostgreSQL, NATS, Hazelcast via Substrate
  • Encrypted SSE event IDs — AES-256-GCM prevents cross-session event enumeration
  • Multi-node ready — sessions, mailboxes, and journals work across nodes with clustered backends
  • 97% test coverage — 400+ unit tests across all modules

Modules

Module Description
`mocapi-api` User-facing API: `@ToolService`, `@ToolMethod`, `McpToolContext`, provider interfaces
`mocapi-model` MCP protocol types
`mocapi-server` Stateful MCP server: session management, JSON-RPC dispatch, tool invocation
`mocapi-transport-streamable-http` Streamable HTTP transport with SSE
`mocapi-spring-boot-starter` All-in-one starter for Spring Boot applications

Quick Start

```xml

com.callibrity.mocapi
mocapi-spring-boot-starter
0.1.0

```

```java
@component
@Toolservice
public class GreetingTool {
@ToolMethod(name = "greet", description = "Returns a greeting")
public GreetingResponse greet(String name) {
return new GreetingResponse("Hello, " + name + "!");
}
public record GreetingResponse(String message) {}
}
```

Dependencies

  • Java 25+
  • Spring Boot 4.0.5
  • Substrate 0.4.0
  • Odyssey 0.8.1
  • RipCurl 2.3.0
  • Methodical 0.3.0

Documentation