Hello everyone
I've built a very basic api that will return a number of unread emails to me.
I can access that api and get the response I want like this with curl
I'm now trying to do that same thing in a rails app to get the number back, but I'm doing something wrong.
Here's what I've got so far.
def oauth_messages_count
require 'httparty'
response = HTTParty.get(url,
:data => {
:text => "00700001"
})
puts response
return response
end
I'm obviously doing something wrong, but I can't work out what it is as the logs on the receiving end aren't really telling me anything.
{"message"=>"The browser (or proxy) sent a request that this server could not understand."}
Any help, tips, or links, greatly appreciated.