Zip List Entries

List the contents of a ZIP file

SDK Method

file.zip_list_contents

Return Object

ZipListEntry

Authorization Requirement

Available to all authenticated keys or sessions.

Example Request

begin
  file = Files::File.new
  file.zip_list_contents
rescue Files::NotAuthenticatedError => e
  puts "Authentication Error Occurred (#{e.class.to_s}): " + e.message
rescue Files::Error => e
  puts "Unknown Error Occurred (#{e.class.to_s}): " + e.message
end

The ZipListEntry Object

Some of the methods above return a ZipListEntry object. The attributes of this object are listed below.

AttributeDescription
path
string
Entry path inside the ZIP. This must be slash-delimited, but it must neither start nor end with a slash. Maximum of 5000 characters.
size
int64
Uncompressed size in bytes.