Extensions to GraphQL

The API Connect DataPower® API Gateway extends the GraphQL specification by providing additional schema directives.

Custom schema directives

@cost
The @cost directive associates weight values with types or fields. Types are used to calculate type cost of a request to the GraphQL API. Fields are used to calculate field cost of a request to the GraphQL API. For more information, see The Cost Directive.
@listSize
The @listSize directive applies slicing arguments to fields. For more information, see The List Size directive.
@remove
The @remove GraphQL schema directive specifies conditions for removing types and fields from validation or introspection for each transaction based on values in the API context. For example, you can prevent specific API plans from using certain types or fields. For more information, see @remove directive.