AWS v6.54.0 published on Friday, Sep 27, 2024 by Pulumi
aws.dynamodb.getTable
Explore with Pulumi AI
Provides information about a DynamoDB table.
Example Usage
import * as pulumi from "@pulumi/pulumi";
import * as aws from "@pulumi/aws";
const tableName = aws.dynamodb.getTable({
name: "tableName",
});
import pulumi
import pulumi_aws as aws
table_name = aws.dynamodb.get_table(name="tableName")
package main
import (
"github.com/pulumi/pulumi-aws/sdk/v6/go/aws/dynamodb"
"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)
func main() {
pulumi.Run(func(ctx *pulumi.Context) error {
_, err := dynamodb.LookupTable(ctx, &dynamodb.LookupTableArgs{
Name: "tableName",
}, 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 tableName = Aws.DynamoDB.GetTable.Invoke(new()
{
Name = "tableName",
});
});
package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.aws.dynamodb.DynamodbFunctions;
import com.pulumi.aws.dynamodb.inputs.GetTableArgs;
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 tableName = DynamodbFunctions.getTable(GetTableArgs.builder()
.name("tableName")
.build());
}
}
variables:
tableName:
fn::invoke:
Function: aws:dynamodb:getTable
Arguments:
name: tableName
Using getTable
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 getTable(args: GetTableArgs, opts?: InvokeOptions): Promise<GetTableResult>
function getTableOutput(args: GetTableOutputArgs, opts?: InvokeOptions): Output<GetTableResult>
def get_table(name: Optional[str] = None,
server_side_encryption: Optional[GetTableServerSideEncryption] = None,
tags: Optional[Mapping[str, str]] = None,
opts: Optional[InvokeOptions] = None) -> GetTableResult
def get_table_output(name: Optional[pulumi.Input[str]] = None,
server_side_encryption: Optional[pulumi.Input[GetTableServerSideEncryptionArgs]] = None,
tags: Optional[pulumi.Input[Mapping[str, pulumi.Input[str]]]] = None,
opts: Optional[InvokeOptions] = None) -> Output[GetTableResult]
func LookupTable(ctx *Context, args *LookupTableArgs, opts ...InvokeOption) (*LookupTableResult, error)
func LookupTableOutput(ctx *Context, args *LookupTableOutputArgs, opts ...InvokeOption) LookupTableResultOutput
> Note: This function is named LookupTable
in the Go SDK.
public static class GetTable
{
public static Task<GetTableResult> InvokeAsync(GetTableArgs args, InvokeOptions? opts = null)
public static Output<GetTableResult> Invoke(GetTableInvokeArgs args, InvokeOptions? opts = null)
}
public static CompletableFuture<GetTableResult> getTable(GetTableArgs args, InvokeOptions options)
// Output-based functions aren't available in Java yet
fn::invoke:
function: aws:dynamodb/getTable:getTable
arguments:
# arguments dictionary
The following arguments are supported:
- Name string
- Name of the DynamoDB table.
- Server
Side Pulumi.Encryption Aws. Dynamo DB. Inputs. Get Table Server Side Encryption - Dictionary<string, string>
- Name string
- Name of the DynamoDB table.
- Server
Side GetEncryption Table Server Side Encryption - map[string]string
- name String
- Name of the DynamoDB table.
- server
Side GetEncryption Table Server Side Encryption - Map<String,String>
- name string
- Name of the DynamoDB table.
- server
Side GetEncryption Table Server Side Encryption - {[key: string]: string}
- name str
- Name of the DynamoDB table.
- server_
side_ Getencryption Table Server Side Encryption - Mapping[str, str]
- name String
- Name of the DynamoDB table.
- server
Side Property MapEncryption - Map<String>
getTable Result
The following output properties are available:
- Arn string
- Attributes
List<Pulumi.
Aws. Dynamo DB. Outputs. Get Table Attribute> - Billing
Mode string - Deletion
Protection boolEnabled - Global
Secondary List<Pulumi.Indexes Aws. Dynamo DB. Outputs. Get Table Global Secondary Index> - Hash
Key string - Id string
- The provider-assigned unique ID for this managed resource.
- Local
Secondary List<Pulumi.Indexes Aws. Dynamo DB. Outputs. Get Table Local Secondary Index> - Name string
- Point
In Pulumi.Time Recovery Aws. Dynamo DB. Outputs. Get Table Point In Time Recovery - Range
Key string - Read
Capacity int - Replicas
List<Pulumi.
Aws. Dynamo DB. Outputs. Get Table Replica> - Server
Side Pulumi.Encryption Aws. Dynamo DB. Outputs. Get Table Server Side Encryption - Stream
Arn string - Stream
Enabled bool - Stream
Label string - Stream
View stringType - Table
Class string - Dictionary<string, string>
- Ttl
Pulumi.
Aws. Dynamo DB. Outputs. Get Table Ttl - Write
Capacity int
- Arn string
- Attributes
[]Get
Table Attribute - Billing
Mode string - Deletion
Protection boolEnabled - Global
Secondary []GetIndexes Table Global Secondary Index - Hash
Key string - Id string
- The provider-assigned unique ID for this managed resource.
- Local
Secondary []GetIndexes Table Local Secondary Index - Name string
- Point
In GetTime Recovery Table Point In Time Recovery - Range
Key string - Read
Capacity int - Replicas
[]Get
Table Replica Type - Server
Side GetEncryption Table Server Side Encryption - Stream
Arn string - Stream
Enabled bool - Stream
Label string - Stream
View stringType - Table
Class string - map[string]string
- Ttl
Get
Table Ttl - Write
Capacity int
- arn String
- attributes
List<Get
Table Attribute> - billing
Mode String - deletion
Protection BooleanEnabled - global
Secondary List<GetIndexes Table Global Secondary Index> - hash
Key String - id String
- The provider-assigned unique ID for this managed resource.
- local
Secondary List<GetIndexes Table Local Secondary Index> - name String
- point
In GetTime Recovery Table Point In Time Recovery - range
Key String - read
Capacity Integer - replicas
List<Get
Table Replica> - server
Side GetEncryption Table Server Side Encryption - stream
Arn String - stream
Enabled Boolean - stream
Label String - stream
View StringType - table
Class String - Map<String,String>
- ttl
Get
Table Ttl - write
Capacity Integer
- arn string
- attributes
Get
Table Attribute[] - billing
Mode string - deletion
Protection booleanEnabled - global
Secondary GetIndexes Table Global Secondary Index[] - hash
Key string - id string
- The provider-assigned unique ID for this managed resource.
- local
Secondary GetIndexes Table Local Secondary Index[] - name string
- point
In GetTime Recovery Table Point In Time Recovery - range
Key string - read
Capacity number - replicas
Get
Table Replica[] - server
Side GetEncryption Table Server Side Encryption - stream
Arn string - stream
Enabled boolean - stream
Label string - stream
View stringType - table
Class string - {[key: string]: string}
- ttl
Get
Table Ttl - write
Capacity number
- arn str
- attributes
Sequence[Get
Table Attribute] - billing_
mode str - deletion_
protection_ boolenabled - global_
secondary_ Sequence[Getindexes Table Global Secondary Index] - hash_
key str - id str
- The provider-assigned unique ID for this managed resource.
- local_
secondary_ Sequence[Getindexes Table Local Secondary Index] - name str
- point_
in_ Gettime_ recovery Table Point In Time Recovery - range_
key str - read_
capacity int - replicas
Sequence[Get
Table Replica] - server_
side_ Getencryption Table Server Side Encryption - stream_
arn str - stream_
enabled bool - stream_
label str - stream_
view_ strtype - table_
class str - Mapping[str, str]
- ttl
Get
Table Ttl - write_
capacity int
- arn String
- attributes List<Property Map>
- billing
Mode String - deletion
Protection BooleanEnabled - global
Secondary List<Property Map>Indexes - hash
Key String - id String
- The provider-assigned unique ID for this managed resource.
- local
Secondary List<Property Map>Indexes - name String
- point
In Property MapTime Recovery - range
Key String - read
Capacity Number - replicas List<Property Map>
- server
Side Property MapEncryption - stream
Arn String - stream
Enabled Boolean - stream
Label String - stream
View StringType - table
Class String - Map<String>
- ttl Property Map
- write
Capacity Number
Supporting Types
GetTableAttribute
GetTableGlobalSecondaryIndex
- Hash
Key string - Name string
- Name of the DynamoDB table.
- Non
Key List<string>Attributes - Projection
Type string - Range
Key string - Read
Capacity int - Write
Capacity int
- Hash
Key string - Name string
- Name of the DynamoDB table.
- Non
Key []stringAttributes - Projection
Type string - Range
Key string - Read
Capacity int - Write
Capacity int
- hash
Key String - name String
- Name of the DynamoDB table.
- non
Key List<String>Attributes - projection
Type String - range
Key String - read
Capacity Integer - write
Capacity Integer
- hash
Key string - name string
- Name of the DynamoDB table.
- non
Key string[]Attributes - projection
Type string - range
Key string - read
Capacity number - write
Capacity number
- hash_
key str - name str
- Name of the DynamoDB table.
- non_
key_ Sequence[str]attributes - projection_
type str - range_
key str - read_
capacity int - write_
capacity int
- hash
Key String - name String
- Name of the DynamoDB table.
- non
Key List<String>Attributes - projection
Type String - range
Key String - read
Capacity Number - write
Capacity Number
GetTableLocalSecondaryIndex
- Name string
- Name of the DynamoDB table.
- Non
Key List<string>Attributes - Projection
Type string - Range
Key string
- Name string
- Name of the DynamoDB table.
- Non
Key []stringAttributes - Projection
Type string - Range
Key string
- name String
- Name of the DynamoDB table.
- non
Key List<String>Attributes - projection
Type String - range
Key String
- name string
- Name of the DynamoDB table.
- non
Key string[]Attributes - projection
Type string - range
Key string
- name str
- Name of the DynamoDB table.
- non_
key_ Sequence[str]attributes - projection_
type str - range_
key str
- name String
- Name of the DynamoDB table.
- non
Key List<String>Attributes - projection
Type String - range
Key String
GetTablePointInTimeRecovery
- Enabled bool
- Enabled bool
- enabled Boolean
- enabled boolean
- enabled bool
- enabled Boolean
GetTableReplica
- Kms
Key stringArn - Region
Name string
- Kms
Key stringArn - Region
Name string
- kms
Key StringArn - region
Name String
- kms
Key stringArn - region
Name string
- kms_
key_ strarn - region_
name str
- kms
Key StringArn - region
Name String
GetTableServerSideEncryption
- enabled bool
- kms_
key_ strarn
GetTableTtl
- Attribute
Name string - Enabled bool
- Attribute
Name string - Enabled bool
- attribute
Name String - enabled Boolean
- attribute
Name string - enabled boolean
- attribute_
name str - enabled bool
- attribute
Name String - enabled Boolean
Package Details
- Repository
- AWS Classic pulumi/pulumi-aws
- License
- Apache-2.0
- Notes
- This Pulumi package is based on the
aws
Terraform Provider.