GraphQL Schema Generator

VerifiedSafe

Generate GraphQL schemas, resolvers, and type definitions. Use when designing GraphQL APIs or documenting schemas.

Sby Skills Guide Bot
DevelopmentIntermediate
8/4/2026
Claude CodeCursorWindsurfCodex
#graphql#schema-generation#api-design#resolvers#code-generation

Recommended for

Automated summary

Generates GraphQL schemas, resolver templates, and type definitions from a data model.

Strengths

  • Produces a consistent schema with types, Query, Mutation, inputs, and custom scalars (full User/Post example)
  • Bundles cursor-based pagination using Connection, Edge, and PageInfo types
  • Ships JavaScript resolver templates with an authentication check on mutations
  • Also covers schema documentation

Limitations

  • Generated resolvers assume existing dataSources and contain no real business logic
  • Examples are JavaScript-only, with no mention of Apollo, GraphQL Yoga, or other languages
  • Error handling is listed as a best practice but barely detailed
When to use it

When you need to bootstrap a GraphQL schema or resolver skeleton from an already defined data model.

When not to use it

When you need production-ready code with validation, fine-grained authorization, or a language other than JavaScript.

Security analysis

Safe
Quality score75/100

The skill contains only static example code for GraphQL schemas and resolvers. It declares no tools and includes no executable commands, network calls, or destructive actions.

No concerns found

How this analysis is made

Examples

Blog schema and resolvers
Generate a GraphQL schema and JavaScript resolver templates for a blog with users, posts, and comments, including cursor-based pagination on the users query.
Modèle de données vers schéma
Voici mon modèle de données Prisma pour une boutique en ligne : génère le schéma GraphQL (types, queries, mutations, inputs) et les résolveurs JavaScript correspondants.
Document existing schema
Read my schema.graphql and generate documentation for each type and query, plus resolver stubs for any fields that need custom logic.

name: graphql-schema-generator description: Generate GraphQL schemas, resolvers, and type definitions. Use when designing GraphQL APIs or documenting GraphQL schemas.

GraphQL Schema Generator Skill

GraphQLスキーマを生成するスキルです。

概要

データモデルからGraphQLスキーマ、リゾルバーを自動生成します。

主な機能

  • スキーマ定義: Type、Query、Mutation
  • リゾルバー生成: 実装テンプレート
  • ベストプラクティス: ページネーション、エラーハンドリング
  • ドキュメント: 自動生成

生成例

Schema

# Types
type User {
  id: ID!
  name: String!
  email: String!
  posts: [Post!]!
  createdAt: DateTime!
}

type Post {
  id: ID!
  title: String!
  content: String!
  author: User!
  published: Boolean!
  createdAt: DateTime!
  updatedAt: DateTime!
}

type Query {
  user(id: ID!): User
  users(first: Int = 10, after: String): UserConnection!
  post(id: ID!): Post
  posts(published: Boolean): [Post!]!
}

type Mutation {
  createUser(input: CreateUserInput!): User!
  updateUser(id: ID!, input: UpdateUserInput!): User!
  deleteUser(id: ID!): Boolean!
  createPost(input: CreatePostInput!): Post!
  publishPost(id: ID!): Post!
}

# Inputs
input CreateUserInput {
  name: String!
  email: String!
  password: String!
}

input UpdateUserInput {
  name: String
  email: String
}

input CreatePostInput {
  title: String!
  content: String!
  authorId: ID!
}

# Pagination
type UserConnection {
  edges: [UserEdge!]!
  pageInfo: PageInfo!
  totalCount: Int!
}

type UserEdge {
  node: User!
  cursor: String!
}

type PageInfo {
  hasNextPage: Boolean!
  hasPreviousPage: Boolean!
  startCursor: String
  endCursor: String
}

# Custom Scalars
scalar DateTime

Resolvers (JavaScript)

const resolvers = {
  Query: {
    user: async (parent, { id }, { dataSources }) => {
      return dataSources.userAPI.getUserById(id);
    },
    users: async (parent, { first, after }, { dataSources }) => {
      return dataSources.userAPI.getUsers({ first, after });
    },
    post: async (parent, { id }, { dataSources }) => {
      return dataSources.postAPI.getPostById(id);
    },
    posts: async (parent, { published }, { dataSources }) => {
      return dataSources.postAPI.getPosts({ published });
    }
  },

  Mutation: {
    createUser: async (parent, { input }, { dataSources }) => {
      return dataSources.userAPI.createUser(input);
    },
    updateUser: async (parent, { id, input }, { dataSources }) => {
      return dataSources.userAPI.updateUser(id, input);
    },
    deleteUser: async (parent, { id }, { dataSources }) => {
      return dataSources.userAPI.deleteUser(id);
    },
    createPost: async (parent, { input }, { dataSources, user }) => {
      if (!user) throw new Error('Unauthorized');
      return dataSources.postAPI.createPost(input);
    },
    publishPost: async (parent, { id }, { dataSources, user }) => {
      if (!user) throw new Error('Unauthorized');
      return dataSources.postAPI.publishPost(id);
    }
  },

  User: {
    posts: async (parent, args, { dataSources }) => {
      return dataSources.postAPI.getPostsByAuthor(parent.id);
    }
  },

  Post: {
    author: async (parent, args, { dataSources }) => {
      return dataSources.userAPI.getUserById(parent.authorId);
    }
  }
};

