@camera.ui/sdk / plugin / OAuthAuthCodeFlowCapable
Interface: OAuthAuthCodeFlowCapable
Defined in: plugin/oauth.ts:105
Implemented by plugins that use the Authorization Code Flow with PKCE. The host opens the auth URL and forwards the IdP redirect's code+state to completeAuthCodeFlow.
Extends
Methods
cancelAuthCodeFlow()
cancelAuthCodeFlow():
Promise<void>
Defined in: plugin/oauth.ts:111
Abort an in-progress authorization-code flow.
Returns
Promise<void>
completeAuthCodeFlow()
completeAuthCodeFlow(
code,state):Promise<OAuthState>
Defined in: plugin/oauth.ts:109
Exchange the IdP-returned code for tokens after validating state.
Parameters
code
string
state
string
Returns
Promise<OAuthState>
disconnect()
disconnect():
Promise<void>
Defined in: plugin/oauth.ts:85
Revoke the current grant at the IdP and clear stored tokens.
Returns
Promise<void>
Inherited from
getOAuthMetadata()
getOAuthMetadata():
Promise<OAuthMetadata>
Defined in: plugin/oauth.ts:81
Return IdP display info, scope descriptions and the implemented flow sub-interfaces.
Returns
Promise<OAuthMetadata>
Inherited from
getOAuthState()
getOAuthState():
Promise<OAuthState>
Defined in: plugin/oauth.ts:83
Return a snapshot of the current lifecycle state; the host polls this to mirror progress.
Returns
Promise<OAuthState>
Inherited from
startAuthCodeFlow()
startAuthCodeFlow(
scope):Promise<OAuthState>
Defined in: plugin/oauth.ts:107
Build the authorization URL for the given scopes; returns the awaiting-user state (authUrl set).
Parameters
scope
string[]
Returns
Promise<OAuthState>