Options
All
  • Public
  • Public/Protected
  • All
Menu

Class GetBucketNotificationConfigurationCommand

Returns the notification configuration of a bucket.

If notifications are not enabled on the bucket, the action returns an empty NotificationConfiguration element.

By default, you must be the bucket owner to read the notification configuration of a bucket. However, the bucket owner can use a bucket policy to grant permission to other users to read this configuration with the s3:GetBucketNotification permission.

For more information about setting and reading the notification configuration on a bucket, see Setting Up Notification of Bucket Events. For more information about bucket policies, see Using Bucket Policies.

The following action is related to GetBucketNotification:

example

Use a bare-bones client and the command you need to make an API call.

import { S3Client, GetBucketNotificationConfigurationCommand } from "@aws-sdk/client-s3"; // ES Modules import
// const { S3Client, GetBucketNotificationConfigurationCommand } = require("@aws-sdk/client-s3"); // CommonJS import
const client = new S3Client(config);
const command = new GetBucketNotificationConfigurationCommand(input);
const response = await client.send(command);
see

GetBucketNotificationConfigurationCommandInput for command's input shape.

see

GetBucketNotificationConfigurationCommandOutput for command's response shape.

see

config for S3Client's config shape.

Hierarchy

Implements

Index

Constructors

Properties

Constructors

constructor

Properties

Readonly input

input: GetBucketNotificationConfigurationCommandInput

Readonly middlewareStack