# How to query GraphQL requests on Postman

You can query [GraphQL API](/en/documentation/devtools/graphql-api/overview/) requests [on Postman](https://www.postman.com/) or other API platforms. To use Postman, you need to go through two steps: create a personal token and run your request on Postman. See the next sections and follow the presented steps.

---

## Creating a personal token

Before running your requests with the **GraphQL API**, you first need to create a personal token on Azion to validate your access.

1. On [Azion Console](https://console.azion.com), on the upper-right corner, select **Account menu** > **Personal Tokens**.
2. Fill the fields to configure the personal token and click the **Create Token** button.
3. Copy and save your token in a safe location to use it in the next section.

See the [Personal Tokens documentation](/en/documentation/products/accounts/personal-tokens/) for more information on how to create one.

As an alternative, you can create a short-duration token through the [Azion API](https://api.azion.com/).

---

## Querying on Postman

After creating your personal token, [go to Postman](https://www.postman.com/) and follow the next steps:

1. On the header, click the **+** button to create a new request.
2. On the **Headers** tab, click on **Bulk Edit** and add the following code, replacing [TOKEN VALUE] with the personal token value you created:

```json
Authorization: Token [TOKEN VALUE]
```

Remain on **Postman** and create the request's body:

1. Select the **Body** tab.
2. On the upper-left corner, click the **GET** option to open a dropdown menu.
3. Select the **POST** option.
4. On the **Enter URL or paste text** field, add the URL being queried: `https://api.azionapi.net/metrics/graphql` or `https://api.azionapi.net/events/graphql`
5. On the options row with radio buttons, select the **GraphQL** option.
6. On the code box, add the query you want to use. For example:

```graphql
query HttpQuery {
  httpMetrics(
    limit: 10,
    filter: {
      tsRange: {begin:"2022-03-21T10:10:10", end:"2022-06-23T10:10:10"}
    }
    aggregate: {sum: bytesSent}
    groupBy: [ts]
    orderBy: [ts_ASC]
  )
  {
    ts
    sum
  }
}
```

7. Click the **Send** button on the upper-right corner.

You'll receive a response with the requested data, similar to this:

```json
{
   "data": {
       "httpMetrics": [
           {
               "ts": "2022-06-09T21:33:13",
               "sum": 1471.0
           },
           {
               "ts": "2022-06-09T21:33:14",
               "sum": 1471.0
           },
           {
               "ts": "2022-06-09T21:33:15",
               "sum": 1471.0
           }
       ]
   }
}
```

You can find queries examples on the [GitHub azion-queries repository](https://github.com/aziontech/azion-queries).