Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type MessageMode ¶
type MessageMode uint8
const ( TEXT_MODE MessageMode = iota SSML_MODE )
Useful for response builders to distinguish between response modes and generate a response in a generic way
type ResponseBuilder ¶
type ResponseBuilder interface { // Generates a new response object which ends the discussion, not asking the user for any sort of prompt. TellResponse(message string, conversationToken *string) (api.RootResponse, error) // Generates a new response object which ends the discussion using SSML in the final response, not asking the user for any sort of prompt. TellResponseSSML(message string, conversationToken *string) (api.RootResponse, error) // Generates a response object which asks the user to respond. You can also provide a list of strings that // can be said to not provide a response. A conversation token is key in making sure you do not lose the context of // the conversation, make sure this is either the same one that is sent from the user or if this is a new request a // unique one as any response that comes back will contain it and can be used for correlation. AskResponse(message string, conversationToken *string, noInputPrompt []string) (api.RootResponse, error) // Generates a response object which asks the user to respond using SSML. You can also provide a list of strings that // can be said to not provide a response. A conversation token is key in making sure you do not lose the context of // the conversation, make sure this is either the same one that is sent from the user or if this is a new request a // unique one as any response that comes back will contain it and can be used for correlation. AskResponseSSML(message string, conversationToken *string, noInputPrompt []string) (api.RootResponse, error) }
func NewResponseBuilder ¶
func NewResponseBuilder() ResponseBuilder
Create a response builder object used to respond to the request
Directories
¶
Path | Synopsis |
---|---|
The basic API for interacting with a google home/google assistant with structures to convert the request/response to and from json
|
The basic API for interacting with a google home/google assistant with structures to convert the request/response to and from json |
Click to show internal directories.
Click to hide internal directories.