Skip to content
CAI
Software that uses CAICheck a score

barrel-platform/barrel_mcp

56.8

Adequate · 15 November 2026

23.2k

lines of production code

Erlang

primary language

4

measurements over time

CAI band scale
CAI trend line
CAI lens gauges

What this system is

Features

New runnable examples for MCP federation, echo client, and sampling

Added three new self-contained Erlang examples under \examples/\ to demonstrate core \barrel\_mcp\ capabilities. The \agent\_host\ example shows how to aggregate tools from multiple federated MCP clients into a single namespaced catalog and route calls back to the correct server. The \echo\_client\ example provides a minimal host that registers an echo tool, connects a client, and performs a round-trip call. The \sampling\_host\ example demonstrates the server-to-client sampling round-trip, where a server-side tool triggers a client-side message handler. Each example includes source code, build configuration, and Common Test suites to verify the behavior.

examples · high confidence

New sampling\_host example demonstrating server-to-client LLM sampling

Added a new Erlang example application (\sampling\_host\) that implements a barrel\_mcp client handler to demonstrate a full server-to-client round-trip for LLM sampling. The example registers a tool (\ask\_sampler\) on the server side which triggers a \sampling/createMessage\ request to the connected client; the client handler then returns a canned reply. It specifically targets the 'handshake era' protocol version (2025-11-25) to demonstrate this interaction pattern, running on port 18081 by default.

_examples/sampling\host · high confidence

Pluggable authentication and multi-server tool aggregation

The library now supports pluggable authentication for both server and client sides. On the server, a new \barrel\_mcp\_auth\ behaviour allows custom providers, with built-in implementations for Bearer tokens (JWT), API keys, HTTP Basic, and a no-auth mode. On the client, \barrel\_mcp\_client\_auth\ manages OAuth 2.1 flows (including PKCE, Client Credentials, and Enterprise Managed Authorization) and static bearer tokens, handling token refresh and DPoP proofs. Additionally, \barrel\_mcp\_agent\ provides a multi-server tool aggregator that namespaces tools from multiple MCP clients into a single catalog and routes tool calls back to the correct server.

src · high confidence

Behavioural changes

1 commit (0 fixes) modifying .claude

A change to existing behaviour in .claude — 1 commit, 2 files: “Adopt the erlang\_quic agent, security and contributing policy”.

.claude · medium confidence · unverified

MCP protocol versioning expanded to support 2026-07-28 stateless era

The library now supports the MCP 2026-07-28 protocol revision alongside legacy handshake-based versions (2024-11-05 through 2025-11-25). This introduces a distinction between 'modern' stateless requests and 'legacy' handshake-based ones, with specific error codes (e.g., -32020 to -32022) and method sets defined for the new era. Legacy-only methods like \ping\ and \logging/setLevel\ are explicitly marked as unknown to modern clients, while modern-only methods like \subscriptions/listen\ and \tasks/update\ are introduced. The header mismatch and missing client capability errors are now standardized under the 2026-07-28 error code range.

include · high confidence

Test coverage

Expanded test coverage for MCP agent, authentication, and protocol features

Added comprehensive test suites for the \barrel\_mcp\_agent\ integration (verifying tool aggregation and routing across multiple clients), \barrel\_mcp\_async\_tools\ (covering async tool cancellation, progress events, and error handling), and \barrel\_mcp\_auth\ (validating PBKDF2/HMAC password hashing, JWT bearer validation, API key verification, and visible/4 filtering). Also added tests for JSON-RPC batch handling across protocol revisions, OAuth client authorization flows (including PKCE, DPoP, and enterprise-managed grants), and client-side auth dispatch.

test · high confidence

Dependencies

Add MCP conformance and interop test dependencies

Added the official MCP conformance suite (version 0.2.0-alpha.11) and the reference server (version 2026.8.18) to the test/conformance directory, enabling automated validation of server compliance. Additionally, configured Python interop test environments with specific MCP SDK versions (1.27.x and 2.0.0) and HTTP/2 libraries (h2, httpx\[http2\]) to support protocol-level interoperability testing.

(dependencies) · high confidence

Housekeeping

Initial project scaffolding and documentation

Adds the AGENTS.md guide for AI coding agents, the Apache 2.0 LICENSE, a Makefile for build and test automation, and the rebar.lock file to pin dependency versions for CI. Updates the README to reflect the current protocol support (2024-11-05 through 2026-07-28) and transport capabilities, and configures rebar.config with the h1/h2/hackney dependencies and ex\_doc extras.

(repo-wide) · high confidence

Written by cca.canine.dev from the codebase's own history, inside the signed delivery this page is composed from.

How this codebase got here

Score

  • CAI 57 → 57 (-0.4)
  • Rubric changed (rubric-2026.10.5 → rubric-2026.11.4) — scores are not directly comparable.

Lenses

  • Code Health 64 → 63 (-1.1)
  • Architecture 100 → 100 (+0.0)
  • Maturity 73 → 73 (+0.2)
  • Readiness 62 → 62 (+0.1)
  • Security 100 → 100 (+0.5)
  • Event-Driven 42 → 42 (+0.0)
  • Event Sourcing 100 → 100 (+0.0)

