{
  "openapi": "3.0.1",
  "info": {
    "title": "Mercari Japan Scraper - Sold Prices and Comparisons",
    "description": "Scrape Mercari Japan sold listings, extract product details and actual selling prices, compare similar items, and analyze market trends to discover profitable resale opportunities and make smarter pricing decisions.",
    "version": "0.0",
    "x-build-id": "Wza8KOrYZCzw9gVFi"
  },
  "servers": [
    {
      "url": "https://api.apify.com/v2"
    }
  ],
  "paths": {
    "/acts/sigma-dev~mercari-japan-scraper-sold-prices-and-comparisons/run-sync-get-dataset-items": {
      "post": {
        "operationId": "run-sync-get-dataset-items-sigma-dev-mercari-japan-scraper-sold-prices-and-comparisons",
        "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/sigma-dev~mercari-japan-scraper-sold-prices-and-comparisons/runs": {
      "post": {
        "operationId": "runs-sync-sigma-dev-mercari-japan-scraper-sold-prices-and-comparisons",
        "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/sigma-dev~mercari-japan-scraper-sold-prices-and-comparisons/run-sync": {
      "post": {
        "operationId": "run-sync-sigma-dev-mercari-japan-scraper-sold-prices-and-comparisons",
        "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": {
          "mode": {
            "title": "What to scrape",
            "enum": [
              "sold-comps",
              "search"
            ],
            "type": "string",
            "description": "Sold prices & comps returns completed sales plus a price-comps report per query (median, P25-P75, sell-through, trend). Live listings returns what is currently on sale.",
            "default": "sold-comps"
          },
          "queries": {
            "title": "Search keywords",
            "uniqueItems": true,
            "type": "array",
            "description": "Keywords to search on Mercari Japan. Japanese keywords return far more results than English ones, because that is how sellers write their listings.",
            "items": {
              "type": "string"
            }
          },
          "startUrls": {
            "title": "Mercari search URLs",
            "type": "array",
            "description": "Paste search URLs straight from jp.mercari.com. Their keyword, category, brand and price filters are read automatically.",
            "items": {
              "type": "object",
              "required": [
                "url"
              ],
              "properties": {
                "url": {
                  "type": "string",
                  "title": "URL of a web page",
                  "format": "uri"
                }
              }
            }
          },
          "maxItems": {
            "title": "Maximum items",
            "minimum": 1,
            "maximum": 100000,
            "type": "integer",
            "description": "Stop after saving this many items across all queries. Protects you from an unexpectedly large bill on a broad search.",
            "default": 500
          },
          "soldWithinDays": {
            "title": "Sold within the last N days",
            "minimum": 1,
            "maximum": 180,
            "type": "integer",
            "description": "Only include sales completed in this window. Mercari returns sold listings going back years, so without this a median mixes current prices with ones from several years ago.",
            "default": 90
          },
          "priceMin": {
            "title": "Minimum price (JPY)",
            "minimum": 0,
            "type": "integer",
            "description": "Lowest price to include, in Japanese yen. Leave at 0 for no minimum.",
            "default": 0
          },
          "priceMax": {
            "title": "Maximum price (JPY)",
            "minimum": 0,
            "type": "integer",
            "description": "Highest price to include, in Japanese yen. Leave at 0 for no maximum.",
            "default": 0
          },
          "excludeKeyword": {
            "title": "Exclude keyword",
            "type": "string",
            "description": "Skip listings containing this text. Useful for stripping out reproductions, damaged goods or bundle lots.",
            "default": ""
          },
          "conditions": {
            "title": "Item condition",
            "uniqueItems": true,
            "type": "array",
            "description": "Only include items in these conditions. Leave empty for all conditions.",
            "items": {
              "type": "string",
              "enum": [
                "new",
                "like-new",
                "no-visible-damage",
                "slight-damage",
                "damaged",
                "poor"
              ],
              "enumTitles": [
                "New, unused",
                "Like new",
                "No noticeable damage",
                "Slight damage or stains",
                "Damaged or stained",
                "Poor overall condition"
              ]
            },
            "default": []
          },
          "shippingPayer": {
            "title": "Who pays shipping",
            "uniqueItems": true,
            "type": "array",
            "description": "Filter by who covers postage. Seller-pays listings dominate Mercari and are the fairer basis for a price comparison.",
            "items": {
              "type": "string",
              "enum": [
                "seller",
                "buyer"
              ],
              "enumTitles": [
                "Seller pays shipping",
                "Buyer pays shipping"
              ]
            },
            "default": []
          },
          "categoryIds": {
            "title": "Category IDs",
            "uniqueItems": true,
            "type": "array",
            "description": "Mercari numeric category IDs, as they appear in a search URL's category_id parameter.",
            "default": [],
            "items": {
              "type": "string"
            }
          },
          "brandIds": {
            "title": "Brand IDs",
            "uniqueItems": true,
            "type": "array",
            "description": "Mercari numeric brand IDs, as they appear in a search URL's brand_id parameter.",
            "default": [],
            "items": {
              "type": "string"
            }
          },
          "sellerIds": {
            "title": "Seller IDs",
            "uniqueItems": true,
            "type": "array",
            "description": "Restrict the search to these sellers. Useful for tracking a competitor's sell-through.",
            "default": [],
            "items": {
              "type": "string"
            }
          },
          "sortBy": {
            "title": "Sort results by",
            "enum": [
              "newest",
              "price",
              "likes",
              "relevance"
            ],
            "type": "string",
            "description": "Order Mercari returns results in. Newest first gives the most representative recent sample.",
            "default": "newest"
          },
          "computeComps": {
            "title": "Compute price comps report",
            "type": "boolean",
            "description": "Produce a comps report per query - median, trimmed mean, P25-P75, days to sell and 30d vs 90d trend - stored under the COMPS key in the key-value store.",
            "default": true
          },
          "includeActiveForSellThrough": {
            "title": "Measure sell-through rate",
            "type": "boolean",
            "description": "Also count currently live listings so the report can show sell-through (sold divided by sold plus active). Costs a few extra requests and is not charged as results.",
            "default": true
          },
          "priceBands": {
            "title": "Price bands",
            "minimum": 0,
            "maximum": 20,
            "type": "integer",
            "description": "Split each query into this many price bands to read past Mercari's paging ceiling. Leave at 0 to split automatically only when a query is too large.",
            "default": 0
          },
          "proxyConfiguration": {
            "title": "Proxy configuration",
            "type": "object",
            "description": "Mercari serves Japan-specific results and rate-limits aggressive clients. Apify Proxy is strongly recommended; Japanese residential proxies give the most reliable results.",
            "default": {
              "useApifyProxy": true
            }
          }
        }
      },
      "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
                  }
                }
              }
            }
          }
        }
      }
    }
  }
}