{
  "openapi": "3.0.1",
  "info": {
    "title": "Classifieds Scraper for Kleinanzeigen - Ads, Prices & Leads",
    "description": "Scrape Kleinanzeigen.de, Germany's #1 classifieds: cars, property, jobs, electronics and more. Prices, attributes, photos, GPS, seller type and dealer leads with phone, email and address. Filter by keyword, category, city, price; monitor new ads. Independent tool, not affiliated with Kleinanzeigen.",
    "version": "0.1",
    "x-build-id": "LR4H6RAqc44sz69DR"
  },
  "servers": [
    {
      "url": "https://api.apify.com/v2"
    }
  ],
  "paths": {
    "/acts/scrapesage~kleinanzeigen-scraper/run-sync-get-dataset-items": {
      "post": {
        "operationId": "run-sync-get-dataset-items-scrapesage-kleinanzeigen-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/scrapesage~kleinanzeigen-scraper/runs": {
      "post": {
        "operationId": "runs-sync-scrapesage-kleinanzeigen-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/scrapesage~kleinanzeigen-scraper/run-sync": {
      "post": {
        "operationId": "run-sync-scrapesage-kleinanzeigen-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": {
          "searchQueries": {
            "title": "Search queries",
            "type": "array",
            "description": "Keywords to search on Kleinanzeigen, e.g. <code>iphone 15</code>, <code>bmw 3er</code>, <code>sofa</code>, <code>wohnung</code>. Each query is combined with the category, location and price filters below. Leave empty to browse purely by category or location, or use Start URLs.",
            "items": {
              "type": "string"
            }
          },
          "startUrls": {
            "title": "Start URLs",
            "type": "array",
            "description": "Paste any Kleinanzeigen.de URL - a search or category page with the filters you set on the site (<code>https://www.kleinanzeigen.de/s-autos/berlin/c216l3331</code>), an ad page (<code>.../s-anzeige/...</code>, returned as a full listing-detail record, charged as <code>listingDetail</code>), a seller page (<code>.../s-bestandsliste.html?userId=...</code>) or a PRO shop (<code>.../pro/&lt;name&gt;</code>). Used in addition to search queries.",
            "items": {
              "type": "object",
              "required": [
                "url"
              ],
              "properties": {
                "url": {
                  "type": "string",
                  "title": "URL of a web page",
                  "format": "uri"
                }
              }
            }
          },
          "urlsFromFile": {
            "title": "Import URLs from a file",
            "type": "string",
            "description": "Paste a list of URLs (one per line), OR one link to a .txt/.csv file, Google Sheet or Google Drive file containing them. Lets you import many Start URLs at once instead of typing each. Google Sheet/Drive share links are handled automatically."
          },
          "listingUrls": {
            "title": "Listing (ad) URLs",
            "type": "array",
            "description": "Direct Kleinanzeigen ad URLs (<code>https://www.kleinanzeigen.de/s-anzeige/...</code>) or ad ids. Each is fetched as a full listing-detail record (charged as <code>listingDetail</code>).",
            "items": {
              "type": "string"
            }
          },
          "sellerUrls": {
            "title": "Seller URLs",
            "type": "array",
            "description": "Seller pages (<code>.../s-bestandsliste.html?userId=12345</code>) or PRO shops (<code>.../pro/&lt;name&gt;</code>). Scrapes every active ad of that seller (all pages) and, with seller leads on, one lead record per seller.",
            "items": {
              "type": "string"
            }
          },
          "category": {
            "title": "Category",
            "type": "string",
            "description": "Limit results to a category, using the site's own names: <code>Autos</code>, <code>Mietwohnungen</code>, <code>Eigentumswohnungen</code>, <code>Häuser zum Kauf</code>, <code>Smartphones</code>, <code>Konsolen</code>, <code>Laptops & Notebooks</code>, <code>Fahrräder & Zubehör</code>, <code>Haus & Garten</code>, <code>Jobs</code>, <code>Haustiere</code> … (top level or sub-category, English names such as <code>cars</code> or <code>apartments</code> work too) or a code like <code>c216</code>. A name Kleinanzeigen does not have is reported on the run card and nothing is searched without it."
          },
          "location": {
            "title": "City / location",
            "type": "string",
            "description": "City, town or 5-digit postcode, e.g. <code>Berlin</code>, <code>München</code>, <code>Köln</code>, <code>50667</code>. Resolved with Kleinanzeigen's own location search. Leave empty for all of Germany. A place Kleinanzeigen does not know is reported on the run card and never searched as all of Germany."
          },
          "radius": {
            "title": "Radius (km)",
            "minimum": 0,
            "type": "integer",
            "description": "Search radius in kilometres around the location (only applies when a location is set), e.g. 5, 10, 20, 50, 100."
          },
          "minPrice": {
            "title": "Min price (€)",
            "minimum": 0,
            "type": "integer",
            "description": "Only ads at or above this price, in euros. With a price filter, ads without a price (\"VB\" only) are left out."
          },
          "maxPrice": {
            "title": "Max price (€)",
            "minimum": 0,
            "type": "integer",
            "description": "Only ads at or below this price, in euros."
          },
          "offerType": {
            "title": "Seller type",
            "enum": [
              "any",
              "private",
              "commercial"
            ],
            "type": "string",
            "description": "Filter by who is selling. <b>Commercial</b> = professional / business sellers only (dealers, shops - great for lead generation). <b>Private</b> = individuals only. <b>Any</b> = both.",
            "default": "any"
          },
          "adType": {
            "title": "Ad type",
            "enum": [
              "any",
              "offer",
              "wanted"
            ],
            "type": "string",
            "description": "<b>Offers</b> = items, properties, jobs offered. <b>Wanted</b> = \"Gesuch\" ads from people looking for something. <b>Any</b> = both.",
            "default": "any"
          },
          "sort": {
            "title": "Sort order",
            "enum": [
              "newest",
              "price_asc",
              "price_desc"
            ],
            "type": "string",
            "description": "How to order results. Newest first is also what monitoring uses.",
            "default": "newest"
          },
          "includeListingDetails": {
            "title": "Include full listing details",
            "type": "boolean",
            "description": "For every listing, also open its ad page: the full description, every structured attribute (car / property / electronics specs), the full image gallery, GPS coordinates, state, street (when shown), shipping note, view count and the seller (name, private vs commercial, member since, active ads, ratings - plus the phone and legal imprint that commercial sellers publish). Charged as <code>listingDetail</code>.",
            "default": false
          },
          "includeSellerLeads": {
            "title": "Output seller leads",
            "type": "boolean",
            "description": "Also output one deduplicated lead record (type = \"sellerLead\") per seller behind the scraped ads - name, private / commercial, company, phone, email, website, address, VAT id and commercial register (from the legal imprint commercial sellers publish), member since, active ads, ratings, categories, price range, sample listings and a 0–100 lead score. Opening ad pages is required, so this implies full listing details.",
            "default": false
          },
          "enrichSellerContacts": {
            "title": "Enrich PRO shop contacts",
            "type": "boolean",
            "description": "For sellers with a Kleinanzeigen PRO shop, also open the shop page for its phone, website, address, opening hours, followers and about text. One extra request per PRO seller.",
            "default": false
          },
          "maxItems": {
            "title": "Max listings",
            "minimum": 1,
            "type": "integer",
            "description": "Maximum number of listings across all queries (shared fairly between them). Kleinanzeigen shows at most 1,250 ads per search and sort order; for larger result sets the actor continues with the other sort orders automatically.",
            "default": 80
          },
          "maxSellerLeads": {
            "title": "Max seller leads",
            "minimum": 1,
            "type": "integer",
            "description": "Maximum number of seller-lead records (when seller leads are on); the highest lead scores are kept.",
            "default": 200
          },
          "monitorMode": {
            "title": "Monitoring mode - only new records",
            "type": "boolean",
            "description": "Remember what earlier runs saw in a named key-value store and emit ONLY ads newly posted since the previous run (and sellers not delivered before). An ad delivered earlier is delivered again, flagged <code>priceDropped</code>, when it reappears at a lower price. Works with Apify Schedules.",
            "default": false
          },
          "monitorKey": {
            "title": "Monitor key",
            "type": "string",
            "description": "Names the memory used by monitoring mode. Use a distinct key per saved search so different watches don't share state.",
            "default": "default"
          },
          "proxyConfiguration": {
            "title": "Proxy configuration",
            "type": "object",
            "description": "Residential proxies in Germany are used by default - Kleinanzeigen serves them reliably and refuses part of the datacenter ranges. If you choose datacenter proxies, refused requests move to German residential addresses automatically.",
            "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
                  }
                }
              }
            }
          }
        }
      }
    }
  }
}