<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Power BI REST API Export File In Group JSON deserializing error in Developer</title>
    <link>https://community.fabric.microsoft.com/t5/Developer/Power-BI-REST-API-Export-File-In-Group-JSON-deserializing-error/m-p/1823379#M29290</link>
    <description>&lt;P&gt;Hello:&lt;/P&gt;&lt;P&gt;I am trying to use PowerBI REST API (in C#) using&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;LI-CODE lang="csharp"&gt;  using var response = await _httpClient.SendAsync(httpRequest, HttpCompletionOption.ResponseHeadersRead, cancellationToken);
... 

if(response.StatusCode = HttpStatusCode.Accepted){
  var result =  await response.Content.ReadFromJsonAsync&amp;lt;Export&amp;gt;(cancellationToken: cancellationToken) 

...}&lt;/LI-CODE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;I got response back, but when I deserialize json , it throws exception&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;LI-CODE lang="markup"&gt;The JSON value could not be converted to System.Nullable`1[Microsoft.PowerBI.Api.Models.ExportState]. Path: $.status | LineNumber: 1 | BytePositionInLine: 278.&lt;/LI-CODE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Can someone help with this error?&lt;/P&gt;&lt;P&gt;When I used online tryit from&amp;nbsp;&lt;A href="https://docs.microsoft.com/en-us/rest/api/power-bi/reports/exporttofileingroup#code-try-0" target="_blank" rel="noopener"&gt;https://docs.microsoft.com/en-us/rest/api/power-bi/reports/exporttofileingroup#code-try-0&lt;/A&gt;&amp;nbsp;, I noticed the response is like this:&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;LI-CODE lang="markup"&gt;{
  "@odata.context": "http://.../v1.0/myorg/groups/.../$metadata#exports/$entity",
  "id": "...",
  "createdDateTime": "2021-05-05T...Z",
  "lastActionDateTime": "2021-05-05T...Z",
  "reportId": "...",
  "status": "NotStarted",
  "percentComplete": 0,
  "expirationTime": "0001-01-01T00:00:00Z"
}&lt;/LI-CODE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
    <pubDate>Wed, 05 May 2021 00:10:08 GMT</pubDate>
    <dc:creator>Anonymous</dc:creator>
    <dc:date>2021-05-05T00:10:08Z</dc:date>
    <item>
      <title>Power BI REST API Export File In Group JSON deserializing error</title>
      <link>https://community.fabric.microsoft.com/t5/Developer/Power-BI-REST-API-Export-File-In-Group-JSON-deserializing-error/m-p/1823379#M29290</link>
      <description>&lt;P&gt;Hello:&lt;/P&gt;&lt;P&gt;I am trying to use PowerBI REST API (in C#) using&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;LI-CODE lang="csharp"&gt;  using var response = await _httpClient.SendAsync(httpRequest, HttpCompletionOption.ResponseHeadersRead, cancellationToken);
... 

if(response.StatusCode = HttpStatusCode.Accepted){
  var result =  await response.Content.ReadFromJsonAsync&amp;lt;Export&amp;gt;(cancellationToken: cancellationToken) 

...}&lt;/LI-CODE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;I got response back, but when I deserialize json , it throws exception&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;LI-CODE lang="markup"&gt;The JSON value could not be converted to System.Nullable`1[Microsoft.PowerBI.Api.Models.ExportState]. Path: $.status | LineNumber: 1 | BytePositionInLine: 278.&lt;/LI-CODE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Can someone help with this error?&lt;/P&gt;&lt;P&gt;When I used online tryit from&amp;nbsp;&lt;A href="https://docs.microsoft.com/en-us/rest/api/power-bi/reports/exporttofileingroup#code-try-0" target="_blank" rel="noopener"&gt;https://docs.microsoft.com/en-us/rest/api/power-bi/reports/exporttofileingroup#code-try-0&lt;/A&gt;&amp;nbsp;, I noticed the response is like this:&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;LI-CODE lang="markup"&gt;{
  "@odata.context": "http://.../v1.0/myorg/groups/.../$metadata#exports/$entity",
  "id": "...",
  "createdDateTime": "2021-05-05T...Z",
  "lastActionDateTime": "2021-05-05T...Z",
  "reportId": "...",
  "status": "NotStarted",
  "percentComplete": 0,
  "expirationTime": "0001-01-01T00:00:00Z"
}&lt;/LI-CODE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Wed, 05 May 2021 00:10:08 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/Developer/Power-BI-REST-API-Export-File-In-Group-JSON-deserializing-error/m-p/1823379#M29290</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2021-05-05T00:10:08Z</dc:date>
    </item>
    <item>
      <title>Re: Power BI REST API Export File In Group JSON deserializing error</title>
      <link>https://community.fabric.microsoft.com/t5/Developer/Power-BI-REST-API-Export-File-In-Group-JSON-deserializing-error/m-p/1828964#M29322</link>
      <description>&lt;P&gt;Hi&amp;nbsp;@Anonymous&amp;nbsp;,&lt;/P&gt;
&lt;P&gt;Please review the solution in the following links and check whether they can help you resolve the problem.&lt;/P&gt;
&lt;P&gt;&lt;A href="https://github.com/dotnet/runtime/issues/37913" target="_self"&gt;&lt;STRONG&gt;JsonSerializer.Deserialize on Nullable value types&lt;/STRONG&gt;&lt;/A&gt;&lt;/P&gt;
&lt;P&gt;&lt;A href="https://stackoverflow.com/questions/66368772/why-it-occurs-this-error-the-json-value-could-not-be-converted-to-system-nullab" target="_self"&gt;&lt;STRONG&gt;Why it occurs this error [The JSON value could not be converted to System.Nullable] &lt;/STRONG&gt;&lt;/A&gt;&lt;/P&gt;
&lt;P&gt;Best Regards&lt;/P&gt;</description>
      <pubDate>Fri, 07 May 2021 04:51:11 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/Developer/Power-BI-REST-API-Export-File-In-Group-JSON-deserializing-error/m-p/1828964#M29322</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2021-05-07T04:51:11Z</dc:date>
    </item>
  </channel>
</rss>

