1. Packages
  2. Okta Provider
  3. API Docs
  4. EmailSender
Okta v4.16.0 published on Wednesday, Apr 9, 2025 by Pulumi

okta.EmailSender

Explore with Pulumi AI

Creates custom email sender. This resource allows you to create and configure a custom email sender.

DEPRECATED The api for this resource has been deprecated. Please use okta.EmailDomain instead.

Example Usage

import * as pulumi from "@pulumi/pulumi";
import * as okta from "@pulumi/okta";

const example = new okta.EmailSender("example", {
    fromName: "Paul Atreides",
    fromAddress: "no-reply@caladan.planet",
    subdomain: "mail",
});
Copy
import pulumi
import pulumi_okta as okta

example = okta.EmailSender("example",
    from_name="Paul Atreides",
    from_address="no-reply@caladan.planet",
    subdomain="mail")
Copy
package main

import (
	"github.com/pulumi/pulumi-okta/sdk/v4/go/okta"
	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)

func main() {
	pulumi.Run(func(ctx *pulumi.Context) error {
		_, err := okta.NewEmailSender(ctx, "example", &okta.EmailSenderArgs{
			FromName:    pulumi.String("Paul Atreides"),
			FromAddress: pulumi.String("no-reply@caladan.planet"),
			Subdomain:   pulumi.String("mail"),
		})
		if err != nil {
			return err
		}
		return nil
	})
}
Copy
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using Okta = Pulumi.Okta;

return await Deployment.RunAsync(() => 
{
    var example = new Okta.EmailSender("example", new()
    {
        FromName = "Paul Atreides",
        FromAddress = "no-reply@caladan.planet",
        Subdomain = "mail",
    });

});
Copy
package generated_program;

import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.okta.EmailSender;
import com.pulumi.okta.EmailSenderArgs;
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 EmailSender("example", EmailSenderArgs.builder()
            .fromName("Paul Atreides")
            .fromAddress("no-reply@caladan.planet")
            .subdomain("mail")
            .build());

    }
}
Copy
resources:
  example:
    type: okta:EmailSender
    properties:
      fromName: Paul Atreides
      fromAddress: no-reply@caladan.planet
      subdomain: mail
Copy

Create EmailSender Resource

Resources are created with functions called constructors. To learn more about declaring and configuring resources, see Resources.

Constructor syntax

new EmailSender(name: string, args: EmailSenderArgs, opts?: CustomResourceOptions);
@overload
def EmailSender(resource_name: str,
                args: EmailSenderArgs,
                opts: Optional[ResourceOptions] = None)

@overload
def EmailSender(resource_name: str,
                opts: Optional[ResourceOptions] = None,
                from_address: Optional[str] = None,
                from_name: Optional[str] = None,
                subdomain: Optional[str] = None)
func NewEmailSender(ctx *Context, name string, args EmailSenderArgs, opts ...ResourceOption) (*EmailSender, error)
public EmailSender(string name, EmailSenderArgs args, CustomResourceOptions? opts = null)
public EmailSender(String name, EmailSenderArgs args)
public EmailSender(String name, EmailSenderArgs args, CustomResourceOptions options)
type: okta:EmailSender
properties: # The arguments to resource properties.
options: # Bag of options to control resource's behavior.

Parameters

name This property is required. string
The unique name of the resource.
args This property is required. EmailSenderArgs
The arguments to resource properties.
opts CustomResourceOptions
Bag of options to control resource's behavior.
resource_name This property is required. str
The unique name of the resource.
args This property is required. EmailSenderArgs
The arguments to resource properties.
opts ResourceOptions
Bag of options to control resource's behavior.
ctx Context
Context object for the current deployment.
name This property is required. string
The unique name of the resource.
args This property is required. EmailSenderArgs
The arguments to resource properties.
opts ResourceOption
Bag of options to control resource's behavior.
name This property is required. string
The unique name of the resource.
args This property is required. EmailSenderArgs
The arguments to resource properties.
opts CustomResourceOptions
Bag of options to control resource's behavior.
name This property is required. String
The unique name of the resource.
args This property is required. EmailSenderArgs
The arguments to resource properties.
options CustomResourceOptions
Bag of options to control resource's behavior.

