diff --git a/docs/kratos/emails-sms/05_custom-email-templates.mdx b/docs/kratos/emails-sms/05_custom-email-templates.mdx index 1bb0c5c85..3741af9a5 100644 --- a/docs/kratos/emails-sms/05_custom-email-templates.mdx +++ b/docs/kratos/emails-sms/05_custom-email-templates.mdx @@ -173,25 +173,80 @@ The variables available for use in email templates change depending on the flow ```mdx-code-block - + -| Template | Variables | +For the `recovery_code.valid` template, the following variables are available: + +| Variable | Description | +| --- | --- | +| `To` | The email address the email will be sent to | +| `RecoveryCode` | The recovery code | +| `Identity` | The identity to be recovered | + +:::note + +The `recovery_code.invalid` template does not allow to send a direct link to the user, as the recovery flow enforces anti-CSRF measures, which would lead to the flow failing, in case the user opens the link in a different browser. + +::: + +For the `recovery_code.invalid` template, the following variables are available: + +| Variable | Description | +| --- | --- | +| `To` | the email address the email will be sent to | + + + + +For the `verification_code.valid` template, the following variables are available: + +| Variable | Description | +| --- | --- | +| `To` | the email address the email will be sent to | +| `VerificationCode` | the verification code | +| `VerificationURL` | the verification link | +| `Identity` | the identity of the email address | + + +For the `verification_code.invalid` template, the following variables are available: + +| Variable | Description | +| --- | --- | +| `To` | the email address the email will be sent to | + + + + +For the `recovery.valid` template, the following variables are available: + +| Variable | Description | +| --- | --- | +| `To` | The email address the email will be sent to | +| `RecoveryURL` | The recovery link | +| `Identity` | The identity to be recovered | + +For the `recovery.invalid` template, the following variables are available: + +| Variable | Description | | --- | --- | -| `recovery_code.valid` | `To` the email address the email will be sent to
`RecoveryCode` the recovery code
`Identity` the identity to be recovered | -| `recovery_code.invalid` | `To` the email address the email will be sent to | -| `recovery.valid` | `To` the email address the email will be sent to
`RecoveryURL` the recovery link
`Identity` the identity to be recovered | -| `recovery.invalid` | `To` the email address the email will be sent to | +| `To` | the email address the email will be sent to |
- + + +For the `verification.valid` template, the following variables are available: + +| Variable | Description | +| --- | --- | +| `To` | the email address the email will be sent to | +| `VerificationURL` | the verification link | +| `Identity` | the identity of the email address | +For the `verification.invalid` template, the following variables are available: -| Template | Variables | +| Variable | Description | | --- | --- | -| `verification_code.valid` | `To` the email address the email will be sent to
`VerificationCode` the verification code
`VerificationURL` the verification link
`Identity` the identity of the email address | -| `verification_code.invalid` | `To` the email address the email will be sent to | -| `verification.valid` | `To` the email address the email will be sent to
`VerificationURL` the verification link
`Identity` the identity to be recovered | -| `verification.invalid` | `To` the email address the email will be sent to | +| `To` | the email address the email will be sent to |