Resolved (5)

  • Hotspot: src/barrel_mcp_client.erl (src/barrel_mcp_client.erl)
  • Hotspot: src/barrel_mcp_stdio.erl (src/barrel_mcp_stdio.erl)
  • Hotspot: src/barrel_mcp_tasks.erl (src/barrel_mcp_tasks.erl)
  • Medium CVE: EEF-[CVE redacted] (rebar.lock)
  • Outdated: hackney

New (37)

  • Edited copies of one member (3 members, 9+ corresponding lines) (examples/agent_host/src/agent_host.erl)
  • Edited copy of a member (10 corresponding lines) (src/barrel_mcp_session.erl)
  • Edited copy of a member (11 corresponding lines) (src/barrel_mcp_jsonschema.erl)
  • Edited copy of a member (12 corresponding lines) (src/barrel_mcp_client_http.erl)
  • Edited copy of a member (12 corresponding lines) (src/barrel_mcp_stdio.erl)
  • Edited copy of a member (13 corresponding lines) (src/barrel_mcp.erl)
  • Edited copy of a member (13 corresponding lines) (src/barrel_mcp_client_auth_oauth.erl)
  • Edited copy of a member (13 corresponding lines) (src/barrel_mcp_elicitation.erl)
  • Edited copy of a member (13 corresponding lines) (src/barrel_mcp_protocol.erl)
  • Edited copy of a member (13 corresponding lines) (src/barrel_mcp_tool_format.erl)
  • Edited copy of a member (15 corresponding lines) (src/barrel_mcp_client.erl)
  • Edited copy of a member (15 corresponding lines) (src/barrel_mcp_jsonschema.erl)
  • Edited copy of a member (16 corresponding lines) (src/barrel_mcp_jsonschema.erl)
  • Edited copy of a member (18 corresponding lines) (src/barrel_mcp_client_auth_oauth.erl)
  • Edited copy of a member (20 corresponding lines) (examples/echo_client/src/echo_client.erl)
  • Edited copy of a member (22 corresponding lines) (src/barrel_mcp_auth.erl)
  • Edited copy of a member (26 corresponding lines) (src/barrel_mcp_auth_apikey.erl)
  • Edited copy of a member (28 corresponding lines) (src/barrel_mcp_http.erl)
  • Edited copy of a member (3 corresponding lines) (src/barrel_mcp_auth_apikey.erl)
  • Edited copy of a member (3 corresponding lines) (src/barrel_mcp_client_http.erl)
  • …and 17 more

Changes since last survey

  • 25 commits — 21 feature/other, 4 fixes

By area

  • (repo) — 13 commits
  • (root) — 10 commits
  • test/barrel_mcp_client_egress_tests.erl — 1 commit
  • test/conformance — 1 commit

Notable commits

  • fix: Merge pull request #90 from barrel-platform/fix/oauth-ssrf
  • fix: Merge pull request #91 from barrel-platform/fix/cleartext-auth
  • fix: Merge pull request #93 from barrel-platform/fix/conformance-patch-esm
  • fix: Merge remote-tracking branch 'origin/main' into fix/cleartext-auth
  • change: Accept either refusal for encoded loopback hosts
  • change: Adopt the erlang_quic agent, security and contributing policy
  • change: Bump h1 to 0.10.0, h2 to 0.15.1 and hackney to 4.10.1
  • change: Bump h1 to 0.11.0, h2 to 0.17.0 and hackney to 4.11.1
  • change: Bump hackney to 4.10.2 and webtransport to 0.5.5
  • change: Give the conformance runner patch its own require
  • change: Merge pull request #88 from barrel-platform/bump-deps-2
  • change: Merge pull request #89 from barrel-platform/docs/agent-policy
  • change: Merge pull request #92 from barrel-platform/release-4.5.0
  • change: Merge pull request #94 from barrel-platform/chore/sdk-tier-readiness
  • change: Merge pull request #95 from barrel-platform/test/conformance-sdk-runner
  • change: Merge pull request #96 from barrel-platform/bump-deps-3
  • change: Merge pull request #97 from barrel-platform/release-4.5.1
  • change: Merge remote-tracking branch 'origin/main' into chore/sdk-tier-readiness
  • change: Merge remote-tracking branch 'origin/main' into docs/agent-policy
  • change: Publish conformance results and the SDK tier policies
  • …and 5 more

Written by cca.canine.dev from the codebase's own history, inside the signed delivery this page is composed from.

Survey your own repository

barrel-platform/barrel_mcp was measured the same way every project in this corpus was: the same rubric, at a pinned commit, with the result published in full. Point a surveyor at a repository you know and see whether you agree with it.

About this page

  • The score is its most recent published measurement, taken on 15 November 2026 at a pinned commit. It is not a live figure and does not change until the project is measured again.
  • Measured at commit 2a9fcef6d4db659f5977aa3690498031d88b4983 — the exact code this score is about.
  • Scored under rubric-2026.11.4 — the same rubric and the same method as every other entry in this index.
  • Measured by Canine Code Analyzer (cca.canine.dev) using cca measure-2026.11.65+preprod-3c33c1882dc1.