dialogflow / dialogflow-python-client

Python library for Dialogflow
Apache License 2.0
557 stars 195 forks source link

How to access user entity values submitted by `send_user_entities_example.py` on api.ai platform? #44

Open clungzta opened 7 years ago

clungzta commented 7 years ago

Hello,

I am trying to access set some User Entities for my session using the python-client. Then use ai.api insert the Value of the User Entity in the text response.

I have successfully ran the user entity sample code send_user_entities_example.py.

However I am unsure of how to simply access the submitted entity value from api.ai to insert it into my text response.

All documentation I have found regarding the use of ai.api UserEntites has been quite vague. Code comments refer to https://api.ai/docs/reference/agent/userentities which states:

A good scenario could be when you have a playlist entity that has generic playlist. As playlists are user-specific, playlist entity could be defined in a request or for a given session.

This is the only source of information I could find online about UserEntites, it does not explain how to access user entity values from the api.ai platform agent.

Further instruction/documentation about "how to access the user entity values submitted by send_user_entities_example.py on the api.ai platform agent" would be greatly appreciated.