graphql

graphql is a skill for Claude Code, Codex from nimadorostkar/Claude-Skills-collection. It costs 33 tokens per session (959 once invoked), scanned A, original, MIT.

A way to design APIs where clients ask for exactly the data they need from a typed schema. It also covers the code that fetches each field and splitting one API across several services.

In plain words
What is it for?
Use it to design schemas, improve resolver performance with batching, limit query cost, handle partial failures, and compose schemas across services.
Why use it?
It helps avoid slow requests, repeated database lookups, uncontrolled expensive queries, and unclear errors in GraphQL APIs.

Skill for Claude CodeCodex

Written for no agent in particular: nothing here depends on one.

Good fit Use it to design schemas, improve resolver performance with batching, limit query cost, handle partial failures, and compose schemas across services.

Compare 6 skills from other repositories ↓
Install with agentmods
npx agentmods add skills/nimadorostkar/claude-skills-collection/graphql
Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

Any agent
npx skills add nimadorostkar/Claude-Skills-collection --skill graphql
Clone the repo
git clone --depth 1 https://github.com/nimadorostkar/Claude-Skills-collection

Made for: Claude Code, Codex.

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

README.md
[![agentmods](https://agentmods.dev/badge/skills/nimadorostkar/claude-skills-collection/graphql/github.svg)](https://agentmods.dev/skills/nimadorostkar/claude-skills-collection/graphql)
Your own site
<a href="https://agentmods.dev/skills/nimadorostkar/claude-skills-collection/graphql"><img src="https://agentmods.dev/badge/skills/nimadorostkar/claude-skills-collection/graphql/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

Your own site · 80×15
<a href="https://agentmods.dev/skills/nimadorostkar/claude-skills-collection/graphql"><img src="https://agentmods.dev/badge/skills/nimadorostkar/claude-skills-collection/graphql.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 33 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 959 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. A grade says what 26 rules found in the file — not that it is safe. Third-party audits
  • NVIDIA SkillSpector pass 7 Sept 2026
How audits are shown
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.00033 $0.00959
Opus 5 $0.00016 $0.00479
Sonnet 5 $0.00007 $0.00192
Haiku 4.5 $0.00003 $0.00096

Measured 11d ago against content hash 33b4366e7db9, method: parsed. Prices are Anthropic first-party input rates as of 2026-09-11, from the pricing page.

Security

Grade A, and why

graphql 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 11d 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.

skills/backend/graphql/SKILL.md · 101 lines

How it starts

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

GraphQL

Purpose

Design a GraphQL schema that models the domain rather than the database, and operate it without letting a single query take down the service.

When to Use

  • Designing a GraphQL schema from scratch.
  • Diagnosing slow queries or N+1 resolver behavior.
  • Protecting a public GraphQL endpoint from expensive queries.
  • Splitting a schema across services with federation.

Capabilities

  • Schema design: types, interfaces, unions, connections, nullability.
  • Resolver architecture and DataLoader batching.
  • Query cost analysis, depth limiting, and persisted queries.
  • Error handling that distinguishes partial failures from total ones.
  • Federation and schema composition.

Inputs

  • The domain model and the client's actual query patterns.
  • The data sources behind each field.
  • Whether the endpoint is public (untrusted queries) or internal.

Outputs

  • A schema with deliberate nullability and stable field names.
  • Resolvers that batch, with no N+1 on any documented query.
  • Cost limits and a persisted-query allow-list for public endpoints.

Workflow

  1. Design for the client, not the tables — The schema is a product surface. If it mirrors your database, you have built a slower REST API with worse caching.
  2. Get nullability right early — A nullable field is a permanent client burden; a non-null field that later fails takes down the whole parent object. Non-null for genuine invariants only.
  3. Batch every relation — Every resolver that fetches by id gets a DataLoader. Without one, orders { customer { name } } issues one query per order.
  4. Bound the cost — Depth limit, complexity limit, and pagination caps. Then persisted queries for first-party clients.
  5. Model errors explicitly — Expected failures (validation, not found) belong in the schema as union results; unexpected failures go to errors.

Best Practices

  • Never expose an unbounded list field. Use the Connection pattern with a first/after cap.
  • DataLoader instances are per-request. A shared loader is a cache-poisoning bug across users.
  • Changing a field from nullable to non-null is a breaking change for clients that handle null; the reverse is breaking for clients that do not. Get it right before launch.
  • Do not version a GraphQL schema. Add fields, deprecate old ones with @deprecated(reason:), and remove them once usage reaches zero.
  • Instrument per-field resolver latency. The slow field is never the one you would guess.
  • Introspection on a public production endpoint is a reconnaissance gift. Disable it or restrict it.

Read the full file on GitHub · 101 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. 11d ago First seen · 101 lines · 33 tokens per session scan A 33b4366e7db9

Subscribe to this mod's changes

graphql is a skill published in the GitHub repository nimadorostkar/Claude-Skills-collection (26 stars, last pushed 24d ago), licensed MIT. It adds 33 tokens to every session and 959 once invoked, about $0.0002 per session on Opus 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-30.

Related

Other skills, from other repositories