{
  "openapi": "3.0.1",
  "info": {
    "title": "Kleinanzeigen Scraper & API: Ads, Prices, Places",
    "description": "Scrape Kleinanzeigen.de ads (formerly eBay Kleinanzeigen) by keyword, category and city: title, price and VB, place, posting time, photos, mileage, rooms and m². Optional ad page: postcode, coordinates, seller type, all attributes. New ad monitor. Export JSON, CSV, Excel.",
    "version": "0.1",
    "x-build-id": "Mo0ixWZ00VPN060SF"
  },
  "servers": [
    {
      "url": "https://api.apify.com/v2"
    }
  ],
  "paths": {
    "/acts/automation_craft~kleinanzeigen-scraper/run-sync-get-dataset-items": {
      "post": {
        "operationId": "run-sync-get-dataset-items-automation_craft-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/automation_craft~kleinanzeigen-scraper/runs": {
      "post": {
        "operationId": "runs-sync-automation_craft-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/automation_craft~kleinanzeigen-scraper/run-sync": {
      "post": {
        "operationId": "run-sync-automation_craft-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": {
          "keywords": {
            "title": "Keywords",
            "type": "array",
            "description": "Search words as you would type them on Kleinanzeigen, for example fahrrad, iPhone 15 or Wohnung. A keyword cannot contain / \\ : + ? # or %.",
            "items": {
              "type": "string"
            }
          },
          "categories": {
            "title": "Categories",
            "type": "array",
            "description": "Kleinanzeigen categories by name (Autos, Fahrräder & Zubehör, Wohnung mieten), by address word (autos, fahrraeder) or by id (216). A name two categories share is answered with a free row listing both ids.",
            "items": {
              "type": "string"
            }
          },
          "locations": {
            "title": "Places",
            "type": "array",
            "description": "German cities, towns, city districts or states by name (Berlin, München, Hamburg-Mitte, Bayern), as \"Name, State\" when a name exists in several states (Altdorf, Bayern), or by Kleinanzeigen place id written as l6411. Postcodes and radius searches are not supported.",
            "items": {
              "type": "string"
            }
          },
          "searchUrls": {
            "title": "Search links",
            "type": "array",
            "description": "Kleinanzeigen search addresses copied from your browser, for example https://www.kleinanzeigen.de/s-fahrraeder/berlin/c217l3331. Their keyword, category and place are used. Links that carry filters (price, sort, radius, seller type, offer type, shipping) are refused with a free row, because robots.txt of Kleinanzeigen asks robots not to use them; use the price settings below instead.",
            "items": {
              "type": "string"
            }
          },
          "adUrls": {
            "title": "Ad links or ids",
            "type": "array",
            "description": "Single ads by link (https://www.kleinanzeigen.de/s-anzeige/...) or by ad id (3538233055). Each is read from its ad page and delivered with the ad page details. An ad that no longer exists gets a free row.",
            "items": {
              "type": "string"
            }
          },
          "maxItems": {
            "title": "Maximum ads",
            "minimum": 1,
            "maximum": 100000,
            "type": "integer",
            "description": "The most ad rows this run delivers, over all searches and ad links. Default 100."
          },
          "maxPagesPerSearch": {
            "title": "Pages per search",
            "minimum": 1,
            "maximum": 5,
            "type": "integer",
            "description": "Result pages read per search, newest ads first, about 30 ads a page. At most 5: robots.txt of Kleinanzeigen asks robots not to read pages 6 and later. Default 5."
          },
          "splitLargeSearches": {
            "title": "Split searches that hold more than five pages",
            "type": "boolean",
            "description": "When a search holds more ads than five pages show, also search its sub categories (or, for a category without sub categories, the districts of its city, or the 16 states for a search without a place), one level deep, up to 50 extra searches per search. Every ad is delivered once. Off by default."
          },
          "includeDetails": {
            "title": "Read the ad page of each ad",
            "type": "boolean",
            "description": "Adds the full description, postcode, state and district, coordinates, all attributes and photos, seller type, seller id, member since, seller badges, shipping and the seller's phone number where the ad page shows it without a login. Each ad delivered this way is billed as Listing plus Listing details. Off by default."
          },
          "includePrivateSellerDetails": {
            "title": "Include private sellers' personal data",
            "type": "boolean",
            "description": "Adds a PRIVATE seller's personal data as the ad page shows it to a visitor who is not logged in: the seller's name (sellerName), street (street), phone number (sellerPhone, where the page shows it without a login), exact coordinates (latitude, longitude, coordinatesRounded false), and phone numbers written into the title, description, attributes, tags or any other text of the row, as written. Off (default): those fields are null, coordinates are rounded to about 1 km and phone numbers in the row's texts are replaced by [phone number removed]. A row without its ad page cannot tell private from commercial and is treated as private. Commercial sellers' details are always included. You are responsible for a lawful use of personal data, the GDPR included. Off by default."
          },
          "minPrice": {
            "title": "Minimum price (EUR)",
            "minimum": 0,
            "type": "integer",
            "description": "Leave out ads below this price, in whole euros. Ads without a price figure (VB alone, jobs) are left out when a price filter is set. With ad pages read, the price the ad page states decides."
          },
          "maxPrice": {
            "title": "Maximum price (EUR)",
            "minimum": 0,
            "type": "integer",
            "description": "Leave out ads above this price, in whole euros. Ads without a price figure are left out when a price filter is set."
          },
          "maxAgeDays": {
            "title": "Posted within the last days",
            "minimum": 1,
            "maximum": 365,
            "type": "integer",
            "description": "Only ads posted within this many days before the run started. A search stops at its first older ad (the results are newest first). TOP ads show no date and are left out when this is set."
          },
          "minMileageKm": {
            "title": "Minimum mileage (km)",
            "minimum": 0,
            "maximum": 2000000,
            "type": "integer",
            "description": "Vehicles: leave out ads below this mileage. An ad that shows no mileage is left out when a mileage filter is set."
          },
          "maxMileageKm": {
            "title": "Maximum mileage (km)",
            "minimum": 0,
            "maximum": 2000000,
            "type": "integer",
            "description": "Vehicles: leave out ads above this mileage. An ad that shows no mileage is left out when a mileage filter is set."
          },
          "minFirstRegistrationYear": {
            "title": "First registration from (year)",
            "minimum": 1900,
            "maximum": 2100,
            "type": "integer",
            "description": "Vehicles: leave out ads first registered before this year. An ad that shows no first registration is left out when this filter is set."
          },
          "maxFirstRegistrationYear": {
            "title": "First registration until (year)",
            "minimum": 1900,
            "maximum": 2100,
            "type": "integer",
            "description": "Vehicles: leave out ads first registered after this year."
          },
          "minRooms": {
            "title": "Minimum rooms",
            "minimum": 0,
            "maximum": 100,
            "type": "integer",
            "description": "Property: leave out ads with fewer rooms. An ad that shows no room count is left out when a rooms filter is set."
          },
          "maxRooms": {
            "title": "Maximum rooms",
            "minimum": 0,
            "maximum": 100,
            "type": "integer",
            "description": "Property: leave out ads with more rooms."
          },
          "minLivingSpaceM2": {
            "title": "Minimum living space (m²)",
            "minimum": 0,
            "maximum": 100000,
            "type": "integer",
            "description": "Property: leave out ads with less living space. An ad that shows no living space is left out when this filter is set."
          },
          "maxLivingSpaceM2": {
            "title": "Maximum living space (m²)",
            "minimum": 0,
            "maximum": 100000,
            "type": "integer",
            "description": "Property: leave out ads with more living space."
          },
          "includeTopAds": {
            "title": "Include TOP ads",
            "type": "boolean",
            "description": "TOP ads are paid placements Kleinanzeigen shows on every results page, outside the date order. Included by default; each is delivered once."
          },
          "sellerType": {
            "title": "Seller type",
            "enum": [
              "any",
              "private",
              "commercial"
            ],
            "type": "string",
            "description": "Only private or only commercial sellers. This needs the ad page of every ad, so ad pages are read and each delivered ad is billed as Listing plus Listing details."
          },
          "adType": {
            "title": "Offer or wanted",
            "enum": [
              "any",
              "offer",
              "wanted"
            ],
            "type": "string",
            "description": "Only offers (Angebote) or only wanted ads (Gesuche). This needs the ad page of every ad, so ad pages are read and each delivered ad is billed as Listing plus Listing details."
          },
          "monitorName": {
            "title": "Monitor name (new ads only)",
            "type": "string",
            "description": "A short name such as bikes-berlin. Letters, digits, spaces and . _ , - : # ( ), up to 60 characters. A name belongs to one set of settings; use a new name for other searches. Schedule runs on one name so they do not overlap."
          }
        }
      },
      "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
                  }
                }
              }
            }
          }
        }
      }
    }
  }
}