{
  "openapi": "3.0.1",
  "info": {
    "title": "Kleinanzeigen Real Time Data Scraper",
    "description": "Live Kleinanzeigen resale intelligence for thrift & vintage resellers: keyword search, full listing details, seller inventory, seller profiles, sold comps & URL collection. Stream structured JSON in real time — pay only for results.",
    "version": "0.0",
    "x-build-id": "ygB4ndsoczPpAGFE3"
  },
  "servers": [
    {
      "url": "https://api.apify.com/v2"
    }
  ],
  "paths": {
    "/acts/b2b_leads~Kleinanzeigen-Real-Time-Data-Scraper/run-sync-get-dataset-items": {
      "post": {
        "operationId": "run-sync-get-dataset-items-b2b_leads-Kleinanzeigen-Real-Time-Data-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/b2b_leads~Kleinanzeigen-Real-Time-Data-Scraper/runs": {
      "post": {
        "operationId": "runs-sync-b2b_leads-Kleinanzeigen-Real-Time-Data-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/b2b_leads~Kleinanzeigen-Real-Time-Data-Scraper/run-sync": {
      "post": {
        "operationId": "run-sync-b2b_leads-Kleinanzeigen-Real-Time-Data-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": {
          "enableListingSearch": {
            "title": "Listing Search",
            "type": "boolean",
            "description": "Live keyword search across Kleinanzeigen — thrift brands, streetwear, and vintage finds. On by default and prefilled so you can click Start and get results in seconds.",
            "default": true
          },
          "searchKeywords": {
            "title": "Search keywords",
            "type": "array",
            "description": "One or more search terms — German works best, e.g. \"carhartt detroit jacke\", \"vintage levis 501\", \"patagonia fleece\". Required when Listing Search is on.",
            "default": [
              "carhartt detroit jacke",
              "vintage levis 501",
              "patagonia fleece"
            ],
            "items": {
              "type": "string"
            }
          },
          "searchMaxResults": {
            "title": "Max results per keyword",
            "minimum": 1,
            "maximum": 200,
            "type": "integer",
            "description": "Maximum listings to return for each keyword (1–200). Default 10 — perfect for instant demo runs.",
            "default": 10
          },
          "searchSort": {
            "title": "Sort order",
            "enum": [
              "relevance",
              "newest",
              "price_low_to_high",
              "price_high_to_low"
            ],
            "type": "string",
            "description": "How to order search results. \"Newest first\" is ideal for deal alerts on fresh inventory.",
            "default": "relevance"
          },
          "searchCategory": {
            "title": "Category slug (optional)",
            "type": "string",
            "description": "Narrow the search to a category using its URL slug, e.g. \"kleidung-herren\" (men's clothing), \"mode-beauty\" (fashion & beauty), \"mобilitaet\" uses its own slug. Copy the slug from a category page URL like /s-kleidung-herren/…/k0c160.",
            "default": ""
          },
          "searchSize": {
            "title": "Size filter (optional)",
            "type": "string",
            "description": "Free-text size hint that must appear in the listing tags, e.g. M, L, XL, 48, 42x32.",
            "default": ""
          },
          "searchCondition": {
            "title": "Condition filter",
            "enum": [
              "",
              "new_with_tags",
              "new",
              "like_new",
              "ok",
              "alright"
            ],
            "type": "string",
            "description": "Filter by item condition as offered by the marketplace's catalog filters.",
            "default": ""
          },
          "searchMinPrice": {
            "title": "Min price (optional)",
            "minimum": 0,
            "maximum": 100000,
            "type": "integer",
            "description": "Minimum listing price in EUR."
          },
          "searchMaxPrice": {
            "title": "Max price (optional)",
            "minimum": 0,
            "maximum": 100000,
            "type": "integer",
            "description": "Maximum listing price in EUR — pair with \"Newest first\" sort to catch underpriced steals fast."
          },
          "searchLeadDetails": {
            "title": "Tag buy-now & wanted leads",
            "type": "boolean",
            "description": "When on, every row additionally carries is_buy_now (fixed \"Direkt kaufen\" price) and is_wanted (\"Gesucht\" buyer ads) tags. Every discovered listing still goes to the dataset — results are never filtered, so run volume stays predictable. Filter downstream in your own tooling. Costs nothing extra: the tags are read from the same listing card.",
            "default": false
          },
          "searchFetchFullDetails": {
            "title": "Enrich with full listing details",
            "type": "boolean",
            "description": "When on, each search result stays ONE row (featureType listing_search, detailsFetched=true) but is enriched with description, size/condition specifics, full image gallery, brand, color, and seller context. Adds a little extra time per listing. When off, you get fast search cards with price, title, tags, and location. Every discovered item is always saved — never filtered out.",
            "default": false
          },
          "enableListingDetails": {
            "title": "Listing Details",
            "type": "boolean",
            "description": "Fetch the full record for specific Kleinanzeigen listings by URL or ad ID.",
            "default": false
          },
          "listingIds": {
            "title": "Listing IDs (optional)",
            "type": "array",
            "description": "Kleinanzeigen ad IDs, e.g. 3524930885.",
            "default": [],
            "items": {
              "type": "string"
            }
          },
          "listingUrls": {
            "title": "Listing URLs (optional)",
            "type": "array",
            "description": "Full Kleinanzeigen listing URLs (https://www.kleinanzeigen.de/s-anzeige/...).",
            "default": [],
            "items": {
              "type": "string"
            }
          },
          "enableClosetListings": {
            "title": "Seller Inventory (closet)",
            "type": "boolean",
            "description": "Collect the full active inventory of any seller — track competitor stock and repricing moves. Identified by numeric seller ID.",
            "default": false
          },
          "sellerIds": {
            "title": "Seller IDs",
            "type": "array",
            "description": "Numeric Kleinanzeigen seller IDs (from the seller page URL, e.g. userId=33915083 → 33915083). Shared by Seller Inventory, Seller Profile, and Sold Comps.",
            "default": [],
            "items": {
              "type": "string"
            }
          },
          "sellerMaxListings": {
            "title": "Max inventory listings per seller",
            "minimum": 1,
            "maximum": 500,
            "type": "integer",
            "description": "Maximum active listings to collect per seller (1–500).",
            "default": 30
          },
          "enableSellerProfile": {
            "title": "Seller Profile",
            "type": "boolean",
            "description": "Extract seller stats: display name, badges, active listings count, member since, and reputation when available.",
            "default": false
          },
          "enableSoldHistory": {
            "title": "Sold Item Comps / History",
            "type": "boolean",
            "description": "Sell-through snapshot per seller: current inventory with per-item sold status, for comps and sell-through analysis. (The marketplace does not publish a completed-sales feed — this is the closest public equivalent; see README.)",
            "default": false
          },
          "soldMaxItems": {
            "title": "Max items per seller",
            "minimum": 1,
            "maximum": 500,
            "type": "integer",
            "description": "Maximum inventory rows to collect per seller for comps (1–500).",
            "default": 30
          },
          "enableScrapeByUrl": {
            "title": "Scrape By URL",
            "type": "boolean",
            "description": "Paste any Kleinanzeigen URL — search results, seller inventory, category page, or single listing.",
            "default": false
          },
          "scrapeUrls": {
            "title": "Kleinanzeigen URLs",
            "type": "array",
            "description": "Any Kleinanzeigen search, seller inventory, category, or listing URL.",
            "default": [],
            "items": {
              "type": "string"
            }
          },
          "webhookUrl": {
            "title": "Webhook URL",
            "type": "string",
            "description": "Optional. Every record is always saved to the run dataset — this webhook is an ADDITIONAL real-time push. Each new row is also POSTed to this URL (Slack, Discord, Zapier, Make, n8n, custom pricing bot).",
            "default": ""
          },
          "webhookFormat": {
            "title": "Webhook format",
            "enum": [
              "json",
              "slack"
            ],
            "type": "string",
            "description": "json = full record object; slack = Slack-friendly message payload.",
            "default": "json"
          },
          "proxyConfiguration": {
            "title": "Proxy settings",
            "type": "object",
            "description": "Residential proxy recommended. Kleinanzeigen is a German marketplace — German (DE) residential egress delivers the most reliable results at scale.",
            "default": {
              "useApifyProxy": true,
              "apifyProxyGroups": [
                "RESIDENTIAL"
              ],
              "apifyProxyCountry": "DE"
            }
          }
        }
      },
      "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
                  }
                }
              }
            }
          }
        }
      }
    }
  }
}