How and where to put scope option for omniauth-oauth2-generic provider

My Oauth2 provider required to provide a scope option, how to configure it?

I’ve followed article

Never mind got it, I had missed the authorize_params option

@ronisaha Could you plase share your config with scope option!

Thanks in advance

You configure it like this:

user_response_structure: {
        root_path: [], # i.e. if attributes are returned in JsonAPI format (in a 'user' node nested under a 'data' node)
        id_path: 'id',
        attributes: { 
            nickname: 'username',
            email: 'email',
            image: 'photoUrl'
        } # if the nickname attribute of a user is called 'username'
      authorize_params: {
           scope: 'profile'