バージョン情報

  • スキルバージョン: 1.0.0

From the file to a first result

The download contains exactly the content displayed on this page. This copy may differ from the latest version in the source repository.

View the source and supporting files

This download contains SKILL.md only. Any scripts, references, templates and dependencies are not included. Get the required files from the source, preserving their directory structure, before continuing.

1. Download the file

Download SKILL.md

From the root of a test project, save the file as .skill-downloads/graphql-schema-generator-mse7ioo8/SKILL.md, or use the command below. This folder is for inspecting the skill before installation.

Command for macOS/Linux or WSL: requires a POSIX shell and curl. On Windows without WSL, use the download button and create the folder manually.

mkdir -p '.skill-downloads/graphql-schema-generator-mse7ioo8' && curl --fail --show-error --location 'https://skills-guides.com/api/skills/graphql-schema-generator-mse7ioo8/download' --output '.skill-downloads/graphql-schema-generator-mse7ioo8/SKILL.md.part' && mv '.skill-downloads/graphql-schema-generator-mse7ioo8/SKILL.md.part' '.skill-downloads/graphql-schema-generator-mse7ioo8/SKILL.md'

2. Check prerequisites

Read SKILL.md before using it. If it references scripts or external services, inspect them and prepare the required access in your test environment.

No recognized prerequisites section in this file. This does not mean it is self-contained: libraries, tools and access requirements may be mentioned elsewhere in the content or source repository.

The platforms on this page are catalog indications. The paths below follow tool documentation; they do not prove this skill has been run in those tools. No minimum tool version is confirmed for this listing.

3. Load the skill

After inspection, copy the complete folder into your project using one of the commands below, then open a new tool session. The command stops if a folder with the same name already exists: compare the files before replacing it.

Claude Code
test -f '.skill-downloads/graphql-schema-generator-mse7ioo8/SKILL.md' && test -s '.skill-downloads/graphql-schema-generator-mse7ioo8/SKILL.md' && mkdir -p '.claude/skills' && test ! -e '.claude/skills/graphql-schema-generator' && cp -R '.skill-downloads/graphql-schema-generator-mse7ioo8' '.claude/skills/graphql-schema-generator'

Cursor
test -f '.skill-downloads/graphql-schema-generator-mse7ioo8/SKILL.md' && test -s '.skill-downloads/graphql-schema-generator-mse7ioo8/SKILL.md' && mkdir -p '.cursor/skills' && test ! -e '.cursor/skills/graphql-schema-generator' && cp -R '.skill-downloads/graphql-schema-generator-mse7ioo8' '.cursor/skills/graphql-schema-generator'

Codex
test -f '.skill-downloads/graphql-schema-generator-mse7ioo8/SKILL.md' && test -s '.skill-downloads/graphql-schema-generator-mse7ioo8/SKILL.md' && mkdir -p '.agents/skills' && test ! -e '.agents/skills/graphql-schema-generator' && cp -R '.skill-downloads/graphql-schema-generator-mse7ioo8' '.agents/skills/graphql-schema-generator'

OpenSkills

OpenSkills must already be installed. The local install/read procedure is checked with OpenSkills 1.5.0, which requires Node.js ≥ 20.6.0. Catalog slugs are not resolved automatically.

Official OpenSkills installation
openskills install './.skill-downloads/graphql-schema-generator-mse7ioo8'

openskills read 'graphql-schema-generator-mse7ioo8'

Reading should display the installed file content and its base directory. It does not run the skill or install its dependencies.

For an agent that reads AGENTS.md, then sync the index. This command changes AGENTS.md: review the diff before using it.

openskills sync

Manual method or another tool: attach SKILL.md to a conversation, or open it in an agent that can read files. Include any required supporting resources. No universal folder is recognized by every tool.

4. Try a first task

Use a short, synthetic input: an API endpoint, a small document or an interface brief. In a new conversation, attach the file or give the agent its path, then adapt this request:

Read .skill-downloads/graphql-schema-generator-mse7ioo8/SKILL.md and apply its instructions to this example: [describe a test input]. Identify any missing files, dependencies or access. Produce the result requested by the skill without inventing data or running unreviewed scripts.

Expected result: output matching the skill instructions, or a precise list of missing prerequisites. A read confirmation alone does not validate a first use. If an external resource is unavailable, that path remains untested.

Related skills