Skip to main content
Glama

Agent Context Hub

English | 简体中文

Agent Context Hub is a reusable MCP server for shared, versioned context across AI agents and devices. It is not tied to OpenClaw: Codex, Claude Code, Hermes, Cursor, OpenClaw, and any client that supports Streamable HTTP MCP can connect to the same workspace.

It keeps human-readable Markdown and YAML in a private GitHub workspace repository and exposes a small MCP interface. This public repository contains only server code, tests, documentation, and generic examples.

What it solves

  • Different agents and devices read the same current profile, rules, skills, and project state.

  • GitHub main stays the source of truth instead of chat history or opaque agent memory.

  • Each device has its own token and can be revoked independently.

  • Task closeouts write only allowed project-state files and reject stale concurrent updates.

Related MCP server: Graph

MCP tools

Tool

Purpose

context_routes

Discover projects, aliases, and routes.

context_bootstrap

Load minimal task context and return a workspace revision.

context_query

Search selected workspace scopes with source paths.

context_closeout

Write an evidence-backed closeout to approved files.

Quick start

git clone https://github.com/YOUR_ACCOUNT/agent-context-hub.git
cd agent-context-hub
npm install
npm test

export PERSONAL_CONTEXT_WORKSPACE="$PWD/examples/personal-context-workspace"
npm run dev

The stdio server is ready to add to an MCP client. It does not print normal console output after startup.

Create your private workspace

Copy examples/personal-context-workspace into a new private GitHub repository. Replace the sample profile, rules, projects, and route map with your own information.

Never publish that workspace. Do not put tokens, private keys, passwords, personal documents, or chat transcripts in it.

context-map.yaml is the important control file. It declares exactly which files a route can read and which project files a closeout may write.

common:
  always_read:
    - profile/RESPONSE_PREFERENCES.md
    - rules/EVIDENCE_POLICY.md

routes:
  sample_project_code:
    project_id: sample-project
    aliases: [sample-project, Sample Project]
    task_aliases: [code, fix, review]
    read:
      - projects/sample-project/CURRENT_STATE.yaml
      - projects/sample-project/NEXT_ACTIONS.md
    write:
      - projects/sample-project/CURRENT_STATE.yaml
      - projects/sample-project/NEXT_ACTIONS.md

Remote deployment

For cross-device use, run the HTTP server on one trusted machine or server and connect clients through HTTPS.

The server reads GitHub through a GitHub App installed only on the private workspace repository. The app needs Contents: Read and write only if you enable context_closeout.

cp .env.example .env
# Fill in your own GitHub App and device-token values. Never commit .env.
npm run build
npm run http:start

Task lifecycle

  1. The agent calls context_routes if it does not know the available routes.

  2. The agent calls context_bootstrap before work and saves workspaceRevision.

  3. The agent performs the task.

  4. On completion, pause, or block, it calls context_closeout with that revision, a factual summary, evidence, and next actions.

  5. The server checks the allowlist and concurrency, writes a Git commit, then returns the revision and commit URL.

Agents should not upload full conversations. Only concise, evidence-backed project state belongs in the workspace.

Verify

npm test
npm run typecheck
npm run build

License

MIT

Install Server
A
license - permissive license
A
quality
C
maintenance

Maintenance

Maintainers
Response time
Release cycle
Releases (12mo)
Commit activity

Resources

Unclaimed servers have limited discoverability.

Looking for Admin?

If you are the server author, to access and configure the admin panel.

Related MCP Servers

View all related MCP servers

Related MCP Connectors

  • A MCP server built for developers enabling Git based project management with project and personal…

  • An MCP server that gives your AI access to the source code and docs of all public github repos

  • Personal assistant MCP server with search, execute, packages, jobs, secrets, and integrations.

View all MCP Connectors

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/zyplong/agent-context-hub'

If you have feedback or need assistance with the MCP directory API, please join our Discord server