lib/cloudflare_client/zone.rb
##
# various zone caching controlls.
# supploy an array of tags, or files, or the purge_everything bool
various zone caching controlls.
supploy an array of tags, or files, or the purge_everything bool
various zone caching controlls . supploy an array of tags or files or the purge_everything bool
def purge_zone_cache(zone_id:, tags: [], files: [], purge_everything: nil)
      raise('zone_id required') if zone_id.nil?
      if purge_everything.nil? && (tags.empty? && files.empty?)
        raise('specify a combination tags[], files[] or purge_everything')
      end
      data                    = {}
      data[:purge_everything] = purge_everything unless purge_everything.nil?
      data[:tags]             = tags unless tags.empty?
      data[:files]            = files unless files.empty?
      cf_delete(path: "/zones/#{zone_id}/purge_cache", data: data)
    end
def purge_zone_cache ( zone_id : , tags : [ ] , files : [ ] , purge_everything : nil ) raise ( 'zone_id required' ) if zone_id . nil? if purge_everything . nil? && ( tags . empty? && files . empty? ) raise ( 'specify a combination tags[], files[] or purge_everything' ) end data = { } data [ :purge_everything ] = purge_everything unless purge_everything . nil? data [ :tags ] = tags unless tags . empty? data [ :files ] = files unless files . empty? cf_delete ( path : "/zones/#{zone_id}/purge_cache" , data : data ) end
various zone caching controlls.
various zone caching controlls .
zone_id
<not_specific>
tags
<not_specific>
files
<not_specific>
purge_everything
<not_specific>