1. Packages
  2. Opentelekomcloud Provider
  3. API Docs
  4. getSmnMessageTemplatesV2
opentelekomcloud 1.36.45 published on Friday, Aug 15, 2025 by opentelekomcloud

opentelekomcloud.getSmnMessageTemplatesV2

Explore with Pulumi AI

opentelekomcloud logo
opentelekomcloud 1.36.45 published on Friday, Aug 15, 2025 by opentelekomcloud

    Use this data source to get the list of SMN message templates.

    Example Usage

    import * as pulumi from "@pulumi/pulumi";
    import * as opentelekomcloud from "@pulumi/opentelekomcloud";
    
    const config = new pulumi.Config();
    const name = config.requireObject("name");
    const test = opentelekomcloud.getSmnMessageTemplatesV2({
        name: name,
    });
    
    import pulumi
    import pulumi_opentelekomcloud as opentelekomcloud
    
    config = pulumi.Config()
    name = config.require_object("name")
    test = opentelekomcloud.get_smn_message_templates_v2(name=name)
    
    package main
    
    import (
    	"github.com/pulumi/pulumi-terraform-provider/sdks/go/opentelekomcloud/opentelekomcloud"
    	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
    	"github.com/pulumi/pulumi/sdk/v3/go/pulumi/config"
    )
    
    func main() {
    	pulumi.Run(func(ctx *pulumi.Context) error {
    		cfg := config.New(ctx, "")
    		name := cfg.RequireObject("name")
    		_, err := opentelekomcloud.GetSmnMessageTemplatesV2(ctx, &opentelekomcloud.GetSmnMessageTemplatesV2Args{
    			Name: pulumi.StringRef(name),
    		}, nil)
    		if err != nil {
    			return err
    		}
    		return nil
    	})
    }
    
    using System.Collections.Generic;
    using System.Linq;
    using Pulumi;
    using Opentelekomcloud = Pulumi.Opentelekomcloud;
    
    return await Deployment.RunAsync(() => 
    {
        var config = new Config();
        var name = config.RequireObject<dynamic>("name");
        var test = Opentelekomcloud.GetSmnMessageTemplatesV2.Invoke(new()
        {
            Name = name,
        });
    
    });
    
    package generated_program;
    
    import com.pulumi.Context;
    import com.pulumi.Pulumi;
    import com.pulumi.core.Output;
    import com.pulumi.opentelekomcloud.OpentelekomcloudFunctions;
    import com.pulumi.opentelekomcloud.inputs.GetSmnMessageTemplatesV2Args;
    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) {
            final var config = ctx.config();
            final var name = config.get("name");
            final var test = OpentelekomcloudFunctions.getSmnMessageTemplatesV2(GetSmnMessageTemplatesV2Args.builder()
                .name(name)
                .build());
    
        }
    }
    
    configuration:
      name:
        type: dynamic
    variables:
      test:
        fn::invoke:
          function: opentelekomcloud:getSmnMessageTemplatesV2
          arguments:
            name: ${name}
    

    Using getSmnMessageTemplatesV2

    Two invocation forms are available. The direct form accepts plain arguments and either blocks until the result value is available, or returns a Promise-wrapped result. The output form accepts Input-wrapped arguments and returns an Output-wrapped result.

    function getSmnMessageTemplatesV2(args: GetSmnMessageTemplatesV2Args, opts?: InvokeOptions): Promise<GetSmnMessageTemplatesV2Result>
    function getSmnMessageTemplatesV2Output(args: GetSmnMessageTemplatesV2OutputArgs, opts?: InvokeOptions): Output<GetSmnMessageTemplatesV2Result>
    def get_smn_message_templates_v2(id: Optional[str] = None,
                                     name: Optional[str] = None,
                                     protocol: Optional[str] = None,
                                     template_id: Optional[str] = None,
                                     opts: Optional[InvokeOptions] = None) -> GetSmnMessageTemplatesV2Result
    def get_smn_message_templates_v2_output(id: Optional[pulumi.Input[str]] = None,
                                     name: Optional[pulumi.Input[str]] = None,
                                     protocol: Optional[pulumi.Input[str]] = None,
                                     template_id: Optional[pulumi.Input[str]] = None,
                                     opts: Optional[InvokeOptions] = None) -> Output[GetSmnMessageTemplatesV2Result]
    func GetSmnMessageTemplatesV2(ctx *Context, args *GetSmnMessageTemplatesV2Args, opts ...InvokeOption) (*GetSmnMessageTemplatesV2Result, error)
    func GetSmnMessageTemplatesV2Output(ctx *Context, args *GetSmnMessageTemplatesV2OutputArgs, opts ...InvokeOption) GetSmnMessageTemplatesV2ResultOutput

    > Note: This function is named GetSmnMessageTemplatesV2 in the Go SDK.

    public static class GetSmnMessageTemplatesV2 
    {
        public static Task<GetSmnMessageTemplatesV2Result> InvokeAsync(GetSmnMessageTemplatesV2Args args, InvokeOptions? opts = null)
        public static Output<GetSmnMessageTemplatesV2Result> Invoke(GetSmnMessageTemplatesV2InvokeArgs args, InvokeOptions? opts = null)
    }
    public static CompletableFuture<GetSmnMessageTemplatesV2Result> getSmnMessageTemplatesV2(GetSmnMessageTemplatesV2Args args, InvokeOptions options)
    public static Output<GetSmnMessageTemplatesV2Result> getSmnMessageTemplatesV2(GetSmnMessageTemplatesV2Args args, InvokeOptions options)
    
    fn::invoke:
      function: opentelekomcloud:index/getSmnMessageTemplatesV2:getSmnMessageTemplatesV2
      arguments:
        # arguments dictionary

    The following arguments are supported:

    Id string
    Indicates the message template ID.
    Name string
    Specifies the name of the message template.
    Protocol string
    Specifies the protocol of the message template.
    TemplateId string
    Specifies the message template ID.
    Id string
    Indicates the message template ID.
    Name string
    Specifies the name of the message template.
    Protocol string
    Specifies the protocol of the message template.
    TemplateId string
    Specifies the message template ID.
    id String
    Indicates the message template ID.
    name String
    Specifies the name of the message template.
    protocol String
    Specifies the protocol of the message template.
    templateId String
    Specifies the message template ID.
    id string
    Indicates the message template ID.
    name string
    Specifies the name of the message template.
    protocol string
    Specifies the protocol of the message template.
    templateId string
    Specifies the message template ID.
    id str
    Indicates the message template ID.
    name str
    Specifies the name of the message template.
    protocol str
    Specifies the protocol of the message template.
    template_id str
    Specifies the message template ID.
    id String
    Indicates the message template ID.
    name String
    Specifies the name of the message template.
    protocol String
    Specifies the protocol of the message template.
    templateId String
    Specifies the message template ID.

    getSmnMessageTemplatesV2 Result

    The following output properties are available:

    Id string
    Indicates the message template ID.
    Templates List<GetSmnMessageTemplatesV2Template>
    The list of message templates. The templates structure is documented below.
    Name string
    Indicates the message template name.
    Protocol string
    Indicates the protocol supported by the template.
    TemplateId string
    Id string
    Indicates the message template ID.
    Templates []GetSmnMessageTemplatesV2Template
    The list of message templates. The templates structure is documented below.
    Name string
    Indicates the message template name.
    Protocol string
    Indicates the protocol supported by the template.
    TemplateId string
    id String
    Indicates the message template ID.
    templates List<GetSmnMessageTemplatesV2Template>
    The list of message templates. The templates structure is documented below.
    name String
    Indicates the message template name.
    protocol String
    Indicates the protocol supported by the template.
    templateId String
    id string
    Indicates the message template ID.
    templates GetSmnMessageTemplatesV2Template[]
    The list of message templates. The templates structure is documented below.
    name string
    Indicates the message template name.
    protocol string
    Indicates the protocol supported by the template.
    templateId string
    id str
    Indicates the message template ID.
    templates Sequence[GetSmnMessageTemplatesV2Template]
    The list of message templates. The templates structure is documented below.
    name str
    Indicates the message template name.
    protocol str
    Indicates the protocol supported by the template.
    template_id str
    id String
    Indicates the message template ID.
    templates List<Property Map>
    The list of message templates. The templates structure is documented below.
    name String
    Indicates the message template name.
    protocol String
    Indicates the protocol supported by the template.
    templateId String

    Supporting Types

    GetSmnMessageTemplatesV2Template

    CreatedAt string
    Indicates the create time.
    Id string
    Indicates the message template ID.
    Name string
    Specifies the name of the message template.
    Protocol string
    Specifies the protocol of the message template.
    TagNames List<string>
    Indicates the variable list. The variable name will be quoted in braces ({}) in the template. When you use a template to send messages, you can replace the variable with any content.
    UpdatedAt string
    Indicates the update time.
    CreatedAt string
    Indicates the create time.
    Id string
    Indicates the message template ID.
    Name string
    Specifies the name of the message template.
    Protocol string
    Specifies the protocol of the message template.
    TagNames []string
    Indicates the variable list. The variable name will be quoted in braces ({}) in the template. When you use a template to send messages, you can replace the variable with any content.
    UpdatedAt string
    Indicates the update time.
    createdAt String
    Indicates the create time.
    id String
    Indicates the message template ID.
    name String
    Specifies the name of the message template.
    protocol String
    Specifies the protocol of the message template.
    tagNames List<String>
    Indicates the variable list. The variable name will be quoted in braces ({}) in the template. When you use a template to send messages, you can replace the variable with any content.
    updatedAt String
    Indicates the update time.
    createdAt string
    Indicates the create time.
    id string
    Indicates the message template ID.
    name string
    Specifies the name of the message template.
    protocol string
    Specifies the protocol of the message template.
    tagNames string[]
    Indicates the variable list. The variable name will be quoted in braces ({}) in the template. When you use a template to send messages, you can replace the variable with any content.
    updatedAt string
    Indicates the update time.
    created_at str
    Indicates the create time.
    id str
    Indicates the message template ID.
    name str
    Specifies the name of the message template.
    protocol str
    Specifies the protocol of the message template.
    tag_names Sequence[str]
    Indicates the variable list. The variable name will be quoted in braces ({}) in the template. When you use a template to send messages, you can replace the variable with any content.
    updated_at str
    Indicates the update time.
    createdAt String
    Indicates the create time.
    id String
    Indicates the message template ID.
    name String
    Specifies the name of the message template.
    protocol String
    Specifies the protocol of the message template.
    tagNames List<String>
    Indicates the variable list. The variable name will be quoted in braces ({}) in the template. When you use a template to send messages, you can replace the variable with any content.
    updatedAt String
    Indicates the update time.

    Package Details

    Repository
    opentelekomcloud opentelekomcloud/terraform-provider-opentelekomcloud
    License
    Notes
    This Pulumi package is based on the opentelekomcloud Terraform Provider.
    opentelekomcloud logo
    opentelekomcloud 1.36.45 published on Friday, Aug 15, 2025 by opentelekomcloud