static void Main(string[] args) { var lc = new LoginClient(LoginBase.LoginType.Gitee); var url = lc.Auth(); var ar = new LoginBase.AuthorizeResult(); ar.code = ""; lc.AuthCallback(ar); }
static void Main(string[] args) { var lc = new LoginClient(LoginBase.LoginType.StackOverflow); //拷贝授权链接在浏览器打开,授权后拿到code,并手动赋值,手动赋值需解码 var url = lc.Auth(); var ar = new LoginBase.AuthorizeResult(); ar.code = ""; //此处打断点,赋值上面拿到的code再继续 ar.code = ar.code.ToDecode(); lc.AuthCallback(ar); }
public void Test1() { var lc = new LoginClient(LoginBase.LoginType.GitHub); //拷贝授权链接在浏览器打开,授权后拿到code,并手动赋值,手动赋值需解码 var URL = lc.Auth(); Console.WriteLine(URL); var ar = new LoginBase.AuthorizeResult(); ar.code = ""; //此处打断点,赋值上面拿到的code再继续 ar.code = ar.code.ToDecode(); ar.auth_code = ar.code; lc.AuthCallback(ar); }
static void Main(string[] args) { var lc = new LoginClient(LoginBase.LoginType.AliPay); //拷贝授权链接在浏览器打开,授权后拿到code,并手动赋值,手动赋值需解码 var URL = lc.Auth(); Console.WriteLine(URL); var ar = new LoginBase.AuthorizeResult(); ar.code = ""; ar.auth_code = ""; //此处打断点,赋值上面拿到的code再继续 ar.code = ar.code.ToDecode(); lc.AuthCallback(ar); }