In GraphQL type definitions, each field can take zero or more arguments. Every argument passed to a field needs to have a name and a type. Next to this, it’s also possible to specify default values for arguments.
For example, let’s create a query in our schema that returns all products for a category, if no category is specified we want to return ‘Beverages’:
But how can you achieve this using GraphQL DotNet using the GraphType first approach?