Streams

Streaming Website Analytics for US Federal Government Agencies

Is there any purpose for streaming website analytics for different US Federal Government Agencies?

We have been working with the data available at analytics.usa.gov, which provides website traffic analytics for many of the US federal government agencies. The unique project provides an interesting look across the visitors to the websites of various agencies, serving up most of the details we’d regularly see for any website that uses Google Analytics.

Analytics.usa.gov provides analytics on over 25 separate federal agencies, allowing you to view top pages being viewed currently, as well as historical data for 7 and 30 days, and other details. In addition to the user interface which allows you to engage with the data, they also provide access to the data in JSON and CSV formats. Since there is JSON available, we thought it would be an excellent opportunity to turn the web traffic across federal agencies into real-time streams. So, we took one agency, the Department of Veterans Affairs (VA), and proxied three of the feeds using Streamdata.io.

Total people online:

curl -v "https://streamdata.motwin.net/https://analytics.usa.gov/data/veterans-affairs/realtime.json?X-Sd-Token=MzljM2U1ZDUtOGE1Ni00MDEwLTgwODEtOGEwZDBjMDgzMjRh"

Visitors per country:

curl -v "https://streamdata.motwin.net/https://analytics.usa.gov/data/veterans-affairs/top-countries-realtime.json?X-Sd-Token=MzljM2U1ZDUtOGE1Ni00MDEwLTgwODEtOGEwZDBjMDgzMjRh"

Visitors per city:

curl -v "https://streamdata.motwin.net/https://analytics.usa.gov/data/veterans-affairs/top-cities-realtime.json?X-Sd-Token=MzljM2U1ZDUtOGE1Ni00MDEwLTgwODEtOGEwZDBjMDgzMjRh"

These three streams provide an interesting snapshot of the number of people on the VA website, as well as which countries and cities they are visiting from. Something that could easily be replicated across the 25+ federal agencies websites available on analytics.usa.gov. Which could easily be turned into a real time web traffic dashboard as well as used to train machine learning models that could be used to understand and predict interest in government services.

We are going to play around with generating streams across each of the agencies available to see what we learn and to better understand the traffic to each of the websites. analytics.usa.gov provides a valuable look at who is visiting government websites, and potentially the types of services and information they are interested in. After playing with each individual website analytics feed, we’ll work to build an aggregate dashboard showing traffic across all of the websites, showing the real power of this aggregate analytics solution coming out of the federal government, as well as what Streamdata.io is capable of.

AI in Finance White paper - OpenAPI

**Original source: streamdata.io blog