Answer the question
In order to leave comments, you need to log in
How do I get facebook's access_token without specifying a redirect_uri?
I've already broken my head.
I just want to get Facebook's access_token in the code and save it to the database, but for this I need to additionally specify redirect_uri in the parameters.
For example, for such cases, on VKontakte, you can specify redirect_uri = https://oauth.vk.com/blank.html
require 'httparty'
access_token = HTTParty.get('https://graph.facebook.com/oauth/access_token', {
client_id: 'хххххххх',
client_secret: 'хххххххх',
redirect_uri: 'http://localhost:3000/',
code: 'хххххххх'
})
Answer the question
In order to leave comments, you need to log in
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question