Discrepancy for JSON type between GraphiQL and API #6251
Replies: 5 comments
-
@martmull any idea for a quickfix on this since you've touched the console? Or does that seem like a more complex issue? |
Beta Was this translation helpful? Give feedback.
-
@gitstart-twenty could you please look into this and see if you find a quick fix? Thanks |
Beta Was this translation helpful? Give feedback.
-
Here is the GitStart Ticket for this issue: https://clients.gitstart.com/twenty/5449/tickets/TWNTY-3306 |
Beta Was this translation helpful? Give feedback.
-
Hey @FelixMalfait It appears that GraphiQL has issues validating custom scalars in general and not just JSON. The errors however, do not affect the queries as they still work as expected. Please refer to the issues below for context:
There's also an RFC that proposes attaching a URI to custom scalars to provide a link to the scalar's definition here |
Beta Was this translation helpful? Give feedback.
-
GraphiQL (whether the docs version or the one on api.twenty.com) expects ECMA-404 formatting for JSON fields (i.e. a stringified JSON). But what the API expect is actually normal JSON (non sitringified).
In the screen below, the request was underlined as if it would fail but it turns out this request worked perfectly:
Query:
Variables:
Beta Was this translation helpful? Give feedback.
All reactions