Convert JSON-values into numbers to display them in a time series panel

Hello
I am using Grafana Cloud with JSON API.
With JSON I query a service and get the following return values:
new, started, up, grace, down, and paused.
I want to do a mapping to display the values in a time series panel:
down = 0
up = 1
new = 2
ā€¦
Is there a way to do something like this?

Hi there @anon89763442

best way for us to help you is to share your unformatted data from the inspect drawer, or a screenshot of your query results visualized using the table panel :+1:

you can convert values using value mappings, but without timestamps your data will not graph on the time series panel

Hi there @mattabrams

Thanks for your answer!
I tried the approach with value mappings. But as you say I am missing the timestamps to make a time series.
In the meantime I had contact with Grafana support. It turned out that it is not possible to implement the solution as I wanted.
Therefore I will choose another form of display.

Best
Dan

1 Like

This topic was automatically closed after 365 days. New replies are no longer allowed.