Problem with using podio_rails_sample following readme.
Hi,
I'm trying to follow readme for podio_rails_sample to connect to Leads application.
Here is my steps:
* Create API Key in Settings-> api keys. Full domain with :3000 port.
* git clone podio_rails_sample
* edit config/initializers/podio.rb put clientID and Client Secret from account settings -> api keys
* update the hardcoded APP_ID and SPACE_ID constants in app/models/lead.rb App ID for Leads.... Space ID from sandbox
* Run rails server on 3000 port. Same domain address as in api key.
* Open web page in browser
* I have "You are not signed in"...
* Put App ID of Leads APP Put App token from Leads app "Token for Leads"
* Podio::BadRequestError in SessionsController#create_from_app_auth
{"error_parameters"=>{}, "error_detail"=>"missing_client_id", "error_propagate"=>false, "request"=>{"url"=>"http://api.podio.com/oauth/token", "query_string"=>"", "method"=>"POST"}, "error_description"=>"Missing parameter client_id", "error"=>"invalid_client"}
* If I try to use "Sign in with Podio" link i have: This is not a valid request Invalid value null (null): must be non empty string
Thanks for any suggestion what is wrong with my sandbox.
-
Official comment
The client id, and possibly also the client secret, are not correctly setup in config/initializers/podio.rb.
The contents of this file should be:
Rails.application.config.middleware.use OmniAuth::Builder do
provider :podio, "Your client ID", "Your client secret"
endIf I replace that with
Rails.application.config.middleware.use OmniAuth::Builder do
provider :podio, nil, nil
endI get the same error as you describe. So clearly you haven't configured OmniAuth correctly with the podio provider. Also remember to restart your local server whenever you make changes to an initializer.
Comment actions
Please sign in to leave a comment.
Comments
7 comments