graphql-mcp: Instructions file for Codex

AGENTS.md

graphql-mcp AGENTS.md is an instructions file for Codex, OpenCode from cubicecho/graphql-mcp. It costs 11,032 tokens per session, scanned A, original, MIT.

Project instructions for a TypeScript package that turns a GraphQL schema into tools an AI assistant can discover and call through the Model Context Protocol (MCP).

In plain words
What is it for?
Use it when developing, testing, formatting, or building the GraphQL-to-MCP server.
Why use it?
It gives coding agents the project context, technology requirements, commands, structure, and testing rules they need before changing the code.

Instructions file for CodexOpenCode

Written for Codex and OpenCode: the file is AGENTS.md. Also seen: mentions AGENTS.md.

This is cubicecho/graphql-mcp's own configuration. It tells Codex and OpenCode how to work on graphql-mcp itself, so it is not a mod to install elsewhere. Copy it as a starting point and replace the rules that are about this project. Everything graphql-mcp configures →

Reuse

Borrowing it

Nothing to install: this file belongs to cubicecho/graphql-mcp. Take a copy, put it at the same path in your own repository, and replace the rules that are about this project with yours.

Copy the file
curl -O https://raw.githubusercontent.com/cubicecho/graphql-mcp/main/AGENTS.md
Clone the repo
git clone --depth 1 https://github.com/cubicecho/graphql-mcp

Made for: Codex, OpenCode.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for graphql-mcp AGENTS.md

README.md
[![agentmods](https://agentmods.dev/badge/instructions/cubicecho/graphql-mcp/agents-md/github.svg)](https://agentmods.dev/instructions/cubicecho/graphql-mcp/agents-md)
Your own site
<a href="https://agentmods.dev/instructions/cubicecho/graphql-mcp/agents-md"><img src="https://agentmods.dev/badge/instructions/cubicecho/graphql-mcp/agents-md/github.svg" alt="Measured on agentmods" height="20"></a>

Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.

agentmods 80×15 button for graphql-mcp AGENTS.md

Your own site · 80×15
<a href="https://agentmods.dev/instructions/cubicecho/graphql-mcp/agents-md"><img src="https://agentmods.dev/badge/instructions/cubicecho/graphql-mcp/agents-md.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 11,032 This file is loaded in full into every session.
When invoked 11,032 The same file — it is already loaded in full.
Security scan A 0 findings. A grade says what 26 rules found in the file — not that it is safe.
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5.1 $0.11032 $0.11032
Opus 5.5 $0.04413 $0.04413
Sonnet 5.5 $0.02206 $0.02206
Haiku 4.5 $0.01103 $0.01103

Measured 29d ago against content hash f5aa3335965b, method: parsed. Prices are Anthropic first-party input rates as of 2026-10-07, from the pricing page.

Security

Grade A, and why

graphql-mcp AGENTS.md scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 29d ago.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

AGENTS.md · 634 lines

How it starts

The opening of the file, as written. The whole thing — 634 lines — stays where its author put it; the contents beside it link to each section on GitHub.

AGENTS.md

Project

@cubicecho/graphql-mcp — middleware that turns a GraphQL schema into a Model Context Protocol server. Each Query/Mutation root field is projected into an MCP tool, described from the SDL (field and argument descriptions, types) so an AI can discover and call your API. It is designed to run side-by-side with your GraphQL server: mount the returned HTTP handler on a route in the same app, or run it as its own process and forward to a remote GraphQL endpoint.

Stack

  • Language: TypeScript 5.7+, strict mode, ESM only, "erasable syntax only" (no enums/namespaces/parameter-properties) so the source runs unbuilt under Node's type stripping.
  • Runtime/build: Source uses .ts import specifiers. Run it directly with node --experimental-strip-types; tsc (with rewriteRelativeImportExtensions) rewrites the specifiers to .js and emits dist/. Requires Node ≥ 22 and TypeScript ≥ 5.7.
  • Tests: Node's built-in test runner (node --test) with type stripping — no test framework dependency. Test files are src/**/*.test.ts.
  • Formatting/linting: Biome (npm run check). Every if/loop body is a braced block (useBlockStatements), and a logic check is negated with === false, not ! (no-negation.grit; ! stays for null guards).
  • File names: kebab-case (zod-schema.ts, event-store.ts). A new module goes in the folder whose phrase below covers it, never in a utils or helpers folder.
  • Comments: every function and method has a TSDoc block: a description of at most four sentences, a blank line, then @param name - … for each parameter (@param [name] - … when optional) and @returns … unless it returns nothing. No {type} annotations. A comment in a function body is at most two lines. Keep the one fact that stops a reader undoing a decision; the longer history goes in this file or the commit message.
  • Dependencies: @graphql-tools/schema (schema merging for the extend option) is the only runtime dependency. @modelcontextprotocol/sdk (>=1.12), graphql (>=16) and zod (^3.25 || ^4.0) are peer deps — zod because the SDK validates against the caller's copy, and a second one in our own tree makes instanceof checks fail across the boundary. Express is not a dependency — the HTTP handler is framework-agnostic. createFetchHandler needs SDK ≥ 1.25 and loads that transport lazily so the floor stays at 1.12 for everyone else.
  • Guiding constraint: avoid adding libraries unless writing it ourselves isn't worth the effort (e.g. the GraphQL→Zod mapping is hand-written). The scalars option is a plain Record<string, AnyZodType> for the same reason — it's structurally identical to what generators emit (e.g. defaultScalarMap from @vantreeseba/graphql-zod), so interop needs no adapter or dependency.

Read the full file on GitHub · 634 lines

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 29d ago Changed · +25 lines · +477 tokens per session f5aa3335965b
  2. 2mo ago Changed · +395 lines · +7,302 tokens per session 8fd50d0f3c41
  3. 2mo ago First seen · 214 lines · 3,253 tokens per session scan A e4a8006fcfa7

Subscribe to this mod's changes

graphql-mcp AGENTS.md is an instructions file published in the GitHub repository cubicecho/graphql-mcp (0 stars, last pushed 29d ago), licensed MIT. It adds 11,032 tokens to every session, about $0.0441 per session on Opus 5.5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-31.

Related

graphql-mcp AGENTS.md compared with instructions from other repositories

graphql-mcp AGENTS.md next to 6 instructions from other repositories
ModTypeStarsLast pushLicenceScanTokensWorks with
graphql-mcp AGENTS.mdcubicecho/graphql-mcpInstructions file029d agoMITA11,032Codex, OpenCode
vscode buildNext.instructions.mdmicrosoft/vscodeInstructions file195kyesterdayMITA9,719GitHub Copilot
next.js AGENTS.mdvercel/next.jsInstructions file143kyesterdayMITA7,461Codex, OpenCode
langchain AGENTS.mdlangchain-ai/langchainInstructions file149kyesterdayMITA4,680Codex, OpenCode
vscode oss-third-party-notices.instructions.mdmicrosoft/vscodeInstructions file195kyesterdayMITA5,516GitHub Copilot
vscode copilot-instructions.mdmicrosoft/vscodeInstructions file195kyesterdayMITA3,093GitHub Copilot
deepseek-harness AGENTS.mddeepseek-ai/deepseek-harnessInstructions file274k2d agoMITA4,313Codex, OpenCode