Azure AD B2C OAuth
Azure AD B2C is a customer identity platform supporting OpenID Connect, OAuth 2.0, and SAML. Use it as an OAuth provider so users can sign in with B2C accounts.
1. Create a B2C tenant
Create a B2C tenant in the Azure Portal.
2. Register an application
In the B2C tenant, register an application and note the Application (client) ID.

3. Create a client secret
Create a client secret for the app and copy its value (it is shown only once).

4. Add redirect URIs
In the app registration, add the Redirect URIs (e.g. your Casdoor callback URL).

5. Define user flows
In B2C, define user flows for sign-up, sign-in, and profile management as needed.
6. Add the provider in Casdoor
Providers → Add. Set Category to OAuth, Type to Azure AD B2C. Enter the Client ID and Client secret from the B2C app.
