okta.template.Email
DEPRECATED This resource is deprecated. Switch over to the email_customization resource.
Creates an Okta Email Template.
This resource allows you to create and configure an Okta Email Template.
Example Usage
using System.Collections.Generic;
using Pulumi;
using Okta = Pulumi.Okta;
return await Deployment.RunAsync(() =>
{
var example = new Okta.Template.Email("example", new()
{
Translations = new[]
{
new Okta.Template.Inputs.EmailTranslationArgs
{
Language = "en",
Subject = "Stuff",
Template = "Hi $user.firstName,<br/><br/>Blah blah $resetPasswordLink",
},
new Okta.Template.Inputs.EmailTranslationArgs
{
Language = "es",
Subject = "Cosas",
Template = "Hola $user.firstName,<br/><br/>Puedo ir al bano $resetPasswordLink",
},
},
Type = "email.forgotPassword",
});
});
package main
import (
"fmt"
"github.com/pulumi/pulumi-okta/sdk/v3/go/okta/template"
"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)
func main() {
pulumi.Run(func(ctx *pulumi.Context) error {
_, err := template.NewEmail(ctx, "example", &template.EmailArgs{
Translations: template.EmailTranslationArray{
&template.EmailTranslationArgs{
Language: pulumi.String("en"),
Subject: pulumi.String("Stuff"),
Template: pulumi.String(fmt.Sprintf("Hi $user.firstName,<br/><br/>Blah blah $resetPasswordLink")),
},
&template.EmailTranslationArgs{
Language: pulumi.String("es"),
Subject: pulumi.String("Cosas"),
Template: pulumi.String(fmt.Sprintf("Hola $user.firstName,<br/><br/>Puedo ir al bano $resetPasswordLink")),
},
},
Type: pulumi.String("email.forgotPassword"),
})
if err != nil {
return err
}
return nil
})
}
package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.okta.template.Email;
import com.pulumi.okta.template.EmailArgs;
import com.pulumi.okta.template.inputs.EmailTranslationArgs;
import java.util.List;
import java.util.ArrayList;
import java.util.Map;
import java.io.File;
import java.nio.file.Files;
import java.nio.file.Paths;
public class App {
public static void main(String[] args) {
Pulumi.run(App::stack);
}
public static void stack(Context ctx) {
var example = new Email("example", EmailArgs.builder()
.translations(
EmailTranslationArgs.builder()
.language("en")
.subject("Stuff")
.template("Hi $user.firstName,<br/><br/>Blah blah $resetPasswordLink")
.build(),
EmailTranslationArgs.builder()
.language("es")
.subject("Cosas")
.template("Hola $user.firstName,<br/><br/>Puedo ir al bano $resetPasswordLink")
.build())
.type("email.forgotPassword")
.build());
}
}
import pulumi
import pulumi_okta as okta
example = okta.template.Email("example",
translations=[
okta.template.EmailTranslationArgs(
language="en",
subject="Stuff",
template="Hi $user.firstName,<br/><br/>Blah blah $resetPasswordLink",
),
okta.template.EmailTranslationArgs(
language="es",
subject="Cosas",
template="Hola $user.firstName,<br/><br/>Puedo ir al bano $resetPasswordLink",
),
],
type="email.forgotPassword")
import * as pulumi from "@pulumi/pulumi";
import * as okta from "@pulumi/okta";
const example = new okta.template.Email("example", {
translations: [
{
language: "en",
subject: "Stuff",
template: `Hi $user.firstName,<br/><br/>Blah blah $resetPasswordLink`,
},
{
language: "es",
subject: "Cosas",
template: `Hola $user.firstName,<br/><br/>Puedo ir al bano $resetPasswordLink`,
},
],
type: "email.forgotPassword",
});
resources:
example:
type: okta:template:Email
properties:
translations:
- language: en
subject: Stuff
template: Hi $user.firstName,<br/><br/>Blah blah $resetPasswordLink
- language: es
subject: Cosas
template: Hola $user.firstName,<br/><br/>Puedo ir al bano $resetPasswordLink
type: email.forgotPassword
Create Email Resource
new Email(name: string, args: EmailArgs, opts?: CustomResourceOptions);
@overload
def Email(resource_name: str,
opts: Optional[ResourceOptions] = None,
default_language: Optional[str] = None,
translations: Optional[Sequence[EmailTranslationArgs]] = None,
type: Optional[str] = None)
@overload
def Email(resource_name: str,
args: EmailArgs,
opts: Optional[ResourceOptions] = None)
func NewEmail(ctx *Context, name string, args EmailArgs, opts ...ResourceOption) (*Email, error)
public Email(string name, EmailArgs args, CustomResourceOptions? opts = null)
type: okta:template:Email
properties: # The arguments to resource properties.
options: # Bag of options to control resource's behavior.
- name string
- The unique name of the resource.
- args EmailArgs
- The arguments to resource properties.
- opts CustomResourceOptions
- Bag of options to control resource's behavior.
- resource_name str
- The unique name of the resource.
- args EmailArgs
- The arguments to resource properties.
- opts ResourceOptions
- Bag of options to control resource's behavior.
- ctx Context
- Context object for the current deployment.
- name string
- The unique name of the resource.
- args EmailArgs
- The arguments to resource properties.
- opts ResourceOption
- Bag of options to control resource's behavior.
- name string
- The unique name of the resource.
- args EmailArgs
- The arguments to resource properties.
- opts CustomResourceOptions
- Bag of options to control resource's behavior.
- name String
- The unique name of the resource.
- args EmailArgs
- The arguments to resource properties.
- options CustomResourceOptions
- Bag of options to control resource's behavior.
Email Resource Properties
To learn more about resource properties and how to use them, see Inputs and Outputs in the Architecture and Concepts docs.
Inputs
The Email resource accepts the following input properties:
- Translations
List<Email
Translation Args> Set of translations for a particular template.
- Type string
Email template type
- Default
Language string The default language, by default is set to
"en"
.
- Translations
[]Email
Translation Args Set of translations for a particular template.
- Type string
Email template type
- Default
Language string The default language, by default is set to
"en"
.
- translations
List<Email
Translation Args> Set of translations for a particular template.
- type String
Email template type
- default
Language String The default language, by default is set to
"en"
.
- translations
Email
Translation Args[] Set of translations for a particular template.
- type string
Email template type
- default
Language string The default language, by default is set to
"en"
.
- translations
Sequence[Email
Translation Args] Set of translations for a particular template.
- type str
Email template type
- default_
language str The default language, by default is set to
"en"
.
- translations List<Property Map>
Set of translations for a particular template.
- type String
Email template type
- default
Language String The default language, by default is set to
"en"
.
Outputs
All input properties are implicitly available as output properties. Additionally, the Email resource produces the following output properties:
- Id string
The provider-assigned unique ID for this managed resource.
- Id string
The provider-assigned unique ID for this managed resource.
- id String
The provider-assigned unique ID for this managed resource.
- id string
The provider-assigned unique ID for this managed resource.
- id str
The provider-assigned unique ID for this managed resource.
- id String
The provider-assigned unique ID for this managed resource.
Look up Existing Email Resource
Get an existing Email resource’s state with the given name, ID, and optional extra properties used to qualify the lookup.
public static get(name: string, id: Input<ID>, state?: EmailState, opts?: CustomResourceOptions): Email
@staticmethod
def get(resource_name: str,
id: str,
opts: Optional[ResourceOptions] = None,
default_language: Optional[str] = None,
translations: Optional[Sequence[EmailTranslationArgs]] = None,
type: Optional[str] = None) -> Email
func GetEmail(ctx *Context, name string, id IDInput, state *EmailState, opts ...ResourceOption) (*Email, error)
public static Email Get(string name, Input<string> id, EmailState? state, CustomResourceOptions? opts = null)
public static Email get(String name, Output<String> id, EmailState state, CustomResourceOptions options)
Resource lookup is not supported in YAML
- name
- The unique name of the resulting resource.
- id
- The unique provider ID of the resource to lookup.
- state
- Any extra arguments used during the lookup.
- opts
- A bag of options that control this resource's behavior.
- resource_name
- The unique name of the resulting resource.
- id
- The unique provider ID of the resource to lookup.
- name
- The unique name of the resulting resource.
- id
- The unique provider ID of the resource to lookup.
- state
- Any extra arguments used during the lookup.
- opts
- A bag of options that control this resource's behavior.
- name
- The unique name of the resulting resource.
- id
- The unique provider ID of the resource to lookup.
- state
- Any extra arguments used during the lookup.
- opts
- A bag of options that control this resource's behavior.
- name
- The unique name of the resulting resource.
- id
- The unique provider ID of the resource to lookup.
- state
- Any extra arguments used during the lookup.
- opts
- A bag of options that control this resource's behavior.
- Default
Language string The default language, by default is set to
"en"
.- Translations
List<Email
Translation Args> Set of translations for a particular template.
- Type string
Email template type
- Default
Language string The default language, by default is set to
"en"
.- Translations
[]Email
Translation Args Set of translations for a particular template.
- Type string
Email template type
- default
Language String The default language, by default is set to
"en"
.- translations
List<Email
Translation Args> Set of translations for a particular template.
- type String
Email template type
- default
Language string The default language, by default is set to
"en"
.- translations
Email
Translation Args[] Set of translations for a particular template.
- type string
Email template type
- default_
language str The default language, by default is set to
"en"
.- translations
Sequence[Email
Translation Args] Set of translations for a particular template.
- type str
Email template type
- default
Language String The default language, by default is set to
"en"
.- translations List<Property Map>
Set of translations for a particular template.
- type String
Email template type
Supporting Types
EmailTranslation
Import
An Okta Email Template can be imported via the template type.
$ pulumi import okta:template/email:Email example <template type>
Package Details
- Repository
- Okta pulumi/pulumi-okta
- License
- Apache-2.0
- Notes
This Pulumi package is based on the
okta
Terraform Provider.