What markup should I use to describe social media links using schema.org? - schema.org

I have a Place/Local Business that has various fields that map quite nicely to schema.org entries. There is one field I'm not sure how to mark up though. We have links to social media accounts for the business such as their Twitter account, Facebook Page and Pinterest account. How should these be marked up in schema.org?

There is a proposal for a socialAccount property (and another one), and an older discussion about an account property. The relevant issue on Schema.org’s GitHub is Social account proposal (no comments yet).
But these properties are not there yet (if they’ll come at all).
Of the currently available properties, url, sameAs, and contactPoint come to mind:
url could be used if that’s the (only) URL of the entity
sameAs could be used if the social media account represents/identifies exactly the same entity (organization, person, etc.)
contactPoint could be used if the social media account allows contacting the entity

<div itemscope itemtype="http://schema.org/Organization">
<link itemprop="url" href="http://www.your-company-site.com">
<a itemprop="sameAs" href="http://www.facebook.com/your-company">FB</a>
<a itemprop="sameAs" href="http://www.twitter.com/YourCompany">Twitter</a>
</div>
https://developers.google.com/webmasters/social-markup/

Related

Need Schema Microdata example of how to list 'required documention' of a organization or business?

Hello and thank you for the opportunity to post a question. I have searched the Internet, Schema.org and Stackoverflow for an answer to my question. Maybe I am not asking my question correctly... I have a directory website that lists various organizations and businesses. Almost all the Organizations are Government funded and require documentation from a client in order to receive services.
For example: 'Name of Food Bank, Address, Telephone, Description, Documentation required: Photo ID, Birth Certificate, Utility Bill, EBT card.' The same would be for a Hospital, Substance Use Program, Medical, Dental, etc.
I cannot find any schema for how to list the documentation that the organization requires from a client in order to be eligible for services. I'm sure it's got to be somewhere!
Most likely, there is a way, but for just one specific entity type. I need a way to use for any entity type.
My question is how would I use Microdata to list the (any) organizations/business 'Required Documentation' of a client?
I don't think there's such an option. You might start from what's it about.
From what you're saying, some companies offer some services. So we could use Service and LocalBusiness entities.
Customers need to provide documentation, which means it's an application, so we can use ApplyAction as the top/main entity, because that seems to be the point.
As for "required documentation", can't think of anything other than just list it in the description, as is.
Here's how it might look (ApplyAction that has a Service as an object, offered by one of the companies, with requirements listed in the description):
<div>
<div itemtype="http://schema.org/ApplyAction" itemscope>
<div itemprop="object" itemtype="http://schema.org/Service" itemscope>
<meta itemprop="serviceType" content="Hospital, Substance Use Program, Medical, Dental, etc." />
<meta itemprop="description" content="Documentation required: Photo ID, Birth Certificate, Utility Bill, EBT card" />
<div itemprop="provider" itemtype="http://schema.org/LocalBusiness" itemscope>
<meta itemprop="name" content="One of various organizations and businesses" />
</div>
</div>
</div>
</div>

Schema.org Organization URL markup issue

In a web page each registered company has own profile page with a list of records belonging to a company. I'm using Schema.org Organization structured data for that page and that schema markup requires URL property. As I understand it should contain e.g company home page url. The problem is that we do not store that kind of information.
If company profile URL in our page is: www.mypage.com/unique-company-profile can I use same url in schema URL property or it has to be an URL with a different domain?
Schema.org doesn’t require the url property for Organization (it never requires any property). Consumers (like Google Search) require properties for their features (like rich results). So, it’s perfectly fine to have an Organization without url; you might just not get a certain feature in a certain search engine.
As far as Schema.org is concerned, the url property can have a site-internal URL as value. A common structure is to use url for your own page about the organization, and sameAs for the organization’s official site.
<link itemprop="url" href="/organizations/acme" />
<a itemprop="sameAs" href="https://acme.example/">official site</a>
That said, again, a consumer might have certain restrictions; if you care about the feature they offer, you have to check their documentation.

RDFa OfferCatalog Syntax

