module Vods
  class Download < Vods::Base
    def download(vod_id)
      req = Vodapi::GetVodDownloadRequest.new({:vod_id => vod_id.to_s})

      resp = Download.twirp_client.manager_get_vod_download(req)

      return nil if resp.nil? || !resp.error.nil?
      return resp.data
    end
  end
end
