This example shows how to list the content libraries known to a single vAPI endpoint.
This example uses the steps that are described in Listing All Content Libraries.
Note: For related code samples, see the
vSphere Automation SDK Ruby samples at GitHub.
... # Create client stub for general library functions. $my_library_stub = Com::Vmware::Content::LibraryService.new $my_stub_config # List content libraries. library_ids = $my_library_stub.list library_ids.each do |id| library = $my_library_stub.get id puts "Library ID #{id}: #{library.name}" end