I have been trying to find the best way to link two items together using RDFa, specifically linking a Person to multiple SoftwareApplication entries.
The way I currently do this on the author page is:
<div class="container text-center" vocab="http://schema.org/" typeof="Person">
...
<span property="hasOfferCatalog" typeof="OfferCatalog">
<meta property="numberOfItems" content="10" />
<span property="itemListElement" typeof="CreativeWork">
<meta property="name" content="Project Name" />
<meta property="url" content="https://www.my-domain.tld/ProjectName/" />
</span>
...
As above the project is actually a SoftwareApplication, and the URL has a complete RDFa/Schema.org definition of it, but if i put:
typeof="SoftwareApplication"
on the author's page then, kind of expectedly, Google's Structured Markup validator throws errors about required values not being present for it, CreativeWork throws no errors but is less specific. I don't really want to repeat the entire SoftwareApplication metadata everywhere the project is referenced, I'd rather just say "go look at this URL".
What is the correct/best way to cross reference the SoftwareApplication pages from the author page? in the project the reverse reference is easy as there is an Author attribute, which can be of type Person, which is acceptable with just name and URL.
Once I know the correct RDFa way of referencing I'll apply the tags to content in the page rather than using meta tags.
To link items together, you need a suitable property. Like author (to state which Person is the creator of the SoftwareApplication), or like hasOfferCatalog (to state which SoftwareApplication is offered by the Person).
Inverse properties
In most cases, Schema.org defines its properties only for one direction. So there is only author, and no authorOf. If you need the property for the other direction, you can use RDFa’s rev attribute.
Linking instead of repeating
If you don’t want to repeat your data (i.e., only define it once and link/refer to this definition instead), you can provide a URL value. Schema.org allows this for all properties, even if URL is not listed as expected type. If you want to follow Semantic Web best practices, give your entities URLs (as identifiers) with RDFa’s resource attribute, and use these URLs as property values to refer to the entities.
For this, simply use one of the linking elements (e.g., elements with href or src attribute).
Example
Using the author case as example:
<!-- on the page about the software: /software/5 -->
<div typeof="schema:SoftwareApplication" resource="/software/5#this">
Author:
<a property="schema:author" typeof="schema:Person" href="/persons/alice#i">Alice</a>
</div>
<!-- on the page about the person: /persons/alice -->
<div typeof="schema:Person" resource="/persons/alice#i">
Authored by:
<a rev="schema:author" typeof="schema:SoftwareApplication" href="/software/5#this">Software 5</a>
</div>
Errors in Google’s SDTT
If the Structured Data Testing Tool gives errors about missing properties, note that it doesn’t mean that something is wrong with your markup. Schema.org never requires a property.
It just means that these properties are required for getting a certain Google search feature. So ignore these errors if you don’t want to get the feature (or if you can’t provide all required properties).
Thank you for the other response, I'll have a read over the linked resources, I have also found a solution to the specific case in my question.
Google Search Console has a page on Carousels which shows that you can use ListItem, which only "needs" URL, to populate the hasOfferCatalog property. E.g.
<span property="itemListElement" typeof="ListItem">
<meta property="position" content="1" />
<meta property="url" content="https://www.my-domain.tld/ProjectName/" />
</span>

Why does Google Testing Tool use the "id" attribute to generate a URL for the Microdata item?

I'm using some Microdata to describe a blog post, and I'm surprised by the value return for Schema.org’s BlogPosting by the Google Developers Testing Tool.
I would have expected it to be the itemprop url, not a merge of the website URL and the item id.
Am I doing something wrong, or is it only a Google display issue?
<div itemscope="itemscope"
itemprop="blogPost"
itemtype="http://schema.org/BlogPosting"
id="foobar">
<a itemprop="url" href="/realone">real</a>
</div>
Value returned by https://developers.google.com/structured-data/testing-tool/:
BlogPosting: http://www.example.com/foobar
url: http://www.example.com/realone
This is strange.
It’s definitely not conforming to the Microdata Note. Apart from Microdata’s itemref attribute, HTML5’s id attribute has no special meaning in Microdata.
If Google wants to use the id value anyway, they should at least generate the URL with a fragment identifier, i.e., http://www.example.com/#foobar.
My guess is that they are (probably unintentionally) handling HTML5’s id attribute the same way as Microdata’s itemid attribute. If using itemid instead of id in your example, Google’s Testing Tool output is the same, but this time correct.

Using Schema.org’s "url" property on a Product page without adding a visual link

After a bit of research I found recommendations as in:
<div itemscope itemtype="http://schema.org/Product">
<a itemprop="url" href="URLOFPRODUCT">Link</a>
</div>
But I am trying to avoid linking to the product, on the product page.
Another approach I've noticed is the use of meta tags but outside the head, which is a big 'no no'.
Any suggestions?
For providing a URL in Microdata, you must use "a URL property element". Currently these are:
a, area, audio, embed, iframe, img, link, object, source, track, and video.
a and link are the only "generic" elements from this set.
If you don’t want to provide a visual link (by using a), go with link (which is typically hidden in browser default stylesheets). This is not "a big 'no no'", as link elements are allowed in the body if used for Microdata.