Skip to main content
Glama

openapi_v2_markets_search

Markets Search V2

Search market data by category with aggregated demand, competition, and pricing metrics.

Use this to evaluate market size and competition before entering a niche. Example: search "Pet Supplies" with sampleAvgMonthlySalesMin >= 200 to find categories with proven demand. Data is based on top-100 product samples per category from the latest daily snapshot; results paginated (max 100 per page). Related: /products/search for product-level data in a category.

Responses:

200: Successful Response (Success Response) Content-Type: application/json

Example Response:

{
  "success": true,
  "meta": {
    "requestId": "Requestid",
    "timestamp": "Timestamp"
  }
}

Output Schema:

{
  "properties": {
    "success": {
      "type": "boolean",
      "title": "Success",
      "description": "Whether the request was successful",
      "default": true
    },
    "data": {
      "title": "Data",
      "description": "Response data payload"
    },
    "error": {
      "description": "Error details if request failed"
    },
    "meta": {
      "description": "Metadata for API responses.\n\nCredit fields follow the ADR-0003 parallel-fields strategy (Option 3):\n- `credits_remaining` / `credits_consumed` (int): legacy fields, rounded\n  to whole credits, kept for zero-breaking-change to existing SDK clients.\n- `credits_remaining_exact` / `credits_consumed_exact` (float): new\n  precision-aware fields for clients that opt in to decimal credits.\n\nSee ADR-0003 decision 5 and the \u00a78 deprecation timeline.\n\nTODO(2026-11, ADR-0003 \u00a78 +6mo): mark `credits_remaining` /\n`credits_consumed` as `deprecated=True` in their Field() definitions\nand announce in customer changelog.\nTODO(2027-05, ADR-0003 \u00a78 +12mo): remove the legacy int fields via a\nmajor-version bump of the OpenAPI surface.",
      "properties": {
        "requestId": {
          "type": "string",
          "title": "Requestid",
          "description": "Unique request identifier"
        },
        "timestamp": {
          "type": "string",
          "title": "Timestamp",
          "description": "Response timestamp in ISO 8601 format"
        },
        "total": {
          "title": "Total",
          "description": "Total number of records"
        },
        "page": {
          "title": "Page",
          "description": "Current page number"
        },
        "pageSize": {
          "title": "Pagesize",
          "description": "Number of records per page"
        },
        "totalPages": {
          "title": "Totalpages",
          "description": "Total number of pages"
        },
        "creditsRemaining": {
          "title": "Creditsremaining",
          "description": "Remaining API credits (rounded to whole credits; see creditsRemainingExact for precise value)"
        },
        "creditsConsumed": {
          "title": "Creditsconsumed",
          "description": "Credits consumed by this request (rounded; see creditsConsumedExact for precise value)"
        },
        "creditsRemainingExact": {
          "title": "Creditsremainingexact",
          "description": "Remaining API credits, precise to 1 decimal place"
        },
        "creditsConsumedExact": {
          "title": "Creditsconsumedexact",
          "description": "Credits consumed by this request, precise to 1 decimal place"
        },
        "tokensUsage": {
          "description": "Provider token-usage block \u2014 populated on terminal video polls only, null on every non-video endpoint. See TokensUsage for its fields."
        }
      },
      "type": "object",
      "required": [
        "requestId",
        "timestamp"
      ],
      "title": "ResponseMeta"
    }
  },
  "type": "object",
  "required": [
    "meta"
  ],
  "title": "OpenApiResponse[list[Market]]",
  "examples": []
}

422: Validation Error Content-Type: application/json

Example Response:

{
  "detail": [
    {
      "loc": [],
      "msg": "Message",
      "type": "Error Type",
      "ctx": {}
    }
  ]
}

Output Schema:

