または AWS SDK ListBucketInventoryConfigurationsで使用する CLI - AWS SDK コード例

AWS Doc SDK Examples GitHub リポジトリには他にも AWS SDK例があります。

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

または AWS SDK ListBucketInventoryConfigurationsで使用する CLI

以下のコード例は、ListBucketInventoryConfigurations の使用方法を示しています。

CLI
AWS CLI

バケットのインベントリ設定のリストを取得するには

次の list-bucket-inventory-configurations の例では、指定したバケットのインベントリ設定をリスト表示します。

aws s3api list-bucket-inventory-configurations \ --bucket my-bucket

出力:

{ "InventoryConfigurationList": [ { "IsEnabled": true, "Destination": { "S3BucketDestination": { "Format": "ORC", "Bucket": "arn:aws:s3:::my-bucket", "AccountId": "123456789012" } }, "IncludedObjectVersions": "Current", "Id": "1", "Schedule": { "Frequency": "Weekly" } }, { "IsEnabled": true, "Destination": { "S3BucketDestination": { "Format": "CSV", "Bucket": "arn:aws:s3:::my-bucket", "AccountId": "123456789012" } }, "IncludedObjectVersions": "Current", "Id": "2", "Schedule": { "Frequency": "Daily" } } ], "IsTruncated": false }
PowerShell
のツール PowerShell

例 1: このコマンドは、指定した S3 バケットの最初の 100 つのインベントリ設定を返します。

Get-S3BucketInventoryConfigurationList -BucketName 'amzn-s3-demo-bucket'
  • API 詳細については、「 コマンドレットリファレンスListBucketInventoryConfigurations」の「」を参照してください。 AWS Tools for PowerShell