Hello my name is Ori Pekelman. I am OriPekelman everywhere (twitter/github/linked-in).
My blog is on http://blog.constellationmatrix.com
I am an independent software architect and I made myself a nice logo.
Application programming interface
It is a system that allows a program to expose functionality and data to another program.
Applying a style is what we call the "design process"
http://www.w3.org is a good one. Also http://pekelman.com/time or http://pekelman.com/time.json or https://github.com/OriPekelman/paris-rb-grape-talk/commits/master
I will get back to this
Still we won't go into details this time...
We have seen that "REST urls are just urls" well a hypermedia API is just a REST API with links. And even more down to earth.. a REST api with elements that have a "href" can be considered hypermedia
http://almostobsolete.net/talks/hypermedia/#8
(edit: so if you weren't there, please click on the link.. see slides 8--21 then use the back button of your browser)
I am using impress.js he is using reveal.js or something. I don't even need to know.
We got back to where we were. Because we had a URL! We are only doing idempotent stuff so we are at the same state.
BTW the bit of presentation you saw was by Thomas Parslow
calling http://pekelman.com/time.json
{ "message": "This Document is http://pekelman.com/time/ and it is about what http://pekelman.com/ knows to do with time.", "status": "clockrunning", "links": [ {"rel": "self", "href": " http://pekelman.com/time/" }, {"rel": "zone", "href": "zone/" }, {"rel": "current", "href": "now/", value:"Thu Apr 18, 2013 17:34 pm "} {"rel": "reset", "title": "RAZ", "verb": "DELETE", "href": "."} ], }
{"rel": "current", "href": "now/", value:"Thu Apr 18, 2013 17:34 pm "}
Remember the part about making the simple use-cases accessible..
{"rel": "reset", "title": "RAZ", "verb": "DELETE", "href": "."}
Principle of least suprise anyone ?
{"rel": "reset", "title": "Reset server time", "verb": "POST", "href": "."}
Principle of least suprise anyone
Well that simply doesn't make any sense does it? A pure Hypermedia API is like a "pure" REST api. We don't want to be pure we want to be simple, general, abstract and prgamatic! Still, if all the methods of your api are discoverable through the api. If you replace internal opaque ids by links. If for chaining methods all you need is the first response well, your Hypermedia is damn pure.