{
  "openapi": "3.0.1",
  "info": {
    "title": "Leboncoin Universal Scraper - Real Estate",
    "description": "⚡ Scrape unlimited Leboncoin real-estate listings — no URL needed! Pick rent, sale or flatshare, add your filters (price, surface, rooms, DPE…) and instantly get rich, structured data for market analysis, deal sourcing, price monitoring or lead generation.",
    "version": "0.1",
    "x-build-id": "RS5daZcfnVyXPMo0v"
  },
  "servers": [
    {
      "url": "https://api.apify.com/v2"
    }
  ],
  "paths": {
    "/acts/scrapifier~leboncoin-universal-scraper-real-estate/run-sync-get-dataset-items": {
      "post": {
        "operationId": "run-sync-get-dataset-items-scrapifier-leboncoin-universal-scraper-real-estate",
        "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/scrapifier~leboncoin-universal-scraper-real-estate/runs": {
      "post": {
        "operationId": "runs-sync-scrapifier-leboncoin-universal-scraper-real-estate",
        "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/scrapifier~leboncoin-universal-scraper-real-estate/run-sync": {
      "post": {
        "operationId": "run-sync-scrapifier-leboncoin-universal-scraper-real-estate",
        "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": {
          "category": {
            "title": "Transaction",
            "enum": [
              "10",
              "9",
              "11",
              "12",
              "304",
              "13"
            ],
            "type": "string",
            "description": "What kind of real-estate listing to search.",
            "default": "10"
          },
          "text": {
            "title": "Keywords",
            "type": "string",
            "description": "Optional free-text keywords, e.g. \"balcon\", \"loft\", a program name."
          },
          "locations": {
            "title": "Location(s)",
            "type": "array",
            "description": "City, arrondissement or postal code, e.g. \"Paris 11\", \"Lyon\", \"75011\". Add several, or leave empty to search all of France.",
            "items": {
              "type": "string"
            }
          },
          "price_min": {
            "title": "Min price (€)",
            "minimum": 0,
            "type": "integer",
            "description": "Minimum price / rent."
          },
          "price_max": {
            "title": "Max price (€)",
            "minimum": 0,
            "type": "integer",
            "description": "Maximum price / rent."
          },
          "owner_type": {
            "title": "Seller type",
            "enum": [
              "all",
              "private",
              "pro"
            ],
            "type": "string",
            "description": "Filter by seller.",
            "default": "all"
          },
          "sort": {
            "title": "Sort by",
            "enum": [
              "relevance",
              "newest",
              "price_asc",
              "price_desc"
            ],
            "type": "string",
            "description": "Result ordering.",
            "default": "relevance"
          },
          "property_types": {
            "title": "Property type",
            "type": "array",
            "description": "One or more property types. Empty = all.",
            "items": {
              "type": "string",
              "enum": [
                "apartment",
                "house",
                "land",
                "parking",
                "other"
              ],
              "enumTitles": [
                "Apartment",
                "House",
                "Land",
                "Parking",
                "Other"
              ]
            }
          },
          "surface_min": {
            "title": "Min surface (m²)",
            "minimum": 0,
            "type": "integer",
            "description": "Minimum living surface."
          },
          "surface_max": {
            "title": "Max surface (m²)",
            "minimum": 0,
            "type": "integer",
            "description": "Maximum living surface."
          },
          "rooms_min": {
            "title": "Min rooms",
            "minimum": 1,
            "type": "integer",
            "description": "Minimum number of rooms (pièces)."
          },
          "bedrooms_min": {
            "title": "Min bedrooms",
            "minimum": 1,
            "type": "integer",
            "description": "Minimum number of bedrooms."
          },
          "bathrooms_min": {
            "title": "Min bathrooms",
            "minimum": 1,
            "type": "integer",
            "description": "Minimum number of bathrooms."
          },
          "land_surface_min": {
            "title": "Min land surface (m²)",
            "minimum": 0,
            "type": "integer",
            "description": "Minimum land/plot surface (houses, land)."
          },
          "land_surface_max": {
            "title": "Max land surface (m²)",
            "minimum": 0,
            "type": "integer",
            "description": "Maximum land/plot surface (houses, land)."
          },
          "furnished": {
            "title": "Furnished",
            "type": "array",
            "description": "Furnished / unfurnished (mostly rentals).",
            "items": {
              "type": "string",
              "enum": [
                "1",
                "2"
              ],
              "enumTitles": [
                "Furnished",
                "Unfurnished"
              ]
            }
          },
          "energy_rate": {
            "title": "Energy rating (DPE)",
            "type": "array",
            "description": "Energy performance classes to include.",
            "items": {
              "type": "string",
              "enum": [
                "a",
                "b",
                "c",
                "d",
                "e",
                "f",
                "g"
              ],
              "enumTitles": [
                "A",
                "B",
                "C",
                "D",
                "E",
                "F",
                "G"
              ]
            }
          },
          "ges": {
            "title": "Greenhouse gas (GES)",
            "type": "array",
            "description": "GES classes to include.",
            "items": {
              "type": "string",
              "enum": [
                "a",
                "b",
                "c",
                "d",
                "e",
                "f",
                "g"
              ],
              "enumTitles": [
                "A",
                "B",
                "C",
                "D",
                "E",
                "F",
                "G"
              ]
            }
          },
          "heating_type": {
            "title": "Heating type",
            "type": "array",
            "description": "Individual or communal heating.",
            "items": {
              "type": "string",
              "enum": [
                "individual",
                "communal"
              ],
              "enumTitles": [
                "Individual",
                "Communal"
              ]
            }
          },
          "heating_mode": {
            "title": "Heating mode",
            "type": "array",
            "description": "Heating energy.",
            "items": {
              "type": "string",
              "enum": [
                "gas",
                "electric",
                "fuel",
                "other"
              ],
              "enumTitles": [
                "Gas",
                "Electric",
                "Fuel oil",
                "Other"
              ]
            }
          },
          "elevator": {
            "title": "Elevator",
            "type": "array",
            "description": "Building elevator.",
            "items": {
              "type": "string",
              "enum": [
                "1",
                "2"
              ],
              "enumTitles": [
                "With elevator",
                "Without elevator"
              ]
            }
          },
          "orientation": {
            "title": "Orientation",
            "type": "array",
            "description": "Facing direction.",
            "items": {
              "type": "string",
              "enum": [
                "north",
                "south",
                "east",
                "west",
                "north_east",
                "north_west",
                "south_east",
                "south_west"
              ],
              "enumTitles": [
                "North",
                "South",
                "East",
                "West",
                "North-East",
                "North-West",
                "South-East",
                "South-West"
              ]
            }
          },
          "floor_min": {
            "title": "Min floor",
            "minimum": 0,
            "type": "integer",
            "description": "Minimum floor number."
          },
          "parkings_min": {
            "title": "Min parking spaces",
            "minimum": 1,
            "type": "integer",
            "description": "Minimum number of parking spaces."
          },
          "building_year_min": {
            "title": "Built after (year)",
            "minimum": 1800,
            "type": "integer",
            "description": "Minimum construction year."
          },
          "building_year_max": {
            "title": "Built before (year)",
            "minimum": 1800,
            "type": "integer",
            "description": "Maximum construction year."
          },
          "immo_sell_type": {
            "title": "Sale type",
            "type": "array",
            "description": "Type of sale (for the 'For sale' transaction).",
            "items": {
              "type": "string",
              "enum": [
                "old",
                "new",
                "viager"
              ],
              "enumTitles": [
                "Existing",
                "New build",
                "Life annuity (viager)"
              ]
            }
          },
          "property_condition": {
            "title": "Condition",
            "type": "array",
            "description": "Property condition.",
            "items": {
              "type": "string",
              "enum": [
                "1",
                "2",
                "3",
                "4"
              ],
              "enumTitles": [
                "Excellent",
                "Good",
                "Renovated",
                "To refresh"
              ]
            }
          },
          "filters": {
            "title": "Advanced filters",
            "type": "object",
            "description": "Any other Leboncoin real-estate filter — each entry is a key with either a list of codes (enum) or a {\"min\":.., \"max\":..} range. Example: {\"energy_rate\": [\"a\",\"b\"], \"rooms\": {\"min\": 2, \"max\": 4}, \"land_plot_surface\": {\"min\": 300}}. The full key/code table is in the README (Filters reference section). Tip: build your search on leboncoin.fr and copy the URL query parameters — every key and value from the URL works here (e.g. real_estate_type=2&square=30-80 → {\"real_estate_type\": [\"2\"], \"square\": {\"min\": 30, \"max\": 80}}). Also lets you override any dedicated input above."
          },
          "max_results": {
            "title": "Max results",
            "minimum": 0,
            "type": "integer",
            "description": "How many listings to collect (0 = as many as available).",
            "default": 100
          },
          "proxyConfiguration": {
            "title": "Proxy",
            "type": "object",
            "description": "Residential FR proxies are recommended for reliable runs."
          }
        }
      },
      "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
                  }
                }
              },
              "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
                  }
                }
              }
            }
          }
        }
      }
    }
  }
}