Sign In

foodblock-mcp

Package Overview
Dependencies
Maintainers
1
Versions
3
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

foodblock-mcp

MCP server for the FoodBlock protocol — food data tools for any AI agent. Works standalone or connected.

latest
Source
npmnpm
Version
0.5.2
Version published
Maintainers
1
Created
Source

FoodBlock MCP Server

Food data tools for any AI agent. Describe food in plain English, get structured data back. Works standalone (zero config, 47 demo blocks) or connected to a live FoodBlock server.

Install

npx foodblock-mcp

No server needed. No database. No config. Just food data tools.

Configure Your AI Tool

Claude Desktop

~/Library/Application Support/Claude/claude_desktop_config.json (macOS) %APPDATA%\Claude\claude_desktop_config.json (Windows)

{
  "mcpServers": {
    "foodblock": {
      "command": "npx",
      "args": ["-y", "foodblock-mcp"]
    }
  }
}

Claude Code

claude mcp add foodblock -- npx -y foodblock-mcp

Cursor

Settings > MCP Servers > Add:

{
  "foodblock": {
    "command": "npx",
    "args": ["-y", "foodblock-mcp"]
  }
}

Windsurf

Settings > MCP:

{
  "mcpServers": {
    "foodblock": {
      "command": "npx",
      "args": ["-y", "foodblock-mcp"]
    }
  }
}

Gemini CLI

{
  "mcpServers": {
    "foodblock": {
      "command": "npx",
      "args": ["-y", "foodblock-mcp"]
    }
  }
}

Connected Mode (your own server)

Set FOODBLOCK_URL to connect to a live FoodBlock server instead of the embedded store:

{
  "mcpServers": {
    "foodblock": {
      "command": "npx",
      "args": ["-y", "foodblock-mcp"],
      "env": {
        "FOODBLOCK_URL": "http://localhost:3111"
      }
    }
  }
}

Tools (17)

ToolDescription
foodblock_fbNatural language entry point — describe food in English, get blocks back
foodblock_infoSystem overview — call this first
foodblock_createCreate a new block
foodblock_updateCreate a new version of an existing block
foodblock_getFetch a block by hash
foodblock_querySearch blocks by type, ref, or heads
foodblock_chainTrace the version history of a block
foodblock_treeBuild the full provenance tree
foodblock_headsList latest versions of all entities
foodblock_tombstoneMark a block for content erasure (GDPR)
foodblock_validateValidate a block against its schema
foodblock_batchCreate multiple blocks in one request
foodblock_create_agentRegister an AI agent identity
foodblock_load_agentRestore a previously created agent
foodblock_agent_draftCreate a draft block as an agent
foodblock_approve_draftApprove an agent's draft
foodblock_list_agentsList all AI agents

How It Works

Standalone:   AI Agent  <--stdio-->  MCP Server [embedded store, 47 blocks]
Connected:    AI Agent  <--stdio-->  MCP Server  <--HTTP-->  FoodBlock API

Standalone mode runs an in-memory FoodBlock store with a complete bakery supply chain demo: farm, mill, bakery, distributor, retailer, certifications, reviews, agent, orders, and more.

Other AI Platforms

ChatGPT / OpenAI

For ChatGPT Custom GPTs, use the OpenAPI spec at openai/openapi.yaml.

For OpenAI API function calling, use the tool definitions at openai/tools.json.

Gemini / Google AI

For Gemini API function calling, use gemini/tools.json.

For Google AI Studio, Vertex AI, and Python SDK usage, see gemini/README.md.

Environment Variables

VariableDefaultDescription
FOODBLOCK_URL(none — standalone)Set to connect to a live FoodBlock API

License

MIT

Keywords

mcp

FAQs

Package last updated on 17 Feb 2026

Related posts