The following table lists the Schema.org-defined query pattern types for Custom
Device Actions. The name of each type starts with `$SchemaOrg`. These types
correspond to the standard types defined in [Schema.org](http://schema.org/).

Some of these types return structured data rather than a single value. These
types are indicated in the table. See [structured data](https://developers.google.com/assistant/sdk/reference/custom-actions/query-pattern-types#structured-data)
for more information.

## Supported Schema.org types

| Type | Example Developer Pattern | Example User Query | Supports Structured Data |
|---|---|---|---|
| [$SchemaOrg_Date](http://www.schema.org/Date) | read my sms from `$SchemaOrg_Date:my_date` on sms pro | *read my sms from april 1st on sms pro* | [Yes](https://developers.google.com/assistant/sdk/reference/custom-actions/query-pattern-types#date) |
| [$SchemaOrg_Number](http://www.schema.org/Number) | blink the flashlight `$SchemaOrg_Number:number` times | *blink the flashlight five times* | No |
| [$SchemaOrg_Time](http://www.schema.org/Time) | read my sms from `$SchemaOrg_Time:my_time` on sms pro | *read my sms from 5 pm on sms pro* | [Yes](https://developers.google.com/assistant/sdk/reference/custom-actions/query-pattern-types#time) |
| [$SchemaOrg_DateTime](http://www.schema.org/DateTime) | read my sms from `$SchemaOrg_DateTime:my_time` on sms pro | *read my sms from yesterday noon on sms pro* | [Yes](https://developers.google.com/assistant/sdk/reference/custom-actions/query-pattern-types#datetime) |
| [$SchemaOrg_DayOfWeek](http://www.schema.org/DayOfWeek) | show me my meetings on `$SchemaOrg_DayOfWeek:day_of_week` | *show me my meetings on Tuesday* | No |
| [$SchemaOrg_Color](http://www.schema.org/color) | turn on the `$SchemaOrg_Color:my_color` strobe light | *turn on the red strobe light* | No |
| [$SchemaOrg_priceCurrency](http://www.schema.org/priceCurrency) | show conversion rate for `$SchemaOrg_priceCurrency:cur` on currency app | *show conversion rate for yen on currency app* | No |
| [$SchemaOrg_Distance](http://www.schema.org/Distance) | show conversion chart for `$SchemaOrg_Distance:dist` | *show conversion chart for kilometer* | No |
| [$SchemaOrg_Temperature](http://www.schema.org/QuantitativeValue) | set temperature to `$SchemaOrg_Number:num` degrees `$SchemaOrg_Temperature:temp` | *set temperature to 70 degrees fahrenheit* | No |
| [$SchemaOrg_Organization](http://www.schema.org/Organization) | watch `$SchemaOrg_Organization:organization` highlights | *watch lakers highlights* | No |
| [$SchemaOrg_Organization](http://www.schema.org/Organization) | show me stock price for `$SchemaOrg_Organization:organization` | *show me stock price for Google* | No |
| [$SchemaOrg_Person](http://www.schema.org/Person) | show top 10 `$SchemaOrg_Person:musician` songs | *show top 10 bruno mars songs* | No |
| [$SchemaOrg_Person](http://www.schema.org/Person) | show me news about `$SchemaOrg_Person:person` | *show me news about bill gates* | No |
| [$SchemaOrg_Place](http://www.schema.org/Place) | write review for `$SchemaOrg_Place:place` | *write review for new york* | [Yes](https://developers.google.com/assistant/sdk/reference/custom-actions/query-pattern-types#place) |
| [$SchemaOrg_Place](http://www.schema.org/Place) | show traffic on `$SchemaOrg_Place:location` | *show traffic on mountain view* | [Yes](https://developers.google.com/assistant/sdk/reference/custom-actions/query-pattern-types#place) |
| [$SchemaOrg_Product](http://schema.org/Product) | write review for `$SchemaOrg_Product:product` | *write review for google glass* | No |
| [$SchemaOrg_Book](http://schema.org/Book) | read `$SchemaOrg_Book:my_book` | *read great expectations* | No |
| [$SchemaOrg_Movie](http://schema.org/Movie) | play the `$SchemaOrg_Movie:my_movie` movie | *review the casablanca movie* | No |
| [$SchemaOrg_TVSeries](http://schema.org/TVSeries) | play next episode of `$SchemaOrg_TVSeries:tv_series` | *play next episode of friends* | No |
| [$SchemaOrg_servesCuisine](http://schema.org/servesCuisine) | show `$SchemaOrg_servesCuisine:my_cuisine` restaurants | *show italian restaurants* | No |
| [$SchemaOrg_MusicAlbum](http://schema.org/MusicAlbum) | add `$SchemaOrg_MusicAlbum:album` to my queue. | *add abbey road to my queue* | No |
| [$SchemaOrg_MusicRecording](http://schema.org/MusicRecording) | add `$SchemaOrg_MusicRecording:song` to my favorites. | *add with or without you to my favorites.* | No |
| $SchemaOrg_YesNo | `$SchemaOrg_YesNo:yesno` | *Yes* | No |
| $SchemaOrg_URL | Add `$SchemaOrg_URL:url` | *Add google.com* | No |
| $SchemaOrg_Email | Add `$SchemaOrg_Email:email` | *Add john@google.com* | No |
| $SchemaOrg_PhoneNumber | Add `$SchemaOrg_PhoneNumber:phonenumber` | *Add (777) 777-7777* | No |
| $SchemaOrg_Text | What's that song where they say `$SchemaOrg_Text:text` | *What's that song where they say you are my sunshine?* | No |

## Structured data

Some types support structured data being passed back instead of a single value.
In the `deviceExecution` section, add `.structured` to the parameter name
to receive structured data back for these types:

```
"my-param-name": "$parameter-name.structured"
```

where <var translate="no">my-param-name</var> is the user-defined name that is passed back in the
`params` and <var translate="no">parameter-name</var> identifies the parameter in the query pattern.

See the following example:

### Place

#### Query

*Write review for New York*

#### Action package

    ...

    "intent": {
        "name": "com.example.intents.Review",
        "parameters": [
            {
                "name": "place",
                "type": "SchemaOrg_Place"
            }
        ],
        "trigger": {
            "queryPatterns": [
                "write review for $SchemaOrg_Place:place"
            ]
        }
    },

    ...

    "deviceExecution": {
        "command": "com.example.commands.Review",
        "params": {
            "placeName": "$place.structured"
        }
    }

    ...

#### Returned params

See [LatLng](https://developers.google.com/assistant/conversational/webhook/reference/rest/Shared.Types/Location#LatLng) for more information.

    "placeName": {
        "latitude": 40.7128,
        "longitude": 74.0060
    }

> [!NOTE]
> **Note:** `placeName` would contain `New York` if `.structured` was not added.

### Date

See [Date](https://developers.google.com/assistant/conversational/webhook/reference/rest/Shared.Types/Argument#date) for more information.

Returned params:

    {
        "year": 2018,
        "month": 12,
        "day": 2
    }

### Time

See [TimeOfDay](https://developers.google.com/assistant/conversational/webhook/reference/rest/Shared.Types/Argument#timeofday) for more information.

Returned params:

    {
        "hours": 12,
        "minutes": 0,
        "seconds": 0,
        "nanos": 0
    }

### DateTime

See [DateTime](https://developers.google.com/assistant/conversational/webhook/reference/rest/Shared.Types/Argument#datetime) for more information.

Returned params:

    {
        "date": {
          "year": 2018,
          "month": 11,
          "day": 30
        },
        "time": {
          "hours": 12,
          "minutes": 0,
          "seconds": 0,
          "nanos": 0
        }
    }