Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

ID type missing in 8.2 Syntax #28

Closed
clentfort opened this issue Jul 6, 2015 · 2 comments
Closed

ID type missing in 8.2 Syntax #28

clentfort opened this issue Jul 6, 2015 · 2 comments

Comments

@clentfort
Copy link
Contributor

While the document explicitly mentions the inbuilt type ID ([Section 3.1.1.1.5](From the description in [Section 3.1.1.1.5]%28http://facebook.github.io/graphql/#sec-Values%29) it is not to be found in the the list of possible types a field can have (Section 8.2.4). This leaves the ID type without a specific definition! Should its value be a Name or a StringValue?

@leebyron
Copy link
Collaborator

leebyron commented Jul 6, 2015

See "input coercion" in http://facebook.github.io/graphql/#sec-ID

When expected as an input type, any string (such as "4") or integer (such as 4) input value should be coerced to ID as appropriate for the ID formats a given GraphQL server expects. Any other input value, including float input values (such as 4.0), must raise a query error indicating an incorrect type.

So StringValue or IntValue, but not Name

@leebyron leebyron closed this as completed Jul 6, 2015
@leebyron
Copy link
Collaborator

leebyron commented Jul 6, 2015

Great feedback on this being not as clear as it could be, though

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants