Baike.dev
All toolsOnline toolsAI codingTrendingOpen sourceNewsSubmit
Log in
< Back to tools
L

linkedin-scraper

> 编程语言
Open source

Scrapes the public profile of the linkedin page

576 stars0 likes3 views
WebsiteGitHub

About

Scrapes the public profile of the linkedin page

Linkedin Scraper

Linkedin-scraper is a gem for scraping public Linkedin profiles. Given the URL of the profile, it gets the name, country, title, area, current companies, past companies, organizations, skills, groups, etc

Installation

Install the gem from RubyGems:

gem install linkedin-scraper

Usage

Include the gem

require 'linkedin-scraper'

Initialize a scraper instance

profile = Linkedin::Profile.new("http://www.linkedin.com/in/jeffweiner08")

With a http web-proxy:

profile = Linkedin::Profile.new("http://www.linkedin.com/in/jeffweiner08", { proxy_ip: '127.0.0.1', proxy_port: '3128', username: 'user', password: 'pass' })

The scraper can also get the details of each past and current companies. This will lead to multiple hits. To enable this functionality, pass company_details=true in options. You can pass them along with proxy options as well

ruby
profile = Linkedin::Profile.new("http://www.linkedin.com/in/jeffweiner08", { company_details: true })

profile = Linkedin::Profile.new("http://www.linkedin.com/in/jeffweiner08", { company_details: true, proxy_ip: '127.0.0.1', proxy_port: '3128', username: 'user', password: 'pass' })

It's also possible to set number of seconds to wait for the connection to open. Scraper will throw exception after given timeout. E. g. to set two seconds long timeout pass open_timeout: 2 in options. Defaults to 60 seconds.

ruby
profile = Linkedin::Profile.new("http://www.linkedin.com/in/jeffweiner08", {open_timeout: 2 })

The returning object responds to the following methods

…

For current and past companies it also provides the details of the companies like company size, industry, address, etc The company details will only be scraped if you pass company_details=true. It is false by default.

…

The gem also comes with a binary and can be used from the command line to get a json response of the scraped data. It takes the url as the first argument. If the last argument is true it will fetch the company details for each company.

linkedin-scraper http://www.linkedin.com/in/jeffweiner08 127.0.0.1 3128 username password
linkedin-scraper http://www.linkedin.com/in/jeffweiner08 127.0.0.1 3128 username password true

Contributing

Bug reports and pull requests are welcome on GitHub at https://github.com/yatish27/linkedin-scraper. This project is intended to be a safe, welcoming space for collaboration, and contributors are expected to adhere to the Contributor Covenant code of conduct.

License

The gem is available as open source under the terms of the MIT License.

Issues· 0 open

View all issuesOpen on GitHub

No open issues yet, or sync has not completed.

> Tags

Ruby

No comments yet. Be the first to share.

> Details

PublishedAug 1, 2026
UpdatedSep 17, 2026
Category编程语言
PricingOpen source

> Related tools

T
TypeScript
JavaScript 的超集,为前端与全栈提供静态类型
P
Python
通用编程语言,广泛用于 Web、数据与 AI
G
Go
Google 推出的简洁高效系统语言