Skip to content

Commit

Permalink
Merge pull request #276 from Discoded/main
Browse files Browse the repository at this point in the history
Update graphql-examples.md with Task example
  • Loading branch information
GrantBirki authored Feb 19, 2024
2 parents c1ce3c7 + e6594dd commit 659eb76
Showing 1 changed file with 39 additions and 0 deletions.
39 changes: 39 additions & 0 deletions docs/graphql-examples.md
Original file line number Diff line number Diff line change
Expand Up @@ -51,3 +51,42 @@ Retrieve information about a given item in the game.
}
}
```

### Tasks

Retrieve quest or task info.

[Inline fragments](https://www.apollographql.com/docs/react/data/fragments/#using-fragments-with-unions-and-interfaces) are used as `objectives` return an `interface TaskObjective`.

```graphql
query {
tasks {
id
name
objectives {
id
type
description
maps {
normalizedName
}
... on TaskObjectiveItem {
item {
name
shortName
}
items {
name
shortName
}
count
foundInRaid
}
... on TaskObjectiveShoot{
targetNames
count
}
}
}
}
```

0 comments on commit 659eb76

Please sign in to comment.