Skip to content

johnidm/PyLinkedinAPI

Repository files navigation

Python Linkedin API

Travis CI PyPI PyPI Coverage Status

The Python Linkedin provides a easy interface to the Linkedin API.

We are in development, if you want to help, please see CONTRIBUTING

Installation

You can to install through pip.

pip install PyLinkedinAPI

Generate Access Token

If you don't have a access token I recommend to use the requests-oauthlib

Examples

See examples here

You need to generate temporary access token for basic tests:

Run python examples/basic.py and insert the access token

Created an instance

from PyLinkedinAPI.PyLinkedinAPI import PyLinkedinAPI

access_token = 'AQVaE34Qblm6uIhh3wVLXuhQPSI...'

linkedin = PyLinkedinAPI(access_token)

Features


Get data profile

profile = linkedin.get_basic_profile()

print(profile)

Get data companies

companies = linkedin.get_companies()

print(companies)

Publish comment on profile

linkedin.publish_profile_comment('This is my first package in Python')

Publish comment on company

linkedin.publish_company_comment(5470551, 'This is my first package in Python')

Publush Content/Comment on profile

linkedin.publish_profile(comment,
                         title=title, description=description,
                         submitted_url='http://www.johnidouglas.com.br/',
                         submitted_image_url='http://www.johnidouglas.com.br/logo.jpeg')

Publush Content/Comment on company

linkedin.publish_company(5470551,
                         comment,
                         title=title, description=description,
                         submitted_url='http://www.johnidouglas.com.br/',
                         submitted_image_url='http://www.johnidouglas.com.br/logo.jpeg)

Utils