views:

83

answers:

2

Hi, I'm trying to run http://github.com/tardate/rails-authlogic-rpx-sample (only rails version was changed) but get error message http://gist.github.com/385696, when RPX returns information after successful authentication via Google Account. What is wrong here? And how I can fix it?

The code was successfully tested with rails 2.3.3 by its author: http://rails-authlogic-rpx-sample.heroku.com/

I run on Windows with cygwin and rails (2.3.5), rpx_now (0.6.20), authlogic_rpx (1.1.1).

Update

In several hours RPX rejected my app http://img96.imageshack.us/img96/2508/14128362.png

Update2

The same error message ( http://gist.github.com/386124) appears with http://github.com/grosser/rpx_now_example , but in this case RPX allows me to sign in (so far).

Solved

See below

A: 
Got error: Invalid parameter: apiKey (code: 1), HTTP status: 200

You have to first register your RPX app at http://www.RPXnow.com and set its name. You'll be assigned an API key which you should set in the config/environment.rb file:

RPX_API_KEY = ENV["RPX_API_KEY"]
RPX_APP_NAME = "your_app_name_here!"

Or: Read slide 35: http://www.slideshare.net/tardate/srbauthlogicrpx

You shouldn't have any constraints enforced at the database level.

Shripad K
Well, it has been done. If something is wrong with my key and name, RPX would not allow me to sign in my Google Account.
Andrey
A: 

The reason was trailing \r character in my API key. Apparently, non of the steps did key trimming and the exception was not processed in a good way.

Andrey