2015/04/09 - Amazon Simple Storage Service - 2 new 1 updated api methods
Returns the notification configuration of a bucket.
Request Syntax
client.get_bucket_notification_configuration(
Bucket='string'
)
string
[REQUIRED] Name of the buket to get the notification configuration for.
dict
Response Syntax
{
'TopicConfigurations': [
{
'Id': 'string',
'TopicArn': 'string',
'Events': [
's3:ReducedRedundancyLostObject'|'s3:ObjectCreated:Put'|'s3:ObjectCreated:Post'|'s3:ObjectCreated:Copy'|'s3:ObjectCreated:CompleteMultipartUpload',
]
},
],
'QueueConfigurations': [
{
'Id': 'string',
'QueueArn': 'string',
'Events': [
's3:ReducedRedundancyLostObject'|'s3:ObjectCreated:Put'|'s3:ObjectCreated:Post'|'s3:ObjectCreated:Copy'|'s3:ObjectCreated:CompleteMultipartUpload',
]
},
],
'LambdaFunctionConfigurations': [
{
'Id': 'string',
'LambdaFunctionArn': 'string',
'Events': [
's3:ReducedRedundancyLostObject'|'s3:ObjectCreated:Put'|'s3:ObjectCreated:Post'|'s3:ObjectCreated:Copy'|'s3:ObjectCreated:CompleteMultipartUpload',
]
},
]
}
Response Structure
(dict) -- Container for specifying the notification configuration of the bucket. If this element is empty, notifications are turned off on the bucket.
TopicConfigurations (list) --
(dict) -- Container for specifying the configuration when you want Amazon S3 to publish events to an Amazon Simple Notification Service (Amazon SNS) topic.
Id (string) -- Optional unique identifier for configurations in a notification configuration. If you don't provide one, Amazon S3 will assign an ID.
TopicArn (string) -- Amazon SNS topic ARN to which Amazon S3 will publish a message when it detects events of specified type.
Events (list) --
(string) -- Bucket event for which to send notifications.
QueueConfigurations (list) --
(dict) -- Container for specifying an configuration when you want Amazon S3 to publish events to an Amazon Simple Queue Service (Amazon SQS) queue.
Id (string) -- Optional unique identifier for configurations in a notification configuration. If you don't provide one, Amazon S3 will assign an ID.
QueueArn (string) -- Amazon SQS queue ARN to which Amazon S3 will publish a message when it detects events of specified type.
Events (list) --
(string) -- Bucket event for which to send notifications.
LambdaFunctionConfigurations (list) --
(dict) -- Container for specifying the AWS Lambda notification configuration.
Id (string) -- Optional unique identifier for configurations in a notification configuration. If you don't provide one, Amazon S3 will assign an ID.
LambdaFunctionArn (string) -- Lambda cloud function ARN that Amazon S3 can invoke when it detects events of the specified type.
Events (list) --
(string) -- Bucket event for which to send notifications.
Enables notifications of specified events for a bucket.
Request Syntax
client.put_bucket_notification_configuration(
Bucket='string',
NotificationConfiguration={
'TopicConfigurations': [
{
'Id': 'string',
'TopicArn': 'string',
'Events': [
's3:ReducedRedundancyLostObject'|'s3:ObjectCreated:Put'|'s3:ObjectCreated:Post'|'s3:ObjectCreated:Copy'|'s3:ObjectCreated:CompleteMultipartUpload',
]
},
],
'QueueConfigurations': [
{
'Id': 'string',
'QueueArn': 'string',
'Events': [
's3:ReducedRedundancyLostObject'|'s3:ObjectCreated:Put'|'s3:ObjectCreated:Post'|'s3:ObjectCreated:Copy'|'s3:ObjectCreated:CompleteMultipartUpload',
]
},
],
'LambdaFunctionConfigurations': [
{
'Id': 'string',
'LambdaFunctionArn': 'string',
'Events': [
's3:ReducedRedundancyLostObject'|'s3:ObjectCreated:Put'|'s3:ObjectCreated:Post'|'s3:ObjectCreated:Copy'|'s3:ObjectCreated:CompleteMultipartUpload',
]
},
]
}
)
string
[REQUIRED]
dict
[REQUIRED] Container for specifying the notification configuration of the bucket. If this element is empty, notifications are turned off on the bucket.
TopicConfigurations (list) --
(dict) -- Container for specifying the configuration when you want Amazon S3 to publish events to an Amazon Simple Notification Service (Amazon SNS) topic.
Id (string) -- Optional unique identifier for configurations in a notification configuration. If you don't provide one, Amazon S3 will assign an ID.
TopicArn (string) -- [REQUIRED] Amazon SNS topic ARN to which Amazon S3 will publish a message when it detects events of specified type.
Events (list) -- [REQUIRED]
(string) -- Bucket event for which to send notifications.
QueueConfigurations (list) --
(dict) -- Container for specifying an configuration when you want Amazon S3 to publish events to an Amazon Simple Queue Service (Amazon SQS) queue.
Id (string) -- Optional unique identifier for configurations in a notification configuration. If you don't provide one, Amazon S3 will assign an ID.
QueueArn (string) -- [REQUIRED] Amazon SQS queue ARN to which Amazon S3 will publish a message when it detects events of specified type.
Events (list) -- [REQUIRED]
(string) -- Bucket event for which to send notifications.
LambdaFunctionConfigurations (list) --
(dict) -- Container for specifying the AWS Lambda notification configuration.
Id (string) -- Optional unique identifier for configurations in a notification configuration. If you don't provide one, Amazon S3 will assign an ID.
LambdaFunctionArn (string) -- [REQUIRED] Lambda cloud function ARN that Amazon S3 can invoke when it detects events of the specified type.
Events (list) -- [REQUIRED]
(string) -- Bucket event for which to send notifications.
None
{'LambdaFunctionConfigurations': [{'Events': ['s3:ReducedRedundancyLostObject '
'| s3:ObjectCreated:Put | '
's3:ObjectCreated:Post | '
's3:ObjectCreated:Copy | '
's3:ObjectCreated:CompleteMultipartUpload'],
'Id': 'string',
'LambdaFunctionArn': 'string'}],
'QueueConfigurations': [{'Events': ['s3:ReducedRedundancyLostObject | '
's3:ObjectCreated:Put | '
's3:ObjectCreated:Post | '
's3:ObjectCreated:Copy | '
's3:ObjectCreated:CompleteMultipartUpload'],
'Id': 'string',
'QueueArn': 'string'}],
'TopicConfigurations': [{'Events': ['s3:ReducedRedundancyLostObject | '
's3:ObjectCreated:Put | '
's3:ObjectCreated:Post | '
's3:ObjectCreated:Copy | '
's3:ObjectCreated:CompleteMultipartUpload'],
'Id': 'string',
'TopicArn': 'string'}]}
Returns the notification configuration of a bucket.
Request Syntax
client.get_bucket_notification_configuration(
Bucket='string'
)
string
[REQUIRED] Name of the buket to get the notification configuration for.
dict
Response Syntax
{
'TopicConfigurations': [
{
'Id': 'string',
'TopicArn': 'string',
'Events': [
's3:ReducedRedundancyLostObject'|'s3:ObjectCreated:Put'|'s3:ObjectCreated:Post'|'s3:ObjectCreated:Copy'|'s3:ObjectCreated:CompleteMultipartUpload',
]
},
],
'QueueConfigurations': [
{
'Id': 'string',
'QueueArn': 'string',
'Events': [
's3:ReducedRedundancyLostObject'|'s3:ObjectCreated:Put'|'s3:ObjectCreated:Post'|'s3:ObjectCreated:Copy'|'s3:ObjectCreated:CompleteMultipartUpload',
]
},
],
'LambdaFunctionConfigurations': [
{
'Id': 'string',
'LambdaFunctionArn': 'string',
'Events': [
's3:ReducedRedundancyLostObject'|'s3:ObjectCreated:Put'|'s3:ObjectCreated:Post'|'s3:ObjectCreated:Copy'|'s3:ObjectCreated:CompleteMultipartUpload',
]
},
]
}
Response Structure
(dict) -- Container for specifying the notification configuration of the bucket. If this element is empty, notifications are turned off on the bucket.
TopicConfigurations (list) --
(dict) -- Container for specifying the configuration when you want Amazon S3 to publish events to an Amazon Simple Notification Service (Amazon SNS) topic.
Id (string) -- Optional unique identifier for configurations in a notification configuration. If you don't provide one, Amazon S3 will assign an ID.
TopicArn (string) -- Amazon SNS topic ARN to which Amazon S3 will publish a message when it detects events of specified type.
Events (list) --
(string) -- Bucket event for which to send notifications.
QueueConfigurations (list) --
(dict) -- Container for specifying an configuration when you want Amazon S3 to publish events to an Amazon Simple Queue Service (Amazon SQS) queue.
Id (string) -- Optional unique identifier for configurations in a notification configuration. If you don't provide one, Amazon S3 will assign an ID.
QueueArn (string) -- Amazon SQS queue ARN to which Amazon S3 will publish a message when it detects events of specified type.
Events (list) --
(string) -- Bucket event for which to send notifications.
LambdaFunctionConfigurations (list) --
(dict) -- Container for specifying the AWS Lambda notification configuration.
Id (string) -- Optional unique identifier for configurations in a notification configuration. If you don't provide one, Amazon S3 will assign an ID.
LambdaFunctionArn (string) -- Lambda cloud function ARN that Amazon S3 can invoke when it detects events of the specified type.
Events (list) --
(string) -- Bucket event for which to send notifications.