Skip to content

Set scopes for Google Provider on signIn in Next Auth 4 #4557

Answered by feri-irawan
huksley asked this question in Help
Discussion options

You must be logged in to vote

You can do like this:

authorization: {
params: {
  scope: [
    "openid",
    "https://www.googleapis.com/auth/userinfo.email",
    "https://www.googleapis.com/auth/userinfo.profile",
    // and more scope urls
  ].join(" "),
  prompt: "consent",
  access_type: "offline",
  response_type: "code",
},
},

Replies: 2 comments 1 reply

Comment options

You must be logged in to vote
0 replies
Comment options

You must be logged in to vote
1 reply
@Manikantaanyam
Comment options

Answer selected by huksley
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Help
Labels
None yet
3 participants