{
  "properties": {
    "detail": {
      "items": {
        "properties": {
          "loc": {
            "items": {},
            "type": "array",
            "title": "Location"
          },
          "msg": {
            "type": "string",
            "title": "Message"
          },
          "type": {
            "type": "string",
            "title": "Error Type"
          },
          "input": {
            "title": "Input"
          },
          "ctx": {
            "type": "object",
            "title": "Context"
          }
        },
        "type": "object",
        "required": [
          "loc",
          "msg",
          "type"
        ],
        "title": "ValidationError"
      },
      "type": "array",
      "title": "Detail"
    }
  },
  "type": "object",
  "title": "HTTPValidationError"
}

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
pageNoPage number
topNNoNumber of top products to analyze: '3', '5', '10', or '20'. Affects top* response fields (e.g., topAvgMonthlySales)10
sortByNoSort field (matches response field names)sampleAvgMonthlyRevenue
pageSizeNoPage size
dateRangeNoAggregation window for metrics like monthly sales, revenue, and rating count. '30d' (default) — last 30 days. 'YYYY-MM' — that calendar month, e.g. '2026-04'. Available months: '2026-02' up to the most recent completed month.30d
sortOrderNoSort direction: asc or descdesc
sampleTypeNoSampling method for market metrics: 'bySale100' = analyze top 100 products by sales volume, 'byBsr100' = top 100 by BSR rank, 'avg' = category-wide averagebySale100
marketplaceNoAmazon marketplace code. Only 'US' is currently supported.US
categoryPathNoCategory hierarchy from root. Example: ['Electronics', 'Computers', 'Laptops'].
topAvgBsrMaxNoMaximum Top N average main-category BSR.
topAvgBsrMinNoMinimum Top N average main-category BSR.
categoryKeywordNoFilter by category name keyword (matches any level in category hierarchy, e.g., 'Electronics' or 'Laptops')
sampleAvgBsrMaxNoMaximum sample average main-category BSR.
sampleAvgBsrMinNoMinimum sample average main-category BSR (lower = better).
topSalesRateMaxNoMaximum Top N sales share as decimal.
topSalesRateMinNoMinimum Top N sales share as decimal. Example: 0.5 = 50%.
newProductPeriodNoDefine 'new product' as listed within X months: '1', '3', '6', or '12'. Affects sampleNewSku* response fields3
sampleAmzRateMaxNoMaximum sample Amazon-sold product rate as decimal.
sampleAmzRateMinNoMinimum sample Amazon-sold product rate as decimal.
sampleFbaRateMaxNoMaximum sample FBA product rate as decimal.
sampleFbaRateMinNoMinimum sample FBA product rate as decimal.
totalSkuCountMaxNoMaximum total SKU count in category.
totalSkuCountMinNoMinimum total SKU count in category.
sampleAvgPriceMaxNoMaximum sample average price.
sampleAvgPriceMinNoMinimum sample average price. Example: 10.00.
sampleSkuCountMaxNoMaximum sample SKU count.
sampleSkuCountMinNoMinimum sample SKU count.
sampleAvgRatingMaxNoMaximum sample average star rating (0.0–5.0).
sampleAvgRatingMinNoMinimum sample average star rating (0.0–5.0).
sampleBrandCountMaxNoMaximum sample unique brand count.
sampleBrandCountMinNoMinimum sample unique brand count.
sampleNewSkuRateMaxNoMaximum sample new product rate as decimal.
sampleNewSkuRateMinNoMinimum sample new product rate as decimal.
sampleNewSkuCountMaxNoMaximum sample new product count.
sampleNewSkuCountMinNoMinimum sample new product count.
sampleSellerCountMaxNoMaximum sample unique seller count.
sampleSellerCountMinNoMinimum sample unique seller count.
topBrandSalesRateMaxNoMaximum Top N brand concentration ratio as decimal.
topBrandSalesRateMinNoMinimum Top N brand concentration ratio as decimal.
topAvgMonthlySalesMaxNoMaximum Top N average monthly sales.
topAvgMonthlySalesMinNoMinimum Top N average monthly sales. Units sold.
topSellerSalesRateMaxNoMaximum Top N seller concentration ratio as decimal.
topSellerSalesRateMinNoMinimum Top N seller concentration ratio as decimal.
sampleAvgRatingCountMaxNoMaximum sample average rating count per product.
sampleAvgRatingCountMinNoMinimum sample average rating count per product.
sampleNewSkuAvgPriceMaxNoMaximum new product average price.
sampleNewSkuAvgPriceMinNoMinimum new product average price.
topAvgMonthlyRevenueMaxNoMaximum Top N average monthly revenue.
topAvgMonthlyRevenueMinNoMinimum Top N average monthly revenue.
sampleAvgMonthlySalesMaxNoMaximum sample average monthly sales. Units sold.
sampleAvgMonthlySalesMinNoMinimum sample average monthly sales. Units sold. Example: 100.
sampleAvgPackageVolumeMaxNoMaximum sample average package volume in in³.
sampleAvgPackageVolumeMinNoMinimum sample average package volume in in³.
sampleAvgPackageWeightMaxNoMaximum sample average package weight in oz.
sampleAvgPackageWeightMinNoMinimum sample average package weight in oz.
sampleAvgMonthlyRevenueMaxNoMaximum sample average monthly revenue.
sampleAvgMonthlyRevenueMinNoMinimum sample average monthly revenue. Example: 5000.00.
sampleNewSkuAvgMonthlySalesMaxNoMaximum new product average monthly sales.
sampleNewSkuAvgMonthlySalesMinNoMinimum new product average monthly sales.

TDQS

A4.1/5.0
Behavior3/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

No annotations provided, so description carries behavioral burden. It discloses data source (top-100 sample), recency (daily snapshot), and pagination (max 100/page). However, it omits critical behavioral constraints like unsupported `sampleType` values (byBsr100, avg) and that marketplace only supports 'US' — both known from schema but not highlighted in prose.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness5/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The description is compact, front-loaded with purpose, then usage, then data facts. No fluff; each sentence adds value. Response schemas are provided separately and do not bloat the textual description.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness3/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

For a complex tool with 59 parameters and no annotations, the description offers a use case, data scope, and pagination info, and includes response schemas. However, it fails to caution about unsupported parameter values (sampleType) or the US-only marketplace, which are critical for correct invocation. It also doesn't explain the overall filter semantics beyond the schema.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters3/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema coverage is 100% (all 59 params have descriptions). The description adds a usage example referencing `sampleAvgMonthlySalesMin`, but does not provide additional semantics beyond the schema's already detailed parameter descriptions. Baseline 3 is appropriate.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

Description clearly states 'Search market data by category with aggregated demand, competition, and pricing metrics' — specific verb and resource. It distinguishes from sibling `/products/search` by pointing to product-level data.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines5/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

Explicitly says to use for evaluating market size/competition before entering a niche, provides an example with a concrete filter, and names a related endpoint for alternative data. Clear when-to-use guidance with a concrete scenario.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

Try in Browser

Glama MCP Gateway

Add one secure layer between your agents and this server.

TDQS

B3.2/5.0
Disambiguation2/5

Several tools have unclear boundaries, most notably openapi_v2_competitor_product_keywords and openapi_v2_product_traffic_terms, which have identical descriptions. The deprecated openapi_v2_realtime_product duplicates openapi_v3_realtime_product, and openapi_v2_image_embedding overlaps heavily with openapi_v2_fashion_image_embedding.

Naming Consistency2/5

Naming is inconsistent: a few tools follow a clean verb_noun pattern (create_video_asset, list_video_assets, poll_video_task), while the vast majority are prefixed with openapi_v2_/openapi_v3_ followed by nouns or mixed verbs. The route-style prefix is not a meaningful verb and creates an arbitrary split across the tool set.

Tool Count2/5

49 tools is far beyond the well-scoped range and spans multiple unrelated domains (Amazon product data, TikTok commerce, fashion vision, web scraping, video generation, billing). The server appears to be an entire REST API surface exposed wholesale rather than a curated set of capabilities.

Completeness3/5

Each domain is individually fairly complete (Amazon search/reviews/keywords/VoC, TikTok search, web tools, video generation), but there are notable gaps: video assets lack update/delete, video tasks lack cancel/list, and there is no singular 'get daily product by ASIN' alongside the realtime variants. The broad scope makes it hard to verify full lifecycle coverage across all domains.

Resources