getanyapi 0.1.0__py3-none-any.whl

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.
Files changed (68) hide show
  1. getanyapi/__init__.py +76 -0
  2. getanyapi/_account.py +132 -0
  3. getanyapi/_async_client.py +215 -0
  4. getanyapi/_client.py +274 -0
  5. getanyapi/_errors.py +115 -0
  6. getanyapi/_pagination.py +295 -0
  7. getanyapi/_transport.py +239 -0
  8. getanyapi/platforms/__init__.py +89 -0
  9. getanyapi/platforms/ahrefs.py +384 -0
  10. getanyapi/platforms/airbnb.py +120 -0
  11. getanyapi/platforms/alibaba.py +95 -0
  12. getanyapi/platforms/amazon.py +442 -0
  13. getanyapi/platforms/appstore.py +95 -0
  14. getanyapi/platforms/bluesky.py +215 -0
  15. getanyapi/platforms/booking.py +128 -0
  16. getanyapi/platforms/coinmarketcap.py +113 -0
  17. getanyapi/platforms/congress.py +106 -0
  18. getanyapi/platforms/dexscreener.py +104 -0
  19. getanyapi/platforms/ebay.py +215 -0
  20. getanyapi/platforms/email.py +166 -0
  21. getanyapi/platforms/facebook.py +2324 -0
  22. getanyapi/platforms/fiverr.py +122 -0
  23. getanyapi/platforms/github.py +954 -0
  24. getanyapi/platforms/glassdoor.py +93 -0
  25. getanyapi/platforms/google.py +232 -0
  26. getanyapi/platforms/google_ads.py +380 -0
  27. getanyapi/platforms/google_finance.py +170 -0
  28. getanyapi/platforms/google_shopping.py +103 -0
  29. getanyapi/platforms/hackernews.py +276 -0
  30. getanyapi/platforms/indeed.py +114 -0
  31. getanyapi/platforms/instagram.py +1868 -0
  32. getanyapi/platforms/linkedin.py +1064 -0
  33. getanyapi/platforms/maps.py +412 -0
  34. getanyapi/platforms/pandaexpress.py +262 -0
  35. getanyapi/platforms/person.py +96 -0
  36. getanyapi/platforms/pinterest.py +96 -0
  37. getanyapi/platforms/playstore.py +99 -0
  38. getanyapi/platforms/polymarket.py +109 -0
  39. getanyapi/platforms/realtor.py +104 -0
  40. getanyapi/platforms/reddit.py +582 -0
  41. getanyapi/platforms/redfin.py +95 -0
  42. getanyapi/platforms/rednote.py +807 -0
  43. getanyapi/platforms/sec.py +118 -0
  44. getanyapi/platforms/semrush.py +358 -0
  45. getanyapi/platforms/snapchat.py +146 -0
  46. getanyapi/platforms/social.py +105 -0
  47. getanyapi/platforms/spotify.py +588 -0
  48. getanyapi/platforms/substack.py +142 -0
  49. getanyapi/platforms/threads.py +358 -0
  50. getanyapi/platforms/tiktok.py +1827 -0
  51. getanyapi/platforms/tiktok_shop.py +536 -0
  52. getanyapi/platforms/tripadvisor.py +180 -0
  53. getanyapi/platforms/trustpilot.py +114 -0
  54. getanyapi/platforms/truthsocial.py +226 -0
  55. getanyapi/platforms/twitter.py +798 -0
  56. getanyapi/platforms/upwork.py +119 -0
  57. getanyapi/platforms/walmart.py +93 -0
  58. getanyapi/platforms/web.py +264 -0
  59. getanyapi/platforms/whatsapp.py +91 -0
  60. getanyapi/platforms/yahoo_finance.py +95 -0
  61. getanyapi/platforms/yelp.py +141 -0
  62. getanyapi/platforms/youtube.py +1452 -0
  63. getanyapi/platforms/zillow.py +218 -0
  64. getanyapi/py.typed +0 -0
  65. getanyapi/types.py +170 -0
  66. getanyapi-0.1.0.dist-info/METADATA +155 -0
  67. getanyapi-0.1.0.dist-info/RECORD +68 -0
  68. getanyapi-0.1.0.dist-info/WHEEL +4 -0
