Extracting information from a webservice

Pierre-Yves pingou at pingoured.fr
Thu Jan 17 08:22:49 PST 2013

On Thu, Jan 17, 2013 at 04:24:00PM +0200, Lubomir I. Ivanov wrote:
> On 17 January 2013 16:20, Pierre-Yves <pingou at pingoured.fr> wrote:
> >>
> >> libsoup can be used, which is pretty straight forward...
> >> http://csoap.sourceforge.net/
> >
> > I think this would be a bit overkill (having a doap webservice), the website
> > store all the information, expose it via it's API, what we need in the client is
> > simply logic to call a url, load the output and deal with it.

> libcurl + libxml2 then?
> http://curl.haxx.se/libcurl/c/simple.html

Sounds more like what I have in mind.

I just pushed a change allowing to retrieve someone's dive in xml (documented in
the /api/).

My idea would be:
1) text field in the preferences to set your user id
2) button "Sync GPS coordinate from subsurface-webservice"
  2.1) call the /api/mydives/<user id>/xml/
  2.2) load the xml returned
  2.3) for each dive information returned, do some smart date matching to
  associate the GPS coordinates with the dives already in subsurface.


More information about the subsurface mailing list