def get_volume(name)
      params = {
          'command' => 'listVolumes',
          'name' => name
      }
      json = send_request(params)
      volumes = json['volume']

      if !volumes || volumes.empty? then
        return nil
      end
      volume = volumes.select { |item| name == item['name'] }
      volume.first
    end
def get_volume(name)
      params = {
          'command' => 'listVolumes',
          'name' => name
      }
      json = send_request(params)
      volumes = json['volume']

      if !volumes || volumes.empty? then
        return nil
      end
      volume = volumes.select { |item| name == item['name'] }
      volume.first
    end
Finds the volume with the specified name.