-- libquvi-scripts local Putlocker = {} -- Identify the script. function ident(qargs) return { domains = table.concat({'putlocker.com'}, ','), can_parse_url = Putlocker.can_parse_url(qargs) } end -- Parse media URL. function parse(qargs) local R = require 'soup_request' local c = quvi.http.fetch(qargs.input_url).data local p = { confirm = "Continue as Free User", hash = c:match('value="([^"]+)" name="hash"') } c = R.request(qargs.input_url, "POST", p) qargs.id = qargs.input_url:match("file/([A-Z0-9]+)") qargs.title = c:match('
%s*

(.-)') --qargs.thumb_url = c:match('property="og:image"%s+content="(.-)"') --qargs.duration_ms = tonumber(c:match('duration:%s*"(%d+)"') or 0) * 1000 qargs.streams = Putlocker.iter_streams(c, qargs) return qargs end function Putlocker.iter_streams(c, qargs) local S = require 'quvi/stream' url = c:match('