# Importing Response Templates

**URL:** <https://forum.rasa.com/t/importing-response-templates/15501>\
**Category:** \[Deprecated\] Rasa X Community Edition\
**Created:** [September 10, 2019, 10:15pm UTC](https://forum.rasa.com/t/importing-response-templates/15501 "2019-09-10T22:15:35Z")\
**Posts on this page:** 9\
**Page:** 1

<div class="post-metadata">

**Author:** ![stephens](https://dub1.discourse-cdn.com/flex013/user_avatar/forum.rasa.com/stephens/32/1632_2.png) [@stephens](https://forum.rasa.com/u/stephens)\
**Post date:** [September 10, 2019, 10:15pm UTC](https://forum.rasa.com/t/importing-response-templates/15501/1 "2019-09-10T22:15:35Z")

</div>

I’m having problems importing response templates in _Version: 0.20.2_. I have about 300 response templates in my `domain.yml` from an existing Rasa bot.

I’ve been using the [HTTP API Domain](https://rasa.com/docs/rasa-x/api/rasa-x-http-api/#operation/updateDomain) endpoint to upload the templates with the PUT operation. I reported this as broken in issue [#4400](https://github.com/RasaHQ/rasa/issues/4400) last week but there has been no response. This worked in prior releases.

I’ve tried pasting my domain.yml into the Rasa X `Training > Domain` but the response templates are not added when I look at the `Training > Responses` page.

Also, are there any plans to implement a `POST` and `PUT` of yml formatted responses in the `/template` endpoint as discussed in issue [#4185](https://github.com/RasaHQ/rasa/issues/4185)?

How can I upload the response templates in my existing domain.yml to Rasa X 0.20.2?

---

<div class="post-metadata">

**Author:** ![gausie](https://dub1.discourse-cdn.com/flex013/user_avatar/forum.rasa.com/gausie/32/21_2.png) [@gausie](https://forum.rasa.com/u/gausie)\
**Post date:** [September 11, 2019, 11:09am UTC](https://forum.rasa.com/t/importing-response-templates/15501/2 "2019-09-11T11:09:28Z")

</div>

At the moment you can’t upload templates from a file. It is in our backlog to add it though!

---

<div class="post-metadata">

**Author:** ![stephens](https://dub1.discourse-cdn.com/flex013/user_avatar/forum.rasa.com/stephens/32/1632_2.png) [@stephens](https://forum.rasa.com/u/stephens)\
**Post date:** [September 11, 2019, 3:10pm UTC](https://forum.rasa.com/t/importing-response-templates/15501/3 "2019-09-11T15:10:38Z")

</div>

@gausie, can you comment on the status [#4185](https://github.com/RasaHQ/rasa/issues/4185).

---

<div class="post-metadata">

**Author:** ![gausie](https://dub1.discourse-cdn.com/flex013/user_avatar/forum.rasa.com/gausie/32/21_2.png) [@gausie](https://forum.rasa.com/u/gausie)\
**Post date:** [September 11, 2019, 3:28pm UTC](https://forum.rasa.com/t/importing-response-templates/15501/4 "2019-09-11T15:28:12Z")

</div>

It’s our intention to review all these irregularities in the API and have a fluent design which works as you would expect for all entity types, as well as more consistent naming etc. When we do that, this will be definitely included. I can’t really give you more detail than that because I just don’t know where it fits into our big to-do list!

---

<div class="post-metadata">

**Author:** ![stephens](https://dub1.discourse-cdn.com/flex013/user_avatar/forum.rasa.com/stephens/32/1632_2.png) [@stephens](https://forum.rasa.com/u/stephens)\
**Post date:** [September 11, 2019, 3:33pm UTC](https://forum.rasa.com/t/importing-response-templates/15501/5 "2019-09-11T15:33:59Z")

</div>

Sorry, I mean’t to reference [#4400](https://github.com/RasaHQ/rasa/issues/4400). I’ve been able to import templates using the API but it is not working in 0.20.2.

Is there a Rasa API call I can use to put my response templates (bypassing Rasa X)? Can I directly put them in the Postgres DB?

---

<div class="post-metadata">

**Author:** ![erohmensing](https://dub1.discourse-cdn.com/flex013/user_avatar/forum.rasa.com/erohmensing/32/1789_2.png) [@erohmensing](https://forum.rasa.com/u/erohmensing)\
**Post date:** [September 11, 2019, 4:02pm UTC](https://forum.rasa.com/t/importing-response-templates/15501/6 "2019-09-11T16:02:50Z")

</div>

AFAIK, the suggested way to import your templates is not through the domain endpoint, but the template replace endpoint: [PUT /templates](https://rasa.com/docs/rasa-x/api/rasa-x-http-api/#operation/replaceTemplates)

---

<div class="post-metadata">

**Author:** ![gausie](https://dub1.discourse-cdn.com/flex013/user_avatar/forum.rasa.com/gausie/32/21_2.png) [@gausie](https://forum.rasa.com/u/gausie)\
**Post date:** [September 11, 2019, 4:07pm UTC](https://forum.rasa.com/t/importing-response-templates/15501/7 "2019-09-11T16:07:35Z")

</div>

I’ve responded on the issue, thanks for poking me on it!

---

<div class="post-metadata">

**Author:** ![stephens](https://dub1.discourse-cdn.com/flex013/user_avatar/forum.rasa.com/stephens/32/1632_2.png) [@stephens](https://forum.rasa.com/u/stephens)\
**Post date:** [September 12, 2019, 2:08am UTC](https://forum.rasa.com/t/importing-response-templates/15501/8 "2019-09-12T02:08:20Z")

</div>

@erohmensing, frankly the API is not completely thought out well in my opinion. Certainly not from the perspective of someone trying to migrate from Rasa to Rasa X.

Please note issue [#4185](https://github.com/RasaHQ/rasa/issues/4185) - the `PUT /templates` call supports only a json format. It does not support the domain.yml format that is used for Rasa bots.

The Rasa X UI should also have an import for templates in yml format.

I’m sure this will all be addressed in time and I appreciate the quick release schedule from the Rasa X team but after upgrading to 0.20.2 I’m stuck. Will probably go back a release for now…

---

<div class="post-metadata">

**Author:** ![stephens](https://dub1.discourse-cdn.com/flex013/user_avatar/forum.rasa.com/stephens/32/1632_2.png) [@stephens](https://forum.rasa.com/u/stephens)\
**Post date:** [September 12, 2019, 3:41pm UTC](https://forum.rasa.com/t/importing-response-templates/15501/9 "2019-09-12T15:41:44Z")

</div>

FYI, I went back to `0.20.1` and confirmed that the `PUT /api/domain?store_templates=true` call works in that release.
