graphql-client
graphql-client copied to clipboard
How to handle Graphql responses in a different format rather than "data"
from what I see the client expects that the graphql response from the server has a "data" property with the result, what if our API response with a custom format like this, how I can customize it so the Serialization, bc right now I got null in the response.data obj.
This is our graphql response format
{ "StatusCode": "Success", "ServerName": "NAME", "ClientIP": "SOME IP", "ExecutionTime": "00:00:00.3523738", "Result": { "entities": [ { "Id": 34, "type": "ResultType", "level": "High" } ] } }
https://spec.graphql.org/October2021/#sec-Data