{
  "openapi": "3.0.1",
  "info": {
    "title": "OLX Scraper: Romania, Portugal, Bulgaria, Ukraine Classifieds",
    "description": "OLX.ro, OLX.pt, OLX.bg and OLX.ua scraper and API (Romania, Portugal, Bulgaria, Ukraine): search by keyword, category, city, URL, filter by price, seller and date. One row per ad: title, full description, price, condition, private or business, attributes, city, posted time, photos. $0.50 per 1,000.",
    "version": "1.0",
    "x-build-id": "7Cwl34Pycnldm8Vca"
  },
  "servers": [
    {
      "url": "https://api.apify.com/v2"
    }
  ],
  "paths": {
    "/acts/rel8ble~olx-classifieds-scraper/run-sync-get-dataset-items": {
      "post": {
        "operationId": "run-sync-get-dataset-items-rel8ble-olx-classifieds-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/rel8ble~olx-classifieds-scraper/runs": {
      "post": {
        "operationId": "runs-sync-rel8ble-olx-classifieds-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/rel8ble~olx-classifieds-scraper/run-sync": {
      "post": {
        "operationId": "run-sync-rel8ble-olx-classifieds-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 keywords",
            "type": "array",
            "description": "Optional. What you would type into the OLX search box, one per line: \"iphone 13\", \"bicicleta\", \"ps5\", \"canapea\", \"bmw x5\". Each keyword is one search (times each country, category and location). Leave empty to list a whole category or city instead.",
            "items": {
              "type": "string"
            }
          },
          "countries": {
            "title": "Countries",
            "type": "array",
            "description": "Optional. Which OLX sites to search: ro (Romania, prices in RON), pt (Portugal, EUR), bg (Bulgaria, EUR), ua (Ukraine, UAH). Several = the same search on each site. Empty = Romania.",
            "items": {
              "type": "string",
              "enum": [
                "ro",
                "pt",
                "bg",
                "ua"
              ],
              "enumTitles": [
                "Romania (olx.ro)",
                "Portugal (olx.pt)",
                "Bulgaria (olx.bg)",
                "Ukraine (olx.ua)"
              ]
            }
          },
          "categories": {
            "title": "Categories",
            "type": "array",
            "description": "Optional. OLX categories, one per line, as the site names them in its own language, or by id or URL path: \"Telefoane\" or \"iPhone\" (olx.ro), \"Telemóveis\" (olx.pt), \"Телефони и таблети\" (olx.bg), \"Телефони та аксесуари\" (olx.ua), \"948\", \"electronice-si-electrocasnice/telefoane-mobile\". All categories of the four sites are built in. Unknown names are skipped with a warning.",
            "items": {
              "type": "string"
            }
          },
          "locations": {
            "title": "Cities or regions",
            "type": "array",
            "description": "Optional. Cities or regions as they appear in OLX URLs, one per line: \"bucuresti\", \"cluj-napoca\", \"cluj-judet\" (a Romanian county), \"lisboa\", \"porto\", \"sofiya\", \"varna\", \"kiev\", \"lvov\". Spaces and accents are fine (\"Cluj judet\"). A place OLX doesn't know returns a not-found warning, never a charge. Empty = the whole country.",
            "items": {
              "type": "string"
            }
          },
          "startUrls": {
            "title": "OLX URLs",
            "type": "array",
            "description": "Optional. OLX search, category or city pages copied from your browser (https://www.olx.ro/oferte/q-iphone/, https://www.olx.pt/telemoveis-e-tablets/telemoveis/lisboa/, https://www.olx.ua/uk/elektronika/kiev/q-iphone/). Filters in the URL (price, sort, page) are kept. Single ad pages are not read.",
            "items": {
              "type": "string"
            }
          },
          "priceMin": {
            "title": "Minimum price",
            "minimum": 0,
            "type": "integer",
            "description": "Optional. Lowest price, in the site's currency (RON on olx.ro, EUR on olx.pt and olx.bg, UAH on olx.ua). Sent to OLX as its own price filter."
          },
          "priceMax": {
            "title": "Maximum price",
            "minimum": 0,
            "type": "integer",
            "description": "Optional. Highest price, in the site's currency. Sent to OLX as its own price filter."
          },
          "sellerType": {
            "title": "Seller type",
            "enum": [
              "any",
              "private",
              "business"
            ],
            "type": "string",
            "description": "Optional. private = individuals, business = shops and companies (OLX's own private / business flag).",
            "default": "any"
          },
          "sortBy": {
            "title": "Sort order",
            "enum": [
              "relevance",
              "newest",
              "price_asc",
              "price_desc"
            ],
            "type": "string",
            "description": "Optional. Order OLX returns ads in. Use newest with postedWithinDays for new-ad alerts.",
            "default": "relevance"
          },
          "postedWithinDays": {
            "title": "Posted within (days)",
            "minimum": 0,
            "type": "integer",
            "description": "Optional. Keep only ads posted in the last N days (0 = today only). With sortBy newest the search stops at the first page of older ads."
          },
          "mustInclude": {
            "title": "Must include (any of these words)",
            "type": "array",
            "description": "Optional. Keep only ads whose title or description contains at least one of these words, e.g. \"256gb\", \"garantie\".",
            "items": {
              "type": "string"
            }
          },
          "excludeKeywords": {
            "title": "Exclude words",
            "type": "array",
            "description": "Optional. Drop ads whose title or description contains any of these words, e.g. \"husa\", \"case\", \"defect\". Dropped ads are free.",
            "items": {
              "type": "string"
            }
          },
          "skipPromoted": {
            "title": "Skip promoted ads",
            "type": "boolean",
            "description": "Optional. Leave out paid promoted (top) ads that OLX mixes into results.",
            "default": false
          },
          "maxItems": {
            "title": "Max ads per search",
            "minimum": 0,
            "type": "integer",
            "description": "How many ads to save per search (country x keyword x category x location). 0 = all OLX shows (up to 1,000 per search; split by category or city for more).",
            "default": 100
          },
          "maxPagesPerSearch": {
            "title": "Max pages per search",
            "minimum": 1,
            "maximum": 25,
            "type": "integer",
            "description": "Safety cap on results pages read per search (40 ads per page, OLX stops at 25).",
            "default": 25
          },
          "maxConcurrency": {
            "title": "Max concurrency",
            "minimum": 1,
            "maximum": 10,
            "type": "integer",
            "description": "Pages fetched in parallel. 3 is polite and fast enough (about 1,000 ads per minute).",
            "default": 3
          },
          "maxRequestRetries": {
            "title": "Max retries per page",
            "minimum": 0,
            "maximum": 15,
            "type": "integer",
            "description": "Retries for a page that fails or is blocked (each on a new session / IP).",
            "default": 6
          },
          "proxyConfiguration": {
            "title": "Proxy",
            "type": "object",
            "description": "Apify Proxy (datacenter) is the default and is included in the price.",
            "default": {
              "useApifyProxy": true
            }
          }
        }
      },
      "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
                  }
                }
              }
            }
          }
        }
      }
    }
  }
}