- Home
- Skills
- APIs & Backend
- GraphQL Schema Stitching Architect
Works with the AI Agents you already use
GraphQL Schema Stitching Architect
Design and compose enterprise GraphQL supergraphs using Apollo Federation v2 and TypeScript resolvers.
$15
GraphQL Schema Stitching Architect
Example session with this skill installed
I need to federate my Product and Review services. The Product service owns the Product entity with an 'id'. The Review service needs to add a 'reviews' field to it.
- Read your context and instructions
- Compiled the graphql schema stitching
I have generated the federated SDL for both subgraphs and the corresponding TypeScript reference resolver for the Review service. This setup uses Apollo Federation v2 directives to allow the Review service to extend the Product entity.
Federated Schema Design
# Product Subgraph
type Product @key(fields: "id") {
id: ID!
name: String!
price: Float!
}
# Review Subgraph
extend type Product @key(fields: "id") {
id: ID! @external
reviews: [Review!]!
}
type Review {
id: ID!
rating: Int!
comment: String!
productId: ID!
}
Entity Resolver (Review Service)
import { Review } from './types';
const resolvers = {
Product: {
reviews: async (parent: { id: string }, context: any) => {
// Implementation using DataLoader to prevent N+1
return await context.loaders.reviewsByProduct.load(parent.id);
}
},
Review: {
__resolveReference: async (reference: { id: string }, context: any) => {
return await context.loaders.reviewById.load(reference.id);
}
}
};
export default resolvers;
Next steps
- Install
@apollo/subgraphin both services to support federation directives. - Run
rover subgraph checkto verify the composition of these two schemas. - Implement the
reviewsByProductDataLoader to batch database calls.
Connects securely to your tools. The creator never sees your data.
About this skill
Managing data across distributed microservices often leads to fragmented APIs and N+1 query performance bottlenecks. This skill provides the architectural logic to merge isolated subgraphs into a unified, performant GraphQL supergraph.
What it does
- Federated design generates subgraph SDL using Apollo Federation v2 directives like
@key,@shareable, and@external. - Entity resolution writes TypeScript resolvers for
__resolveReferenceto link data across service boundaries. - Supergraph composition merges multiple domain schemas into a single gateway schema.
- Performance optimization implements DataLoader patterns to eliminate N+1 query amplification during execution.
How it works
- Define Subgraphs by mapping your domain entities to individual service SDLs with federation directives.
- Configure Entities to allow cross-service lookups using shared keys.
- Draft Resolvers in TypeScript to handle reference resolution for the gateway.
- Compose Supergraph to validate schema compatibility and directive usage.
Frameworks & tools
This skill is built for Apollo Federation v2, GraphQL Schema Stitching, TypeScript, and DataLoader.
Why this beats prompting it yourself
Directives like @requires and @provides are notoriously easy to misconfigure, leading to composition errors. This skill enforces strict Apollo Federation v2 syntax and boilerplate entity resolvers that prevent runtime failures.
Use cases
- Migrating a monolithic GraphQL API to a distributed microservices architecture.
- Linking user profiles in an Auth service to order history in a Commerce service.
- Optimizing gateway performance for nested queries across three or more subgraphs.
- Designing schema extensions where one service adds fields to an entity it does not own.
Known limitations
This skill focuses on SDL and TypeScript resolvers. It does not handle infrastructure concerns like gateway deployment, managed federation cloud setup, or real-time mesh networking.
Find more skills like this on the Claude Skills Marketplace, the Codex Skills Marketplace and the Gemini Skills Marketplace, or browse Claude Skills for APIs & Backend.
Focuses on SDL and TypeScript resolvers. Does not handle gateway deployment, cloud infrastructure, or networking setup.
How to use
- 1
Connect your agent to the Agensi MCP
Copy the prompt and paste it into Claude, ChatGPT, Cursor or any agent that supports MCP. It sets up the connection for you. Manual setup
- 2
Sign in to Agensi
Your agent shows a sign-in link. Sign in and click Allow.
- 3
Ask for what you need
Your agent loads this skill and uses it on your task. It always asks before buying a skill.
Reviews
No reviews yet
Be one of the first to try it. Every listed skill goes through the trust checks below.
Security scanned
Checked by our 8-point scan before listing
Fresh listing
Recently published to Agensi
Money-back guarantee
Doesn't do what its page promises? You get your money back.
Trust & safety
Security scan
Security scan passed 3 days ago
- Software
- Zero global installationorelevated privileges required.
File System Read/Write (strictly scoped to current project workspace `./`).
Permissions
Target Use Cases: - Architect an Apollo Federation v2 supergraph schema. - Stitch GraphQL schemas across distributed services. - Configure entity resolution with @key in GraphQL Federation.