Problem in Zemanta call (404 - File not found)

17 views
Skip to first unread message

Massimiliano Ruocco

unread,
Aug 7, 2011, 9:28:01 AM8/7/11
to Zemanta Developers
Hi all,
i am new in Zemanta. I have tryied the demo and it seems to be great!
I download the api, i got a key and i am trying to run a java example.
Once i run the easy example (with my personal API key) i got an error.
I even try to submit the post on the url bar of the browser but i got
an File Not Found (404). Exctly the following:

...
Page not found (404)
Request Method: GET
Request URL: http://api.zemanta.com/services/rest/0.0/method=zemanta.suggest&api_key=<MY
KEY>&text=football barcelona camp nou&format=json
...

Can you help me?

Thanks in advance

Regards

Massimiliano

Andraz Tori

unread,
Aug 7, 2011, 10:38:42 PM8/7/11
to zemanta-d...@googlegroups.com

Hi Massimilano,

you should start the list of parameters with the question mark.
Therefore /rest/0.0/?method= ...

In order to avoid such mistakes, I would strongly suggest to use some
standard library in order to add parameters to the url, so they are
properly encoded.

The other thing is that while GET requests will work, they will break
down for longer texts, for that you will need to use POST requests.

bye
andraz

Massimiliano Ruocco

unread,
Aug 8, 2011, 5:04:43 AM8/8/11
to zemanta-d...@googlegroups.com
Really thanks a lot for the answer!
Yesterday night i was probably too tired...

Regards

Massimiliano

2011/8/8 Andraz Tori <andra...@gmail.com>
--
You received this message because you are subscribed to the Google Groups "Zemanta Developers" group.
To post to this group, send email to zemanta-d...@googlegroups.com.
To unsubscribe from this group, send email to zemanta-develop...@googlegroups.com.
For more options, visit this group at http://groups.google.com/group/zemanta-developers?hl=en.


Reply all
Reply to author
Forward
0 new messages