Skip to content

Latest commit

 

History

History
19 lines (15 loc) · 562 Bytes

faq.md

File metadata and controls

19 lines (15 loc) · 562 Bytes

FAQ

This page answers common asked questions about Mercurius.

Disable Graphql instrospection

To disable Graphql instrospection you can use NoSchemaIntrospectionCustomRule from graphql, we have an example on "example/disable-instrospection.js", using this approach:

import { NoSchemaIntrospectionCustomRule } from 'graphql';

app.register(mercurius, {
  context: buildContext,
  gateway: {
    services: [....],
    pollingInterval: 30000,
  },
  validationRules: process.env.NODE_ENV === 'production' && [NoSchemaIntrospectionCustomRule],
});