proxycurl-js-linkedin-profile-scraper
v1.0.2
Published
The official Javascript/NodeJS client for Proxycurl API to scrape and enrich LinkedIn profiles
Downloads
808
Readme
proxycurl-js-linkedin-profile-scraper
- The official Javascript/NodeJS client for Proxycurl API to scrape and enrich LinkedIn profiles
- What is Proxycurl?
- Installation
- Getting Started
- Documentation for API Endpoints
- Documentation for Models
- Documentation for Authorization
What is Proxycurl?
Proxycurl is an enrichment API to fetch fresh data on people and businesses. We are a fully-managed API that sits between your application and raw data so that you can focus on building the application; instead of worrying about building a web-scraping team and processing data at scale.
With Proxycurl, you can programatically:
- Enrich profiles on people and companies
- Lookup people and companies
- Lookup contact information on people and companies
- Check if an email address is of a disposable nature
- And more..
Visit Proxycurl's website for more details.
Installation
For Node.js
npm
Install it via:
npm install proxycurl-js-linkedin-profile-scraper
Finally, you need to build the module:
npm run build
Local development
To use the library locally without publishing to a remote npm registry, first install the dependencies by changing into the directory containing package.json
(and this README). Let's call this JAVASCRIPT_CLIENT_DIR
. Then run:
npm install
Next, link it globally in npm with the following, also from JAVASCRIPT_CLIENT_DIR
:
npm link
To use the link you just defined in your project, switch to the directory you want to use your proxycurl-js-linkedin-profile-scraper from, and run:
npm link /path/to/<JAVASCRIPT_CLIENT_DIR>
Finally, you need to build the module:
npm run build
git
If the library is hosted at a git repository, e.g.https://github.com/GIT_USER_ID/GIT_REPO_ID then install it via:
npm install GIT_USER_ID/GIT_REPO_ID --save
For browser
The library also works in the browser environment via npm and browserify. After following
the above steps with Node.js and installing browserify with npm install -g browserify
,
perform the following (assuming main.js is your entry file):
browserify main.js > bundle.js
Then include bundle.js in the HTML pages.
Webpack Configuration
Using Webpack you may encounter the following error: "Module not found: Error: Cannot resolve module", most certainly you should disable AMD loader. Add/merge the following section to your webpack config:
module: {
rules: [
{
parser: {
amd: false
}
}
]
}
Getting Started
Please follow the installation instruction and execute the following JS code:
var ProxycurlApi = require('proxycurl-js-linkedin-profile-scraper');
var defaultClient = ProxycurlApi.ApiClient.instance;
// Configure Bearer access token for authorization: BearerAuth
var BearerAuth = defaultClient.authentications['BearerAuth'];
BearerAuth.accessToken = "YOUR ACCESS TOKEN"
var api = new ProxycurlApi.CompanyAPIApi()
var opts = {
'companyLocation': sg, // {String} The location / region of company. ISO 3166-1 alpha-2 codes
'companyDomain': accenture.com, // {String} Company website or Company domain Requires either `company_domain` or `company_name`
'companyName': Accenture // {String} Company Name Requires either `company_domain` or `company_name`
};
var callback = function(error, data, response) {
if (error) {
console.error(error);
} else {
console.log('API called successfully. Returned data: ' + data);
}
};
api.companyLookupEndpoint(opts, callback);
Documentation for API Endpoints
All URIs are relative to https://nubela.co/proxycurl
Class | Method | HTTP request | Description ------------ | ------------- | ------------- | ------------- ProxycurlApi.CompanyAPIApi | companyLookupEndpoint | GET /api/linkedin/company/resolve | Cost: 2 credits / successful request. Resolve Company LinkedIn Profile from company name, domain name and location. ProxycurlApi.CompanyAPIApi | companyProfileEndpoint | GET /api/linkedin/company | Cost: 1 credit / successful request. Get structured data of a Company Profile ProxycurlApi.CompanyAPIApi | companyProfilePictureEndpoint | GET /api/linkedin/company/profile-picture | Cost: 0 credit / successful request. Get the profile picture of a company. Profile pictures are served from cached company profiles found within LinkDB. If the profile does not exist within LinkDB, then the API will return a `404` status code. ProxycurlApi.CompanyAPIApi | employeeCountEndpoint | GET /api/linkedin/company/employees/count/ | Cost: 1 credit / successful request. Get a number of total employees of a Company. Get an employee count of this company from various sources. ProxycurlApi.CompanyAPIApi | employeeListingEndpoint | GET /api/linkedin/company/employees/ | Cost: 3 credits / employee returned. Get a list of employees of a Company. This API endpoint is limited by LinkDB which is populated with profiles in the US, UK, Canada, Israel, Australia, Ireland, New Zealand and Singapore. As such, this endpoint is best used to list employees working in companies based in those locations only. ProxycurlApi.CompanyAPIApi | employeeSearchAPIEndpoint | GET /api/linkedin/company/employee/search/ | Cost: 10 credits / successful request. Search employees of a target by their job title. ProxycurlApi.ContactAPIApi | disposableEmailAddressCheckEndpoint | GET /api/disposable-email | Cost: 0 credit / request. Given an email address, checks if the email address belongs to a disposable email service. ProxycurlApi.ContactAPIApi | personalContactNumberLookupEndpoint | GET /api/contact-api/personal-contact | Cost: 1 credit / contact number returned. Given an LinkedIn profile, returns a list of personal contact numbers belonging to this identity. ProxycurlApi.ContactAPIApi | personalEmailLookupEndpoint | GET /api/contact-api/personal-email | Cost: 1 credit / email returned. Given an LinkedIn profile, returns a list of personal emails belonging to this identity. Emails are verified to be deliverable. ProxycurlApi.ContactAPIApi | reverseWorkEmailLookupEndpoint | GET /api/linkedin/profile/resolve/email | Cost: 3 credits / successful request. Resolve LinkedIn Profile from a work email address ProxycurlApi.ContactAPIApi | workEmailLookupEndpoint | GET /api/linkedin/profile/email | Cost: 3 credits / request. Lookup work email address of a LinkedIn Person Profile. Email addresses returned are verified to not be role-based or catch-all emails. Email addresses returned by our API endpoint come with a 95+% deliverability guarantee Endpoint behavior This endpoint may not return results immediately. If you provided a webhook in your request parameter, our application will call your webhook with the result once. See `Webhook request` below. ProxycurlApi.JobsAPIApi | jobProfileEndpoint | GET /api/linkedin/job | Cost: 2 credits / successful request. Get structured data of a LinkedIn Job Profile ProxycurlApi.JobsAPIApi | jobsListingEndpoint | GET /api/v2/linkedin/company/job | Cost: 2 credits / successful request. List jobs posted by a company on LinkedIn ProxycurlApi.MetaAPIApi | viewCreditBalanceEndpoint | GET /api/credit-balance | Cost: 0 credit / successful request. Get your current credit(s) balance ProxycurlApi.PeopleAPIApi | personLookupEndpoint | GET /api/linkedin/profile/resolve | Cost: 2 credits / successful request. Resolve LinkedIn Profile ProxycurlApi.PeopleAPIApi | personProfileEndpoint | GET /api/v2/linkedin | Cost: 1 credit / successful request. Get structured data of a Personal Profile ProxycurlApi.PeopleAPIApi | personProfilePictureEndpoint | GET /api/linkedin/person/profile-picture | Cost: 0 credit / successful request. Get the profile picture of a person. Profile pictures are served from cached people profiles found within LinkDB. If the profile does not exist within LinkDB, then the API will return a `404` status code. ProxycurlApi.PeopleAPIApi | roleLookupEndpoint | GET /api/find/company/role | Cost: 3 credits / successful request. Finds the closest (person) profile with a given role in a Company. For example, you can use this endpoint to find the "CTO" of "Apple". This API endpoint returns only one result that is the closest match. There is also a role search under the Employee Listing Endpoint if you require: * precision on the target company * a list of employees that matches a role (instead of one result). ProxycurlApi.RevealAPIApi | revealEndpoint | GET /api/reveal/company | Cost: 2 credits / successful request. Deanonymize an IPv4 address and associate the Company behind the IPv4 address. ProxycurlApi.SchoolAPIApi | schoolProfileEndpoint | GET /api/linkedin/school | Cost: 1 credit / successful request. Get structured data of a LinkedIn School Profile
Documentation for Models
- ProxycurlApi.AccomplishmentOrg
- ProxycurlApi.AcquiredCompany
- ProxycurlApi.AcquiredCompanyAnnouncedDate
- ProxycurlApi.Acquisition
- ProxycurlApi.AcquisitionAcquiredBy
- ProxycurlApi.Acquisitor
- ProxycurlApi.Activity
- ProxycurlApi.Article
- ProxycurlApi.Certification
- ProxycurlApi.CompanyDetails
- ProxycurlApi.CompanyDetailsFoundingDate
- ProxycurlApi.CompanyDetailsIpoDate
- ProxycurlApi.CompanyLocation
- ProxycurlApi.CompanyReveal
- ProxycurlApi.CompanyRevealCompany
- ProxycurlApi.CompanyRevealRoleProfile
- ProxycurlApi.CompanyUpdate
- ProxycurlApi.CompanyUpdatePostedOn
- ProxycurlApi.Course
- ProxycurlApi.CreditBalance
- ProxycurlApi.DisposableEmail
- ProxycurlApi.Education
- ProxycurlApi.Employee
- ProxycurlApi.EmployeeCount
- ProxycurlApi.EmployeeList
- ProxycurlApi.EmployeeProfile
- ProxycurlApi.Exit
- ProxycurlApi.Experience
- ProxycurlApi.ExtractionEmailResult
- ProxycurlApi.Funding
- ProxycurlApi.FundingAnnouncedDate
- ProxycurlApi.HonourAward
- ProxycurlApi.HonourAwardIssuedOn
- ProxycurlApi.InferredSalary
- ProxycurlApi.Investor
- ProxycurlApi.Job
- ProxycurlApi.JobCompany
- ProxycurlApi.JobListPage
- ProxycurlApi.JobLocation
- ProxycurlApi.LinkedinCompany
- ProxycurlApi.LinkedinCompanyAcquisitions
- ProxycurlApi.LinkedinCompanyExtra
- ProxycurlApi.LinkedinCompanyHq
- ProxycurlApi.LinkedinJob
- ProxycurlApi.LinkedinJobCompany
- ProxycurlApi.LinkedinJobLocation
- ProxycurlApi.LinkedinSchool
- ProxycurlApi.ModelDate
- ProxycurlApi.PDLEmailResult
- ProxycurlApi.PDLPhoneNumberResult
- ProxycurlApi.Patent
- ProxycurlApi.PatentIssuedOn
- ProxycurlApi.PeopleAlsoViewed
- ProxycurlApi.Person
- ProxycurlApi.PersonEndpointResponse
- ProxycurlApi.PersonEndpointResponseBirthDate
- ProxycurlApi.PersonEndpointResponseExtra
- ProxycurlApi.PersonEndpointResponseInferredSalary
- ProxycurlApi.PersonExtra
- ProxycurlApi.PersonGroup
- ProxycurlApi.ProfilePicture
- ProxycurlApi.Project
- ProxycurlApi.Publication
- ProxycurlApi.PublicationPublishedOn
- ProxycurlApi.RoleSearchResult
- ProxycurlApi.SimilarCompany
- ProxycurlApi.SimilarProfile
- ProxycurlApi.TestScore
- ProxycurlApi.TestScoreDateOn
- ProxycurlApi.UrlResult
- ProxycurlApi.UrlResult1
- ProxycurlApi.UrlResult2
- ProxycurlApi.VolunteeringExperience
Documentation for Authorization
BearerAuth
- Type: Bearer authentication