stackjohnny
stackjohnny

Reputation: 805

Button is not showing in Google Nest devices but showing properly in Mobile Assistant

I am using google actions for one of our clients. We are using Button to navigate the user to a specific URL but Button is not showing in the Nest devices, but it is showing fine in Mobile Assistant devices.

Anyway, where we can enable the same?

Also if there is no option, what is the way to identify if the user logged in the device has button functionality enabled?

Upvotes: 0

Views: 64

Answers (1)

Nick Felker
Nick Felker

Reputation: 11978

Buttons that link to a webpage are not available on smart displays. In the platform different devices have certain limitations. As such, the device running the action sends capabilities that define what is possible. You will need to check for the WEB_LINK capability.

In the Node.js library this would be done as such:

app.handle('handle-name', conv => {
    const supportsWebLink = conv.device.capabilities.includes('WEB_LINK')
    if (!supportsWebLink) {
        // Behavior for Nest Hub and other devices
    }
})

I see you have the dialogflow-es tag rather than actions-builder, so to do it in Dialogflow:

app.intent('intent-name', conv => {
    const supportsWebLink = conv.device.capabilities.includes('WEB_LINK')
    if (!supportsWebLink) {
        // Behavior for Nest Hub and other devices
    }
})

Upvotes: 1

Related Questions