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.
- getanyapi/__init__.py +76 -0
- getanyapi/_account.py +132 -0
- getanyapi/_async_client.py +215 -0
- getanyapi/_client.py +274 -0
- getanyapi/_errors.py +115 -0
- getanyapi/_pagination.py +295 -0
- getanyapi/_transport.py +239 -0
- getanyapi/platforms/__init__.py +89 -0
- getanyapi/platforms/ahrefs.py +384 -0
- getanyapi/platforms/airbnb.py +120 -0
- getanyapi/platforms/alibaba.py +95 -0
- getanyapi/platforms/amazon.py +442 -0
- getanyapi/platforms/appstore.py +95 -0
- getanyapi/platforms/bluesky.py +215 -0
- getanyapi/platforms/booking.py +128 -0
- getanyapi/platforms/coinmarketcap.py +113 -0
- getanyapi/platforms/congress.py +106 -0
- getanyapi/platforms/dexscreener.py +104 -0
- getanyapi/platforms/ebay.py +215 -0
- getanyapi/platforms/email.py +166 -0
- getanyapi/platforms/facebook.py +2324 -0
- getanyapi/platforms/fiverr.py +122 -0
- getanyapi/platforms/github.py +954 -0
- getanyapi/platforms/glassdoor.py +93 -0
- getanyapi/platforms/google.py +232 -0
- getanyapi/platforms/google_ads.py +380 -0
- getanyapi/platforms/google_finance.py +170 -0
- getanyapi/platforms/google_shopping.py +103 -0
- getanyapi/platforms/hackernews.py +276 -0
- getanyapi/platforms/indeed.py +114 -0
- getanyapi/platforms/instagram.py +1868 -0
- getanyapi/platforms/linkedin.py +1064 -0
- getanyapi/platforms/maps.py +412 -0
- getanyapi/platforms/pandaexpress.py +262 -0
- getanyapi/platforms/person.py +96 -0
- getanyapi/platforms/pinterest.py +96 -0
- getanyapi/platforms/playstore.py +99 -0
- getanyapi/platforms/polymarket.py +109 -0
- getanyapi/platforms/realtor.py +104 -0
- getanyapi/platforms/reddit.py +582 -0
- getanyapi/platforms/redfin.py +95 -0
- getanyapi/platforms/rednote.py +807 -0
- getanyapi/platforms/sec.py +118 -0
- getanyapi/platforms/semrush.py +358 -0
- getanyapi/platforms/snapchat.py +146 -0
- getanyapi/platforms/social.py +105 -0
- getanyapi/platforms/spotify.py +588 -0
- getanyapi/platforms/substack.py +142 -0
- getanyapi/platforms/threads.py +358 -0
- getanyapi/platforms/tiktok.py +1827 -0
- getanyapi/platforms/tiktok_shop.py +536 -0
- getanyapi/platforms/tripadvisor.py +180 -0
- getanyapi/platforms/trustpilot.py +114 -0
- getanyapi/platforms/truthsocial.py +226 -0
- getanyapi/platforms/twitter.py +798 -0
- getanyapi/platforms/upwork.py +119 -0
- getanyapi/platforms/walmart.py +93 -0
- getanyapi/platforms/web.py +264 -0
- getanyapi/platforms/whatsapp.py +91 -0
- getanyapi/platforms/yahoo_finance.py +95 -0
- getanyapi/platforms/yelp.py +141 -0
- getanyapi/platforms/youtube.py +1452 -0
- getanyapi/platforms/zillow.py +218 -0
- getanyapi/py.typed +0 -0
- getanyapi/types.py +170 -0
- getanyapi-0.1.0.dist-info/METADATA +155 -0
- getanyapi-0.1.0.dist-info/RECORD +68 -0
- getanyapi-0.1.0.dist-info/WHEEL +4 -0
|
@@ -0,0 +1,215 @@
|
|
|
1
|
+
# Generated - do not edit. Regenerate with: pnpm generate
|
|
2
|
+
"""Generated namespace module for the ebay platform."""
|
|
3
|
+
|
|
4
|
+
from __future__ import annotations
|
|
5
|
+
|
|
6
|
+
from typing import 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 EbaySearchInput(TypedDict, total=False):
|
|
19
|
+
"""Input for eBay Search."""
|
|
20
|
+
|
|
21
|
+
limit: NotRequired[int]
|
|
22
|
+
"""Maximum number of results to return (1 to 25, default 25). You are billed per result returned, so a lower limit costs less. Range: 1 to 25."""
|
|
23
|
+
maxPrice: NotRequired[int]
|
|
24
|
+
"""Optional maximum item price in USD. Minimum: 0."""
|
|
25
|
+
minPrice: NotRequired[int]
|
|
26
|
+
"""Optional minimum item price in USD. Minimum: 0."""
|
|
27
|
+
query: Required[str]
|
|
28
|
+
"""Search keywords, e.g. "nintendo switch" or "vintage levis 501"."""
|
|
29
|
+
|
|
30
|
+
|
|
31
|
+
class EbaySoldListingsInput(TypedDict, total=False):
|
|
32
|
+
"""Input for eBay Sold Listings."""
|
|
33
|
+
|
|
34
|
+
condition: NotRequired[Literal["any", "new", "used"]]
|
|
35
|
+
"""Item condition filter (e.g. used). Default: any."""
|
|
36
|
+
daysBack: NotRequired[int]
|
|
37
|
+
"""How many days back to include sold listings, 1-90 (e.g. 30). Default: 30."""
|
|
38
|
+
limit: NotRequired[int]
|
|
39
|
+
"""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."""
|
|
40
|
+
query: Required[str]
|
|
41
|
+
"""Search keyword for sold items (e.g. iphone 13 pro)."""
|
|
42
|
+
site: NotRequired[
|
|
43
|
+
Literal[
|
|
44
|
+
"ebay.com",
|
|
45
|
+
"ebay.co.uk",
|
|
46
|
+
"ebay.de",
|
|
47
|
+
"ebay.fr",
|
|
48
|
+
"ebay.it",
|
|
49
|
+
"ebay.es",
|
|
50
|
+
"ebay.ca",
|
|
51
|
+
"ebay.com.au",
|
|
52
|
+
]
|
|
53
|
+
]
|
|
54
|
+
"""eBay country site to search (e.g. ebay.co.uk). Default: ebay.com."""
|
|
55
|
+
|
|
56
|
+
|
|
57
|
+
class EbaySearchData(BaseModel):
|
|
58
|
+
items: list[EbaySearchItem] = Field(
|
|
59
|
+
description="Listing records: title, price, condition, shipping cost, seller info, image, and item URL."
|
|
60
|
+
)
|
|
61
|
+
|
|
62
|
+
|
|
63
|
+
class EbaySearchItem(BaseModel):
|
|
64
|
+
model_config = ConfigDict(extra="allow", populate_by_name=True)
|
|
65
|
+
|
|
66
|
+
condition: str | None = None
|
|
67
|
+
image: str | None = Field(
|
|
68
|
+
default=None,
|
|
69
|
+
description="Primary listing image URL. Present whenever the upstream returns this record.",
|
|
70
|
+
)
|
|
71
|
+
item_id: str = Field(alias="itemId", description="eBay item identifier.")
|
|
72
|
+
listing_type: str | None = Field(
|
|
73
|
+
default=None, alias="listingType", description="Auction, FixedPrice, etc."
|
|
74
|
+
)
|
|
75
|
+
price: float | None = Field(default=None, description="Listing price.")
|
|
76
|
+
seller_feedback_percent: float | None = Field(
|
|
77
|
+
default=None,
|
|
78
|
+
alias="sellerFeedbackPercent",
|
|
79
|
+
description="Seller positive-feedback percentage.",
|
|
80
|
+
)
|
|
81
|
+
seller_name: str | None = Field(default=None, alias="sellerName")
|
|
82
|
+
shipping_cost: str | None = Field(
|
|
83
|
+
default=None,
|
|
84
|
+
alias="shippingCost",
|
|
85
|
+
description="Shipping cost or free-delivery label.",
|
|
86
|
+
)
|
|
87
|
+
title: str
|
|
88
|
+
url: str
|
|
89
|
+
|
|
90
|
+
|
|
91
|
+
class EbaySoldListingsData(BaseModel):
|
|
92
|
+
items: list[EbaySoldListingsItem] = Field(
|
|
93
|
+
description="Sold listing records: title, sold price, sale date, condition, shipping, and item URL."
|
|
94
|
+
)
|
|
95
|
+
|
|
96
|
+
|
|
97
|
+
class EbaySoldListingsItem(BaseModel):
|
|
98
|
+
model_config = ConfigDict(extra="allow", populate_by_name=True)
|
|
99
|
+
|
|
100
|
+
condition: str | None = None
|
|
101
|
+
ended_at: str | None = Field(
|
|
102
|
+
default=None, alias="endedAt", description="Sale date (ISO 8601)."
|
|
103
|
+
)
|
|
104
|
+
image: str | None = Field(
|
|
105
|
+
default=None,
|
|
106
|
+
description="Primary listing image URL. Present whenever the upstream returns this record.",
|
|
107
|
+
)
|
|
108
|
+
item_id: str = Field(alias="itemId", description="eBay item identifier.")
|
|
109
|
+
listing_type: str | None = Field(default=None, alias="listingType")
|
|
110
|
+
seller_username: str | None = Field(default=None, alias="sellerUsername")
|
|
111
|
+
sold_currency: str | None = Field(default=None, alias="soldCurrency")
|
|
112
|
+
sold_price: float | None = Field(
|
|
113
|
+
default=None, alias="soldPrice", description="Final sold price."
|
|
114
|
+
)
|
|
115
|
+
title: str
|
|
116
|
+
total_price: float | None = Field(
|
|
117
|
+
default=None, alias="totalPrice", description="Sold price plus shipping."
|
|
118
|
+
)
|
|
119
|
+
url: str
|
|
120
|
+
|
|
121
|
+
|
|
122
|
+
class EbayNamespace:
|
|
123
|
+
"""Typed methods for this platform. Attached lazily to the client."""
|
|
124
|
+
|
|
125
|
+
def __init__(self, client: "AnyAPI") -> None:
|
|
126
|
+
self._client = client
|
|
127
|
+
|
|
128
|
+
def search(
|
|
129
|
+
self, *, options: RequestOptions | None = None, **input: Unpack[EbaySearchInput]
|
|
130
|
+
) -> RunResult[EbaySearchData]:
|
|
131
|
+
"""eBay Search
|
|
132
|
+
|
|
133
|
+
Search eBay active listings by keyword and get title, price, condition,
|
|
134
|
+
shipping, seller, and sold count in one normalized response. You are billed
|
|
135
|
+
per result returned.
|
|
136
|
+
|
|
137
|
+
Price: $0.001 per request plus $0.00234 per result.
|
|
138
|
+
|
|
139
|
+
Example:
|
|
140
|
+
res = client.ebay.search(limit=3, query="nintendo switch")
|
|
141
|
+
"""
|
|
142
|
+
raw = self._client._run_raw( # pyright: ignore[reportPrivateUsage]
|
|
143
|
+
"ebay.search", dict(input), options
|
|
144
|
+
)
|
|
145
|
+
return RunResult[EbaySearchData].model_validate(raw)
|
|
146
|
+
|
|
147
|
+
def sold_listings(
|
|
148
|
+
self,
|
|
149
|
+
*,
|
|
150
|
+
options: RequestOptions | None = None,
|
|
151
|
+
**input: Unpack[EbaySoldListingsInput],
|
|
152
|
+
) -> RunResult[EbaySoldListingsData]:
|
|
153
|
+
"""eBay Sold Listings
|
|
154
|
+
|
|
155
|
+
Retrieve recently sold eBay listings for any keyword - sold price, sale
|
|
156
|
+
date, condition, and item details - ideal for pricing research, at a flat
|
|
157
|
+
per-request USD price.
|
|
158
|
+
|
|
159
|
+
Price: $0.00005 per request plus $0.004 per result.
|
|
160
|
+
|
|
161
|
+
Example:
|
|
162
|
+
res = client.ebay.sold_listings(limit=3, query="nintendo switch")
|
|
163
|
+
"""
|
|
164
|
+
raw = self._client._run_raw( # pyright: ignore[reportPrivateUsage]
|
|
165
|
+
"ebay.sold_listings", dict(input), options
|
|
166
|
+
)
|
|
167
|
+
return RunResult[EbaySoldListingsData].model_validate(raw)
|
|
168
|
+
|
|
169
|
+
|
|
170
|
+
class AsyncEbayNamespace:
|
|
171
|
+
"""Typed methods for this platform. Attached lazily to the client."""
|
|
172
|
+
|
|
173
|
+
def __init__(self, client: "AsyncAnyAPI") -> None:
|
|
174
|
+
self._client = client
|
|
175
|
+
|
|
176
|
+
async def search(
|
|
177
|
+
self, *, options: RequestOptions | None = None, **input: Unpack[EbaySearchInput]
|
|
178
|
+
) -> RunResult[EbaySearchData]:
|
|
179
|
+
"""eBay Search
|
|
180
|
+
|
|
181
|
+
Search eBay active listings by keyword and get title, price, condition,
|
|
182
|
+
shipping, seller, and sold count in one normalized response. You are billed
|
|
183
|
+
per result returned.
|
|
184
|
+
|
|
185
|
+
Price: $0.001 per request plus $0.00234 per result.
|
|
186
|
+
|
|
187
|
+
Example:
|
|
188
|
+
res = client.ebay.search(limit=3, query="nintendo switch")
|
|
189
|
+
"""
|
|
190
|
+
raw = await self._client._arun_raw( # pyright: ignore[reportPrivateUsage]
|
|
191
|
+
"ebay.search", dict(input), options
|
|
192
|
+
)
|
|
193
|
+
return RunResult[EbaySearchData].model_validate(raw)
|
|
194
|
+
|
|
195
|
+
async def sold_listings(
|
|
196
|
+
self,
|
|
197
|
+
*,
|
|
198
|
+
options: RequestOptions | None = None,
|
|
199
|
+
**input: Unpack[EbaySoldListingsInput],
|
|
200
|
+
) -> RunResult[EbaySoldListingsData]:
|
|
201
|
+
"""eBay Sold Listings
|
|
202
|
+
|
|
203
|
+
Retrieve recently sold eBay listings for any keyword - sold price, sale
|
|
204
|
+
date, condition, and item details - ideal for pricing research, at a flat
|
|
205
|
+
per-request USD price.
|
|
206
|
+
|
|
207
|
+
Price: $0.00005 per request plus $0.004 per result.
|
|
208
|
+
|
|
209
|
+
Example:
|
|
210
|
+
res = client.ebay.sold_listings(limit=3, query="nintendo switch")
|
|
211
|
+
"""
|
|
212
|
+
raw = await self._client._arun_raw( # pyright: ignore[reportPrivateUsage]
|
|
213
|
+
"ebay.sold_listings", dict(input), options
|
|
214
|
+
)
|
|
215
|
+
return RunResult[EbaySoldListingsData].model_validate(raw)
|
|
@@ -0,0 +1,166 @@
|
|
|
1
|
+
# Generated - do not edit. Regenerate with: pnpm generate
|
|
2
|
+
"""Generated namespace module for the email platform."""
|
|
3
|
+
|
|
4
|
+
from __future__ import annotations
|
|
5
|
+
|
|
6
|
+
from typing import Any, 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 EmailFindInput(TypedDict, total=False):
|
|
19
|
+
"""Input for Email Finder."""
|
|
20
|
+
|
|
21
|
+
person: NotRequired[dict[str, Any]]
|
|
22
|
+
"""The person to find an email for, e.g. {"firstName": "Jane", "surname": "Doe", "domain": "acme.com"} (domain also accepts a company name)."""
|
|
23
|
+
|
|
24
|
+
|
|
25
|
+
class EmailVerifyInput(TypedDict, total=False):
|
|
26
|
+
"""Input for Email Verifier."""
|
|
27
|
+
|
|
28
|
+
email: Required[str]
|
|
29
|
+
"""The email address to verify (e.g. jane.doe@acme.com)."""
|
|
30
|
+
|
|
31
|
+
|
|
32
|
+
class EmailFindData(BaseModel):
|
|
33
|
+
items: list[EmailFindItem] = Field(
|
|
34
|
+
description="Email lookup records: the discovered email address, verification status, and the matched person and company details."
|
|
35
|
+
)
|
|
36
|
+
|
|
37
|
+
|
|
38
|
+
class EmailFindItem(BaseModel):
|
|
39
|
+
model_config = ConfigDict(extra="allow", populate_by_name=True)
|
|
40
|
+
|
|
41
|
+
domain: str | None = None
|
|
42
|
+
email: str = Field(
|
|
43
|
+
description="Discovered email address, or empty when none was found."
|
|
44
|
+
)
|
|
45
|
+
first_name: str | None = Field(default=None, alias="firstName")
|
|
46
|
+
is_deliverable: bool | None = Field(default=None, alias="isDeliverable")
|
|
47
|
+
last_name: str | None = Field(default=None, alias="lastName")
|
|
48
|
+
status: str = Field(description="Lookup status (e.g. found, not_found).")
|
|
49
|
+
|
|
50
|
+
|
|
51
|
+
class EmailVerifyData(BaseModel):
|
|
52
|
+
items: list[EmailVerifyItem] = Field(
|
|
53
|
+
description="Verification records: the email address with its deliverability verdict and syntax, domain, and mailbox check details."
|
|
54
|
+
)
|
|
55
|
+
|
|
56
|
+
|
|
57
|
+
class EmailVerifyItem(BaseModel):
|
|
58
|
+
model_config = ConfigDict(extra="allow", populate_by_name=True)
|
|
59
|
+
|
|
60
|
+
catch_all: bool | None = Field(
|
|
61
|
+
default=None, alias="catchAll", description="Domain accepts all addresses."
|
|
62
|
+
)
|
|
63
|
+
disposable: bool | None = None
|
|
64
|
+
domain: str | None = None
|
|
65
|
+
email: str
|
|
66
|
+
free: bool | None = Field(default=None, description="Free email provider.")
|
|
67
|
+
reason: str | None = None
|
|
68
|
+
role: bool | None = Field(
|
|
69
|
+
default=None, description="Role-based address (e.g. info@)."
|
|
70
|
+
)
|
|
71
|
+
score: int | None = Field(default=None, description="Confidence score (0-100).")
|
|
72
|
+
status: str = Field(
|
|
73
|
+
description="Deliverability verdict (e.g. valid, risky, invalid)."
|
|
74
|
+
)
|
|
75
|
+
|
|
76
|
+
|
|
77
|
+
class EmailNamespace:
|
|
78
|
+
"""Typed methods for this platform. Attached lazily to the client."""
|
|
79
|
+
|
|
80
|
+
def __init__(self, client: "AnyAPI") -> None:
|
|
81
|
+
self._client = client
|
|
82
|
+
|
|
83
|
+
def find(
|
|
84
|
+
self, *, options: RequestOptions | None = None, **input: Unpack[EmailFindInput]
|
|
85
|
+
) -> RunResult[EmailFindData]:
|
|
86
|
+
"""Email Finder
|
|
87
|
+
|
|
88
|
+
Find a person's work email address from their name and company domain, with
|
|
89
|
+
transparent per-request USD pricing.
|
|
90
|
+
|
|
91
|
+
Price: $0.005 per request plus $0.008 per result.
|
|
92
|
+
|
|
93
|
+
Example:
|
|
94
|
+
res = client.email.find(person={"domain": "stripe.com", "firstName": "Patrick", "surname": "Collison"})
|
|
95
|
+
"""
|
|
96
|
+
raw = self._client._run_raw( # pyright: ignore[reportPrivateUsage]
|
|
97
|
+
"email.find", dict(input), options
|
|
98
|
+
)
|
|
99
|
+
return RunResult[EmailFindData].model_validate(raw)
|
|
100
|
+
|
|
101
|
+
def verify(
|
|
102
|
+
self,
|
|
103
|
+
*,
|
|
104
|
+
options: RequestOptions | None = None,
|
|
105
|
+
**input: Unpack[EmailVerifyInput],
|
|
106
|
+
) -> RunResult[EmailVerifyData]:
|
|
107
|
+
"""Email Verifier
|
|
108
|
+
|
|
109
|
+
Verify any email address for deliverability - syntax, domain, and mailbox
|
|
110
|
+
checks in one normalized response, priced per request in USD.
|
|
111
|
+
|
|
112
|
+
Price: $0.0008 per result.
|
|
113
|
+
|
|
114
|
+
Example:
|
|
115
|
+
res = client.email.verify(email="patrick@stripe.com")
|
|
116
|
+
"""
|
|
117
|
+
raw = self._client._run_raw( # pyright: ignore[reportPrivateUsage]
|
|
118
|
+
"email.verify", dict(input), options
|
|
119
|
+
)
|
|
120
|
+
return RunResult[EmailVerifyData].model_validate(raw)
|
|
121
|
+
|
|
122
|
+
|
|
123
|
+
class AsyncEmailNamespace:
|
|
124
|
+
"""Typed methods for this platform. Attached lazily to the client."""
|
|
125
|
+
|
|
126
|
+
def __init__(self, client: "AsyncAnyAPI") -> None:
|
|
127
|
+
self._client = client
|
|
128
|
+
|
|
129
|
+
async def find(
|
|
130
|
+
self, *, options: RequestOptions | None = None, **input: Unpack[EmailFindInput]
|
|
131
|
+
) -> RunResult[EmailFindData]:
|
|
132
|
+
"""Email Finder
|
|
133
|
+
|
|
134
|
+
Find a person's work email address from their name and company domain, with
|
|
135
|
+
transparent per-request USD pricing.
|
|
136
|
+
|
|
137
|
+
Price: $0.005 per request plus $0.008 per result.
|
|
138
|
+
|
|
139
|
+
Example:
|
|
140
|
+
res = client.email.find(person={"domain": "stripe.com", "firstName": "Patrick", "surname": "Collison"})
|
|
141
|
+
"""
|
|
142
|
+
raw = await self._client._arun_raw( # pyright: ignore[reportPrivateUsage]
|
|
143
|
+
"email.find", dict(input), options
|
|
144
|
+
)
|
|
145
|
+
return RunResult[EmailFindData].model_validate(raw)
|
|
146
|
+
|
|
147
|
+
async def verify(
|
|
148
|
+
self,
|
|
149
|
+
*,
|
|
150
|
+
options: RequestOptions | None = None,
|
|
151
|
+
**input: Unpack[EmailVerifyInput],
|
|
152
|
+
) -> RunResult[EmailVerifyData]:
|
|
153
|
+
"""Email Verifier
|
|
154
|
+
|
|
155
|
+
Verify any email address for deliverability - syntax, domain, and mailbox
|
|
156
|
+
checks in one normalized response, priced per request in USD.
|
|
157
|
+
|
|
158
|
+
Price: $0.0008 per result.
|
|
159
|
+
|
|
160
|
+
Example:
|
|
161
|
+
res = client.email.verify(email="patrick@stripe.com")
|
|
162
|
+
"""
|
|
163
|
+
raw = await self._client._arun_raw( # pyright: ignore[reportPrivateUsage]
|
|
164
|
+
"email.verify", dict(input), options
|
|
165
|
+
)
|
|
166
|
+
return RunResult[EmailVerifyData].model_validate(raw)
|