Can you retrieve system.timestamp":"{system.timestamp}" via the Apigee Analytics metrics API ?

I understand under message logging we can extract system.timestamp":"{system.timestamp}" along with various other timestamps.

"client.received.start.timestamp":"{client.received.start.timestamp}",
"client.sent.end.timestamp":"{client.sent.end.timestamp}",
"target.sent.start.timestamp":"{target.sent.start.timestamp}",
"target.received.end.timestamp":"{target.received.end.timestamp}",

But we are wanting to use the metrics API to obtain certain metrics via the API , as an example :

https://api.enterprise.apigee.com/v1/o/{org_name}/environments/prod/stats/apiproxy,request_path,request_uri,request_verb,?select=sum(message_count)&timeRange=08/26/2022%2000:00~08/26/2022%2023:59&timeUnit=minute

But need the actual system.timestamp":"{system.timestamp} of the request being made so is this possible using the metrics  API ?  Cant seem to find a way to do this apart from the metrics using  timeUnit=

Basically we just need the physical timestamp of each request made and not in a time unit but the actual timestamp. As you can see from my example API metrics Curl its the requests we are primarily needing in this particular situation.

Cant seem to find anything in the docs to elaborate on this so thought i'd ask the community here for some help.

 

0 1 191
1 REPLY 1

But need the actual system.timestamp":"{system.timestamp} of the request being made so is this possible using the metrics API ?

What are you really trying to do? The metrics/stats API delivers the results of aggregation and elaboration of the underlying data records. It will give answers to questions like

  • how many transactions did Apigee handle between 0800 and 2000 yesterday?
  • What was the TP50 and TP95 latency of requests for apiproxy X, for each hour last week?
  • For last week, What percentage of requests received a non-200 response status code and how did that compare to the prior week?

If you want to know "what was the specific timestamp of one of the requests handled by Apigee yesterday?" then you probably need to use a different data store. That's not a question that the stats/metrics API can answer. If you need the ability to retrieve specific data related to each transaction, then you will need to modify your API proxies so that they log that specific data into a logging system (like Google Cloud Logging) , and then query THAT.