1. Packages
  2. AWS Classic
  3. API Docs
  4. opensearch
  5. getServerlessCollection

Try AWS Native preview for resources not in the classic version.

AWS Classic v6.33.1 published on Thursday, May 2, 2024 by Pulumi

aws.opensearch.getServerlessCollection

Explore with Pulumi AI

aws logo

Try AWS Native preview for resources not in the classic version.

AWS Classic v6.33.1 published on Thursday, May 2, 2024 by Pulumi

    Data source for managing an AWS OpenSearch Serverless Collection.

    Example Usage

    Basic Usage

    import * as pulumi from "@pulumi/pulumi";
    import * as aws from "@pulumi/aws";
    
    const example = aws.opensearch.getServerlessCollection({
        name: "example",
    });
    
    import pulumi
    import pulumi_aws as aws
    
    example = aws.opensearch.get_serverless_collection(name="example")
    
    package main
    
    import (
    	"github.com/pulumi/pulumi-aws/sdk/v6/go/aws/opensearch"
    	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
    )
    
    func main() {
    	pulumi.Run(func(ctx *pulumi.Context) error {
    		_, err := opensearch.LookupServerlessCollection(ctx, &opensearch.LookupServerlessCollectionArgs{
    			Name: pulumi.StringRef("example"),
    		}, nil)
    		if err != nil {
    			return err
    		}
    		return nil
    	})
    }
    
    using System.Collections.Generic;
    using System.Linq;
    using Pulumi;
    using Aws = Pulumi.Aws;
    
    return await Deployment.RunAsync(() => 
    {
        var example = Aws.OpenSearch.GetServerlessCollection.Invoke(new()
        {
            Name = "example",
        });
    
    });
    
    package generated_program;
    
    import com.pulumi.Context;
    import com.pulumi.Pulumi;
    import com.pulumi.core.Output;
    import com.pulumi.aws.opensearch.OpensearchFunctions;
    import com.pulumi.aws.opensearch.inputs.GetServerlessCollectionArgs;
    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 example = OpensearchFunctions.getServerlessCollection(GetServerlessCollectionArgs.builder()
                .name("example")
                .build());
    
        }
    }
    
    variables:
      example:
        fn::invoke:
          Function: aws:opensearch:getServerlessCollection
          Arguments:
            name: example
    

    Using getServerlessCollection

    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 getServerlessCollection(args: GetServerlessCollectionArgs, opts?: InvokeOptions): Promise<GetServerlessCollectionResult>
    function getServerlessCollectionOutput(args: GetServerlessCollectionOutputArgs, opts?: InvokeOptions): Output<GetServerlessCollectionResult>
    def get_serverless_collection(id: Optional[str] = None,
                                  name: Optional[str] = None,
                                  opts: Optional[InvokeOptions] = None) -> GetServerlessCollectionResult
    def get_serverless_collection_output(id: Optional[pulumi.Input[str]] = None,
                                  name: Optional[pulumi.Input[str]] = None,
                                  opts: Optional[InvokeOptions] = None) -> Output[GetServerlessCollectionResult]
    func LookupServerlessCollection(ctx *Context, args *LookupServerlessCollectionArgs, opts ...InvokeOption) (*LookupServerlessCollectionResult, error)
    func LookupServerlessCollectionOutput(ctx *Context, args *LookupServerlessCollectionOutputArgs, opts ...InvokeOption) LookupServerlessCollectionResultOutput

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

    public static class GetServerlessCollection 
    {
        public static Task<GetServerlessCollectionResult> InvokeAsync(GetServerlessCollectionArgs args, InvokeOptions? opts = null)
        public static Output<GetServerlessCollectionResult> Invoke(GetServerlessCollectionInvokeArgs args, InvokeOptions? opts = null)
    }
    public static CompletableFuture<GetServerlessCollectionResult> getServerlessCollection(GetServerlessCollectionArgs args, InvokeOptions options)
    // Output-based functions aren't available in Java yet
    
    fn::invoke:
      function: aws:opensearch/getServerlessCollection:getServerlessCollection
      arguments:
        # arguments dictionary

    The following arguments are supported:

    Id string
    ID of the collection. Either id or name must be provided.
    Name string
    Name of the collection. Either name or id must be provided.
    Id string
    ID of the collection. Either id or name must be provided.
    Name string
    Name of the collection. Either name or id must be provided.
    id String
    ID of the collection. Either id or name must be provided.
    name String
    Name of the collection. Either name or id must be provided.
    id string
    ID of the collection. Either id or name must be provided.
    name string
    Name of the collection. Either name or id must be provided.
    id str
    ID of the collection. Either id or name must be provided.
    name str
    Name of the collection. Either name or id must be provided.
    id String
    ID of the collection. Either id or name must be provided.
    name String
    Name of the collection. Either name or id must be provided.

    getServerlessCollection Result

    The following output properties are available:

    Arn string
    Amazon Resource Name (ARN) of the collection.
    CollectionEndpoint string
    Collection-specific endpoint used to submit index, search, and data upload requests to an OpenSearch Serverless collection.
    CreatedDate string
    Date the Collection was created.
    DashboardEndpoint string
    Collection-specific endpoint used to access OpenSearch Dashboards.
    Description string
    Description of the collection.
    Id string
    KmsKeyArn string
    The ARN of the Amazon Web Services KMS key used to encrypt the collection.
    LastModifiedDate string
    Date the Collection was last modified.
    Name string
    StandbyReplicas string
    Indicates whether standby replicas should be used for a collection.
    Tags Dictionary<string, string>
    A map of tags to assign to the collection.
    Type string
    Type of collection.
    Arn string
    Amazon Resource Name (ARN) of the collection.
    CollectionEndpoint string
    Collection-specific endpoint used to submit index, search, and data upload requests to an OpenSearch Serverless collection.
    CreatedDate string
    Date the Collection was created.
    DashboardEndpoint string
    Collection-specific endpoint used to access OpenSearch Dashboards.
    Description string
    Description of the collection.
    Id string
    KmsKeyArn string
    The ARN of the Amazon Web Services KMS key used to encrypt the collection.
    LastModifiedDate string
    Date the Collection was last modified.
    Name string
    StandbyReplicas string
    Indicates whether standby replicas should be used for a collection.
    Tags map[string]string
    A map of tags to assign to the collection.
    Type string
    Type of collection.
    arn String
    Amazon Resource Name (ARN) of the collection.
    collectionEndpoint String
    Collection-specific endpoint used to submit index, search, and data upload requests to an OpenSearch Serverless collection.
    createdDate String
    Date the Collection was created.
    dashboardEndpoint String
    Collection-specific endpoint used to access OpenSearch Dashboards.
    description String
    Description of the collection.
    id String
    kmsKeyArn String
    The ARN of the Amazon Web Services KMS key used to encrypt the collection.
    lastModifiedDate String
    Date the Collection was last modified.
    name String
    standbyReplicas String
    Indicates whether standby replicas should be used for a collection.
    tags Map<String,String>
    A map of tags to assign to the collection.
    type String
    Type of collection.
    arn string
    Amazon Resource Name (ARN) of the collection.
    collectionEndpoint string
    Collection-specific endpoint used to submit index, search, and data upload requests to an OpenSearch Serverless collection.
    createdDate string
    Date the Collection was created.
    dashboardEndpoint string
    Collection-specific endpoint used to access OpenSearch Dashboards.
    description string
    Description of the collection.
    id string
    kmsKeyArn string
    The ARN of the Amazon Web Services KMS key used to encrypt the collection.
    lastModifiedDate string
    Date the Collection was last modified.
    name string
    standbyReplicas string
    Indicates whether standby replicas should be used for a collection.
    tags {[key: string]: string}
    A map of tags to assign to the collection.
    type string
    Type of collection.
    arn str
    Amazon Resource Name (ARN) of the collection.
    collection_endpoint str
    Collection-specific endpoint used to submit index, search, and data upload requests to an OpenSearch Serverless collection.
    created_date str
    Date the Collection was created.
    dashboard_endpoint str
    Collection-specific endpoint used to access OpenSearch Dashboards.
    description str
    Description of the collection.
    id str
    kms_key_arn str
    The ARN of the Amazon Web Services KMS key used to encrypt the collection.
    last_modified_date str
    Date the Collection was last modified.
    name str
    standby_replicas str
    Indicates whether standby replicas should be used for a collection.
    tags Mapping[str, str]
    A map of tags to assign to the collection.
    type str
    Type of collection.
    arn String
    Amazon Resource Name (ARN) of the collection.
    collectionEndpoint String
    Collection-specific endpoint used to submit index, search, and data upload requests to an OpenSearch Serverless collection.
    createdDate String
    Date the Collection was created.
    dashboardEndpoint String
    Collection-specific endpoint used to access OpenSearch Dashboards.
    description String
    Description of the collection.
    id String
    kmsKeyArn String
    The ARN of the Amazon Web Services KMS key used to encrypt the collection.
    lastModifiedDate String
    Date the Collection was last modified.
    name String
    standbyReplicas String
    Indicates whether standby replicas should be used for a collection.
    tags Map<String>
    A map of tags to assign to the collection.
    type String
    Type of collection.

    Package Details

    Repository
    AWS Classic pulumi/pulumi-aws
    License
    Apache-2.0
    Notes
    This Pulumi package is based on the aws Terraform Provider.
    aws logo

    Try AWS Native preview for resources not in the classic version.

    AWS Classic v6.33.1 published on Thursday, May 2, 2024 by Pulumi