@@ -0,0 +1,1064 @@
1
+ # Generated - do not edit. Regenerate with: pnpm generate
2
+ """Generated namespace module for the linkedin platform."""
3
+
4
+ from __future__ import annotations
5
+
6
+ from typing import Any, Literal, TYPE_CHECKING
7
+
8
+ from pydantic import BaseModel, ConfigDict, Field
9
+ from typing_extensions import NotRequired, Required, TypedDict, Unpack
10
+
11
+ from ..types import RequestOptions, RunResult
12
+
13
+ if TYPE_CHECKING:
14
+ from .._async_client import AsyncAnyAPI
15
+ from .._client import AnyAPI
16
+
17
+
18
+ class LinkedinAdInput(TypedDict, total=False):
19
+ """Input for LinkedIn Ad Details."""
20
+
21
+ url: Required[str]
22
+ """LinkedIn Ad Library ad URL (e.g. "https://www.linkedin.com/ad-library/detail/666281156")."""
23
+
24
+
25
+ class LinkedinAdsInput(TypedDict, total=False):
26
+ """Input for LinkedIn Ads Library."""
27
+
28
+ limit: NotRequired[int]
29
+ """Maximum number of results to return (1-20, default 20). You are billed per result returned, so a lower limit costs less. Range: 1 to 20."""
30
+ url: Required[str]
31
+ """LinkedIn Ad Library search URL or a LinkedIn company URL (e.g. https://www.linkedin.com/ad-library/search?companyIds=1035)."""
32
+
33
+
34
+ class LinkedinAdsSearchInput(TypedDict, total=False):
35
+ """Input for LinkedIn Ad Search."""
36
+
37
+ company: NotRequired[str]
38
+ """Company name to search (e.g. "microsoft")."""
39
+ companyId: NotRequired[str]
40
+ """LinkedIn company identifier."""
41
+ countries: NotRequired[str]
42
+ """Comma-separated two-letter country codes (e.g. "US,CA,MX")."""
43
+ endDate: NotRequired[str]
44
+ """Search end date in YYYY-MM-DD format."""
45
+ keyword: NotRequired[str]
46
+ """Keyword term for the ad search."""
47
+ paginationToken: NotRequired[str]
48
+ """Opaque pagination token from a previous response's nextCursor."""
49
+ startDate: NotRequired[str]
50
+ """Search start date in YYYY-MM-DD format."""
51
+
52
+
53
+ class LinkedinCompanyInput(TypedDict, total=False):
54
+ """Input for LinkedIn Company."""
55
+
56
+ url: Required[str]
57
+ """Full LinkedIn company page URL."""
58
+
59
+
60
+ class LinkedinCompanyEmployeesInput(TypedDict, total=False):
61
+ """Input for LinkedIn Company Employees."""
62
+
63
+ company: Required[str]
64
+ """Company name or LinkedIn company URL (e.g. google or https://www.linkedin.com/company/google/)."""
65
+ jobTitle: NotRequired[str]
66
+ """Optional job-title filter supporting boolean operators (e.g. CEO OR CTO)."""
67
+ limit: NotRequired[int]
68
+ """Maximum number of results to return (1-10, default 10). You are billed per result returned, so a lower limit costs less. Range: 1 to 10."""
69
+
70
+
71
+ class LinkedinCompanyPostsInput(TypedDict, total=False):
72
+ """Input for LinkedIn Company Posts."""
73
+
74
+ page: NotRequired[int]
75
+ """Page number for pagination. Minimum: 1."""
76
+ url: Required[str]
77
+ """Full LinkedIn company page URL."""
78
+
79
+
80
+ class LinkedinEmailInput(TypedDict, total=False):
81
+ """Input for LinkedIn Email Finder."""
82
+
83
+ profileUrl: Required[str]
84
+ """LinkedIn profile URL or public ID to find the work email for."""
85
+
86
+
87
+ class LinkedinJobsInput(TypedDict, total=False):
88
+ """Input for LinkedIn Jobs."""
89
+
90
+ limit: NotRequired[int]
91
+ """Maximum number of results to return (1-25, default 25). You are billed per result returned, so a lower limit costs less. Range: 1 to 25."""
92
+ location: NotRequired[str]
93
+ """City, region, or country to search within."""
94
+ query: Required[str]
95
+ """Job title or keywords to search."""
96
+
97
+
98
+ class LinkedinPostInput(TypedDict, total=False):
99
+ """Input for LinkedIn Post."""
100
+
101
+ url: Required[str]
102
+ """Full LinkedIn post or article URL."""
103
+
104
+
105
+ class LinkedinPostTranscriptInput(TypedDict, total=False):
106
+ """Input for LinkedIn Post Transcript."""
107
+
108
+ url: Required[str]
109
+ """The full URL of the LinkedIn post to get the video transcript from."""
110
+
111
+
112
+ class LinkedinProfileInput(TypedDict, total=False):
113
+ """Input for LinkedIn Profile."""
114
+
115
+ url: Required[str]
116
+ """Full LinkedIn profile URL."""
117
+
118
+
119
+ class LinkedinSearchCompaniesInput(TypedDict, total=False):
120
+ """Input for LinkedIn Company Search."""
121
+
122
+ limit: NotRequired[int]
123
+ """Maximum number of results to return (1-20, default 20). You are billed per result returned, so a lower limit costs less. Range: 1 to 20."""
124
+ location: NotRequired[str]
125
+ """Optional location filter, written out in full (e.g. United Kingdom or San Francisco)."""
126
+ query: Required[str]
127
+ """Keyword to search LinkedIn companies for (e.g. marketing agency)."""
128
+
129
+
130
+ class LinkedinSearchPostsInput(TypedDict, total=False):
131
+ """Input for LinkedIn Post Search."""
132
+
133
+ cursor: NotRequired[str]
134
+ """Pagination cursor from a previous response."""
135
+ datePosted: NotRequired[
136
+ Literal["last-hour", "last-day", "last-week", "last-month", "last-year"]
137
+ ]
138
+ """Filter by recency. One of last-hour, last-day, last-week, last-month, last-year."""
139
+ query: Required[str]
140
+ """The post search query."""
141
+
142
+
143
+ class LinkedinSearchProfilesInput(TypedDict, total=False):
144
+ """Input for LinkedIn Profile Search."""
145
+
146
+ jobTitle: NotRequired[str]
147
+ """Optional current job title filter (e.g. 'Software Engineer')."""
148
+ limit: NotRequired[int]
149
+ """Maximum number of results to return (1-10, default 10). You are billed per result returned, so a lower limit costs less. Range: 1 to 10."""
150
+ location: NotRequired[str]
151
+ """Optional location filter (e.g. 'San Francisco')."""
152
+ query: Required[str]
153
+ """Search query for LinkedIn profiles - a role, name, or keywords (e.g. 'Marketing Manager')."""
154
+
155
+
156
+ class LinkedinAdData(BaseModel):
157
+ model_config = ConfigDict(extra="allow", populate_by_name=True)
158
+
159
+ ad_type: str = Field(alias="adType")
160
+ advertiser: str
161
+ advertiser_linkedin_page: str = Field(alias="advertiserLinkedinPage")
162
+ cta: str
163
+ description: str
164
+ destination_url: str = Field(alias="destinationUrl")
165
+ end_date: str = Field(alias="endDate", description="ISO 8601 date.")
166
+ headline: str
167
+ id: str
168
+ image: str
169
+ start_date: str = Field(alias="startDate", description="ISO 8601 date.")
170
+ total_impressions: str = Field(alias="totalImpressions")
171
+
172
+
173
+ class LinkedinAdsData(BaseModel):
174
+ items: list[LinkedinAdsItem] = Field(
175
+ description="Ad records: advertiser name, ad creative text, format, and ad library URL."
176
+ )
177
+
178
+
179
+ class LinkedinAdsItem(BaseModel):
180
+ model_config = ConfigDict(extra="allow")
181
+
182
+ id: str
183
+ text: str | None = Field(
184
+ default=None, description="Present whenever the upstream returns this record."
185
+ )
186
+ url: str
187
+
188
+
189
+ class LinkedinAdsSearchData(BaseModel):
190
+ model_config = ConfigDict(populate_by_name=True)
191
+
192
+ ads: list[LinkedinAdsSearchAd]
193
+ next_cursor: str = Field(alias="nextCursor")
194
+ total_ads: int = Field(alias="totalAds")
195
+
196
+
197
+ class LinkedinAdsSearchAd(BaseModel):
198
+ model_config = ConfigDict(extra="allow", populate_by_name=True)
199
+
200
+ ad_type: str = Field(alias="adType")
201
+ advertiser: str
202
+ advertiser_linkedin_page: str = Field(alias="advertiserLinkedinPage")
203
+ cta: str
204
+ description: str
205
+ destination_url: str = Field(alias="destinationUrl")
206
+ end_date: str = Field(alias="endDate")
207
+ headline: str
208
+ id: str
209
+ start_date: str = Field(alias="startDate")
210
+ total_impressions: str = Field(alias="totalImpressions")
211
+
212
+
213
+ class LinkedinCompanyData(BaseModel):
214
+ model_config = ConfigDict(extra="allow", populate_by_name=True)
215
+
216
+ description: str
217
+ employee_count: int = Field(alias="employeeCount")
218
+ industry: str
219
+ logo_url: str = Field(alias="logoUrl")
220
+ name: str
221
+ tagline: str
222
+ website: str
223
+
224
+
225
+ class LinkedinCompanyEmployeesData(BaseModel):
226
+ items: list[LinkedinCompanyEmployeesItem] = Field(
227
+ description="Employee records: name, job title, location text, and LinkedIn profile URL."
228
+ )
229
+
230
+
231
+ class LinkedinCompanyEmployeesItem(BaseModel):
232
+ model_config = ConfigDict(extra="allow", populate_by_name=True)
233
+
234
+ handle: str | None = Field(
235
+ default=None, description="Present whenever the upstream returns this record."
236
+ )
237
+ job_title: str | None = Field(
238
+ default=None,
239
+ alias="jobTitle",
240
+ description="The employee's current role or headline at the company.",
241
+ )
242
+ location_text: str | None = Field(
243
+ default=None,
244
+ alias="locationText",
245
+ description="The employee's location as a single string (city, region, country).",
246
+ )
247
+ name: str | None = Field(
248
+ default=None, description="Present whenever the upstream returns this record."
249
+ )
250
+ url: str
251
+
252
+
253
+ class LinkedinCompanyPostsData(BaseModel):
254
+ posts: list[LinkedinCompanyPostsPost]
255
+
256
+
257
+ class LinkedinCompanyPostsPost(BaseModel):
258
+ model_config = ConfigDict(extra="allow", populate_by_name=True)
259
+
260
+ id: str
261
+ published_at: str = Field(alias="publishedAt")
262
+ text: str
263
+ url: str
264
+
265
+
266
+ class LinkedinEmailData(BaseModel):
267
+ items: list[LinkedinEmailItem] = Field(
268
+ description="Email lookup records: the discovered work email for a LinkedIn profile, with the person's name, profile URL, title, and company."
269
+ )
270
+
271
+
272
+ class LinkedinEmailItem(BaseModel):
273
+ model_config = ConfigDict(extra="allow", populate_by_name=True)
274
+
275
+ company: str | None = Field(default=None, description="Current company name.")
276
+ email: str = Field(description="Discovered work email address.")
277
+ linkedin_url: str | None = Field(
278
+ default=None,
279
+ alias="linkedinUrl",
280
+ description="Canonical LinkedIn profile URL. Present whenever the upstream returns this record.",
281
+ )
282
+ name: str = Field(description="Full name on the LinkedIn profile.")
283
+ title: str | None = Field(default=None, description="Current job title.")
284
+
285
+
286
+ class LinkedinJobsData(BaseModel):
287
+ items: list[LinkedinJobsItem] = Field(
288
+ description="Job records: title and listing URL, plus (when present) company, location, posting date, description, and seniority."
289
+ )
290
+
291
+
292
+ class LinkedinJobsItem(BaseModel):
293
+ model_config = ConfigDict(extra="allow", populate_by_name=True)
294
+
295
+ company: str | None = Field(
296
+ default=None,
297
+ description="Hiring company name. Present whenever the upstream returns this record.",
298
+ )
299
+ description: str | None = Field(
300
+ default=None, description="Full job description text."
301
+ )
302
+ location: str | None = Field(
303
+ default=None,
304
+ description="Job location (city, region). Present whenever the upstream returns this record.",
305
+ )
306
+ posted_at: str | None = Field(
307
+ default=None,
308
+ alias="postedAt",
309
+ description="When the job was posted, as an ISO 8601 timestamp. Present whenever the upstream returns this record.",
310
+ )
311
+ seniority: str | None = Field(
312
+ default=None,
313
+ description="Seniority / experience level (e.g. Entry level, Mid-Senior, Not Applicable).",
314
+ )
315
+ title: str
316
+ url: str = Field(description="Canonical LinkedIn job listing URL.")
317
+
318
+
319
+ class LinkedinPostData(BaseModel):
320
+ model_config = ConfigDict(extra="allow", populate_by_name=True)
321
+
322
+ author: str
323
+ comments: int
324
+ likes: int
325
+ published_at: str = Field(alias="publishedAt")
326
+ text: str
327
+ title: str
328
+ url: str
329
+
330
+
331
+ class LinkedinPostTranscriptData(BaseModel):
332
+ model_config = ConfigDict(extra="allow", populate_by_name=True)
333
+
334
+ transcript: str
335
+ transcript_not_available: bool = Field(alias="transcriptNotAvailable")
336
+ url: str
337
+
338
+
339
+ class LinkedinProfileData(BaseModel):
340
+ model_config = ConfigDict(extra="allow", populate_by_name=True)
341
+
342
+ about: str
343
+ articles: list[LinkedinProfileArticle]
344
+ avatar_url: str = Field(alias="avatarUrl")
345
+ education: list[LinkedinProfileEducation]
346
+ experience: list[LinkedinProfileExperience]
347
+ followers: int
348
+ location: str
349
+ name: str
350
+ recent_posts: list[LinkedinProfileRecentPost] = Field(alias="recentPosts")
351
+
352
+
353
+ class LinkedinProfileArticle(BaseModel):
354
+ model_config = ConfigDict(extra="allow", populate_by_name=True)
355
+
356
+ headline: str
357
+ published_at: str | None = Field(default=None, alias="publishedAt")
358
+ url: str | None = None
359
+
360
+
361
+ class LinkedinProfileEducation(BaseModel):
362
+ model_config = ConfigDict(extra="allow", populate_by_name=True)
363
+
364
+ end_date: str | None = Field(default=None, alias="endDate")
365
+ school: str
366
+ school_url: str | None = Field(default=None, alias="schoolUrl")
367
+ start_date: str | None = Field(default=None, alias="startDate")
368
+
369
+
370
+ class LinkedinProfileExperience(BaseModel):
371
+ model_config = ConfigDict(extra="allow", populate_by_name=True)
372
+
373
+ company: str
374
+ company_url: str | None = Field(default=None, alias="companyUrl")
375
+ end_date: str | None = Field(default=None, alias="endDate")
376
+ start_date: str | None = Field(default=None, alias="startDate")
377
+
378
+
379
+ class LinkedinProfileRecentPost(BaseModel):
380
+ model_config = ConfigDict(extra="allow", populate_by_name=True)
381
+
382
+ activity_type: str | None = Field(default=None, alias="activityType")
383
+ id: str
384
+ published_at: str | None = Field(default=None, alias="publishedAt")
385
+ text: str | None = None
386
+ url: str | None = None
387
+
388
+
389
+ class LinkedinSearchCompaniesData(BaseModel):
390
+ items: list[LinkedinSearchCompaniesItem] = Field(
391
+ description="Matching company records: name, LinkedIn URL, industry, location, headcount range, and description."
392
+ )
393
+
394
+
395
+ class LinkedinSearchCompaniesItem(BaseModel):
396
+ model_config = ConfigDict(extra="allow")
397
+
398
+ id: str
399
+ name: str
400
+ url: str
401
+
402
+
403
+ class LinkedinSearchPostsData(BaseModel):
404
+ posts: list[LinkedinSearchPostsPost]
405
+
406
+
407
+ class LinkedinSearchPostsPost(BaseModel):
408
+ model_config = ConfigDict(extra="allow", populate_by_name=True)
409
+
410
+ published_at: str = Field(alias="publishedAt")
411
+ text: str
412
+ url: str
413
+
414
+
415
+ class LinkedinSearchProfilesData(BaseModel):
416
+ items: list[LinkedinSearchProfilesItem] = Field(
417
+ description="Matched profile records. Each carries the profile URL, handle, and id. Depending on the match, records may also include first/last name, headline, location, current position, work experience, and education, plus upstream extras (about, skills, languages, certifications, connections, profile picture, and more) that pass through."
418
+ )
419
+
420
+
421
+ class LinkedinSearchProfilesItem(BaseModel):
422
+ model_config = ConfigDict(extra="allow", populate_by_name=True)
423
+
424
+ current_position: Any | None = Field(
425
+ default=None,
426
+ alias="currentPosition",
427
+ description="Current role(s), passed through from the upstream. Typically a list of objects with job title, company, dates, and description; shape can vary by profile.",
428
+ )
429
+ education: Any | None = Field(
430
+ default=None,
431
+ description="Education history, passed through from the upstream. Typically a list of objects with school, degree, and field of study; shape can vary by profile.",
432
+ )
433
+ experience: Any | None = Field(
434
+ default=None,
435
+ description="Full work history, passed through from the upstream. Typically a list of objects with job title, company, dates, and description; shape can vary by profile.",
436
+ )
437
+ first_name: str | None = Field(
438
+ default=None, alias="firstName", description="Member's first name."
439
+ )
440
+ handle: str | None = Field(
441
+ default=None,
442
+ description="Public profile identifier (the vanity slug in the URL). Present whenever the upstream returns this record.",
443
+ )
444
+ headline: str | None = Field(
445
+ default=None,
446
+ description="Profile headline (the tagline under the name). Present whenever the upstream returns this record.",
447
+ )
448
+ id: str = Field(description="LinkedIn member URN id for the profile.")
449
+ last_name: str | None = Field(
450
+ default=None, alias="lastName", description="Member's last name."
451
+ )
452
+ location: Any | None = Field(
453
+ default=None,
454
+ description="Member's location, passed through from the upstream. Typically an object with the displayed location text and country code; shape can vary by profile.",
455
+ )
456
+ url: str = Field(description="Canonical LinkedIn profile URL.")
457
+
458
+
459
+ class LinkedinNamespace:
460
+ """Typed methods for this platform. Attached lazily to the client."""
461
+
462
+ def __init__(self, client: "AnyAPI") -> None:
463
+ self._client = client
464
+
465
+ def ad(
466
+ self, *, options: RequestOptions | None = None, **input: Unpack[LinkedinAdInput]
467
+ ) -> RunResult[LinkedinAdData]:
468
+ """LinkedIn Ad Details
469
+
470
+ Look up a single LinkedIn Ad Library ad by URL and get the advertiser,
471
+ headline, creative text, format, CTA, targeting, run dates, and impressions
472
+ as clean JSON, billed per request in USD.
473
+
474
+ Price: $0.002 per request.
475
+
476
+ Example:
477
+ res = client.linkedin.ad(url="https://www.linkedin.com/ad-library/detail/1487405616")
478
+ """
479
+ raw = self._client._run_raw( # pyright: ignore[reportPrivateUsage]
480
+ "linkedin.ad", dict(input), options
481
+ )
482
+ return RunResult[LinkedinAdData].model_validate(raw)
483
+
484
+ def ads(
485
+ self,
486
+ *,
487
+ options: RequestOptions | None = None,
488
+ **input: Unpack[LinkedinAdsInput],
489
+ ) -> RunResult[LinkedinAdsData]:
490
+ """LinkedIn Ads Library
491
+
492
+ Search the LinkedIn Ad Library by search URL and list the matching ads
493
+ (advertiser, creative text, format), priced per request in USD.
494
+
495
+ Price: $0.00005 per request plus $0.0015 per result.
496
+
497
+ Example:
498
+ res = client.linkedin.ads(limit=3, url="https://www.linkedin.com/company/stripe")
499
+ """
500
+ raw = self._client._run_raw( # pyright: ignore[reportPrivateUsage]
501
+ "linkedin.ads", dict(input), options
502
+ )
503
+ return RunResult[LinkedinAdsData].model_validate(raw)
504
+
505
+ def ads_search(
506
+ self,
507
+ *,
508
+ options: RequestOptions | None = None,
509
+ **input: Unpack[LinkedinAdsSearchInput],
510
+ ) -> RunResult[LinkedinAdsSearchData]:
511
+ """LinkedIn Ad Search
512
+
513
+ Search the LinkedIn Ad Library by company or keyword and list matching ads -
514
+ advertiser, headline, creative text, format, CTA, and run dates - with
515
+ pagination, billed per request in USD.
516
+
517
+ Price: $0.002 per request.
518
+
519
+ Example:
520
+ res = client.linkedin.ads_search(company="microsoft")
521
+ """
522
+ raw = self._client._run_raw( # pyright: ignore[reportPrivateUsage]
523
+ "linkedin.ads_search", dict(input), options
524
+ )
525
+ return RunResult[LinkedinAdsSearchData].model_validate(raw)
526
+
527
+ def company(
528
+ self,
529
+ *,
530
+ options: RequestOptions | None = None,
531
+ **input: Unpack[LinkedinCompanyInput],
532
+ ) -> RunResult[LinkedinCompanyData]:
533
+ """LinkedIn Company
534
+
535
+ Fetch a LinkedIn company page (description, employee count, industry,
536
+ website, logo) by company URL, normalized across providers with transparent
537
+ failover.
538
+
539
+ Price: $0.002 per request.
540
+
541
+ Example:
542
+ res = client.linkedin.company(url="https://www.linkedin.com/company/stripe")
543
+ """
544
+ raw = self._client._run_raw( # pyright: ignore[reportPrivateUsage]
545
+ "linkedin.company", dict(input), options
546
+ )
547
+ return RunResult[LinkedinCompanyData].model_validate(raw)
548
+
549
+ def company_employees(
550
+ self,
551
+ *,
552
+ options: RequestOptions | None = None,
553
+ **input: Unpack[LinkedinCompanyEmployeesInput],
554
+ ) -> RunResult[LinkedinCompanyEmployeesData]:
555
+ """LinkedIn Company Employees
556
+
557
+ List the employees of a LinkedIn company by name or company URL, with
558
+ optional job-title filtering and transparent per-request USD pricing.
559
+
560
+ Price: $0.01 per result.
561
+
562
+ Example:
563
+ res = client.linkedin.company_employees(company="stripe", limit=3)
564
+ """
565
+ raw = self._client._run_raw( # pyright: ignore[reportPrivateUsage]
566
+ "linkedin.company_employees", dict(input), options
567
+ )
568
+ return RunResult[LinkedinCompanyEmployeesData].model_validate(raw)
569
+
570
+ def company_posts(
571
+ self,
572
+ *,
573
+ options: RequestOptions | None = None,
574
+ **input: Unpack[LinkedinCompanyPostsInput],
575
+ ) -> RunResult[LinkedinCompanyPostsData]:
576
+ """LinkedIn Company Posts
577
+
578
+ List a LinkedIn company page's recent posts by URL with page pagination
579
+ (text, link, publish date), normalized across providers.
580
+
581
+ Price: $0.002 per request.
582
+
583
+ Example:
584
+ res = client.linkedin.company_posts(url="https://www.linkedin.com/company/stripe")
585
+ """
586
+ raw = self._client._run_raw( # pyright: ignore[reportPrivateUsage]
587
+ "linkedin.company_posts", dict(input), options
588
+ )
589
+ return RunResult[LinkedinCompanyPostsData].model_validate(raw)
590
+
591
+ def email(
592
+ self,
593
+ *,
594
+ options: RequestOptions | None = None,
595
+ **input: Unpack[LinkedinEmailInput],
596
+ ) -> RunResult[LinkedinEmailData]:
597
+ """LinkedIn Email Finder
598
+
599
+ Find the verified work email behind a LinkedIn profile URL or ID, with
600
+ transparent per-request USD pricing.
601
+
602
+ Price: $0.0007 per result.
603
+
604
+ Example:
605
+ res = client.linkedin.email(profileUrl="https://www.linkedin.com/in/satyanadella")
606
+ """
607
+ raw = self._client._run_raw( # pyright: ignore[reportPrivateUsage]
608
+ "linkedin.email", dict(input), options
609
+ )
610
+ return RunResult[LinkedinEmailData].model_validate(raw)
611
+
612
+ def jobs(
613
+ self,
614
+ *,
615
+ options: RequestOptions | None = None,
616
+ **input: Unpack[LinkedinJobsInput],
617
+ ) -> RunResult[LinkedinJobsData]:
618
+ """LinkedIn Jobs
619
+
620
+ Search LinkedIn job listings by title and location - up to 25 normalized job
621
+ records per request at a flat USD price.
622
+
623
+ Price: $0.001 per request.
624
+
625
+ Example:
626
+ res = client.linkedin.jobs(limit=3, location="San Francisco", query="software engineer")
627
+ """
628
+ raw = self._client._run_raw( # pyright: ignore[reportPrivateUsage]
629
+ "linkedin.jobs", dict(input), options
630
+ )
631
+ return RunResult[LinkedinJobsData].model_validate(raw)
632
+
633
+ def post(
634
+ self,
635
+ *,
636
+ options: RequestOptions | None = None,
637
+ **input: Unpack[LinkedinPostInput],
638
+ ) -> RunResult[LinkedinPostData]:
639
+ """LinkedIn Post
640
+
641
+ Fetch a single LinkedIn post or article by URL (title, text, author, like
642
+ and comment counts, publish date), normalized across providers.
643
+
644
+ Price: $0.001 per request.
645
+
646
+ Example:
647
+ res = client.linkedin.post(url="https://www.linkedin.com/posts/stripe_last-week-agent-traffic-surpassed-human-activity-7470882737390940160-2Nxs")
648
+ """
649
+ raw = self._client._run_raw( # pyright: ignore[reportPrivateUsage]
650
+ "linkedin.post", dict(input), options
651
+ )
652
+ return RunResult[LinkedinPostData].model_validate(raw)
653
+
654
+ def post_transcript(
655
+ self,
656
+ *,
657
+ options: RequestOptions | None = None,
658
+ **input: Unpack[LinkedinPostTranscriptInput],
659
+ ) -> RunResult[LinkedinPostTranscriptData]:
660
+ """LinkedIn Post Transcript
661
+
662
+ Get the spoken transcript of a LinkedIn video post by URL, with transparent
663
+ per-request USD pricing.
664
+
665
+ Price: $0.002 per request.
666
+
667
+ Example:
668
+ res = client.linkedin.post_transcript(url="https://www.linkedin.com/posts/artificial-analysis_gemini-35-flash-is-a-step-forward-for-google-activity-7465082408409870337-4Pm-")
669
+ """
670
+ raw = self._client._run_raw( # pyright: ignore[reportPrivateUsage]
671
+ "linkedin.post_transcript", dict(input), options
672
+ )
673
+ return RunResult[LinkedinPostTranscriptData].model_validate(raw)
674
+
675
+ def profile(
676
+ self,
677
+ *,
678
+ options: RequestOptions | None = None,
679
+ **input: Unpack[LinkedinProfileInput],
680
+ ) -> RunResult[LinkedinProfileData]:
681
+ """LinkedIn Profile
682
+
683
+ Fetch a LinkedIn member's public profile by URL: name, location, followers,
684
+ about, plus experience, education, recent posts, and published articles.
685
+
686
+ Price: $0.002 per request.
687
+
688
+ Example:
689
+ res = client.linkedin.profile(url="https://www.linkedin.com/in/williamhgates")
690
+ """
691
+ raw = self._client._run_raw( # pyright: ignore[reportPrivateUsage]
692
+ "linkedin.profile", dict(input), options
693
+ )
694
+ return RunResult[LinkedinProfileData].model_validate(raw)
695
+
696
+ def search_companies(
697
+ self,
698
+ *,
699
+ options: RequestOptions | None = None,
700
+ **input: Unpack[LinkedinSearchCompaniesInput],
701
+ ) -> RunResult[LinkedinSearchCompaniesData]:
702
+ """LinkedIn Company Search
703
+
704
+ Search LinkedIn companies by keyword with optional location filtering,
705
+ returning normalized company records with transparent per-request USD
706
+ pricing.
707
+
708
+ Price: $0.001 per request plus $0.004 per result.
709
+
710
+ Example:
711
+ res = client.linkedin.search_companies(limit=3, query="fintech")
712
+ """
713
+ raw = self._client._run_raw( # pyright: ignore[reportPrivateUsage]
714
+ "linkedin.search_companies", dict(input), options
715
+ )
716
+ return RunResult[LinkedinSearchCompaniesData].model_validate(raw)
717
+
718
+ def search_posts(
719
+ self,
720
+ *,
721
+ options: RequestOptions | None = None,
722
+ **input: Unpack[LinkedinSearchPostsInput],
723
+ ) -> RunResult[LinkedinSearchPostsData]:
724
+ """LinkedIn Post Search
725
+
726
+ Search public LinkedIn posts by keyword (text, link, publish date),
727
+ normalized across providers with transparent failover.
728
+
729
+ Price: $0.002 per request.
730
+
731
+ Example:
732
+ res = client.linkedin.search_posts(datePosted="last-week", query="hiring")
733
+ """
734
+ raw = self._client._run_raw( # pyright: ignore[reportPrivateUsage]
735
+ "linkedin.search_posts", dict(input), options
736
+ )
737
+ return RunResult[LinkedinSearchPostsData].model_validate(raw)
738
+
739
+ def search_profiles(
740
+ self,
741
+ *,
742
+ options: RequestOptions | None = None,
743
+ **input: Unpack[LinkedinSearchProfilesInput],
744
+ ) -> RunResult[LinkedinSearchProfilesData]:
745
+ """LinkedIn Profile Search
746
+
747
+ Search LinkedIn profiles by keyword with optional location and job-title
748
+ filters. Each match returns a full profile record: name, headline, location,
749
+ current position, work experience, and education, plus the profile URL,
750
+ handle, and id. Flat USD price per request.
751
+
752
+ Price: $0.0325 per request.
753
+
754
+ Example:
755
+ res = client.linkedin.search_profiles(limit=3, query="recruiter")
756
+ """
757
+ raw = self._client._run_raw( # pyright: ignore[reportPrivateUsage]
758
+ "linkedin.search_profiles", dict(input), options
759
+ )
760
+ return RunResult[LinkedinSearchProfilesData].model_validate(raw)
761
+
762
+
763
+ class AsyncLinkedinNamespace:
764
+ """Typed methods for this platform. Attached lazily to the client."""
765
+
766
+ def __init__(self, client: "AsyncAnyAPI") -> None:
767
+ self._client = client
768
+
769
+ async def ad(
770
+ self, *, options: RequestOptions | None = None, **input: Unpack[LinkedinAdInput]
771
+ ) -> RunResult[LinkedinAdData]:
772
+ """LinkedIn Ad Details
773
+
774
+ Look up a single LinkedIn Ad Library ad by URL and get the advertiser,
775
+ headline, creative text, format, CTA, targeting, run dates, and impressions
776
+ as clean JSON, billed per request in USD.
777
+
778
+ Price: $0.002 per request.
779
+
780
+ Example:
781
+ res = client.linkedin.ad(url="https://www.linkedin.com/ad-library/detail/1487405616")
782
+ """
783
+ raw = await self._client._arun_raw( # pyright: ignore[reportPrivateUsage]
784
+ "linkedin.ad", dict(input), options
785
+ )
786
+ return RunResult[LinkedinAdData].model_validate(raw)
787
+
788
+ async def ads(
789
+ self,
790
+ *,
791
+ options: RequestOptions | None = None,
792
+ **input: Unpack[LinkedinAdsInput],
793
+ ) -> RunResult[LinkedinAdsData]:
794
+ """LinkedIn Ads Library
795
+
796
+ Search the LinkedIn Ad Library by search URL and list the matching ads
797
+ (advertiser, creative text, format), priced per request in USD.
798
+
799
+ Price: $0.00005 per request plus $0.0015 per result.
800
+
801
+ Example:
802
+ res = client.linkedin.ads(limit=3, url="https://www.linkedin.com/company/stripe")
803
+ """
804
+ raw = await self._client._arun_raw( # pyright: ignore[reportPrivateUsage]
805
+ "linkedin.ads", dict(input), options
806
+ )
807
+ return RunResult[LinkedinAdsData].model_validate(raw)
808
+
809
+ async def ads_search(
810
+ self,
811
+ *,
812
+ options: RequestOptions | None = None,
813
+ **input: Unpack[LinkedinAdsSearchInput],
814
+ ) -> RunResult[LinkedinAdsSearchData]:
815
+ """LinkedIn Ad Search
816
+
817
+ Search the LinkedIn Ad Library by company or keyword and list matching ads -
818
+ advertiser, headline, creative text, format, CTA, and run dates - with
819
+ pagination, billed per request in USD.
820
+
821
+ Price: $0.002 per request.
822
+
823
+ Example:
824
+ res = client.linkedin.ads_search(company="microsoft")
825
+ """
826
+ raw = await self._client._arun_raw( # pyright: ignore[reportPrivateUsage]
827
+ "linkedin.ads_search", dict(input), options
828
+ )
829
+ return RunResult[LinkedinAdsSearchData].model_validate(raw)
830
+
831
+ async def company(
832
+ self,
833
+ *,
834
+ options: RequestOptions | None = None,
835
+ **input: Unpack[LinkedinCompanyInput],
836
+ ) -> RunResult[LinkedinCompanyData]:
837
+ """LinkedIn Company
838
+
839
+ Fetch a LinkedIn company page (description, employee count, industry,
840
+ website, logo) by company URL, normalized across providers with transparent
841
+ failover.
842
+
843
+ Price: $0.002 per request.
844
+
845
+ Example:
846
+ res = client.linkedin.company(url="https://www.linkedin.com/company/stripe")
847
+ """
848
+ raw = await self._client._arun_raw( # pyright: ignore[reportPrivateUsage]
849
+ "linkedin.company", dict(input), options
850
+ )
851
+ return RunResult[LinkedinCompanyData].model_validate(raw)
852
+
853
+ async def company_employees(
854
+ self,
855
+ *,
856
+ options: RequestOptions | None = None,
857
+ **input: Unpack[LinkedinCompanyEmployeesInput],
858
+ ) -> RunResult[LinkedinCompanyEmployeesData]:
859
+ """LinkedIn Company Employees
860
+
861
+ List the employees of a LinkedIn company by name or company URL, with
862
+ optional job-title filtering and transparent per-request USD pricing.
863
+
864
+ Price: $0.01 per result.
865
+
866
+ Example:
867
+ res = client.linkedin.company_employees(company="stripe", limit=3)
868
+ """
869
+ raw = await self._client._arun_raw( # pyright: ignore[reportPrivateUsage]
870
+ "linkedin.company_employees", dict(input), options
871
+ )
872
+ return RunResult[LinkedinCompanyEmployeesData].model_validate(raw)
873
+
874
+ async def company_posts(
875
+ self,
876
+ *,
877
+ options: RequestOptions | None = None,
878
+ **input: Unpack[LinkedinCompanyPostsInput],
879
+ ) -> RunResult[LinkedinCompanyPostsData]:
880
+ """LinkedIn Company Posts
881
+
882
+ List a LinkedIn company page's recent posts by URL with page pagination
883
+ (text, link, publish date), normalized across providers.
884
+
885
+ Price: $0.002 per request.
886
+
887
+ Example:
888
+ res = client.linkedin.company_posts(url="https://www.linkedin.com/company/stripe")
889
+ """
890
+ raw = await self._client._arun_raw( # pyright: ignore[reportPrivateUsage]
891
+ "linkedin.company_posts", dict(input), options
892
+ )
893
+ return RunResult[LinkedinCompanyPostsData].model_validate(raw)
894
+
895
+ async def email(
896
+ self,
897
+ *,
898
+ options: RequestOptions | None = None,
899
+ **input: Unpack[LinkedinEmailInput],
900
+ ) -> RunResult[LinkedinEmailData]:
901
+ """LinkedIn Email Finder
902
+
903
+ Find the verified work email behind a LinkedIn profile URL or ID, with
904
+ transparent per-request USD pricing.
905
+
906
+ Price: $0.0007 per result.
907
+
908
+ Example:
909
+ res = client.linkedin.email(profileUrl="https://www.linkedin.com/in/satyanadella")
910
+ """
911
+ raw = await self._client._arun_raw( # pyright: ignore[reportPrivateUsage]
912
+ "linkedin.email", dict(input), options
913
+ )
914
+ return RunResult[LinkedinEmailData].model_validate(raw)
915
+
916
+ async def jobs(
917
+ self,
918
+ *,
919
+ options: RequestOptions | None = None,
920
+ **input: Unpack[LinkedinJobsInput],
921
+ ) -> RunResult[LinkedinJobsData]:
922
+ """LinkedIn Jobs
923
+
924
+ Search LinkedIn job listings by title and location - up to 25 normalized job
925
+ records per request at a flat USD price.
926
+
927
+ Price: $0.001 per request.
928
+
929
+ Example:
930
+ res = client.linkedin.jobs(limit=3, location="San Francisco", query="software engineer")
931
+ """
932
+ raw = await self._client._arun_raw( # pyright: ignore[reportPrivateUsage]
933
+ "linkedin.jobs", dict(input), options
934
+ )
935
+ return RunResult[LinkedinJobsData].model_validate(raw)
936
+
937
+ async def post(
938
+ self,
939
+ *,
940
+ options: RequestOptions | None = None,
941
+ **input: Unpack[LinkedinPostInput],
942
+ ) -> RunResult[LinkedinPostData]:
943
+ """LinkedIn Post
944
+
945
+ Fetch a single LinkedIn post or article by URL (title, text, author, like
946
+ and comment counts, publish date), normalized across providers.
947
+
948
+ Price: $0.001 per request.
949
+
950
+ Example:
951
+ res = client.linkedin.post(url="https://www.linkedin.com/posts/stripe_last-week-agent-traffic-surpassed-human-activity-7470882737390940160-2Nxs")
952
+ """
953
+ raw = await self._client._arun_raw( # pyright: ignore[reportPrivateUsage]
954
+ "linkedin.post", dict(input), options
955
+ )
956
+ return RunResult[LinkedinPostData].model_validate(raw)
957
+
958
+ async def post_transcript(
959
+ self,
960
+ *,
961
+ options: RequestOptions | None = None,
962
+ **input: Unpack[LinkedinPostTranscriptInput],
963
+ ) -> RunResult[LinkedinPostTranscriptData]:
964
+ """LinkedIn Post Transcript
965
+
966
+ Get the spoken transcript of a LinkedIn video post by URL, with transparent
967
+ per-request USD pricing.
968
+
969
+ Price: $0.002 per request.
970
+
971
+ Example:
972
+ res = client.linkedin.post_transcript(url="https://www.linkedin.com/posts/artificial-analysis_gemini-35-flash-is-a-step-forward-for-google-activity-7465082408409870337-4Pm-")
973
+ """
974
+ raw = await self._client._arun_raw( # pyright: ignore[reportPrivateUsage]
975
+ "linkedin.post_transcript", dict(input), options
976
+ )
977
+ return RunResult[LinkedinPostTranscriptData].model_validate(raw)
978
+
979
+ async def profile(
980
+ self,
981
+ *,
982
+ options: RequestOptions | None = None,
983
+ **input: Unpack[LinkedinProfileInput],
984
+ ) -> RunResult[LinkedinProfileData]:
985
+ """LinkedIn Profile
986
+
987
+ Fetch a LinkedIn member's public profile by URL: name, location, followers,
988
+ about, plus experience, education, recent posts, and published articles.
989
+
990
+ Price: $0.002 per request.
991
+
992
+ Example:
993
+ res = client.linkedin.profile(url="https://www.linkedin.com/in/williamhgates")
994
+ """
995
+ raw = await self._client._arun_raw( # pyright: ignore[reportPrivateUsage]
996
+ "linkedin.profile", dict(input), options
997
+ )
998
+ return RunResult[LinkedinProfileData].model_validate(raw)
999
+
1000
+ async def search_companies(
1001
+ self,
1002
+ *,
1003
+ options: RequestOptions | None = None,
1004
+ **input: Unpack[LinkedinSearchCompaniesInput],
1005
+ ) -> RunResult[LinkedinSearchCompaniesData]:
1006
+ """LinkedIn Company Search
1007
+
1008
+ Search LinkedIn companies by keyword with optional location filtering,
1009
+ returning normalized company records with transparent per-request USD
1010
+ pricing.
1011
+
1012
+ Price: $0.001 per request plus $0.004 per result.
1013
+
1014
+ Example:
1015
+ res = client.linkedin.search_companies(limit=3, query="fintech")
1016
+ """
1017
+ raw = await self._client._arun_raw( # pyright: ignore[reportPrivateUsage]
1018
+ "linkedin.search_companies", dict(input), options
1019
+ )
1020
+ return RunResult[LinkedinSearchCompaniesData].model_validate(raw)
1021
+
1022
+ async def search_posts(
1023
+ self,
1024
+ *,
1025
+ options: RequestOptions | None = None,
1026
+ **input: Unpack[LinkedinSearchPostsInput],
1027
+ ) -> RunResult[LinkedinSearchPostsData]:
1028
+ """LinkedIn Post Search
1029
+
1030
+ Search public LinkedIn posts by keyword (text, link, publish date),
1031
+ normalized across providers with transparent failover.
1032
+
1033
+ Price: $0.002 per request.
1034
+
1035
+ Example:
1036
+ res = client.linkedin.search_posts(datePosted="last-week", query="hiring")
1037
+ """
1038
+ raw = await self._client._arun_raw( # pyright: ignore[reportPrivateUsage]
1039
+ "linkedin.search_posts", dict(input), options
1040
+ )
1041
+ return RunResult[LinkedinSearchPostsData].model_validate(raw)
1042
+
1043
+ async def search_profiles(
1044
+ self,
1045
+ *,
1046
+ options: RequestOptions | None = None,
1047
+ **input: Unpack[LinkedinSearchProfilesInput],
1048
+ ) -> RunResult[LinkedinSearchProfilesData]:
1049
+ """LinkedIn Profile Search
1050
+
1051
+ Search LinkedIn profiles by keyword with optional location and job-title
1052
+ filters. Each match returns a full profile record: name, headline, location,
1053
+ current position, work experience, and education, plus the profile URL,
1054
+ handle, and id. Flat USD price per request.
1055
+
1056
+ Price: $0.0325 per request.
1057
+
1058
+ Example:
1059
+ res = client.linkedin.search_profiles(limit=3, query="recruiter")
1060
+ """
1061
+ raw = await self._client._arun_raw( # pyright: ignore[reportPrivateUsage]
1062
+ "linkedin.search_profiles", dict(input), options
1063
+ )
1064
+ return RunResult[LinkedinSearchProfilesData].model_validate(raw)