{
  "openapi": "3.0.1",
  "info": {
    "title": "LeBonCoin Scraper — Search, Cars, Real Estate, Ads & Sellers",
    "description": "Scrape Leboncoin.fr classified listings — cars, real estate, electronics, furniture & all categories. Extract 30+ fields: prices, images at all resolutions, GPS coordinates, DPE ratings, seller profiles, and dynamic attributes. 6 modes: search with advanced vehicle & real estate filters/",
    "version": "1.8",
    "x-build-id": "MTJHDCN4v3Rda2Kun"
  },
  "servers": [
    {
      "url": "https://api.apify.com/v2"
    }
  ],
  "paths": {
    "/acts/rp_openpro.ai~leboncoin-scraper/run-sync-get-dataset-items": {
      "post": {
        "operationId": "run-sync-get-dataset-items-rp_openpro.ai-leboncoin-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/rp_openpro.ai~leboncoin-scraper/runs": {
      "post": {
        "operationId": "runs-sync-rp_openpro.ai-leboncoin-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/rp_openpro.ai~leboncoin-scraper/run-sync": {
      "post": {
        "operationId": "run-sync-rp_openpro.ai-leboncoin-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": {
          "mode": {
            "title": "Mode",
            "enum": [
              "search",
              "searchCars",
              "searchRealEstate",
              "fetchAd",
              "fetchAdsBatch",
              "fetchUser"
            ],
            "type": "string",
            "description": "Operation mode. Leave empty for auto-detection: if vehicleFilters is set the mode becomes searchCars, if realEstateFilters is set it becomes searchRealEstate, otherwise search."
          },
          "text": {
            "title": "Search keywords",
            "type": "string",
            "description": "What are you looking for? e.g. \"peugeot 308\", \"appartement lumineux\", \"vélo électrique\""
          },
          "category": {
            "title": "Category",
            "enum": [
              "",
              "TOUTES_CATEGORIES",
              "VEHICULES_VOITURES",
              "VEHICULES_MOTOS",
              "VEHICULES_UTILITAIRES",
              "VEHICULES_CARAVANING",
              "VEHICULES_NAUTISME",
              "IMMOBILIER_VENTES_IMMOBILIERES",
              "IMMOBILIER_LOCATIONS",
              "IMMOBILIER_COLOCATIONS",
              "IMMOBILIER_BUREAUX_ET_COMMERCES",
              "MULTIMEDIA_INFORMATIQUE",
              "MULTIMEDIA_CONSOLES_ET_JEUX_VIDEO",
              "MULTIMEDIA_IMAGE_ET_SON",
              "MULTIMEDIA_TELEPHONIE",
              "MAISON_AMEUBLEMENT",
              "MAISON_ELECTROMENAGER",
              "MAISON_ARTS_DE_LA_TABLE",
              "MAISON_DECORATION",
              "MAISON_LINGE_DE_MAISON",
              "MAISON_BRICOLAGE",
              "MAISON_JARDINAGE",
              "MAISON_VETEMENTS",
              "LOISIRS_DVD_ET_FILMS",
              "LOISIRS_CD_ET_MUSIQUE",
              "LOISIRS_LIVRES",
              "LOISIRS_ANIMAUX",
              "LOISIRS_VELOS",
              "LOISIRS_SPORTS_ET_HOBBIES",
              "LOISIRS_INSTRUMENTS_DE_MUSIQUE",
              "LOISIRS_COLLECTION",
              "LOISIRS_JEUX_ET_JOUETS",
              "LOISIRS_VINS_ET_GASTRONOMIE",
              "EMPLOI_OFFRES",
              "SERVICES_PRESTATIONS_DE_SERVICES",
              "SERVICES_BILLETTERIE",
              "SERVICES_COURS_PARTICULIERS",
              "SERVICES_EVENEMENTS",
              "VACANCES_LOCATIONS_ET_GITES",
              "VACANCES_CHAMBRES_D_HOTES",
              "VACANCES_CAMPINGS",
              "VACANCES_HOTELS",
              "MATERIEL_PROFESSIONNEL_MATERIEL_AGRICOLE",
              "MATERIEL_PROFESSIONNEL_TRANSPORT_MANUTENTION",
              "MATERIEL_PROFESSIONNEL_BTP_CHANTIER_GROS_OEUVRE",
              "MATERIEL_PROFESSIONNEL_OUTILLAGE_MATERIAUX_2ND_OEUVRE",
              "MATERIEL_PROFESSIONNEL_EQUIPEMENT_INDUSTRIELS",
              "MATERIEL_PROFESSIONNEL_RESTAURATION_HOTELLERIE",
              "MATERIEL_PROFESSIONNEL_FOURNITURES_ET_EQUIPEMENTS_DE_BUREAU",
              "MATERIEL_PROFESSIONNEL_COMMERCES_ET_MARCHES",
              "MATERIEL_PROFESSIONNEL_MATERIEL_MEDICAL",
              "AUTRES"
            ],
            "type": "string",
            "description": "Leboncoin category. Leave empty for all categories. Auto-set to Voitures when using vehicle filters and Real Estate when using real estate filters."
          },
          "sort": {
            "title": "Sort order",
            "enum": [
              "",
              "NEWEST",
              "PRICE_ASC",
              "PRICE_DESC",
              "RELEVANCE"
            ],
            "type": "string",
            "description": "Sort results. NEWEST = most recent first, PRICE_ASC = cheapest first, PRICE_DESC = most expensive first."
          },
          "location": {
            "title": "Location",
            "type": "string",
            "description": "City name, zipcode, or region. e.g. \"Paris\", \"75009\", \"Lyon\". Leave empty for all of France."
          },
          "priceMin": {
            "title": "Minimum price (EUR)",
            "minimum": 0,
            "type": "integer",
            "description": "Minimum listing price in euros."
          },
          "priceMax": {
            "title": "Maximum price (EUR)",
            "minimum": 0,
            "type": "integer",
            "description": "Maximum listing price in euros."
          },
          "maxPages": {
            "title": "Max pages to scrape",
            "minimum": 1,
            "maximum": 500,
            "type": "integer",
            "description": "Number of result pages to fetch (up to 35 listings per page). Stops early if no more results.",
            "default": 1
          },
          "vehicleFilters": {
            "title": "Vehicle filters (cars)",
            "type": "object",
            "description": "Advanced car filters: registration_year, mileage_km, horsepower, fuels, gearboxes, u_car_brands, u_car_models, doors, vehicle_seats, vehicle_types, first_owner, critair, vehicule_colors. Each range is {min, max}. Each list is string tokens from Leboncoin."
          },
          "realEstateFilters": {
            "title": "Real estate filters",
            "type": "object",
            "description": "Advanced property filters: square_m2, rooms, bedrooms, energy_rates, ges_ratings, real_estate_types, building_year, elevator, furnished, floor_numbers, and more. Each range is {min, max}. Each list is string tokens from Leboncoin."
          },
          "extraFilters": {
            "title": "Extra filters (advanced)",
            "type": "object",
            "description": "Raw Leboncoin finder keys. Ranges as [min, max], enums as [\"value1\", \"value2\"]. Overrides any structured filter with the same key."
          },
          "delayBetweenPagesMs": {
            "title": "Delay between pages (ms)",
            "minimum": 0,
            "maximum": 60000,
            "type": "integer",
            "description": "Pause between pages to reduce anti-bot pressure. 0 = no delay.",
            "default": 0
          },
          "prefetchUsers": {
            "title": "Include seller profiles",
            "type": "boolean",
            "description": "Attach seller name, account type, and location to every listing in the results.",
            "default": false
          },
          "adId": {
            "title": "Listing ID",
            "type": "string",
            "description": "Single listing ID to fetch (mode fetchAd). The numeric ID from any Leboncoin listing URL."
          },
          "adIds": {
            "title": "Listing IDs (batch)",
            "type": "array",
            "description": "Multiple listing IDs to fetch in parallel (mode fetchAdsBatch).",
            "items": {
              "type": "string"
            }
          },
          "userId": {
            "title": "Seller user ID",
            "type": "string",
            "description": "Seller profile ID to fetch (mode fetchUser). UUID from listing data."
          },
          "clientPoolSize": {
            "title": "Parallel sessions",
            "minimum": 1,
            "maximum": 32,
            "type": "integer",
            "description": "Number of parallel HTTP sessions. Higher = faster but more anti-bot risk. 3-6 is typical.",
            "default": 4
          },
          "proxyConfiguration": {
            "title": "Proxy configuration",
            "type": "object",
            "description": "Recommended on Apify Cloud (Datadome). Datacenter IPs often show poor reputation — keep RESIDENTIAL + country FR. One proxy session per run is applied automatically. Password: Console → Proxy."
          }
        }
      },
      "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
                  }
                }
              }
            }
          }
        }
      }
    }
  }
}