views:

39

answers:

1

I need to post some text to a remote server over HTTP, this server in turn puts these comment on a Wordpress page. I am still waiting for interface details.

Is it possible to post comments directly on a Wordpress page from an Android or Java application?

Links to relevant documentation, tutorials etc. is appreciated.

Thanks.

+1  A: 

Here is one Java client library for WordPress. A Google search will probably turn up others -- after all, that's where I got the one linked to above.

CommonsWare
Thanks for your reply Mark. I am not developing a full-fledged Wordpress client; I just need the "add a new comment" functionality in my app. Wouldn't adding the full library be too much?I did some googling myself and found that wordpress has exposed their APIs to be consumed using XML-RPC protocol(details http://codex.wordpress.org/XML-RPC_wp#wp.newComment). If I could somehow invoke this method using DefaultHttpClient, I should be good I think.
manoj
"Wouldn't adding the full library be too much?" Beats me -- I didn't look at the size. I'll be a bit surprised if you find a library that only does comments, though. "If I could somehow invoke this method using DefaultHttpClient, I should be good I think." -- XML-RPC is certainly simpler than SOAP. I have hand-crafted XML-RPC payloads in the past, though not real recently. The Apache XML-RPC client might work on Android as well.
CommonsWare
"XML-RPC is certainly simpler than SOAP. I have hand-crafted XML-RPC payloads in the past, though not real recently" I skimmed through the XML-RPC specs [http://www.xmlrpc.com/spec] and tried to hand-craft a request myself for invoking wp.newComment(link in comments above). Not sure if I've got it right, though. :|"A Google search will probably turn up others..."The Wikipedia entry for XML-RPC enlists lots of client libraries under Java including some of which you've already mentioned.
manoj