Skip to main content

GoogleParameters

@webda/google-auth


Class: GoogleParameters

Defined in: google-auth/src/google-auth.service.ts:34

Google login parameters https://developers.google.com/identity/protocols/oauth2/openid-connect

Extends​

  • OAuthProviderParameters

Constructors​

Constructor​

new GoogleParameters(): GoogleParameters

Returns​

GoogleParameters

Inherited from​

OAuthProviderParameters.constructor

Properties​

access_type?​

optional access_type?: "online" | "offline"

Defined in: google-auth/src/google-auth.service.ts:52

Type of access: "offline" also returns a refresh token (stored encrypted in the ident tokens)

Default​

"online"

allowedEmailDomains?​

optional allowedEmailDomains?: string[]

Defined in: auth/lib/oauth/oauth.service.d.ts:99

Only these email domains may use this provider (see ProviderEmailPolicy)

Inherited from​

OAuthProviderParameters.allowedEmailDomains


audiences?​

optional audiences?: string[]

Defined in: google-auth/src/google-auth.service.ts:57

Other client ids whose ID tokens Auth.Google.Token accepts (for example Android/iOS client ids)

Default​

[]

auth_options?​

optional auth_options?: Record<string, any>

Defined in: google-auth/src/google-auth.service.ts:68

Additional authorization url parameters (for example prompt, login_hint); cannot override state, redirect_uri, scope, access_type, response_type, code_challenge*, nonce nor hd See https://developers.google.com/identity/protocols/oauth2/openid-connect#authenticationuriparameters


authorized_uris?​

optional authorized_uris?: string[]

Defined in: auth/lib/oauth/oauth.service.d.ts:93

Allowed post-login targets for the redirect query parameter of the login route: absolute http(s) urls, a target matches when it has the same origin and its path is the listed path or below it

Default​

[]

Inherited from​

OAuthProviderParameters.authorized_uris


client_id​

client_id: string

Defined in: google-auth/src/google-auth.service.ts:38

Google OAuth client id (web application)

Overrides​

OAuthProviderParameters.client_id


client_secret​

client_secret: string

Defined in: google-auth/src/google-auth.service.ts:42

Google OAuth client secret

Overrides​

OAuthProviderParameters.client_secret


hostedDomain?​

optional hostedDomain?: string

Defined in: google-auth/src/google-auth.service.ts:62

Only accept Google Workspace accounts of this domain (the hd claim of the ID token); also sent as a hint to the account chooser


redirect_uri?​

optional redirect_uri?: string

Defined in: auth/lib/oauth/oauth.service.d.ts:87

Callback url registered at the provider

Default​

"<absolute url of the request>/callback"; set it explicitly behind a proxy

Inherited from​

OAuthProviderParameters.redirect_uri


redirects?​

optional redirects?: OAuthRedirects

Defined in: auth/lib/oauth/oauth.service.d.ts:97

Browser redirects of the callback

Inherited from​

OAuthProviderParameters.redirects


scope?​

optional scope?: string[]

Defined in: google-auth/src/google-auth.service.ts:47

Scopes requested from Google

Default​

["openid", "email", "profile"]

Overrides​

OAuthProviderParameters.scope


trustEmailVerification?​

optional trustEmailVerification?: boolean | string[]

Defined in: auth/lib/oauth/oauth.service.d.ts:101

Whether the verification of the email is believed (see ProviderEmailPolicy)

Inherited from​

OAuthProviderParameters.trustEmailVerification


type​

type: string

Defined in: core/lib/services/serviceparameters.d.ts:8

Type of the service

Inherited from​

OAuthProviderParameters.type


url?​

optional url?: string

Defined in: auth/lib/oauth/oauth.service.d.ts:70

Route prefix of the login (<url>) and callback (<url>/callback) routes

Default​

"/auth/<providerName>"

Inherited from​

OAuthProviderParameters.url

Methods​

load()​

load(params?): this

Defined in: google-auth/src/google-auth.service.ts:74

Parameters​

params?​

any = {}

raw parameters

Returns​

this

this

Overrides​

OAuthProviderParameters.load


update()​

update(params, delta): this

Defined in: core/lib/services/serviceparameters.d.ts:25

Update parameters and call watchers if a parameter was changed

Parameters​

params​

any

the service parameters

delta​

any

the delta

Returns​

this

this for chaining

Inherited from​

OAuthProviderParameters.update


with()​

with(callback): this

Defined in: core/lib/services/serviceparameters.d.ts:31

Watch for changes on the parameters and call watchers when a parameter is changed

Parameters​

callback​

(params) => void

the callback function

Returns​

this

this for chaining

Inherited from​

OAuthProviderParameters.with