We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
GraphQL allows you to alias, or rename, elements of your queries. This is built-in and trivial, but a powerful feature that is often overlooked.
alias
To alias, simply prefix the elements you wish to rename with the desired string followed by :, like so:
:
{ imaginarium:places( id:"UGxhY2VUeXBlOjUxOA==, UGxhY2VUeXBlOjU0Nw==") { menagerie:edges { dogs:node { dogtag:id place:name favoritePizzaPlace:name } } } }
Which results in:
{ "data": { "imaginarium": { "menagerie": [ { "dogs": { "dogtag": "UGxhY2VUeXBlOjUxOA==", "place": "Dallas, Dallas, Texas, United States", "favoritePizzaPlace": "Dallas, Dallas, Texas, United States" } } ] } } }