Can Dialogflow could be developed entirely with a text editor?

389 views Asked by At

I have some entities and intent sentences that I could use right away. It is tedious to input them by hand in the UI. I've seen that the output is just a bunch of JSONs although there are some Ids that were generated from the Dialogflow UI.

The question is, can Dialogflow be used like a regular programming language and the somehow package the JSONs into a zip that can be imported. Is the process streamlined somehow with any tool?

2

There are 2 answers

1
Riel On BEST ANSWER

Following up on my previous response, these APIs can also be used in creating the agent from scratch as long as you have a GCP project you can link your agent to.

If you're referring to the JSON schema of the exported agent, currently, there’s no JSON schema for the exported agent zip file in the Dialogflow documentation as this is not intended to be edited or replicated. The exported agent zip file is meant to be a backup of your agent for future use. You can use this exported agent to replicate the current agent to a new agent. For restoring and importing agents, you need to upload a zip file which contains the agent.json file as well as the intents or entities folders.

As best practice, it is better to create the agent using Dialogflow APIs if you opt to use JSON files. By following the JSON representation of each type (agent, intents, entities, etc), you will be sure that you are providing the correct and required fields.

1
Riel On

Dialogflow has APIs where you can make requests to create and update your agent programmatically. Each Dialogflow edition offers their own API methods.

For Dialogflow Trial and Essentials Edition, you can check the following documentation:

  1. Setup
  2. Dialogflow V2 API reference
  3. Dialogflow V2Beta1 reference
  4. Client Libraries supported

For Dialogflow CX Edition, here are the documentation that will be helpful in creating your agent programmatically:

  1. Setup
  2. Dialogflow CX V3 API reference
  3. Currently available Dialogflow CX client libraries