# Update "Change Password (Link)" email template not updating by terraform

**URL:** <https://community.auth0.com/t/update-change-password-link-email-template-not-updating-by-terraform/150830>\
**Category:** Get Help\
**Tags:** email-templates-branding, branding\
**Created:** [November 1, 2024, 5:42am UTC](https://community.auth0.com/t/update-change-password-link-email-template-not-updating-by-terraform/150830 "2024-11-01T05:42:57Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![david.isackson](https://sea1.discourse-cdn.com/auth0/user_avatar/community.auth0.com/david.isackson/32/60163_2.png) [@david.isackson](https://community.auth0.com/u/david.isackson)\
**Post date:** [November 1, 2024, 5:42am UTC](https://community.auth0.com/t/update-change-password-link-email-template-not-updating-by-terraform/150830/1 "2024-11-01T05:42:57Z")

</div>

Hi,

When I run a pipeline deploy with this terraform script, the “Change Password (Link)” email template is not updated in auth0. The documentation says options are `reset_email`, `change_password` (legacy), or `password_reset` (legacy). `reset_email` and `password_reset` fail in the pipeline. `change_password` successfully runs but no template is updated. Which template do we use for “Change Password (Link)” or “Change Password (Code)”. The current docs are not very clear.

The error I get when it fails is: _Error: 400 Bad Request: The template property provided in payload must match the template in the URL._  
_[303](https://gitlab.cochlear.dev/it/ciam/auth0/-/jobs/1946113#L303)│_  
_[304](https://gitlab.cochlear.dev/it/ciam/auth0/-/jobs/1946113#L304)│ with auth0\_email\_template.reset\_password\_email\_template,_  
_[305](https://gitlab.cochlear.dev/it/ciam/auth0/-/jobs/1946113#L305)│ on branding.tf line 138, in resource “auth0\_email\_template” “reset\_password\_email\_template”:_  
_[306](https://gitlab.cochlear.dev/it/ciam/auth0/-/jobs/1946113#L306)│ 138: resource “auth0\_email\_template” “reset\_password\_email\_template” {_

The TF script is:  
resource “auth0\_email\_template” “reset\_password\_email\_template” {  
depends\_on = [auth0\_email\_provider.smtp\_email\_provider]  
template = “change\_password”  
subject =   
from =   
body =   
result\_url =   
syntax = “liquid”  
url\_lifetime\_in\_seconds = 86400  
enabled = true  
}.

thanks

---

<div class="post-metadata">

**Author:** ![rueben.tiow](https://sea1.discourse-cdn.com/auth0/user_avatar/community.auth0.com/rueben.tiow/32/11646_2.png) [@rueben.tiow](https://community.auth0.com/u/rueben.tiow)\
**Post date:** [November 25, 2024, 7:16pm UTC](https://community.auth0.com/t/update-change-password-link-email-template-not-updating-by-terraform/150830/3 "2024-11-25T19:16:44Z")

</div>

Hi @david.isackson,

The correct email template you should change should be the `reset_email`.

This is also mentioned in [this related communtiy post](https://community.auth0.com/t/cant-update-change-password-email-template-via-api/85888/3).

Let me know if you have any further questions.

Thanks,  
Rueben

---

<div class="post-metadata">

**Author:** ![system](https://global.discourse-cdn.com/auth0/original/3X/b/5/b560f266932fcce5d57f09a6595bd50518cae3f3.jpeg) [@system](https://community.auth0.com/u/system)\
**Post date:** [December 9, 2024, 7:16pm UTC](https://community.auth0.com/t/update-change-password-link-email-template-not-updating-by-terraform/150830/4 "2024-12-09T19:16:54Z")

</div>

This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.
