Export, import, and restore

Agents can be exported, imported, and restored in the Dialogflow console. Import, export, and restore should be used for backing up agents or transferring them from one account to another.

Import, export, and restore options are in the agent's settings (the gear icon settings next to the agent's name) under the Export and Import tab.

Export

Exporting an agent generates a ZIP file. The resulting ZIP file contains all of the JSON files related to the agent, including intents, training phrases (per language for multi-language agents), and contexts (per language for multi-language agents).

While you can edit the JSON files directly and re-import them, you should make edits within the Dialogflow console or through the API. This ensures that changes are validated by the system and keeps troubleshooting to a minimum.

To export an agent, follow these steps:

  1. Click on the gear icon settings next to the agent name in the left menu.
  2. Click on the Export and Import tab.
  3. Click EXPORT AS ZIP.

You are then prompted to choose a location on your system to save the ZIP file.

Import

Importing an agent adds intents and entities to the current agent from the supplied ZIP file.

To import an agent, follow these steps:

  1. Click on the gear icon settings next to the agent name in the left menu.
  2. Click on the Export and Import tab.
  3. Click IMPORT FROM ZIP.
  4. Navigate to and open the ZIP file you want to import.
  5. Type "IMPORT" into the text field to confirm.
  6. Click IMPORT.

If any existing intents or entities have the same name as those in the ZIP file, they will be replaced.

Restore

Restoring an agent overwrites the current agent with the supplied ZIP file.

To restore an agent, follow these steps:

  1. Click on the gear icon settings next to the agent name in the left menu.
  2. Click on the Export and Import tab.
  3. Click RESTORE FROM ZIP.
  4. Navigate to and open the ZIP file you want to restore.
  5. Type "RESTORE" in the text field to confirm.
  6. Click RESTORE.