code: def generate_sigv4_auth_request(header_value=None):
      
      request = requests.Request(
          method='POST',
          url='https://sts.amazonaws.com/',
          headers={'Content-Type': 'application/x-www-form-urlencoded; charset=utf-8', 'Host': 'sts.amazonaws.com'},
          data='Action=GetCallerIdentity&Version=2011-06-15',
      )
  
      if header_value:
          request.headers['X-Vault-AWS-IAM-Server-ID'] = header_value
  
      prepared_request = request.prepare()
      return prepared_request
docs: Helper function to prepare a AWS API request to subsequently generate a "AWS Signature Version 4" header.
  
      :param header_value: Vault allows you to require an additional header, X-Vault-AWS-IAM-Server-ID, to be present
          to mitigate against different types of replay attacks. Depending on the configuration of the AWS auth
          backend, providing a argument to this optional parameter may be required.
      :type header_value: str
      :return: A PreparedRequest instance, optionally containing the provided header value under a
          'X-Vault-AWS-IAM-Server-ID' header name pointed to AWS's simple token service with action "GetCallerIdentity"
      :rtype: requests.PreparedRequest