elastic stack – How to get the corresponding timestamp for maximum count using Kibana Lens

I am trying to make a table in Kibana Lens which contains the API name, max number of requests (max(load per hour)) and its corresponding timestamp.
I am able to get the maximum(number of requests per hour) but I am unable to extract the corresponding timestamp for it.

I have tried two approaches –
First was – My main metric is count of Records where type=REQUEST. I have added API name and @timestamp under ‘Rows’. This is the configuration I have used for @timestamp column:
configuration for @timestamp
This gives me the API name and the max load but no timestamp as the column has been collapsed.

Second approach was to not use “Collapse by” max under @timestamp and instead, use overall_max(overall_max(count(kql=”TYPE : “REQUEST” “)). This is again giving me the max load but this is what I get, where max load of 3087 is for API-1 and 7 is for API-2.
Approach-2

Is there any way I can also get the timestamp/1 hour period for which we have the highest load for each API?

Read more here: Source link