-
Notifications
You must be signed in to change notification settings - Fork 469
Update Embed Token
ali-hamud edited this page Apr 20, 2017
·
5 revisions
setAccessToken can be used to update underlying Embed token without reloading the embedded report. This method can be helpful in different cases:
-
After SaveAs After SaveAs, the new report will be shown, while the underlying token is giving access to the old report. In such case, you should generate a new token to see the new report, and use setAccessToken to set new generated token.
-
Token is expired or near expiry If you want to change a token which is expired or near expiry, you need to use setAccessToken.
report.setAccessToken("eyJ0eXAiOiJKV1Qi..00YU")
.catch(error => { ... });
getAccessToken returns the current embed token.
var token = report.getAccessToken();