public class GOAuth2 extends Object
Modifier and Type | Field and Description |
---|---|
BBjString |
CharacterEncoding!
Character encoding for authentication requests.
|
BBjString |
ClientIDProperty!
applications using OAuth, this property can be overridden to look
for a different property in BBj.properties.
|
BBjString |
ClientSecretProperty!
applications using OAuth, this property can be overridden to look
for a different property in BBj.properties.
|
BBjNumber |
CookieGroup!
Specifies type of cookie.
|
BBjString |
CookieRefreshTokenVariable!
the cookie.
|
BBjString |
CookieScopeVariable!
Typically does not need to be modified.
|
BBjString |
CookieTokenVariable!
in the cookie.
|
BBjString |
RedirectURL!
URL or URI to which the authorization token will be sent.
|
BBjVector |
Scopes!
scopes for authorization.
|
BBjNumber |
Timeout
Authentication timeout in seconds.
|
BBjNumber |
UsesLocalhostAuthentication
Indicates whether this instance uses copy and paste token authentication or localhost authentication.
|
Modifier and Type | Method and Description |
---|---|
BBjString |
getBearerTokenFromRefreshToken(BBjString refreshToken!)
This method exchanges the refresh token for a bearer token.
|
static GOAuth2 |
getCopyPasteFromBrowserInstance()
Create a GOAuth2 object for copy/paste authentication.
|
static GOAuth2 |
getRedirectToLocalHostInstance()
Create a GOAuth2 object for localhost authentication.
|
BBjString |
getRefreshToken()
The authorization refresh token.
|
BBjString |
getToken()
The authorization token.
|
BBjString |
getTokenFromCookie()
permissions, submit the refresh token to get a new token from Google.
|
BBjNumber |
leg1()
Leg 1 constructs a permission request to send to Google, which
then will obtain permission from the user.
|
void |
leg3(BBjString code!)
In Leg 3, the intermediate code is sent to Google in exchange for
an authentication token.
|
BBjString |
localhostleg2()
Used only for locaalhost authentication, leg 2 looks for an intermediate
code that's been sent to the local webserver.
|
void |
revokeAccess()
Revokes access of the application to the currently signed in user.
|
void |
revokeAccess(BBjString token!)
Revokes access of the current token!.
|
public BBjString CookieTokenVariable!
public BBjString CookieScopeVariable!
public BBjString CookieRefreshTokenVariable!
public BBjNumber CookieGroup!
public BBjString RedirectURL!
public BBjVector Scopes!
public BBjString ClientIDProperty!
public BBjString ClientSecretProperty!
public BBjString CharacterEncoding!
public BBjNumber Timeout
public BBjNumber UsesLocalhostAuthentication
public static GOAuth2 getRedirectToLocalHostInstance()
public static GOAuth2 getCopyPasteFromBrowserInstance()
public BBjString getTokenFromCookie()
public BBjNumber leg1()
public BBjString localhostleg2()
!ERROR
- = 254 when authorization times out.!ERROR
- = 254 when an authorization error occurs.public void leg3(BBjString code!)
public BBjString getToken()
public BBjString getRefreshToken()
public BBjString getBearerTokenFromRefreshToken(BBjString refreshToken!)
!ERROR
- = 254 if refreshToken! is invalid. In particular, the error message "invalid_grant;quot; points to an invalid refresh token being provided.public void revokeAccess()
!ERROR
- = 254 if nobody is signed in. (token! is null() in that case.)public void revokeAccess(BBjString token!)
!ERROR
- = 254 if token! is null.!ERROR
- = 254 if token! was not successfully revoked.