scrapebadger 0.19.0 → 0.20.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/index.d.cts +395 -14
- package/dist/index.d.ts +395 -14
- package/dist/index.js +170 -0
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +170 -1
- package/dist/index.mjs.map +1 -1
- package/package.json +1 -1
package/dist/index.mjs
CHANGED
|
@@ -6552,6 +6552,172 @@ var DepopClient = class {
|
|
|
6552
6552
|
}
|
|
6553
6553
|
};
|
|
6554
6554
|
|
|
6555
|
+
// src/linkedin/client.ts
|
|
6556
|
+
var LinkedInClient = class {
|
|
6557
|
+
client;
|
|
6558
|
+
constructor(client) {
|
|
6559
|
+
this.client = client;
|
|
6560
|
+
}
|
|
6561
|
+
/**
|
|
6562
|
+
* Search LinkedIn jobs (guest search API).
|
|
6563
|
+
*
|
|
6564
|
+
* @param options - Optional parameters (keywords, location, geoId, companyId,
|
|
6565
|
+
* datePosted, experience, jobType, workplace, sort, start, country).
|
|
6566
|
+
* @returns Jobs search response with matching job cards and pagination meta.
|
|
6567
|
+
* @throws AuthenticationError - If the API key is invalid.
|
|
6568
|
+
* @throws ValidationError - If the parameters are invalid.
|
|
6569
|
+
*/
|
|
6570
|
+
async jobsSearch(options = {}) {
|
|
6571
|
+
return this.client.request("/v1/linkedin/jobs/search", {
|
|
6572
|
+
params: {
|
|
6573
|
+
keywords: options.keywords,
|
|
6574
|
+
location: options.location,
|
|
6575
|
+
geo_id: options.geoId,
|
|
6576
|
+
company_id: options.companyId,
|
|
6577
|
+
date_posted: options.datePosted,
|
|
6578
|
+
experience: options.experience,
|
|
6579
|
+
job_type: options.jobType,
|
|
6580
|
+
workplace: options.workplace,
|
|
6581
|
+
sort: options.sort,
|
|
6582
|
+
start: options.start ?? 0,
|
|
6583
|
+
country: options.country ?? "us"
|
|
6584
|
+
}
|
|
6585
|
+
});
|
|
6586
|
+
}
|
|
6587
|
+
/**
|
|
6588
|
+
* Get full detail for one LinkedIn job posting.
|
|
6589
|
+
*
|
|
6590
|
+
* @param jobId - The numeric LinkedIn job id.
|
|
6591
|
+
* @param options - Optional parameters (country).
|
|
6592
|
+
* @returns Full job detail.
|
|
6593
|
+
* @throws NotFoundError - If the job doesn't exist.
|
|
6594
|
+
*/
|
|
6595
|
+
async getJob(jobId, options = {}) {
|
|
6596
|
+
return this.client.request(`/v1/linkedin/jobs/${jobId}`, {
|
|
6597
|
+
params: { country: options.country ?? "us" }
|
|
6598
|
+
});
|
|
6599
|
+
}
|
|
6600
|
+
/**
|
|
6601
|
+
* Get a company's job postings.
|
|
6602
|
+
*
|
|
6603
|
+
* @param companyId - The numeric LinkedIn company id.
|
|
6604
|
+
* @param options - Optional parameters (start, country).
|
|
6605
|
+
* @returns Jobs search response with the company's job cards and pagination meta.
|
|
6606
|
+
* @throws NotFoundError - If the company doesn't exist.
|
|
6607
|
+
*/
|
|
6608
|
+
async companyJobs(companyId, options = {}) {
|
|
6609
|
+
return this.client.request(
|
|
6610
|
+
`/v1/linkedin/companies/${companyId}/jobs`,
|
|
6611
|
+
{
|
|
6612
|
+
params: {
|
|
6613
|
+
start: options.start ?? 0,
|
|
6614
|
+
country: options.country ?? "us"
|
|
6615
|
+
}
|
|
6616
|
+
}
|
|
6617
|
+
);
|
|
6618
|
+
}
|
|
6619
|
+
/**
|
|
6620
|
+
* Get a public LinkedIn company page.
|
|
6621
|
+
*
|
|
6622
|
+
* @param universalName - The company's universal name (URL slug).
|
|
6623
|
+
* @param options - Optional parameters (country).
|
|
6624
|
+
* @returns Company profile.
|
|
6625
|
+
* @throws NotFoundError - If the company doesn't exist.
|
|
6626
|
+
*/
|
|
6627
|
+
async getCompany(universalName, options = {}) {
|
|
6628
|
+
return this.client.request(`/v1/linkedin/companies/${universalName}`, {
|
|
6629
|
+
params: { country: options.country ?? "us" }
|
|
6630
|
+
});
|
|
6631
|
+
}
|
|
6632
|
+
/**
|
|
6633
|
+
* Get a public LinkedIn school page.
|
|
6634
|
+
*
|
|
6635
|
+
* @param universalName - The school's universal name (URL slug).
|
|
6636
|
+
* @param options - Optional parameters (country).
|
|
6637
|
+
* @returns School profile.
|
|
6638
|
+
* @throws NotFoundError - If the school doesn't exist.
|
|
6639
|
+
*/
|
|
6640
|
+
async getSchool(universalName, options = {}) {
|
|
6641
|
+
return this.client.request(`/v1/linkedin/schools/${universalName}`, {
|
|
6642
|
+
params: { country: options.country ?? "us" }
|
|
6643
|
+
});
|
|
6644
|
+
}
|
|
6645
|
+
/**
|
|
6646
|
+
* Get a public LinkedIn profile.
|
|
6647
|
+
*
|
|
6648
|
+
* @param publicId - The profile's public id (URL slug).
|
|
6649
|
+
* @param options - Optional parameters (country).
|
|
6650
|
+
* @returns Public profile.
|
|
6651
|
+
* @throws NotFoundError - If the profile doesn't exist.
|
|
6652
|
+
*/
|
|
6653
|
+
async getProfile(publicId, options = {}) {
|
|
6654
|
+
return this.client.request(`/v1/linkedin/profiles/${publicId}`, {
|
|
6655
|
+
params: { country: options.country ?? "us" }
|
|
6656
|
+
});
|
|
6657
|
+
}
|
|
6658
|
+
/**
|
|
6659
|
+
* Get a public LinkedIn post (activity share).
|
|
6660
|
+
*
|
|
6661
|
+
* @param postSlug - The post slug (last URL segment).
|
|
6662
|
+
* @param options - Optional parameters (country).
|
|
6663
|
+
* @returns Post detail.
|
|
6664
|
+
* @throws NotFoundError - If the post doesn't exist.
|
|
6665
|
+
*/
|
|
6666
|
+
async getPost(postSlug, options = {}) {
|
|
6667
|
+
return this.client.request(`/v1/linkedin/posts/${postSlug}`, {
|
|
6668
|
+
params: { country: options.country ?? "us" }
|
|
6669
|
+
});
|
|
6670
|
+
}
|
|
6671
|
+
/**
|
|
6672
|
+
* Get a public LinkedIn article (`/pulse/`).
|
|
6673
|
+
*
|
|
6674
|
+
* @param articleSlug - The article slug (last URL segment).
|
|
6675
|
+
* @param options - Optional parameters (country).
|
|
6676
|
+
* @returns Article detail (Post shape).
|
|
6677
|
+
* @throws NotFoundError - If the article doesn't exist.
|
|
6678
|
+
*/
|
|
6679
|
+
async getArticle(articleSlug, options = {}) {
|
|
6680
|
+
return this.client.request(`/v1/linkedin/articles/${articleSlug}`, {
|
|
6681
|
+
params: { country: options.country ?? "us" }
|
|
6682
|
+
});
|
|
6683
|
+
}
|
|
6684
|
+
/**
|
|
6685
|
+
* Get a public LinkedIn Learning course.
|
|
6686
|
+
*
|
|
6687
|
+
* @param courseSlug - The course slug (last URL segment).
|
|
6688
|
+
* @param options - Optional parameters (country).
|
|
6689
|
+
* @returns Course detail.
|
|
6690
|
+
* @throws NotFoundError - If the course doesn't exist.
|
|
6691
|
+
*/
|
|
6692
|
+
async getCourse(courseSlug, options = {}) {
|
|
6693
|
+
return this.client.request(`/v1/linkedin/learning/${courseSlug}`, {
|
|
6694
|
+
params: { country: options.country ?? "us" }
|
|
6695
|
+
});
|
|
6696
|
+
}
|
|
6697
|
+
/**
|
|
6698
|
+
* Suggest geo / company ids for a query (typeahead).
|
|
6699
|
+
*
|
|
6700
|
+
* @param query - Location or company name, e.g. "London".
|
|
6701
|
+
* @param type - "geo" | "company" (default: "geo").
|
|
6702
|
+
* @returns Geo-suggest response with matching suggestions.
|
|
6703
|
+
*/
|
|
6704
|
+
async geoSuggest(query, type = "geo") {
|
|
6705
|
+
return this.client.request("/v1/linkedin/geo/suggest", {
|
|
6706
|
+
params: { query, type }
|
|
6707
|
+
});
|
|
6708
|
+
}
|
|
6709
|
+
/**
|
|
6710
|
+
* LinkedIn scraper health check.
|
|
6711
|
+
*
|
|
6712
|
+
* Free — this endpoint costs no credits.
|
|
6713
|
+
*
|
|
6714
|
+
* @returns Health payload (status, service, version, products).
|
|
6715
|
+
*/
|
|
6716
|
+
async health() {
|
|
6717
|
+
return this.client.request("/v1/linkedin/health");
|
|
6718
|
+
}
|
|
6719
|
+
};
|
|
6720
|
+
|
|
6555
6721
|
// src/client.ts
|
|
6556
6722
|
var ScrapeBadger = class {
|
|
6557
6723
|
baseClient;
|
|
@@ -6589,6 +6755,8 @@ var ScrapeBadger = class {
|
|
|
6589
6755
|
loopnet;
|
|
6590
6756
|
/** Depop scraper API client — search, product, user, user products, markets (www.depop.com, 10 markets) */
|
|
6591
6757
|
depop;
|
|
6758
|
+
/** LinkedIn scraper API client — 11 no-auth endpoints (jobs, company, school, profile, post, article, learning, geo) */
|
|
6759
|
+
linkedin;
|
|
6592
6760
|
/**
|
|
6593
6761
|
* Create a new ScrapeBadger client.
|
|
6594
6762
|
*
|
|
@@ -6640,9 +6808,10 @@ var ScrapeBadger = class {
|
|
|
6640
6808
|
this.immobiliare = new ImmobiliareClient(this.baseClient);
|
|
6641
6809
|
this.loopnet = new LoopNetClient(this.baseClient);
|
|
6642
6810
|
this.depop = new DepopClient(this.baseClient);
|
|
6811
|
+
this.linkedin = new LinkedInClient(this.baseClient);
|
|
6643
6812
|
}
|
|
6644
6813
|
};
|
|
6645
6814
|
|
|
6646
|
-
export { AccountRestrictedError, AmazonClient, ListingsClient as AmazonListingsClient, ProductsClient2 as AmazonProductsClient, ReferenceClient2 as AmazonReferenceClient, SearchClient4 as AmazonSearchClient, SellersClient as AmazonSellersClient, AuthenticationError, CommunitiesClient, ConflictError, DepopClient, CategoriesClient as EbayCategoriesClient, EbayClient, ItemsClient2 as EbayItemsClient, ReferenceClient5 as EbayReferenceClient, SearchClient7 as EbaySearchClient, SellersClient2 as EbaySellersClient, GeoClient, AiModeClient as GoogleAiModeClient, AutocompleteClient as GoogleAutocompleteClient, GoogleClient, FinanceClient as GoogleFinanceClient, FlightsClient as GoogleFlightsClient, HotelsClient as GoogleHotelsClient, ImagesClient as GoogleImagesClient, JobsClient as GoogleJobsClient, LensClient as GoogleLensClient, MapsClient as GoogleMapsClient, NewsClient as GoogleNewsClient, PatentsClient as GooglePatentsClient, ProductsClient as GoogleProductsClient, ScholarClient as GoogleScholarClient, SearchClient2 as GoogleSearchClient, ShoppingClient as GoogleShoppingClient, ShortsClient as GoogleShortsClient, TrendsClient2 as GoogleTrendsClient, VideosClient as GoogleVideosClient, ImmobiliareClient, InsufficientCreditsError, AdsClient2 as LeboncoinAdsClient, LeboncoinClient, ReferenceClient8 as LeboncoinReferenceClient, SearchClient10 as LeboncoinSearchClient, SellersClient3 as LeboncoinSellersClient, ListsClient, BrokersClient as LoopNetBrokersClient, LoopNetClient, ListingsClient2 as LoopNetListingsClient, ReferenceClient10 as LoopNetReferenceClient, SearchClient12 as LoopNetSearchClient, NotFoundError, RateLimitError, RealtorClient, PropertiesClient as RealtorPropertiesClient, ReferenceClient7 as RealtorReferenceClient, SearchClient9 as RealtorSearchClient, RedditClient, PostsClient as RedditPostsClient, SearchClient3 as RedditSearchClient, SubredditsClient as RedditSubredditsClient, UsersClient3 as RedditUsersClient, RedfinClient, ScrapeBadger, ScrapeBadgerError, ServerError, ShopeeClient, ProductsClient3 as ShopeeProductsClient, ReferenceClient3 as ShopeeReferenceClient, ReviewsClient as ShopeeReviewsClient, SearchClient5 as ShopeeSearchClient, SpacesClient, StreamClient, AdsClient as TikTokAdsClient, TikTokClient, HashtagsClient as TikTokHashtagsClient, MusicClient as TikTokMusicClient, ReferenceClient4 as TikTokReferenceClient, SearchClient6 as TikTokSearchClient, TrendingClient as TikTokTrendingClient, UsersClient4 as TikTokUsersClient, VideosClient2 as TikTokVideosClient, TimeoutError, TrendsClient, TweetsClient, TwitterClient, UsersClient, ValidationError, VintedClient, ItemsClient as VintedItemsClient, ReferenceClient as VintedReferenceClient, SearchClient as VintedSearchClient, UsersClient2 as VintedUsersClient, WebClient, WebSocketStreamError, ChannelsClient as YoutubeChannelsClient, YoutubeClient, CommunityClient as YoutubeCommunityClient, MusicClient2 as YoutubeMusicClient, PlaylistsClient as YoutubePlaylistsClient, ReferenceClient6 as YoutubeReferenceClient, SearchClient8 as YoutubeSearchClient, ShortsClient2 as YoutubeShortsClient, TrendingClient2 as YoutubeTrendingClient, VideosClient3 as YoutubeVideosClient, AgentClient as ZillowAgentClient, ZillowClient, PropertiesClient2 as ZillowPropertiesClient, ReferenceClient9 as ZillowReferenceClient, SearchClient11 as ZillowSearchClient, collectAll, verifyWebhookSignature };
|
|
6815
|
+
export { AccountRestrictedError, AmazonClient, ListingsClient as AmazonListingsClient, ProductsClient2 as AmazonProductsClient, ReferenceClient2 as AmazonReferenceClient, SearchClient4 as AmazonSearchClient, SellersClient as AmazonSellersClient, AuthenticationError, CommunitiesClient, ConflictError, DepopClient, CategoriesClient as EbayCategoriesClient, EbayClient, ItemsClient2 as EbayItemsClient, ReferenceClient5 as EbayReferenceClient, SearchClient7 as EbaySearchClient, SellersClient2 as EbaySellersClient, GeoClient, AiModeClient as GoogleAiModeClient, AutocompleteClient as GoogleAutocompleteClient, GoogleClient, FinanceClient as GoogleFinanceClient, FlightsClient as GoogleFlightsClient, HotelsClient as GoogleHotelsClient, ImagesClient as GoogleImagesClient, JobsClient as GoogleJobsClient, LensClient as GoogleLensClient, MapsClient as GoogleMapsClient, NewsClient as GoogleNewsClient, PatentsClient as GooglePatentsClient, ProductsClient as GoogleProductsClient, ScholarClient as GoogleScholarClient, SearchClient2 as GoogleSearchClient, ShoppingClient as GoogleShoppingClient, ShortsClient as GoogleShortsClient, TrendsClient2 as GoogleTrendsClient, VideosClient as GoogleVideosClient, ImmobiliareClient, InsufficientCreditsError, AdsClient2 as LeboncoinAdsClient, LeboncoinClient, ReferenceClient8 as LeboncoinReferenceClient, SearchClient10 as LeboncoinSearchClient, SellersClient3 as LeboncoinSellersClient, LinkedInClient, ListsClient, BrokersClient as LoopNetBrokersClient, LoopNetClient, ListingsClient2 as LoopNetListingsClient, ReferenceClient10 as LoopNetReferenceClient, SearchClient12 as LoopNetSearchClient, NotFoundError, RateLimitError, RealtorClient, PropertiesClient as RealtorPropertiesClient, ReferenceClient7 as RealtorReferenceClient, SearchClient9 as RealtorSearchClient, RedditClient, PostsClient as RedditPostsClient, SearchClient3 as RedditSearchClient, SubredditsClient as RedditSubredditsClient, UsersClient3 as RedditUsersClient, RedfinClient, ScrapeBadger, ScrapeBadgerError, ServerError, ShopeeClient, ProductsClient3 as ShopeeProductsClient, ReferenceClient3 as ShopeeReferenceClient, ReviewsClient as ShopeeReviewsClient, SearchClient5 as ShopeeSearchClient, SpacesClient, StreamClient, AdsClient as TikTokAdsClient, TikTokClient, HashtagsClient as TikTokHashtagsClient, MusicClient as TikTokMusicClient, ReferenceClient4 as TikTokReferenceClient, SearchClient6 as TikTokSearchClient, TrendingClient as TikTokTrendingClient, UsersClient4 as TikTokUsersClient, VideosClient2 as TikTokVideosClient, TimeoutError, TrendsClient, TweetsClient, TwitterClient, UsersClient, ValidationError, VintedClient, ItemsClient as VintedItemsClient, ReferenceClient as VintedReferenceClient, SearchClient as VintedSearchClient, UsersClient2 as VintedUsersClient, WebClient, WebSocketStreamError, ChannelsClient as YoutubeChannelsClient, YoutubeClient, CommunityClient as YoutubeCommunityClient, MusicClient2 as YoutubeMusicClient, PlaylistsClient as YoutubePlaylistsClient, ReferenceClient6 as YoutubeReferenceClient, SearchClient8 as YoutubeSearchClient, ShortsClient2 as YoutubeShortsClient, TrendingClient2 as YoutubeTrendingClient, VideosClient3 as YoutubeVideosClient, AgentClient as ZillowAgentClient, ZillowClient, PropertiesClient2 as ZillowPropertiesClient, ReferenceClient9 as ZillowReferenceClient, SearchClient11 as ZillowSearchClient, collectAll, verifyWebhookSignature };
|
|
6647
6816
|
//# sourceMappingURL=index.mjs.map
|
|
6648
6817
|
//# sourceMappingURL=index.mjs.map
|