Alexa Entities Reference
An Alexa entity represents a real-world person, place, or thing. Built-in slot types that support entity resolution disambiguate user utterances into specific, known entities.
The Alexa knowledge graph contains data about entities. Each entity is a node linked to other entities in the knowledge graph. Use the Linked Data API in your skill to retrieve information related to the entities.
You can use Alexa Entities in the following locales:
-
English (AU)
-
English (CA)
-
English (IN)
-
English (UK)
-
English (US)
-
French (FR)
-
German (DE)
-
Italian (IT)
-
Spanish (ES)
Built-in slot types that support entity resolution
Built-in slot types that support entity resolution disambiguate user utterances into specific, known entities in the Alexa knowledge graph. Each entity has a unique ID in the form of an internationalized URI (IRI). You can use the IRI to call the Linked Data API to get information about the entity. For details about retrieving an IRI, see Retrieve the IRI from the skill request
The following table shows the list of built-in slot types that support entity resolution. For each slot type, the table indicates how you can use the entity IRIs. Note the following meaning of the columns:
- Built-in slot type – The name of a built-in slot type that supports entity resolution.
-
Possible entity classes – If slot type values resolve to entities with data in the knowledge graph, this column lists the possible entity classes for those entities. The entity class determines the set of properties available for the entity when you retrieve the entity with the Linked Data API. See the linked topic for each entity for the set of properties available for each entity.
An entity can have multiple classes. For example, a value for the
AMAZON.Author
slot type might resolve to an entity that has bothentertainment:Author
andPerson
properties.
Built-in slot type | Possible entity classes |
---|---|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
|
Built-in slot type | Possible entity classes |
---|---|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
Built-in slot type | Possible entity classes |
---|---|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
|
Built-in slot type | Possible entity classes |
---|---|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
|
Built-in slot type | Possible entity classes |
---|---|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
Built-in slot type | Possible entity classes |
---|---|
| |
| |
| |
| |
| |
| |
| |
| |
|
Built-in slot type | Possible entity classes |
---|---|
| |
| |
| |
| |
| |
| |
| |
| |
|
Built-in slot type | Possible entity classes |
---|---|
| |
| |
| |
| |
| |
| |
| |
| |
|
Built-in slot type | Possible entity classes |
---|---|
| |
| |
| |
| |
| |
| |
| |
| |
|
Data structures and namespaces
Alexa Entities use a Resource Description Framework (RDF) data model. The data model defines the entity classes and properties that Alexa supports. Every type and every property has an internationalized URI (IRI) registered under the https://schema.amazonalexa.com/
domain. For example, the AMAZON.Person
slot type has entities from the https://schema.amazonalexa.com/core/1.0/Person
class.
To reduce the length of these identifiers and make them easier to use in code, the data uses a common set of prefixes. A prefix is a shorthand replacement for a URL domain and path. For example, the prefix core:
represents the URL https://schema.amazonalexa.com/core/1.0/
. Therefore, the following identifiers reference the same class:
core:Person
https://schema.amazonalexa.com/core/1.0/Person
Entity classes and properties use namespaces to disambiguate similar names and to indicate the namespace (the place in the ontology) where a given property or class is located. For example, the entertainment:
prefix is a shorthand for https://schema.amazonalexa.com/entertainment/1.0/. This format is used for properties like entertainment:director
and classes like entertainment:Author
.
The core:
namespace is the default. In the JSON-LD response, any property or type that doesn't have a prefix is in the core
namespace. This default simplifies syntax for the most common classes and properties.
Some properties located in the core:
namespace might have a prefix, which looks like a namespace. This prefix disambiguates the semantics of that property. This prefix most often corresponds to the class that sits at the left of that property, and it would look something like the following: https://schema.amazonalexa.com/core/1.0/CreativeWork/producer
, or creativeWork:
, for short.
Alexa Entities and JSON-LD syntax
An Alexa entity is a node within the Alexa knowledge graph, potentially linked to other nodes. Properties provide links to the other nodes. For example, a Person
entity might have a birthplace
property. This property returns a link to a Place
entity, which you can use to retrieve information about that specific place.
Entities are represented in JSON-LD syntax, which is a standard format intended for linked data. In your skill code, work with a JSON-LD response the same way you work with any JSON file. You don't need special tools or libraries, but understanding some basics of how JSON-LD presents linked data might be helpful.
A JSON-LD document returned by the Linked Data API contains different types of properties. Properties named with an "at" sign (@
) are JSON-LD keywords. For example, @id
always refers to an ID represented as an IRI.
Object properties
An object property is a property that represents a link to an entity in the knowledge graph. For example, the birthplace
property for a Person
entity returns a link to the entity representing the person's birthplace. You can use the link to call the Linked Data API again to retrieve more details about the linked entity.
An object property returns a JSON object with the following properties:
@id
– The ID of the entity, provided as an IRI. Use the IRI to retrieve the entity with the Linked Data API.@type
(required) – An array of classes for the linked entity. An entity can have multiple classes, such asPerson
andentertainment:Author
. An object property always includes@type
.name
– A data property containing an array of names for the entity.
Every object property has a @type
. The @id
and name
properties are optional and might not be included for a particular object.
{
"birthplace": {
"@id": "https://ld.amazonalexa.com/entities/v1/DEPQSUzTa1nCPkZJPJVWoC",
"@type": [
"City"
],
"name": [
{
"@language": "en",
"@value": "Albuquerque, New Mexico"
}
]
}
}
Data properties
A data property represents a literal value and doesn't have an IRI. For example, the birthdate
property for a Person
entity returns a literal date value.
A data property returns a JSON object with the following properties:
@value
– The literal value. For example, the string "1982-01-28" for a date. XML Schema@type
– The data type for interpreting the literal value. For example,asd:DateTime
. Not included for localized string values (rdf:langString
).@language
: Included for a localized string (rdf:langString
) values. A locale code indicating the language for the@value
. For example,en-US
. Use theAccept-Language
header in the Linked Data API call to specify the locale returned.
For a list of possible data types, see Data types.
The following example shows an asd:DateTime
data property:
{
"birthdate": {
"@type": "asd:DateTime",
"@value": "1964-01-12"
}
}
The following example shows an rdf:langString
data type for US English:
{
"name": [
{
"@language": "en-us",
"@value": "Jeff Bezos"
}
]
}
When does a property return a single object or an array?
The characteristics of a property determine whether the property returns a single object or an array of values.
- A functional property can have only one value at a time.
- A permanent property has a value that can't change.
- A transient property has a value that can change over time.
When a property is both functional and permanent, the property returns a JSON object that represents the single value. All other properties return an array of JSON objects. This means that a property that's both functional and transient returns an array with a single value.
These rules apply to both object properties and data properties.
Examples:
- Functional and permanent – A
Person
has onebirthplace
, and this value doesn't change over time. This property returns a single object.
{
"birthplace": {
"@id": "https://ld.amazonalexa.com/entities/v1/DEPQSUzTa1nCPkZJPJVWoC",
"@type": [
"City"
],
"name": [
{
"@language": "en",
"@value": "Albuquerque, New Mexico"
}
]
}
}
- Functional and transient – A
Country
has onepoliticalLeader
, but the value does change over time. This property returns an array. The value in the array represents the value at the current point in time, not historical values.
{
"politicalLeader": [
{
"@id": "https://ld.amazonalexa.com/entities/v1/...",
"@type": [
"Person"
],
"name": [
{
"@language": "en",
"@value": "Justin Trudeau"
}
]
}
]
}
- Transient – A
Country
can have multipleborderingCountry
values because a country can border multiple other countries. Country names and borders also change over time. This property returns an array that might contain any number of values.
{
"borderingCountry": [
{
"@id": "https://ld.amazonalexa.com/entities/v1/...",
"@type": [
"Country"
],
"name": [
{
"@language": "en",
"@value": "United States"
}
]
}
]
}
JSON-LD reserved keywords
The JSON-LD syntax uses the @
sign in property names that represent reserved keywords. To access these properties in languages like JavaScript, use bracket notation instead of dot notation.
Bracket notation in JavaScript
name[0]['@value'] // returns "Canada" (the first name value in the array)
politicalLeader[0].name[0]['@value'] // returns Justin Trudeau
Missing properties and values
Alexa provides you with expected properties for each entity type. Not every entity returns the full set of possible properties. For example, not every Person entity has a deathdate
property. Alexa leaves out of the JSON response all properties that aren't available. In your code, check for the presence of a property before attempting to access data.
The Linked Data API might also return incomplete lists of values. For example, a person might have eight children but the API might know about (and return) only four of those children. Don't use the API to answer questions about data completeness. For instance, if you want to know the total number of children that an actor has, don't count the number of elements in the child property of the entity that represents that actor.
Full example of a JSON-LD response
The following example illustrates a JSON-LD document that represents a Country
entity in the Alexa knowledge graph.
Entity classes and properties
For details about the property types, see Alexa Entities and JSON-LD syntax.
The List column indicates whether the property returns a single value or an array of values. For more about how this is determined, see When does a property return a single object or an array?.
The Availability column indicates whether the property is available or in public beta.
- Available – The type or property is fully available. The name and data structure for the property are considered stable and won't change.
- Public beta – The type or property is offered in public beta. Its name and/or data structure might change or improve as we learn more from developers.
For all properties, data returned by Alexa Entities might change, for example when Alexa learns a new fact or a value is updated.
AnimalType
Represents the type of the animal, such as a species or breed. For example, lion is an AnimalType
.
Property | Description | Type | List | Availability | Example Value |
---|---|---|---|---|---|
name |
A descriptive name for the type of animal. | rdf:langString |
Yes | Available | "zebra" |
typicalGestation |
The duration of the typical full-term pregnancy for this animal. | xsd:duration |
Yes | Available | "P376D" |
typicalHeight |
The typical height of this type of animal. | asd:Distance |
Yes | Available | 129.54 |
typicalLength |
The typical length of this type of animal. | asd:Distance |
Yes | Available | 235 |
typicalLifespan |
The typical length of time that an animal of this type lives. | xsd:duration |
Yes | Available | "P25Y" |
typicalWeight |
The typical weight of an animal of this type. | asd:Mass |
Yes | Available | 219 |
AudioTrack
An audio track is an audio work that consists of a single stream of recorded sound and that can be featured in a collection of audio tracks, such as an audio playlist. For example, "Bridge Over Troubled Waters" is an audio track. "Radiolab" isn't an audio track.
Property | Description | Type | List | Availability | Example Value |
---|---|---|---|---|---|
audioWork:artist |
The artist or artists associated to the audio work as the main performer or performers. | Artist |
Yes | Available | "Bob Dylan" |
name |
The name of the audio track | rdf:langString |
Yes | Available | "Like a rolling stone" |
version |
The version of the creative work. | CreativeVersion |
Yes | Available | See AudioTrackVersion |
AudioTrackVersion
An audio track version is an audio version that consists of a single stream of recorded sound. It is also a specific version of an audio track. Come Together (remastered 2009) is an audio track version in the music album Abbey Road 1969 (Remastered 2009) on Spotify.
Property | Description | Type | List | Availability | Example Value |
---|---|---|---|---|---|
audioTrackVersion:album |
The collection of recordings that include the audio track. | MusicAlbumVersion | Yes | Available | "Highway 61 Revisited" |
runtime |
The length of time that the creative version lasts. | xsd:duration | No | Available | "PT6M9S" |
versionOf |
The corresponding work of the creative version. Note this only appears when the initial request is for a MusicAlbum. If an AudioTrack is requested this does not appear. | AudioTrack | No | Available | "Revolver" |
Book
A book is a written work that uses words and pictures to represent knowledge or a fictional story. A book is often in bound paper and ink or it can be an e-book. For example, Harry Potter and The Chamber of Secrets is a Book
.
Property | Description | Type | List | Availability | Example Value |
---|---|---|---|---|---|
entertainment:author |
The author of the book. | entertainment:Author |
Yes | Available | "J. K. Rowling" |
name |
The primary title for the book. | rdf:langString |
Yes | Available | "Harry Potter and The Chamber of Secrets" |
version |
The version of the creative work. | CreativeVersion |
Yes | Available | See BookVersion |
BookVersion
A book version is a written version that uses words and/or pictures to represent knowledge or a fictional story, often manifested in bound paper and ink, or in e-books. A book version is also a specific version of a book. For example, The Italian first edition of the book Harry Potter and the Chamber of Secrets is a BookVersion
.
Property | Description | Type | List | Availability | Example Value |
---|---|---|---|---|---|
name |
The primary title for book version | rdf:langString |
Yes | Available | "Harry Potter e la Camera dei Segreti" |
publisher |
The agent that prepares and issues the creative version for sale. | Agent |
Yes | Available | "Bloomsbury Publishing Plc" |
releaseEvent |
The event or events that took place when the book version was released in various countries. | ReleaseEvent |
Yes | Public beta | See ReleaseEvent |
City
A city is a human settlement of significant size. For example, Liverpool is a City
.
Property | Description | Type | List | Availability | Example Value |
---|---|---|---|---|---|
averageElevation |
The average height above sea-level in meters for a geographical area. | asd:Distance |
Yes | Available | 115 |
capitalOf |
The place for which this city is the primary governing city or town. | Place |
Yes | Available | "France" |
humanPopulation |
The number of people who live in a geographical area. | xsd:integer |
Yes | Available | 2148000 |
locatedWithin |
The place where the city is located. | Place |
Yes | Available | "France" |
name |
The name of the city. | rdf:langString |
Yes | Available | "Paris" |
Country
A country is a geographical area whose extension corresponds to a sovereign state or former sovereign state, and whose territory is internationally recognized as a political or cultural entity. For example, France is a country.
Property | Description | Type | List | Availability | Example Value |
---|---|---|---|---|---|
borderingCountry |
A country with which this country shares a border. | Country |
Yes | Available | "Belgium" |
capital |
The primary governing city or town for a place. | Settlement |
Yes | Available | "Paris" |
currency |
A system of money used in a geographical area. | Currency |
Yes | Available | "Euro" |
humanPopulation |
The number of people who live in a geographical area. | xsd:integer |
Yes | Available | 65328864 |
name |
The name for the country. | rdf:langString |
Yes | Available | "France" |
politicalLeader |
A person who occupies a position of leadership in the government of a place. | Person |
Yes | Available | "Emmanuel Macron" |
entertainment:Actor
An actor is an artist who portrays a character in one or more acted work versions. For example, Leonardo Di Caprio is an actor.
Property | Description | Type | List | Availability | Example Value |
---|---|---|---|---|---|
entertainment:castMemberOf |
The animated visual works in which the artist portrayed a character. | AnimatedVisualWork |
Yes | Available | "Kill Bill Volume 1" |
name |
The primary label for the actor. | rdf:langString |
Yes | Available | "Leonardo Di Caprio" |
totalNumberOfAwards |
The number of awards that the actor has won. | xsd:integer |
Yes | Public beta | 99 |
entertainment:Author
An author is an artist who creates the text within a written work or version. This type includes individual human authors and pseudonyms. For example, C.S. Lewis is an Author
.
An Author
entity might include Person
properties as well.
Property | Description | Type | List | Availability | Example Value |
---|---|---|---|---|---|
entertainment:authorOf |
The books that this author has published. | CreativeWork |
Yes | Available | "The Lion, the Witch and the Wardrobe" |
name |
The name of the author. | rdf:langString |
Yes | Available | "C. S. Lewis" |
entertainment:Director
A director is an entity who is known for directing animated visual productions such as films or TV shows. This includes individual human directors and combined entities such as director duos. For example, Sam Mendes is a director. Ben Affleck is both an actor and a director. The Coen Brothers duo is a director.
Property | Description | Type | List | Availability | Example Value |
---|---|---|---|---|---|
entertainment:directorOf |
The creative works for which the director is in charge of the creative aspects of the production. | CreativeWork |
Yes | Available | "American Beauty" |
name |
The name of the director. | rdf:langString |
Yes | Available | "Sam Mendes" |
totalNumberOfAwards |
The number of awards that the director has won. | xsd:integer |
Yes | Public beta | 4 |
entertainment:Musician
A musician is an artist who plays a musical instrument or is musically talented. For example, Ed Sheeran is a musician.
Property | Description | Type | List | Availability | Example Value |
---|---|---|---|---|---|
artist:album |
The artist's collection of recordings. | MusicAlbum |
Yes | Available | "Piano Piano" |
musician:band |
The music group to which the artist belongs. | MusicGroup |
Yes | Public beta | "The Lumineers" |
name |
The name of the musician. | rdf:langString |
Yes | Available | "Jeremiah Fraites" |
artist:recordedSongVersion |
The song version or versions that the artist has recorded and released. | SongVersion |
Yes | Available | "Maggie" |
FoodType
Food type is a class of foods encompassing prepared dishes as well as individual food items.
Property | Description | Type | List | Availability | Example Value |
---|---|---|---|---|---|
|
The nutritional content or biological source of the |
|
Yes |
Public beta |
"fruits" |
|
When true, indicates that the |
|
No |
Public beta |
"true" |
|
When true, indicates that the |
|
No |
Public beta |
"false" |
|
When true, indicates that the |
|
No |
Public beta |
"true" |
|
The other food types that are used to create the primary food type. |
|
Yes |
Public beta |
"milk, cinnamon, butter, salt" |
Movie
A movie is an animated visual work that consists of a series of moving pictures, often telling a story. For example, Pulp Fiction is a Movie
.
Property | Description | Type | List | Availability | Example Value |
---|---|---|---|---|---|
countryOfOrigin |
The country in which the movie originated. | Place |
No | Public beta | "United States" |
entertainment:castMember |
An artist who acts to portray a character in the animated visual work. | entertainment:Actor |
Yes | Available | "Tim Roth" |
entertainment:director |
The artist who is in charge of the creative aspects of the creative work. | entertainment:Director |
Yes | Available | "Quentin Tarantino" |
name |
The name of the movie. | rdf:langString |
Yes | Available | "Pulp Fiction" |
version |
The version of the creative work. | CreativeVersion |
Yes | Available | See MovieVersion |
MovieVersion
A movie version is an animated visual version that consists of a series of moving pictures, often telling a story, usually shown in a theater or on television. A movie version is also a specific version of a movie. For example, "Kill Bill: Volume 2 (English Language, 2004)" is a MovieVersion
.
Property | Description | Type | List | Availability | Example Value |
---|---|---|---|---|---|
name |
The name of the movie version. | rdf:langString |
Yes | Available | "Pulp Fiction" |
releaseEvent |
The event or events that took place when the movie version was released in various countries. | ReleaseEvent |
Yes | Public beta | See ReleaseEvent |
runtime |
The length of time that the creative version lasts. | xsd:duration |
No | Available | "PT154M" |
MusicAlbum
A music album is an audio playlist that consists of a list of music tracks that were released as a collection and are available as a compact disk (CD), vinyl or on other media. For example, Abbey Road by The Beatles is a music album.
Property | Description | Type | List | Availability | Example Value |
---|---|---|---|---|---|
audioTrackVersion |
An audio track that's included in the audio playlist. | AudioTrack |
Yes | Public beta | "At the Bottom of Everything" |
audioWork:artist |
The artist or artists associated with the audio work as the main performer or performers. | Artist |
Yes | Available | "Bright Eyes" |
name |
The name of the music album. | rdf:langString |
Yes | Available | "I'm Wide Awake, It's Morning" |
version |
The version of the creative work. | CreativeVersion | Yes | Available | See MusicAlbumVersion. |
MusicAlbumVersion
A music album version is an audio playlist version that consists of a list of music track versions that are released as a collection and are available as a compact disk (CD), vinyl or on other media. It is also a version of a music album. Revolver (Remastered) by The Beatles is a music album version.
Property | Description | Type | List | Availability | Example Value |
---|---|---|---|---|---|
versionOf |
The corresponding work of the creative version. Note this only appears when the initial request is for an AudioTrack. If a MusicAlbum is requested this does not appear. | MusicAlbum | Yes | Available | "Revolver" |
numberOfTracks |
The number of audio tracks included in the audio playlist. | xsd:integer |
No | Available | "10" |
releaseEvent |
The event or events that took place when the albu, version was released in various countries. | ReleaseEvent |
Yes | Public beta | See ReleaseEvent |
runtime |
The length of time that the creative version lasts. | xsd:duration |
No | Available | "PT45M" |
MusicGroup
A music group is a performing group that performs music. For example, The Beatles are a music group.
Property | Description | Type | List | Availability | Example Value |
---|---|---|---|---|---|
artist:album |
The artist's collection of recordings. | MusicAlbum |
Yes | Available | "Cassadaga" |
dateFounded |
The date and time when the music group was established. | asd:DateTime |
No | Available | "1995" |
member |
An Agent who is part of music group. | Agent |
Yes | Public beta | "Conor Oberst" |
name |
The name of the music group. | rdf:langString |
Yes | Available | "Bright Eyes" |
numberOfMembers |
The number of individuals belong to the music group. | xsd:integer |
Yes | Public beta | 3 |
artist:recordedSongVersion |
The song version or versions that have been recorded and released by the artist. | SongVersion |
Yes | Available | "Lime Tree" |
Person
A person is an animal that's a member of the human race and a member of the Homo Sapiens species. For example, Alexander Hamilton is a Person
.
Property | Description | Type | List | Availability | Example Value |
---|---|---|---|---|---|
birthdate |
The point in time when the person was born. | asd:DateTime |
No | Available | "1755-01-11" |
birthplace |
The place where the person was born. | Place |
No | Available | "Charlestown" |
child |
The person's child or children | Person |
Yes | Available | "Alexander Hamilton Jr." |
deathdate |
The point in time when the person died. | asd:DateTime |
No | Available | "1804-07-12" |
deathplace |
The place where the person died | Place |
No | Available | "Greenwhich Village" |
name |
The name of the person. | rdf:langString |
Yes | Available | "Alexander Hamilton" |
occupation |
The person's source of livelihood. Also includes roles that are unpaid but take up the majority of the person's productive time, such as full-time careers and unpublished novelists. | Occupation |
Yes | Available | "politician" |
ReleaseEvent
A release event is an individual event consisting of releasing a product to customers. For example, the event of Blade Runner International Version being released in Japan.
Property | Description | Type | List | Availability | Example Value |
---|---|---|---|---|---|
startDateTime |
The start day and time for an event. | asd:DateTime |
Yes | Available | "1994-10-14" |
event:location |
event:location is a property of an individual event that indicates the place in which the event takes place. | Place | Yes | Available | "France" |
TvSeries
A TV series is an animated visual work that consists of a set of connected episodes that constitute a program transmitted on television or on other broadcasters such as Netflix, Amazon Prime and similar. For example, The Good Place is a TV series.
Property | Description | Type | List | Availability | Example Value |
---|---|---|---|---|---|
entertainment:castMember |
An artist who acts to portray a character in the animated visual work. | entertainment:Actor |
Yes | Available | "Claire Foy" |
episode |
A specific instance of a TV series. For example, Friends Season 10 has episodes including The One With Princess Consuela. The BBC series Tomorrow's World had over 1000 episodes which do not appear to have been organized into seasons. | Episode | Yes | Available | Friends Season 10 has episodes including The One With Princess Consuela. |
name |
The name of the TV series. | rdf:langString |
Yes | Available | "The Crown" |
numberOfEpisodes |
The number of episodes in a TvSeries or podcast. | xsd:integer |
No | Available | 40 |
numberOfSeasons |
The number of seasons in a TvSeries. | xsd:integer |
No | Available | 4 |
Data types
Each data property has a type. These types are in the namespace https://schema.amazonalexa.com/datatypes/1.0/
.
Name | Description / Example Value | Standard |
---|---|---|
|
|
|
|
The
|
N/A |
|
The
|
N/A |
|
A localized string value. The object returned for this type has a
Use the |
|
|
|
|
|
|
|
|
|
Sample code
The following sample code demonstrates how to build a skill that uses Alexa knowledge graph:
Related topics
Last updated: Nov 28, 2023