[{"data":1,"prerenderedAt":-1},["ShallowReactive",2],{"skill:01M6F37PKT42FD4SJVD0C5D46V":3,"skill-same:01M6F37PKT42FD4SJVD0C5D46V":73},{"skillNo":4,"name":5,"nameZh":6,"description":7,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":16,"categories":17,"keywords":18,"publishedAt":39,"linkOnly":40,"markdownContent":41,"markdownBody":42,"frontMatter":43,"refName":50,"commitSha":51,"skillDirectory":52,"forksCount":53,"repositoryHtmlUrl":54,"repositoryHomepageUrl":55,"ownerHtmlUrl":56,"ownerBlogUrl":6,"ownerDescription":57,"updatedAt":58,"install":59,"resources":72},"01M6F37PKT42FD4SJVD0C5D46V","apollo-server",null,"Guide for building GraphQL servers with Apollo Server 5.x. Use this skill when: (1) setting up a new Apollo Server project, (2) writing resolvers or defining GraphQL schemas, (3) implementing authentication or authorization, (4) creating plugins or custom data sources, (5) troubleshooting Apollo Server errors or performance issues.","ComeOnOliver\u002Fskillshub","ComeOnOliver","https:\u002F\u002Favatars.githubusercontent.com\u002Fu\u002F43215937?v=4","01M6E5JNFECJAAVFE0W7SMWWD2","Haoran Shu","01M6E5JNNDQS7AJZDYFQ8TPZCK",67,"MIT","https:\u002F\u002Fgithub.com\u002FComeOnOliver\u002Fskillshub\u002Fblob\u002Fmain\u002Fskills\u002Fapollographql\u002Fskills\u002Fapollo-server\u002FSKILL.md",[],[19,20,21,22,23,24,25,26,27,28,29,30,31,32,33,34,35,36,37,38],"apollo server","server","apollo","write","fastify","sources","express","project","up","guide","edit","writing","read","node","Bash","data","issues","authentication","performance","typescript","2026-11-10 10:12:30",false,"---\nname: apollo-server\ndescription: >\n  Guide for building GraphQL servers with Apollo Server 5.x. Use this skill when:\n  (1) setting up a new Apollo Server project,\n  (2) writing resolvers or defining GraphQL schemas,\n  (3) implementing authentication or authorization,\n  (4) creating plugins or custom data sources,\n  (5) troubleshooting Apollo Server errors or performance issues.\nlicense: MIT\ncompatibility: Node.js v20+, TypeScript 4.7+. Works with Express v4\u002Fv5, standalone, Fastify, and serverless.\nmetadata:\n  author: apollographql\n  version: \"1.0.0\"\nallowed-tools: Bash(npm:*) Bash(npx:*) Bash(node:*) Read Write Edit Glob Grep\n---\n\n# Apollo Server 5.x Guide\n\nApollo Server is an open-source GraphQL server that works with any GraphQL schema. Apollo Server 5 is framework-agnostic and runs standalone or integrates with Express, Fastify, and serverless environments.\n\n## Quick Start\n\n### Step 1: Install\n\n```bash\nnpm install @apollo\u002Fserver graphql\n```\n\nFor Express integration:\n\n```bash\nnpm install @apollo\u002Fserver @as-integrations\u002Fexpress5 express graphql cors\n```\n\n### Step 2: Define Schema\n\n```typescript\nconst typeDefs = `#graphql\n  type Book {\n    title: String\n    author: String\n  }\n\n  type Query {\n    books: [Book]\n  }\n`;\n```\n\n### Step 3: Write Resolvers\n\n```typescript\nconst resolvers = {\n  Query: {\n    books: () => [\n      { title: \"The Great Gatsby\", author: \"F. Scott Fitzgerald\" },\n      { title: \"1984\", author: \"George Orwell\" },\n    ],\n  },\n};\n```\n\n### Step 4: Start Server\n\n**Standalone (Recommended for prototyping):**\n\nThe standalone server is great for prototyping, but for production services, we recommend integrating Apollo Server with a more fully-featured web framework such as Express, Koa, or Fastify. Swapping from the standalone server to a web framework later is straightforward.\n\n```typescript\nimport { ApolloServer } from \"@apollo\u002Fserver\";\nimport { startStandaloneServer } from \"@apollo\u002Fserver\u002Fstandalone\";\n\nconst server = new ApolloServer({ typeDefs, resolvers });\n\nconst { url } = await startStandaloneServer(server, {\n  listen: { port: 4000 },\n});\n\nconsole.log(`Server ready at ${url}`);\n```\n\n**Express:**\n\n```typescript\nimport { ApolloServer } from \"@apollo\u002Fserver\";\nimport { expressMiddleware } from \"@as-integrations\u002Fexpress5\";\nimport { ApolloServerPluginDrainHttpServer } from \"@apollo\u002Fserver\u002Fplugin\u002FdrainHttpServer\";\nimport express from \"express\";\nimport http from \"http\";\nimport cors from \"cors\";\n\nconst app = express();\nconst httpServer = http.createServer(app);\n\nconst server = new ApolloServer({\n  typeDefs,\n  resolvers,\n  plugins: [ApolloServerPluginDrainHttpServer({ httpServer })],\n});\n\nawait server.start();\n\napp.use(\n  \"\u002Fgraphql\",\n  cors(),\n  express.json(),\n  expressMiddleware(server, {\n    context: async ({ req }) => ({ token: req.headers.authorization }),\n  }),\n);\n\nawait new Promise\u003Cvoid>((resolve) => httpServer.listen({ port: 4000 }, resolve));\nconsole.log(\"Server ready at http:\u002F\u002Flocalhost:4000\u002Fgraphql\");\n```\n\n## Schema Definition\n\n### Scalar Types\n\n- `Int` - 32-bit integer\n- `Float` - Double-precision floating-point\n- `String` - UTF-8 string\n- `Boolean` - true\u002Ffalse\n- `ID` - Unique identifier (serialized as String)\n\n### Type Definitions\n\n```graphql\ntype User {\n  id: ID!\n  name: String!\n  email: String\n  posts: [Post!]!\n}\n\ntype Post {\n  id: ID!\n  title: String!\n  content: String\n  author: User!\n}\n\ninput CreatePostInput {\n  title: String!\n  content: String\n}\n\ntype Query {\n  user(id: ID!): User\n  users: [User!]!\n}\n\ntype Mutation {\n  createPost(input: CreatePostInput!): Post!\n}\n```\n\n### Enums and Interfaces\n\n```graphql\nenum Status {\n  DRAFT\n  PUBLISHED\n  ARCHIVED\n}\n\ninterface Node {\n  id: ID!\n}\n\ntype Article implements Node {\n  id: ID!\n  title: String!\n}\n```\n\n## Resolvers Overview\n\nResolvers follow the signature: `(parent, args, contextValue, info)`\n\n- **parent**: Result from parent resolver (root resolvers receive undefined)\n- **args**: Arguments passed to the field\n- **contextValue**: Shared context object (auth, dataSources, etc.)\n- **info**: Field-specific info and schema details (rarely used)\n\n```typescript\nconst resolvers = {\n  Query: {\n    user: async (_, { id }, { dataSources }) => {\n      return dataSources.usersAPI.getUser(id);\n    },\n  },\n  User: {\n    posts: async (parent, _, { dataSources }) => {\n      return dataSources.postsAPI.getPostsByAuthor(parent.id);\n    },\n  },\n  Mutation: {\n    createPost: async (_, { input }, { dataSources, user }) => {\n      if (!user) throw new GraphQLError(\"Not authenticated\");\n      return dataSources.postsAPI.create({ ...input, authorId: user.id });\n    },\n  },\n};\n```\n\n## Context Setup\n\nContext is created per-request and passed to all resolvers.\n\n```typescript\ninterface MyContext {\n  token?: string;\n  user?: User;\n  dataSources: {\n    usersAPI: UsersDataSource;\n    postsAPI: PostsDataSource;\n  };\n}\n\nconst server = new ApolloServer\u003CMyContext>({\n  typeDefs,\n  resolvers,\n});\n\n\u002F\u002F Standalone\nconst { url } = await startStandaloneServer(server, {\n  context: async ({ req }) => ({\n    token: req.headers.authorization || \"\",\n    user: await getUser(req.headers.authorization || \"\"),\n    dataSources: {\n      usersAPI: new UsersDataSource(),\n      postsAPI: new PostsDataSource(),\n    },\n  }),\n});\n\n\u002F\u002F Express middleware\nexpressMiddleware(server, {\n  context: async ({ req, res }) => ({\n    token: req.headers.authorization,\n    user: await getUser(req.headers.authorization),\n    dataSources: {\n      usersAPI: new UsersDataSource(),\n      postsAPI: new PostsDataSource(),\n    },\n  }),\n});\n```\n\n## Reference Files\n\nDetailed documentation for specific topics:\n\n- [Resolvers](references\u002Fresolvers.md) - Resolver patterns and best practices\n- [Context and Auth](references\u002Fcontext-and-auth.md) - Authentication and authorization\n- [Plugins](references\u002Fplugins.md) - Server and request lifecycle hooks\n- [Data Sources](references\u002Fdata-sources.md) - RESTDataSource and DataLoader\n- [Error Handling](references\u002Ferror-handling.md) - GraphQLError and error formatting\n- [Troubleshooting](references\u002Ftroubleshooting.md) - Common issues and solutions\n\n## Key Rules\n\n### Schema Design\n\n- Use **!** (non-null) for fields that always have values\n- Prefer input types for mutations over inline arguments\n- Use interfaces for polymorphic types\n- Keep schema descriptions for documentation\n\n### Resolver Best Practices\n\n- Keep resolvers thin - delegate to services\u002Fdata sources\n- Always handle errors explicitly\n- Use DataLoader for batching related queries\n- Return partial data when possible (GraphQL's strength)\n\n### Performance\n\n- Use `@defer` and `@stream` for large responses\n- Implement DataLoader to solve N+1 queries\n- Consider persisted queries for production\n- Use caching headers and CDN where appropriate\n\n## Ground Rules\n\n- ALWAYS use Apollo Server 5.x patterns (not v4 or earlier)\n- ALWAYS type your context with TypeScript generics\n- ALWAYS use `GraphQLError` from `graphql` package for errors\n- NEVER expose stack traces in production errors\n- PREFER `startStandaloneServer` for prototyping only\n- USE an integration with a server framework like Express, Koa, Fastify, Next, etc. for production apps\n- IMPLEMENT authentication in context, authorization in resolvers\n\n","# Apollo Server 5.x Guide\n\nApollo Server is an open-source GraphQL server that works with any GraphQL schema. Apollo Server 5 is framework-agnostic and runs standalone or integrates with Express, Fastify, and serverless environments.\n\n## Quick Start\n\n### Step 1: Install\n\n```bash\nnpm install @apollo\u002Fserver graphql\n```\n\nFor Express integration:\n\n```bash\nnpm install @apollo\u002Fserver @as-integrations\u002Fexpress5 express graphql cors\n```\n\n### Step 2: Define Schema\n\n```typescript\nconst typeDefs = `#graphql\n  type Book {\n    title: String\n    author: String\n  }\n\n  type Query {\n    books: [Book]\n  }\n`;\n```\n\n### Step 3: Write Resolvers\n\n```typescript\nconst resolvers = {\n  Query: {\n    books: () => [\n      { title: \"The Great Gatsby\", author: \"F. Scott Fitzgerald\" },\n      { title: \"1984\", author: \"George Orwell\" },\n    ],\n  },\n};\n```\n\n### Step 4: Start Server\n\n**Standalone (Recommended for prototyping):**\n\nThe standalone server is great for prototyping, but for production services, we recommend integrating Apollo Server with a more fully-featured web framework such as Express, Koa, or Fastify. Swapping from the standalone server to a web framework later is straightforward.\n\n```typescript\nimport { ApolloServer } from \"@apollo\u002Fserver\";\nimport { startStandaloneServer } from \"@apollo\u002Fserver\u002Fstandalone\";\n\nconst server = new ApolloServer({ typeDefs, resolvers });\n\nconst { url } = await startStandaloneServer(server, {\n  listen: { port: 4000 },\n});\n\nconsole.log(`Server ready at ${url}`);\n```\n\n**Express:**\n\n```typescript\nimport { ApolloServer } from \"@apollo\u002Fserver\";\nimport { expressMiddleware } from \"@as-integrations\u002Fexpress5\";\nimport { ApolloServerPluginDrainHttpServer } from \"@apollo\u002Fserver\u002Fplugin\u002FdrainHttpServer\";\nimport express from \"express\";\nimport http from \"http\";\nimport cors from \"cors\";\n\nconst app = express();\nconst httpServer = http.createServer(app);\n\nconst server = new ApolloServer({\n  typeDefs,\n  resolvers,\n  plugins: [ApolloServerPluginDrainHttpServer({ httpServer })],\n});\n\nawait server.start();\n\napp.use(\n  \"\u002Fgraphql\",\n  cors(),\n  express.json(),\n  expressMiddleware(server, {\n    context: async ({ req }) => ({ token: req.headers.authorization }),\n  }),\n);\n\nawait new Promise\u003Cvoid>((resolve) => httpServer.listen({ port: 4000 }, resolve));\nconsole.log(\"Server ready at http:\u002F\u002Flocalhost:4000\u002Fgraphql\");\n```\n\n## Schema Definition\n\n### Scalar Types\n\n- `Int` - 32-bit integer\n- `Float` - Double-precision floating-point\n- `String` - UTF-8 string\n- `Boolean` - true\u002Ffalse\n- `ID` - Unique identifier (serialized as String)\n\n### Type Definitions\n\n```graphql\ntype User {\n  id: ID!\n  name: String!\n  email: String\n  posts: [Post!]!\n}\n\ntype Post {\n  id: ID!\n  title: String!\n  content: String\n  author: User!\n}\n\ninput CreatePostInput {\n  title: String!\n  content: String\n}\n\ntype Query {\n  user(id: ID!): User\n  users: [User!]!\n}\n\ntype Mutation {\n  createPost(input: CreatePostInput!): Post!\n}\n```\n\n### Enums and Interfaces\n\n```graphql\nenum Status {\n  DRAFT\n  PUBLISHED\n  ARCHIVED\n}\n\ninterface Node {\n  id: ID!\n}\n\ntype Article implements Node {\n  id: ID!\n  title: String!\n}\n```\n\n## Resolvers Overview\n\nResolvers follow the signature: `(parent, args, contextValue, info)`\n\n- **parent**: Result from parent resolver (root resolvers receive undefined)\n- **args**: Arguments passed to the field\n- **contextValue**: Shared context object (auth, dataSources, etc.)\n- **info**: Field-specific info and schema details (rarely used)\n\n```typescript\nconst resolvers = {\n  Query: {\n    user: async (_, { id }, { dataSources }) => {\n      return dataSources.usersAPI.getUser(id);\n    },\n  },\n  User: {\n    posts: async (parent, _, { dataSources }) => {\n      return dataSources.postsAPI.getPostsByAuthor(parent.id);\n    },\n  },\n  Mutation: {\n    createPost: async (_, { input }, { dataSources, user }) => {\n      if (!user) throw new GraphQLError(\"Not authenticated\");\n      return dataSources.postsAPI.create({ ...input, authorId: user.id });\n    },\n  },\n};\n```\n\n## Context Setup\n\nContext is created per-request and passed to all resolvers.\n\n```typescript\ninterface MyContext {\n  token?: string;\n  user?: User;\n  dataSources: {\n    usersAPI: UsersDataSource;\n    postsAPI: PostsDataSource;\n  };\n}\n\nconst server = new ApolloServer\u003CMyContext>({\n  typeDefs,\n  resolvers,\n});\n\n\u002F\u002F Standalone\nconst { url } = await startStandaloneServer(server, {\n  context: async ({ req }) => ({\n    token: req.headers.authorization || \"\",\n    user: await getUser(req.headers.authorization || \"\"),\n    dataSources: {\n      usersAPI: new UsersDataSource(),\n      postsAPI: new PostsDataSource(),\n    },\n  }),\n});\n\n\u002F\u002F Express middleware\nexpressMiddleware(server, {\n  context: async ({ req, res }) => ({\n    token: req.headers.authorization,\n    user: await getUser(req.headers.authorization),\n    dataSources: {\n      usersAPI: new UsersDataSource(),\n      postsAPI: new PostsDataSource(),\n    },\n  }),\n});\n```\n\n## Reference Files\n\nDetailed documentation for specific topics:\n\n- [Resolvers](references\u002Fresolvers.md) - Resolver patterns and best practices\n- [Context and Auth](references\u002Fcontext-and-auth.md) - Authentication and authorization\n- [Plugins](references\u002Fplugins.md) - Server and request lifecycle hooks\n- [Data Sources](references\u002Fdata-sources.md) - RESTDataSource and DataLoader\n- [Error Handling](references\u002Ferror-handling.md) - GraphQLError and error formatting\n- [Troubleshooting](references\u002Ftroubleshooting.md) - Common issues and solutions\n\n## Key Rules\n\n### Schema Design\n\n- Use **!** (non-null) for fields that always have values\n- Prefer input types for mutations over inline arguments\n- Use interfaces for polymorphic types\n- Keep schema descriptions for documentation\n\n### Resolver Best Practices\n\n- Keep resolvers thin - delegate to services\u002Fdata sources\n- Always handle errors explicitly\n- Use DataLoader for batching related queries\n- Return partial data when possible (GraphQL's strength)\n\n### Performance\n\n- Use `@defer` and `@stream` for large responses\n- Implement DataLoader to solve N+1 queries\n- Consider persisted queries for production\n- Use caching headers and CDN where appropriate\n\n## Ground Rules\n\n- ALWAYS use Apollo Server 5.x patterns (not v4 or earlier)\n- ALWAYS type your context with TypeScript generics\n- ALWAYS use `GraphQLError` from `graphql` package for errors\n- NEVER expose stack traces in production errors\n- PREFER `startStandaloneServer` for prototyping only\n- USE an integration with a server framework like Express, Koa, Fastify, Next, etc. for production apps\n- IMPLEMENT authentication in context, authorization in resolvers\n\n",{"name":5,"license":15,"metadata":44,"description":47,"allowed-tools":48,"compatibility":49},{"author":45,"version":46},"apollographql","1.0.0","Guide for building GraphQL servers with Apollo Server 5.x. Use this skill when: (1) setting up a new Apollo Server project, (2) writing resolvers or defining GraphQL schemas, (3) implementing authentication or authorization, (4) creating plugins or custom data sources, (5) troubleshooting Apollo Server errors or performance issues.\n","Bash(npm:*) Bash(npx:*) Bash(node:*) Read Write Edit Glob Grep","Node.js v20+, TypeScript 4.7+. Works with Express v4\u002Fv5, standalone, Fastify, and serverless.","main","def8531e65114c0fca8fb8551c1871ee0eed705c","skills\u002Fapollographql\u002Fskills\u002Fapollo-server",24,"https:\u002F\u002Fgithub.com\u002FComeOnOliver\u002Fskillshub","https:\u002F\u002Fskillshub.wtf","https:\u002F\u002Fgithub.com\u002FComeOnOliver","AI & Blockchain Engineer\r\n","2026-06-24 22:07:19",{"source":8,"skillName":5,"commands":60,"prompt":70,"zipAvailable":71},[61,64,67],{"tool":62,"command":63},"npx","npx skills add ComeOnOliver\u002Fskillshub --skill apollo-server",{"tool":65,"command":66},"bunx","bunx skills add ComeOnOliver\u002Fskillshub --skill apollo-server",{"tool":68,"command":69},"pnpm","pnpm dlx skills add ComeOnOliver\u002Fskillshub --skill apollo-server","安装技能，技能地址：https:\u002F\u002Fgithub.com\u002FComeOnOliver\u002Fskillshub\u002Fblob\u002Fmain\u002Fskills\u002Fapollographql\u002Fskills\u002Fapollo-server\u002FSKILL.md",true,[],[74,83,92,101,107,113],{"skillNo":75,"name":76,"nameZh":6,"description":6,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":77,"categories":78,"keywords":79,"publishedAt":39},"01M6FKJN13GMG4KY57J3QD8GY5","model-hierarchy-skill","https:\u002F\u002Fgithub.com\u002FComeOnOliver\u002Fskillshub\u002Fblob\u002Fmain\u002Fskills\u002Fzscole\u002Fmodel-hierarchy-skill\u002Fmodel-hierarchy-skill\u002FSKILL.md",[],[80,81,82],"model","model hierarchy","model hierarchy skill",{"skillNo":84,"name":85,"nameZh":6,"description":6,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":86,"categories":87,"keywords":88,"publishedAt":39},"01M6FKJJJ6GCAMR4PPPRD12M5X","zoom-mcp","https:\u002F\u002Fgithub.com\u002FComeOnOliver\u002Fskillshub\u002Fblob\u002Fmain\u002Fskills\u002Fzoom\u002Fskills\u002Fzoom-mcp\u002FSKILL.md",[],[89,90,91],"MCP","zoom","zoom mcp",{"skillNo":93,"name":94,"nameZh":6,"description":6,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":95,"categories":96,"keywords":97,"publishedAt":39},"01M6FKJE3KYT3KPEZMEEHYKA6K","zoom-apps-sdk","https:\u002F\u002Fgithub.com\u002FComeOnOliver\u002Fskillshub\u002Fblob\u002Fmain\u002Fskills\u002Fzoom\u002Fskills\u002Fzoom-apps-sdk\u002FSKILL.md",[],[98,99,100,90],"sdk","zoom apps sdk","apps",{"skillNo":102,"name":103,"nameZh":6,"description":6,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":104,"categories":105,"keywords":106,"publishedAt":39},"01M6FKJ9EDH9Q5VWDF8HAJRSP0","windows","https:\u002F\u002Fgithub.com\u002FComeOnOliver\u002Fskillshub\u002Fblob\u002Fmain\u002Fskills\u002Fzoom\u002Fskills\u002Fwindows\u002FSKILL.md",[],[103],{"skillNo":108,"name":109,"nameZh":6,"description":6,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":110,"categories":111,"keywords":112,"publishedAt":39},"01M6FKJ666BEEFC3AE9GJ72Q93","whiteboard","https:\u002F\u002Fgithub.com\u002FComeOnOliver\u002Fskillshub\u002Fblob\u002Fmain\u002Fskills\u002Fzoom\u002Fskills\u002Fwhiteboard\u002FSKILL.md",[],[109],{"skillNo":114,"name":115,"nameZh":6,"description":6,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":116,"categories":117,"keywords":118,"publishedAt":39},"01M6FKJ21WFCDGTJQ2Q91T9DVW","websockets","https:\u002F\u002Fgithub.com\u002FComeOnOliver\u002Fskillshub\u002Fblob\u002Fmain\u002Fskills\u002Fzoom\u002Fskills\u002Fwebsockets\u002FSKILL.md",[],[115]]