Skip to content

Commit

Permalink
Merge pull request #19117 from marcusperezNR/mperez/add-cancel-async-…
Browse files Browse the repository at this point in the history
…query

feat: Add Cancel Query Nerdgraph Block
  • Loading branch information
ally-sassman authored Oct 30, 2024
2 parents ec5d901 + 60a4c68 commit 65342b6
Showing 1 changed file with 14 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -68,3 +68,17 @@ Some important details about this query:
* The `account` argument must match the `account` argument from the original query.
* This query will return results if asynchronous execution has completed; otherwise it will return `queryProgress` data.
* The query can be repeated verbatim until results or an error are returned.

## Cancel an async query [#example-cancel-query]

You can cancel an asynchronous query by using the `cancelAsyncQuery` mutation. This mutation takes the `queryId` of the query you want to cancel.

```graphql
mutation {
cancelAsyncQuery(queryId: "YOUR_QUERY_ID") {
queryToken
accepted
rejectionCause
}
}
```

0 comments on commit 65342b6

Please sign in to comment.