googleapis
Version:
Google APIs Client Library for Node.js
1,248 lines (1,247 loc) • 296 kB
TypeScript
import { OAuth2Client, JWT, Compute, UserRefreshClient, BaseExternalAccountClient, GaxiosResponseWithHTTP2, GoogleConfigurable, MethodOptions, StreamMethodOptions, GlobalOptions, GoogleAuth, BodyResponseCallback, APIRequestContext } from 'googleapis-common';
import { Readable } from 'stream';
export declare namespace identitytoolkit_v2 {
export interface Options extends GlobalOptions {
version: 'v2';
}
interface StandardParameters {
/**
* Auth client or API Key for the request
*/
auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient | BaseExternalAccountClient | GoogleAuth;
/**
* V1 error format.
*/
'$.xgafv'?: string;
/**
* OAuth access token.
*/
access_token?: string;
/**
* Data format for response.
*/
alt?: string;
/**
* JSONP
*/
callback?: string;
/**
* Selector specifying which fields to include in a partial response.
*/
fields?: string;
/**
* API key. Your API key identifies your project and provides you with API access, quota, and reports. Required unless you provide an OAuth 2.0 token.
*/
key?: string;
/**
* OAuth 2.0 token for the current user.
*/
oauth_token?: string;
/**
* Returns response with indentations and line breaks.
*/
prettyPrint?: boolean;
/**
* Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters.
*/
quotaUser?: string;
/**
* Legacy upload protocol for media (e.g. "media", "multipart").
*/
uploadType?: string;
/**
* Upload protocol for media (e.g. "raw", "multipart").
*/
upload_protocol?: string;
}
/**
* Identity Toolkit API
*
* The Google Identity Toolkit API lets you use open standards to verify a user's identity.
*
* @example
* ```js
* const {google} = require('googleapis');
* const identitytoolkit = google.identitytoolkit('v2');
* ```
*/
export class Identitytoolkit {
context: APIRequestContext;
accounts: Resource$Accounts;
defaultSupportedIdps: Resource$Defaultsupportedidps;
projects: Resource$Projects;
v2: Resource$V2;
constructor(options: GlobalOptions, google?: GoogleConfigurable);
}
/**
* Defines a policy of allowing every region by default and adding disallowed regions to a disallow list.
*/
export interface Schema$GoogleCloudIdentitytoolkitAdminV2AllowByDefault {
/**
* Two letter unicode region codes to disallow as defined by https://cldr.unicode.org/ The full list of these region codes is here: https://github.com/unicode-cldr/cldr-localenames-full/blob/master/main/en/territories.json
*/
disallowedRegions?: string[] | null;
}
/**
* Defines a policy of only allowing regions by explicitly adding them to an allowlist.
*/
export interface Schema$GoogleCloudIdentitytoolkitAdminV2AllowlistOnly {
/**
* Two letter unicode region codes to allow as defined by https://cldr.unicode.org/ The full list of these region codes is here: https://github.com/unicode-cldr/cldr-localenames-full/blob/master/main/en/territories.json
*/
allowedRegions?: string[] | null;
}
/**
* Configuration options related to authenticating an anonymous user.
*/
export interface Schema$GoogleCloudIdentitytoolkitAdminV2Anonymous {
/**
* Whether anonymous user auth is enabled for the project or not.
*/
enabled?: boolean | null;
}
/**
* Additional config for SignInWithApple.
*/
export interface Schema$GoogleCloudIdentitytoolkitAdminV2AppleSignInConfig {
/**
* A list of Bundle ID's usable by this project
*/
bundleIds?: string[] | null;
/**
* Additional config for Apple for code flow.
*/
codeFlowConfig?: Schema$GoogleCloudIdentitytoolkitAdminV2CodeFlowConfig;
}
/**
* Configuration related to Blocking Functions.
*/
export interface Schema$GoogleCloudIdentitytoolkitAdminV2BlockingFunctionsConfig {
/**
* The user credentials to include in the JWT payload that is sent to the registered Blocking Functions.
*/
forwardInboundCredentials?: Schema$GoogleCloudIdentitytoolkitAdminV2ForwardInboundCredentials;
/**
* Map of Trigger to event type. Key should be one of the supported event types: "beforeCreate", "beforeSignIn"
*/
triggers?: {
[key: string]: Schema$GoogleCloudIdentitytoolkitAdminV2Trigger;
} | null;
}
/**
* Options related to how clients making requests on behalf of a project should be configured.
*/
export interface Schema$GoogleCloudIdentitytoolkitAdminV2ClientConfig {
/**
* Output only. API key that can be used when making requests for this project.
*/
apiKey?: string | null;
/**
* Output only. Firebase subdomain.
*/
firebaseSubdomain?: string | null;
/**
* Configuration related to restricting a user's ability to affect their account.
*/
permissions?: Schema$GoogleCloudIdentitytoolkitAdminV2Permissions;
}
/**
* Options related to how clients making requests on behalf of a tenant should be configured.
*/
export interface Schema$GoogleCloudIdentitytoolkitAdminV2ClientPermissionConfig {
/**
* Configuration related to restricting a user's ability to affect their account.
*/
permissions?: Schema$GoogleCloudIdentitytoolkitAdminV2ClientPermissions;
}
/**
* Configuration related to restricting a user's ability to affect their account.
*/
export interface Schema$GoogleCloudIdentitytoolkitAdminV2ClientPermissions {
/**
* When true, end users cannot delete their account on the associated project through any of our API methods
*/
disabledUserDeletion?: boolean | null;
/**
* When true, end users cannot sign up for a new account on the associated project through any of our API methods
*/
disabledUserSignup?: boolean | null;
}
/**
* Additional config for Apple for code flow.
*/
export interface Schema$GoogleCloudIdentitytoolkitAdminV2CodeFlowConfig {
/**
* Key ID for the private key.
*/
keyId?: string | null;
/**
* Private key used for signing the client secret JWT.
*/
privateKey?: string | null;
/**
* Apple Developer Team ID.
*/
teamId?: string | null;
}
/**
* Represents an Identity Toolkit project.
*/
export interface Schema$GoogleCloudIdentitytoolkitAdminV2Config {
/**
* List of domains authorized for OAuth redirects
*/
authorizedDomains?: string[] | null;
/**
* Whether anonymous users will be auto-deleted after a period of 30 days.
*/
autodeleteAnonymousUsers?: boolean | null;
/**
* Configuration related to blocking functions.
*/
blockingFunctions?: Schema$GoogleCloudIdentitytoolkitAdminV2BlockingFunctionsConfig;
/**
* Options related to how clients making requests on behalf of a project should be configured.
*/
client?: Schema$GoogleCloudIdentitytoolkitAdminV2ClientConfig;
/**
* Output only. Default Firebase hosting site name
*/
defaultHostingSite?: string | null;
/**
* Configuration for settings related to email privacy and public visibility.
*/
emailPrivacyConfig?: Schema$GoogleCloudIdentitytoolkitAdminV2EmailPrivacyConfig;
/**
* Configuration for this project's multi-factor authentication, including whether it is active and what factors can be used for the second factor
*/
mfa?: Schema$GoogleCloudIdentitytoolkitAdminV2MultiFactorAuthConfig;
/**
* Configuration for settings related to univeral links (iOS) and app links (Android).
*/
mobileLinksConfig?: Schema$GoogleCloudIdentitytoolkitAdminV2MobileLinksConfig;
/**
* Configuration related to monitoring project activity.
*/
monitoring?: Schema$GoogleCloudIdentitytoolkitAdminV2MonitoringConfig;
/**
* Configuration related to multi-tenant functionality.
*/
multiTenant?: Schema$GoogleCloudIdentitytoolkitAdminV2MultiTenantConfig;
/**
* Output only. The name of the Config resource. Example: "projects/my-awesome-project/config"
*/
name?: string | null;
/**
* Configuration related to sending notifications to users.
*/
notification?: Schema$GoogleCloudIdentitytoolkitAdminV2NotificationConfig;
/**
* The project level password policy configuration.
*/
passwordPolicyConfig?: Schema$GoogleCloudIdentitytoolkitAdminV2PasswordPolicyConfig;
/**
* Configuration related to quotas.
*/
quota?: Schema$GoogleCloudIdentitytoolkitAdminV2QuotaConfig;
/**
* The project-level reCAPTCHA config.
*/
recaptchaConfig?: Schema$GoogleCloudIdentitytoolkitAdminV2RecaptchaConfig;
/**
* Configuration related to local sign in methods.
*/
signIn?: Schema$GoogleCloudIdentitytoolkitAdminV2SignInConfig;
/**
* Configures which regions are enabled for SMS verification code sending.
*/
smsRegionConfig?: Schema$GoogleCloudIdentitytoolkitAdminV2SmsRegionConfig;
/**
* Output only. The subtype of this config.
*/
subtype?: string | null;
}
/**
* Custom strength options to enforce on user passwords.
*/
export interface Schema$GoogleCloudIdentitytoolkitAdminV2CustomStrengthOptions {
/**
* The password must contain a lower case character.
*/
containsLowercaseCharacter?: boolean | null;
/**
* The password must contain a non alpha numeric character.
*/
containsNonAlphanumericCharacter?: boolean | null;
/**
* The password must contain a number.
*/
containsNumericCharacter?: boolean | null;
/**
* The password must contain an upper case character.
*/
containsUppercaseCharacter?: boolean | null;
/**
* Maximum password length. No default max length
*/
maxPasswordLength?: number | null;
/**
* Minimum password length. Range from 6 to 30
*/
minPasswordLength?: number | null;
}
/**
* Standard Identity Toolkit-trusted IDPs.
*/
export interface Schema$GoogleCloudIdentitytoolkitAdminV2DefaultSupportedIdp {
/**
* Description of the Idp
*/
description?: string | null;
/**
* Id the of Idp
*/
idpId?: string | null;
}
/**
* Configurations options for authenticating with a the standard set of Identity Toolkit-trusted IDPs.
*/
export interface Schema$GoogleCloudIdentitytoolkitAdminV2DefaultSupportedIdpConfig {
/**
* Additional config for Apple-based projects.
*/
appleSignInConfig?: Schema$GoogleCloudIdentitytoolkitAdminV2AppleSignInConfig;
/**
* OAuth client ID.
*/
clientId?: string | null;
/**
* OAuth client secret.
*/
clientSecret?: string | null;
/**
* True if allows the user to sign in with the provider.
*/
enabled?: boolean | null;
/**
* The name of the DefaultSupportedIdpConfig resource, for example: "projects/my-awesome-project/defaultSupportedIdpConfigs/google.com"
*/
name?: string | null;
}
/**
* Information of custom domain DNS verification. By default, default_domain will be used. A custom domain can be configured using VerifyCustomDomain.
*/
export interface Schema$GoogleCloudIdentitytoolkitAdminV2DnsInfo {
/**
* Output only. The applied verified custom domain.
*/
customDomain?: string | null;
/**
* Output only. The current verification state of the custom domain. The custom domain will only be used once the domain verification is successful.
*/
customDomainState?: string | null;
/**
* Output only. The timestamp of initial request for the current domain verification.
*/
domainVerificationRequestTime?: string | null;
/**
* Output only. The custom domain that's to be verified.
*/
pendingCustomDomain?: string | null;
/**
* Whether to use custom domain.
*/
useCustomDomain?: boolean | null;
}
/**
* Configuration options related to authenticating a user by their email address.
*/
export interface Schema$GoogleCloudIdentitytoolkitAdminV2Email {
/**
* Whether email auth is enabled for the project or not.
*/
enabled?: boolean | null;
/**
* Whether a password is required for email auth or not. If true, both an email and password must be provided to sign in. If false, a user may sign in via either email/password or email link.
*/
passwordRequired?: boolean | null;
}
/**
* Configuration for settings related to email privacy and public visibility. Settings in this config protect against email enumeration, but may make some trade-offs in user-friendliness.
*/
export interface Schema$GoogleCloudIdentitytoolkitAdminV2EmailPrivacyConfig {
/**
* Migrates the project to a state of improved email privacy. For example certain error codes are more generic to avoid giving away information on whether the account exists. In addition, this disables certain features that as a side-effect allow user enumeration. Enabling this toggle disables the fetchSignInMethodsForEmail functionality and changing the user's email to an unverified email. It is recommended to remove dependence on this functionality and enable this toggle to improve user privacy.
*/
enableImprovedEmailPrivacy?: boolean | null;
}
/**
* Email template. The subject and body fields can contain the following placeholders which will be replaced with the appropriate values: %LINK% - The link to use to redeem the send OOB code. %EMAIL% - The email where the email is being sent. %NEW_EMAIL% - The new email being set for the account (when applicable). %APP_NAME% - The Google Cloud project's display name. %DISPLAY_NAME% - The user's display name.
*/
export interface Schema$GoogleCloudIdentitytoolkitAdminV2EmailTemplate {
/**
* Email body
*/
body?: string | null;
/**
* Email body format
*/
bodyFormat?: string | null;
/**
* Output only. Whether the body or subject of the email is customized.
*/
customized?: boolean | null;
/**
* Reply-to address
*/
replyTo?: string | null;
/**
* Sender display name
*/
senderDisplayName?: string | null;
/**
* Local part of From address
*/
senderLocalPart?: string | null;
/**
* Subject of the email
*/
subject?: string | null;
}
/**
* Indicates which credentials to pass to the registered Blocking Functions.
*/
export interface Schema$GoogleCloudIdentitytoolkitAdminV2ForwardInboundCredentials {
/**
* Whether to pass the user's OAuth identity provider's access token.
*/
accessToken?: boolean | null;
/**
* Whether to pass the user's OIDC identity provider's ID token.
*/
idToken?: boolean | null;
/**
* Whether to pass the user's OAuth identity provider's refresh token.
*/
refreshToken?: boolean | null;
}
/**
* History information of the hash algorithm and key. Different accounts' passwords may be generated by different version.
*/
export interface Schema$GoogleCloudIdentitytoolkitAdminV2HashConfig {
/**
* Output only. Different password hash algorithms used in Identity Toolkit.
*/
algorithm?: string | null;
/**
* Output only. Memory cost for hash calculation. Used by scrypt and other similar password derivation algorithms. See https://tools.ietf.org/html/rfc7914 for explanation of field.
*/
memoryCost?: number | null;
/**
* Output only. How many rounds for hash calculation. Used by scrypt and other similar password derivation algorithms.
*/
rounds?: number | null;
/**
* Output only. Non-printable character to be inserted between the salt and plain text password in base64.
*/
saltSeparator?: string | null;
/**
* Output only. Signer key in base64.
*/
signerKey?: string | null;
}
/**
* The IDP's certificate data to verify the signature in the SAMLResponse issued by the IDP.
*/
export interface Schema$GoogleCloudIdentitytoolkitAdminV2IdpCertificate {
/**
* The x509 certificate
*/
x509Certificate?: string | null;
}
/**
* The SAML IdP (Identity Provider) configuration when the project acts as the relying party.
*/
export interface Schema$GoogleCloudIdentitytoolkitAdminV2IdpConfig {
/**
* IDP's public keys for verifying signature in the assertions.
*/
idpCertificates?: Schema$GoogleCloudIdentitytoolkitAdminV2IdpCertificate[];
/**
* Unique identifier for all SAML entities.
*/
idpEntityId?: string | null;
/**
* Indicates if outbounding SAMLRequest should be signed.
*/
signRequest?: boolean | null;
/**
* URL to send Authentication request to.
*/
ssoUrl?: string | null;
}
/**
* A pair of SAML RP-IDP configurations when the project acts as the relying party.
*/
export interface Schema$GoogleCloudIdentitytoolkitAdminV2InboundSamlConfig {
/**
* The config's display name set by developers.
*/
displayName?: string | null;
/**
* True if allows the user to sign in with the provider.
*/
enabled?: boolean | null;
/**
* The SAML IdP (Identity Provider) configuration when the project acts as the relying party.
*/
idpConfig?: Schema$GoogleCloudIdentitytoolkitAdminV2IdpConfig;
/**
* The name of the InboundSamlConfig resource, for example: 'projects/my-awesome-project/inboundSamlConfigs/my-config-id'. Ignored during create requests.
*/
name?: string | null;
/**
* The SAML SP (Service Provider) configuration when the project acts as the relying party to receive and accept an authentication assertion issued by a SAML identity provider.
*/
spConfig?: Schema$GoogleCloudIdentitytoolkitAdminV2SpConfig;
}
/**
* Settings that the tenants will inherit from project level.
*/
export interface Schema$GoogleCloudIdentitytoolkitAdminV2Inheritance {
/**
* Whether to allow the tenant to inherit custom domains, email templates, and custom SMTP settings. If true, email sent from tenant will follow the project level email sending configurations. If false (by default), emails will go with the default settings with no customizations.
*/
emailSendingConfig?: boolean | null;
}
/**
* Request for InitializeIdentityPlatform.
*/
export interface Schema$GoogleCloudIdentitytoolkitAdminV2InitializeIdentityPlatformRequest {
}
/**
* Response for InitializeIdentityPlatform. Empty for now.
*/
export interface Schema$GoogleCloudIdentitytoolkitAdminV2InitializeIdentityPlatformResponse {
}
/**
* Response for DefaultSupportedIdpConfigs
*/
export interface Schema$GoogleCloudIdentitytoolkitAdminV2ListDefaultSupportedIdpConfigsResponse {
/**
* The set of configs.
*/
defaultSupportedIdpConfigs?: Schema$GoogleCloudIdentitytoolkitAdminV2DefaultSupportedIdpConfig[];
/**
* Token to retrieve the next page of results, or empty if there are no more results in the list.
*/
nextPageToken?: string | null;
}
/**
* Response for ListDefaultSupportedIdps
*/
export interface Schema$GoogleCloudIdentitytoolkitAdminV2ListDefaultSupportedIdpsResponse {
/**
* The set of configs.
*/
defaultSupportedIdps?: Schema$GoogleCloudIdentitytoolkitAdminV2DefaultSupportedIdp[];
/**
* Token to retrieve the next page of results, or empty if there are no more results in the list.
*/
nextPageToken?: string | null;
}
/**
* Response for ListInboundSamlConfigs
*/
export interface Schema$GoogleCloudIdentitytoolkitAdminV2ListInboundSamlConfigsResponse {
/**
* The set of configs.
*/
inboundSamlConfigs?: Schema$GoogleCloudIdentitytoolkitAdminV2InboundSamlConfig[];
/**
* Token to retrieve the next page of results, or empty if there are no more results in the list.
*/
nextPageToken?: string | null;
}
/**
* Response for ListOAuthIdpConfigs
*/
export interface Schema$GoogleCloudIdentitytoolkitAdminV2ListOAuthIdpConfigsResponse {
/**
* Token to retrieve the next page of results, or empty if there are no more results in the list.
*/
nextPageToken?: string | null;
/**
* The set of configs.
*/
oauthIdpConfigs?: Schema$GoogleCloudIdentitytoolkitAdminV2OAuthIdpConfig[];
}
/**
* Response message for ListTenants.
*/
export interface Schema$GoogleCloudIdentitytoolkitAdminV2ListTenantsResponse {
/**
* The token to get the next page of results.
*/
nextPageToken?: string | null;
/**
* A list of tenants under the given agent project.
*/
tenants?: Schema$GoogleCloudIdentitytoolkitAdminV2Tenant[];
}
/**
* Configuration mobile links.
*/
export interface Schema$GoogleCloudIdentitytoolkitAdminV2MobileLinksConfig {
/**
* Open code in app domain to use for app links and universal links.
*/
domain?: string | null;
}
/**
* Configuration related to monitoring project activity.
*/
export interface Schema$GoogleCloudIdentitytoolkitAdminV2MonitoringConfig {
/**
* Configuration for logging requests made to this project to Stackdriver Logging
*/
requestLogging?: Schema$GoogleCloudIdentitytoolkitAdminV2RequestLogging;
}
/**
* Options related to MultiFactor Authentication for the project.
*/
export interface Schema$GoogleCloudIdentitytoolkitAdminV2MultiFactorAuthConfig {
/**
* A list of usable second factors for this project.
*/
enabledProviders?: string[] | null;
/**
* A list of usable second factors for this project along with their configurations. This field does not support phone based MFA, for that use the 'enabled_providers' field.
*/
providerConfigs?: Schema$GoogleCloudIdentitytoolkitAdminV2ProviderConfig[];
/**
* Whether MultiFactor Authentication has been enabled for this project.
*/
state?: string | null;
}
/**
* Configuration related to multi-tenant functionality.
*/
export interface Schema$GoogleCloudIdentitytoolkitAdminV2MultiTenantConfig {
/**
* Whether this project can have tenants or not.
*/
allowTenants?: boolean | null;
/**
* The default cloud parent org or folder that the tenant project should be created under. The parent resource name should be in the format of "/", such as "folders/123" or "organizations/456". If the value is not set, the tenant will be created under the same organization or folder as the agent project.
*/
defaultTenantLocation?: string | null;
}
/**
* Configuration related to sending notifications to users.
*/
export interface Schema$GoogleCloudIdentitytoolkitAdminV2NotificationConfig {
/**
* Default locale used for email and SMS in IETF BCP 47 format.
*/
defaultLocale?: string | null;
/**
* Options for email sending.
*/
sendEmail?: Schema$GoogleCloudIdentitytoolkitAdminV2SendEmail;
/**
* Options for SMS sending.
*/
sendSms?: Schema$GoogleCloudIdentitytoolkitAdminV2SendSms;
}
/**
* Configuration options for authenticating with an OAuth IDP.
*/
export interface Schema$GoogleCloudIdentitytoolkitAdminV2OAuthIdpConfig {
/**
* The client id of an OAuth client.
*/
clientId?: string | null;
/**
* The client secret of the OAuth client, to enable OIDC code flow.
*/
clientSecret?: string | null;
/**
* The config's display name set by developers.
*/
displayName?: string | null;
/**
* True if allows the user to sign in with the provider.
*/
enabled?: boolean | null;
/**
* For OIDC Idps, the issuer identifier.
*/
issuer?: string | null;
/**
* The name of the OAuthIdpConfig resource, for example: 'projects/my-awesome-project/oauthIdpConfigs/oauth-config-id'. Ignored during create requests.
*/
name?: string | null;
/**
* The response type to request for in the OAuth authorization flow. You can set either `id_token` or `code` to true, but not both. Setting both types to be simultaneously true (`{code: true, id_token: true\}`) is not yet supported.
*/
responseType?: Schema$GoogleCloudIdentitytoolkitAdminV2OAuthResponseType;
}
/**
* The response type to request for in the OAuth authorization flow. You can set either `id_token` or `code` to true, but not both. Setting both types to be simultaneously true (`{code: true, id_token: true\}`) is not yet supported. See https://openid.net/specs/openid-connect-core-1_0.html#Authentication for a mapping of response type to OAuth 2.0 flow.
*/
export interface Schema$GoogleCloudIdentitytoolkitAdminV2OAuthResponseType {
/**
* If true, authorization code is returned from IdP's authorization endpoint.
*/
code?: boolean | null;
/**
* If true, ID token is returned from IdP's authorization endpoint.
*/
idToken?: boolean | null;
/**
* Do not use. The `token` response type is not supported at the moment.
*/
token?: boolean | null;
}
/**
* The configuration for the password policy on the project.
*/
export interface Schema$GoogleCloudIdentitytoolkitAdminV2PasswordPolicyConfig {
/**
* Users must have a password compliant with the password policy to sign-in.
*/
forceUpgradeOnSignin?: boolean | null;
/**
* Output only. The last time the password policy on the project was updated.
*/
lastUpdateTime?: string | null;
/**
* Which enforcement mode to use for the password policy.
*/
passwordPolicyEnforcementState?: string | null;
/**
* Must be of length 1. Contains the strength attributes for the password policy.
*/
passwordPolicyVersions?: Schema$GoogleCloudIdentitytoolkitAdminV2PasswordPolicyVersion[];
}
/**
* The strength attributes for the password policy on the project.
*/
export interface Schema$GoogleCloudIdentitytoolkitAdminV2PasswordPolicyVersion {
/**
* The custom strength options enforced by the password policy.
*/
customStrengthOptions?: Schema$GoogleCloudIdentitytoolkitAdminV2CustomStrengthOptions;
/**
* Output only. schema version number for the password policy
*/
schemaVersion?: number | null;
}
/**
* Configuration related to restricting a user's ability to affect their account.
*/
export interface Schema$GoogleCloudIdentitytoolkitAdminV2Permissions {
/**
* When true, end users cannot delete their account on the associated project through any of our API methods
*/
disabledUserDeletion?: boolean | null;
/**
* When true, end users cannot sign up for a new account on the associated project through any of our API methods
*/
disabledUserSignup?: boolean | null;
}
/**
* Configuration options related to authenticated a user by their phone number.
*/
export interface Schema$GoogleCloudIdentitytoolkitAdminV2PhoneNumber {
/**
* Whether phone number auth is enabled for the project or not.
*/
enabled?: boolean | null;
/**
* A map of that can be used for phone auth testing.
*/
testPhoneNumbers?: {
[key: string]: string;
} | null;
}
/**
* ProviderConfig describes the supported MFA providers along with their configurations.
*/
export interface Schema$GoogleCloudIdentitytoolkitAdminV2ProviderConfig {
/**
* Describes the state of the MultiFactor Authentication type.
*/
state?: string | null;
/**
* TOTP MFA provider config for this project.
*/
totpProviderConfig?: Schema$GoogleCloudIdentitytoolkitAdminV2TotpMfaProviderConfig;
}
/**
* Configuration related to quotas.
*/
export interface Schema$GoogleCloudIdentitytoolkitAdminV2QuotaConfig {
/**
* Quota for the Signup endpoint, if overwritten. Signup quota is measured in sign ups per project per hour per IP.
*/
signUpQuotaConfig?: Schema$GoogleCloudIdentitytoolkitAdminV2TemporaryQuota;
}
/**
* The reCAPTCHA Enterprise integration config.
*/
export interface Schema$GoogleCloudIdentitytoolkitAdminV2RecaptchaConfig {
/**
* The reCAPTCHA config for email/password provider, containing the enforcement status. The email/password provider contains all email related user flows protected by reCAPTCHA.
*/
emailPasswordEnforcementState?: string | null;
/**
* The managed rules for authentication action based on reCAPTCHA scores. The rules are shared across providers for a given tenant project.
*/
managedRules?: Schema$GoogleCloudIdentitytoolkitAdminV2RecaptchaManagedRule[];
/**
* The reCAPTCHA config for phone provider, containing the enforcement status. The phone provider contains all SMS related user flows protected by reCAPTCHA.
*/
phoneEnforcementState?: string | null;
/**
* The reCAPTCHA keys.
*/
recaptchaKeys?: Schema$GoogleCloudIdentitytoolkitAdminV2RecaptchaKey[];
/**
* The managed rules for the authentication action based on reCAPTCHA toll fraud risk scores. Toll fraud managed rules will only take effect when the phone_enforcement_state is AUDIT or ENFORCE and use_sms_toll_fraud_protection is true.
*/
tollFraudManagedRules?: Schema$GoogleCloudIdentitytoolkitAdminV2RecaptchaTollFraudManagedRule[];
/**
* Whether to use the account defender for reCAPTCHA assessment. Defaults to `false`.
*/
useAccountDefender?: boolean | null;
/**
* Whether to use the rCE bot score for reCAPTCHA phone provider. Can only be true when the phone_enforcement_state is AUDIT or ENFORCE.
*/
useSmsBotScore?: boolean | null;
/**
* Whether to use the rCE sms toll fraud protection risk score for reCAPTCHA phone provider. Can only be true when the phone_enforcement_state is AUDIT or ENFORCE.
*/
useSmsTollFraudProtection?: boolean | null;
}
/**
* The reCAPTCHA key config. reCAPTCHA Enterprise offers different keys for different client platforms.
*/
export interface Schema$GoogleCloudIdentitytoolkitAdminV2RecaptchaKey {
/**
* The reCAPTCHA Enterprise key resource name, e.g. "projects/{project\}/keys/{key\}"
*/
key?: string | null;
/**
* The client's platform type.
*/
type?: string | null;
}
/**
* The config for a reCAPTCHA managed rule. Models a single interval [start_score, end_score]. The start_score is implicit. It is either the closest smaller end_score (if one is available) or 0. Intervals in aggregate span [0, 1] without overlapping.
*/
export interface Schema$GoogleCloudIdentitytoolkitAdminV2RecaptchaManagedRule {
/**
* The action taken if the reCAPTCHA score of a request is within the interval [start_score, end_score].
*/
action?: string | null;
/**
* The end score (inclusive) of the score range for an action. Must be a value between 0.0 and 1.0, at 11 discrete values; e.g. 0, 0.1, 0.2, 0.3, ... 0.9, 1.0. A score of 0.0 indicates the riskiest request (likely a bot), whereas 1.0 indicates the safest request (likely a human). See https://cloud.google.com/recaptcha-enterprise/docs/interpret-assessment.
*/
endScore?: number | null;
}
/**
* The config for a reCAPTCHA toll fraud assessment managed rule. Models a single interval [start_score, end_score]. The end_score is implicit. It is either the closest smaller end_score (if one is available) or 0. Intervals in aggregate span [0, 1] without overlapping.
*/
export interface Schema$GoogleCloudIdentitytoolkitAdminV2RecaptchaTollFraudManagedRule {
/**
* The action taken if the reCAPTCHA score of a request is within the interval [start_score, end_score].
*/
action?: string | null;
/**
* The start score (inclusive) for an action. Must be a value between 0.0 and 1.0, at 11 discrete values; e.g. 0, 0.1, 0.2, 0.3, ... 0.9, 1.0. A score of 0.0 indicates the safest request (likely legitimate), whereas 1.0 indicates the riskiest request (likely toll fraud). See https://cloud.google.com/recaptcha-enterprise/docs/sms-fraud-detection#create-assessment-sms.
*/
startScore?: number | null;
}
/**
* Configuration for logging requests made to this project to Stackdriver Logging
*/
export interface Schema$GoogleCloudIdentitytoolkitAdminV2RequestLogging {
/**
* Whether logging is enabled for this project or not.
*/
enabled?: boolean | null;
}
/**
* Options for email sending.
*/
export interface Schema$GoogleCloudIdentitytoolkitAdminV2SendEmail {
/**
* action url in email template.
*/
callbackUri?: string | null;
/**
* Email template for change email
*/
changeEmailTemplate?: Schema$GoogleCloudIdentitytoolkitAdminV2EmailTemplate;
/**
* Information of custom domain DNS verification.
*/
dnsInfo?: Schema$GoogleCloudIdentitytoolkitAdminV2DnsInfo;
/**
* Reset password email template for legacy Firebase V1 app.
*/
legacyResetPasswordTemplate?: Schema$GoogleCloudIdentitytoolkitAdminV2EmailTemplate;
/**
* The method used for sending an email.
*/
method?: string | null;
/**
* Email template for reset password
*/
resetPasswordTemplate?: Schema$GoogleCloudIdentitytoolkitAdminV2EmailTemplate;
/**
* Email template for reverting second factor addition emails
*/
revertSecondFactorAdditionTemplate?: Schema$GoogleCloudIdentitytoolkitAdminV2EmailTemplate;
/**
* Use a custom SMTP relay
*/
smtp?: Schema$GoogleCloudIdentitytoolkitAdminV2Smtp;
/**
* Email template for verify email
*/
verifyEmailTemplate?: Schema$GoogleCloudIdentitytoolkitAdminV2EmailTemplate;
}
/**
* Options for SMS sending.
*/
export interface Schema$GoogleCloudIdentitytoolkitAdminV2SendSms {
/**
* Output only. The template to use when sending an SMS.
*/
smsTemplate?: Schema$GoogleCloudIdentitytoolkitAdminV2SmsTemplate;
/**
* Whether to use the accept_language header for SMS.
*/
useDeviceLocale?: boolean | null;
}
/**
* Configuration related to local sign in methods.
*/
export interface Schema$GoogleCloudIdentitytoolkitAdminV2SignInConfig {
/**
* Whether to allow more than one account to have the same email.
*/
allowDuplicateEmails?: boolean | null;
/**
* Configuration options related to authenticating an anonymous user.
*/
anonymous?: Schema$GoogleCloudIdentitytoolkitAdminV2Anonymous;
/**
* Configuration options related to authenticating a user by their email address.
*/
email?: Schema$GoogleCloudIdentitytoolkitAdminV2Email;
/**
* Output only. Hash config information.
*/
hashConfig?: Schema$GoogleCloudIdentitytoolkitAdminV2HashConfig;
/**
* Configuration options related to authenticated a user by their phone number.
*/
phoneNumber?: Schema$GoogleCloudIdentitytoolkitAdminV2PhoneNumber;
}
/**
* Configures the regions where users are allowed to send verification SMS for the project or tenant. This is based on the calling code of the destination phone number.
*/
export interface Schema$GoogleCloudIdentitytoolkitAdminV2SmsRegionConfig {
/**
* A policy of allowing SMS to every region by default and adding disallowed regions to a disallow list.
*/
allowByDefault?: Schema$GoogleCloudIdentitytoolkitAdminV2AllowByDefault;
/**
* A policy of only allowing regions by explicitly adding them to an allowlist.
*/
allowlistOnly?: Schema$GoogleCloudIdentitytoolkitAdminV2AllowlistOnly;
}
/**
* The template to use when sending an SMS.
*/
export interface Schema$GoogleCloudIdentitytoolkitAdminV2SmsTemplate {
/**
* Output only. The SMS's content. Can contain the following placeholders which will be replaced with the appropriate values: %APP_NAME% - For Android or iOS apps, the app's display name. For web apps, the domain hosting the application. %LOGIN_CODE% - The OOB code being sent in the SMS.
*/
content?: string | null;
}
/**
* Configuration for SMTP relay
*/
export interface Schema$GoogleCloudIdentitytoolkitAdminV2Smtp {
/**
* SMTP relay host
*/
host?: string | null;
/**
* SMTP relay password
*/
password?: string | null;
/**
* SMTP relay port
*/
port?: number | null;
/**
* SMTP security mode.
*/
securityMode?: string | null;
/**
* Sender email for the SMTP relay
*/
senderEmail?: string | null;
/**
* SMTP relay username
*/
username?: string | null;
}
/**
* The SP's certificate data for IDP to verify the SAMLRequest generated by the SP.
*/
export interface Schema$GoogleCloudIdentitytoolkitAdminV2SpCertificate {
/**
* Timestamp of the cert expiration instance.
*/
expiresAt?: string | null;
/**
* Self-signed public certificate.
*/
x509Certificate?: string | null;
}
/**
* The SAML SP (Service Provider) configuration when the project acts as the relying party to receive and accept an authentication assertion issued by a SAML identity provider.
*/
export interface Schema$GoogleCloudIdentitytoolkitAdminV2SpConfig {
/**
* Callback URI where responses from IDP are handled.
*/
callbackUri?: string | null;
/**
* Output only. Public certificates generated by the server to verify the signature in SAMLRequest in the SP-initiated flow.
*/
spCertificates?: Schema$GoogleCloudIdentitytoolkitAdminV2SpCertificate[];
/**
* Unique identifier for all SAML entities.
*/
spEntityId?: string | null;
}
/**
* Temporary quota increase / decrease
*/
export interface Schema$GoogleCloudIdentitytoolkitAdminV2TemporaryQuota {
/**
* Corresponds to the 'refill_token_count' field in QuotaServer config
*/
quota?: string | null;
/**
* How long this quota will be active for
*/
quotaDuration?: string | null;
/**
* When this quota will take effect
*/
startTime?: string | null;
}
/**
* A Tenant contains configuration for the tenant in a multi-tenant project.
*/
export interface Schema$GoogleCloudIdentitytoolkitAdminV2Tenant {
/**
* Whether to allow email/password user authentication.
*/
allowPasswordSignup?: boolean | null;
/**
* Whether anonymous users will be auto-deleted after a period of 30 days.
*/
autodeleteAnonymousUsers?: boolean | null;
/**
* Options related to how clients making requests on behalf of a project should be configured.
*/
client?: Schema$GoogleCloudIdentitytoolkitAdminV2ClientPermissionConfig;
/**
* Whether authentication is disabled for the tenant. If true, the users under the disabled tenant are not allowed to sign-in. Admins of the disabled tenant are not able to manage its users.
*/
disableAuth?: boolean | null;
/**
* Display name of the tenant.
*/
displayName?: string | null;
/**
* Configuration for settings related to email privacy and public visibility.
*/
emailPrivacyConfig?: Schema$GoogleCloudIdentitytoolkitAdminV2EmailPrivacyConfig;
/**
* Whether to enable anonymous user authentication.
*/
enableAnonymousUser?: boolean | null;
/**
* Whether to enable email link user authentication.
*/
enableEmailLinkSignin?: boolean | null;
/**
* Output only. Hash config information of a tenant for display on Pantheon. This can only be displayed on Pantheon to avoid the sensitive information to get accidentally leaked. Only returned in GetTenant response to restrict reading of this information. Requires firebaseauth.configs.getHashConfig permission on the agent project for returning this field.
*/
hashConfig?: Schema$GoogleCloudIdentitytoolkitAdminV2HashConfig;
/**
* Specify the settings that the tenant could inherit.
*/
inheritance?: Schema$GoogleCloudIdentitytoolkitAdminV2Inheritance;
/**
* The tenant-level configuration of MFA options.
*/
mfaConfig?: Schema$GoogleCloudIdentitytoolkitAdminV2MultiFactorAuthConfig;
/**
* Optional. Deprecated. Never launched. Configuration for settings related to univeral links (iOS) and app links (Android).
*/
mobileLinksConfig?: Schema$GoogleCloudIdentitytoolkitAdminV2MobileLinksConfig;
/**
* Configuration related to monitoring project activity.
*/
monitoring?: Schema$GoogleCloudIdentitytoolkitAdminV2MonitoringConfig;
/**
* Output only. Resource name of a tenant. For example: "projects/{project-id\}/tenants/{tenant-id\}"
*/
name?: string | null;
/**
* The tenant-level password policy config
*/
passwordPolicyConfig?: Schema$GoogleCloudIdentitytoolkitAdminV2PasswordPolicyConfig;
/**
* The tenant-level reCAPTCHA config.
*/
recaptchaConfig?: Schema$GoogleCloudIdentitytoolkitAdminV2RecaptchaConfig;
/**
* Configures which regions are enabled for SMS verification code sending.
*/
smsRegionConfig?: Schema$GoogleCloudIdentitytoolkitAdminV2SmsRegionConfig;
/**
* A map of pairs that can be used for MFA. The phone number should be in E.164 format (https://www.itu.int/rec/T-REC-E.164/) and a maximum of 10 pairs can be added (error will be thrown once exceeded).
*/
testPhoneNumbers?: {
[key: string]: string;
} | null;
}
/**
* TotpMFAProviderConfig represents the TOTP based MFA provider.
*/
export interface Schema$GoogleCloudIdentitytoolkitAdminV2TotpMfaProviderConfig {
/**
* The allowed number of adjacent intervals that will be used for verification to avoid clock skew.
*/
adjacentIntervals?: number | null;
}
/**
* Synchronous Cloud Function with HTTP Trigger
*/
export interface Schema$GoogleCloudIdentitytoolkitAdminV2Trigger {
/**
* HTTP URI trigger for the Cloud Function.
*/
functionUri?: string | null;
/**
* When the trigger was changed.
*/
updateTime?: string | null;
}
/**
* The information required to auto-retrieve an SMS.
*/
export interface Schema$GoogleCloudIdentitytoolkitV2AutoRetrievalInfo {
/**
* The Android app's signature hash for Google Play Service's SMS Retriever API.
*/
appSignatureHash?: string | null;
}
/**
* Custom strength options to enforce on user passwords.
*/
export interface Schema$GoogleCloudIdentitytoolkitV2CustomStrengthOptions {
/**
* The password must contain a lower case character.
*/
containsLowercaseCharacter?: boolean | null;
/**
* The password must contain a non alpha numeric character.
*/
containsNonAlphanumericCharacter?: boolean | null;
/**
* The password must contain a number.
*/
containsNumericCharacter?: boolean | null;
/**
* The password must contain an upper case character.
*/
containsUppercaseCharacter?: boolean | null;
/**
* Maximum password length. No default max length
*/
maxPasswordLength?: number | null;
/**
* Minimum password length. Range from 6 to 30
*/
minPasswordLength?: number | null;
}
/**
* Finishes enrolling a second factor for the user.
*/
export interface Schema$GoogleCloudIdentitytoolkitV2FinalizeMfaEnrollmentRequest {
/**
* Display name which is entered by users to distinguish between different second factors with same type or different type.
*/
displayName?: string | null;
/**
* Required. ID token.
*/
idToken?: string | null;
/**
* Verification info to authorize sending an SMS for phone verification.
*/
phoneVerificationInfo?: Schema$GoogleCloudIdentitytoolkitV2FinalizeMfaPhoneRequestInfo;
/**
* The ID of the Identity Platform tenant that the user enrolling MFA belongs to. If not set, the user belongs to the default Identity Platform project.
*/
tenantId?: string | null;
/**
* Verification information for TOTP.
*/
totpVerificationInfo?: Schema$GoogleCloudIdentitytoolkitV2FinalizeMfaTotpEnrollmentRequestInfo;
}
/**
* FinalizeMfaEnrollment response.
*/
export interface Schema$GoogleCloudIdentitytoolkitV2FinalizeMfaEnrollmentResponse {
/**
* ID token updated to reflect MFA enrollment.
*/
idToken?: string | null;
/**
* Auxiliary auth info specific to phone auth.
*/
phoneAuthInfo?: Schema$GoogleCloudIdentitytoolkitV2FinalizeMfaPhoneResponseInfo;
/**
* Refresh token updated to reflect MFA enrollment.
*/
refreshToken?: string | null;
/**
* Auxiliary auth info specific to TOTP auth.
*/
totpAuthInfo?: Schema$GoogleCloudIdentitytoolkitV2FinalizeMfaTotpEnrollmentResponseInfo;
}
/**
* Phone Verification info for a FinalizeMfa request.
*/
export interface Schema$GoogleCloudIdentitytoolkitV2FinalizeMfaPhoneRequestInfo {
/**
* Android only. Uses for "instant" phone number verification though GmsCore.
*/
androidVerificationProof?: string | null;
/**
* User-entered verification code.