{
  "openapi": "3.0.1",
  "info": {
    "title": "Vinted, Reverb, TCGPlayer & Discogs Scraper — Sold Comps",
    "description": "Compute real sold market comps (P25, Median, P75, 30d velocity) and live buy/resell arbitrage margins across Vinted, Reverb, TCGPlayer, and Discogs using Chrome TLS & JSON APIs. Built for pro resellers, collectibles shops, Discord/Telegram deal bots, and n8n arbitrage alerts.",
    "version": "1.0",
    "x-build-id": "rbG3C2moZPuDT2XMW"
  },
  "servers": [
    {
      "url": "https://api.apify.com/v2"
    }
  ],
  "paths": {
    "/acts/vesper_studio~reseller-arbitrage-sold-comps/run-sync-get-dataset-items": {
      "post": {
        "operationId": "run-sync-get-dataset-items-vesper_studio-reseller-arbitrage-sold-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/vesper_studio~reseller-arbitrage-sold-comps/runs": {
      "post": {
        "operationId": "runs-sync-vesper_studio-reseller-arbitrage-sold-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/vesper_studio~reseller-arbitrage-sold-comps/run-sync": {
      "post": {
        "operationId": "run-sync-vesper_studio-reseller-arbitrage-sold-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",
        "required": [
          "queries"
        ],
        "properties": {
          "queries": {
            "title": "Search Queries / Products / SKUs",
            "type": "array",
            "description": "One or more product names, card names, vinyl releases, or gear models to price-check and scan for arbitrage opportunities.",
            "default": [
              "Boss DS-1"
            ],
            "items": {
              "type": "string"
            }
          },
          "marketplaces": {
            "title": "Verified Marketplaces",
            "type": "array",
            "description": "Select which verified proxy-free marketplaces to query. Note: eBay requires residential proxies (Akamai 403 on datacenter IPs) and is intentionally excluded from default proxy-free adapters.",
            "items": {
              "type": "string",
              "enum": [
                "reverb",
                "tcgplayer",
                "discogs",
                "vinted"
              ],
              "enumTitles": [
                "Reverb (Music Gear & Synths - Sold + Active JSON API)",
                "TCGPlayer (Pokemon / MTG / Yu-Gi-Oh - Sold + Active JSON API)",
                "Discogs (Vinyl / CDs - Official API + Release Sold Stats)",
                "Vinted (EU/UK/US Resale - Live Active Asks Sourcing)"
              ]
            },
            "default": [
              "reverb",
              "tcgplayer",
              "discogs",
              "vinted"
            ]
          },
          "includeSold": {
            "title": "Include Sold Comps",
            "type": "boolean",
            "description": "Fetch completed/sold transactions to compute P25, Median, P75 market value and 30-day sales velocity.",
            "default": true
          },
          "includeActive": {
            "title": "Include Active Listings",
            "type": "boolean",
            "description": "Fetch live active asking listings to compute spreadPct and flag underpriced arbitrage deals.",
            "default": true
          },
          "maxSoldPerMarketplace": {
            "title": "Max Sold Comps per Marketplace & Query",
            "minimum": 1,
            "maximum": 200,
            "type": "integer",
            "description": "Maximum number of sold comps to fetch per marketplace for each query.",
            "default": 40
          },
          "maxActivePerMarketplace": {
            "title": "Max Active Listings per Marketplace & Query",
            "minimum": 1,
            "maximum": 200,
            "type": "integer",
            "description": "Maximum number of live active listings to fetch per marketplace for each query.",
            "default": 40
          },
          "targetCurrency": {
            "title": "Target Summary Currency",
            "enum": [
              "USD",
              "EUR",
              "GBP",
              "CAD"
            ],
            "type": "string",
            "description": "Currency used in MARKET_SUMMARY and cross-marketplace gross margin calculations (listings keep their native currency on each item).",
            "default": "USD"
          },
          "vintedDomain": {
            "title": "Vinted Regional Domain",
            "enum": [
              "fr",
              "com",
              "co.uk",
              "de",
              "es",
              "it",
              "nl",
              "be"
            ],
            "type": "string",
            "description": "Vinted country storefront to scan when Vinted is enabled.",
            "default": "fr"
          },
          "discogsToken": {
            "title": "Discogs Personal Access Token (Optional)",
            "type": "string",
            "description": "Optional free Discogs developer token (from discogs.com/settings/developers). Increases API rate limit from 25 to 60 req/min and enables per-condition price suggestions fallback."
          },
          "strictQueryMatch": {
            "title": "Strict Query Title Matching",
            "type": "boolean",
            "description": "Filter out off-topic marketplace search results whose title does not contain the core query tokens (normalizes hyphens/spaces like DS-1 vs DS1).",
            "default": true
          },
          "excludeAccessories": {
            "title": "Exclude Accessories & Parts Noise",
            "type": "boolean",
            "description": "Exclude accessories, empty boxes, manuals, power adapters, pins, posters, and 'for parts' listings unless those terms appear in your search query.",
            "default": true
          },
          "alertDiscountBelowMedianPct": {
            "title": "Underpriced Alert Threshold (% Below Median Sold)",
            "minimum": 0,
            "maximum": 95,
            "type": "number",
            "description": "Active listings priced at least this percentage below medianSoldPrice are flagged with isUnderpriced=true and sent to webhookUrl.",
            "default": 20
          },
          "onlyNew": {
            "title": "Delta Mode (onlyNew)",
            "type": "boolean",
            "description": "Persist seen listing IDs across runs in Key-Value Store and output/alert only brand-new listings not delivered in previous runs. Market summary medians are still computed from fresh sold comps.",
            "default": false
          },
          "webhookUrl": {
            "title": "Discord / n8n / Telegram Relay Webhook URL (Optional)",
            "type": "string",
            "description": "Optional HTTPS webhook URL. Automatically formats rich Discord embeds for discord.com/api/webhooks/... or sends structured JSON for n8n/Make/bots whenever new underpriced deals are detected."
          },
          "maxItems": {
            "title": "Max Dataset Items to Deliver",
            "minimum": 1,
            "maximum": 10000,
            "type": "integer",
            "description": "Hard cap on total ListingComp records pushed to the dataset (also bounded by Pay-Per-Event maxTotalChargeUsd).",
            "default": 500
          },
          "proxyConfiguration": {
            "title": "Proxy Configuration (Optional)",
            "type": "object",
            "description": "Disabled by default. All 4 supported marketplaces work proxy-free via Chrome TLS impersonation; enable only if you run high-frequency schedules from a single IP.",
            "default": {
              "useApifyProxy": false
            }
          }
        }
      },
      "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
                  }
                }
              }
            }
          }
        }
      }
    }
  }
}