published on Sunday, Oct 11, 2026 by Descope
published on Sunday, Oct 11, 2026 by Descope
Manages a single text message template for an authentication method in a Descope project. The active template is selected on the method’s settings resource, e.g. the textTemplateId attribute of descope.MagiclinkSettings.
Create TextTemplate Resource
Resources are created with functions called constructors. To learn more about declaring and configuring resources, see Resources.
Constructor syntax
new TextTemplate(name: string, args: TextTemplateArgs, opts?: CustomResourceOptions);@overload
def TextTemplate(resource_name: str,
args: TextTemplateArgs,
opts: Optional[ResourceOptions] = None)
@overload
def TextTemplate(resource_name: str,
opts: Optional[ResourceOptions] = None,
body: Optional[str] = None,
method: Optional[str] = None,
project_id: Optional[str] = None,
name: Optional[str] = None)func NewTextTemplate(ctx *Context, name string, args TextTemplateArgs, opts ...ResourceOption) (*TextTemplate, error)public TextTemplate(string name, TextTemplateArgs args, CustomResourceOptions? opts = null)
public TextTemplate(String name, TextTemplateArgs args)
public TextTemplate(String name, TextTemplateArgs args, CustomResourceOptions options)
type: descope:TextTemplate
properties: # The arguments to resource properties.
options: # Bag of options to control resource's behavior.
resource "descope_text_template" "name" {
# resource properties
}Parameters
- name string
- The unique name of the resource.
- args TextTemplateArgs
- 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 TextTemplateArgs
- 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 TextTemplateArgs
- The arguments to resource properties.
- opts ResourceOption
- Bag of options to control resource's behavior.
- name string
- The unique name of the resource.
- args TextTemplateArgs
- The arguments to resource properties.
- opts CustomResourceOptions
- Bag of options to control resource's behavior.
- name String
- The unique name of the resource.
- args TextTemplateArgs
- 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 textTemplateResource = new Descope.TextTemplate("textTemplateResource", new()
{
Body = "string",
Method = "string",
ProjectId = "string",
Name = "string",
});
example, err := descope.NewTextTemplate(ctx, "textTemplateResource", &descope.TextTemplateArgs{
Body: pulumi.String("string"),
Method: pulumi.String("string"),
ProjectId: pulumi.String("string"),
Name: pulumi.String("string"),
})
resource "descope_text_template" "textTemplateResource" {
lifecycle {
create_before_destroy = true
}
body = "string"
method = "string"
project_id = "string"
name = "string"
}
var textTemplateResource = new TextTemplate("textTemplateResource", TextTemplateArgs.builder()
.body("string")
.method("string")
.projectId("string")
.name("string")
.build());
text_template_resource = descope.TextTemplate("textTemplateResource",
body="string",
method="string",
project_id="string",
name="string")
const textTemplateResource = new descope.TextTemplate("textTemplateResource", {
body: "string",
method: "string",
projectId: "string",
name: "string",
});
type: descope:TextTemplate
properties:
body: string
method: string
name: string
projectId: string
TextTemplate 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 TextTemplate resource accepts the following input properties:
- Body string
- The body of text messages sent with this template. Template macros such as
{{.code}}can be used to insert dynamic values. - Method string
- The authentication method the text template is used with, e.g.
magiclink,otporenchantedlink. Changing this value will require the resource to be deleted and recreated. - Project
Id string - The ID of the project that the text template belongs to. Changing this value will require the resource to be deleted and recreated.
- Name string
- A name for the text template that's unique among the templates of the same authentication method.
- Body string
- The body of text messages sent with this template. Template macros such as
{{.code}}can be used to insert dynamic values. - Method string
- The authentication method the text template is used with, e.g.
magiclink,otporenchantedlink. Changing this value will require the resource to be deleted and recreated. - Project
Id string - The ID of the project that the text template belongs to. Changing this value will require the resource to be deleted and recreated.
- Name string
- A name for the text template that's unique among the templates of the same authentication method.
- body string
- The body of text messages sent with this template. Template macros such as
{{.code}}can be used to insert dynamic values. - method string
- The authentication method the text template is used with, e.g.
magiclink,otporenchantedlink. Changing this value will require the resource to be deleted and recreated. - project_
id string - The ID of the project that the text template belongs to. Changing this value will require the resource to be deleted and recreated.
- name string
- A name for the text template that's unique among the templates of the same authentication method.
- body String
- The body of text messages sent with this template. Template macros such as
{{.code}}can be used to insert dynamic values. - method String
- The authentication method the text template is used with, e.g.
magiclink,otporenchantedlink. Changing this value will require the resource to be deleted and recreated. - project
Id String - The ID of the project that the text template belongs to. Changing this value will require the resource to be deleted and recreated.
- name String
- A name for the text template that's unique among the templates of the same authentication method.
- body string
- The body of text messages sent with this template. Template macros such as
{{.code}}can be used to insert dynamic values. - method string
- The authentication method the text template is used with, e.g.
magiclink,otporenchantedlink. Changing this value will require the resource to be deleted and recreated. - project
Id string - The ID of the project that the text template belongs to. Changing this value will require the resource to be deleted and recreated.
- name string
- A name for the text template that's unique among the templates of the same authentication method.
- body str
- The body of text messages sent with this template. Template macros such as
{{.code}}can be used to insert dynamic values. - method str
- The authentication method the text template is used with, e.g.
magiclink,otporenchantedlink. Changing this value will require the resource to be deleted and recreated. - project_
id str - The ID of the project that the text template belongs to. Changing this value will require the resource to be deleted and recreated.
- name str
- A name for the text template that's unique among the templates of the same authentication method.
- body String
- The body of text messages sent with this template. Template macros such as
{{.code}}can be used to insert dynamic values. - method String
- The authentication method the text template is used with, e.g.
magiclink,otporenchantedlink. Changing this value will require the resource to be deleted and recreated. - project
Id String - The ID of the project that the text template belongs to. Changing this value will require the resource to be deleted and recreated.
- name String
- A name for the text template that's unique among the templates of the same authentication method.
Outputs
All input properties are implicitly available as output properties. Additionally, the TextTemplate 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 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 TextTemplate Resource
Get an existing TextTemplate 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?: TextTemplateState, opts?: CustomResourceOptions): TextTemplate@staticmethod
def get(resource_name: str,
id: str,
opts: Optional[ResourceOptions] = None,
body: Optional[str] = None,
method: Optional[str] = None,
name: Optional[str] = None,
project_id: Optional[str] = None) -> TextTemplatefunc GetTextTemplate(ctx *Context, name string, id IDInput, state *TextTemplateState, opts ...ResourceOption) (*TextTemplate, error)public static TextTemplate Get(string name, Input<string> id, TextTemplateState? state, CustomResourceOptions? opts = null)public static TextTemplate get(String name, Output<String> id, TextTemplateState state, CustomResourceOptions options)resources: existingTextTemplate: type: descope:TextTemplate get: id: ${id}import {
to = descope_text_template.example
id = "${id}"
}
- name string
- The unique name of the resulting resource.
- id Input<ID>
- The unique provider ID of the resource to look up.
- state TextTemplateState
- Known property values the provider needs, along with the ID, to find the resource. Usually not required.
- opts CustomResourceOptions
- Bag of options to control resource's behavior.
- resource_name str
- The unique name of the resulting resource.
- id str
- The unique provider ID of the resource to look up.
- 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 resulting resource.
- id IDInput
- The unique provider ID of the resource to look up.
- state TextTemplateState
- Known property values the provider needs, along with the ID, to find the resource. Usually not required.
- opts ResourceOption
- Bag of options to control resource's behavior.
- name string
- The unique name of the resulting resource.
- id Input<string>
- The unique provider ID of the resource to look up.
- state TextTemplateState
- Known property values the provider needs, along with the ID, to find the resource. Usually not required.
- opts CustomResourceOptions
- Bag of options to control resource's behavior.
- name String
- The unique name of the resulting resource.
- id Output<String>
- The unique provider ID of the resource to look up.
- state TextTemplateState
- Known property values the provider needs, along with the ID, to find the resource. Usually not required.
- options CustomResourceOptions
- Bag of options to control resource's behavior.
- Body string
- The body of text messages sent with this template. Template macros such as
{{.code}}can be used to insert dynamic values. - Method string
- The authentication method the text template is used with, e.g.
magiclink,otporenchantedlink. Changing this value will require the resource to be deleted and recreated. - Name string
- A name for the text template that's unique among the templates of the same authentication method.
- Project
Id string - The ID of the project that the text template belongs to. Changing this value will require the resource to be deleted and recreated.
- Body string
- The body of text messages sent with this template. Template macros such as
{{.code}}can be used to insert dynamic values. - Method string
- The authentication method the text template is used with, e.g.
magiclink,otporenchantedlink. Changing this value will require the resource to be deleted and recreated. - Name string
- A name for the text template that's unique among the templates of the same authentication method.
- Project
Id string - The ID of the project that the text template belongs to. Changing this value will require the resource to be deleted and recreated.
- body string
- The body of text messages sent with this template. Template macros such as
{{.code}}can be used to insert dynamic values. - method string
- The authentication method the text template is used with, e.g.
magiclink,otporenchantedlink. Changing this value will require the resource to be deleted and recreated. - name string
- A name for the text template that's unique among the templates of the same authentication method.
- project_
id string - The ID of the project that the text template belongs to. Changing this value will require the resource to be deleted and recreated.
- body String
- The body of text messages sent with this template. Template macros such as
{{.code}}can be used to insert dynamic values. - method String
- The authentication method the text template is used with, e.g.
magiclink,otporenchantedlink. Changing this value will require the resource to be deleted and recreated. - name String
- A name for the text template that's unique among the templates of the same authentication method.
- project
Id String - The ID of the project that the text template belongs to. Changing this value will require the resource to be deleted and recreated.
- body string
- The body of text messages sent with this template. Template macros such as
{{.code}}can be used to insert dynamic values. - method string
- The authentication method the text template is used with, e.g.
magiclink,otporenchantedlink. Changing this value will require the resource to be deleted and recreated. - name string
- A name for the text template that's unique among the templates of the same authentication method.
- project
Id string - The ID of the project that the text template belongs to. Changing this value will require the resource to be deleted and recreated.
- body str
- The body of text messages sent with this template. Template macros such as
{{.code}}can be used to insert dynamic values. - method str
- The authentication method the text template is used with, e.g.
magiclink,otporenchantedlink. Changing this value will require the resource to be deleted and recreated. - name str
- A name for the text template that's unique among the templates of the same authentication method.
- project_
id str - The ID of the project that the text template belongs to. Changing this value will require the resource to be deleted and recreated.
- body String
- The body of text messages sent with this template. Template macros such as
{{.code}}can be used to insert dynamic values. - method String
- The authentication method the text template is used with, e.g.
magiclink,otporenchantedlink. Changing this value will require the resource to be deleted and recreated. - name String
- A name for the text template that's unique among the templates of the same authentication method.
- project
Id String - The ID of the project that the text template belongs to. Changing this value will require the resource to be deleted and recreated.
Package Details
- Repository
- descope descope/pulumi-descope
- License
- Apache-2.0
- Notes
- This Pulumi package is based on the
descopeTerraform Provider.
published on Sunday, Oct 11, 2026 by Descope