ruby Nokogiri requests 403 Forbidden

http-status-code-403, nokogiri, ruby

Solution

Try to change your user-agent:

Nokogiri::HTML(open("https://www.ruby-toolbox.com/categories/by_name", 'User-Agent' => 'firefox'))

www.ruby-toolbox.com doesn't seem to accept 'ruby' as an agent.

Problem

Hi I use gem Nokogiri to scrape the gem getails from ruby-toolbox ``` Nokogiri::HTML(open("https://www.ruby-toolbox.com/categories/by_name")) ``` but I get the error: "403 Forbidden" Can anyone tell me why I am getting this error? Thanks in advance

Original source

Related problems