-
Notifications
You must be signed in to change notification settings - Fork 159
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Support reset_email_by_code template (#1014)
- Loading branch information
Showing
17 changed files
with
14,783 additions
and
17,746 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -116,8 +116,6 @@ Contents of `promptName_screenName.json` | |
} | ||
``` | ||
|
||
|
||
|
||
## Databases | ||
|
||
When managing database connections, the values of `options.customScripts` point to specific javascript files relative to | ||
|
@@ -282,3 +280,97 @@ Contents of `password_reset.json` | |
"name": "password_reset" | ||
} | ||
``` | ||
|
||
|
||
## emailTemplates | ||
|
||
When managing email templates, the values of `options.body` and `options.body` point to specific HTML files relative to the path of the output folder. Otherwise, the payload closely matches that of the [Management API](https://auth0.com/docs/api/management/v2#!/Email_Templates/post_email_templates). | ||
|
||
**YAML Example** | ||
|
||
``` | ||
Folder structure when in YAML mode. | ||
./emailTemplates/ | ||
./verify_email.html | ||
./welcome_email.html | ||
./password_reset.html | ||
./reset_email.html | ||
./reset_email_by_code.html | ||
./tenant.yaml | ||
``` | ||
|
||
```yaml | ||
# Contents of ./tenant.yaml | ||
emailTemplates: | ||
- template: "verify_email" | ||
enabled: true | ||
syntax: "liquid" | ||
from: "[email protected]" | ||
subject: "something" | ||
body: "emailTemplates/change_email.html" | ||
|
||
- template: "welcome_email" | ||
enabled: true | ||
syntax: "liquid" | ||
from: "[email protected]" | ||
subject: "something" | ||
body: "emailTemplates/change_email.html" | ||
|
||
- template: "password_reset" | ||
enabled: true | ||
syntax: "liquid" | ||
from: "[email protected]" | ||
subject: "something" | ||
body: "emailTemplates/change_email.html" | ||
|
||
- template: "reset_email_by_code" | ||
enabled: true | ||
syntax: "liquid" | ||
from: "[email protected]" | ||
subject: "something" | ||
body: "emailTemplates/change_email.html" | ||
``` | ||
**Directory Example** | ||
``` | ||
Folder structure when in directory mode. | ||
./emailTemplates/ | ||
./welcome_email.html | ||
./welcome_email.json | ||
./reset_email.html | ||
./reset_email.json | ||
./reset_email_by_code.html | ||
./reset_email_by_code.json | ||
``` | ||
|
||
Contents of `welcome_email.json` | ||
|
||
```json | ||
{ | ||
"name": "welcome_email", | ||
"enabled": true, | ||
"html": "./welcome_email.html" | ||
} | ||
``` | ||
|
||
Contents of `reset_email.json` | ||
|
||
```json | ||
{ | ||
"name": "reset_email", | ||
"enabled": true, | ||
"html": "./reset_email.html" | ||
} | ||
``` | ||
|
||
Contents of `reset_email_by_code.json` | ||
|
||
```json | ||
{ | ||
"name": "reset_email_by_code", | ||
"enabled": true, | ||
"html": "./reset_email_by_code.html" | ||
} | ||
``` |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
<html> | ||
<body> | ||
Example Email | ||
</body> | ||
</html> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,10 @@ | ||
{ | ||
"template": "reset_email_by_code", | ||
"from": "", | ||
"subject": "", | ||
"resultUrl": "", | ||
"syntax": "liquid", | ||
"body": "./reset_email_by_code.html", | ||
"urlLifetimeInSeconds": 432000, | ||
"enabled": true | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -100,6 +100,13 @@ emailTemplates: | |
subject: "something" | ||
body: "emails/change_email.html" | ||
|
||
- template: "reset_email_by_code" | ||
enabled: true | ||
syntax: "liquid" | ||
from: "[email protected]" | ||
subject: "something" | ||
body: "emails/change_email.html" | ||
|
||
|
||
clientGrants: | ||
- client_id: "My M2M" | ||
|
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.