mirror of
https://github.com/fog/fog.git
synced 2022-11-09 13:51:43 -05:00
28 lines
880 B
Ruby
28 lines
880 B
Ruby
module Fog
|
|
module Compute
|
|
class VcloudDirector
|
|
class Real
|
|
# Retrieves a thumbnail image of a VM console.
|
|
#
|
|
# The content type of the response can be any of `image/png`,
|
|
# `image/gif`.
|
|
#
|
|
# @param [String] id Object identifier of the VM.
|
|
# @return [Excon::Response]
|
|
# * body<~String> - the thumbnail image.
|
|
#
|
|
# @see http://pubs.vmware.com/vcd-51/topic/com.vmware.vcloud.api.reference.doc_51/doc/operations/GET-Thumbnail.html
|
|
# @since vCloud API version 0.9
|
|
def get_thumbnail(id)
|
|
request(
|
|
:expects => 200,
|
|
:headers => {'Accept' => "image/*;version=#{@api_version}"},
|
|
:idempotent => true,
|
|
:method => 'GET',
|
|
:path => "vApp/#{id}/screen"
|
|
)
|
|
end
|
|
end
|
|
end
|
|
end
|
|
end
|