added OAuth2 displayName and pkce options

This commit is contained in:
Gani Georgiev
2023-11-29 20:19:54 +02:00
parent 995733000f
commit b283ee2263
65 changed files with 421 additions and 226 deletions
+7 -5
View File
@@ -24,11 +24,13 @@ type Yandex struct {
// Docs: https://yandex.ru/dev/id/doc/en/
func NewYandexProvider() *Yandex {
return &Yandex{&baseProvider{
ctx: context.Background(),
scopes: []string{"login:email", "login:avatar", "login:info"},
authUrl: yandex.Endpoint.AuthURL,
tokenUrl: yandex.Endpoint.TokenURL,
userApiUrl: "https://login.yandex.ru/info",
ctx: context.Background(),
displayName: "Yandex",
pkce: true,
scopes: []string{"login:email", "login:avatar", "login:info"},
authUrl: yandex.Endpoint.AuthURL,
tokenUrl: yandex.Endpoint.TokenURL,
userApiUrl: "https://login.yandex.ru/info",
}}
}