File tree Expand file tree Collapse file tree 2 files changed +30
-2
lines changed
src/Auth0.ManagementApi/Models/Connections
tests/Auth0.ManagementApi.IntegrationTests Expand file tree Collapse file tree 2 files changed +30
-2
lines changed Original file line number Diff line number Diff line change 1+ using System . Runtime . Serialization ;
2+
13using Newtonsoft . Json ;
4+ using Newtonsoft . Json . Converters ;
25
36namespace Auth0 . ManagementApi . Models . Connections
47{
@@ -12,5 +15,30 @@ public class ConnectionOptionsEmailAttribute : ConnectionOptionsAttributeBase
1215 /// </summary>
1316 [ JsonProperty ( "signup" ) ]
1417 public ConnectionOptionsEmailSignup Signup { get ; set ; }
18+
19+ /// <summary>
20+ /// Gets or sets the verification method for email.
21+ /// </summary>
22+ [ JsonConverter ( typeof ( StringEnumConverter ) ) ]
23+ [ JsonProperty ( "verification_method" ) ]
24+ public ConnectionOptionsEmailVerificationMethod ? VerificationMethod { get ; set ; }
25+ }
26+
27+ /// <summary>
28+ /// Verification methods for email authentication
29+ /// </summary>
30+ public enum ConnectionOptionsEmailVerificationMethod
31+ {
32+ /// <summary>
33+ /// Use magic link for verification
34+ /// </summary>
35+ [ EnumMember ( Value = "link" ) ]
36+ Link ,
37+
38+ /// <summary>
39+ /// Use one-time password for verification
40+ /// </summary>
41+ [ EnumMember ( Value = "otp" ) ]
42+ Otp
1543 }
1644}
Original file line number Diff line number Diff line change 1111using System . Collections . Generic ;
1212using Auth0 . AuthenticationApi . Models ;
1313using Auth0 . ManagementApi . Models . Connections ;
14- using Auth0 . Tests . Shared ;
1514using Newtonsoft . Json ;
1615
1716namespace Auth0 . ManagementApi . IntegrationTests
@@ -506,7 +505,8 @@ private ConnectionOptions GetConnectionOptionsRequest()
506505 {
507506 Active = false
508507 }
509- }
508+ } ,
509+ VerificationMethod = ConnectionOptionsEmailVerificationMethod . Otp
510510 } ,
511511 PhoneNumber = new ConnectionOptionsPhoneNumberAttribute ( )
512512 {
You can’t perform that action at this time.
0 commit comments