code: def extraction(event_collection, timeframe=None, timezone=None, filters=None, latest=None, email=None,
                 property_names=None):
      
      _initialize_client_from_environment()
      return _client.extraction(event_collection=event_collection, timeframe=timeframe, timezone=timezone,
                                filters=filters, latest=latest, email=email, property_names=property_names)
docs: Performs a data extraction
  
      Returns either a JSON object of events or a response
       indicating an email will be sent to you with data.
  
      :param event_collection: string, the name of the collection to query
      :param timeframe: string or dict, the timeframe in which the events
      happened example: "previous_7_days"
      :param timezone: int, the timezone you'd like to use for the timeframe
      and interval in seconds
      :param filters: array of dict, contains the filters you'd like to apply to the data
      example: [{"property_name":"device", "operator":"eq", "property_value":"iPhone"}]
      :param latest: int, the number of most recent records you'd like to return
      :param email: string, optional string containing an email address to email results to
      :param property_names: string or list of strings, used to limit the properties returned