1. Packages
  2. AWS
  3. API Docs
  4. qldb
  5. getLedger
AWS v7.11.0 published on Wednesday, Nov 5, 2025 by Pulumi

aws.qldb.getLedger

Start a Neo task
Explain and create an aws.qldb.getLedger resource
aws logo
AWS v7.11.0 published on Wednesday, Nov 5, 2025 by Pulumi

    Use this data source to fetch information about a Quantum Ledger Database.

    Example Usage

    import * as pulumi from "@pulumi/pulumi";
    import * as aws from "@pulumi/aws";
    
    const example = aws.qldb.getLedger({
        name: "an_example_ledger",
    });
    
    import pulumi
    import pulumi_aws as aws
    
    example = aws.qldb.get_ledger(name="an_example_ledger")
    
    package main
    
    import (
    	"github.com/pulumi/pulumi-aws/sdk/v7/go/aws/qldb"
    	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
    )
    
    func main() {
    	pulumi.Run(func(ctx *pulumi.Context) error {
    		_, err := qldb.LookupLedger(ctx, &qldb.LookupLedgerArgs{
    			Name: "an_example_ledger",
    		}, 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.Qldb.GetLedger.Invoke(new()
        {
            Name = "an_example_ledger",
        });
    
    });
    
    package generated_program;
    
    import com.pulumi.Context;
    import com.pulumi.Pulumi;
    import com.pulumi.core.Output;
    import com.pulumi.aws.qldb.QldbFunctions;
    import com.pulumi.aws.qldb.inputs.GetLedgerArgs;
    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 = QldbFunctions.getLedger(GetLedgerArgs.builder()
                .name("an_example_ledger")
                .build());
    
        }
    }
    
    variables:
      example:
        fn::invoke:
          function: aws:qldb:getLedger
          arguments:
            name: an_example_ledger
    

    Using getLedger

    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 getLedger(args: GetLedgerArgs, opts?: InvokeOptions): Promise<GetLedgerResult>
    function getLedgerOutput(args: GetLedgerOutputArgs, opts?: InvokeOptions): Output<GetLedgerResult>
    def get_ledger(name: Optional[str] = None,
                   region: Optional[str] = None,
                   tags: Optional[Mapping[str, str]] = None,
                   opts: Optional[InvokeOptions] = None) -> GetLedgerResult
    def get_ledger_output(name: Optional[pulumi.Input[str]] = None,
                   region: Optional[pulumi.Input[str]] = None,
                   tags: Optional[pulumi.Input[Mapping[str, pulumi.Input[str]]]] = None,
                   opts: Optional[InvokeOptions] = None) -> Output[GetLedgerResult]
    func LookupLedger(ctx *Context, args *LookupLedgerArgs, opts ...InvokeOption) (*LookupLedgerResult, error)
    func LookupLedgerOutput(ctx *Context, args *LookupLedgerOutputArgs, opts ...InvokeOption) LookupLedgerResultOutput

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

    public static class GetLedger 
    {
        public static Task<GetLedgerResult> InvokeAsync(GetLedgerArgs args, InvokeOptions? opts = null)
        public static Output<GetLedgerResult> Invoke(GetLedgerInvokeArgs args, InvokeOptions? opts = null)
    }
    public static CompletableFuture<GetLedgerResult> getLedger(GetLedgerArgs args, InvokeOptions options)
    public static Output<GetLedgerResult> getLedger(GetLedgerArgs args, InvokeOptions options)
    
    fn::invoke:
      function: aws:qldb/getLedger:getLedger
      arguments:
        # arguments dictionary

    The following arguments are supported:

    Name string
    Friendly name of the ledger to match.
    Region string
    Region where this resource will be managed. Defaults to the Region set in the provider configuration.
    Tags Dictionary<string, string>
    Name string
    Friendly name of the ledger to match.
    Region string
    Region where this resource will be managed. Defaults to the Region set in the provider configuration.
    Tags map[string]string
    name String
    Friendly name of the ledger to match.
    region String
    Region where this resource will be managed. Defaults to the Region set in the provider configuration.
    tags Map<String,String>
    name string
    Friendly name of the ledger to match.
    region string
    Region where this resource will be managed. Defaults to the Region set in the provider configuration.
    tags {[key: string]: string}
    name str
    Friendly name of the ledger to match.
    region str
    Region where this resource will be managed. Defaults to the Region set in the provider configuration.
    tags Mapping[str, str]
    name String
    Friendly name of the ledger to match.
    region String
    Region where this resource will be managed. Defaults to the Region set in the provider configuration.
    tags Map<String>

    getLedger Result

    The following output properties are available:

    Arn string
    DeletionProtection bool
    Id string
    The provider-assigned unique ID for this managed resource.
    KmsKey string
    Name string
    PermissionsMode string
    Region string
    Tags Dictionary<string, string>
    Arn string
    DeletionProtection bool
    Id string
    The provider-assigned unique ID for this managed resource.
    KmsKey string
    Name string
    PermissionsMode string
    Region string
    Tags map[string]string
    arn String
    deletionProtection Boolean
    id String
    The provider-assigned unique ID for this managed resource.
    kmsKey String
    name String
    permissionsMode String
    region String
    tags Map<String,String>
    arn string
    deletionProtection boolean
    id string
    The provider-assigned unique ID for this managed resource.
    kmsKey string
    name string
    permissionsMode string
    region string
    tags {[key: string]: string}
    arn str
    deletion_protection bool
    id str
    The provider-assigned unique ID for this managed resource.
    kms_key str
    name str
    permissions_mode str
    region str
    tags Mapping[str, str]
    arn String
    deletionProtection Boolean
    id String
    The provider-assigned unique ID for this managed resource.
    kmsKey String
    name String
    permissionsMode String
    region String
    tags Map<String>

    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
    AWS v7.11.0 published on Wednesday, Nov 5, 2025 by Pulumi
      Meet Neo: Your AI Platform Teammate