

翻訳は機械翻訳により提供されています。提供された翻訳内容と英語版の間で齟齬、不一致または矛盾がある場合、英語版が優先します。

# AWS::Serverless::SimpleTable
<a name="sam-resource-simpletable"></a>

単一属性のプライマリキーで DynamoDB テーブルを作成します。これは、データへのアクセスがプライマリキー経由でのアクセスに限定されている場合に役立ちます。

より高度な機能については、 CloudFormationで [https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-dynamodb-table.html](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-dynamodb-table.html) リソースを使用します。これらのリソースは AWS SAMで使用できます。これらは包括的であり、[https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-dynamodb-table-keyschema.html](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-dynamodb-table-keyschema.html) や [https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-dynamodb-table-resourcepolicy.html](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-dynamodb-table-resourcepolicy.html) のカスタマイズなど、さらなるカスタマイズを提供します。

**注記**  
にデプロイすると AWS CloudFormation、 は AWS SAM リソースを CloudFormation リソース AWS SAM に変換します。詳細については、「[の生成済み CloudFormation リソース AWS SAM](sam-specification-generated-resources.md)」を参照してください。

## 構文
<a name="sam-resource-simpletable-syntax"></a>

 AWS Serverless Application Model (AWS SAM) テンプレートでこのエンティティを宣言するには、次の構文を使用します。

### YAML
<a name="sam-resource-simpletable-syntax.yaml"></a>

```
Type: AWS::Serverless::SimpleTable
Properties:
  PointInTimeRecoverySpecification: [PointInTimeRecoverySpecification](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-dynamodb-table-pointintimerecoveryspecification.html)
  [PrimaryKey](#sam-simpletable-primarykey): PrimaryKeyObject
  [ProvisionedThroughput](#sam-simpletable-provisionedthroughput): ProvisionedThroughputObject
  [SSESpecification](#sam-simpletable-ssespecification): [SSESpecification](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-dynamodb-table-ssespecification.html)
  [TableName](#sam-simpletable-tablename): String
  [Tags](#sam-simpletable-tags): Map
```

## プロパティ
<a name="sam-resource-simpletable-properties"></a>

 `PointInTimeRecoverySpecification`   <a name="sam-simpletable-pointintimerecoveryspecification"></a>
ポイントインタイムリカバリを有効にするための設定。  
*タイプ*: [PointInTimeRecoverySpecification](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-dynamodb-table-pointintimerecoveryspecification.html)  
*必須:* いいえ  
*CloudFormation 互換性*: このプロパティは、 `AWS::DynamoDB::Table`リソースの `[PointInTimeRecoverySpecification](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-dynamodb-table-pointintimerecoveryspecification.html)`プロパティに直接渡されます。

 `PrimaryKey`   <a name="sam-simpletable-primarykey"></a>
テーブルのプライマリキーとして使用される属性の名前とタイプです。指定しない場合、プライマリキーは値が `id` の `String` になります。  
このプロパティの値は、このリソースが作成された後で変更することはできません。
*タイプ*: [PrimaryKeyObject](sam-property-simpletable-primarykeyobject.md)  
*必須:* いいえ  
*CloudFormation 互換性*: このプロパティは に固有 AWS SAM であり、 CloudFormation 同等のものはありません。

 `ProvisionedThroughput`   <a name="sam-simpletable-provisionedthroughput"></a>
読み取りおよび書き込みスループットのプロビジョニング情報です。  
`ProvisionedThroughput` が指定されていない場合、`BillingMode` は `PAY_PER_REQUEST` として指定されます。  
*タイプ*: [ProvisionedThroughputObject](sam-property-simpletable-provisionedthroughputobject.md)  
*必須:* いいえ  
*CloudFormation 互換性*: このプロパティは、 `AWS::DynamoDB::Table`リソースの `[ProvisionedThroughput](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-dynamodb-table-provisionedthroughput.html)`プロパティに直接渡されます。

 `SSESpecification`   <a name="sam-simpletable-ssespecification"></a>
サーバー側の暗号化を有効にする設定を指定します。  
*タイプ*: [SSESpecification](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-dynamodb-table-ssespecification.html)  
*必須:* いいえ  
*CloudFormation 互換性*: このプロパティは、 `AWS::DynamoDB::Table`リソースの `[SSESpecification](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-dynamodb-table-ssespecification.html)`プロパティに直接渡されます。

 `TableName`   <a name="sam-simpletable-tablename"></a>
DynamoDB テーブルの名前です。  
*型*: 文字列  
*必須:* いいえ  
*CloudFormation 互換性*: このプロパティは、 `AWS::DynamoDB::Table`リソースの `[TableName](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-dynamodb-table.html#cfn-dynamodb-table-tablename)`プロパティに直接渡されます。

 `Tags`   <a name="sam-simpletable-tags"></a>
この SimpleTable に追加されるタグを指定するマップ (文字列対文字列) です。タグの有効なキーと値の詳細については、*AWS CloudFormation ユーザーガイド*の[リソースタグ](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-resource-tags.html)を参照してください。  
*タイプ*: マップ  
*必須:* いいえ  
*CloudFormation 互換性*: このプロパティは、 `AWS::DynamoDB::Table`リソースの `[Tags](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-dynamodb-table.html#cfn-dynamodb-table-tags)`プロパティに似ています。SAM の Tags プロパティは、キーバリューペアで構成されています。CloudFormation では、タグオブジェクトのリストで構成されています。

## 戻り値
<a name="sam-resource-simpletable-return-values"></a>

### 参照番号
<a name="sam-resource-simpletable-return-values-ref"></a>

このリソースの論理 ID が Ref 組み込み関数に提供されると、基盤となる DynamoDB テーブルのリソース名 が返されます。

