code: def from_api_repr(cls, resource):
          
          action = resource["action"]
          instance = cls(action["storageClass"], _factory=True)
          instance.update(resource)
          return instance
docs: Factory:  construct instance from resource.
  
          :type resource: dict
          :param resource: mapping as returned from API call.
  
          :rtype: :class:`LifecycleRuleDelete`
          :returns: Instance created from resource.