[{"name":"Indeed","actif":true,"url":"https:\/\/www.indeed.com","codeLiens":"\/\/WIZ_TITLE Indeed\r\njobTerm = \"senior IT manager\"; \/\/WIZ_VARIABLE #name:The title of the job you want to search for\r\nwhere = \"London\"; \/\/WIZ_VARIABLE #name:Where is this job located (within 25km) \r\ncountry = \"uk\"; \/\/WIZ_VARIABLE #name:Country #code:[\"fr\",\"uk\",\"deit\",\"es\",\"nl\"]\r\nnbResults = 50; \/\/WIZ_VARIABLE #name:Number of ads to browse\r\n\r\n\r\n\/\/WIZ_TITLE The CSV\r\n\/\/WIZ_COMMENT While the script is running, never open the CSV directly. It would become read-only, would be inaccessible, and the script would crash. Instead, make a copy and open there to check. \r\npathDir = ''; \/\/WIZ_VARIABLE #name:Path of the directory where the CSV must be writtend (leave blank to chose your Desktop)\r\nnameCSV = 'my_export'; \/\/WIZ_VARIABLE #name:Name of the CSV file\r\ndeleteCSVstart = true; \/\/WIZ_VARIABLE #name:Remove the CSV on startup if a file already exists\r\n\r\n\/\/WIZ_TITLE The CSV\r\n\/\/WIZ_COMMENT Indeed can sometimes decide to block you if you make too many requests. In this case, go to their site, enter the captcha. For example, use the Developer Tools Network tool in Firefox, take a request from Indeed and copy the value of the Cookie field from any request sent to Indeed. \r\ncookie='' \/\/WIZ_VARIABLE #name:Indeed cookie if needed\r\n\r\nif(!pathDir) pathDir=path(\"desktop\")\r\npathCSV=pathDir+nameCSV+\".csv\"\r\n\r\nif(deleteCSVstart) delete(pathCSV)\r\n\r\nsetCookieValue(cookie, \"https:\/\/\"+country+\".indeed.com\/\")\r\n\r\niResult=0\r\n\r\nnbPages=ceil(nbResults\/10)\r\nfor(iPage=0;iPage<nbPages;iPage++)\r\n{\r\n\thtmlResult=getPage(\"https:\/\/\"+country+\".indeed.com\/jobs?q=\"+urlEncode(jobTerm)+\"&l=\"+urlEncode(where)+\"&start=\"+(iPage*10))\r\n\tselectAll(\".jobsearch-SerpJobCard\",htmlResult,\"outerHTML\").each{job->\r\n\t\tif(iResult>nbResults) return;\r\n\t\r\n\t\ttitle=cleanSelect(\"h2\", job)\r\n\t\tcompany=cleanSelect(\".company\", job)\r\n\t\tlocation=cleanSelect(\".location\", job)\r\n\t\tsummary=cleanSelect(\".summary\", job)\r\n\t\tlink=cleanSelect(\"a.jobtitle\",job,\"href\")\r\n\r\n\t\thtmlJob=getPage(\"https:\/\/\"+country+\".indeed.com\"+link)\r\n\t\tinfo1=cleanSelect(\".jobsearch-DesktopStickyContainer .jobsearch-JobMetadataHeader-item span:nth-child(1)\", htmlJob)\r\n\t\tinfo2=cleanSelect(\".jobsearch-DesktopStickyContainer .jobsearch-JobMetadataHeader-item span:nth-child(2)\", htmlJob)\r\n\t\tinfo3=cleanSelect(\".jobsearch-DesktopStickyContainer .jobsearch-JobMetadataHeader-item span:nth-child(3)\", htmlJob)\r\n\t\t\r\n\t\tdescription=cleanSelect(\"#jobDescriptionText\", htmlJob,null,\"description\")\r\n\r\n\t\tcsv(pathCSV,[\r\n\t\t\t\"Title\":title,\r\n\t\t\t\"Location\":location,\r\n\t\t\t\"Summary\":summary,\r\n\t\t\t\"Info 1\":info1,\r\n\t\t\t\"Info 2\":info2,\r\n\t\t\t\"Info 3\":info3,\r\n\t\t\t\"Company\":company,\r\n\t\t\t\"description\":description,\r\n\t\t\t\"Link\":\"https:\/\/\"+country+\".indeed.com\"+link,\r\n\t\t])\r\n\r\n\t\tiResult++\r\n\t}\r\n}\r\n\r\n\/\/MATRICULE 5D99","codeGroovy":"","codeFinal":"","regexUrlBloquer":"([^a-z0-9]logout)","nbTaches":"1","modeSuiviCookie":"0","urlsAutoSavProgression":"0","maxUrl":"100000","httpAgent":"Mozilla\/5.0 (Windows NT 10.0; Win64; x64; rv:87.0) Gecko\/20100101 Firefox\/87.0","delai":"100","profondeur":"7"}]