Ruchi Anand
TFDThoughtSpot For Developers
•Created by vmcafee on 4/4/2025 in #help
Session coordination between TS and hosted application
You can use autoLogin:true, it will remain the session active.
6 replies
TFDThoughtSpot For Developers
•Created by vmcafee on 4/4/2025 in #help
Session coordination between TS and hosted application
@vmcafee The is no way to track this API call from the host application, This API is called every 30 seconds to verify the session's active status after the successful login.
6 replies
TFDThoughtSpot For Developers
•Created by Anderson on 4/4/2025 in #dev-help
Anderson - Hi team, I have a user who is trying...
@Anderson Currently, there is no method to track this API call.
7 replies
TFDThoughtSpot For Developers
•Created by Jerry Jin on 4/4/2025 in #dev-help
Jerry Jin - Hello,I am trying to find a way t...
Hi @Jerry Jin The getAuthToken function needs to return a Promise that resolves with the token.
Instead of using JSON.stringify, you can just return the token as string directly in a Promise.resolve().
init({
thoughtSpotHost: "host",
authType: AuthType.TrustedAuthToken,
username: "<username>",
getAuthToken: () => {
let tsToken = "<your-token>";
return Promise.resolve(tsToken);
}
});
For more info, refer : https://developers.thoughtspot.com/docs/trusted-auth-sdk2 replies
TFDThoughtSpot For Developers
•Created by TomerLand on 4/1/2025 in #dev-help
TomerLand - Hey, we are embedding the app and w...
If you'd like to customize the error message, you can pass your custom error message in the init function like this:
const authStatus = init({
thoughtSpotHost: thoughtSpotHost,
loginFailedMessage: "Your custom error message"
});
Alternatively, if the onError event doesn't work, you can listen for the AuthStatus.FAILURE event, which is triggered whenever an error occurs during authentication. You can handle the error as shown below:
authStatus.on(AuthStatus.FAILURE, (reason) => {
console.error('Authentication failed:', reason);
// Here, you can implement your app's error handling (e.g., show a login modal)
});
you can refer this for more info : https://developers.thoughtspot.com/docs/embed-auth#_authentication_errors_and_event_handling4 replies