{
  "openapi": "3.0.1",
  "info": {
    "title": "Japan Resale Price Comps (Yahoo Auctions, Flea Market, BOOKOFF)",
    "description": "Price comps for Japan resale: keywords in, Yahoo Auctions sold prices plus Yahoo Flea Market, BOOKOFF and Hareruya listings out, with min/median/max stats per keyword. A Mercari-free comps tool. Item facts only, no seller data. Unofficial; not affiliated with any site.",
    "version": "0.1",
    "x-build-id": "xEc2NgHqVXUDQZEly"
  },
  "servers": [
    {
      "url": "https://api.apify.com/v2"
    }
  ],
  "paths": {
    "/acts/jpopendata~japan-resale-price-comps/run-sync-get-dataset-items": {
      "post": {
        "operationId": "run-sync-get-dataset-items-jpopendata-japan-resale-price-comps",
        "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/jpopendata~japan-resale-price-comps/runs": {
      "post": {
        "operationId": "runs-sync-jpopendata-japan-resale-price-comps",
        "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/jpopendata~japan-resale-price-comps/run-sync": {
      "post": {
        "operationId": "run-sync-jpopendata-japan-resale-price-comps",
        "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",
            "type": "array",
            "description": "Products to price, one per line, e.g. \"ポケモンカード 151\", \"PS5 本体\", \"Nikon F3\". Japanese titles match best (the sources are Japanese marketplaces). Each keyword gets its own price summary record. Up to 200 keywords per run. If empty, the Quick start keywords are used.",
            "default": [
              "Nintendo Switch",
              "ポケモンカード"
            ],
            "items": {
              "type": "string"
            }
          },
          "sources": {
            "title": "Sources",
            "type": "array",
            "description": "Which marketplaces to query. Valid values: yahoo-auctions-sold (Yahoo! Auctions SOLD prices / ヤフオク落札相場), yahoo-flea-market (Yahoo! Flea Market / ex-PayPay Flea Market current listings), bookoff (BOOKOFF online store: books, comics, CDs, DVDs, games), hareruya (Hareruya: Magic: The Gathering singles), surugaya (Suruga-ya hobby shop — OPT-IN: needs a Japanese RESIDENTIAL proxy, waits 30 s between requests and fails on some proxy exits). Case and spelling are forgiving (e.g. \"yahoo\", \"paypay\", \"ヤフオク\"). Empty = the four default sources.",
            "default": [
              "yahoo-auctions-sold",
              "yahoo-flea-market",
              "bookoff",
              "hareruya"
            ],
            "items": {
              "type": "string"
            }
          },
          "maxItemsPerSource": {
            "title": "Max items per source (per keyword)",
            "type": "integer",
            "description": "Item records kept per keyword per source (1..500; values outside are clamped). 20 gives a usable median; raise it for tighter statistics. Each item record is one billable `record` event.",
            "default": 20
          },
          "maxPagesPerSource": {
            "title": "Max result pages per source (per keyword)",
            "type": "integer",
            "description": "Upper bound on result pages requested per keyword per source (1..10; clamped). One page = one polite request (Yahoo Auctions 50 items, Yahoo Flea Market ~100, BOOKOFF 30, Suruga-ya 24; Hareruya always uses one request). Requests are serial per site and spaced like the original single-source actors.",
            "default": 2
          },
          "soldWithinDays": {
            "title": "Sold within the last N days",
            "type": "integer",
            "description": "Keep only sales that completed within the last N days (0 = no cutoff). Applies to sold items with a known sale time (Yahoo Auctions). Listing prices are never filtered by this.",
            "default": 0
          },
          "condition": {
            "title": "Condition",
            "type": "string",
            "description": "any (default), new or used — Japanese labels (新品, 未使用, 中古) work too. Applied after fetching. Hareruya card grades (NM/EX/...) have no new/used meaning, so a new/used filter excludes Hareruya.",
            "default": "any"
          },
          "priceMin": {
            "title": "Min price (JPY)",
            "type": "integer",
            "description": "Optional. Drop items cheaper than this (e.g. 3000 to drop accessories and parts). Applied after fetching."
          },
          "priceMax": {
            "title": "Max price (JPY)",
            "type": "integer",
            "description": "Optional. Drop items more expensive than this. Applied after fetching."
          },
          "excludeWords": {
            "title": "Exclude words",
            "type": "array",
            "description": "Optional. Items whose title contains any of these words are dropped before statistics, e.g. \"ジャンク\" (junk), \"ケース\" (case), \"箱のみ\" (box only). Case- and width-insensitive.",
            "default": [],
            "items": {
              "type": "string"
            }
          },
          "bookoffCategory": {
            "title": "BOOKOFF category",
            "type": "string",
            "description": "BOOKOFF has no free-text search, so it is browsed by category and only items whose title/author/genre contain every keyword word are kept. One of: game (default), comic, book, magazine, cd, dvd — or a numeric BOOKOFF genre id (the /search/genre/<id> URL also works).",
            "default": "game"
          },
          "proxyConfiguration": {
            "title": "Proxy (Yahoo Auctions, Yahoo Flea Market, BOOKOFF, Hareruya)",
            "type": "object",
            "description": "Optional. These four sources answer Apify datacenter IPs directly, so no proxy is used by default. If you set one, each source keeps a single sticky session for the whole run.",
            "default": {
              "useApifyProxy": false
            }
          },
          "surugayaProxyConfiguration": {
            "title": "Proxy for Suruga-ya (only used when surugaya is selected)",
            "type": "object",
            "description": "suruga-ya.jp blocks datacenter IPs, so Suruga-ya needs Apify RESIDENTIAL proxies in Japan (billed as Apify platform usage). One sticky session per run; if the first request is refused, the actor retries once on a different exit and then gives up on Suruga-ya while the other sources continue.",
            "default": {
              "useApifyProxy": true,
              "apifyProxyGroups": [
                "RESIDENTIAL"
              ],
              "apifyProxyCountry": "JP"
            }
          }
        }
      },
      "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
                  }
                }
              }
            }
          }
        }
      }
    }
  }
}