{"name":"@apollo/subgraph","version":"2.4.0-alpha.0","keywords":["graphql","federation","apollo","subgraph"],"author":{"name":"Apollo","email":"packages@apollographql.com"},"license":"MIT","_id":"@apollo/subgraph@2.4.0-alpha.0","maintainers":[{"name":"apollo-bot","email":"npm@apollographql.com"}],"homepage":"https://github.com/apollographql/federation#readme","bugs":{"url":"https://github.com/apollographql/federation/issues"},"dist":{"shasum":"9dc56b994044f5de723dc310ad1c05c60a97c972","tarball":"http://registry-npm.ywwl.com/@apollo/subgraph/download/@apollo/subgraph-2.4.0-alpha.0.tgz","fileCount":69,"integrity":"sha512-Q/w3TMLrxg8np05r8xyBohhvfez7IaRZNPOO+MDVm4IRjbKlSPuUuIWo01LlzCxwvcz+2QHcxGkUsUVsUDHzZw==","signatures":[{"sig":"MEYCIQDqRciX7wdcOWHRnA4goCtcS6M6Zqm8ZdmUGPl+tWfoiQIhAK2PVKzGra61c3F0wuVFQnY81ATd57GCAxD7aIDj9xjO","keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA"}],"unpackedSize":210042,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v4.10.10\r\nComment: https://openpgpjs.org\r\n\r\nwsFzBAEBCAAGBQJkC5GGACEJED1NWxICdlZqFiEECWMYAoorWMhJKdjhPU1b\r\nEgJ2VmoCqxAAmkQnth0BZkLJAPfl9kyDVOO7747nT7rQAurJtJ6E0+C66nWA\r\nSaHO4O62KO4hz7XUNyt9r6j4pVztJcL1cfA5Mcf8XYmOCd/qTYoSX+K4O7zz\r\n1+MoT8QwOnOWoi+lvKM2JkPkrkPqQASfZC8SIgDaglHTf57K5mTcMt2jQO8J\r\nS9lQ2hOhbqZ2Dhb3+r6h4401xhRIIf9lcYIgjKcoaCGHnFZaEHDzriNNwXwn\r\ny/31oizm4DzAecbT6iVb8sxpfQqfQlPtNcnoAP0HbjM/ja8/aV2yC7310MFS\r\n8dFyZXulf309Pz2xcUNjlpLZzh0Tg+PLLoJKc5c0Bsns+kjSjsf0Hkq9PlZO\r\np6pNwrcv34Klc4fJHvvGy3wJmUJJlHp4eenNB6r/5OLFQ17Z9Mle37lag5uh\r\nDIL+iZkH+M0PedAnh8UVPZBQd/0XSlopslLK9/3eCrXvSk7MEYjMKTmy6fh2\r\nOHUxgr3S1ejGMWTkItdHn4t3vyjDqDhA+lEhkjRDR/yPKKfSlIDatgLMH9BR\r\nPm2BrTygqgocUL1h/hydxQ/L/dEuch6eym3Mj6PSKpbs6aOldojwiEALM2Hi\r\nXTK6o2tT4wgJngBLjpA85cTUy6WhXRohT3tRbvJF/w2T+N+Ykw6HmBM0edEN\r\noVTYAOQDmFk4QgNoh2621CjtvmTDs65/MJc=\r\n=QRJF\r\n-----END PGP SIGNATURE-----\r\n","size":50988,"noattachment":false,"key":"/@apollo/subgraph/-/@apollo/subgraph-2.4.0-alpha.0.tgz"},"main":"dist/index.js","types":"dist/index.d.ts","readme":"# `Apollo Subgraph`\n\nThis package provides utilities for creating GraphQL microservices, which can be combined into a single endpoint through tools like [Apollo Gateway](https://github.com/apollographql/federation/tree/main/gateway-js).\n\nFor complete documentation, see the [Apollo Subgraph API reference](https://www.apollographql.com/docs/federation/subgraphs/).\n\n## Usage\n\n```js\nimport { ApolloServer } from '@apollo/server';\nimport { startStandaloneServer } from '@apollo/server/standalone';\nimport { gql } from 'graphql-tag';\nimport { buildSubgraphSchema } from '@apollo/subgraph';\n\nconst typeDefs = gql`\n  type Query {\n    me: User\n  }\n\n  type User @key(fields: \"id\") {\n    id: ID!\n    username: String\n  }\n`;\n\nconst resolvers = {\n  Query: {\n    me() {\n      return { id: \"1\", username: \"@ava\" }\n    }\n  },\n  User: {\n    __resolveReference(user, { fetchUserById }){\n      return fetchUserById(user.id)\n    }\n  }\n};\n\nconst server = new ApolloServer({\n  schema: buildSubgraphSchema([{ typeDefs, resolvers }])\n});\n\n// Note the top-level await!\nconst { url } = await startStandaloneServer(server);\nconsole.log(`🚀  Server ready at ${url}`);\n```\n","engines":{"node":">=14.15.0"},"gitHead":"3f2045f1423669c07e7b71d27fc6de1e78d3f8c3","_npmUser":{"name":"apollo-bot","email":"npm@apollographql.com"},"repository":{"url":"git+https://github.com/apollographql/federation.git","type":"git","directory":"subgraph-js/"},"_npmVersion":"8.19.3","description":"Apollo Subgraph Utilities","directories":{},"_nodeVersion":"16.19.1","dependencies":{"@apollo/cache-control-types":"^1.0.2","@apollo/federation-internals":"2.4.0-alpha.0"},"publishConfig":{"access":"public"},"_hasShrinkwrap":false,"readmeFilename":"README.md","peerDependencies":{"graphql":"^16.5.0"},"_npmOperationalInternal":{"tmp":"tmp/subgraph_2.4.0-alpha.0_1678479750166_0.43654884161139074","host":"s3://npm-registry-packages"},"publish_time":1678479750396,"_cnpm_publish_time":1678479750396,"dist-tags":{"alpha":"2.10.0-alpha.4","beta":"2.9.0-beta.0","connectors":"2.9.0-connectors.9","latest":"2.10.0","latest-1":"0.6.1","next":"2.11.0-preview.0","preview":"2.11.0-preview.0","testing":"2.7.4-testing.1"}}