Backstage
Docs
Github
Preparing search index...
@backstage/plugin-auth-node
OAuthAuthenticator
Interface OAuthAuthenticator<TContext, TProfile>
interface
OAuthAuthenticator
<
TContext
,
TProfile
>
{
defaultProfileTransform
:
ProfileTransform
<
OAuthAuthenticatorResult
<
TProfile
>
,
>
;
scopes
?:
OAuthAuthenticatorScopeOptions
;
shouldPersistScopes
?:
boolean
;
authenticate
(
input
:
OAuthAuthenticatorAuthenticateInput
,
ctx
:
TContext
,
)
:
Promise
<
OAuthAuthenticatorResult
<
TProfile
>
>
;
initialize
(
ctx
:
{
callbackUrl
:
string
;
config
:
Config
}
)
:
TContext
;
logout
?
(
input
:
OAuthAuthenticatorLogoutInput
,
ctx
:
TContext
)
:
Promise
<
void
>
;
refresh
(
input
:
OAuthAuthenticatorRefreshInput
,
ctx
:
TContext
,
)
:
Promise
<
OAuthAuthenticatorResult
<
TProfile
>
>
;
start
(
input
:
OAuthAuthenticatorStartInput
,
ctx
:
TContext
,
)
:
Promise
<
{
status
?:
number
;
url
:
string
}
>
;
}
Type Parameters
TContext
TProfile
Index
Properties
default
Profile
Transform
scopes?
should
Persist
Scopes?
Methods
authenticate
initialize
logout?
refresh
start
Properties
default
Profile
Transform
defaultProfileTransform
:
ProfileTransform
<
OAuthAuthenticatorResult
<
TProfile
>
>
Optional
scopes
scopes
?:
OAuthAuthenticatorScopeOptions
Optional
should
Persist
Scopes
shouldPersistScopes
?:
boolean
Deprecated
use
scopes.persist
instead
Methods
authenticate
authenticate
(
input
:
OAuthAuthenticatorAuthenticateInput
,
ctx
:
TContext
,
)
:
Promise
<
OAuthAuthenticatorResult
<
TProfile
>
>
Parameters
input
:
OAuthAuthenticatorAuthenticateInput
ctx
:
TContext
Returns
Promise
<
OAuthAuthenticatorResult
<
TProfile
>
>
initialize
initialize
(
ctx
:
{
callbackUrl
:
string
;
config
:
Config
}
)
:
TContext
Parameters
ctx
:
{
callbackUrl
:
string
;
config
:
Config
}
Returns
TContext
Optional
logout
logout
?
(
input
:
OAuthAuthenticatorLogoutInput
,
ctx
:
TContext
)
:
Promise
<
void
>
Parameters
input
:
OAuthAuthenticatorLogoutInput
ctx
:
TContext
Returns
Promise
<
void
>
refresh
refresh
(
input
:
OAuthAuthenticatorRefreshInput
,
ctx
:
TContext
,
)
:
Promise
<
OAuthAuthenticatorResult
<
TProfile
>
>
Parameters
input
:
OAuthAuthenticatorRefreshInput
ctx
:
TContext
Returns
Promise
<
OAuthAuthenticatorResult
<
TProfile
>
>
start
start
(
input
:
OAuthAuthenticatorStartInput
,
ctx
:
TContext
,
)
:
Promise
<
{
status
?:
number
;
url
:
string
}
>
Parameters
input
:
OAuthAuthenticatorStartInput
ctx
:
TContext
Returns
Promise
<
{
status
?:
number
;
url
:
string
}
>
Settings
Member Visibility
Protected
Inherited
External
Theme
OS
Light
Dark
On This Page
Properties
default
Profile
Transform
scopes
should
Persist
Scopes
Methods
authenticate
initialize
logout
refresh
start
Docs
Github
Backstage
Loading...
Deprecated
use
scopes.persistinstead