Guys I'm having this problem when trying to perform authentication using lib version omniauth-bigcommerce (0.3.3)
/config/initializers/omniauth.rb
Rails.application.config.middleware.use OmniAuth::Builder do
provider :bigcommerce, ENV['BC_CLIENT_ID'], ENV['BC_CLIENT_SECRET'],
{
scope: "store_payments_methods_read store_stored_payment_instruments_read_only store_v2_content_read_only store_v2_customers_read_only store_v2_default store_v2_orders_read_only store_v2_products_read_only store_v2_transactions_read_only users_basic_information",
client_options: {
site: 'https://login.bigcommerce.com'
}
}
end
config/routes.rb
get '/oauth' => 'omniauths#callback'
get '/load' => 'omniauths#load'
get '/uninstall' => 'omniauths#uninstall'
app/controllers/api/v1/omniauths_controller.rb
class Api::V1::OmniauthsController < Api::V1::BaseController
skip_before_action :validate_access_token, only: [:callback, :uninstall, :load]
def callback
auth = request.env["omniauth.auth"] # nill ever
end
end
Guys I'm having this problem when trying to perform authentication using lib version
omniauth-bigcommerce (0.3.3)/config/initializers/omniauth.rb
config/routes.rb
app/controllers/api/v1/omniauths_controller.rb