2020 Developer ToolsMaps & LocationSafari & WebApp Services
WWDC20 · 30 min · Developer Tools / Maps & Location / Safari & Web / App Services
Broaden your reach with Siri Event Suggestions
Whether you’re hosting event information in your app, on the web, or in an email, Siri Event Suggestions can help people keep track of their commitments — without compromising their privacy. We’ll show you how to set up your reservations so that they automatically show up in the Calendar app and how to work with the Siri Event Suggestions APIs for iOS and Markup for web and email.
Watch at developer.apple.com ↗Code shown on screen · 11 snippets
JSON-LD
<script type="application/ld+json">
{
"@context": "http://schema.org",
"@type": "FoodEstablishmentReservation",
"reservationStatus": "http://schema.org/ReservationConfirmed",
"reservationId": "IWDSCA",
"partySize": "2",
"reservationFor": {
"@type": "FoodEstablishment",
"name": "EPIC Steak",
"startDate": "2020-06-26T19:30:00-07:00",
"telephone": "(415)369-9955"
"address": {
"@type": "http://schema.org/PostalAddress",
"streetAddress": "369 The Embarcadero",
"addressLocality": "San Francisco"
"addressRegion": "CA",
"postalCode": "95105",
"addressCountry": "USA"
}
}
}
</script> Microdata
<div itemscope itemtype="FoodEstablishmentReservation">
<link itemprop="reservationStatus" href="http://schema.org/ReservationConfirmed"/>
<meta itemprop="reservationId" content="IWDSCA"/>
<meta itemprop="partySize" content="2"/>
<div itemprop="reservationFor" itemscope itemtype="FoodEstablishment">
<meta itemprop="name" content="EPIC Steak"/>
<meta itemprop="startDate" content="2020-06-26T19:30:00-07:00"/>
<meta itemprop="telephone" content="(415)369-9955"/>
<div itemprop="address" itemscope itemtype="PostalAddress">
<meta itemprop="streetAddress" content="369 The Embarcadero"/>
<meta itemprop="addressLocality" content="San Francisco"/>
<meta itemprop="addressRegion" content="CA"/>
<meta itemprop="postalCode" content="95105"/>
<meta itemprop="addressCountry" content="USA"/>
</div>
</div>
</div> Modified Reservation JSON-LD
<script type="application/ld+json">
{
"@context": "http://schema.org",
"@type": "FoodEstablishmentReservation",
"reservationStatus": "http://schema.org/ReservationConfirmed",
"reservationId": "IWDSCA",
"partySize": "2",
"reservationFor": {
"@type": "FoodEstablishment",
"name": "EPIC Steak",
"startDate": "2020-06-26T18:30:00-07:00",
"telephone": "(415)369-9955"
"address": {
"@type": "http://schema.org/PostalAddress",
"streetAddress": "369 The Embarcadero",
"addressLocality": "San Francisco"
"addressRegion": "CA",
"postalCode": "95105",
"addressCountry": "USA"
}
}
}
</script> Cancelled Reservation JSON-LD
<script type="application/ld+json">
{
"@context": "http://schema.org",
"@type": "FoodEstablishmentReservation",
"reservationStatus": "http://schema.org/ReservationCancelled",
"reservationId": "IWDSCA",
"partySize": "2",
"reservationFor": {
"@type": "FoodEstablishment",
"name": "EPIC Steak",
"startDate": "2020-06-26T19:30:00-07:00",
"telephone": "(415)369-9955"
"address": {
"@type": "http://schema.org/PostalAddress",
"streetAddress": "369 The Embarcadero",
"addressLocality": "San Francisco"
"addressRegion": "CA",
"postalCode": "95105",
"addressCountry": "USA"
}
}
}
</script> SuggestionsAllowAnyDomainForMarkup default
defaults write com.apple.suggestions SuggestionsAllowAnyDomainForMarkup -bool true SuggestionsAllowUnverifiedSourceForMarkup default
defaults write com.apple.suggestions SuggestionsAllowUnverifiedSourceForMarkup -bool true SuggestionsAllowAnyDomainForMarkup default
defaults write com.apple.suggestions SuggestionsAllowAnyDomainForMarkup -bool true SuggestionsAllowUnverifiedSourceForMarkup default
defaults write com.apple.suggestions SuggestionsAllowUnverifiedSourceForMarkup -bool true Reservation Confirmation JSON-LD
<script type='application/ld+json'>
{
"@context": "http://schema.org",
"@type": "http://schema.org/FoodEstablishmentReservation",
"reservationId": "IWDSCA",
"reservationStatus": "http://schema.org/ReservationConfirmed",
"url": "http://localhost:3000/reservations/6",
"underName": {
"@type": "http://schema.org/Person",
"name": "John Appleseed"
},
"broker": {
"@type": "http://schema.org/Organization",
"name": "Apple Reservations"
},
"startTime": "2020-06-26T19:30:00-07:00",
"partySize": "2",
"reservationFor": {
"@type": "http://schema.org/FoodEstablishment",
"name": "EPIC Steak",
"telephone": "(415)369-9955",
"address": {
"@type": "http://schema.org/PostalAddress",
"streetAddress": "369 The Embarcadero",
"addressLocality": "San Francisco"
"addressRegion": "CA",
"postalCode": "95105",
"addressCountry": "USA"
}
}
}
</script> Reservation Cancelled JSON-LD
<script type='application/ld+json'>
{
"@context": "http://schema.org",
"@type": "http://schema.org/FoodEstablishmentReservation",
"reservationId": "IWDSCA",
"reservationStatus": "http://schema.org/ReservationCancelled",
"url": "http://localhost:3000/reservations/6",
"underName": {
"@type": "http://schema.org/Person",
"name": "John Appleseed"
},
"broker": {
"@type": "http://schema.org/Organization",
"name": "Apple Reservations"
},
"startTime": "2020-06-26T19:30:00-07:00",
"partySize": "2",
"reservationFor": {
"@type": "http://schema.org/FoodEstablishment",
"name": "EPIC Steak",
"telephone": "(415)369-9955",
"address": {
"@type": "http://schema.org/PostalAddress",
"streetAddress": "369 The Embarcadero",
"addressLocality": "San Francisco"
"addressRegion": "CA",
"postalCode": "95105",
"addressCountry": "USA"
}
}
}
</script> Registration URL
developer.apple.com/contact/request/siri-events Resources
Related sessions
-
22 min -
12 min -
7 min -
20 min -
5 min -
6 min -
29 min