Forum Discussion

navigator's avatar
navigator
New Member
6 years ago

REST call: Reports - Get Pages In Group always return null in the name field

I do a GET request as decribed here: https://docs.microsoft.com/en-us/rest/api/power-bi/reports/getpagesingroup#page

 

The name field in the response should be filled, but it's null.

 

For example:

 

{
  "value": [
    {
      "displayName": "Regional Sales Analysis",
      "name": null,
      "order": "0"
    },
    {
      "displayName": "Geographic Analysis",
      "name": null,
      "order": "1"
    }
  ]
}

 

 

It should look something like this:

 

{
  "value": [
    {
      "displayName": "Regional Sales Analysis",
      "name": "ReportSection",
      "order": "0"
    },
    {
      "displayName": "Geographic Analysis",
      "name": "ReportSection1",
      "order": "1"
    }
  ]
}

 

 

Am I doing something wrong here? The docs don't say it can be null, so I'm really confused. 

Any help is much appreciated.

 

Cheers,

Mike

2 Replies

  • Update: I see now that I a Name field is present (instead of a name field):

     

     

    {
      "@odata.context":"http://wabi-west-europe-redirect.analysis.windows.net/v1.0/myorg/groups/XXX-XXX-XXX/$metadata#pages","value":[
        {
          "Name":"ReportSection","displayName":"X","order":0
        },{
          "Name":"ReportSection90784923874","displayName":"Y","order":1
        },{
          "Name":"ReportSection2134325","displayName":"Z","order":2
        }
      ]
    }

     

     

    I think this causes my library to not be able to deserialize the value properly, as it should be name and not Name.

    In the swagger file that describes the power-bi api, we can see the following description of Page:

     

     

    "Page":{
       "description":"A Power BI report page",
       "properties":{
          "name":{
             "type":"string",
             "description":"The page name"
          },
          "displayName":{
             "type":"string",
             "description":"The page display name"
          },
          "order":{
             "type":"integer",
             "format":"int32",
             "description":"The page order"
          }
       }
    }

     

     

     

    Clearly the name property should be with a lower-case n, but is currently returned with a capital N.

    Is this a bug?