Class V2modelsBot


  • public class V2modelsBot
    extends com.pulumi.resources.CustomResource
    Resource for managing an AWS Lex V2 Models Bot. ## Example Usage ### Basic Usage
     
     package generated_program;
     
     import com.pulumi.Context;
     import com.pulumi.Pulumi;
     import com.pulumi.core.Output;
     import com.pulumi.aws.iam.Role;
     import com.pulumi.aws.iam.RoleArgs;
     import com.pulumi.aws.lex.V2modelsBot;
     import com.pulumi.aws.lex.V2modelsBotArgs;
     import com.pulumi.aws.lex.inputs.V2modelsBotDataPrivacyArgs;
     import static com.pulumi.codegen.internal.Serialization.*;
     import java.util.ArrayList;
     import java.util.Arrays;
     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 exampleRole = new Role("exampleRole", RoleArgs.builder()
                 .name("example")
                 .assumeRolePolicy(serializeJson(
                     jsonObject(
                         jsonProperty("Version", "2012-10-17"),
                         jsonProperty("Statement", jsonArray(jsonObject(
                             jsonProperty("Action", "sts:AssumeRole"),
                             jsonProperty("Effect", "Allow"),
                             jsonProperty("Sid", ""),
                             jsonProperty("Principal", jsonObject(
                                 jsonProperty("Service", "lexv2.amazonaws.com")
                             ))
                         )))
                     )))
                 .tags(Map.of("created_by", "aws"))
                 .build());
     
             var example = new V2modelsBot("example", V2modelsBotArgs.builder()
                 .dataPrivacies(V2modelsBotDataPrivacyArgs.builder()
                     .childDirected(false)
                     .build())
                 .name("example")
                 .description("Example description")
                 .idleSessionTtlInSeconds(60)
                 .roleArn(exampleRole.arn())
                 .type("Bot")
                 .tags(Map.of("foo", "bar"))
                 .build());
     
         }
     }
     
     
    ## Import Using `pulumi import`, import Lex V2 Models Bot using the `id`. For example: ```sh $ pulumi import aws:lex/v2modelsBot:V2modelsBot example bot-id-12345678 ```
    • Nested Class Summary

      • Nested classes/interfaces inherited from class com.pulumi.resources.CustomResource

        com.pulumi.resources.CustomResource.CustomResourceInternal
      • Nested classes/interfaces inherited from class com.pulumi.resources.Resource

        com.pulumi.resources.Resource.LazyField<T extends java.lang.Object>, com.pulumi.resources.Resource.LazyFields, com.pulumi.resources.Resource.ResourceInternal
    • Field Summary

      • Fields inherited from class com.pulumi.resources.Resource

        childResources, remote
    • Method Summary

      All Methods Static Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      com.pulumi.core.Output<java.lang.String> arn()  
      com.pulumi.core.Output<java.util.List<V2modelsBotDataPrivacy>> dataPrivacies()  
      com.pulumi.core.Output<java.util.Optional<java.lang.String>> description()  
      static V2modelsBot get​(java.lang.String name, com.pulumi.core.Output<java.lang.String> id, V2modelsBotState state, com.pulumi.resources.CustomResourceOptions options)
      Get an existing Host resource's state with the given name, ID, and optional extra properties used to qualify the lookup.
      com.pulumi.core.Output<java.lang.Integer> idleSessionTtlInSeconds()  
      com.pulumi.core.Output<java.util.Optional<java.util.List<V2modelsBotMember>>> members()  
      com.pulumi.core.Output<java.lang.String> name()  
      com.pulumi.core.Output<java.lang.String> region()  
      com.pulumi.core.Output<java.lang.String> roleArn()  
      com.pulumi.core.Output<java.util.Optional<java.util.Map<java.lang.String,​java.lang.String>>> tags()  
      com.pulumi.core.Output<java.util.Map<java.lang.String,​java.lang.String>> tagsAll()  
      com.pulumi.core.Output<java.util.Optional<java.util.Map<java.lang.String,​java.lang.String>>> testBotAliasTags()  
      com.pulumi.core.Output<java.util.Optional<V2modelsBotTimeouts>> timeouts()  
      com.pulumi.core.Output<java.lang.String> type()  
      • Methods inherited from class com.pulumi.resources.CustomResource

        getId, id, idFuture
      • Methods inherited from class com.pulumi.resources.Resource

        getChildResources, getResourceName, getResourceType, getUrn, pulumiChildResources, pulumiResourceName, pulumiResourceType, urn
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Constructor Detail

      • V2modelsBot

        public V2modelsBot​(java.lang.String name)
        Parameters:
        name - The _unique_ name of the resulting resource.
      • V2modelsBot

        public V2modelsBot​(java.lang.String name,
                           V2modelsBotArgs args)
        Parameters:
        name - The _unique_ name of the resulting resource.
        args - The arguments to use to populate this resource's properties.
      • V2modelsBot

        public V2modelsBot​(java.lang.String name,
                           V2modelsBotArgs args,
                           @Nullable
                           com.pulumi.resources.CustomResourceOptions options)
        Parameters:
        name - The _unique_ name of the resulting resource.
        args - The arguments to use to populate this resource's properties.
        options - A bag of options that control this resource's behavior.
    • Method Detail

      • arn

        public com.pulumi.core.Output<java.lang.String> arn()
      • dataPrivacies

        public com.pulumi.core.Output<java.util.List<V2modelsBotDataPrivacy>> dataPrivacies()
        Returns:
        Provides information on additional privacy protections Amazon Lex should use with the bot's data. See `dataPrivacy`
      • description

        public com.pulumi.core.Output<java.util.Optional<java.lang.String>> description()
        Returns:
        Description of the bot. It appears in lists to help you identify a particular bot.
      • idleSessionTtlInSeconds

        public com.pulumi.core.Output<java.lang.Integer> idleSessionTtlInSeconds()
        Returns:
        Time, in seconds, that Amazon Lex should keep information about a user's conversation with the bot. You can specify between 60 (1 minute) and 86,400 (24 hours) seconds.
      • members

        public com.pulumi.core.Output<java.util.Optional<java.util.List<V2modelsBotMember>>> members()
        Returns:
        List of bot members in a network to be created. See `botMembers`.
      • name

        public com.pulumi.core.Output<java.lang.String> name()
        Returns:
        Name of the bot. The bot name must be unique in the account that creates the bot. Type String. Length Constraints: Minimum length of 1. Maximum length of 100.
      • region

        public com.pulumi.core.Output<java.lang.String> region()
        Returns:
        Region where this resource will be [managed](https://docs.aws.amazon.com/general/latest/gr/rande.html#regional-endpoints). Defaults to the Region set in the provider configuration.
      • roleArn

        public com.pulumi.core.Output<java.lang.String> roleArn()
        Returns:
        ARN of an IAM role that has permission to access the bot. The following arguments are optional:
      • tags

        public com.pulumi.core.Output<java.util.Optional<java.util.Map<java.lang.String,​java.lang.String>>> tags()
        Returns:
        List of tags to add to the bot. You can only add tags when you create a bot.
      • tagsAll

        public com.pulumi.core.Output<java.util.Map<java.lang.String,​java.lang.String>> tagsAll()
      • testBotAliasTags

        public com.pulumi.core.Output<java.util.Optional<java.util.Map<java.lang.String,​java.lang.String>>> testBotAliasTags()
        Returns:
        List of tags to add to the test alias for a bot. You can only add tags when you create a bot.
      • type

        public com.pulumi.core.Output<java.lang.String> type()
        Returns:
        Type of a bot to create. Possible values are `"Bot"` and `"BotNetwork"`.
      • get

        public static V2modelsBot get​(java.lang.String name,
                                      com.pulumi.core.Output<java.lang.String> id,
                                      @Nullable
                                      V2modelsBotState state,
                                      @Nullable
                                      com.pulumi.resources.CustomResourceOptions options)
        Get an existing Host resource's state with the given name, ID, and optional extra properties used to qualify the lookup.
        Parameters:
        name - The _unique_ name of the resulting resource.
        id - The _unique_ provider ID of the resource to lookup.
        state -
        options - Optional settings to control the behavior of the CustomResource.