<?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 Re: Anybody know how to change and detect Power BI Embedded token expiration. in Developer</title>
    <link>https://community.fabric.microsoft.com/t5/Developer/Anybody-know-how-to-change-and-detect-Power-BI-Embedded-token/m-p/388495#M11542</link>
    <description>&lt;P&gt;Hi&amp;nbsp;&lt;a href="https://community.fabric.microsoft.com/t5/user/viewprofilepage/user-id/59861"&gt;@Phineas&lt;/a&gt;,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Check to see if the response from &lt;A href="https://stackoverflow.com/questions/39528675/how-to-find-that-the-power-bi-embedded-apptoken-has-expired" target="_self"&gt;RBreuer&lt;/A&gt;&lt;SPAN&gt;&amp;nbsp;would help in your scenario:&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;"&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;When listening to errors, as in:&lt;SPAN&gt;&amp;nbsp;&lt;/SPAN&gt;&lt;A href="https://github.com/Microsoft/PowerBI-JavaScript/wiki/Handling-Events#full-list-of-events-and-their-response-values" rel="nofollow noreferrer" target="_blank"&gt;https://github.com/Microsoft/PowerBI-JavaScript/wiki/Handling-Events#full-list-of-events-and-their-response-values&lt;/A&gt;&lt;SPAN&gt;&amp;nbsp;&lt;/SPAN&gt;you can subscribe to report.on('error', ...) and access the message propery in the error object to detect token expiration.&lt;/P&gt;&lt;P&gt;Once detected, you can use the JS SDK to apply a new token without having to reload the embedded report&lt;SPAN&gt;&amp;nbsp;&lt;/SPAN&gt;&lt;A href="https://github.com/Microsoft/PowerBI-JavaScript/wiki/Update-Embed-Token" rel="nofollow noreferrer" target="_blank"&gt;https://github.com/Microsoft/PowerBI-JavaScript/wiki/Update-Embed-Token&lt;/A&gt;&lt;/P&gt;&lt;P&gt;of course, by using 'exp' in your JWT token, you can always set a timer to refresh the token&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;"&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;Regards,&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;Michael&lt;/SPAN&gt;&lt;/P&gt;</description>
    <pubDate>Tue, 03 Apr 2018 08:31:06 GMT</pubDate>
    <dc:creator>v-micsh-msft</dc:creator>
    <dc:date>2018-04-03T08:31:06Z</dc:date>
    <item>
      <title>Anybody know how to change and detect Power BI Embedded token expiration.</title>
      <link>https://community.fabric.microsoft.com/t5/Developer/Anybody-know-how-to-change-and-detect-Power-BI-Embedded-token/m-p/388366#M11539</link>
      <description>&lt;P&gt;I'm using Power BI Embedded with new Power BI Service (Not Power BI Workspace Collections). And I'm just using the "App owns data" approach for user to embed reports in web browser. We know embedded token has an expiration time.&amp;nbsp; See:&amp;nbsp;&lt;A href="https://msdn.microsoft.com/en-us/library/mt784614.aspx&amp;nbsp;" target="_self"&gt;https://msdn.microsoft.com/en-us/library/mt784614.aspx&amp;nbsp;&lt;/A&gt;&lt;/P&gt;&lt;P&gt;So my question is: Is there a way to set expiration time ?(Power BI Workspace Collections API has this parameter). If not, I'm a single page application, how can I detect the embedded token has expired ?&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Sincerely.&lt;/P&gt;&lt;P&gt;Looking forward to your reply.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Tue, 03 Apr 2018 06:08:09 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/Developer/Anybody-know-how-to-change-and-detect-Power-BI-Embedded-token/m-p/388366#M11539</guid>
      <dc:creator>Phineas</dc:creator>
      <dc:date>2018-04-03T06:08:09Z</dc:date>
    </item>
    <item>
      <title>Re: Anybody know how to change and detect Power BI Embedded token expiration.</title>
      <link>https://community.fabric.microsoft.com/t5/Developer/Anybody-know-how-to-change-and-detect-Power-BI-Embedded-token/m-p/388495#M11542</link>
      <description>&lt;P&gt;Hi&amp;nbsp;&lt;a href="https://community.fabric.microsoft.com/t5/user/viewprofilepage/user-id/59861"&gt;@Phineas&lt;/a&gt;,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Check to see if the response from &lt;A href="https://stackoverflow.com/questions/39528675/how-to-find-that-the-power-bi-embedded-apptoken-has-expired" target="_self"&gt;RBreuer&lt;/A&gt;&lt;SPAN&gt;&amp;nbsp;would help in your scenario:&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;"&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;When listening to errors, as in:&lt;SPAN&gt;&amp;nbsp;&lt;/SPAN&gt;&lt;A href="https://github.com/Microsoft/PowerBI-JavaScript/wiki/Handling-Events#full-list-of-events-and-their-response-values" rel="nofollow noreferrer" target="_blank"&gt;https://github.com/Microsoft/PowerBI-JavaScript/wiki/Handling-Events#full-list-of-events-and-their-response-values&lt;/A&gt;&lt;SPAN&gt;&amp;nbsp;&lt;/SPAN&gt;you can subscribe to report.on('error', ...) and access the message propery in the error object to detect token expiration.&lt;/P&gt;&lt;P&gt;Once detected, you can use the JS SDK to apply a new token without having to reload the embedded report&lt;SPAN&gt;&amp;nbsp;&lt;/SPAN&gt;&lt;A href="https://github.com/Microsoft/PowerBI-JavaScript/wiki/Update-Embed-Token" rel="nofollow noreferrer" target="_blank"&gt;https://github.com/Microsoft/PowerBI-JavaScript/wiki/Update-Embed-Token&lt;/A&gt;&lt;/P&gt;&lt;P&gt;of course, by using 'exp' in your JWT token, you can always set a timer to refresh the token&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;"&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;Regards,&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;Michael&lt;/SPAN&gt;&lt;/P&gt;</description>
      <pubDate>Tue, 03 Apr 2018 08:31:06 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/Developer/Anybody-know-how-to-change-and-detect-Power-BI-Embedded-token/m-p/388495#M11542</guid>
      <dc:creator>v-micsh-msft</dc:creator>
      <dc:date>2018-04-03T08:31:06Z</dc:date>
    </item>
    <item>
      <title>Re: Anybody know how to change and detect Power BI Embedded token expiration.</title>
      <link>https://community.fabric.microsoft.com/t5/Developer/Anybody-know-how-to-change-and-detect-Power-BI-Embedded-token/m-p/388533#M11543</link>
      <description>&lt;P&gt;Hi, Michael, Thanks for your reply.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I'll already seen the link you mentionded.&lt;/P&gt;&lt;P&gt;I tested it in my code by adding: "report.on('error',function(){...})", but the function will not be invoked. Instead, a 403 HTTP code will be returned with content "Access token has expired, resubmit with a new access token".&lt;/P&gt;&lt;P&gt;I know the expired time will be returned with embedded token by calling WEB API "GenerateTokenInGroupAsync(...)".&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I want to know whether it is possible to change the expiration time. and is it possible to detect this in front-end.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Regards Phineas&lt;/P&gt;</description>
      <pubDate>Tue, 03 Apr 2018 09:19:00 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/Developer/Anybody-know-how-to-change-and-detect-Power-BI-Embedded-token/m-p/388533#M11543</guid>
      <dc:creator>Phineas</dc:creator>
      <dc:date>2018-04-03T09:19:00Z</dc:date>
    </item>
    <item>
      <title>Re: Anybody know how to change and detect Power BI Embedded token expiration.</title>
      <link>https://community.fabric.microsoft.com/t5/Developer/Anybody-know-how-to-change-and-detect-Power-BI-Embedded-token/m-p/417618#M12423</link>
      <description>&lt;P&gt;Hi, any news?&lt;/P&gt;&lt;P&gt;I'm also interested in how to set the expiration time of an embedded token with the "new powerBI", if it's possible.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Regards&lt;/P&gt;</description>
      <pubDate>Tue, 15 May 2018 10:25:32 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/Developer/Anybody-know-how-to-change-and-detect-Power-BI-Embedded-token/m-p/417618#M12423</guid>
      <dc:creator>EttoreP</dc:creator>
      <dc:date>2018-05-15T10:25:32Z</dc:date>
    </item>
    <item>
      <title>Re: Anybody know how to change and detect Power BI Embedded token expiration.</title>
      <link>https://community.fabric.microsoft.com/t5/Developer/Anybody-know-how-to-change-and-detect-Power-BI-Embedded-token/m-p/723017#M19757</link>
      <description>&lt;P&gt;I am also interested in setting the lifetime or expiration time of the embed token for testing. Is this possible with teh new API?&lt;/P&gt;</description>
      <pubDate>Tue, 25 Jun 2019 00:11:23 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/Developer/Anybody-know-how-to-change-and-detect-Power-BI-Embedded-token/m-p/723017#M19757</guid>
      <dc:creator>brusser</dc:creator>
      <dc:date>2019-06-25T00:11:23Z</dc:date>
    </item>
  </channel>
</rss>

