Altair: https://altairgraphql.dev/
- Add the Altair chrome extension.
- Enable the extension and start it.
- Once you are in the Altair client, install altair-graphql-plugin-graphql-explorer. For installation follow the following instructions.
- Go to the settings icon of Altair client.
- Click settings.
- Click
Toggle advanced mode. - Add the below block in already existing configuration file.
The config should now look like"plugin.list": [ "altair-graphql-plugin-graphql-explorer" ]
{ "theme": "system", "language": "en-US", "addQueryDepthLimit": 3, "tabSize": 2, "plugin.list": [ "altair-graphql-plugin-graphql-explorer" ] }- Save the changes.
- Reload the window.
For more information regarding the plugins, you can visit altair plugins.
- Go to the alert-hub-backend repository and download the schema.graphql file.
Note
The schema file might change in the future. Make sure to use the latest one.
- Click
Docsin Altair graphql client.
- Click the options button
...and clickLoad Schema....
- Select and load the downloaded schema file.
Enter one of the following URL to the Enter URL field.
Production URL: (https://alerthub-api.ifrc.org/graphql/)
- Click on the
Docsbutton in the top-rigt corner to open the schema explorer.
-
From the Docs panel, browse and select the query or fragment you want to run.
-
Click on the fields to view their structure and available fields.
-
Click on "Add Fragment" for each field to run its corresponding queries or fragments.
- Replace the default
---with a meaningful query name. - The query name should match what you are executing.
- Replace the default
-
If the query belongs to the public schema
- Wrap your fragment or query inside
public - Add the fragment name after it
- Wrap your fragment or query inside
- For running multiple queries at once.
- Add multiple fragment names
Important
For mandatory parameters which are marked as * in the parameter selection, we need to pass the respective values using variables section or directly in the query.
- Click on the green
Send Requestbutton on top right or the(Send query MyQuery)button directly above the query. - The response will be displayed on the right panel.
Note
Variables can only be used with the queries that accept arguments
- Select the query you want to run and also select the parameters. The required parameters are identified by
*after the parameter name. - Click on the
$sign next to the parameter. This will extract the current value into GraphQL variable. - Click on
VARIABLESsection below the query window. - Add the required arguments and corresponding values
JSONformat.{ "pk": "1000" } - Or, we could also pass the value to parameter in the query itself.
- Run the query and the response will be displayed on the right panel.
Please follow this official GraphQL documentation for more information on how to use GraphQL.