Constructor example

The following reference example uses placeholder values for all input properties.

var emailSenderResource = new Okta.EmailSender("emailSenderResource", new()
{
    FromAddress = "string",
    FromName = "string",
    Subdomain = "string",
});
Copy
example, err := okta.NewEmailSender(ctx, "emailSenderResource", &okta.EmailSenderArgs{
	FromAddress: pulumi.String("string"),
	FromName:    pulumi.String("string"),
	Subdomain:   pulumi.String("string"),
})
Copy
var emailSenderResource = new EmailSender("emailSenderResource", EmailSenderArgs.builder()
    .fromAddress("string")
    .fromName("string")
    .subdomain("string")
    .build());
Copy
email_sender_resource = okta.EmailSender("emailSenderResource",
    from_address="string",
    from_name="string",
    subdomain="string")
Copy
const emailSenderResource = new okta.EmailSender("emailSenderResource", {
    fromAddress: "string",
    fromName: "string",
    subdomain: "string",
});
Copy
type: okta:EmailSender
properties:
    fromAddress: string
    fromName: string
    subdomain: string
Copy

EmailSender Resource Properties

To learn more about resource properties and how to use them, see Inputs and Outputs in the Architecture and Concepts docs.

Inputs

In Python, inputs that are objects can be passed either as argument classes or as dictionary literals.

The EmailSender resource accepts the following input properties:

FromAddress This property is required. string
Email address to send from
FromName This property is required. string
Name of sender
Subdomain
This property is required.
Changes to this property will trigger replacement.
string
Mail domain to send from
FromAddress This property is required. string
Email address to send from
FromName This property is required. string
Name of sender
Subdomain
This property is required.
Changes to this property will trigger replacement.
string
Mail domain to send from
fromAddress This property is required. String
Email address to send from
fromName This property is required. String
Name of sender
subdomain
This property is required.
Changes to this property will trigger replacement.
String
Mail domain to send from
fromAddress This property is required. string
Email address to send from
fromName This property is required. string
Name of sender
subdomain
This property is required.
Changes to this property will trigger replacement.
string
Mail domain to send from
from_address This property is required. str
Email address to send from
from_name This property is required. str
Name of sender
subdomain
This property is required.
Changes to this property will trigger replacement.
str
Mail domain to send from
fromAddress This property is required. String
Email address to send from
fromName This property is required. String
Name of sender
subdomain
This property is required.
Changes to this property will trigger replacement.
String
Mail domain to send from

Outputs

All input properties are implicitly available as output properties. Additionally, the EmailSender resource produces the following output properties:

DnsRecords List<EmailSenderDnsRecord>
TXT and CNAME records to be registered for the Domain
Id string
The provider-assigned unique ID for this managed resource.
Status string
Verification status
DnsRecords []EmailSenderDnsRecord
TXT and CNAME records to be registered for the Domain
Id string
The provider-assigned unique ID for this managed resource.
Status string
Verification status
dnsRecords List<EmailSenderDnsRecord>
TXT and CNAME records to be registered for the Domain
id String
The provider-assigned unique ID for this managed resource.
status String
Verification status
dnsRecords EmailSenderDnsRecord[]
TXT and CNAME records to be registered for the Domain
id string
The provider-assigned unique ID for this managed resource.
status string
Verification status
dns_records Sequence[EmailSenderDnsRecord]
TXT and CNAME records to be registered for the Domain
id str
The provider-assigned unique ID for this managed resource.
status str
Verification status
dnsRecords List<Property Map>
TXT and CNAME records to be registered for the Domain
id String
The provider-assigned unique ID for this managed resource.
status String
Verification status

Look up Existing EmailSender Resource

