@getanyapi/sdk 0.50.0 → 0.51.1
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.cjs +101 -15
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +697 -34
- package/dist/index.d.ts +697 -34
- package/dist/index.js +100 -15
- package/dist/index.js.map +1 -1
- package/package.json +1 -1
package/dist/index.cjs
CHANGED
|
@@ -87,6 +87,7 @@ __export(index_exports, {
|
|
|
87
87
|
SecNamespace: () => SecNamespace,
|
|
88
88
|
SemrushNamespace: () => SemrushNamespace,
|
|
89
89
|
SeoNamespace: () => SeoNamespace,
|
|
90
|
+
SimilarwebNamespace: () => SimilarwebNamespace,
|
|
90
91
|
SnapchatNamespace: () => SnapchatNamespace,
|
|
91
92
|
SocialNamespace: () => SocialNamespace,
|
|
92
93
|
SpotifyNamespace: () => SpotifyNamespace,
|
|
@@ -1211,6 +1212,19 @@ var AhrefsNamespace = class {
|
|
|
1211
1212
|
overview(input, options) {
|
|
1212
1213
|
return this._core.run("ahrefs.overview", input, options);
|
|
1213
1214
|
}
|
|
1215
|
+
/**
|
|
1216
|
+
* Ahrefs Traffic Overview
|
|
1217
|
+
*
|
|
1218
|
+
* Get the Ahrefs organic traffic overview for any domain or URL: monthly traffic estimate and value, the top keywords it already ranks for with position and traffic, top pages, traffic by country, and a monthly traffic history - as normalized JSON.
|
|
1219
|
+
*
|
|
1220
|
+
* Price: $0.00006 per request plus $0.00495 per result (maximum $0.00501).
|
|
1221
|
+
*
|
|
1222
|
+
* @example
|
|
1223
|
+
* const res = await client.ahrefs.traffic({ url: "ahrefs.com", mode: "subdomains" });
|
|
1224
|
+
*/
|
|
1225
|
+
traffic(input, options) {
|
|
1226
|
+
return this._core.run("ahrefs.traffic", input, options);
|
|
1227
|
+
}
|
|
1214
1228
|
};
|
|
1215
1229
|
|
|
1216
1230
|
// src/generated/platforms/airbnb.ts
|
|
@@ -1977,7 +1991,7 @@ var EbayNamespace = class {
|
|
|
1977
1991
|
*
|
|
1978
1992
|
* Search eBay active listings by keyword with optional price-range, item-condition, listing-type, and sort filters and get title, price, condition, shipping, and seller in one normalized response.
|
|
1979
1993
|
*
|
|
1980
|
-
* Price: $0.
|
|
1994
|
+
* Price: $0.00225 per request.
|
|
1981
1995
|
*
|
|
1982
1996
|
* @example
|
|
1983
1997
|
* const res = await client.ebay.search({ query: "nintendo switch", limit: 3, sort: "price_low" });
|
|
@@ -1990,7 +2004,7 @@ var EbayNamespace = class {
|
|
|
1990
2004
|
*
|
|
1991
2005
|
* Retrieve recently sold eBay listings for any keyword with optional price-range, condition, and sort filters (sold price, sale date, condition, seller, item details); ideal for pricing research.
|
|
1992
2006
|
*
|
|
1993
|
-
* Price: $0.
|
|
2007
|
+
* Price: $0.0135 per request.
|
|
1994
2008
|
*
|
|
1995
2009
|
* @example
|
|
1996
2010
|
* const res = await client.ebay.soldListings({ query: "iphone 13 pro", limit: 10, sort: "ended_recently" });
|
|
@@ -1998,6 +2012,19 @@ var EbayNamespace = class {
|
|
|
1998
2012
|
soldListings(input, options) {
|
|
1999
2013
|
return this._core.run("ebay.sold_listings", input, options);
|
|
2000
2014
|
}
|
|
2015
|
+
/**
|
|
2016
|
+
* eBay Sold Listings (Basic)
|
|
2017
|
+
*
|
|
2018
|
+
* Retrieve recently sold eBay listings for any keyword with the sold price, sale date, condition, format, bids, and whether a Best Offer was accepted, without seller details; the lighter sibling of eBay Sold Listings for price comps.
|
|
2019
|
+
*
|
|
2020
|
+
* Price: $0.0135 per request.
|
|
2021
|
+
*
|
|
2022
|
+
* @example
|
|
2023
|
+
* const res = await client.ebay.soldListingsThin({ query: "iphone 13 pro", limit: 10, sort: "ended_recently" });
|
|
2024
|
+
*/
|
|
2025
|
+
soldListingsThin(input, options) {
|
|
2026
|
+
return this._core.run("ebay.sold_listings_thin", input, options);
|
|
2027
|
+
}
|
|
2001
2028
|
};
|
|
2002
2029
|
|
|
2003
2030
|
// src/generated/platforms/email.ts
|
|
@@ -2695,6 +2722,22 @@ var FacebookNamespace = class {
|
|
|
2695
2722
|
profileReels(input, options) {
|
|
2696
2723
|
return this._core.run("facebook.profile_reels", input, options);
|
|
2697
2724
|
}
|
|
2725
|
+
/**
|
|
2726
|
+
* Iterate every result of Facebook Profile Reels across pages.
|
|
2727
|
+
*
|
|
2728
|
+
* Yields items directly; call `.pages()` on the return value to walk whole
|
|
2729
|
+
* result pages instead (each carries its own costUsd).
|
|
2730
|
+
*/
|
|
2731
|
+
iterProfileReels(input, options) {
|
|
2732
|
+
return paginate(
|
|
2733
|
+
this._core,
|
|
2734
|
+
"facebook.profile_reels",
|
|
2735
|
+
input,
|
|
2736
|
+
"reels",
|
|
2737
|
+
false,
|
|
2738
|
+
options
|
|
2739
|
+
);
|
|
2740
|
+
}
|
|
2698
2741
|
/**
|
|
2699
2742
|
* Facebook Company Search
|
|
2700
2743
|
*
|
|
@@ -2726,7 +2769,7 @@ var FacebookNamespace = class {
|
|
|
2726
2769
|
*
|
|
2727
2770
|
* Search public Facebook posts by keyword, optionally filtered by location, and get structured post records (text, author, engagement).
|
|
2728
2771
|
*
|
|
2729
|
-
* Price: $0
|
|
2772
|
+
* Price: $0 per request plus $0.00135 per result (maximum $0.027).
|
|
2730
2773
|
*
|
|
2731
2774
|
* @example
|
|
2732
2775
|
* const res = await client.facebook.searchPosts({ query: "nike", limit: 3 });
|
|
@@ -3049,7 +3092,7 @@ var GoogleNamespace = class {
|
|
|
3049
3092
|
*
|
|
3050
3093
|
* Ask Google AI Mode a prompt and receive the cited answer it generates. AI Mode composes the answer at search time, so repeat calls on one prompt can differ in wording and in which sources are cited.
|
|
3051
3094
|
*
|
|
3052
|
-
* Price: $0.
|
|
3095
|
+
* Price: $0.00006 per request plus $0.0033 per result (maximum $0.00336).
|
|
3053
3096
|
*
|
|
3054
3097
|
* @example
|
|
3055
3098
|
* const res = await client.google.aiMode({ prompt: "What is AnyAPI at getanyapi.com, and what does it offer?" });
|
|
@@ -3151,9 +3194,9 @@ var GoogleNamespace = class {
|
|
|
3151
3194
|
/**
|
|
3152
3195
|
* Google Search
|
|
3153
3196
|
*
|
|
3154
|
-
* Run a Google web search and get the organic results (title, link, snippet, position) as clean JSON. Returns about 10 results per call - Google stopped honoring bulk result counts in September 2025, so a limit above 10 is accepted but returns no more than a page.
|
|
3197
|
+
* Run a Google web search and get the organic results (title, link, snippet, position) as clean JSON. Returns about 10 results per call - Google stopped honoring bulk result counts in September 2025, so a limit above 10 is accepted but returns no more than a page. Send page 2, 3, ... to walk further, or use google.search_100 for up to 100 ranked results in one call, which is cheaper past roughly 20 results.
|
|
3155
3198
|
*
|
|
3156
|
-
* Price: $0.
|
|
3199
|
+
* Price: $0.0004 per request.
|
|
3157
3200
|
*
|
|
3158
3201
|
* @example
|
|
3159
3202
|
* const res = await client.google.search({ query: "best coffee maker", gl: "us", hl: "en", limit: 10 });
|
|
@@ -3444,7 +3487,7 @@ var InstagramNamespace = class {
|
|
|
3444
3487
|
*
|
|
3445
3488
|
* Fetch an Instagram account's core public profile fields (followers, posts, bio, verification) by user id.
|
|
3446
3489
|
*
|
|
3447
|
-
* Price: $0.
|
|
3490
|
+
* Price: $0.001 per request.
|
|
3448
3491
|
*
|
|
3449
3492
|
* @example
|
|
3450
3493
|
* const res = await client.instagram.basicProfile({ userId: "314216" });
|
|
@@ -3738,7 +3781,7 @@ var InstagramNamespace = class {
|
|
|
3738
3781
|
*
|
|
3739
3782
|
* Fetch an Instagram account's public profile (followers, posts, bio, verification) by handle.
|
|
3740
3783
|
*
|
|
3741
|
-
* Price: $0.
|
|
3784
|
+
* Price: $0.001 per request.
|
|
3742
3785
|
*
|
|
3743
3786
|
* @example
|
|
3744
3787
|
* const res = await client.instagram.profile({ handle: "nasa" });
|
|
@@ -3890,7 +3933,7 @@ var InstagramNamespace = class {
|
|
|
3890
3933
|
*
|
|
3891
3934
|
* List the accounts Instagram recommends as similar to a public profile, with each account's handle, display name, verified flag and avatar.
|
|
3892
3935
|
*
|
|
3893
|
-
* Price: $0.
|
|
3936
|
+
* Price: $0.00175 per request.
|
|
3894
3937
|
*
|
|
3895
3938
|
* @example
|
|
3896
3939
|
* const res = await client.instagram.similarProfiles({ handle: "nasa" });
|
|
@@ -4425,7 +4468,7 @@ var LinkedinNamespace = class {
|
|
|
4425
4468
|
*
|
|
4426
4469
|
* Search public LinkedIn posts by keyword (text, link, publish date).
|
|
4427
4470
|
*
|
|
4428
|
-
* Price: $0.
|
|
4471
|
+
* Price: $0.0012 per request.
|
|
4429
4472
|
*
|
|
4430
4473
|
* @example
|
|
4431
4474
|
* const res = await client.linkedin.searchPosts({ query: "hiring", datePosted: "last-week" });
|
|
@@ -4530,7 +4573,7 @@ var MapsNamespace = class {
|
|
|
4530
4573
|
*
|
|
4531
4574
|
* Search Google Maps for businesses and enrich each result with contact details (emails, phones, and social profiles from their websites), up to 20 records per request.
|
|
4532
4575
|
*
|
|
4533
|
-
* Price: $0.
|
|
4576
|
+
* Price: $0.0045 per request.
|
|
4534
4577
|
*
|
|
4535
4578
|
* @example
|
|
4536
4579
|
* const res = await client.maps.contacts({ location: "Austin, TX", query: "coffee shop", limit: 3, placeMinimumStars: "four", website: "withWebsite" });
|
|
@@ -4852,7 +4895,7 @@ var PerplexityNamespace = class {
|
|
|
4852
4895
|
*
|
|
4853
4896
|
* Ask Perplexity a web-grounded question and receive an answer with source citations.
|
|
4854
4897
|
*
|
|
4855
|
-
* Price: $0.
|
|
4898
|
+
* Price: $0.00006 per request plus $0.011 per result (maximum $0.0111).
|
|
4856
4899
|
*
|
|
4857
4900
|
* @example
|
|
4858
4901
|
* const res = await client.perplexity.search({ prompt: "What is AnyAPI at getanyapi.com, and what does it offer?" });
|
|
@@ -5199,7 +5242,7 @@ var RedditNamespace = class {
|
|
|
5199
5242
|
*
|
|
5200
5243
|
* Fetch a Reddit user's public profile (karma split, post and comment counts, bio, avatar, account age) by username.
|
|
5201
5244
|
*
|
|
5202
|
-
* Price: $0.
|
|
5245
|
+
* Price: $0.0012 per request.
|
|
5203
5246
|
*
|
|
5204
5247
|
* @example
|
|
5205
5248
|
* const res = await client.reddit.profile({ username: "spez" });
|
|
@@ -5812,6 +5855,40 @@ var SeoNamespace = class {
|
|
|
5812
5855
|
}
|
|
5813
5856
|
};
|
|
5814
5857
|
|
|
5858
|
+
// src/generated/platforms/similarweb.ts
|
|
5859
|
+
var SimilarwebNamespace = class {
|
|
5860
|
+
constructor(_core) {
|
|
5861
|
+
this._core = _core;
|
|
5862
|
+
}
|
|
5863
|
+
_core;
|
|
5864
|
+
/**
|
|
5865
|
+
* Similarweb Website Traffic
|
|
5866
|
+
*
|
|
5867
|
+
* Get the Similarweb traffic overview for any website: estimated monthly visits and a three-month history, global, country, and category rank, bounce rate, pages per visit, visit duration, traffic sources including AI chatbots, top countries, and top search keywords - as normalized JSON.
|
|
5868
|
+
*
|
|
5869
|
+
* Price: $0.00002 per request plus $0.00165 per result (maximum $0.00167).
|
|
5870
|
+
*
|
|
5871
|
+
* @example
|
|
5872
|
+
* const res = await client.similarweb.overview({ domain: "stripe.com" });
|
|
5873
|
+
*/
|
|
5874
|
+
overview(input, options) {
|
|
5875
|
+
return this._core.run("similarweb.overview", input, options);
|
|
5876
|
+
}
|
|
5877
|
+
/**
|
|
5878
|
+
* Similarweb Similar Sites
|
|
5879
|
+
*
|
|
5880
|
+
* Find the websites Similarweb ranks as most similar to any website: up to 20 competitor and alternative sites in similarity order, each with its similarity score, category, top-country rank, estimated monthly visits, and description - as normalized JSON.
|
|
5881
|
+
*
|
|
5882
|
+
* Price: $0.00002 per request plus $0.00165 per result (maximum $0.00167).
|
|
5883
|
+
*
|
|
5884
|
+
* @example
|
|
5885
|
+
* const res = await client.similarweb.similarSites({ domain: "stripe.com" });
|
|
5886
|
+
*/
|
|
5887
|
+
similarSites(input, options) {
|
|
5888
|
+
return this._core.run("similarweb.similar_sites", input, options);
|
|
5889
|
+
}
|
|
5890
|
+
};
|
|
5891
|
+
|
|
5815
5892
|
// src/generated/platforms/snapchat.ts
|
|
5816
5893
|
var SnapchatNamespace = class {
|
|
5817
5894
|
constructor(_core) {
|
|
@@ -6108,7 +6185,7 @@ var TiktokNamespace = class {
|
|
|
6108
6185
|
*
|
|
6109
6186
|
* Search TikTok's public Ads Library by keyword or advertiser (advertiser, title, audience band, run dates, library link, and video).
|
|
6110
6187
|
*
|
|
6111
|
-
* Price: $0.
|
|
6188
|
+
* Price: $0.0012 per request.
|
|
6112
6189
|
*
|
|
6113
6190
|
* @example
|
|
6114
6191
|
* const res = await client.tiktok.adLibrarySearch({ query: "spotify" });
|
|
@@ -8018,7 +8095,7 @@ var YoutubeNamespace = class {
|
|
|
8018
8095
|
*
|
|
8019
8096
|
* Fetch the transcript/captions of a YouTube video or Short by URL or ID.
|
|
8020
8097
|
*
|
|
8021
|
-
* Price: $0.
|
|
8098
|
+
* Price: $0.0009 per request.
|
|
8022
8099
|
*
|
|
8023
8100
|
* @example
|
|
8024
8101
|
* const res = await client.youtube.videoTranscript({ url: "https://www.youtube.com/watch?v=dQw4w9WgXcQ" });
|
|
@@ -8590,6 +8667,14 @@ var AnyAPI2 = class extends AnyAPI {
|
|
|
8590
8667
|
this._core
|
|
8591
8668
|
);
|
|
8592
8669
|
}
|
|
8670
|
+
/**
|
|
8671
|
+
* Typed methods for the similarweb platform.
|
|
8672
|
+
*/
|
|
8673
|
+
get similarweb() {
|
|
8674
|
+
return this._namespaces["similarweb"] ??= new SimilarwebNamespace(
|
|
8675
|
+
this._core
|
|
8676
|
+
);
|
|
8677
|
+
}
|
|
8593
8678
|
/**
|
|
8594
8679
|
* Typed methods for the snapchat platform.
|
|
8595
8680
|
*/
|
|
@@ -8828,6 +8913,7 @@ var AnyAPI2 = class extends AnyAPI {
|
|
|
8828
8913
|
SecNamespace,
|
|
8829
8914
|
SemrushNamespace,
|
|
8830
8915
|
SeoNamespace,
|
|
8916
|
+
SimilarwebNamespace,
|
|
8831
8917
|
SnapchatNamespace,
|
|
8832
8918
|
SocialNamespace,
|
|
8833
8919
|
SpotifyNamespace,
|