qmetrics.net

http4k

Functional Kotlin toolkit for HTTP servers and clients

http4k screenshot

http4k models HTTP as pure Kotlin functions for routing, clients, testing, and integrations. Modules cover servers, cloud connectors, AI adapters, and enterprise add-ons.

Overview

http4k is a Kotlin HTTP toolkit where applications are functions from Request to Response, optionally wrapped by composable filters. The core stays small while add-on modules supply servers, clients, formats, security, templating, WebSockets, and serverless adapters.

Because handlers are plain functions, tests can invoke application logic in memory without starting sockets—a default property rather than a bolt-on test harness. Apps can mount into Jetty, Netty, Servlet containers, AWS Lambda, and other backends, or compile to GraalVM native binaries.

http4k-connect provides typed clients and fakes for cloud and SaaS APIs. http4k-ai adds LLM provider adapters, LangChain4J integration, and agent-oriented helpers with in-memory fakes. Commercial http4k-pro and http4k-enterprise modules add Wiretap tracing, WebAuthn, MCP, hot reload, long-term support, and supply-chain verification tooling.

Artifacts publish to Maven Central and a project Maven repository on a regular release cadence. The ecosystem lists hundreds of integration modules for AWS, GCP, Azure, Kafka, OpenTelemetry, OAuth, and related stacks.

The design favors uniform composition: routing, authentication, and outbound calls all use the same functional patterns, contrasting with heavier annotation-driven frameworks.

Key features

  • Request-to-Response function model
  • Composable filter middleware
  • In-memory HTTP testing
  • Multiple server and client backends
  • Cloud API client modules
  • LLM and agent adapters
  • GraalVM native compilation
  • OpenAPI and security modules

Use cases

  • Kotlin microservices and APIs
  • Serverless HTTP handlers
  • Contract-style unit testing
  • Cloud-integrated backend services
  • LLM-backed agent tooling

Tags

Similar software

FastAPI

Python web framework for building APIs with type hints

FastAPI is a Python web framework for building APIs using standard type hints. It builds on Starlette and Pydantic and generates interactive OpenAPI documentation for the endpoints you define.

★ 105.1k⟳ 9 days agoMIT

NestJS

Progressive TypeScript framework for Node.js backends

Nest organizes Node server apps with modules, dependency injection, and first-party packages for auth, data, queues, and observability.

★ 77.2k⟳ todayMIT

OkHttp

HTTP client for JVM, Android, and GraalVM

OkHttp is an HTTP client library tuned for efficient networking on Android, Java, and GraalVM native images. It offers synchronous and asynchronous call APIs with a fluent request builder.

★ 47.1k⟳ yesterdayApache-2.0
Frameworks & PlatformsDesktop/CLI app

gRPC

Cross-language remote procedure call framework

gRPC is an RPC framework that lets client and server programs communicate transparently and supports building connected, multi-language systems.

★ 45.5k⟳ todayApache-2.0

tRPC

End-to-end typesafe TypeScript APIs without code generation

tRPC helps teams define server procedures and call them from clients with full TypeScript types for inputs, outputs, and errors—no schemas or codegen step.

★ 40.9k⟳ todayMIT
Frameworks & PlatformsDesktop/CLI app

go-zero

Cloud-native Go microservices and RPC framework

go-zero is a Go web and RPC framework with code generation, built-in resilience middleware, and tooling aimed at stable high-traffic services.

★ 33.5k⟳ 9 days agoMIT