Login with Keycloak integartion on MAUI application

Is it possible to integrate the login feature with keycloak?

Currently we are using back end API for login and after that we are redirecting the user to home page. Instead we need to add a login button on the UI and when tapping on it we need to open the keyclok login page and over there the user will login. After login it will return a token and we need to fetch that value on the app.

I saw Web authenticator can do the browser-based authentication and listen for a callback. But on Web authenticator where I should pass the keycloak domain, realm name and other required properties?

I saw a lot of packages, which one is suitable for my requirements.

I research for a long time but didn’t get any useful blogs.

Just look for a library that implements OIDC [1] (ideally, check if it is certified by the OpenID Foundation [2]). Then, you will implement the OAuth 2.0 Authorization Code flow [3].

[1] Final: OpenID Connect Core 1.0 incorporating errata set 2
[2] Certified OpenID Connect Implementations - OpenID Foundation
[3] RFC 6749 - The OAuth 2.0 Authorization Framework