{"name":"apollo-server-koa","version":"3.0.0-alpha.3","description":"Production-ready Node.js GraphQL server for Koa","main":"dist/index.js","types":"dist/index.d.ts","repository":{"type":"git","url":"git+https://github.com/apollographql/apollo-server.git","directory":"packages/apollo-server-koa"},"keywords":["GraphQL","Apollo","Server","Koa","Javascript"],"author":{"name":"Apollo","email":"opensource@apollographql.com"},"license":"MIT","bugs":{"url":"https://github.com/apollographql/apollo-server/issues"},"homepage":"https://github.com/apollographql/apollo-server#readme","engines":{"node":">=12.0 <15.0"},"dependencies":{"@apollographql/graphql-playground-html":"1.6.26","@koa/cors":"^3.1.0","@types/accepts":"^1.3.5","@types/cors":"^2.8.7","@types/koa":"^2.11.3","@types/koa-bodyparser":"^4.3.0","@types/koa-compose":"^3.2.5","@types/koa__cors":"^3.0.1","accepts":"^1.3.7","apollo-server-core":"^3.0.0-alpha.3","apollo-server-types":"^0.300.0-alpha.3","koa":"2.13.0","koa-bodyparser":"^4.3.0","koa-compose":"^4.1.0"},"devDependencies":{"apollo-server-integration-testsuite":"^3.0.0-alpha.3"},"peerDependencies":{"graphql":"^15.3.0"},"gitHead":"15b90eec22523e32e00d97a51b28cbfba3f39c78","readme":"[![npm version](https://badge.fury.io/js/apollo-server-koa.svg)](https://badge.fury.io/js/apollo-server-koa) [![Build Status](https://circleci.com/gh/apollographql/apollo-server.svg?style=svg)](https://circleci.com/gh/apollographql/apollo-server) [![Join the community on Spectrum](https://withspectrum.github.io/badge/badge.svg)](https://spectrum.chat/apollo)\n\n\nThis is the Koa integration of GraphQL Server. Apollo Server is a community-maintained open-source GraphQL server that works with many Node.js HTTP server frameworks. [Read the docs](https://www.apollographql.com/docs/apollo-server/). [Read the CHANGELOG.](https://github.com/apollographql/apollo-server/blob/main/CHANGELOG.md)\n\n```shell\nnpm install apollo-server-koa graphql\n```\n\n## Koa\n\n```js\nconst Koa = require('koa');\nconst { ApolloServer, gql } = require('apollo-server-koa');\n\n// Construct a schema, using GraphQL schema language\nconst typeDefs = gql`\n  type Query {\n    hello: String\n  }\n`;\n\n// Provide resolver functions for your schema fields\nconst resolvers = {\n  Query: {\n    hello: () => 'Hello world!',\n  },\n};\n\nconst server = new ApolloServer({ typeDefs, resolvers });\n\nconst app = new Koa();\nserver.applyMiddleware({ app });\n// alternatively you can get a composed middleware from the apollo server\n// app.use(server.getMiddleware());\n\napp.listen({ port: 4000 }, () =>\n  console.log(`🚀 Server ready at http://localhost:4000${server.graphqlPath}`),\n);\n```\n\n## Principles\n\nGraphQL Server is built with the following principles in mind:\n\n- **By the community, for the community**: GraphQL Server's development is driven by the needs of developers\n- **Simplicity**: by keeping things simple, GraphQL Server is easier to use, easier to contribute to, and more secure\n- **Performance**: GraphQL Server is well-tested and production-ready - no modifications needed\n\nAnyone is welcome to contribute to GraphQL Server, just read [CONTRIBUTING.md](https://github.com/apollographql/apollo-server/blob/main/CONTRIBUTING.md), take a look at the [roadmap](https://github.com/apollographql/apollo-server/blob/main/ROADMAP.md) and make your first PR!\n","readmeFilename":"README.md","_id":"apollo-server-koa@3.0.0-alpha.3","_nodeVersion":"10.22.0","_npmVersion":"lerna/3.22.1/node@v10.22.0+x64 (linux)","dist":{"integrity":"sha512-72gXuGMDhAz4d6jwj3r7V1wVS/oW85/E4E1ohL2HjhGAV291znJp8tqU9fzpkvIw7HquUuBxaKKTvxHKu9z3KA==","shasum":"e9dca142b50e700f02335521fb42689e100bde0b","tarball":"http://registry-npm.ywwl.com/apollo-server-koa/download/apollo-server-koa-3.0.0-alpha.3.tgz","fileCount":22,"unpackedSize":51590,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.4\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJfNB/BCRA9TVsSAnZWagAAVxIP/1GevdwWgco2KgVPAmwl\nwRlW7T9DfNqyRO4Gg/ifA+WeieuR/JHnPEp0DF6EeRmEiWZG1fyA8FxB+Kg2\nMFV8YPEafoYYJBOVyrCObEzfR6IRn+/3jPKP179qKyGCHUaoSzv44vowKy1b\n34Zy/k6hdnApq+Kx/w0F7XodN3AjkEshFucYbIdE5l3D4xC4NbrKPRuTfFFJ\nqQBn64103y+vf7LFJG4GHDzLcTFSM4wtISQdMm4A3Abcw6jCCYzJz183jARw\noTVnWyzN0lOFPp0E/2ZhHMMfCbWsDlvVADfeXtNK84ibd44XdW9wARf7er1s\n6pAHHV8ce2ISjf4G1r9SW2hk4Y6QbR/szRPGOvlO1HOolzeMMr2K6qKZOw8f\nly27RYPq3jFoSKVbtCGGNjuADDSUdfusBmCNOxf5V37xZpLbBbVnpYH9k5Jo\nkSV0+MU4CdCGG+xJTTZ8yufZ9cSe1K4NM8Z5maXcQ25z9xikH8ksPHkIlwo9\nCmOlPE900J9pzJ8X+suHxj5benI9MD/rZ6PSArFhEvu8rnDtlRIQP4vPQzR8\nxuPy5XIwbCP1XsCZ7UyXkltAaoXRO5g/ivYSh87bnDbalyxAiCzKHHhjkLvQ\n/jcpT2QR822jpOMaXD0UQs/eqAl+KoAuPozQcNYNyj6WeW7C0fhVrLvG8KyV\ni2ke\r\n=1ATx\r\n-----END PGP SIGNATURE-----\r\n","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEQCIBGBzs1lH2M3Ky9FWfUHFTT7yh6FwP3f+XPNZuwMRmM+AiB04HCg2iBuEV6ExJrbP0e4at9gfDrnkn8FKmjq3oUIRQ=="}],"size":12422,"noattachment":false,"key":"/apollo-server-koa/-/apollo-server-koa-3.0.0-alpha.3.tgz"},"maintainers":[{"email":"npm@apollographql.com","name":"apollo-bot"},{"email":"evanshauser@gmail.com","name":"evanshauser"}],"_npmUser":{"name":"apollo-bot","email":"npm@apollographql.com"},"directories":{},"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/apollo-server-koa_3.0.0-alpha.3_1597251521064_0.8465652395909544"},"_hasShrinkwrap":false,"deprecated":"The `apollo-server-koa` package is part of Apollo Server v2 and v3, which are now end-of-life (as of October 22nd 2023 and October 22nd 2024, respectively). This package's functionality is now found in the `@apollo/server` package. See https://www.apollographql.com/docs/apollo-server/previous-versions/ for more details.","publish_time":1597251521164,"_cnpm_publish_time":1597251521164,"dist-tags":{"alpha":"3.6.0-alpha.1","alphalambda":"3.0.0-lambda.0","html":"3.0.0-html.2","latest":"3.13.0","next":"3.2.0","next-v3":"3.0.0-alpha.3","preview":"3.0.0-preview.4","rc":"3.0.0-rc.1","unified":"2.23.1-unified2.3","v2":"2.26.2"}}