Skip to content
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.

Commit 3b2edd9

Browse files
wynksaiddestroysimi
authored andcommittedMay 22, 2024
Update API version to v19.0
1 parent ebfca0e commit 3b2edd9

File tree

2 files changed

+4
-4
lines changed

2 files changed

+4
-4
lines changed
 

‎README.md

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -60,14 +60,14 @@ end
6060

6161
### API Version
6262

63-
OmniAuth Facebook uses versioned API endpoints by default (current v5.0). You can configure a different version via `client_options` hash passed to `provider`, specifically you should change the version in the `site` and `authorize_url` parameters. For example, to change to v7.0 (assuming that exists):
63+
OmniAuth Facebook uses versioned API endpoints by default (current v19.0). You can configure a different version via `client_options` hash passed to `provider`, specifically you should change the version in the `site` and `authorize_url` parameters. For example, to change to v20.0 (assuming that exists):
6464

6565
```ruby
6666
use OmniAuth::Builder do
6767
provider :facebook, ENV['FACEBOOK_APP_ID'], ENV['FACEBOOK_APP_SECRET'],
6868
client_options: {
69-
site: 'https://graph.facebook.com/v7.0',
70-
authorize_url: "https://www.facebook.com/v7.0/dialog/oauth"
69+
site: 'https://graph.facebook.com/v20.0',
70+
authorize_url: "https://www.facebook.com/v20.0/dialog/oauth"
7171
}
7272
end
7373
```

‎lib/omniauth/strategies/facebook.rb

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ class Facebook < OmniAuth::Strategies::OAuth2
1010
class NoAuthorizationCodeError < StandardError; end
1111

1212
DEFAULT_SCOPE = 'email'
13-
DEFAULT_FACEBOOK_API_VERSION = 'v5.0'.freeze
13+
DEFAULT_FACEBOOK_API_VERSION = 'v19.0'.freeze
1414

1515
option :client_options, {
1616
site: "https://graph.facebook.com/#{DEFAULT_FACEBOOK_API_VERSION}",

0 commit comments

Comments
 (0)
Please sign in to comment.