Desktop WPF login with kc

Hello,

I’ve got a desktop c# wpf software with a simple login page.

How can i use KeyCloack Api (and which one) to login my users with a user and password please ?

The login call that method:
private static User Login(string username, string password)
{
//keycloack api call here
}

Thank you very much