/api-graphql:api-graphqlfrom api-graphql
Designs and reviews public GraphQL APIs that third-party developers query. Use when deciding whether GraphQL fits, writing or reviewing a schema (naming, nullability, Node IDs, input and payload types, Relay connections, result-union errors), setting depth and cost limits, exposing a federated graph, or planning field deprecation.
Ships in api-graphql. Installing the plugin adds it to Claude Code.
What the skill costs in Claude's context, stage by stage
Name and description: Claude knows it exists.
SKILL.md joins the conversation and stays.
Read when SKILL.md points to them.
Design for strangers. A third party writes queries you have never seen, so schema conventions, ceilings, and the trust boundary matter more than they do for your own apps.
Not for gqlgen or other server code (golang), REST contracts and rate-limit headers (api-rest-design), or gRPC (api-grpc). Each named skill applies if installed.
For a public API the default is REST. Choose GraphQL only when a trigger holds, and say which one.
REST gets URL-keyed HTTP caching, a fixed endpoint list to learn, and the widest tooling for free. GraphQL needs those rebuilt. Offering both is a valid result. If no trigger holds, stop and use api-rest-design, if installed.
If first-party and third-party clients share the endpoint, design for the third party. A surface safe for strangers serves your own apps, and the reverse is false.
Write the conventions down once and lint against them. Consistency matters more than the particular choice.
is/has/can on booleans.publishPost, cancelOrder), not one updateOrder that edits any field. Pick verb-first (createUser) or noun-first (userCreate) and use it everywhere.[Type!]! for lists, so a caller gets an empty list and never a null list or null item. Make a field non-null only where the domain guarantees it. Per the spec, a null in a non-null field propagates to the nearest nullable parent, so reflexive non-null spreads damage. Keep mutation payload fields nullable enough to carry a partial failure.interface Node { id: ID! } with node(id: ID!): Node on entities (the Global Object Identification pattern). The pattern doesn't require opaque IDs, but make them opaque anyway so clients don't parse them. Share one identifier with the REST surface when both exist.author: User!), not foreign keys (authorId). Put the key on the object's own id only.Viewer and TeamMember can share name and still evolve apart.Read references/schema-and-results.md for the casing table, the mutation argument shape, and SDL for connections and result unions.
Paginate every list a third party can grow. A bare list can't gain pagination later without a breaking change.
edges, node, cursor, pageInfo, first and after). Cursors stay stable under concurrent writes and stay fast at depth. Treat cursors as opaque.nodes list with endCursor is a documented shortcut used by large public APIs, but it is not in the Relay spec. Take it only when no per-edge data will ever exist, and return a wrapper object so promotion to a full connection stays additive.first to a documented maximum. The schema can't express the bound.totalCount that forces an expensive count.GraphQL has two channels, and each error type has one right home.
errors array (with partial data) carries what a caller can't plan around: server faults, malformed or invalid requests, authentication.union CreateOrderResult = CreateOrderSuccess | ValidationError | InsufficientInventory. The schema then documents every outcome and a client can't skip a case. Adding a member to a shipped union is a dangerous change, since clients with exhaustive handling can break, so list the likely outcomes early.errors array alone suits only a first-party surface where you control every client.ErrorCode enum under either posture so clients switch on stable codes while message text can change.A public graph lets strangers compose arbitrary queries, so decide the acceptable shape before any metering exists.
Federation is internal composition, not public exposure. Make the router the only publicly reachable component, and keep every subgraph on a private network.
Query._service { sdl } returns the subgraph's full schema, and the spec says it is for the router's use only. Query._entities resolves @key entities by representation. Turning off introspection doesn't remove either field, because composition needs them.@inaccessible to keep internal fields out of the composed public schema.GraphQL evolves one live schema with field-level @deprecated. Shape types so they can grow: payload objects can gain fields, while a bare scalar return can't. A result union can gain members only as a dangerous change that clients must be ready for. A date-versioned GraphQL API is also legitimate, so record the chosen stance in the API's versioning policy. Deprecation still costs integrators work, so don't treat it as free.
Read references/evolution.md when deciding whether a schema change is breaking, deprecating or removing a field, or writing the GraphQL evolution policy.
For a design, give one section per step above: the gate verdict and which trigger fired, the convention set, the pagination choice per list, the error posture with its result unions, each ceiling with its value and rejection error, the federation boundary with the probe result, and the persisted-query policy per traffic class. For a review of an existing schema, report each hit as the anti-pattern, the SDL location, and the convention it breaks.
spec.graphql.org (September 2025 edition lists the response format, @deprecated, introspection, and non-null propagation), relay.dev/graphql/connections.htm, graphql.org/learn (global object identification, pagination, response, security), and Apollo Federation's subgraph specification.
What SKILL.md sets; muted values are Claude Code's defaults
Other plugins' skills for the same job
npx claudepluginhub adminhead/claude-plugins --plugin api-graphql