Hey I'm a student and for a project we have to do a agent for google via API.ai (now named dialogflow.com). Creating the agent isn“t that hard, but is it possible to interrogate the network of the user in a certain intent, to find out which printers he is using? I think you can handle this with fulfillments, but i dont really understand how i can do this with a snmp trap. Is it possible to catch the data of the google assitant users network? Or is it google who says no we dont want you to scan our users network?
1 Answers
There are a number of things that made this impossible.
First - the Google Home device itself doesn't allow for local monitoring or control of anything. Although it does have "Smart Home" voice actions, these commands are all sent to a cloud server, and the local devices are responsible for getting their commands from the manufacturer's cloud server.
Second - Actions on Google primarily treats a device (the speaker or your phone) as a user interface device. With a few exceptions, it does not allow access to the hardware itself, so it can't access the networking stack directly, and can't access any SNMP operations.
Third - While commands with Dialogflow are sent to a fulfillment server, that server must be at a publicly accessible HTTPS server address, and everyone using your action will be hitting the same server. So you can't just access a service running on the user's local network. You could create a public service that identifies each user accessing it and forwards the command to something registered on their network, but you still need a way to establish that connection.
One possible workaround would be to have a local server collect SNMP information and save them to a cloud-based database, and then have your fulfillment service access the database to provide information you're querying. There are a lot of pitfalls in this scheme, however, and you'll need to make sure you take appropriate data security measures.

- 49,922
- 7
- 53
- 105