@@ -1451,3 +1451,68 @@ export class OIDCConfig implements OIDCAuthProviderConfig {
1451
1451
} ;
1452
1452
}
1453
1453
}
1454
+
1455
+ /**
1456
+ * Enforcement state of reCAPTCHA protection.
1457
+ * - 'OFF': Unenforced.
1458
+ * - 'AUDIT': Assessment is created but result is not used to enforce.
1459
+ * - 'ENFORCE': Assessment is created and result is used to enforce.
1460
+ */
1461
+ export type RecaptchaProviderEnforcementState = 'OFF' | 'AUDIT' | 'ENFORCE' ;
1462
+
1463
+ /**
1464
+ * The actions for reCAPTCHA-protected requests.
1465
+ * - 'BLOCK': The reCAPTCHA-protected request will be blocked.
1466
+ */
1467
+ export type RecaptchaAction = 'BLOCK' ;
1468
+
1469
+ /**
1470
+ * The config for a reCAPTCHA action rule.
1471
+ */
1472
+ export interface RecaptchaManagedRule {
1473
+ /**
1474
+ * The action will be enforced if the reCAPTCHA score of a request is larger than endScore.
1475
+ */
1476
+ endScore : number ;
1477
+ /**
1478
+ * The action for reCAPTCHA-protected requests.
1479
+ */
1480
+ action ?: RecaptchaAction ;
1481
+ }
1482
+
1483
+ /**
1484
+ * The key's platform type: only web supported now.
1485
+ */
1486
+ export type RecaptchaKeyClientType = 'WEB' ;
1487
+
1488
+ /**
1489
+ * The reCAPTCHA key config.
1490
+ */
1491
+ export interface RecaptchaKey {
1492
+ /**
1493
+ * The key's client platform type.
1494
+ */
1495
+ type ?: RecaptchaKeyClientType ;
1496
+
1497
+ /**
1498
+ * The reCAPTCHA site key.
1499
+ */
1500
+ key : string ;
1501
+ }
1502
+
1503
+ export interface RecaptchaConfig {
1504
+ /**
1505
+ * The enforcement state of email password provider.
1506
+ */
1507
+ emailPasswordEnforcementState ?: RecaptchaProviderEnforcementState ;
1508
+
1509
+ /**
1510
+ * The reCAPTCHA managed rules.
1511
+ */
1512
+ managedRules : RecaptchaManagedRule [ ] ;
1513
+
1514
+ /**
1515
+ * The reCAPTCHA keys.
1516
+ */
1517
+ recaptchaKeys ?: RecaptchaKey [ ] ;
1518
+ }
0 commit comments