code: def rule_counters(self, engine, duration_type='one_week',
              duration=0, start_time=0):
          
          json = {'target_ref': engine.href, 'duration_type': duration_type}
          return [RuleCounter(**rule)
                  for rule in self.make_request(
                      method='create',
                      resource='rule_counter',
                      json=json)]
docs: .. versionadded:: 0.5.6
              Obtain rule counters for this policy. Requires SMC >= 6.2
          
          Rule counters can be obtained for a given policy and duration for
          those counters can be provided in duration_type. A custom start
          range can also be provided.
  
          :param Engine engine: the target engine to obtain rule counters from
          :param str duration_type: duration for obtaining rule counters. Valid
              options are: one_day, one_week, one_month, six_months, one_year,
              custom, since_last_upload
          :param int duration: if custom set for duration type, specify the
              duration in seconds (Default: 0)
          :param int start_time: start time in milliseconds (Default: 0)
          :raises: ActionCommandFailed
          :return: list of rule counter objects
          :rtype: RuleCounter