if(idKey == null) return "invalid";
IPersistenceManager persistenceManager = PersistenceManagerFactory.getPersistenceManager();
IWidgetInstance widgetInstance = persistenceManager.findWidgetInstanceByIdKey(idKey);
if(widgetInstance==null) return "invalid";
IOAuthToken oauthToken = persistenceManager.findOAuthToken(widgetInstance);
if (oauthToken != null) {
if (!oauthToken.isExpires())
return oauthToken.getAccessToken() ;
}
return "invalid";