FAQ Database Discussion Community


How to specify supported http operation for a resource in json-ld?

rest,http-method,json-ld
I'm new to JSON-LD and I was wondering if there is any way of specifying supported operation of a resource in JSON-LD without using Hydra's supportedOperation or supportedProperty. Is there any way to specify the context something like : { "@context" : { "@vocab" : "http://www.schema.org/", "data" : "object", "id"...

Schema.org - JSON-LD - Where to Place?

schema.org,json-ld
I am looking to use JSON-LD for schema on a website. (Schema meaning schema.org data.) I know how to write the data but my question is is there a prefered location in my code to insert this data? In other words, should the JSON-LD always be in the head, body,...

Reify triples in JSON-LD

rdf,json-ld
Suppose I have the following JSON doc: { "@id":"http://www.example.com/id/linkFrom", "http://www.example.com/link":{ "@id":"http://www.example.com/id/linkTo", "linkType":{ "@id": "http://www.example.com/vocab#specialLink" } } } How do I express that the triple <http://www.example.com/id/linkFrom> <http://www.example.com/link> <http://www.example.com/id/linkTo> has the type http://www.example.com/vocab#specialLink?...

Sitelinks Search Box JSON-LD giving error on Google Structured Data Testing Tool

schema.org,google-rich-snippets,json-ld
I implemented Google’s Sitelinks Search Box to my site. It was working very well. But today I cheked again on Google Structured Data Testing Tool and something was wrong. Now I’m getting below error: And my implementation is: <script type="application/ld+json"> { "@context": "http://schema.org", "@type": "WebSite", "url": "https://www.saatler.com/", "potentialAction": { "@type":...

How to model directories and files using schema.org types with JSON-LD syntax?

schema.org,json-ld
I'm trying to model the concept of folders (or directories) and files. Folders can contain files, or other folders (arbitrary nested recursive structure, like on your typical filesystem). I would ideally like to start with a schema.org context and base type, and extend that to represent these entities. For various...

Why is the schema.org JSON-LD representation so small?

schema.org,json-ld
When requesting the schema.org vocabulary in JSON-LD form (which can be accomplished via the following request headers): Accept: application/ld+json, application/json;q=0.9, application/javascript;q=0.5, text/javascript;q=0.5, text/plain;q=0.2, */*;q=0.1 The response document (snipped included at the bottom) appears to be very small and incomplete at first blush. It only lists a few attributes, and does...

What is the use of @vocab in JSON-LD and what is the difference to @context?

rdf,json-ld
What is the @vocab attribute in JSON-LD for? As I see it you can "import" a remote vocabulary, but isn't this the same you can do with @context? If I'm not wrong then you can "import" a remote source for @context as well. So where is the difference between @vocab...

Enabling Google Sitelinks Search Box

schema.org,google-rich-snippets,json-ld
I want to enable Google Sitelinks Search Box for a website. The point is its custom search page is implemented by hash fragment so the JSON-LD data snippet is like this: <script type="application/ld+json"> { "@context": "http://schema.org", "@type": "WebSite", "name" : "my site", "alternateName" : "example.com", "url": "http://www.example.com/", "potentialAction": { "@type":...

Best JSON-LD practices: using multiple