Expand my Community achievements bar.

SOLVED

Observability API - Access Denied

Avatar

Level 4

I have full and complete access to my Sandbox - 118765E655DEE7427F000101@AdobeOrg .

 

Problem 1: have been trying to access https://platform.adobe.io/data/infrastructure/observability/insights/metrics, however been getting following error 

Problem 2: Inspite of passing sandbox  name, it says missing Sandbox name.

 

{
    "errorCode""OBS-4005",
    "httpStatus"401,
    "title""Access Denied",
    "details""Access Denied. x-Sandbox-Name is missing."
1 Accepted Solution

Avatar

Correct answer by
Community Advisor

Hello @navink386520 

118765E655DEE7427F000101@AdobeOrg  is your IMS org ID. Sandbox name is different.

Add an additional header in your API request. Try using x-sandbox-name as a key and prod as a value.
If this does not work, then change the value to your company name for eg. google



     Manoj
     Find me on LinkedIn

View solution in original post

8 Replies

Avatar

Correct answer by
Community Advisor

Hello @navink386520 

118765E655DEE7427F000101@AdobeOrg  is your IMS org ID. Sandbox name is different.

Add an additional header in your API request. Try using x-sandbox-name as a key and prod as a value.
If this does not work, then change the value to your company name for eg. google



     Manoj
     Find me on LinkedIn

Avatar

Level 4

Offcourse, I tried with x-sandbox-name, however its same issue.

@_Manoj_Kumar_   could you please try and check if you are getting response for Observability Metrics API.

Avatar

Community Advisor

Hello @navink386520 ,

Confirming it is working for me by adding the x-sandbox-name-value manually.

Manoj_Kumar__0-1651106743370.png

 

As I mentioned in my previous comment it might not work if you are using the {{ SANDBOX_NAME }} variable from the environment.

You will have to change the value specified for this API call.

The possible value can be your company name for eg. google

 


     Manoj
     Find me on LinkedIn

Avatar

Level 4

@_Manoj_Kumar_  offcourse this is standard response, but not right response. Offcourse, am passing right Sandbox (I gave org id for reference to debug) details.

That said, expected response (below screenshot), however your response does not include object value for 

"datapoints": 

 

{
  "metricResponses": [
    {
      "metric": "timeseries.ingestion.dataset.recordsuccess.count",
      "filters": [
        {
          "name": "dataSetId",
          "value": "5edcfb2fbb642119194c7d94|5eddb21420f516191b7a8dad",
          "groupBy": true
        }
      ],
      "datapoints": [
        {
          "groupBy": {
            "dataSetId": "5edcfb2fbb642119194c7d94"
          },
          "dps": {
            "2020-07-14T00:00:00Z": 44.0,
            "2020-07-15T00:00:00Z": 46.0,
            "2020-07-16T00:00:00Z": 36.0,
            "2020-07-17T00:00:00Z": 50.0,
            "2020-07-18T00:00:00Z": 38.0,
            "2020-07-19T00:00:00Z": 40.0,
            "2020-07-20T00:00:00Z": 42.0,
            "2020-07-21T00:00:00Z": 42.0,
            "2020-07-22T00:00:00Z": 50.0
          }
        },
        {
          "groupBy": {
            "dataSetId": "5eddb21420f516191b7a8dad"
          },
          "dps": {
            "2020-07-14T00:00:00Z": 44.0,
            "2020-07-15T00:00:00Z": 46.0,
            "2020-07-16T00:00:00Z": 36.0,
            "2020-07-17T00:00:00Z": 50.0,
            "2020-07-18T00:00:00Z": 38.0,

 

Avatar

Community Advisor

Hello @navink386520 ,

I was just testing the response at that time and the filters were not correct. That is why the API response of datapoints was empty.

Here is the screenshot of the response with correct filters where I see the records in data points.

Manoj_Kumar__0-1651116180916.png

 




     Manoj
     Find me on LinkedIn

Avatar

Level 4

Thanks @_Manoj_Kumar_  unfortunately, am still get 0 value in datapoints. Can we connect in Adobe slack

navink386520_0-1651162084412.png

navink386520_1-1651162110231.png