Created Update Embed Token (markdown)
Родитель
b1ed6bd61c
Коммит
e6a9c1dda6
|
@ -0,0 +1,25 @@
|
|||
## setAccessToken
|
||||
setAccessToken can be used to update underlying Embed token without reloading the embedded report.
|
||||
This method can be helpful in different cases:
|
||||
1. 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.
|
||||
|
||||
2. Token is expired or near expiry
|
||||
If you want to change a token which is expired or near expiry, you need to use setAccessToken.
|
||||
|
||||
### Usage Example
|
||||
|
||||
```javascript
|
||||
report.setAccessToken("eyJ0eXAiOiJKV1Qi..00YU")
|
||||
.catch(error => { ... });
|
||||
```
|
||||
|
||||
## getAccessToken
|
||||
getAccessToken returns the current embed token.
|
||||
|
||||
### Usage Example
|
||||
|
||||
```javascript
|
||||
var token = report.getAccessToken();
|
||||
```
|
Загрузка…
Ссылка в новой задаче