Closed bdaniel7 closed 2 years ago
Yes! See the docs here
In your case, it would be
"errorType": {
"CustomErrorType": {
"message": "string"
"path": "string list"
"extensions": "dictionary<string, string>"
}
}
As for locations
, there isn't a generic way to describe such type (list of other complex objects) but it should be doable to add if you REALLY need it
I believe this is resolved as well? I'll close the issue, please re-open if the problem persists
For now I removed the custom errorType definition.
@bdaniel7 Didn't the proposed solution work for you?
Hmm, I see now that it does fill the error object:
{ message =
"Cannot query field "updateTimestamps" on type "Vessel". Did you mean "updateTimestamp"?"
path = null
extensions = seq [[code, GRAPHQL_VALIDATION_FAILED]] }
Ok, I will use the custom error object as you recommended, thank you.
Is there a way to configure the errorType to be a more complex object? Like an array/list of error objects.