Link to reproduction
No response
Describe the Bug
Currently there is no way to disable GraphQL introspection and I'd rather call it a bug than a feature request as it exposes the complete schema without any restrictions. Ideally I'd even like to apply an access rule e.g. to still fetch it for development of a headless frontend.
To Reproduce
Just enable graphQL and try to retreive the schema with @graphql-codegen/cli
// codegen.ts
// https://the-guild.dev/graphql/codegen/plugins/other/schema-ast
import type { CodegenConfig } from '@graphql-codegen/cli';
const config: CodegenConfig = {
overwrite: true,
generates: {
'./src/types/payloadSchema.graphql': {
schema: 'https://<PAYLOAD_URL>/api/graphql',
plugins: ['schema-ast'],
},
}
};
export default config;
Payload Version
2.0.11
Adapters and Plugins
No response
Link to reproduction
No response
Describe the Bug
Currently there is no way to disable GraphQL introspection and I'd rather call it a bug than a feature request as it exposes the complete schema without any restrictions. Ideally I'd even like to apply an access rule e.g. to still fetch it for development of a headless frontend.
To Reproduce
Just enable graphQL and try to retreive the schema with @graphql-codegen/cli
Payload Version
2.0.11
Adapters and Plugins
No response