.NET Core SDK reference
appsettings.json
:
appsettings.json
file as shown above.
Next, add the following to your Program.cs
file before the builder.build()
statement:
RowndCookieExchange
base class to handle the exchange of
Rownd JWTs for a session cookie. It will accept a Rownd JWT in the POST
body, call the HttpContext.SignInAsync()
method with the user’s email
address and/or phone number and a role (if present).
ApiController
) that we’ll use later to handle the exchange of Rownd JWTs
for a session cookie. You can specify any route you like here, but
/api/auth/rownd
is a decent choice.
UserManager
instance.
_addNewUsersToDatabase
is a protected, base class instance variable and is
set to false
by default. If you want Rownd to add users to your database,
you’ll need to set this to true
. Likewise, _userManager
is a protected,
base class instance variable and is set to null
by default. Be sure to
populate this with the UserManager injected dependency if
_addNewUsersToDatabase
is true
.