Boto3 reference#

class boto3.NullHandler(level=0)[source]#

Initializes the instance - basically setting the formatter to None and the filter list to empty.


Do whatever it takes to actually log the specified logging record.

This version is intended to be implemented by subclasses and so raises a NotImplementedError.

boto3.client(*args, **kwargs)[source]#

Create a low-level service client by name using the default session.

See boto3.session.Session.client().

boto3.resource(*args, **kwargs)[source]#

Create a resource service client by name using the default session.

See boto3.session.Session.resource().

boto3.set_stream_logger(name='boto3', level=10, format_string=None)[source]#

Add a stream handler for the given name and level to the logging module. By default, this logs all boto3 messages to stdout.

>>> import boto3
>>> boto3.set_stream_logger('boto3.resources', logging.INFO)

For debugging purposes a good choice is to set the stream logger to '' which is equivalent to saying “log everything”.


Be aware that when logging anything from 'botocore' the full wire trace will appear in your logs. If your payloads contain sensitive data this should not be used in production.

  • name (string) – Log name

  • level (int) – Logging level, e.g. logging.INFO

  • format_string (str) – Log message format


Set up a default session, passing through any parameters to the session constructor. There is no need to call this unless you wish to pass custom parameters, because a default session will be created for you.