API requests for specific speed test results

We’re working on trying to build some custom reporting in Netbeez regarding remote worker network performance. We have regularly scheduled speed tests for our remote workers. what we’d like to be able to do is query for speed tests below certain thresholds and to limit those queries for the most recent test. Right now we are getting a huge amount of data back and I’m not clear from the API documentation how to get more targeted.

Thanks!

2 Likes

Hi @snorkel,

Great question! General information about the endpoint which serves network speed results can be found here: NetBeez API

We currently don’t have a way to filter on the value of the measurements BUT we do have a way of filtering based on the “warning conditions” you set on the test. If the test is already created you can edit and set the conditions. The form looks like this:

More on the warning conditions here: https://netbeez.zendesk.com/hc/en-us/articles/210072726-Network-Speed

Once the conditions are set, then every result which satisfies those conditions will be marked with severity 4 (warning). You can then filter for results with severity 4 by using this filter:

filter[severity][operator]=<=&filter[severity][value]=4

This will return all the measurements marked with severity 4 or lower.

We also, currently don’t have a way to get the last result for each agent, but a workaround would be to try to filter the measurements based on a time range. You can do that by using this filter:

filter[ts][operator]=<=>&filter[ts][value1]=$from_ts&filter[ts][value2]=$to_ts

where $from_ts and $to_ts are the UNIX epoch timestamps in milliseconds for the range you are looking for.

I’d like to also note that we do have in our backlog an improvement request for getting the ‘last’ result for each agent for a specific network speed test. It may even make it in the next release (v.12.0).

If you have further question, please ask away!

@snorkel I’d like to let you know that with version 12.0 we have added a new filter to the scheduled tests results endpoint to return the last result from each agent involved, by using filter[last_result]=true
image

Let me know if you have any questions.