I'm trying to automate training the agent and I'm using the V2 API. When I want to add a new example training phrase to an existing intent, I think I need to update the intent by using this API call: https://dialogflow.com/docs/reference/api-v2/rest/v2/projects.agent.intents/patch
But if I call that API with an intent that only has the one new training phrase it will delete all the existing ones. So I probably need to first get the contents of the intent. I tried to do it with this API call: https://dialogflow.com/docs/reference/api-v2/rest/v2/projects.agent.intents/get
But there the problem is that the intent that is returned does not contain training phrases at all.
Can anyone help me to add training phrases via the V2 API?
Thanks to the Dialogflow support I got the answer that I was missing the intentView argument from my get intent call and that's why the training phrases were not visible. Now it returns them and I can train the agent!
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With