What's in a link?

I may have completely missed the whole point of Solid and the data browsere here, but … having created a web-app that allows me to register aircraft models and log flights on my POD, I can now create a model and store it’s data as a Solid linked data document - for instance at https://elfisk.solid.community/public/solidrc/models/demo (which should be functional for the next couple of days).

Lets assume I share that model with you - or rather, I share the link to the model with you - https://elfisk.solid.community/public/solidrc/models/demo - feel free to try it out.

What you will get is the data-browser showing a boring generic panel with the triplets stored in the document. Unless you are really good at reading Turtle/RDF, you will have a hard time figuring out why the bleep I sent you that link.

The problem is that the data is supposed to be rendered by some web-app in a completely different location on the web. So how do I include that information when I share somethng?

The situation is a bit like having a classic web application with, for instance, some sort of JSON based REST-ish backend API. The front-end link would be something like http://my-app/models/1234 (returning carefully crafted HTML) and the back-end resource would be something like http://api.my-app/models/1234 (returning a JSON object).

In that case I would never sent the API link, but only share the front-end link.

Going back to Solid - if https://elfisk.solid.community/public/solidrc/models/demo is the back-end data API link, what would the front-end link then be?

As I see it, the front end link would be a link to the web-app, with the complete URL to the data embedded in it, right? Something like http://my-app/models?src=https%3A%2F%2Felfisk.solid.community%2Fpublic%2Fsolidrc%2Fmodels%2Fdemo (please note that I do not have the web-app online, yet).

Have I missed something here? Is there a better way to do it? Is there a place to register RDF types with associated web-app URL templates? Or is there a standard RDF predicate I can store with my model’s data which will inform the data-browser of an external web-app that may render the resource? Or should I always implement a standard data-browser-panel (if that is the name) for this purpose? Or something else?

/Jørn

2 Likes

You could add something like the following to the RDF of https://elfisk.solid.community/public/solidrc/models/demo: <https://elfisk.solid.community/public/solidrc/models/demo> <http://example.com/worksWith> <http://my-app/models/1234>. That way when you browse your data you can deduct which application is suggested for it.

If you send http://my-app/models?src=https%3A%2F%2Felfisk.solid.community%2Fpublic%2Fsolidrc%2Fmodels%2Fdemo to a person, that would make perfect sense to me. At the end you want them to view the data through the application, right?

2 Likes

Actually it would have to be <https://elfisk.solid.community/public/solidrc/models/demo> <http://example.com/worksWith> <http://my-app/models?src=https%3A%2F%2Felfisk.solid.community%2Fpublic%2Fsolidrc%2Fmodels%2Fdemo> since the web-app wouldn’t know what POD “1234” belongs to.

Maybe the predicate name “opensWith” would be more to the point, but that’s a detail.

Does such a predicate exist? Is there something in the standard data-browser that supports it?

Glad you agree, thanks :slight_smile: It’s just such an ugly URL, but the web-app really needs to know BOTH the POD address and the data address = complete linked data URL.

Not that I know of, but sounds like a nice feature to me!

Well, you can always shorten it or have a pretty URL that redirects. :partying_face:

Added feature request https://github.com/solid/node-solid-server/issues/944

1 Like