{"name":"@envelop/disable-introspection","version":"4.0.6-alpha-20230217204304-88b8c61d","sideEffects":false,"peerDependencies":{"@envelop/core":"3.0.6-alpha-20230217204304-88b8c61d","graphql":"^14.0.0 || ^15.0.0 || ^16.0.0"},"dependencies":{"tslib":"^2.5.0"},"repository":{"type":"git","url":"git+https://github.com/n1ru4l/envelop.git","directory":"packages/plugins/disable-introspection"},"author":{"name":"Dotan Simha","email":"dotansimha@gmail.com"},"license":"MIT","main":"cjs/index.js","module":"esm/index.js","typings":"typings/index.d.ts","typescript":{"definition":"typings/index.d.ts"},"type":"module","exports":{".":{"require":{"types":"./typings/index.d.cts","default":"./cjs/index.js"},"import":{"types":"./typings/index.d.ts","default":"./esm/index.js"},"default":{"types":"./typings/index.d.ts","default":"./esm/index.js"}},"./*":{"require":{"types":"./typings/*.d.cts","default":"./cjs/*.js"},"import":{"types":"./typings/*.d.ts","default":"./esm/*.js"},"default":{"types":"./typings/*.d.ts","default":"./esm/*.js"}},"./package.json":"./package.json"},"readme":"## `@envelop/disable-introspection`\n\nThis plugin injects the `NoSchemaIntrospectionCustomRule` validation rule exported from the `graphql` module to the validation phase for disabling introspection.\n\n## Getting Started\n\n```\nyarn add @envelop/disable-introspection\n```\n\n## Usage Example\n\n```ts\nimport { parse, validate, specifiedRules, execute, subscribe } from 'graphql'\nimport { envelop, useEngine } from '@envelop/core'\nimport { useDisableIntrospection } from '@envelop/disable-introspection'\n\nconst getEnveloped = envelop({\n  plugins: [useEngine({ parse, validate, specifiedRules, execute, subscribe }), useDisableIntrospection()]\n})\n```\n\n## Optional configuration\n\nThe plugin optionally accepts a configuration object:\n\n```\n{\n  disableIf?: ({context, params}) => boolean\n}\n```\n\n- `disableIf`: A function that allow you to evaluate the need to disable introspection, based on the incoming operation. If introspection needs to be disabled/enabled based on the dynamic parameter (GraphQL operation, or, incoming request/headers), use this function to determine when introspection needs to be disabled. Return true for disabling the introspection for the incoming operation, or false to allow introspection.\n","readmeFilename":"README.md","gitHead":"88b8c61d4541908bc2f259241e1d6e8bcc7e7fae","description":"This plugin injects the `NoSchemaIntrospectionCustomRule` validation rule exported from the `graphql` module to the validation phase for disabling introspection.","bugs":{"url":"https://github.com/n1ru4l/envelop/issues"},"homepage":"https://github.com/n1ru4l/envelop#readme","_id":"@envelop/disable-introspection@4.0.6-alpha-20230217204304-88b8c61d","_nodeVersion":"18.14.0","_npmVersion":"9.3.1","dist":{"integrity":"sha512-e0LuGmHT5UN2KyeopzQ5dgMrbVxDiG7hu3Xdxf7oNymtxm/xJDy99aXSToHvBAEioskRQ0huhkgqIOVYtxfUPw==","shasum":"68058b7fefeab7a7cdc3ee28ce33b547f45452bd","tarball":"http://registry-npm.ywwl.com/@envelop/disable-introspection/download/@envelop/disable-introspection-4.0.6-alpha-20230217204304-88b8c61d.tgz","fileCount":7,"unpackedSize":4610,"signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEQCIGLMKYakAY6ABNC6YwqNbX7P7I+Ubn93CULK4zjkUhpaAiButNCjYgUrWzXVz5eTwMvv7vmuh3Po72tu1AdrfcoQSw=="}],"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v4.10.10\r\nComment: https://openpgpjs.org\r\n\r\nwsFzBAEBCAAGBQJj7+b/ACEJED1NWxICdlZqFiEECWMYAoorWMhJKdjhPU1b\r\nEgJ2VmqkEw/+PNq4a1BqFMe4om6eqzWfStTEvpVZ+p7g1Wp0nkG4pXajcq/u\r\nz/kplMjD0WCOPofHvQ+VxKX5z5gFODh6knyql0mt1vSSffX7LDXe+GE/8om0\r\nIc+be6HGG0K+rZEIg93nLvkp6QFOr30L0e1aly0WUWEQFgXnu8Fif9lhYoeX\r\nzIpA3ea47K5FztAKWEbm2aOKIrxcyqaxwP6PV1KR/LcGfKNuH+Rp4XhX0wk1\r\n2K94FPJrFjhKdIpCndUd3oQyE95bSek6o7ayE0is+rShVj/SFUCGAbJN9yF8\r\npTapBW6xwkdRW2zV22TD+FK4hsuHLpipt9tF73816ILX9Bm+HT9strJGLoLj\r\nKJ90l5cR15MtebvRqakbOjL+8DVpvPGznQSPJkmIykqRuZCZLMzjYQ8K7iXu\r\nHuzBsf/rO+Gz6yl6lYbF6ZiShC8Us1Ml2ZX9Uu6Q72CT8CTBBpeBNOeHf7Ui\r\njA9Rw9+uEl4UG5bwJcDXkupwBej43muUuvELy7Ok/x5LHEhL8Z5Bq6udCtMy\r\nz6YUYPuRjpX2e+ip7IpUHE0wwZ1uwtTHKfVJDMh9cet3nubGZLj033RSJ9ZA\r\nXohxUuuKfFvrUX/L9E1W95UO+8LU05D2BeDveAqMCfWbQOkJpBLxaR6Yv+6N\r\nKX9RQAcx2BbsjFhyB9O6gVJtOnszRL+2kAQ=\r\n=zMZa\r\n-----END PGP SIGNATURE-----\r\n","size":1565,"noattachment":false,"key":"/@envelop/disable-introspection/-/@envelop/disable-introspection-4.0.6-alpha-20230217204304-88b8c61d.tgz"},"_npmUser":{"name":"dotansimha","email":"dotansimha@gmail.com"},"directories":{},"maintainers":[{"name":"dotansimha","email":"dotansimha@gmail.com"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/disable-introspection_4.0.6-alpha-20230217204304-88b8c61d_1676666622755_0.6786103698776409"},"_hasShrinkwrap":false,"publish_time":1676666623044,"_cnpm_publish_time":1676666623044,"dist-tags":{"alpha":"10.0.0-alpha-20261019231601-b21e6cedc1a444383d9ce69fe6180f5b4ff67120","latest":"10.0.0","rc":"10.0.0-rc-20261022165416-7c29decb398764e6ac3915e1c539c478cbf19237"}}