graphql / graphql/swapi-graphql

The API doesn't work (almost): most of the returned property values are `null`

Open
#241 3 comments 6 reactions 0 assignees View on GitHub
Dominant language
JavaScript
Stars
1.1k
Forks
267
PR merge metrics
No merged PRs in 30d

Description

There must be something wrong with schemas or the way the individual records are fetched.

1. Go to https://swapi-graphql.netlify.app/
2. Try any query, requesting different fields.
Example:
```gql
query MyQuery {
allPlanets {
edges {
cursor
node {
climates
created
diameter
edited
name
}
}
}
}
```
3. Observe that most of the fields return as `null`
```json
{
"data": {
"allPlanets": {
"edges": [
{
"cursor": "YXJyYXljb25uZWN0aW9uOjA=",
"node": {
"climates": null,
"created": null,
"diameter": null,
"edited": null,
"name": "Tatooine"
}
},
{
"cursor": "YXJyYXljb25uZWN0aW9uOjE=",
"node": {
"climates": null,
"created": null,
"diameter": null,
"edited": null,
"name": "Alderaan"
}
},
{
"cursor": "YXJyYXljb25uZWN0aW9uOjI=",
"node": {
"climates": null,
"created": null,
"diameter": null,
"edited": null,
"name": "Yavin IV"
}
},
...
...
]
}
}
```

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.