Skip to content

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

Open
@nad182

Description

@nad182

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"
          }
        },
...
...
    ]
  }
}

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions