scavio 0.10.0 → 0.12.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/README.md +34 -5
- package/dist/index.cjs +22 -5
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +66 -47
- package/dist/index.d.ts +66 -47
- package/dist/index.js +22 -5
- package/dist/index.js.map +1 -1
- package/package.json +1 -1
package/dist/index.d.cts
CHANGED
|
@@ -1,49 +1,45 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Amazon moved to a new upstream in 2026-07 and the API now returns a
|
|
3
|
+
* normalized shape instead of the old raw provider payload. Nine options went
|
|
4
|
+
* with the old provider: language, currency, device, sort_by, pages,
|
|
5
|
+
* category_id, merchant_id, zip_code and autoselect_variant. They are removed
|
|
6
|
+
* rather than kept as no-ops - notably `sort_by`, which the marketplace was
|
|
7
|
+
* verified to ignore entirely (every sort value returned the same unordered
|
|
8
|
+
* set). Sending a retired option anyway still returns 200, with a top-level
|
|
9
|
+
* `warnings` array naming what was ignored.
|
|
10
|
+
*
|
|
11
|
+
* `country` is the canonical marketplace selector; `domain` and `start_page`
|
|
12
|
+
* remain as deprecated aliases because published SDK versions send them.
|
|
13
|
+
*/
|
|
1
14
|
interface AmazonSearchOptions {
|
|
2
15
|
/** Product search query (1-500 characters). */
|
|
3
16
|
query: string;
|
|
4
|
-
/**
|
|
5
|
-
domain?: string;
|
|
6
|
-
/** Country code for localization. */
|
|
17
|
+
/** Marketplace country code (ISO 3166-1 alpha-2, e.g. 'us', 'gb', 'de'). Defaults to 'us'. */
|
|
7
18
|
country?: string;
|
|
8
|
-
/**
|
|
9
|
-
|
|
10
|
-
/**
|
|
11
|
-
|
|
12
|
-
/**
|
|
13
|
-
device?: "desktop" | "mobile" | "tablet";
|
|
14
|
-
/** Result sort order. */
|
|
15
|
-
sort_by?: "most_recent" | "price_low_to_high" | "price_high_to_low" | "featured" | "average_review" | "bestsellers";
|
|
16
|
-
/** Starting page (1-indexed). */
|
|
19
|
+
/** @deprecated Amazon domain suffix ('com', 'co.uk'). Use `country` instead. */
|
|
20
|
+
domain?: string;
|
|
21
|
+
/** Results page, 1-based. One page per call, 1 credit each. */
|
|
22
|
+
page?: number;
|
|
23
|
+
/** @deprecated Alias for `page`. */
|
|
17
24
|
start_page?: number;
|
|
18
|
-
/** Number of pages to fetch. */
|
|
19
|
-
pages?: number;
|
|
20
|
-
/** Amazon category id. */
|
|
21
|
-
category_id?: string;
|
|
22
|
-
/** Filter to a specific merchant. */
|
|
23
|
-
merchant_id?: string;
|
|
24
|
-
/** ZIP/postal code for localized pricing. */
|
|
25
|
-
zip_code?: string;
|
|
26
|
-
/** Auto-select the default variant. */
|
|
27
|
-
autoselect_variant?: boolean;
|
|
28
25
|
[key: string]: unknown;
|
|
29
26
|
}
|
|
30
27
|
interface AmazonProductOptions {
|
|
31
28
|
/** Amazon ASIN (e.g. 'B09XS7JWHH'). Sent to the API as 'query'. */
|
|
32
29
|
asin: string;
|
|
33
|
-
/**
|
|
30
|
+
/** Marketplace country code (ISO 3166-1 alpha-2, e.g. 'us', 'gb', 'de'). Defaults to 'us'. */
|
|
31
|
+
country?: string;
|
|
32
|
+
/** @deprecated Amazon domain suffix ('com', 'co.uk'). Use `country` instead. */
|
|
34
33
|
domain?: string;
|
|
35
|
-
|
|
34
|
+
[key: string]: unknown;
|
|
35
|
+
}
|
|
36
|
+
interface AmazonOffersOptions {
|
|
37
|
+
/** Amazon ASIN (e.g. 'B09XS7JWHH'). Sent to the API as 'query'. */
|
|
38
|
+
asin: string;
|
|
39
|
+
/** Marketplace country code (ISO 3166-1 alpha-2, e.g. 'us', 'gb', 'de'). Defaults to 'us'. */
|
|
36
40
|
country?: string;
|
|
37
|
-
/**
|
|
38
|
-
|
|
39
|
-
/** Currency code (ISO 4217, e.g. 'USD'). */
|
|
40
|
-
currency?: string;
|
|
41
|
-
/** Device to emulate. */
|
|
42
|
-
device?: "desktop" | "mobile" | "tablet";
|
|
43
|
-
/** ZIP/postal code for localized pricing. */
|
|
44
|
-
zip_code?: string;
|
|
45
|
-
/** Auto-select the default variant. */
|
|
46
|
-
autoselect_variant?: boolean;
|
|
41
|
+
/** @deprecated Amazon domain suffix ('com', 'co.uk'). Use `country` instead. */
|
|
42
|
+
domain?: string;
|
|
47
43
|
[key: string]: unknown;
|
|
48
44
|
}
|
|
49
45
|
declare class AmazonNamespace {
|
|
@@ -51,7 +47,12 @@ declare class AmazonNamespace {
|
|
|
51
47
|
constructor(client: Scavio);
|
|
52
48
|
search(options: AmazonSearchOptions): Promise<Record<string, unknown>>;
|
|
53
49
|
product(options: AmazonProductOptions): Promise<Record<string, unknown>>;
|
|
54
|
-
/**
|
|
50
|
+
/** Every seller offer for one ASIN: price, seller, condition, shipping, and
|
|
51
|
+
* which offer holds the buy box. Page 1 only. */
|
|
52
|
+
offers(options: AmazonOffersOptions): Promise<Record<string, unknown>>;
|
|
53
|
+
/** Supported Amazon marketplaces, as `domains` and `countries`. `languages`
|
|
54
|
+
* and `currencies` remain in the payload but are always empty: neither is a
|
|
55
|
+
* request parameter any more. */
|
|
55
56
|
options(): Promise<Record<string, unknown>>;
|
|
56
57
|
}
|
|
57
58
|
|
|
@@ -1158,6 +1159,12 @@ interface LinkedInPersonOptions {
|
|
|
1158
1159
|
url?: string;
|
|
1159
1160
|
[key: string]: unknown;
|
|
1160
1161
|
}
|
|
1162
|
+
interface LinkedInPersonPostsRequest extends LinkedInPersonOptions {
|
|
1163
|
+
/** Which feed: the member's own posts (default), posts they commented on, or posts they reacted to. */
|
|
1164
|
+
type?: "posts" | "comments" | "reactions";
|
|
1165
|
+
/** Opaque cursor from a previous response's next_cursor. */
|
|
1166
|
+
cursor?: string;
|
|
1167
|
+
}
|
|
1161
1168
|
/** A company reference: a universal name (slug), or a full company URL. */
|
|
1162
1169
|
interface LinkedInCompanyOptions {
|
|
1163
1170
|
/** Company universal name (slug), e.g. "microsoft". */
|
|
@@ -1166,17 +1173,23 @@ interface LinkedInCompanyOptions {
|
|
|
1166
1173
|
url?: string;
|
|
1167
1174
|
[key: string]: unknown;
|
|
1168
1175
|
}
|
|
1176
|
+
interface LinkedInCompanyPostsRequest extends LinkedInCompanyOptions {
|
|
1177
|
+
/** Opaque cursor from a previous response's next_cursor. */
|
|
1178
|
+
cursor?: string;
|
|
1179
|
+
}
|
|
1169
1180
|
/** @deprecated Use {@link LinkedInPersonOptions}. */
|
|
1170
1181
|
type LinkedInPersonRefOptions = LinkedInPersonOptions;
|
|
1171
|
-
/** @deprecated Use {@link
|
|
1172
|
-
type LinkedInPersonPostsOptions =
|
|
1173
|
-
/** @deprecated Use {@link
|
|
1174
|
-
type LinkedInCompanyPostsOptions =
|
|
1182
|
+
/** @deprecated Use {@link LinkedInPersonPostsRequest}. */
|
|
1183
|
+
type LinkedInPersonPostsOptions = LinkedInPersonPostsRequest;
|
|
1184
|
+
/** @deprecated Use {@link LinkedInCompanyPostsRequest}. */
|
|
1185
|
+
type LinkedInCompanyPostsOptions = LinkedInCompanyPostsRequest;
|
|
1175
1186
|
interface LinkedInSearchJobsOptions {
|
|
1176
1187
|
/** Search keyword. */
|
|
1177
1188
|
search: string;
|
|
1178
1189
|
/** Geographic filter; omit to search everywhere. */
|
|
1179
1190
|
location?: string;
|
|
1191
|
+
/** Opaque cursor from a previous response's next_cursor. */
|
|
1192
|
+
cursor?: string;
|
|
1180
1193
|
[key: string]: unknown;
|
|
1181
1194
|
}
|
|
1182
1195
|
interface LinkedInJobOptions {
|
|
@@ -1194,7 +1207,7 @@ interface LinkedInPostOptions {
|
|
|
1194
1207
|
[key: string]: unknown;
|
|
1195
1208
|
}
|
|
1196
1209
|
interface LinkedInPostCommentsOptions extends LinkedInPostOptions {
|
|
1197
|
-
/** 1-based page number,
|
|
1210
|
+
/** 1-based page number. Page size varies, so page until a page comes back empty. */
|
|
1198
1211
|
page?: number;
|
|
1199
1212
|
}
|
|
1200
1213
|
/** @deprecated Retired upstream; always returns HTTP 410. */
|
|
@@ -1229,19 +1242,25 @@ declare class LinkedInNamespace {
|
|
|
1229
1242
|
person(options: LinkedInPersonOptions): Promise<Record<string, unknown>>;
|
|
1230
1243
|
/** The about-only slice of the profile payload. */
|
|
1231
1244
|
personAbout(options: LinkedInPersonOptions): Promise<Record<string, unknown>>;
|
|
1232
|
-
/**
|
|
1233
|
-
|
|
1245
|
+
/**
|
|
1246
|
+
* A member's posts, or the posts they commented on or reacted to via `type`.
|
|
1247
|
+
* 50 per page; pass the previous response's `next_cursor` to advance.
|
|
1248
|
+
*/
|
|
1249
|
+
personPosts(options: LinkedInPersonPostsRequest): Promise<Record<string, unknown>>;
|
|
1234
1250
|
/** Company profile, including locations and featured employees. */
|
|
1235
1251
|
company(options: LinkedInCompanyOptions): Promise<Record<string, unknown>>;
|
|
1236
|
-
/** Recent company posts,
|
|
1237
|
-
companyPosts(options:
|
|
1238
|
-
/**
|
|
1252
|
+
/** Recent company posts, 50 per page; advance with `next_cursor`. */
|
|
1253
|
+
companyPosts(options: LinkedInCompanyPostsRequest): Promise<Record<string, unknown>>;
|
|
1254
|
+
/**
|
|
1255
|
+
* Job search, 25 per page; advance with `next_cursor`. Upstream rotates its
|
|
1256
|
+
* result set, so pages overlap slightly - dedupe by job id.
|
|
1257
|
+
*/
|
|
1239
1258
|
searchJobs(options: LinkedInSearchJobsOptions): Promise<Record<string, unknown>>;
|
|
1240
1259
|
/** Full detail for one job listing, including the hiring company. */
|
|
1241
1260
|
job(options: LinkedInJobOptions): Promise<Record<string, unknown>>;
|
|
1242
1261
|
/** Full detail for one post, including its top visible comments. */
|
|
1243
1262
|
post(options: LinkedInPostOptions): Promise<Record<string, unknown>>;
|
|
1244
|
-
/** Comments with their replies
|
|
1263
|
+
/** Comments with their replies. Page size varies - keep paging until empty. */
|
|
1245
1264
|
postComments(options: LinkedInPostCommentsOptions): Promise<Record<string, unknown>>;
|
|
1246
1265
|
/**
|
|
1247
1266
|
* @deprecated Retired by the upstream provider. Always returns HTTP 410 and is
|
|
@@ -1353,4 +1372,4 @@ declare class ScavioAPIError extends ScavioError {
|
|
|
1353
1372
|
constructor(statusCode: number, message: string, responseBody?: Record<string, unknown>);
|
|
1354
1373
|
}
|
|
1355
1374
|
|
|
1356
|
-
export { type AmazonProductOptions, type AmazonSearchOptions, BadRequestError, type GoogleAiModeOptions, type GoogleFlightsOptions, type GoogleHotelsDetailOptions, type GoogleHotelsOptions, type GoogleMapsPlaceOptions, type GoogleMapsReviewsOptions, type GoogleMapsSearchOptions, type GoogleNewsOptions, type GoogleSearchOptions, type GoogleShoppingOptions, type GoogleShoppingProductOptions, type GoogleShoppingStoresOptions, type GoogleTrendingOptions, type GoogleTrendsOptions, type InstagramCommentRepliesOptions, type InstagramFollowOptions, type InstagramPostCommentsOptions, type InstagramPostOptions, type InstagramProfileOptions, type InstagramSearchOptions, type InstagramStoriesOptions, type InstagramUserFeedOptions, InsufficientCreditsError, InvalidAPIKeyError, type LinkedInCompanyOptions, type LinkedInCompanyPostsOptions, type LinkedInCompanyRefOptions, type LinkedInJobOptions, type LinkedInPersonContactOptions, type LinkedInPersonOptions, type LinkedInPersonPostsOptions, type LinkedInPersonRefOptions, type LinkedInPostCommentsOptions, type LinkedInPostOptions, type LinkedInSearchJobsOptions, type LinkedInSearchPeopleOptions, type LinkedInSearchPostsOptions, MissingAPIKeyError, NotFoundError, RateLimitError, type RedditCommentRepliesOptions, type RedditFeedSort, type RedditPopularOptions, type RedditPostCommentsOptions, type RedditPostOptions, type RedditSearchOptions, type RedditSearchSuggestionsOptions, type RedditSort, type RedditSubredditOptions, type RedditSubredditPostsOptions, type RedditUserFeedOptions, type RedditUserOptions, Scavio, ScavioAPIError, type ScavioConfig, ScavioConnectionError, ScavioError, ScavioTimeoutError, type TikTokCommentRepliesOptions, type TikTokHashtagOptions, type TikTokHashtagVideosOptions, type TikTokProfileOptions, type TikTokSearchUsersOptions, type TikTokSearchVideosOptions, type TikTokShopCategoryProductsOptions, type TikTokShopListingRegion, type TikTokShopProductOptions, type TikTokShopProductReviewsOptions, type TikTokShopRegion, type TikTokShopResolveOptions, type TikTokShopReviewSort, type TikTokShopSearchOptions, type TikTokShopShopProductsOptions, type TikTokShopSuggestionsOptions, type TikTokUserFollowersOptions, type TikTokUserFollowingsOptions, type TikTokUserPostsOptions, type TikTokVideoCommentsOptions, type TikTokVideoOptions, type WalmartProductOptions, type WalmartSearchOptions, type XSearchOptions, type XTrendingOptions, type XTweetCommentsOptions, type XTweetOptions, type XTweetRetweetersOptions, type XUserFeedOptions, type XUserOptions, type YouTubeChannelCommunityOptions, type YouTubeChannelOptions, type YouTubeChannelResolveOptions, type YouTubeChannelSearchOptions, type YouTubeChannelShortsOptions, type YouTubeChannelVideosOptions, type YouTubeCommentRepliesOptions, type YouTubeCommentsOptions, type YouTubeMetadataOptions, type YouTubeRelatedOptions, type YouTubeSearchOptions, type YouTubeShortsOptions, type YouTubeStreamsOptions, type YouTubeSuggestionsOptions, type YouTubeTranscriptOptions, type YouTubeVideoOptions };
|
|
1375
|
+
export { type AmazonOffersOptions, type AmazonProductOptions, type AmazonSearchOptions, BadRequestError, type GoogleAiModeOptions, type GoogleFlightsOptions, type GoogleHotelsDetailOptions, type GoogleHotelsOptions, type GoogleMapsPlaceOptions, type GoogleMapsReviewsOptions, type GoogleMapsSearchOptions, type GoogleNewsOptions, type GoogleSearchOptions, type GoogleShoppingOptions, type GoogleShoppingProductOptions, type GoogleShoppingStoresOptions, type GoogleTrendingOptions, type GoogleTrendsOptions, type InstagramCommentRepliesOptions, type InstagramFollowOptions, type InstagramPostCommentsOptions, type InstagramPostOptions, type InstagramProfileOptions, type InstagramSearchOptions, type InstagramStoriesOptions, type InstagramUserFeedOptions, InsufficientCreditsError, InvalidAPIKeyError, type LinkedInCompanyOptions, type LinkedInCompanyPostsOptions, type LinkedInCompanyRefOptions, type LinkedInJobOptions, type LinkedInPersonContactOptions, type LinkedInPersonOptions, type LinkedInPersonPostsOptions, type LinkedInPersonRefOptions, type LinkedInPostCommentsOptions, type LinkedInPostOptions, type LinkedInSearchJobsOptions, type LinkedInSearchPeopleOptions, type LinkedInSearchPostsOptions, MissingAPIKeyError, NotFoundError, RateLimitError, type RedditCommentRepliesOptions, type RedditFeedSort, type RedditPopularOptions, type RedditPostCommentsOptions, type RedditPostOptions, type RedditSearchOptions, type RedditSearchSuggestionsOptions, type RedditSort, type RedditSubredditOptions, type RedditSubredditPostsOptions, type RedditUserFeedOptions, type RedditUserOptions, Scavio, ScavioAPIError, type ScavioConfig, ScavioConnectionError, ScavioError, ScavioTimeoutError, type TikTokCommentRepliesOptions, type TikTokHashtagOptions, type TikTokHashtagVideosOptions, type TikTokProfileOptions, type TikTokSearchUsersOptions, type TikTokSearchVideosOptions, type TikTokShopCategoryProductsOptions, type TikTokShopListingRegion, type TikTokShopProductOptions, type TikTokShopProductReviewsOptions, type TikTokShopRegion, type TikTokShopResolveOptions, type TikTokShopReviewSort, type TikTokShopSearchOptions, type TikTokShopShopProductsOptions, type TikTokShopSuggestionsOptions, type TikTokUserFollowersOptions, type TikTokUserFollowingsOptions, type TikTokUserPostsOptions, type TikTokVideoCommentsOptions, type TikTokVideoOptions, type WalmartProductOptions, type WalmartSearchOptions, type XSearchOptions, type XTrendingOptions, type XTweetCommentsOptions, type XTweetOptions, type XTweetRetweetersOptions, type XUserFeedOptions, type XUserOptions, type YouTubeChannelCommunityOptions, type YouTubeChannelOptions, type YouTubeChannelResolveOptions, type YouTubeChannelSearchOptions, type YouTubeChannelShortsOptions, type YouTubeChannelVideosOptions, type YouTubeCommentRepliesOptions, type YouTubeCommentsOptions, type YouTubeMetadataOptions, type YouTubeRelatedOptions, type YouTubeSearchOptions, type YouTubeShortsOptions, type YouTubeStreamsOptions, type YouTubeSuggestionsOptions, type YouTubeTranscriptOptions, type YouTubeVideoOptions };
|
package/dist/index.d.ts
CHANGED
|
@@ -1,49 +1,45 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Amazon moved to a new upstream in 2026-07 and the API now returns a
|
|
3
|
+
* normalized shape instead of the old raw provider payload. Nine options went
|
|
4
|
+
* with the old provider: language, currency, device, sort_by, pages,
|
|
5
|
+
* category_id, merchant_id, zip_code and autoselect_variant. They are removed
|
|
6
|
+
* rather than kept as no-ops - notably `sort_by`, which the marketplace was
|
|
7
|
+
* verified to ignore entirely (every sort value returned the same unordered
|
|
8
|
+
* set). Sending a retired option anyway still returns 200, with a top-level
|
|
9
|
+
* `warnings` array naming what was ignored.
|
|
10
|
+
*
|
|
11
|
+
* `country` is the canonical marketplace selector; `domain` and `start_page`
|
|
12
|
+
* remain as deprecated aliases because published SDK versions send them.
|
|
13
|
+
*/
|
|
1
14
|
interface AmazonSearchOptions {
|
|
2
15
|
/** Product search query (1-500 characters). */
|
|
3
16
|
query: string;
|
|
4
|
-
/**
|
|
5
|
-
domain?: string;
|
|
6
|
-
/** Country code for localization. */
|
|
17
|
+
/** Marketplace country code (ISO 3166-1 alpha-2, e.g. 'us', 'gb', 'de'). Defaults to 'us'. */
|
|
7
18
|
country?: string;
|
|
8
|
-
/**
|
|
9
|
-
|
|
10
|
-
/**
|
|
11
|
-
|
|
12
|
-
/**
|
|
13
|
-
device?: "desktop" | "mobile" | "tablet";
|
|
14
|
-
/** Result sort order. */
|
|
15
|
-
sort_by?: "most_recent" | "price_low_to_high" | "price_high_to_low" | "featured" | "average_review" | "bestsellers";
|
|
16
|
-
/** Starting page (1-indexed). */
|
|
19
|
+
/** @deprecated Amazon domain suffix ('com', 'co.uk'). Use `country` instead. */
|
|
20
|
+
domain?: string;
|
|
21
|
+
/** Results page, 1-based. One page per call, 1 credit each. */
|
|
22
|
+
page?: number;
|
|
23
|
+
/** @deprecated Alias for `page`. */
|
|
17
24
|
start_page?: number;
|
|
18
|
-
/** Number of pages to fetch. */
|
|
19
|
-
pages?: number;
|
|
20
|
-
/** Amazon category id. */
|
|
21
|
-
category_id?: string;
|
|
22
|
-
/** Filter to a specific merchant. */
|
|
23
|
-
merchant_id?: string;
|
|
24
|
-
/** ZIP/postal code for localized pricing. */
|
|
25
|
-
zip_code?: string;
|
|
26
|
-
/** Auto-select the default variant. */
|
|
27
|
-
autoselect_variant?: boolean;
|
|
28
25
|
[key: string]: unknown;
|
|
29
26
|
}
|
|
30
27
|
interface AmazonProductOptions {
|
|
31
28
|
/** Amazon ASIN (e.g. 'B09XS7JWHH'). Sent to the API as 'query'. */
|
|
32
29
|
asin: string;
|
|
33
|
-
/**
|
|
30
|
+
/** Marketplace country code (ISO 3166-1 alpha-2, e.g. 'us', 'gb', 'de'). Defaults to 'us'. */
|
|
31
|
+
country?: string;
|
|
32
|
+
/** @deprecated Amazon domain suffix ('com', 'co.uk'). Use `country` instead. */
|
|
34
33
|
domain?: string;
|
|
35
|
-
|
|
34
|
+
[key: string]: unknown;
|
|
35
|
+
}
|
|
36
|
+
interface AmazonOffersOptions {
|
|
37
|
+
/** Amazon ASIN (e.g. 'B09XS7JWHH'). Sent to the API as 'query'. */
|
|
38
|
+
asin: string;
|
|
39
|
+
/** Marketplace country code (ISO 3166-1 alpha-2, e.g. 'us', 'gb', 'de'). Defaults to 'us'. */
|
|
36
40
|
country?: string;
|
|
37
|
-
/**
|
|
38
|
-
|
|
39
|
-
/** Currency code (ISO 4217, e.g. 'USD'). */
|
|
40
|
-
currency?: string;
|
|
41
|
-
/** Device to emulate. */
|
|
42
|
-
device?: "desktop" | "mobile" | "tablet";
|
|
43
|
-
/** ZIP/postal code for localized pricing. */
|
|
44
|
-
zip_code?: string;
|
|
45
|
-
/** Auto-select the default variant. */
|
|
46
|
-
autoselect_variant?: boolean;
|
|
41
|
+
/** @deprecated Amazon domain suffix ('com', 'co.uk'). Use `country` instead. */
|
|
42
|
+
domain?: string;
|
|
47
43
|
[key: string]: unknown;
|
|
48
44
|
}
|
|
49
45
|
declare class AmazonNamespace {
|
|
@@ -51,7 +47,12 @@ declare class AmazonNamespace {
|
|
|
51
47
|
constructor(client: Scavio);
|
|
52
48
|
search(options: AmazonSearchOptions): Promise<Record<string, unknown>>;
|
|
53
49
|
product(options: AmazonProductOptions): Promise<Record<string, unknown>>;
|
|
54
|
-
/**
|
|
50
|
+
/** Every seller offer for one ASIN: price, seller, condition, shipping, and
|
|
51
|
+
* which offer holds the buy box. Page 1 only. */
|
|
52
|
+
offers(options: AmazonOffersOptions): Promise<Record<string, unknown>>;
|
|
53
|
+
/** Supported Amazon marketplaces, as `domains` and `countries`. `languages`
|
|
54
|
+
* and `currencies` remain in the payload but are always empty: neither is a
|
|
55
|
+
* request parameter any more. */
|
|
55
56
|
options(): Promise<Record<string, unknown>>;
|
|
56
57
|
}
|
|
57
58
|
|
|
@@ -1158,6 +1159,12 @@ interface LinkedInPersonOptions {
|
|
|
1158
1159
|
url?: string;
|
|
1159
1160
|
[key: string]: unknown;
|
|
1160
1161
|
}
|
|
1162
|
+
interface LinkedInPersonPostsRequest extends LinkedInPersonOptions {
|
|
1163
|
+
/** Which feed: the member's own posts (default), posts they commented on, or posts they reacted to. */
|
|
1164
|
+
type?: "posts" | "comments" | "reactions";
|
|
1165
|
+
/** Opaque cursor from a previous response's next_cursor. */
|
|
1166
|
+
cursor?: string;
|
|
1167
|
+
}
|
|
1161
1168
|
/** A company reference: a universal name (slug), or a full company URL. */
|
|
1162
1169
|
interface LinkedInCompanyOptions {
|
|
1163
1170
|
/** Company universal name (slug), e.g. "microsoft". */
|
|
@@ -1166,17 +1173,23 @@ interface LinkedInCompanyOptions {
|
|
|
1166
1173
|
url?: string;
|
|
1167
1174
|
[key: string]: unknown;
|
|
1168
1175
|
}
|
|
1176
|
+
interface LinkedInCompanyPostsRequest extends LinkedInCompanyOptions {
|
|
1177
|
+
/** Opaque cursor from a previous response's next_cursor. */
|
|
1178
|
+
cursor?: string;
|
|
1179
|
+
}
|
|
1169
1180
|
/** @deprecated Use {@link LinkedInPersonOptions}. */
|
|
1170
1181
|
type LinkedInPersonRefOptions = LinkedInPersonOptions;
|
|
1171
|
-
/** @deprecated Use {@link
|
|
1172
|
-
type LinkedInPersonPostsOptions =
|
|
1173
|
-
/** @deprecated Use {@link
|
|
1174
|
-
type LinkedInCompanyPostsOptions =
|
|
1182
|
+
/** @deprecated Use {@link LinkedInPersonPostsRequest}. */
|
|
1183
|
+
type LinkedInPersonPostsOptions = LinkedInPersonPostsRequest;
|
|
1184
|
+
/** @deprecated Use {@link LinkedInCompanyPostsRequest}. */
|
|
1185
|
+
type LinkedInCompanyPostsOptions = LinkedInCompanyPostsRequest;
|
|
1175
1186
|
interface LinkedInSearchJobsOptions {
|
|
1176
1187
|
/** Search keyword. */
|
|
1177
1188
|
search: string;
|
|
1178
1189
|
/** Geographic filter; omit to search everywhere. */
|
|
1179
1190
|
location?: string;
|
|
1191
|
+
/** Opaque cursor from a previous response's next_cursor. */
|
|
1192
|
+
cursor?: string;
|
|
1180
1193
|
[key: string]: unknown;
|
|
1181
1194
|
}
|
|
1182
1195
|
interface LinkedInJobOptions {
|
|
@@ -1194,7 +1207,7 @@ interface LinkedInPostOptions {
|
|
|
1194
1207
|
[key: string]: unknown;
|
|
1195
1208
|
}
|
|
1196
1209
|
interface LinkedInPostCommentsOptions extends LinkedInPostOptions {
|
|
1197
|
-
/** 1-based page number,
|
|
1210
|
+
/** 1-based page number. Page size varies, so page until a page comes back empty. */
|
|
1198
1211
|
page?: number;
|
|
1199
1212
|
}
|
|
1200
1213
|
/** @deprecated Retired upstream; always returns HTTP 410. */
|
|
@@ -1229,19 +1242,25 @@ declare class LinkedInNamespace {
|
|
|
1229
1242
|
person(options: LinkedInPersonOptions): Promise<Record<string, unknown>>;
|
|
1230
1243
|
/** The about-only slice of the profile payload. */
|
|
1231
1244
|
personAbout(options: LinkedInPersonOptions): Promise<Record<string, unknown>>;
|
|
1232
|
-
/**
|
|
1233
|
-
|
|
1245
|
+
/**
|
|
1246
|
+
* A member's posts, or the posts they commented on or reacted to via `type`.
|
|
1247
|
+
* 50 per page; pass the previous response's `next_cursor` to advance.
|
|
1248
|
+
*/
|
|
1249
|
+
personPosts(options: LinkedInPersonPostsRequest): Promise<Record<string, unknown>>;
|
|
1234
1250
|
/** Company profile, including locations and featured employees. */
|
|
1235
1251
|
company(options: LinkedInCompanyOptions): Promise<Record<string, unknown>>;
|
|
1236
|
-
/** Recent company posts,
|
|
1237
|
-
companyPosts(options:
|
|
1238
|
-
/**
|
|
1252
|
+
/** Recent company posts, 50 per page; advance with `next_cursor`. */
|
|
1253
|
+
companyPosts(options: LinkedInCompanyPostsRequest): Promise<Record<string, unknown>>;
|
|
1254
|
+
/**
|
|
1255
|
+
* Job search, 25 per page; advance with `next_cursor`. Upstream rotates its
|
|
1256
|
+
* result set, so pages overlap slightly - dedupe by job id.
|
|
1257
|
+
*/
|
|
1239
1258
|
searchJobs(options: LinkedInSearchJobsOptions): Promise<Record<string, unknown>>;
|
|
1240
1259
|
/** Full detail for one job listing, including the hiring company. */
|
|
1241
1260
|
job(options: LinkedInJobOptions): Promise<Record<string, unknown>>;
|
|
1242
1261
|
/** Full detail for one post, including its top visible comments. */
|
|
1243
1262
|
post(options: LinkedInPostOptions): Promise<Record<string, unknown>>;
|
|
1244
|
-
/** Comments with their replies
|
|
1263
|
+
/** Comments with their replies. Page size varies - keep paging until empty. */
|
|
1245
1264
|
postComments(options: LinkedInPostCommentsOptions): Promise<Record<string, unknown>>;
|
|
1246
1265
|
/**
|
|
1247
1266
|
* @deprecated Retired by the upstream provider. Always returns HTTP 410 and is
|
|
@@ -1353,4 +1372,4 @@ declare class ScavioAPIError extends ScavioError {
|
|
|
1353
1372
|
constructor(statusCode: number, message: string, responseBody?: Record<string, unknown>);
|
|
1354
1373
|
}
|
|
1355
1374
|
|
|
1356
|
-
export { type AmazonProductOptions, type AmazonSearchOptions, BadRequestError, type GoogleAiModeOptions, type GoogleFlightsOptions, type GoogleHotelsDetailOptions, type GoogleHotelsOptions, type GoogleMapsPlaceOptions, type GoogleMapsReviewsOptions, type GoogleMapsSearchOptions, type GoogleNewsOptions, type GoogleSearchOptions, type GoogleShoppingOptions, type GoogleShoppingProductOptions, type GoogleShoppingStoresOptions, type GoogleTrendingOptions, type GoogleTrendsOptions, type InstagramCommentRepliesOptions, type InstagramFollowOptions, type InstagramPostCommentsOptions, type InstagramPostOptions, type InstagramProfileOptions, type InstagramSearchOptions, type InstagramStoriesOptions, type InstagramUserFeedOptions, InsufficientCreditsError, InvalidAPIKeyError, type LinkedInCompanyOptions, type LinkedInCompanyPostsOptions, type LinkedInCompanyRefOptions, type LinkedInJobOptions, type LinkedInPersonContactOptions, type LinkedInPersonOptions, type LinkedInPersonPostsOptions, type LinkedInPersonRefOptions, type LinkedInPostCommentsOptions, type LinkedInPostOptions, type LinkedInSearchJobsOptions, type LinkedInSearchPeopleOptions, type LinkedInSearchPostsOptions, MissingAPIKeyError, NotFoundError, RateLimitError, type RedditCommentRepliesOptions, type RedditFeedSort, type RedditPopularOptions, type RedditPostCommentsOptions, type RedditPostOptions, type RedditSearchOptions, type RedditSearchSuggestionsOptions, type RedditSort, type RedditSubredditOptions, type RedditSubredditPostsOptions, type RedditUserFeedOptions, type RedditUserOptions, Scavio, ScavioAPIError, type ScavioConfig, ScavioConnectionError, ScavioError, ScavioTimeoutError, type TikTokCommentRepliesOptions, type TikTokHashtagOptions, type TikTokHashtagVideosOptions, type TikTokProfileOptions, type TikTokSearchUsersOptions, type TikTokSearchVideosOptions, type TikTokShopCategoryProductsOptions, type TikTokShopListingRegion, type TikTokShopProductOptions, type TikTokShopProductReviewsOptions, type TikTokShopRegion, type TikTokShopResolveOptions, type TikTokShopReviewSort, type TikTokShopSearchOptions, type TikTokShopShopProductsOptions, type TikTokShopSuggestionsOptions, type TikTokUserFollowersOptions, type TikTokUserFollowingsOptions, type TikTokUserPostsOptions, type TikTokVideoCommentsOptions, type TikTokVideoOptions, type WalmartProductOptions, type WalmartSearchOptions, type XSearchOptions, type XTrendingOptions, type XTweetCommentsOptions, type XTweetOptions, type XTweetRetweetersOptions, type XUserFeedOptions, type XUserOptions, type YouTubeChannelCommunityOptions, type YouTubeChannelOptions, type YouTubeChannelResolveOptions, type YouTubeChannelSearchOptions, type YouTubeChannelShortsOptions, type YouTubeChannelVideosOptions, type YouTubeCommentRepliesOptions, type YouTubeCommentsOptions, type YouTubeMetadataOptions, type YouTubeRelatedOptions, type YouTubeSearchOptions, type YouTubeShortsOptions, type YouTubeStreamsOptions, type YouTubeSuggestionsOptions, type YouTubeTranscriptOptions, type YouTubeVideoOptions };
|
|
1375
|
+
export { type AmazonOffersOptions, type AmazonProductOptions, type AmazonSearchOptions, BadRequestError, type GoogleAiModeOptions, type GoogleFlightsOptions, type GoogleHotelsDetailOptions, type GoogleHotelsOptions, type GoogleMapsPlaceOptions, type GoogleMapsReviewsOptions, type GoogleMapsSearchOptions, type GoogleNewsOptions, type GoogleSearchOptions, type GoogleShoppingOptions, type GoogleShoppingProductOptions, type GoogleShoppingStoresOptions, type GoogleTrendingOptions, type GoogleTrendsOptions, type InstagramCommentRepliesOptions, type InstagramFollowOptions, type InstagramPostCommentsOptions, type InstagramPostOptions, type InstagramProfileOptions, type InstagramSearchOptions, type InstagramStoriesOptions, type InstagramUserFeedOptions, InsufficientCreditsError, InvalidAPIKeyError, type LinkedInCompanyOptions, type LinkedInCompanyPostsOptions, type LinkedInCompanyRefOptions, type LinkedInJobOptions, type LinkedInPersonContactOptions, type LinkedInPersonOptions, type LinkedInPersonPostsOptions, type LinkedInPersonRefOptions, type LinkedInPostCommentsOptions, type LinkedInPostOptions, type LinkedInSearchJobsOptions, type LinkedInSearchPeopleOptions, type LinkedInSearchPostsOptions, MissingAPIKeyError, NotFoundError, RateLimitError, type RedditCommentRepliesOptions, type RedditFeedSort, type RedditPopularOptions, type RedditPostCommentsOptions, type RedditPostOptions, type RedditSearchOptions, type RedditSearchSuggestionsOptions, type RedditSort, type RedditSubredditOptions, type RedditSubredditPostsOptions, type RedditUserFeedOptions, type RedditUserOptions, Scavio, ScavioAPIError, type ScavioConfig, ScavioConnectionError, ScavioError, ScavioTimeoutError, type TikTokCommentRepliesOptions, type TikTokHashtagOptions, type TikTokHashtagVideosOptions, type TikTokProfileOptions, type TikTokSearchUsersOptions, type TikTokSearchVideosOptions, type TikTokShopCategoryProductsOptions, type TikTokShopListingRegion, type TikTokShopProductOptions, type TikTokShopProductReviewsOptions, type TikTokShopRegion, type TikTokShopResolveOptions, type TikTokShopReviewSort, type TikTokShopSearchOptions, type TikTokShopShopProductsOptions, type TikTokShopSuggestionsOptions, type TikTokUserFollowersOptions, type TikTokUserFollowingsOptions, type TikTokUserPostsOptions, type TikTokVideoCommentsOptions, type TikTokVideoOptions, type WalmartProductOptions, type WalmartSearchOptions, type XSearchOptions, type XTrendingOptions, type XTweetCommentsOptions, type XTweetOptions, type XTweetRetweetersOptions, type XUserFeedOptions, type XUserOptions, type YouTubeChannelCommunityOptions, type YouTubeChannelOptions, type YouTubeChannelResolveOptions, type YouTubeChannelSearchOptions, type YouTubeChannelShortsOptions, type YouTubeChannelVideosOptions, type YouTubeCommentRepliesOptions, type YouTubeCommentsOptions, type YouTubeMetadataOptions, type YouTubeRelatedOptions, type YouTubeSearchOptions, type YouTubeShortsOptions, type YouTubeStreamsOptions, type YouTubeSuggestionsOptions, type YouTubeTranscriptOptions, type YouTubeVideoOptions };
|
package/dist/index.js
CHANGED
|
@@ -275,7 +275,18 @@ var AmazonNamespace = class {
|
|
|
275
275
|
...rest
|
|
276
276
|
});
|
|
277
277
|
}
|
|
278
|
-
/**
|
|
278
|
+
/** Every seller offer for one ASIN: price, seller, condition, shipping, and
|
|
279
|
+
* which offer holds the buy box. Page 1 only. */
|
|
280
|
+
async offers(options) {
|
|
281
|
+
const { asin, ...rest } = options;
|
|
282
|
+
return this.client._post("/api/v1/amazon/offers", {
|
|
283
|
+
query: asin,
|
|
284
|
+
...rest
|
|
285
|
+
});
|
|
286
|
+
}
|
|
287
|
+
/** Supported Amazon marketplaces, as `domains` and `countries`. `languages`
|
|
288
|
+
* and `currencies` remain in the payload but are always empty: neither is a
|
|
289
|
+
* request parameter any more. */
|
|
279
290
|
async options() {
|
|
280
291
|
return this.client._get("/api/v1/amazon/options");
|
|
281
292
|
}
|
|
@@ -728,7 +739,10 @@ var LinkedInNamespace = class {
|
|
|
728
739
|
async personAbout(options) {
|
|
729
740
|
return this.client._post("/api/v1/linkedin/person/about", options);
|
|
730
741
|
}
|
|
731
|
-
/**
|
|
742
|
+
/**
|
|
743
|
+
* A member's posts, or the posts they commented on or reacted to via `type`.
|
|
744
|
+
* 50 per page; pass the previous response's `next_cursor` to advance.
|
|
745
|
+
*/
|
|
732
746
|
async personPosts(options) {
|
|
733
747
|
return this.client._post("/api/v1/linkedin/person/posts", options);
|
|
734
748
|
}
|
|
@@ -736,11 +750,14 @@ var LinkedInNamespace = class {
|
|
|
736
750
|
async company(options) {
|
|
737
751
|
return this.client._post("/api/v1/linkedin/company", options);
|
|
738
752
|
}
|
|
739
|
-
/** Recent company posts,
|
|
753
|
+
/** Recent company posts, 50 per page; advance with `next_cursor`. */
|
|
740
754
|
async companyPosts(options) {
|
|
741
755
|
return this.client._post("/api/v1/linkedin/company/posts", options);
|
|
742
756
|
}
|
|
743
|
-
/**
|
|
757
|
+
/**
|
|
758
|
+
* Job search, 25 per page; advance with `next_cursor`. Upstream rotates its
|
|
759
|
+
* result set, so pages overlap slightly - dedupe by job id.
|
|
760
|
+
*/
|
|
744
761
|
async searchJobs(options) {
|
|
745
762
|
return this.client._post("/api/v1/linkedin/search/jobs", options);
|
|
746
763
|
}
|
|
@@ -752,7 +769,7 @@ var LinkedInNamespace = class {
|
|
|
752
769
|
async post(options) {
|
|
753
770
|
return this.client._post("/api/v1/linkedin/post", options);
|
|
754
771
|
}
|
|
755
|
-
/** Comments with their replies
|
|
772
|
+
/** Comments with their replies. Page size varies - keep paging until empty. */
|
|
756
773
|
async postComments(options) {
|
|
757
774
|
return this.client._post("/api/v1/linkedin/post/comments", options);
|
|
758
775
|
}
|