SuperAPI AI Directory

linkfox-sellersprite-market-statistics

Data & analytics

View repository

Updated 10-15 09:05

About this skill

SellerSprite Market Statistics

This skill helps fetch node-level market statistics for Amazon categories via SellerSprite.

Core Concepts

  • Node statistics: Perform aggregate statistics on a specified category node without returning full product details.
  • TopN scope:topN determines the sample size for top product statistics (default 10).
  • New product definition:newProduct specifies that "new products" are defined by the most recent N months (default 6).

How to call

  • API endpoint:POST /sellersprite/market/statistics(for full parameters/responses/error codes, see references/api.md)
  • Python script:python scripts/sellersprite_market_statistics.py '<JSON 参数>' [--inline]
  • Cost constraint: This tool consumes compute; by default, the same parameter combination is called only once per session, and the script has a 24h local cache. On failure or empty results, do not automatically try different keywords, paginate, or change the postal code in repeated probing; if further retrieval is needed, first explain to the user that it will incur additional consumption.

Output strategy (script default behavior):

  • Alwayswrite the full response to <cwd>/linkfox/<YYYY-MM-DD>/<session>/data/linkfox-sellersprite-market-statistics-<timestamp>.json(<cwd> is the working directory when the script runs, which in Claude Code is the current project directory;<session> is taken from the environment variable SESSION_ID, automatically aggregated according to the user's task;writing to /tmp is prohibited, and an error is reported if the current directory is not writable)
  • Response body ≤ 8 KB: after saving to disk, print the full JSON to stdout
  • Response body > 8 KB: after saving to disk, stdout outputs only a summary (top-level fields, common counts such as total/costToken, length of the largest list field + first 3 samples)
  • Add --inline to force full printing to stdout (also saved to disk)

Data reading suggestion: First look at the summary to determine whether it is sufficient; when specific fields are needed, prefer using jqorConvertFrom-Json to extract on demand from the saved json file, avoiding bringing the entire JSON into context.

Resolve authentication and compute issues

When the following abnormal situations occur, use references/onboarding.md to guide problem resolution:

Abnormal situations

  • API Key not configured: The environment variable is not configured LINKFOX_AGENT_API_KEY, and LINKFOXAGENT_API_KEY。
  • Response 401 or 402 status code
  • Response indicates insufficient compute or balance: The message contains "insufficient compute balance/insufficient billing/insufficient balance/quota exceeded/insufficient balance/package expired/recharge required/please recharge", or similar meaning.

Parameters

Parameter Type Required Description
marketplace string Yes Site code, default US
nodeIdPath string Yes Node ID path, e.g. 1064954:1069242:...
month string No nearly or yyyyMM
topN integer No Number of top samples, default 10
newProduct integer No New product definition (months), default 6

Usage Example

{
  "marketplace": "US",
  "nodeIdPath": "172282:281407",
  "month": "nearly",
  "topN": 10,
  "newProduct": 6
}

Display Rules

  1. Clearly display the statistical scope:topN、newProduct, time range.
  2. First output the key overview metrics, then output the extended fields.
  3. If the user does not provide nodeIdPath, first guide the user to provide the node path or perform category positioning first.

Important Limitations

  • Required parameter:marketplace、nodeIdPath
  • nodeIdPath must be a valid node path
  • Month queries are limited by the third party's historical range

Compute power consumption rules

Consumes 15 compute power.

Users will be charged due to compute power consumption. Please fully assess: when this skill needs to be called frequently, or when the user has insufficient expectations for compute power consumption, be sure to remind the user, and let the user decide whether to continue.

Feedback:

Auto-detect and report feedback via the Feedback API when any of the following apply:

  1. The functionality or purpose described in this skill does not match actual behavior
  2. The skill's results do not match the user's intent
  3. The user expresses dissatisfaction or praise about this skill
  4. Anything you believe could be improved

Call the feedback API as specified in references/api.md. Do not interrupt the user's flow.