class_docstr: Configures access to secured resources stored in AWS S3.
      
class_docstr_tok: ["Configures","access","to","secured","resources","stored","in","AWS","S3","."]
docstr: Create a new AWS session
  
  Parameters
  ----------
  session : optional
      A boto3 session object.
  aws_unsigned : bool, optional (default: False)
      If True, requests will be unsigned.
  aws_access_key_id : str, optional
      An access key id, as per boto3.
  aws_secret_access_key : str, optional
      A secret access key, as per boto3.
  aws_session_token : str, optional
      A session token, as per boto3.
  region_name : str, optional
      A region name, as per boto3.
  profile_name : str, optional
      A shared credentials profile name, as per boto3.
  endpoint_url: str, optional
      An endpoint_url, as per GDAL's AWS_S3_ENPOINT
  requester_pays : bool, optional
      True if the requester agrees to pay transfer costs (default:
      False)
docstr_tok: ["Create","a","new","AWS","session","Parameters","--","--","--","--","--","session",":","optional","A","boto3","session","object",".","aws_unsigned",":","bool",",","optional","(","default",":","False",")","If","True",",","requests","will","be","unsigned",".","aws_access_key_id",":","str",",","optional","An","access","key","id",",","as","per","boto3",".","aws_secret_access_key",":","str",",","optional","A","secret","access","key",",","as","per","boto3",".","aws_session_token",":","str",",","optional","A","session","token",",","as","per","boto3",".","region_name",":","str",",","optional","A","region","name",",","as","per","boto3",".","profile_name",":","str",",","optional","A","shared","credentials","profile","name",",","as","per","boto3",".","endpoint_url",":","str",",","optional","An","endpoint_url",",","as","per","GDAL","'s","AWS_S3_ENPOINT","requester_pays",":","bool",",","optional","True","if","the","requester","agrees","to","pay","transfer","costs","(","default",":","False",")"]
code: def __init__(
      self,
      session=None,
      aws_unsigned=False,
      aws_access_key_id=None,
      aws_secret_access_key=None,
      aws_session_token=None,
      region_name=None,
      profile_name=None,
      endpoint_url=None,
      requester_pays=False,
  ):
      """Create a new AWS session
  
      Parameters
      ----------
      session : optional
          A boto3 session object.
      aws_unsigned : bool, optional (default: False)
          If True, requests will be unsigned.
      aws_access_key_id : str, optional
          An access key id, as per boto3.
      aws_secret_access_key : str, optional
          A secret access key, as per boto3.
      aws_session_token : str, optional
          A session token, as per boto3.
      region_name : str, optional
          A region name, as per boto3.
      profile_name : str, optional
          A shared credentials profile name, as per boto3.
      endpoint_url: str, optional
          An endpoint_url, as per GDAL's AWS_S3_ENPOINT
      requester_pays : bool, optional
          True if the requester agrees to pay transfer costs (default:
          False)
  
      """
      if session:
          self._session = session
      else:
          self._session = boto3.Session(
              aws_access_key_id=aws_access_key_id,
              aws_secret_access_key=aws_secret_access_key,
              aws_session_token=aws_session_token,
              region_name=region_name,
              profile_name=profile_name,
          )
  
      self.requester_pays = requester_pays
      self.unsigned = bool(
          os.getenv("AWS_NO_SIGN_REQUEST", aws_unsigned)
      )
      self.endpoint_url = endpoint_url
      self._creds = (
          self._session.get_credentials()
          if not self.unsigned and self._session
          else None
      )
  
imports: import logging
  import os
  import warnings
  from fiona.path import parse_path, UnparsedPath
label_desc: Use image node_id 1 to create a new AWSSession object from inherited base classes: Session with example: obj = AWSSession(session, aws_unsigned, aws_access_key_id, aws_secret_access_key, aws_session_token, region_name, profile_name, endpoint_url, requester_pays)