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

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

Open
nad182 opened this issue Jan 27, 2025 · 0 comments
Open

Comments

@nad182
Copy link

nad182 commented Jan 27, 2025

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:
query MyQuery {
  allPlanets {
    edges {
      cursor
      node {
        climates
        created
        diameter
        edited
        name
      }
    }
  }
}
  1. Observe that most of the fields return as null
{
  "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"
          }
        },
...
...
    ]
  }
}
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

1 participant