Azion Announces GraphQL API for Deep Analysis of Real-Time Events Data

Explore Azion's Events GraphQL API for real-time data querying and analysis with low latency and high flexibility. Ideal for security and performance management.

Evandro Flores - Product Manager
Lais Misko - Product Marketing Manager
Vivian Seixas - Technical Researcher
Azion Announces GraphQL API for Deep Analysis of Real-Time Events Data

Last quarter, Azion made our Metrics GraphQL API available to give our customers access to aggregated metrics on product usage, security, request/response events, and more.

To start the new year, we’ve added the Events GraphQL API endpoint that allows our customers to query raw event data for deep levels of analysis, giving the users autonomy to request the data they want and receive exactly what they asked for. It’s more power and agility.

Image with Azion's and GraphQL's logos

A Quick Overview Through Ours Both GraphQL APIs

The Metrics GraphQL API gives you access to the aggregated data model, thus the API will fetch the data according to a predefined interval of minutes, hours, or days. It’s possible to consider more than 20 types of variables to filter.

With the Events GraphQL API beta version, we explore raw data with more than 60 types of variables. Users of Real-Time Events can filter until 168 hours (7 days).

Both APIs can reach 120 requests per minute.

Introducing GraphQL for Real-Time Events

At Azion, we’ve always prioritized giving our customers the right data to manage, monitor, and troubleshoot their website, app, or service. And with this update, customers can retrieve and visualize raw event records in a well-structured and object-oriented way and receive results in a convenient JSON format.

Because your code is running on Azion’s edge locations all over the world, requests via the GraphQL API will have extremely low latency. This has allowed one of our customers, a multi-billion dollar worldwide retailer, to automate GraphQL queries to retrieve the latest security data in a matter of milliseconds.

Requests made via our Events GraphQL API are totally free for our customers in this beta version. Additionally, Azion does not restrict queries as some of our competitors do, forcing users into strict query templates. On the other hand, we invite our users to explore all data available by querying the GraphQL metadata here.

Use Cases and Examples

Events GraphQL API supports many decision use cases associated with running applications on the Azion platform.

  • Identifying irregular spikes in user activity
  • Understanding common attributes associated with requests
  • Drilling down to granular detail to solve application performance issues

However, security use cases are often at the top of many organizations’ minds, so let’s look at one example where the Events GraphQL API can help in a common security workflow.

Query Example

query EventsQuery {
    httpEvents(
        limit: 2,
        filter: {
        status: 400
        upstreamStatus: 0
        },
        aggregate: {count: remoteAddress}
        groupBy: [remoteAddress, requestUri,status,host, httpReferer, wafMatch]
        orderBy: [count_DESC]
        )
        {
            remoteAddress
            requestUri
            count
            status
            host
            httpReferer
        }
}

Response Example

{
  "data": {
    "httpEvents": [
      {
        "remoteAddress": "138.198.135.2",
        "requestUri": "/favicon.ico",
        "count": 3,
        "status": 400,
        "host": "1234567h.ha.azioncdn.net",
        "httpReferer": "https://1234567h.ha.azioncdn.net/radware/index.html"
      },
      {
        "remoteAddress": "138.198.135.2",
        "requestUri": "/favicon.ico",
        "count": 3,
        "status": 400,
        "host": "1234567h.ha.azioncdn.net",
        "httpReferer": "https://1234567h.ha.azioncdn.net/radware/images/900x350.png?ims=90x35"
      }
    ]
  }
}

Try It Now

If you’re ready to start using Azion’s Event GraphQL API to query your real-time events, check out our documentation. If you’re not using our platform today, you can try it for free today!

And for more hands-on help or observability best practices, reach out to your customer success manager or contact an expert today!

stay up to date

Subscribe to our Newsletter

Get the latest product updates, event highlights, and tech industry insights delivered to your inbox.