{
  "openapi": "3.0.1",
  "info": {
    "title": "KOMEHYO Scraper – Japan Luxury & Brand Resale (コメ兵)",
    "description": "Scrape KOMEHYO (komehyo.jp, コメ兵) — Japan's largest luxury & brand reuse store: bags, watches, jewelry, fashion, cameras. Search by keyword, brand, category, condition rank, price or new arrivals; get normalized size, condition, measurements and images. JP Data Works series.",
    "version": "0.2",
    "x-build-id": "Ky6eXvc7gEbVaOmR4"
  },
  "servers": [
    {
      "url": "https://api.apify.com/v2"
    }
  ],
  "paths": {
    "/acts/tokyo-select-jp~komehyo-search-scraper/run-sync-get-dataset-items": {
      "post": {
        "operationId": "run-sync-get-dataset-items-tokyo-select-jp-komehyo-search-scraper",
        "x-openai-isConsequential": false,
        "summary": "Executes an Actor, waits for its completion, and returns Actor's dataset items in response.",
        "tags": [
          "Run Actor"
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/inputSchema"
              }
            }
          }
        },
        "parameters": [
          {
            "name": "token",
            "in": "query",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "Enter your Apify token here"
          }
        ],
        "responses": {
          "200": {
            "description": "OK"
          }
        }
      }
    },
    "/acts/tokyo-select-jp~komehyo-search-scraper/runs": {
      "post": {
        "operationId": "runs-sync-tokyo-select-jp-komehyo-search-scraper",
        "x-openai-isConsequential": false,
        "summary": "Executes an Actor and returns information about the initiated run in response.",
        "tags": [
          "Run Actor"
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/inputSchema"
              }
            }
          }
        },
        "parameters": [
          {
            "name": "token",
            "in": "query",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "Enter your Apify token here"
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/runsResponseSchema"
                }
              }
            }
          }
        }
      }
    },
    "/acts/tokyo-select-jp~komehyo-search-scraper/run-sync": {
      "post": {
        "operationId": "run-sync-tokyo-select-jp-komehyo-search-scraper",
        "x-openai-isConsequential": false,
        "summary": "Executes an Actor, waits for completion, and returns the OUTPUT from Key-value store in response.",
        "tags": [
          "Run Actor"
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/inputSchema"
              }
            }
          }
        },
        "parameters": [
          {
            "name": "token",
            "in": "query",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "Enter your Apify token here"
          }
        ],
        "responses": {
          "200": {
            "description": "OK"
          }
        }
      }
    }
  },
  "components": {
    "schemas": {
      "inputSchema": {
        "type": "object",
        "properties": {
          "keywords": {
            "title": "Keywords",
            "uniqueItems": true,
            "type": "array",
            "description": "Simple keyword searches, one per line — brand names, item types, model numbers, Japanese or English (e.g. `KAPITAL`, `ルイヴィトン モノグラム`, `Rolex Datejust`). Each keyword is one search and inherits the defaults below. Optional when `searches` is set.",
            "default": [],
            "items": {
              "type": "string"
            }
          },
          "searches": {
            "title": "Structured searches",
            "type": "array",
            "description": "Advanced searches as JSON objects. Every field is optional, but each search needs at least one of `keyword`, `brand`, `brandId`, `categoryPath`, `categoryCode`.\n\n- `keyword` — free text.\n- `brand` — brand name as listed on komehyo.jp (English or katakana, e.g. `KAPITAL`, `キャピタル`, `LOUIS VUITTON`); resolved to the site's brand id. `brandId` — that id directly (e.g. 1734 = KAPITAL).\n- `categoryPath` — `mens`, `ladies`, `bags`, `watches mens`, `jewelry`, `camera`, `guitar`, `kimono`, `stationery`, or a path such as `mens > bottoms > jeans`, `メンズファッション > トップス > Tシャツ`, `bags > トートバッグ`; `categoryCode` — the site's dispNo code (009001009003 = メンズファッション > ボトムス).\n- `gender` — `mens`, `ladies`, `any`.\n- `priceMinJpy` / `priceMaxJpy` — exact bounds (applied client-side; the site only has fixed buckets, which are used when the range fits one).\n- `rankMin` — minimum condition rank 2–6 (6 = 新品 / 未使用品, 5 = 中古品S, 4 = 中古品A, 3 = 中古品B, 2 = 中古品C), or `rankIds` — the site's rank ids 1 新品, 2 未使用品, 3 中古品S, 4 中古品A, 5 中古品B, 6 中古品C.\n- `sort` — `recommended` (default), `newest`, `priceAsc`, `priceDesc`, `discountAsc`, `discountDesc`.\n- `includeSoldOut` — also return SOLD OUT items (default false).\n- `storeName` — keep only items held by a shop whose name contains this text (client-side).\n- `excludeWords` — drop items whose title contains any of these (client-side).\n\nValues set here override the defaults below.",
            "items": {
              "type": "object",
              "properties": {
                "keyword": {
                  "type": "string",
                  "title": "Keyword",
                  "description": "Free-text search."
                },
                "brand": {
                  "type": "string",
                  "title": "Brand name",
                  "description": "Brand name as listed on komehyo.jp (English or katakana); resolved to brandId."
                },
                "brandId": {
                  "type": "integer",
                  "title": "Brand id",
                  "description": "Site brand id (brandNo), e.g. 1734 = KAPITAL."
                },
                "categoryPath": {
                  "type": "string",
                  "title": "Category path",
                  "description": "Top category or path, e.g. `mens > bottoms > jeans`, `メンズファッション > トップス`, `bags`, `watches mens`."
                },
                "categoryCode": {
                  "type": "string",
                  "title": "Category code",
                  "description": "Site dispNo code, e.g. 009001009003."
                },
                "gender": {
                  "type": "string",
                  "title": "Gender",
                  "description": "mens, ladies or any.",
                  "enum": [
                    "mens",
                    "ladies",
                    "any"
                  ]
                },
                "priceMinJpy": {
                  "type": "integer",
                  "title": "Min price (JPY)",
                  "description": "Lower price bound in JPY.",
                  "minimum": 0
                },
                "priceMaxJpy": {
                  "type": "integer",
                  "title": "Max price (JPY)",
                  "description": "Upper price bound in JPY.",
                  "minimum": 0
                },
                "rankMin": {
                  "type": "integer",
                  "title": "Min condition rank",
                  "description": "Minimum condition rank 2–6 (6 = 新品 / 未使用品).",
                  "minimum": 2,
                  "maximum": 6
                },
                "rankIds": {
                  "type": "array",
                  "title": "Rank ids",
                  "description": "Site rank ids 1 新品, 2 未使用品, 3 中古品S, 4 中古品A, 5 中古品B, 6 中古品C; overrides rankMin.",
                  "items": {
                    "type": "integer"
                  }
                },
                "sort": {
                  "type": "string",
                  "title": "Sort",
                  "description": "recommended (default), newest, priceAsc, priceDesc, discountAsc, discountDesc.",
                  "enum": [
                    "recommended",
                    "newest",
                    "priceAsc",
                    "priceDesc",
                    "discountAsc",
                    "discountDesc"
                  ]
                },
                "includeSoldOut": {
                  "type": "boolean",
                  "title": "Include sold out",
                  "description": "Also return SOLD OUT items."
                },
                "storeName": {
                  "type": "string",
                  "title": "Store name (client-side filter)",
                  "description": "Keep only items whose shop name contains this text."
                },
                "excludeWords": {
                  "type": "array",
                  "title": "Exclude words (client-side)",
                  "description": "Drop items whose title contains any of these words.",
                  "items": {
                    "type": "string"
                  }
                }
              }
            },
            "default": []
          },
          "outputMode": {
            "title": "Output mode",
            "enum": [
              "items",
              "summary",
              "both"
            ],
            "type": "string",
            "description": "`items` (default): one dataset row per listing. `summary`: one market-summary row per search instead of the listings — sample size, price min / p25 / median / mean / p75 / max, price histogram, status / condition-rank / size / brand / category breakdowns, cheapest listings — billed once per search as the `summary` event (the sampled listings are not billed). `both`: listings plus the summary row.",
            "default": "items"
          },
          "sort": {
            "title": "Default sort order",
            "enum": [
              "recommended",
              "newest",
              "priceAsc",
              "priceDesc",
              "discountAsc",
              "discountDesc"
            ],
            "type": "string",
            "description": "Applied to every keyword / search without its own `sort`.",
            "default": "recommended"
          },
          "gender": {
            "title": "Default gender",
            "enum": [
              "any",
              "mens",
              "ladies"
            ],
            "type": "string",
            "description": "Applied to every search without its own `gender`.",
            "default": "any"
          },
          "priceMinJpy": {
            "title": "Default min price (JPY)",
            "minimum": 0,
            "type": "integer",
            "description": "Lower price bound for every search without its own `priceMinJpy`."
          },
          "priceMaxJpy": {
            "title": "Default max price (JPY)",
            "minimum": 0,
            "type": "integer",
            "description": "Upper price bound for every search without its own `priceMaxJpy`."
          },
          "rankMin": {
            "title": "Default min condition rank",
            "minimum": 2,
            "maximum": 6,
            "type": "integer",
            "description": "Only listings with this condition rank or better: 6 新品 / 未使用品, 5 中古品S (close to unused), 4 中古品A (little sign of use), 3 中古品B (visible use), 2 中古品C (heavy use). Leave empty for all."
          },
          "includeSoldOut": {
            "title": "Include sold-out items",
            "type": "boolean",
            "description": "Also return listings marked SOLD OUT (useful for price history).",
            "default": false
          },
          "excludeWords": {
            "title": "Default exclude words (client-side)",
            "type": "array",
            "description": "Drop items whose title contains any of these words (case-insensitive).",
            "default": [],
            "items": {
              "type": "string"
            }
          },
          "maxItemsPerSearch": {
            "title": "Max items per search",
            "minimum": 1,
            "maximum": 2000,
            "type": "integer",
            "description": "Stop after this many listings for each keyword / search. The site shows 50 listings per page.",
            "default": 100
          },
          "maxTotalItems": {
            "title": "Max total items",
            "minimum": 1,
            "type": "integer",
            "description": "Hard cap on listings saved in this run across all searches. Leave empty for no cap (Max total charge still applies)."
          },
          "dedupeAcrossSearches": {
            "title": "Deduplicate across searches",
            "type": "boolean",
            "description": "Save a listing only once when several searches return it.",
            "default": true
          },
          "enrichDetail": {
            "title": "Enrich with product pages",
            "type": "boolean",
            "description": "Open each product page for model number, condition note, gender, measurements in cm, material, colour, category path, description, return policy and the full-size gallery. One extra request and one `detail-page` event per item.",
            "default": false
          },
          "maxDetailPages": {
            "title": "Max product pages per run",
            "minimum": 0,
            "maximum": 5000,
            "type": "integer",
            "description": "Cap on product-page requests per run. Items beyond the cap are returned without detail fields.",
            "default": 100
          },
          "requestDelayMs": {
            "title": "Delay between requests (ms)",
            "minimum": 1000,
            "maximum": 60000,
            "type": "integer",
            "description": "Minimum pause between requests. Please keep ≥ 3000.",
            "default": 3000
          },
          "proxyConfiguration": {
            "title": "Proxy configuration",
            "type": "object",
            "description": "Optional Apify Proxy or your own proxies. Not needed under normal use."
          },
          "outputFields": {
            "title": "Output fields",
            "type": "array",
            "description": "Keep only these top-level fields in the output (`itemId` and `url` are always kept). Leave empty for all fields.",
            "default": [],
            "items": {
              "type": "string"
            }
          }
        }
      },
      "runsResponseSchema": {
        "type": "object",
        "properties": {
          "data": {
            "type": "object",
            "properties": {
              "id": {
                "type": "string"
              },
              "actId": {
                "type": "string"
              },
              "userId": {
                "type": "string"
              },
              "startedAt": {
                "type": "string",
                "format": "date-time",
                "example": "2025-01-08T00:00:00.000Z"
              },
              "finishedAt": {
                "type": "string",
                "format": "date-time",
                "example": "2025-01-08T00:00:00.000Z"
              },
              "status": {
                "type": "string",
                "example": "READY"
              },
              "meta": {
                "type": "object",
                "properties": {
                  "origin": {
                    "type": "string",
                    "example": "API"
                  },
                  "userAgent": {
                    "type": "string"
                  }
                }
              },
              "stats": {
                "type": "object",
                "properties": {
                  "inputBodyLen": {
                    "type": "integer",
                    "example": 2000
                  },
                  "rebootCount": {
                    "type": "integer",
                    "example": 0
                  },
                  "restartCount": {
                    "type": "integer",
                    "example": 0
                  },
                  "resurrectCount": {
                    "type": "integer",
                    "example": 0
                  },
                  "computeUnits": {
                    "type": "integer",
                    "example": 0
                  }
                }
              },
              "options": {
                "type": "object",
                "properties": {
                  "build": {
                    "type": "string",
                    "example": "latest"
                  },
                  "timeoutSecs": {
                    "type": "integer",
                    "example": 300
                  },
                  "memoryMbytes": {
                    "type": "integer",
                    "example": 1024
                  },
                  "diskMbytes": {
                    "type": "integer",
                    "example": 2048
                  }
                }
              },
              "buildId": {
                "type": "string"
              },
              "defaultKeyValueStoreId": {
                "type": "string"
              },
              "defaultDatasetId": {
                "type": "string"
              },
              "defaultRequestQueueId": {
                "type": "string"
              },
              "buildNumber": {
                "type": "string",
                "example": "1.0.0"
              },
              "containerUrl": {
                "type": "string"
              },
              "usage": {
                "type": "object",
                "properties": {
                  "ACTOR_COMPUTE_UNITS": {
                    "type": "integer",
                    "example": 0
                  },
                  "DATASET_READS": {
                    "type": "integer",
                    "example": 0
                  },
                  "DATASET_WRITES": {
                    "type": "integer",
                    "example": 0
                  },
                  "KEY_VALUE_STORE_READS": {
                    "type": "integer",
                    "example": 0
                  },
                  "KEY_VALUE_STORE_WRITES": {
                    "type": "integer",
                    "example": 1
                  },
                  "KEY_VALUE_STORE_LISTS": {
                    "type": "integer",
                    "example": 0
                  },
                  "REQUEST_QUEUE_READS": {
                    "type": "integer",
                    "example": 0
                  },
                  "REQUEST_QUEUE_WRITES": {
                    "type": "integer",
                    "example": 0
                  },
                  "DATA_TRANSFER_INTERNAL_GBYTES": {
                    "type": "integer",
                    "example": 0
                  },
                  "DATA_TRANSFER_EXTERNAL_GBYTES": {
                    "type": "integer",
                    "example": 0
                  },
                  "PROXY_RESIDENTIAL_TRANSFER_GBYTES": {
                    "type": "integer",
                    "example": 0
                  },
                  "PROXY_SERPS": {
                    "type": "integer",
                    "example": 0
                  },
                  "PROXY_UNBLOCKER_UNITS": {
                    "type": "integer",
                    "example": 0
                  }
                }
              },
              "usageTotalUsd": {
                "type": "number",
                "example": 0.00005
              },
              "usageUsd": {
                "type": "object",
                "properties": {
                  "ACTOR_COMPUTE_UNITS": {
                    "type": "integer",
                    "example": 0
                  },
                  "DATASET_READS": {
                    "type": "integer",
                    "example": 0
                  },
                  "DATASET_WRITES": {
                    "type": "integer",
                    "example": 0
                  },
                  "KEY_VALUE_STORE_READS": {
                    "type": "integer",
                    "example": 0
                  },
                  "KEY_VALUE_STORE_WRITES": {
                    "type": "number",
                    "example": 0.00005
                  },
                  "KEY_VALUE_STORE_LISTS": {
                    "type": "integer",
                    "example": 0
                  },
                  "REQUEST_QUEUE_READS": {
                    "type": "integer",
                    "example": 0
                  },
                  "REQUEST_QUEUE_WRITES": {
                    "type": "integer",
                    "example": 0
                  },
                  "DATA_TRANSFER_INTERNAL_GBYTES": {
                    "type": "integer",
                    "example": 0
                  },
                  "DATA_TRANSFER_EXTERNAL_GBYTES": {
                    "type": "integer",
                    "example": 0
                  },
                  "PROXY_RESIDENTIAL_TRANSFER_GBYTES": {
                    "type": "integer",
                    "example": 0
                  },
                  "PROXY_SERPS": {
                    "type": "integer",
                    "example": 0
                  },
                  "PROXY_UNBLOCKER_UNITS": {
                    "type": "integer",
                    "example": 0
                  }
                }
              }
            }
          }
        }
      }
    }
  }
}