{"name":"@apollo/subgraph","version":"0.3.0","keywords":["graphql","federation","apollo","subgraph"],"author":{"name":"Apollo","email":"packages@apollographql.com"},"license":"MIT","_id":"@apollo/subgraph@0.3.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":"08c189b9050e99507923d2dd4f0acc0b0f6532c6","tarball":"http://registry-npm.ywwl.com/@apollo/subgraph/download/@apollo/subgraph-0.3.0.tgz","fileCount":68,"integrity":"sha512-CS+NnzR9GqS0CaDo61Bh8bKNsmdgYQjPnV8a5TTVb60kp9fZW8r+TMMDmlAHs9aVl9/JZGbXgxrted/MX6Ctfg==","signatures":[{"sig":"MEUCIH7q3QozjR77V50qaMPiqZOUFfMsgJVPkNI/F0XAXslYAiEA7BRs1OdA8Im/QTtgxf1xgZtQxRdKTK6NPfTRo53/4h8=","keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA"}],"unpackedSize":218269,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.13\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJiAuwdCRA9TVsSAnZWagAA2wcP/ReyjupLO/ukZIG8+QtA\n1tentPbMFkUQIBmoib7C2EcIrJVtqWUsSj6wiplS28m06x9kMvg5KB+7DUYK\nEcrrxbsrCdRxHwOZnxDZHTGx3CLpguP5m6MiOrSnuzSEf2YAQlRUeqKNmEMe\nbas7hBJDCv4HKGkdK+xjGLOiQS9UQ6NIwmDpZPuzuNZpxWFePWkDd59ucGMV\nozS92NhfRoTmS+zpATjM+rjAgeD4BIIFG+ZVLeTjv8cyVH6pVSiN6ahwKFT8\nEQuEdP0tLBhdL4qKXcsucOE8sFdDDy3ZSnYyeFCH2McI1jlRMkL5kQa5H/EC\n5TL4IPjsCRoBv8M0kFBFokdap6+IgtgYbmF+ZSrwCBVlDEcwnvGtnzC/OtGB\n5RsFUIVfm5qmeboLFyhXvVdOQ1vbZ/nO3zJqDiuP1wjBxAIdT74TNqzbXh4/\nL3j28uWws8YH/KrxADMj4zk85/iFXYdm+mbem7rDXPsuopuXGWnbRXSL2J0r\nYY+/Ob7Fmr1/tiRXCM1nYvxduok6qAs8srDo7MxzwtoHb563JRbAjBZzxw+Q\nzoko0AC+d3S4k9s/hGf6TGXY1ofuTq7VgnblXV/DGS9NYeqkfFCE0HWKHxRf\n7GTNb9mv6AYu3oOxFX02SbFr2fvbD170GjribpAmr8QilNEYa6T1wPQbmCXF\nFIW8\r\n=+ILQ\r\n-----END PGP SIGNATURE-----\r\n","size":60895,"noattachment":false,"key":"/@apollo/subgraph/-/@apollo/subgraph-0.3.0.tgz"},"main":"dist/index.js","types":"dist/index.d.ts","engines":{"node":">=12.13.0 <17.0"},"gitHead":"87449e166586c8277d28391f50dcede4da79603e","_npmUser":{"name":"apollo-bot","email":"npm@apollographql.com"},"deprecated":"All v0.x versions of @apollo/subgraph are now deprecated with an end-of-life date of September 22, 2023. Apollo recommends upgrading to v2.x as soon as possible. For more details, see our announcement blog post (https://www.apollographql.com/blog/announcement/backend/announcing-the-end-of-life-schedule-for-apollo-gateway-v0-x/) and documentation (https://www.apollographql.com/docs/federation/federation-2/backward-compatibility/#is-official-support-ending-for-apollogateway-v0x).","repository":{"url":"git+https://github.com/apollographql/federation.git","type":"git","directory":"subgraph-js/"},"_npmVersion":"lerna/4.0.0/node@v12.22.7+x64 (linux)","description":"Apollo Subgraph Utilities","directories":{},"_nodeVersion":"12.22.7","publishConfig":{"access":"public"},"_hasShrinkwrap":false,"peerDependencies":{"graphql":"^15.8.0 || ^16.0.0"},"_npmOperationalInternal":{"tmp":"tmp/subgraph_0.3.0_1644358685492_0.4522688957910801","host":"s3://npm-registry-packages"},"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","publish_time":1644358685648,"_cnpm_publish_time":1644358685648,"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"}}