Allow the request data to be filtered. Previously this filter was only applied to non-HTTP requests. Since 0.2.0, we will apply it to all requests.
This is a great place to hook if you are interested in implementing persisted queries (and ends up being a bit more flexible than graphql-php’s built-in persistentQueryLoader).
apply_filters( 'graphql_request_data', array $data, array $request_context );
- $data (array): An array containing the pieces of the data of the GraphQL request
- $request_context (array): An array containing the both body and query params