OpenLinkedInAPI
An Open-Source Python Library for LinkedIn Automation
Features
✅ No official API access required – just use a valid LinkedIn account.
✅ Direct HTTP API interface – no Selenium, Puppeteer, or browser-based scraping.
✅ Search and retrieve profiles, companies, jobs, and posts.
✅ Send and receive messages.
✅ Send and accept connection requests.
✅ React to posts and extract data efficiently.
✅ Community-driven and regularly updated.
⚠ Disclaimer: This library is not officially supported by LinkedIn. Using it may violate LinkedIn's Terms of Service. Use it at your own risk.
Installation
Note: Python >= 3.10 required
pip install openlinkedinapi
For the latest version from GitHub:
pip install git+https://github.com/your-repo/openlinkedinapi.git
Quick Start
from openlinkedinapi import Linkedin
# Authenticate with LinkedIn credentials
api = Linkedin('your-email@example.com', 'your-password')
# Get a profile
profile = api.get_profile('john-doe')
# Get profile contact info
contact_info = api.get_profile_contact_info('john-doe')
# Get first-degree connections
connections = api.get_profile_connections('123456789')
Development
Dependencies
- Poetry
- A valid LinkedIn account (avoid using your personal account)
Setup
Clone the repository and install dependencies:
git clone https://github.com/your-repo/openlinkedinapi.git
cd openlinkedinapi
poetry install
poetry self add poetry-plugin-dotenv
Running Tests
poetry run pytest
Troubleshooting
LinkedIn Challenge Prompts
LinkedIn may require additional verification (e.g., CAPTCHA, 2FA). If you encounter login issues, try:
- Logging into LinkedIn manually.
- Using a different IP (VPN or proxy).
- Avoiding excessive requests in a short period.
How It Works
This project interacts with LinkedIn’s internal API, Voyager, which powers LinkedIn’s web interface. By analyzing network requests, we extract structured data directly from LinkedIn pages without requiring an official API key.
Contributing
We welcome contributions! Feel free to submit issues, feature requests, or pull requests.
License
This project is licensed under the MIT License. See the LICENSE file for details.
Metadata
Release files for open-linkedin-api 2.3.1
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | Actions |
|---|---|---|---|---|
| open_linkedin_api-2.3.1.tar.gz | 21.7 kB | Without provenance | Details for open_linkedin_api-2.3.1.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| open_linkedin_api-2.3.1-py3-none-any.whl | Python 3 | none | any | Details for open_linkedin_api-2.3.1-py3-none-any.whl |
Total release size: 44.3 kB
Release files / open_linkedin_api-2.3.1.tar.gz
| Download URL | open_linkedin_api-2.3.1.tar.gz |
|---|---|
| Size | 21.7 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
d596de868bb677d02fd03c003c5a271a8bbb2554acf56a748fcd0a3a4a193ef6
|
|
BLAKE2b-256 checksum How to use checksums |
2e8747473ec27774fd1e03b12892dd022c451bb39f3b1620ca6d130e931533ab
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
poetry/1.8.2 CPython/3.12.3 Linux/6.11.0-19-generic
|
Release files / open_linkedin_api-2.3.1-py3-none-any.whl
| Download URL | open_linkedin_api-2.3.1-py3-none-any.whl |
|---|---|
| Size | 22.7 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
326459846598f1048985eb54e01c84f2d9ff9053a3ccbae9849b0ab062f41651
|
|
BLAKE2b-256 checksum How to use checksums |
7ed00a093c25d0474121f7f71d1b1a74f6b1ab52dc59fb639a0336fd1b3a8b25
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
poetry/1.8.2 CPython/3.12.3 Linux/6.11.0-19-generic
|
Security for open-linkedin-api 2.3.1
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
No provenance found
None of the files in this release were uploaded with provenance metadata.
A note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.