Stay organized with collections
Save and categorize content based on your preferences.
Action ID
actions.intent.START_EXERCISE
Description
Initiate the user's fitness-related physical activity in real-time (for
example, live tracking of a run). Determine the physical activity to be
initiated first, if required.
We recommend that you specify entities for exercise.name.
This built-in intent uses enumerated values for some parameters. Parameters that follow this
pattern are listed in Supported text field values below,
with the enumerated parameter values they support.
Locale support
Functionality
Locales
Preview creation using App Actions test tool
en-US, en-GB, en-CA, en-IN, en-BE, en-SG, en-AU
User invocation from Google Assistant
en-US, en-GB, en-CA, en-IN, en-BE, en-SG, en-AU
Example queries
en-US, en-GB, en-CA, en-IN, en-BE, en-SG, en-AU
Start my run using ExampleProvider.
Track my hike using ExampleProvider.
Start walking for one hour using ExampleProvider.
Recommended fields
The following fields represent essential information that users often
provide in queries that trigger this built-in intent:
[null,null,["Last updated 2024-09-04 UTC."],[],[],null,["# Start exercise\n\nAction ID\n: `actions.intent.START_EXERCISE`\n\nDescription\n\n: Initiate the user's fitness-related physical activity in real-time (for\n example, live tracking of a run). Determine the physical activity to be\n initiated first, if required.\n\n We recommend that you specify entities for `exercise.name`.\n\n This built-in intent uses enumerated values for some parameters. Parameters that follow this\n pattern are listed in [Supported text field values](#supported-text-id-values) below,\n with the enumerated parameter values they support.\n\nExample queries\n---------------\n\n#### en-US, en-GB, en-CA, en-IN, en-BE, en-SG, en-AU\n\n- Start my run using ExampleProvider.\n- Track my hike using ExampleProvider.\n- Start walking for one hour using ExampleProvider.\n\nRecommended fields\n------------------\n\nThe following fields represent essential information that users often\nprovide in queries that trigger this built-in intent:\n[`exercise.name`](https://schema.googleapis.com/name) \n\nOther supported fields\n----------------------\n\nThe following fields represent information that users often provide to\ndisambiguate their needs or otherwise improve their results:\n[`exercise.@type`](https://schema.googleapis.com/Exercise) \n[`exercise.duration`](https://schema.googleapis.com/duration) \n\nSupported text values by field\n------------------------------\n\n`exercise.@type`\n\n- Exercise\n\n`exercise.name`\n\n- Aerobics\n- Bench Press\n- Biking\n- Burpee\n- Climbing\n- Cross Fit\n- Crunch\n- Hiking\n- Kayaking\n- Lunge\n- Other\n- Plank\n- Pull-up\n- Push-up\n- Rowing\n- Running\n- Sit-up\n- Skiing\n- Snow boarding\n- Squat\n- Stretching\n- Surfing\n- Swimming\n- Walking\n- Yoga\n\nInventory availability by field\n-------------------------------\n\n`exercise.name`\n\n- Inline inventory\n\nForeground app invocation\n-------------------------\n\nThis built-in intent supports [foreground app invocation](/guide/app-actions/foreground-app).\n\n| Functionality | Locales |\n|----------------------------------------------|-------------------------------------------------|\n| Preview creation using App Actions test tool | en-US, en-GB, en-CA, en-IN, en-BE, en-SG, en-AU |\n| User invocation from Google Assistant | |\n\nThe following example queries are specific to intent matching for foreground app invocation:\n\n#### en-US, en-GB, en-CA, en-IN, en-BE, en-SG, en-AU\n\n- Start my run\n- Track my hike\n\nSample XML files\n----------------\n\nFor information about the `shortcuts.xml` schema, see [Create shortcuts.xml](/guide/app-actions/action-schema).\n\n\n| **Deprecation notice:** Google is ending support for App Actions implemented using the\n| `actions.xml` resource file. Please use the\n| [Actions.xml migration guide](/guide/app-actions/legacy/migration-guide) to update your\n| actions to use the fully supported Android Shortcuts framework. For details on\n| the Shortcuts framework, see [App Actions overview](/guide/app-actions/overview).\n\n\u003cbr /\u003e\n\n### Handle BII parameters\n\n### shortcuts.xml\n\n\n```world-of-warcraft-toc\n\u003c?xml version=\"1.0\" encoding=\"utf-8\"?\u003e\n\u003c!-- This is a sample shortcuts.xml --\u003e\n\u003cshortcuts xmlns:android=\"http://schemas.android.com/apk/res/android\"\u003e\n \u003ccapability android:name=\"actions.intent.START_EXERCISE\"\u003e\n \u003cintent\n android:action=\"android.intent.action.VIEW\"\n android:targetPackage=\"YOUR_UNIQUE_APPLICATION_ID\"\n android:targetClass=\"YOUR_TARGET_CLASS\"\u003e\n \u003c!-- Eg. name = \"Running\" --\u003e\n \u003cparameter\n android:name=\"exercise.name\"\n android:key=\"name\"/\u003e\n \u003c!-- Eg. duration = \"PT1H\" --\u003e\n \u003cparameter\n android:name=\"exercise.duration\"\n android:key=\"duration\"/\u003e\n \u003c/intent\u003e\n \u003c/capability\u003e\n\u003c/shortcuts\u003e\n \n```\n\n\u003cbr /\u003e\n\n### actions.xml\n\n\n```world-of-warcraft-toc\n\u003c?xml version=\"1.0\" encoding=\"utf-8\"?\u003e\n\u003c!-- This is a sample actions.xml --\u003e\n\u003cactions\u003e\n \u003caction intentName=\"actions.intent.START_EXERCISE\"\u003e\n \u003cfulfillment urlTemplate=\"myapp://custom-deeplink{?name,duration}\"\u003e\n \u003c!-- e.g. name = \"Running\" --\u003e\n \u003c!-- (Optional) Require a field eg.name for fulfillment with required=\"true\" --\u003e\n \u003cparameter-mapping urlParameter=\"name\" intentParameter=\"exercise.name\" required=\"true\" /\u003e\n \u003c!-- e.g. duration = \"PT1H\" --\u003e\n \u003cparameter-mapping urlParameter=\"duration\" intentParameter=\"exercise.duration\" /\u003e\n \u003c/fulfillment\u003e\n\n \u003c!-- Provide a fallback fulfillment with no required parameters. For example, to your app search or router deeplink --\u003e\n \u003cfulfillment urlTemplate=\"myapp://deeplink\" /\u003e\n \u003c/action\u003e\n\u003c/actions\u003e\n```\n\n\u003cbr /\u003e\n\n### Use inline inventory\n\n### shortcuts.xml\n\n\n`exercise.name` is an\nintent parameter that supports [inline inventory](/guide/app-actions/action-schema#inline-inventory).\nBy defining a `\u003cshortcut\u003e` for `exercise.name`,\nyou can uniquely identify entities that are of interest to your app or restrict\nfulfillment to the set of supported entities.\n\nIn the following example, when the user query matches the\n`name_one`\nshortcut, Assistant provides the associated shorcut identifier, `ID_ONE`, as\nthe URL parameter `name`\nto fulfillment.\n\nIf there is no inventory match, the text value received in the query for\n`exercise.name` is passed\nas-is. \n\n```transact-sql\n\u003c?xml version=\"1.0\" encoding=\"utf-8\"?\u003e\n\u003c!-- This is a sample shortcuts.xml --\u003e\n\u003cshortcuts xmlns:android=\"http://schemas.android.com/apk/res/android\"\u003e\n \u003ccapability android:name=\"actions.intent.START_EXERCISE\"\u003e\n \u003cintent\n android:targetPackage=\"YOUR_UNIQUE_APPLICATION_ID\"\n android:targetClass=\"YOUR_TARGET_CLASS\"\u003e\n \u003cparameter\n android:name=\"exercise.name\"\n android:key=\"name\"/\u003e\n \u003cparameter\n android:name=\"exercise.duration\"\n android:key=\"duration\"/\u003e\n \u003c/intent\u003e\n \u003c/capability\u003e\n \u003c!-- Short and long labels must be @string resource. --\u003e\n \u003cshortcut\n android:shortcutId=\"ID_ONE\"\n android:shortcutShortLabel=\"@string/shortcut_short_label\"\n android:shortcutLongLabel=\"@string/shortcut_long_label\"\u003e\n \u003ccapability-binding android:key=\"actions.intent.START_EXERCISE\"\u003e\n \u003cparameter-binding\n android:value=\"name\"\n android:key=\"exercise.name\"/\u003e\n \u003c/capability-binding\u003e\n \u003c/shortcut\u003e\n\u003c/shortcuts\u003e\n \n```\n\n\u003cbr /\u003e\n\n### actions.xml\n\n\n`exercise.name` is an\nintent parameter that supports [inline inventory](/guide/app-actions/action-schema#inline-inventory).\nBy defining an `\u003centity-set\u003e` for `exercise.name`,\nyou can uniquely identify entities that are of interest to your app or restrict\nfulfillment to the set of supported entities.\n\nIn the following example, when the user query matches the\n`name_one`\nentity, Assistant provides the associated identifier, `ID_ONE`, as\nthe URL parameter `name`\nto fulfillment.\n\nIf there is no inventory match, the text value received in the query for\n`exercise.name` is passed\nas-is. \n\n```transact-sql\n\u003c?xml version=\"1.0\" encoding=\"utf-8\"?\u003e\n\u003c!-- This is a sample actions.xml --\u003e\n\u003cactions\u003e\n \u003caction intentName=\"actions.intent.START_EXERCISE\"\u003e\n \u003cfulfillment urlTemplate=\"myapp://deeplink{?name}\" \u003e\n \u003c!-- name = \"ID_ONE\" or \"ID_TWO\" --\u003e\n \u003c!-- If no inventory match, name is a text value, such as \"Running\" --\u003e\n \u003c!-- (Optional) Use entityMatchRequired=\"true\" to require inventory match for fulfillment --\u003e\n \u003cparameter-mapping urlParameter=\"name\" intentParameter=\"exercise.name\" /\u003e\n \u003c/fulfillment\u003e\n\n \u003c!-- Define parameters with inventories here --\u003e\n \u003cparameter name=\"exercise.name\"\u003e\n \u003centity-set-reference entitySetId=\"nameEntitySet\"/\u003e\n \u003c/parameter\u003e\n \u003c/action\u003e\n\n \u003centity-set entitySetId=\"nameEntitySet\"\u003e\n \u003c!-- Provide an identifier per entity --\u003e\n \u003centity identifier=\"ID_ONE\" name=\"name_one\" alternateName=\"@array/name_one_synonyms\"/\u003e\n \u003centity identifier=\"ID_TWO\" name=\"name_two\" alternateName=\"@array/name_two_synonyms\"/\u003e\n \u003c/entity-set\u003e\n\u003c/actions\u003e\n```\n\n\u003cbr /\u003e\n\nThe `url` attribute associated with the entity can be used to\ndetermine the fulfillment URL if there is an inventory match. In the following\nexample, when the user query matches the\n`name_one`\nentity, Assistant provides `myapp://deeplink/one` as the fulfillment\nURL. \n\n```transact-sql\n \u003c?xml version=\"1.0\" encoding=\"utf-8\"?\u003e\n \u003c!-- This is a sample actions.xml --\u003e\n \u003cactions\u003e\n \u003caction intentName=\"actions.intent.START_EXERCISE\"\u003e\n \u003c!-- Use url from inventory match for deep link fulfillment --\u003e\n \u003cfulfillment urlTemplate=\"{@url}\" /\u003e\n\n \u003c!-- Provide a fallback fulfillment with no required parameters. For example, to your app search or router deeplink --\u003e\n \u003cfulfillment urlTemplate=\"myapp://deeplink\" /\u003e\n\n \u003c!-- Define parameters with inventories here --\u003e\n \u003cparameter name=\"exercise.name\"\u003e\n \u003centity-set-reference entitySetId=\"nameEntitySet\"/\u003e\n \u003c/parameter\u003e\n \u003c/action\u003e\n\n \u003centity-set entitySetId=\"nameEntitySet\"\u003e\n \u003c!-- Provide a URL per entity --\u003e\n \u003centity url=\"myapp://deeplink/one\" name=\"name_one\" alternateName=\"@array/name_one_synonyms\"/\u003e\n \u003centity url=\"myapp://deeplink/two\" name=\"name_two\" alternateName=\"@array/name_two_synonyms\"/\u003e\n \u003c/entity-set\u003e\n \u003c/actions\u003e\n \n```\n\n\u003cbr /\u003e\n\nJSON-LD sample\n--------------\n\nThe following JSON-LD sample provides some example values that you can\nuse in the App Actions test tool: \n\n```carbon\n{\n \"@context\": \"http://schema.googleapis.com\",\n \"@type\": \"Exercise\",\n \"duration\": \"PT1H\",\n \"name\": \"Running\"\n}\n```"]]