This page provides links to quickly generate sample Actions that you can customize and use to explore the features of the platform. By clicking the sample type links, you'll be presented with a wizard user interface. When the wizard completes, you get a working Dialogflow agent with intents and full source code for the fulfillment which you can modify for your own Actions.
To get started building your Actions:
- Scroll to one of the samples types from the list. Optionally, you can preview the user experience for each sample type by playing the audio recording, or try out an instance by clicking on the Action link.
- Click on its Add to Dialogflow button.
- Follow the Dialogflow wizard to generate the sample.
|Sample||Create It||Preview||Features||Action Link|
|Handling user input
This sample, a story book Action, shows how to accept user input and use it to create a dynamic response.
|User input, rich response, SSML||TRY IT|
This sample, a joke Action, demonstrates the use of simple textual responses, including SSML, for conversational Actions.
|SSML, Audio, daily updates, routine suggestions, built-in intents||TRY IT|
This sample, an Action for famous quotes, showcases the use of a basic card to display images and data in a response.
|Basic card rich response, daily updates, routine suggestions, built-in intents||TRY IT|
This sample, an Action for facts, demonstrates the use of a table card to display tabular data in a response.
|Table card rich response, daily updates, routine suggestions||TRY IT|
This sample, a horoscope Action, demonstrates a list response to allow a user to select an option.
|List selection rich response, custom entities, helpers||TRY IT|
This sample, an interactive adventure Action, showcases how to use session state to store conversational data.
|In-dialog data persistence, custom entities||TRY IT|
This sample demonstrates how to play audio content in an Action.
|Media response, Media status||TRY IT|
Using sample Actions
You can use the sample Actions here to see examples of various Actions on Google capabilities, such as rich responses, SSML, persistence, and built-in intents. There are also sample Actions that can use daily updates and notifications, or be added to routines for recurrent use.
The intents are designed to follow our best practices for Actions, including:
- Error handling with no-input and fallback logic
- Support for help
- Support for repeating prompts
- Support for navigating back
- Exit and cancel prompts
Each sample type include examples of user prompts that follow our conversational design guidelines.
Customize your Action
The agent is configured to use Cloud Functions for Firebase for the fulfillment. To customize the Action behavior, open the Dialogflow fulfillment editor and follow the step-by-step instructions provided in the source code.
Enable daily updates and routines
To enable daily updates or routines in your Action:
- Go to the Actions console.
- Select the Actions menu option.
- Select One-shot from the list of Actions, then enable daily or routines under User engagement.
The Assistant will automatically suggest to the user to add your Action to daily updates or routines after they invoke your Action.
Test your Action
To test your Action, follow these steps:
- In the Dialogflow console, after you have modified the fulfillment code, save and deploy it as a Cloud Function by clicking on the Deploy button at the bottom of the Dialogflow fulfillment editor.
- Once the function is deployed, click on Integrations > Google Assistant > Test to launch the Actions simulator and test your new Action.