Reconsidering APIs

This is good advice from Peter Krantz:

TL;DR See if it is possible to publish your open data as file dumps instead of building advanced API's that force entrepreneurs to integrate their apps with your infrastructure.

Agreed. I'm still convinced that data is usually better than an API.

Via Sunlight Labs director Tom Lee makes a great point in there about web APIs for GIS.


Re: Reconsidering APIs

Author: Peter Rushforth

Disagree Sean. Good REST practice dictates that data be exposed as resources, and clients interact with their representation.

That way servers, who deliver that open data, can keep their clients informed of changes as required.

My $.02



Re: Reconsidering APIs

Author: Martin Davis

Agree 100% that data is better than an API.

Now if only there was a good, simple, open, expressive format for spatial data.

(and no, I don't think that sqlite is it - for the same reason, it's an API, not an open format).

Re: Reconsidering APIs

Author: dw

This is crazy talk.

What happens when the data is updated?

What happens when different entities are storing your data in different, ineffective ways to the public?

People not using REST effectively isn't a reason to not use REST.

Re: Reconsidering APIs

Author: Sean

Martin: isn't sqlite more of a hybrid? There's an API, but it's a local - not network - API and all the data is included with it.

My understanding of REST is that it's different from the kind of APIs discussed in the blog posts I referenced. I don't see why an entire modestly sized dataset can't be a first class web resource.

Re: Reconsidering APIs

Author: Martin Davis

Yes, the sqlite API is local. But it is basically opaque - at least, I've never looked but I'm pretty sure that a format designed to support a full database is not going to very friendly for reading directly. And I've never seen the format published. So it has the same problem that's being raised.

I this might be considered a bit OT. But it's a pet peeve of mine that we're still stuck with shapefiles after all these years. In my wilder moments I contemplate how nice it would be if the FOSS4G community got together and created a new standard file format to replace the shapefile (fixing the obviously broken bits and moving it in the 21st cent in a sane way)