Get an existing EmailSender 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?: EmailSenderState, opts?: CustomResourceOptions): EmailSender
@staticmethod
def get(resource_name: str,
        id: str,
        opts: Optional[ResourceOptions] = None,
        dns_records: Optional[Sequence[EmailSenderDnsRecordArgs]] = None,
        from_address: Optional[str] = None,
        from_name: Optional[str] = None,
        status: Optional[str] = None,
        subdomain: Optional[str] = None) -> EmailSender
func GetEmailSender(ctx *Context, name string, id IDInput, state *EmailSenderState, opts ...ResourceOption) (*EmailSender, error)
public static EmailSender Get(string name, Input<string> id, EmailSenderState? state, CustomResourceOptions? opts = null)
public static EmailSender get(String name, Output<String> id, EmailSenderState state, CustomResourceOptions options)
resources:  _:    type: okta:EmailSender    get:      id: ${id}
name This property is required.
The unique name of the resulting resource.
id This property is required.
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 This property is required.
The unique name of the resulting resource.
id This property is required.
The unique provider ID of the resource to lookup.
name This property is required.
The unique name of the resulting resource.
id This property is required.
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 This property is required.
The unique name of the resulting resource.
id This property is required.
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 This property is required.
The unique name of the resulting resource.
id This property is required.
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.
The following state arguments are supported:
DnsRecords List<EmailSenderDnsRecord>
TXT and CNAME records to be registered for the Domain
FromAddress string
Email address to send from
FromName string
Name of sender
Status string
Verification status
Subdomain Changes to this property will trigger replacement. string
Mail domain to send from
DnsRecords []EmailSenderDnsRecordArgs
TXT and CNAME records to be registered for the Domain
FromAddress string
Email address to send from
FromName string
Name of sender
Status string
Verification status
Subdomain Changes to this property will trigger replacement. string
Mail domain to send from
dnsRecords List<EmailSenderDnsRecord>
TXT and CNAME records to be registered for the Domain
fromAddress String
Email address to send from
fromName String
Name of sender
status String
Verification status
subdomain Changes to this property will trigger replacement. String
Mail domain to send from
dnsRecords EmailSenderDnsRecord[]
TXT and CNAME records to be registered for the Domain
fromAddress string
Email address to send from
fromName string
Name of sender
status string
Verification status
subdomain Changes to this property will trigger replacement. string
Mail domain to send from
dns_records Sequence[EmailSenderDnsRecordArgs]
TXT and CNAME records to be registered for the Domain
from_address str
Email address to send from
from_name str
Name of sender
status str
Verification status
subdomain Changes to this property will trigger replacement. str
Mail domain to send from
dnsRecords List<Property Map>
TXT and CNAME records to be registered for the Domain
fromAddress String
Email address to send from
fromName String
Name of sender
status String
Verification status
subdomain Changes to this property will trigger replacement. String
Mail domain to send from

Supporting Types

EmailSenderDnsRecord
, EmailSenderDnsRecordArgs

Fqdn string
DNS record name
RecordType string
Record type can be TXT or CNAME
Value string
DNS verification value
Fqdn string
DNS record name
RecordType string
Record type can be TXT or CNAME
Value string
DNS verification value
fqdn String
DNS record name
recordType String
Record type can be TXT or CNAME
value String
DNS verification value
fqdn string
DNS record name
recordType string
Record type can be TXT or CNAME
value string
DNS verification value
fqdn str
DNS record name
record_type str
Record type can be TXT or CNAME
value str
DNS verification value
fqdn String
DNS record name
recordType String
Record type can be TXT or CNAME
value String
DNS verification value

Import

$ pulumi import okta:index/emailSender:EmailSender example <sender_id>
Copy

To learn more about importing existing cloud resources, see Importing resources.

Package Details

Repository
Okta pulumi/pulumi-okta
License
Apache-2.0
Notes
This Pulumi package is based on the okta Terraform Provider.