Action packages (Dialogflow)
Stay organized with collections
Save and categorize content based on your preferences.
You can create localized Actions with the Actions SDK by creating separate
Action packages for each locale and then uploading them to your Actions project
with the gactions
tool.
To create localized Actions with the Actions SDK:
- Create separate Action packages for each locale that you want to support,
giving them localized names such as
action.de.json
and action.en.json
.
Alternatively, you can create subdirectories in your project for your
localized Action packages and other resource files.
- Add the
locale
element at the top of your Action package with the language
or locale that you want to support. In addition, provide localized query
patterns for your Actions, so that users can trigger them properly for the
locale they are in. For example:
{
"locale": "de",
"actions": [
{
"intent": {
"name": "actions.intent.MAIN",
"trigger": {
"queryPatterns": [
"<Insert German query patterns here>"
]
}
}
}
]
}
- Use the
gactions
tool to upload your
Action packages to your Actions project, specifying each of your localized
Action packages. For example:
./gactions update --project my-project-id --action_package action.de.json --action_package action.en.json --action_package action.fr.json --action_package action.ja.json --action_package action.ko.json
Except as otherwise noted, the content of this page is licensed under the Creative Commons Attribution 4.0 License, and code samples are licensed under the Apache 2.0 License. For details, see the Google Developers Site Policies. Java is a registered trademark of Oracle and/or its affiliates.
Last updated 2024-11-28 UTC.
[[["Easy to understand","easyToUnderstand","thumb-up"],["Solved my problem","solvedMyProblem","thumb-up"],["Other","otherUp","thumb-up"]],[["Missing the information I need","missingTheInformationINeed","thumb-down"],["Too complicated / too many steps","tooComplicatedTooManySteps","thumb-down"],["Out of date","outOfDate","thumb-down"],["Samples / code issue","samplesCodeIssue","thumb-down"],["Other","otherDown","thumb-down"]],["Last updated 2024-11-28 UTC."],[[["OAuth and Google Sign-In linking combines Google's authentication with custom logins for flexibility."],["This linking type is ideal for Actions needing cross-platform functionality and support for non-Google accounts."],["Users can create accounts using their Google profile, link existing accounts, or sign in with other providers."],["Developers can choose between authorization code or implicit flow based on security and implementation complexity."],["Account linking flows adapt based on service settings and user accounts to create secure and personalized experiences."]]],[]]