Skip to content

REST + JSON = #winning!

March 19, 2011

I’ve written a lot of late about REST and JSON.  I hold them dear as being two pillars at the center of good web API design and data delivery.

So I was delighted to read two nice posts on these matters recently on Apigee’s “API Best Practices and Infrastructure” blog.

The first, “REST API design for SQL programmers“, is actually a short slide presentation (accessible via Slideshare here).  It walks you through designing a well thought out, simple, easy to use web API when you’re used to thinking in SQL.  Apigee CTO Greg Brail (@gbrail) uses an employee database example to show you how to design a RESTful API to access, add, and remove employee data.  This presentation is recommended for anyone getting up to speed with REST or especially for someone designing a RESTful API for the first time.  Simple and concise, just as it should be.

The second, “Not serving JSON AND JSONP? Then you’re doing it wrong!“, is a blog post from Mr. Brail explaining why we’re seeing such a tremendous rise in JSON and the related JSONP.  In a nutshell, this approach leads to smaller messages being sent across the network, very important for anyone doing mobile work.  Because JSON is less complicated than many alternatives, this approach often also results in faster parsing and manipulation of the message contents.

Click to read the complete post via the PayPal X Developer Network. Your comments there would be greatly appreciated.


From → Uncategorized

  1. One thing many programmers seem to miss is that if their software ends up being used to fuel something that is very exciting and sees high use, each byte counts. When it’s just you and a dozen friends using something across the net then it isn’t a big deal. When a site starts to get tens of thousands or hundreds of thousands of hits a day, though, then being efficient is extremely cost effective.

    JSON in its raw format is already much more efficient than XML. For this reason I’ve given up on XML entirely. He suggests at the end of his post that XML isn’t dead yet. I’ll have to read his arguments.

  2. I think the gist of his argument for XML is that it’s still useful for more complicated structures and for certain data. In other words, use JSON by default, only falling back to XML for certain limited cases.

    Thankfully for my recent work, JSON has been perfectly sufficient.

Comments are closed.

%d bloggers like this: