I share your optimism...
>
> But it returns an unhelpful 500 error.
>
> It turns out that the default routes of an OAuth::Consumer
> (e.g. :request_token_path=>"/oauth/request_token") and the routes
> provided by CloudKit differ ("/oauth/request_tokens" instead).
>
> Is it too late in the projects history for the cloudkit routes to
> match the defaults of the oauth gem?
>
> Otherwise, for anyone else, I think the following non-default options
> allow an OAuth::Consumer connect to CloudKit:
>
> @consumer = OAuth::Consumer.new('cloudkitconsumer','', { :site =>
> 'http://localhost:9292',
> :authorize_path=>"/oauth/authorization", :access_token_path=>"/oauth/
> access_tokens", :request_token_path=>"/oauth/request_tokens"})
>
> The oauth gem defaults seem to be:
>
> :request_token_path=>"/oauth/request_tokens",
> :access_token_path=>"/oauth/access_tokens",
> :authorize_path=>"/oauth/authorization",
> :http_method=>:post,
> :signature_method=>"HMAC-SHA1",
> :oauth_version=>"1.0",
> :scheme=>:header
Your assessment and workaround are correct. Would you mind if I
tackled the issue of defaults from the opposite direction? If I added
support for OAuth Discovery to the OAuth gem, it would work
automatically with any host that supported the protocol by checking
its descriptor. If other committers aren't up for the idea, then I
won't waste any time making the quick change to CloudKit instead.
-Jon