scrapebadger 0.62.0 → 0.63.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.d.cts CHANGED
@@ -8633,8 +8633,10 @@ interface EbaySearchByImageParams {
8633
8633
  }
8634
8634
  /** Parameters for searching completed / sold eBay listings. */
8635
8635
  interface EbayCompletedParams {
8636
- /** Search keywords (required) */
8637
- query: string;
8636
+ /** Search keywords. Optional when `seller` is set; pass at least one. */
8637
+ query?: string;
8638
+ /** Only this seller's sold listings (eBay username). Works without `query`. */
8639
+ seller?: string;
8638
8640
  /** Marketplace domain (default: "com") */
8639
8641
  domain?: string;
8640
8642
  /** Restrict to a category id */
@@ -8769,7 +8771,10 @@ declare class SearchClient$b {
8769
8771
  /**
8770
8772
  * Search completed / sold listings — eBay's sold-price history.
8771
8773
  *
8772
- * @param params - Search parameters including query, filters, and pagination.
8774
+ * Pass `query`, `seller` or both. `seller` alone pages through everything
8775
+ * that seller sold, e.g. `completed({ seller: "musicmagpie", domain: "co.uk" })`.
8776
+ *
8777
+ * @param params - Search parameters including query, seller, filters, and pagination.
8773
8778
  * @returns Search results (with `sold: true`), facets, and pagination.
8774
8779
  */
8775
8780
  completed(params: EbayCompletedParams): Promise<SearchResponse$6>;
package/dist/index.d.ts CHANGED
@@ -8633,8 +8633,10 @@ interface EbaySearchByImageParams {
8633
8633
  }
8634
8634
  /** Parameters for searching completed / sold eBay listings. */
8635
8635
  interface EbayCompletedParams {
8636
- /** Search keywords (required) */
8637
- query: string;
8636
+ /** Search keywords. Optional when `seller` is set; pass at least one. */
8637
+ query?: string;
8638
+ /** Only this seller's sold listings (eBay username). Works without `query`. */
8639
+ seller?: string;
8638
8640
  /** Marketplace domain (default: "com") */
8639
8641
  domain?: string;
8640
8642
  /** Restrict to a category id */
@@ -8769,7 +8771,10 @@ declare class SearchClient$b {
8769
8771
  /**
8770
8772
  * Search completed / sold listings — eBay's sold-price history.
8771
8773
  *
8772
- * @param params - Search parameters including query, filters, and pagination.
8774
+ * Pass `query`, `seller` or both. `seller` alone pages through everything
8775
+ * that seller sold, e.g. `completed({ seller: "musicmagpie", domain: "co.uk" })`.
8776
+ *
8777
+ * @param params - Search parameters including query, seller, filters, and pagination.
8773
8778
  * @returns Search results (with `sold: true`), facets, and pagination.
8774
8779
  */
8775
8780
  completed(params: EbayCompletedParams): Promise<SearchResponse$6>;
package/dist/index.js CHANGED
@@ -9,7 +9,7 @@ function _interopDefault (e) { return e && e.__esModule ? e : { default: e }; }
9
9
  var WebSocket__default = /*#__PURE__*/_interopDefault(WebSocket);
10
10
 
11
11
  // src/internal/version.ts
12
- var SDK_VERSION = "0.62.0";
12
+ var SDK_VERSION = "0.63.0";
13
13
 
14
14
  // src/internal/exceptions.ts
15
15
  var ScrapeBadgerError = class _ScrapeBadgerError extends Error {
@@ -6177,13 +6177,20 @@ var SearchClient8 = class {
6177
6177
  /**
6178
6178
  * Search completed / sold listings — eBay's sold-price history.
6179
6179
  *
6180
- * @param params - Search parameters including query, filters, and pagination.
6180
+ * Pass `query`, `seller` or both. `seller` alone pages through everything
6181
+ * that seller sold, e.g. `completed({ seller: "musicmagpie", domain: "co.uk" })`.
6182
+ *
6183
+ * @param params - Search parameters including query, seller, filters, and pagination.
6181
6184
  * @returns Search results (with `sold: true`), facets, and pagination.
6182
6185
  */
6183
6186
  async completed(params) {
6187
+ if (!params.query && !params.seller) {
6188
+ throw new Error("Pass query, seller, or both.");
6189
+ }
6184
6190
  return this.client.request("/v1/ebay/completed", {
6185
6191
  params: {
6186
6192
  query: params.query,
6193
+ seller: params.seller,
6187
6194
  domain: params.domain,
6188
6195
  category_id: params.category_id,
6189
6196
  page: params.page,