Skip to content

Commit

Permalink
[EDU-5976] refactor: update GraphQL API Playground reference (#1438)
Browse files Browse the repository at this point in the history
* refactor: add top attacks example - Playground EN/PT

* Update src/content/docs/en/pages/main-menu/additional-resources/developer-tools/graphql-playground.mdx

* Apply suggestions from code review

* refactor: refine order
  • Loading branch information
MarianaAguilera authored Jan 17, 2025
1 parent 6b053dd commit e141a68
Show file tree
Hide file tree
Showing 2 changed files with 44 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -168,6 +168,28 @@ query TOP5IPsWAFRequests {
}
```

Or use this one to filter the top attack types, ranked by occurrence.

```graphql
query Top5Attacks {
httpMetrics(
limit: 5
filter: {
tsRange: {
begin:"2025-01-15T00:00:00"
end:"2025-01-15T20:00:00"
}
}
groupBy:[wafAttackFamily]
orderBy:[wafRequestsThreat_DESC]
)
{
wafAttackFamily
wafRequestsThreat
}
}
```

:::tip
Visit the [Guides page](/en/documentation/products/guides/#graphql-api) and the [GraphQL API documentation](/en/documentation/devtools/graphql-api/) to explore more options for querying data.
:::
Expand All @@ -176,5 +198,3 @@ Discover how to leverage the GraphiQL Playground for real-time data analysis and
<div class="cms-embed">
<iframe width="600" height="400" src="https://www.youtube.com/embed/0V_MlxWoYPU?si=AEOBC1TcBuuvUXzg" loading="lazy" title="YouTube video player" frameborder="0" allow="accelerometer; autoplay; clipboard-write; encrypted-media; gyroscope; picture-in-picture; web-share" allowfullscreen></iframe>
</div>


Original file line number Diff line number Diff line change
Expand Up @@ -168,6 +168,28 @@ query TOP5IPsWAFRequests {
}
```

Ou use esta query para filtrar os principais tipos de ataques, classificados por ocorrência.

```graphql
query Top5Attacks {
httpMetrics(
limit: 5
filter: {
tsRange: {
begin:"2025-01-15T00:00:00"
end:"2025-01-15T20:00:00"
}
}
groupBy:[wafAttackFamily]
orderBy:[wafRequestsThreat_DESC]
)
{
wafAttackFamily
wafRequestsThreat
}
}
```

:::tip
Visite a [página de Guias](/pt-br/documentacao/produtos/guias/#graphql-api) e a [documentação da GraphQL API](/pt-br/documentacao/devtools/graphql-api/) para explorar mais opções de consulta de dados.
:::

0 comments on commit e141a68

Please sign in to comment.