Skip to content

Commit 9b90466

Browse files
committed
add simple sanity check for external data source
1 parent 60196db commit 9b90466

File tree

1 file changed

+16
-1
lines changed

1 file changed

+16
-1
lines changed

README.md

+16-1
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,22 @@ wrangler generate my-graphql-server https://github.com/cloudflare/workers-graphq
1818

1919
You'll need to configure your project's `wrangler.toml` file to prepare your project for deployment. See the ["Configuration"](https://developers.cloudflare.com/workers/cli-wrangler/configuration/) docs for a guide on how to do this. Note that you'll need to [find your Cloudflare API keys](https://developers.cloudflare.com/workers/cli-wrangler/authentication/) to set up your config file.
2020

21-
The source for this project includes an example external REST data source, and defined types for the [PokeAPI](https://pokeapi.co/), as an example of how to integrate external APIs.
21+
The source for this project includes an example external REST data source, and defined types for the [PokeAPI](https://pokeapi.co/), as an example of how to integrate external APIs. Once you have the worker available, try this query as a sanity check:
22+
23+
```graphql
24+
query samplePokeAPIquery {
25+
pokemon: pokemon(id:1) {
26+
id,
27+
name,
28+
height,
29+
weight,
30+
sprites{
31+
front_shiny,
32+
back_shiny
33+
}
34+
}
35+
}
36+
```
2237

2338
To start using the project, configure your `graphQLOptions` object in `src/index.js`:
2439

0 commit comments

Comments
 (0)