Configure Defaults

The defaultConfig field is mandatory and allows you to configure the default options for all Operations. In this example, we're disabling authentication for all Operations, setting our API to be public by default.

1
2
3
4
5
6
7
8
9
10
11
12
13
// wundergraph.operations.ts
import { configureWunderGraphOperations } from '@wundergraph/sdk';
import type { OperationsConfiguration } from './generated/wundergraph.operations';
export default configureWunderGraphOperations<OperationsConfiguration>({
operations: {
defaultConfig: {
authentication: {
required: false,
},
},
},
});
Previous
Overview

Was this article helpful to you?
Provide feedback

Edit this page