`Ref` 関数の使用方法の詳細については、*AWS CloudFormation ユーザーガイド*の「[https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/intrinsic-function-reference-ref.html](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/intrinsic-function-reference-ref.html)」を参照してください。

## 例
<a name="sam-resource-simpletable--examples"></a>

### SimpleTableExample
<a name="sam-resource-simpletable--examples--simpletableexample"></a>

SimpleTable の例

#### YAML
<a name="sam-resource-simpletable--examples--simpletableexample--yaml"></a>

```
Properties:
  TableName: my-table
  PrimaryKey:
    Name: MyPrimaryKey
    Type: String
  ProvisionedThroughput:
    ReadCapacityUnits: 5
    WriteCapacityUnits: 5
  Tags:
    Department: Engineering
    AppType: Serverless
```

# PrimaryKeyObject
<a name="sam-property-simpletable-primarykeyobject"></a>

プライマリキーのプロパティを説明するオブジェクトです。

## 構文
<a name="sam-property-simpletable-primarykeyobject-syntax"></a>

 AWS Serverless Application Model (AWS SAM) テンプレートでこのエンティティを宣言するには、次の構文を使用します。

### YAML
<a name="sam-property-simpletable-primarykeyobject-syntax.yaml"></a>

```
  [Name](#sam-simpletable-primarykeyobject-name): String
  [Type](#sam-simpletable-primarykeyobject-type): String
```

## プロパティ
<a name="sam-property-simpletable-primarykeyobject-properties"></a>

 `Name`   <a name="sam-simpletable-primarykeyobject-name"></a>
プライマリキーの属性名です。  
*タイプ*: 文字列  
*必須*: はい  
*CloudFormation 互換性*: このプロパティは、 `AWS::DynamoDB::Table` `AttributeDefinition` データ型の `[AttributeName](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-dynamodb-attributedef.html#cfn-dynamodb-attributedef-attributename)`プロパティに直接渡されます。  
*その他の注意点*: このプロパティは、`AWS::DynamoDB::Table KeySchema` データ型の [AttributeName](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-dynamodb-keyschema.html#aws-properties-dynamodb-keyschema-attributename) プロパティにも渡されます。

 `Type`   <a name="sam-simpletable-primarykeyobject-type"></a>
プライマリキーのデータ型です。  
有効な値: `String`、`Number`、`Binary`  
*タイプ*: 文字列  
*必須*: はい  
*CloudFormation 互換性*: このプロパティは、 `AWS::DynamoDB::Table` `AttributeDefinition` データ型の `[AttributeType](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-dynamodb-attributedef.html#cfn-dynamodb-attributedef-attributename-attributetype)`プロパティに直接渡されます。

## 例
<a name="sam-property-simpletable-primarykeyobject--examples"></a>

### PrimaryKey
<a name="sam-property-simpletable-primarykeyobject--examples--primarykey"></a>

プライマリキーの例です。

#### YAML
<a name="sam-property-simpletable-primarykeyobject--examples--primarykey--yaml"></a>

```
Properties:
  PrimaryKey:
    Name: MyPrimaryKey
    Type: String
```

# ProvisionedThroughputObject
<a name="sam-property-simpletable-provisionedthroughputobject"></a>

プロビジョニングされたスループットのプロパティを記述するオブジェクト。

## 構文
<a name="sam-property-simpletable-provisionedthroughputobject-syntax"></a>

 AWS Serverless Application Model (AWS SAM) テンプレートでこのエンティティを宣言するには、次の構文を使用します。

### YAML
<a name="w2aac13c22c41c19b5b5"></a>

```
  [ReadCapacityUnits](#sam-simpletable-provisionedthroughputobject-readcapacityunits): Integer
  [WriteCapacityUnits](#sam-simpletable-provisionedthroughputobject-writecapacityunits): Integer
```

## プロパティ
<a name="sam-property-simpletable-provisionedthroughputobject-properties"></a>

 `ReadCapacityUnits`   <a name="sam-simpletable-provisionedthroughputobject-readcapacityunits"></a>
1 秒間に消費される強力な整合性のある読み取りの最大数。この最大数を超えると、DynamoDB が `ThrottlingException` を返します。  
*タイプ:* 整数  
*必須:* はい  
*CloudFormation 互換性*: このプロパティは、 `AWS::DynamoDB::Table` `ProvisionedThroughput` データ型の `[ReadCapacityUnits](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-dynamodb-table-provisionedthroughput.html#aws-properties-dynamodb-table-provisionedthroughput-properties)`プロパティに直接渡されます。

 `WriteCapacityUnits`   <a name="sam-simpletable-provisionedthroughputobject-writecapacityunits"></a>
1 秒間に消費される書き込みの最大数。この最大数を超えると、DynamoDB が `ThrottlingException` を返します。  
*タイプ:* 整数  
*必須:* はい  
*CloudFormation 互換性*: このプロパティは、 `AWS::DynamoDB::Table` `ProvisionedThroughput` データ型の `[WriteCapacityUnits](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-dynamodb-table-provisionedthroughput.html#aws-properties-dynamodb-table-provisionedthroughput-properties)`プロパティに直接渡されます。

## 例
<a name="sam-property-simpletable-provisionedthroughputobject--examples"></a>

### ProvisionedThroughput
<a name="sam-property-simpletable-provisionedthroughputobject--examples--provisionedthroughput"></a>

プロビジョニングされたスループットの例。

#### YAML
<a name="sam-property-simpletable-provisionedthroughputobject--examples--provisionedthroughput--yaml"></a>

```
Properties:
   ProvisionedThroughput:
     ReadCapacityUnits: 5
     WriteCapacityUnits: 5
```