<link rel="stylesheet" href="/styles.css">
But in the header, which means API consumers don't have to search the response body for links, and can specifically request the index with a HEAD request. Link: </styles.css>; rel="stylesheet"
The reltype is pretty powerful - it enables semantic standards and lets a client make assumptions about endpoints. Since the Link header is a standard format of, you know, links, it's also very discoverable.1. http://tools.ietf.org/html/rfc5988
EDIT: hm. No idea why I got downvoted, but I tightened it up to get more to the OP's point.
There's a great Python library called UniversalClient which illustrates this nicely: it provides some helpful scaffolding for working with REST APIs and structuring your code in a maintainable manner but ultimately a programmer still has to provide the service-specific understanding:
https://universal-client.readthedocs.org/en/latest/basics.ht...
I don't get how that would work magically. Imagine that I want to update my phone number in my account data on two different sites. If I point this magical library at the two site's APIs, how would it decide which resources to update under which paths?
It seems to me that you would still need to implement the different concepts, resource names, and so on across different sites, and you wouldn't really win anything here.
If you're talking about B2B or other more back-end type stuff, yeah some of this is annoyingly outdated. My bank's "business bill pay" website looks like it was written in 1998 and not changed since.... it does work in FF and Chrome though, since it's just bare-bones html forms and almost no javascript.
What is needed is a standard for discoverable RESTful interfaces. With that, there could be a single client library for each platform/programming language to access any compliant API.
The metaphor is here that i don't need a different browser to connect to Citibank's and Bank of America's online banking services. A single browser works just fine. This is the deeper meaning of RESTful, something which is overlooked by many people.