@scavio/mcp-server 0.42.0 → 0.44.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 +38 -5
- package/dist/tools/index.d.ts +2 -2
- package/dist/tools/index.js +4 -2
- package/dist/tools/index.js.map +1 -1
- package/dist/tools/jcpenney.d.ts +3 -0
- package/dist/tools/jcpenney.js +145 -0
- package/dist/tools/jcpenney.js.map +1 -0
- package/package.json +6 -2
package/README.md
CHANGED
|
@@ -3,9 +3,9 @@
|
|
|
3
3
|

|
|
4
4
|

|
|
5
5
|
|
|
6
|
-
[Scavio](https://scavio.dev?utm_source=npm-mcp&utm_medium=package&utm_campaign=readme) is a unified [Web Search API](https://scavio.dev/docs/search-api?utm_source=npm-mcp&utm_medium=package&utm_campaign=readme) and MCP server that gives AI agents web search, page extraction, and structured data from e-commerce, social, travel, jobs, real-estate, app-store, ad-library and company-filing sources.
|
|
6
|
+
[Scavio](https://scavio.dev?utm_source=npm-mcp&utm_medium=package&utm_campaign=readme) is a unified [Web Search API](https://scavio.dev/docs/search-api?utm_source=npm-mcp&utm_medium=package&utm_campaign=readme) and MCP server that gives AI agents web search, page extraction, and structured data from e-commerce, social, travel, jobs, real-estate, app-store, ad-library and company-filing sources. 437 tools across 67 platforms plus Extract, map, crawl and batch, one API key.
|
|
7
7
|
|
|
8
|
-
**The 22 platforms added in 0.13.0 are opt-in.** Registering all
|
|
8
|
+
**The 22 platforms added in 0.13.0 are opt-in.** Registering all 437 tools puts ~520KB of tool definitions — roughly 90k tokens — into every session before you type anything. So the default is the platform set 0.12.x already had, plus Extract: 142 tools, 112KB. Upgrading never removes a tool you were using. Everything else is one env var away: see [Choosing which tools load](#choosing-which-tools-load).
|
|
9
9
|
|
|
10
10
|
## Remote MCP Server
|
|
11
11
|
|
|
@@ -207,7 +207,7 @@ Add to settings (`Cmd+,`):
|
|
|
207
207
|
|
|
208
208
|
## Choosing which tools load
|
|
209
209
|
|
|
210
|
-
Scavio exposes
|
|
210
|
+
Scavio exposes 437 tools. Loading all of them costs ~520KB of `tools/list` —
|
|
211
211
|
roughly 90k tokens of context in every session before the user has said anything,
|
|
212
212
|
and more tools than some clients will accept at all. So the server registers a
|
|
213
213
|
curated subset by default and lets you pick the rest. The sizes below are
|
|
@@ -218,7 +218,7 @@ measured, not estimated: `npm run toolslist` reproduces them.
|
|
|
218
218
|
| Value | Registers |
|
|
219
219
|
|-------|-----------|
|
|
220
220
|
| *(unset)* or `default` | Every platform 0.12.x had, plus `extract` — **142 tools, 112KB** |
|
|
221
|
-
| `all` | every platform — **
|
|
221
|
+
| `all` | every platform — **437 tools, ~520KB** |
|
|
222
222
|
| `extract,sec,g2` | just those platforms — 18 tools, 21KB |
|
|
223
223
|
| `default,zillow,metaads` | the default set plus two more — 148 tools, 120KB |
|
|
224
224
|
| `default,chatgpt,gemini` | the default set plus ChatGPT and Gemini — 144 tools, 115KB |
|
|
@@ -233,7 +233,7 @@ tells you to call to check the server works.
|
|
|
233
233
|
|
|
234
234
|
**Platform keys:** `extract`, `google`, `chatgpt`, `gemini`, `youtube`, `tiktok`, `instagram`,
|
|
235
235
|
`reddit`, `x`, `linkedin`, `threads`, `kuaishou`, `amazon`, `walmart`, `ebay`,
|
|
236
|
-
`target`, `homedepot`, `costco`, `heb`, `kroger`, `decathlon`, `specs`, `lowes`, `samsclub`, `canadiantire`, `dollargeneral`, `sephora`, `ulta`, `aldi`, `microcenter`, `walgreens`, `cvs`, `wholefoods`, `harborfreight`, `petsmart`, `petco`, `iherb`, `chewy`, `menards`, `nordstrom`, `nordstromrack`, `bestbuy`, `tcgplayer`, `vinted`, `macys`, `saks`, `kohls`, `mercadolibre`, `tiktok-shop`, `booking`, `airbnb`,
|
|
236
|
+
`target`, `homedepot`, `costco`, `heb`, `kroger`, `decathlon`, `specs`, `lowes`, `samsclub`, `canadiantire`, `dollargeneral`, `sephora`, `ulta`, `aldi`, `microcenter`, `walgreens`, `cvs`, `wholefoods`, `harborfreight`, `petsmart`, `petco`, `iherb`, `chewy`, `menards`, `nordstrom`, `nordstromrack`, `bestbuy`, `tcgplayer`, `vinted`, `macys`, `saks`, `kohls`, `jcpenney`, `mercadolibre`, `tiktok-shop`, `booking`, `airbnb`,
|
|
237
237
|
`tripadvisor`, `yelp`, `zillow`, `redfin`, `realtor`, `rightmove`, `indeed`, `glassdoor`,
|
|
238
238
|
`appstore`, `googleplay`, `g2`, `capterra`, `trustpilot`, `googleads`, `metaads`, `sec`, `companieshouse`
|
|
239
239
|
|
|
@@ -1212,6 +1212,39 @@ price after a public offer code, with the code. Rating and review count only:
|
|
|
1212
1212
|
review text is not available. No price history, international sites, account
|
|
1213
1213
|
offers or checkout: to track clearance prices, poll and store your own.
|
|
1214
1214
|
|
|
1215
|
+
### JCPenney
|
|
1216
|
+
|
|
1217
|
+
| Tool | Description |
|
|
1218
|
+
|------|-------------|
|
|
1219
|
+
| `search_jcpenney` | Search jcpenney.com (US), 48 products per page (at most 25 pages): current, regular and after-coupon price ranges with the coupon code, price type (sale / clearance / original), percent off, deal label, rating, review count, badge, availability label, colors with SKU ids, marketplace flag and seller; filter by brand, color, size, price range, deal label or any facet value; sort by relevance, new arrivals, best sellers, rating or price; plus the facets with counts, `corrected_query` and `redirected_to` |
|
|
1220
|
+
| `get_jcpenney_product` | One product by id or URL, or up to 20 by `product_ids`: price block (regular, sale and clearance ranges, percent off, after-coupon price with its code, price window), breadcrumbs, average rating, review count, question and answer counts, and every variant with sku, UPC, color, size, status and online stock level (high / low / out) |
|
|
1221
|
+
| `get_jcpenney_category` | Browse a category by its `/g/` path or URL (the path carries its `id=cat...`), 48 per page, with the same filters and sorts as search, plus breadcrumbs |
|
|
1222
|
+
| `get_jcpenney_brand` | Browse one brand by name or brand page URL, 48 per page, with the same filters and sorts as search |
|
|
1223
|
+
| `get_jcpenney_deals` | Clearance (default), Sale, Black Friday deals, Big Buy, Limited Time Special, Best Value, Gotta Have It, Closeout, Buy 1 Get 1 or any Deals & Promotions label, across all products or one department |
|
|
1224
|
+
| `get_jcpenney_stores` | JCPenney stores near a ZIP, a city + state or a point within 1-100 miles (default 25), paged: `store_id`, address, phone, weekly hours, timezone, services (salon, portrait studio, JCPenney Beauty, Curbside Pickup...), pickup directions and bookable appointments |
|
|
1225
|
+
| `get_jcpenney_store_availability` | Real unit counts of one SKU at the 5 nearest stores to a ZIP (or lat + lng): `quantity`, `status`, `updated_at`, store hours, plus `stores_with_stock` and `total_quantity` |
|
|
1226
|
+
| `get_jcpenney_suggestions` | The search-box suggestions: keyword completions with their search URL and department refinements where JCPenney offers them |
|
|
1227
|
+
| `get_jcpenney_coupons` | Today's public JCPenney coupons: code (null for in-store offers that need none), channel, headline, details, start and end dates, disclaimer and eligible-products URL |
|
|
1228
|
+
| `get_jcpenney_reviews` | Real review text of one product by id or URL, up to 98 per call (default 38), sorted most recent, most helpful, highest or lowest rating, or relevance, optionally one star rating: `total_reviews` (every language), `displayed_reviews` (the English reviews JCPenney lists), `matching_reviews` for the sort and filter, rating distribution, recommended percent, secondary ratings (Quality, Value...), and per review the text, rating, author nickname, location, dates, helpful votes, `verified_purchaser`, `incentivized`, `syndicated` with `syndication_source`, photos, videos and the brand's response |
|
|
1229
|
+
| `get_jcpenney_questions` | Customer questions and every answer for one product, up to 50 questions (default 10), newest answers first: `total_questions`, `total_answers`, and per answer the text, author, `author_type` (brand, retailer for JCPenney staff, ai, customer), `ai_label` (AI-Generated / AI-Assisted), `is_best_answer` and votes |
|
|
1230
|
+
|
|
1231
|
+
Platform key `jcpenney`. 1 credit per call, reviews and questions included. US site only (Puerto Rico
|
|
1232
|
+
stores included), prices in USD. Search, category, brand and deals share one
|
|
1233
|
+
grid: 48 products per page, at most 25 pages (1,200 items deep), with
|
|
1234
|
+
`total` and `total_pages`. Facet values feed `filters` as
|
|
1235
|
+
`{facet id: value}`. A category needs a jcpenney.com `/g/` path or URL that
|
|
1236
|
+
carries its `id=cat...`; a department page lists no products without a
|
|
1237
|
+
filter. Prices are product-level ranges plus the after-coupon price and its
|
|
1238
|
+
code: JCPenney does not expose a price per size or color. Store availability
|
|
1239
|
+
takes a product's `variants[].sku` and returns real unit counts at exactly
|
|
1240
|
+
the 5 nearest stores. Reviews and questions are slower than the other
|
|
1241
|
+
tools: usually 15-90s, up to about 3 minutes, and failed calls are not
|
|
1242
|
+
charged. `total_reviews` counts every language and is often larger than
|
|
1243
|
+
`displayed_reviews`; the questions list has no sort option. Reviewer age,
|
|
1244
|
+
gender and IP addresses are never returned. No price history, international
|
|
1245
|
+
sites, account offers or JCPenney Rewards balances, or checkout: to track
|
|
1246
|
+
clearance prices, poll and store your own.
|
|
1247
|
+
|
|
1215
1248
|
### Kroger
|
|
1216
1249
|
|
|
1217
1250
|
| Tool | Description |
|
package/dist/tools/index.d.ts
CHANGED
|
@@ -5,7 +5,7 @@ export declare const PLATFORM_KEYS: string[];
|
|
|
5
5
|
* What registers when SCAVIO_PLATFORMS is unset.
|
|
6
6
|
*
|
|
7
7
|
* Registering everything is not an option any more. The full surface is 408
|
|
8
|
-
* tools, which serialises to
|
|
8
|
+
* tools, which serialises to 520KB of tools/list (measured with
|
|
9
9
|
* `npm run toolslist`, not estimated) — roughly 90k tokens pushed into the
|
|
10
10
|
* context of EVERY session before the user has typed anything, and past the
|
|
11
11
|
* hard tool-count ceiling some clients enforce. The default set below is 142
|
|
@@ -27,7 +27,7 @@ export declare const DEFAULT_PLATFORMS: string[];
|
|
|
27
27
|
* Turn a SCAVIO_PLATFORMS value into the canonical platform keys to register.
|
|
28
28
|
*
|
|
29
29
|
* Accepts a comma-separated list of platform keys, plus three keywords:
|
|
30
|
-
* all — every platform (
|
|
30
|
+
* all — every platform (437 tools)
|
|
31
31
|
* default — expands to DEFAULT_PLATFORMS, so `default,sec,g2` is additive
|
|
32
32
|
* none — no platform tools at all, leaving only get_usage
|
|
33
33
|
*
|
package/dist/tools/index.js
CHANGED
|
@@ -45,6 +45,7 @@ import { registerVintedTools } from "./vinted.js";
|
|
|
45
45
|
import { registerMacysTools } from "./macys.js";
|
|
46
46
|
import { registerSaksTools } from "./saks.js";
|
|
47
47
|
import { registerKohlsTools } from "./kohls.js";
|
|
48
|
+
import { registerJcpenneyTools } from "./jcpenney.js";
|
|
48
49
|
import { registerMercadoLibreTools } from "./mercadolibre.js";
|
|
49
50
|
import { registerTiktokShopTools } from "./tiktok-shop.js";
|
|
50
51
|
import { registerBookingTools } from "./booking.js";
|
|
@@ -133,6 +134,7 @@ const PLATFORMS = {
|
|
|
133
134
|
macys: registerMacysTools,
|
|
134
135
|
saks: registerSaksTools,
|
|
135
136
|
kohls: registerKohlsTools,
|
|
137
|
+
jcpenney: registerJcpenneyTools,
|
|
136
138
|
mercadolibre: registerMercadoLibreTools,
|
|
137
139
|
"tiktok-shop": registerTiktokShopTools,
|
|
138
140
|
// Travel and local
|
|
@@ -168,7 +170,7 @@ export const PLATFORM_KEYS = Object.keys(PLATFORMS);
|
|
|
168
170
|
* What registers when SCAVIO_PLATFORMS is unset.
|
|
169
171
|
*
|
|
170
172
|
* Registering everything is not an option any more. The full surface is 408
|
|
171
|
-
* tools, which serialises to
|
|
173
|
+
* tools, which serialises to 520KB of tools/list (measured with
|
|
172
174
|
* `npm run toolslist`, not estimated) — roughly 90k tokens pushed into the
|
|
173
175
|
* context of EVERY session before the user has typed anything, and past the
|
|
174
176
|
* hard tool-count ceiling some clients enforce. The default set below is 142
|
|
@@ -225,7 +227,7 @@ function warnOnce(message) {
|
|
|
225
227
|
* Turn a SCAVIO_PLATFORMS value into the canonical platform keys to register.
|
|
226
228
|
*
|
|
227
229
|
* Accepts a comma-separated list of platform keys, plus three keywords:
|
|
228
|
-
* all — every platform (
|
|
230
|
+
* all — every platform (437 tools)
|
|
229
231
|
* default — expands to DEFAULT_PLATFORMS, so `default,sec,g2` is additive
|
|
230
232
|
* none — no platform tools at all, leaving only get_usage
|
|
231
233
|
*
|
package/dist/tools/index.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js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,CAAC,CAAC;IACxC,OAAO,SAAS,CAAC;AACnB,CAAC"}
|
|
@@ -0,0 +1,145 @@
|
|
|
1
|
+
import { z } from "zod";
|
|
2
|
+
import { handleApiError } from "../lib/tool-error.js";
|
|
3
|
+
import { trimResponse } from "../lib/trim-response.js";
|
|
4
|
+
// Shapes mirror backend/src/routes/jcpenney.ts (jcpenney.com, US incl. Puerto
|
|
5
|
+
// Rico stores, USD). Cross-field rules the backend enforces and zod here does
|
|
6
|
+
// not: product takes product_id, url or product_ids; category takes path or
|
|
7
|
+
// url; brand takes brand or url; stores take one location (zip, city + state,
|
|
8
|
+
// or lat + lng); store availability takes zip or lat + lng; reviews and
|
|
9
|
+
// questions take product_id or url. No zod
|
|
10
|
+
// `.default()`: the MCP SDK would post a defaulted field on every call.
|
|
11
|
+
const SORTS = ["relevance", "new_arrivals", "best_sellers", "rating", "price_low_to_high", "price_high_to_low"];
|
|
12
|
+
const REVIEW_SORTS = ["most_recent", "most_helpful", "highest_rating", "lowest_rating", "relevance"];
|
|
13
|
+
const DEAL_TYPES = ["clearance", "sale", "black_friday", "big_buy", "limited_time_special", "best_value", "gotta_have_it", "closeout", "bogo"];
|
|
14
|
+
const ITEM_FIELDS = "id, title, brand, URL, image, sku_id, price and price_max (current), regular_price and regular_price_max, price_type (sale, clearance, original), percent_off, deal_label (BIG BUY!, CLEARANCE...), coupon_price with coupon_code (the price after today's coupon), rating, review_count, badge (Only at JCP, NEW, Few Left), availability_label (Same Day Pickup, Online Only...), colors with their SKU ids, and is_marketplace with the seller for third-party items";
|
|
15
|
+
const GRID_SHORT = "48 products per page (at most 25 pages) with the same item fields, facets and totals as search_jcpenney";
|
|
16
|
+
const GRID = `48 products per page (at most 25 pages = 1,200 items), each with ${ITEM_FIELDS}. Also returns total, page, total_pages, the sort applied, applied_filters and every facet (id, label and values with their value, count and a selected flag; any of them works in filters). Prices are product-level ranges: JCPenney does not expose a price per size or color. Average rating and review count here; review text is get_jcpenney_reviews. Prices in USD`;
|
|
17
|
+
const textOrList = (description) => z.union([z.string().min(1).max(120), z.array(z.string().min(1).max(120)).min(1).max(20)]).optional().describe(description);
|
|
18
|
+
const brandFilter = () => textOrList("Only this brand (or any of several), as the Brand facet lists it, e.g. \"levi's\", \"nike\", \"st. john's bay\".");
|
|
19
|
+
const dealFilter = () => textOrList("Only items with this Deals & Promotions label (\"SALE\", \"CLEARANCE\", \"BIG BUY!\"...), as the facet lists it.");
|
|
20
|
+
const zip = () => z.union([z.string().regex(/^\d{5}(-\d{4})?$/), z.number().int().min(0).max(99999)]);
|
|
21
|
+
const productId = () => z.string().regex(/^[pP][pP][a-zA-Z]?\d{6,13}$/);
|
|
22
|
+
const gridFields = {
|
|
23
|
+
page: z.number().int().min(1).max(25).optional()
|
|
24
|
+
.describe("Results page, 1-based (48 items per page, at most 25 pages). A page past the last one returns an empty items list with the real total. Defaults to 1."),
|
|
25
|
+
sort: z.enum(SORTS).optional()
|
|
26
|
+
.describe("relevance (default), new_arrivals, best_sellers, rating (highest rated first), price_low_to_high or price_high_to_low. The price orders are JCPenney's own and loose: sort the items by price yourself when you need a strict order."),
|
|
27
|
+
color: textOrList("Only this color (or any of several), as the Color facet lists it (black, blue, beige...)."),
|
|
28
|
+
size: textOrList("Only this size (or any of several), as the Size facet lists it (m, 12, 32x30...)."),
|
|
29
|
+
price_range: textOrList("A Price Range facet value, e.g. \"under $5\", \"$20 - $24\"."),
|
|
30
|
+
filters: z.record(z.string(), z.union([z.string(), z.number(), z.array(z.union([z.string(), z.number()])).max(20)])).optional()
|
|
31
|
+
.describe("Any facet from a previous response: {facets[].id: facets[].values[].value, or a list of values (any of them)}, e.g. {\"gender\": \"women\"}, {\"store_availability\": \"same day pickup\"}, {\"average_rating\": \"4 rating\"}. Several facets combine (AND)."),
|
|
32
|
+
};
|
|
33
|
+
export function registerJcpenneyTools(server, getClient) {
|
|
34
|
+
const post = (path) => async (params) => {
|
|
35
|
+
try {
|
|
36
|
+
const data = await getClient().post(`/api/v1/jcpenney/${path}`, params);
|
|
37
|
+
return trimResponse(data);
|
|
38
|
+
}
|
|
39
|
+
catch (err) {
|
|
40
|
+
return handleApiError(err);
|
|
41
|
+
}
|
|
42
|
+
};
|
|
43
|
+
server.tool("search_jcpenney", `Search jcpenney.com (US) by keyword, filtered by brand, color, size, price range, deal label (SALE, CLEARANCE...) and any facet value (gender, store availability, rating, rise...), sorted by relevance (default), new arrivals, best sellers, rating or price. ${GRID}. When the site autocorrects the keyword, corrected_query says so; when it sends a keyword to a deal or category listing (doorbusters), redirected_to says where and the items are that listing's. Use an item's id with get_jcpenney_product, get_jcpenney_reviews or get_jcpenney_questions. 1 credit.`, {
|
|
44
|
+
query: z.string().min(1).max(200)
|
|
45
|
+
.describe("Search keywords, e.g. 'jeans'."),
|
|
46
|
+
brand: brandFilter(),
|
|
47
|
+
deal: dealFilter(),
|
|
48
|
+
exact: z.boolean().optional()
|
|
49
|
+
.describe("JCPenney narrows many keywords to a category on its own (jeans -> the Jeans category, visible in applied_filters). true searches the keyword across every category instead."),
|
|
50
|
+
...gridFields,
|
|
51
|
+
}, post("search"));
|
|
52
|
+
server.tool("get_jcpenney_product", `One jcpenney.com product by id or URL, or up to 20 by product_ids in one call: title, brand, description, features, category and breadcrumbs, product and item type, images, average rating, review_count, question and answer counts (review text and Q&A: get_jcpenney_reviews and get_jcpenney_questions), the price block (regular, sale and clearance min / max ranges, percent off, price type, deal label, the after-coupon price with its coupon code, and when the price window starts and ends), channel (Omnichannel / OnlineOnly), in-store pickup, marketplace flag, and every variant: sku, UPC, color, size, all options, status, max per order and online_stock (high, low or out; single product only, a level, not a count). Prices are product-level ranges: JCPenney does not expose a price per size or color. A variants[].sku is what get_jcpenney_store_availability takes. An unknown id is a 404; unknown ids in a batch are listed in not_found. 1 credit.`, {
|
|
53
|
+
product_id: productId().optional()
|
|
54
|
+
.describe("A JCPenney product id (ppr / ppm / pp + digits): a search result's id, the last part of a product URL, e.g. 'ppr5008604049'."),
|
|
55
|
+
url: z.string().min(1).max(800).optional()
|
|
56
|
+
.describe("A jcpenney.com product URL (its product id is used). Alternative to product_id."),
|
|
57
|
+
product_ids: z.array(productId()).min(1).max(20).optional()
|
|
58
|
+
.describe("Up to 20 product ids in one call (still 1 credit). Batch results carry no online stock."),
|
|
59
|
+
}, post("product"));
|
|
60
|
+
server.tool("get_jcpenney_category", `Browse one JCPenney category by its path or URL (Dresses, Sheets, Women's Boots...), with the same filters and sorts as search_jcpenney. The path needs its id=cat... part, the way jcpenney.com /g/ category links and a response's breadcrumbs carry it. ${GRID_SHORT}. Also returns the category's name, id, path, URL and breadcrumbs. A department page (dept...) lists no products by itself: it needs a deal or another filter. 1 credit.`, {
|
|
61
|
+
path: z.string().min(1).max(800).optional()
|
|
62
|
+
.describe("A JCPenney category path with its id=cat... part, e.g. '/g/women/dresses?id=cat100210008'."),
|
|
63
|
+
url: z.string().min(1).max(1200).optional()
|
|
64
|
+
.describe("A jcpenney.com category URL. Filters, a sort or a page in the URL are kept."),
|
|
65
|
+
brand: brandFilter(),
|
|
66
|
+
deal: dealFilter(),
|
|
67
|
+
...gridFields,
|
|
68
|
+
}, post("category"));
|
|
69
|
+
server.tool("get_jcpenney_brand", `Every JCPenney product of one brand by name (Nike, St. John's Bay, Carter's...) or a brand page URL, with the same filters and sorts as search_jcpenney (except brand). ${GRID_SHORT}. Also returns the brand's name, facet value and URL. An unknown brand is a 404. 1 credit.`, {
|
|
70
|
+
brand: z.string().min(1).max(100).optional()
|
|
71
|
+
.describe("A brand name as JCPenney lists it in the Brand facet, e.g. 'Nike', \"St. John's Bay\", \"Carter's\"."),
|
|
72
|
+
url: z.string().min(1).max(1200).optional()
|
|
73
|
+
.describe("A jcpenney.com brand page URL, e.g. 'https://www.jcpenney.com/g/brands/nike?id=cat11100023787' (JCPenney's curated brand page; its assortment can differ slightly from the brand name listing)."),
|
|
74
|
+
deal: dealFilter(),
|
|
75
|
+
...gridFields,
|
|
76
|
+
}, post("brand"));
|
|
77
|
+
server.tool("get_jcpenney_deals", `JCPenney deal listings across all products or one department: Clearance (default), Sale, Black Friday deals, Big Buy, Limited Time Special, Best Value, Gotta Have It, Closeout, Buy 1 Get 1, or any Deals & Promotions label, with the same filters and sorts as search_jcpenney. ${GRID_SHORT}. Seasonal labels (black_friday) list nothing once the event ends. To track clearance prices over time, poll and store your own: there is no price history. 1 credit.`, {
|
|
78
|
+
type: z.enum(DEAL_TYPES).optional()
|
|
79
|
+
.describe("clearance (default), sale, black_friday, big_buy, limited_time_special, best_value, gotta_have_it, closeout or bogo (every Buy 1 Get 1 offer)."),
|
|
80
|
+
label: z.string().min(1).max(120).optional()
|
|
81
|
+
.describe("Any Deals & Promotions label verbatim from a previous response's facets (s1_deals_and_promotions), instead of type, e.g. 'BUY 1 GET 1 50% OFF'."),
|
|
82
|
+
department: z.string().regex(/^(?:cat|dept)\d{5,16}$/i).optional()
|
|
83
|
+
.describe("Limit the deal to one department or category id (dept... / cat..., from breadcrumbs or a category URL), e.g. 'dept20000011'."),
|
|
84
|
+
brand: brandFilter(),
|
|
85
|
+
...gridFields,
|
|
86
|
+
}, post("deals"));
|
|
87
|
+
server.tool("get_jcpenney_stores", `JCPenney stores near a US or Puerto Rico ZIP code, a city + state or a point (lat + lng), within 25 miles by default (up to 100), paged: store_id, name, address, city, state, ZIP, phone, lat / lng, distance in miles, weekly opening hours, timezone, services (Curbside Pickup, salon, portrait studio, JCPenney Beauty...), curbside and in-store pickup directions, bookable appointments (Sephora, salon) and the store page URL. Pass one location. 1 credit.`, {
|
|
88
|
+
zip: zip().optional()
|
|
89
|
+
.describe("US or Puerto Rico ZIP code to search around, e.g. '75024'."),
|
|
90
|
+
city: z.string().min(1).max(60).optional()
|
|
91
|
+
.describe("City (with state), instead of zip, e.g. 'Austin'."),
|
|
92
|
+
state: z.string().length(2).optional()
|
|
93
|
+
.describe("2-letter state code (with city), e.g. 'TX'."),
|
|
94
|
+
lat: z.number().min(-90).max(90).optional()
|
|
95
|
+
.describe("Latitude (with lng), instead of zip."),
|
|
96
|
+
lng: z.number().min(-180).max(180).optional()
|
|
97
|
+
.describe("Longitude (with lat)."),
|
|
98
|
+
radius: z.number().int().min(1).max(100).optional()
|
|
99
|
+
.describe("Search radius in miles, 1-100. Defaults to 25."),
|
|
100
|
+
page: z.number().int().min(1).max(50).optional()
|
|
101
|
+
.describe("Results page, 1-based. Defaults to 1."),
|
|
102
|
+
page_size: z.number().int().min(1).max(20).optional()
|
|
103
|
+
.describe("Stores per page, 1-20. Defaults to 10."),
|
|
104
|
+
}, post("stores"));
|
|
105
|
+
server.tool("get_jcpenney_store_availability", `Real unit counts for one JCPenney SKU at the 5 nearest stores to a US or Puerto Rico ZIP code (or lat + lng): per store quantity, status (in_stock, low, out_of_stock, not_stocked), when the count was refreshed (updated_at), and the store's address, phone, distance and hours. Also returns how many of them have it (stores_with_stock) and total_quantity. in_stock_only drops the stores that have none. Take sku from get_jcpenney_product variants[].sku. 1 credit.`, {
|
|
106
|
+
sku: z.union([z.string().regex(/^\d{8,16}$/), z.number().int().positive()])
|
|
107
|
+
.describe("A JCPenney SKU id: a product's variants[].sku (or a search result's sku_id / colors[].sku_id), e.g. '84630160042'."),
|
|
108
|
+
zip: zip().optional()
|
|
109
|
+
.describe("US or Puerto Rico ZIP code: the 5 nearest stores are checked, e.g. '90012'."),
|
|
110
|
+
lat: z.number().min(-90).max(90).optional()
|
|
111
|
+
.describe("Latitude (with lng), instead of zip."),
|
|
112
|
+
lng: z.number().min(-180).max(180).optional()
|
|
113
|
+
.describe("Longitude (with lat)."),
|
|
114
|
+
radius: z.number().int().min(1).max(100).optional()
|
|
115
|
+
.describe("Search radius in miles. Defaults to 25."),
|
|
116
|
+
in_stock_only: z.boolean().optional()
|
|
117
|
+
.describe("Drop the stores (of the 5 nearest) that have none."),
|
|
118
|
+
}, post("store-availability"));
|
|
119
|
+
server.tool("get_jcpenney_suggestions", `The jcpenney.com search-box suggestions for a partial query: keyword completions with their search URL and, where JCPenney offers them, department refinements (nike shoes women -> sneakers, running shoes...). Useful for keyword research and for building queries for search_jcpenney. 1 credit.`, {
|
|
120
|
+
query: z.string().min(1).max(100)
|
|
121
|
+
.describe("What the shopper has typed so far, e.g. 'jea'."),
|
|
122
|
+
}, post("suggestions"));
|
|
123
|
+
server.tool("get_jcpenney_coupons", `Today's public JCPenney coupons: code (null for in-store offers that need none), channel (online, in store or both), headline and details of each offer, start and end dates, the full disclaimer with its exclusions, and the URL of the eligible products. Public codes only, no account offers or JCPenney Rewards balances. No parameters. 1 credit.`, {}, post("coupons"));
|
|
124
|
+
const productTarget = {
|
|
125
|
+
product_id: productId().optional()
|
|
126
|
+
.describe("A JCPenney product id (ppr / ppm / pp + digits): a search result's id, the last part of a product URL, e.g. 'ppr5008604049'."),
|
|
127
|
+
url: z.string().min(1).max(800).optional()
|
|
128
|
+
.describe("A jcpenney.com product URL (its product id is used). Alternative to product_id."),
|
|
129
|
+
};
|
|
130
|
+
server.tool("get_jcpenney_reviews", `Real customer review text of one jcpenney.com (US) product by id or URL, up to 98 per call (default 38), sorted most recent (default), most helpful, highest or lowest rating, or relevance, optionally only one star rating. Returns the product's review statistics: total_reviews (every language), displayed_reviews (the English reviews JCPenney lists and pages through, often fewer than total_reviews), average_rating, rating_distribution (1-5), recommended_percent, secondary_ratings_averages (Quality, Value, Apparel...), photo_count, and matching_reviews for the sort and filter. Each review has id, rating, title, text, author nickname, location, submitted_at and updated_at, recommended, helpful and unhelpful votes, verified_purchaser and incentivized badges, syndicated with syndication_source (the brand site it came from, e.g. sharkninja.com), customer photos and videos, secondary ratings, the brand's public response (name, department, text, date) and the original product name. Reviewer age, gender and IP are never returned. Slower than the other JCPenney tools: usually 15-90s, up to about 3 minutes; failed calls are not charged. A product with no reviews returns an empty list; an unknown product is a 404. 1 credit.`, {
|
|
131
|
+
...productTarget,
|
|
132
|
+
sort: z.enum(REVIEW_SORTS).optional()
|
|
133
|
+
.describe("most_recent (default), most_helpful, highest_rating, lowest_rating or relevance: the review list's own sort menu."),
|
|
134
|
+
rating: z.number().int().min(1).max(5).optional()
|
|
135
|
+
.describe("Only reviews with this star rating (1-5), e.g. 1 for the critical ones. A rating nobody gave returns an empty list."),
|
|
136
|
+
max_reviews: z.number().int().min(8).max(98).optional()
|
|
137
|
+
.describe("Reviews to return, 8-98. Defaults to 38. JCPenney loads 8, then 30 more per page, so 8, 38, 68 and 98 are the natural sizes; larger values take longer."),
|
|
138
|
+
}, post("reviews"));
|
|
139
|
+
server.tool("get_jcpenney_questions", `Customer questions and every answer for one jcpenney.com (US) product by id or URL, up to 50 questions per call (default 10), newest answers first (JCPenney's order; there is no sort option). Returns total_questions and total_answers. Each question has id, question, details, author, submitted_at, answer_count and helpful_votes; each answer has id, text, author, author_type (brand for the manufacturer's product experts, retailer for JCPenney staff, ai for AI-generated answers, customer), ai_label (AI-Generated / AI-Assisted when JCPenney labels it), is_best_answer, submitted_at and helpful / unhelpful votes. Answerer IPs are never returned. Slower than the other JCPenney tools: usually 15-90s, up to about 3 minutes; failed calls are not charged. A product with no questions returns an empty list; an unknown product is a 404. 1 credit.`, {
|
|
140
|
+
...productTarget,
|
|
141
|
+
max_questions: z.number().int().min(10).max(50).optional()
|
|
142
|
+
.describe("Questions to return, 10-50 (10 per page). Defaults to 10."),
|
|
143
|
+
}, post("questions"));
|
|
144
|
+
}
|
|
145
|
+
//# sourceMappingURL=jcpenney.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"jcpenney.js","sourceRoot":"","sources":["../../src/tools/jcpenney.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAGxB,OAAO,EAAE,cAAc,EAAE,MAAM,sBAAsB,CAAC;AACtD,OAAO,EAAE,YAAY,EAAE,MAAM,yBAAyB,CAAC;AAEvD,8EAA8E;AAC9E,8EAA8E;AAC9E,4EAA4E;AAC5E,8EAA8E;AAC9E,wEAAwE;AACxE,2CAA2C;AAC3C,wEAAwE;AAExE,MAAM,KAAK,GAAG,CAAC,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CAAC;KACvK,EACD,IAAI,CAAC,SAAS,CAAC,CAChB,CAAC;IAEF,MAAM,CAAC,IAAI,CACT,wBAAwB,EACxB,80BAA80B,EAC90B;QACE,GAAG,aAAa;QAChB,aAAa,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,GAAG,EAAE,CAAC,GAAG,CAAC,EAAE,CAAC,CAAC,GAAG,CAAC,EAAE,CAAC,CAAC,QAAQ,EAAE;aACvD,QAAQ,CAAC,2DAA2D,CAAC;KACzE,EACD,IAAI,CAAC,WAAW,CAAC,CAClB,CAAC;AACJ,CAAC"}
|
package/package.json
CHANGED
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@scavio/mcp-server",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.44.0",
|
|
4
4
|
"mcpName": "io.github.scavio-ai/scavio-mcp",
|
|
5
|
-
"description": "MCP server connecting AI agents to Scavio: web search, page extraction, and structured e-commerce, social, travel, jobs, real-estate, app-store, ad-library and company-filing data.
|
|
5
|
+
"description": "MCP server connecting AI agents to Scavio: web search, page extraction, and structured e-commerce, social, travel, jobs, real-estate, app-store, ad-library and company-filing data. 437 tools across 67 platforms plus Extract, site map, crawl and batch extraction, one API key.",
|
|
6
6
|
"type": "module",
|
|
7
7
|
"license": "MIT",
|
|
8
8
|
"author": "Scavio",
|
|
@@ -59,6 +59,10 @@
|
|
|
59
59
|
"kohls",
|
|
60
60
|
"kohls-api",
|
|
61
61
|
"kohls-clearance",
|
|
62
|
+
"jcpenney",
|
|
63
|
+
"jcpenney-api",
|
|
64
|
+
"jcpenney-coupons",
|
|
65
|
+
"jcpenney-reviews",
|
|
62
66
|
"mercadolibre",
|
|
63
67
|
"mercado-libre",
|
|
64
68
|
"tiktok",
|