Skip to Content
Build an MCP

Build an MCP

Build, test, and publish a Cendriix MCP (Modular Capability Provider) — the plugin system that gives agents access to external services.

What is an MCP?

An MCP is a containerised plugin exposing a typed toolset. Each tool has a name, input/output schema, and handler. Agents can only invoke tools in their permitted list.

File layout

my-mcp/ ├── manifest.yaml ├── src/ │ ├── index.ts │ ├── tools/ │ │ ├── listItems.ts │ │ └── createItem.ts │ └── auth.ts ├── Dockerfile └── package.json

Manifest schema

name: my-mcp version: 1.0.0 description: Short description tools: - name: listItems description: List all items input: type: object properties: filter: { type: string } output: type: array - name: createItem description: Create an item input: type: object required: [title] properties: title: { type: string } body: { type: string }

Tool handler interface

interface ToolContext { input: Record<string, unknown>; secrets: Record<string, string>; logger: Logger; runId: string; workspaceId: string; } type ToolHandler = (ctx: ToolContext) => Promise<ToolResult>;

Authentication

Credentials are injected via environment variables at container start:

  • API keyMCP_SECRET_API_KEY
  • OAuthMCP_SECRET_OAUTH_TOKEN (refresh handled by runtime)
  • AWS IAM — assume-role credentials via STS

Packaging and publishing

docker build -t my-mcp:1.0.0 . docker push registry.cendriix.ai/mcps/my-mcp:1.0.0 cendriix mcp publish --manifest manifest.yaml --image registry.cendriix.ai/mcps/my-mcp:1.0.0

See also: Core concepts → MCP, MCP Marketplace, Connectors, Policies

Last updated on