← Back to team overview

openstack team mailing list archive

Re: API Versioning and Extensibility

 

On 10/26/2011 04:45 PM, Jorge Williams wrote:

On Oct 26, 2011, at 1:19 PM, Bryan Taylor wrote:

So no pdfs or excel spreadsheets without conneg.

But PDFs and excel spreadsheets are precisely why you want variants!

Reports and spreadsheets are presentation layer resources that should come from control panels and dashboards and not from a web services API layer.

In fact, it's with some reluctance that I even suggested having HTML in the services layer, but we said an API goal was to target developers eyeballing our data formats in a browser. HTML is the best media type to use for this, leveraging the <pre> element, perhaps with some syntax highlighting eye candy.

"Here's my usage stats for 2009...

http://usage.api.acme.com/v1.0/jorgew/2009/usage.pdf";

That shouldn't be coming directly from an openstack API.

We're actually building a usage service on top of OpenStack and we don't have any PDFs in it. Dashboards, control panels, BI systems etc, should host that resource, not our APIs.

You mean to tell me that I can't send that out as an e-mail? Instead I
have to say

"Please run this command to see my usage stats for 2009

Our use case is to show *developers* what the openstack API payloads look like, not to deal with arbitrary end user presentation desires.

curl -H "Accept: application/vnd.acme.com+pdf;version=1.0"
http://usage.api.acme.com/jorgew/2009/usage";

That seems silly to me, we're missing an important feature, the ability
to click.

We are adding an important feature by leaving it out: separation of presentation and data.





Follow ups

References