This week's book giveaway is in the OO, Patterns, UML and Refactoring forum.
We're giving away four copies of Refactoring for Software Design Smells: Managing Technical Debt and have Girish Suryanarayana, Ganesh Samarthyam & Tushar Sharma on-line!
See this thread for details.
The moose likes Other Open Source Projects and the fly likes Google Custom Search REST API Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


JavaRanch » Java Forums » Products » Other Open Source Projects
Bookmark "Google Custom Search REST API" Watch "Google Custom Search REST API" New topic
Author

Google Custom Search REST API

Patrick Noah
Greenhorn

Joined: Aug 22, 2011
Posts: 28
Hi, I am trying to consume the google custom search REST API with the following java code. I get an exception that says "bad request". What am I doing wrong? Here is the google api documentation I have been following: https://developers.google.com/custom-search/v1/getting_started

Thanks in advance.



[Added code tags - see UseCodeTags for details]
Ulf Dittmer
Rancher

Joined: Mar 22, 2005
Posts: 42958
    
  73
Just to make sure: You're passing in the actual values for the "key" and "cx" parameters, not the dummy values you posted, correct?
Patrick Noah
Greenhorn

Joined: Aug 22, 2011
Posts: 28
Yes, I am passing in the values provided to me by google.
Patrick Noah
Greenhorn

Joined: Aug 22, 2011
Posts: 28
I figured it out, I did not have the query string argument "q="
 
Have you checked out Aspose?
 
subject: Google Custom Search REST API
 
It's not a secret anymore!