我想提供用于登录意图的自定义问题消息。
在DATETIME,我们可以提供自定义消息。
{
"expectUserResponse": true,
"expectedInputs": [
{
"possibleIntents": [
{
"intent": "actions.intent.DATETIME",
"inputValueData": {
"@type": "type.googleapis.com/google.actions.v2.DateTimeValueSpec",
"dialogSpec": {
"requestDatetimeText": "When would you like to schedule the appointment?",
"requestDateText": "What day was that?",
"requestTimeText": "What time works for you?"
}
}
}
]
}
]
}
对于SIGN_IN意图,没有这样的选项。
{
"expectUserResponse": true,
"expectedInputs": [
{
"possibleIntents": [
{
"intent": "actions.intent.SIGN_IN",
"inputValueData": {
"@type": "type.googleapis.com/google.actions.v2.SignInValueSpec"
}
}
]
}
]
}
您将需要optContent
属性以及您要用于登录请求(一部分)的自定义文本。因此可能类似于
{
"expectUserResponse": true,
"expectedInputs": [
{
"possibleIntents": [
{
"intent": "actions.intent.SIGN_IN",
"inputValueData": {
"@type": "type.googleapis.com/google.actions.v2.SignInValueSpec",
"optContext": "In order to know who you are"
}
}
]
}
]
}