-
Notifications
You must be signed in to change notification settings - Fork 72
Description
Feature Request
The requested feature would be provide a way to inject an extra auth token to all API requests' header,
along with a way to automatically refresh the token when it s expired.
Description of Problem:
Symphony APIs requires the session token and key manager token to authenticate the requests.
in BDK, once the bot authenticates itself, the retrieved tokens are systematically added to all APIs requests.
However in case where all Symphony components are behind a gateway, Apigee for instance, there is no
way to inject the extra auth token to all API requests, in order to authenticate the requests against Apigee,
therefore requests are rejected.
Potential Solutions:
A new interface allowing bdk bot developer to retrieve the token, also determine the expiration of the token
based on the exception.
public interface CustomEnhancedAuthAuthenticator {
/**
* Authenticates.
*
* @return the authentication session.
*/
@Nonnull
String authenticate() throws AuthUnauthorizedException;
boolean isAuthTokenExpired(ApiException exception);
}