- From: Nathan Ridley <axefrog@gmail.com>
- Date: Sat, 14 Feb 2015 18:10:37 +1000
- To: public-linked-json@w3.org
- Message-ID: <CAMKTGkbHuOG9BBaHOBpDVa1CNnGJztDqO7mTpf8M94T7gOub=Q@mail.gmail.com>
Thanks Brent and Manu for your replies. Manu, the fact that content negotiation is available on schema.org, among others, is definitely useful to know, thanks. That gets me part of the way there. My understanding of the true spirit of REST is that, given an API address, the hypermedia representation should provide enough information to consume the entirety of the API simply by following the provided media and action links, and with Hydra (perhaps I should cross-post to the Hydra list on this one) effectively we get the ability to traverse the entire system, analyze the application state and make intelligent decisions programmatically with regards to our client representation. Effectively, our ideal smart client should be able to generate a suitable user interface for the user with only the API endpoint URL as the initial input. The rest can be figured out just by following the trail of links, understanding the returned contexts and making judgements based on the information we're extracting from the linked data. So with that in mind, let's use the MedicineSystem type at schema.org, found at http://schema.org/MedicineSystem. If a context I'm looking at references this particular type and I don't know about it in advance and I want to follow the trail to work out what it consist of, and thus how to generate a representation thereof, then, even if I use the correct 'Accept' header, I still don't get a useful JSON-LD representation in response, which means there's no way to determine anything about that type. Your w3id links I think answered my question a little more. The first redirected to a proper JSON-LD response. The second redirected to an HTML page in the browser, as I would expect, but the JSON-LD response (from the command line) ended up with the following response: http: error: SSLError: hostname 'web-payments.org' doesn't match either of 'payswarm.com', ' www.payswarm.com' I'm guessing this is just a case of this space being somewhat immature in terms of support and adoption. In an ideal world, any of the above would have a machine-readable response, and my dreams of being able to follow my nose all the way to any endpoint referenced by a context, and being able to automatically determine its composition, would be realised. If I'm misunderstanding anything, let me know, but otherwise in the mean time I'll settle for caching locally what I find at schema.rdfs.org and using it as a stand-in for the real thing, for the time being. thanks again, Nathan -- *Google*: axefrog@gmail.com *Skype*: axefrog *Twitter*: @NathanRidley *Website*: http://axefrog.com / http://nathanridley.com *Phone: *+61 (0) 475 072789
Received on Saturday, 14 February 2015 08:11:05 UTC