{
  "openapi": "3.0.1",
  "info": {
    "title": "OLX.pl Listings Scraper",
    "description": "Scrape OLX.pl listings at scale — price, description, location with GPS, attributes, photos, seller info and delivery — from any keyword, category or URL. Optional phone reveal. Reliable official-API source, structured JSON. Pay only for the results you get.",
    "version": "1.0",
    "x-build-id": "nSSEgyhgpgtQCSgAT"
  },
  "servers": [
    {
      "url": "https://api.apify.com/v2"
    }
  ],
  "paths": {
    "/acts/axlymxp~olx-pl-listings-scraper/run-sync-get-dataset-items": {
      "post": {
        "operationId": "run-sync-get-dataset-items-axlymxp-olx-pl-listings-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/axlymxp~olx-pl-listings-scraper/runs": {
      "post": {
        "operationId": "runs-sync-axlymxp-olx-pl-listings-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/axlymxp~olx-pl-listings-scraper/run-sync": {
      "post": {
        "operationId": "run-sync-axlymxp-olx-pl-listings-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": {
          "searchQuery": {
            "title": "Search query",
            "type": "string",
            "description": "Free-text keywords to search on OLX.pl, e.g. \"iphone 15\" or \"mieszkanie\". Optional if you provide a Category ID or Start URLs."
          },
          "startUrls": {
            "title": "Start URLs (OLX search/category pages)",
            "type": "array",
            "description": "Paste one or more OLX.pl category or search-result URLs. Each is resolved to its search parameters automatically. Overrides Search query / Category ID.",
            "items": {
              "type": "object",
              "required": [
                "url"
              ],
              "properties": {
                "url": {
                  "type": "string",
                  "title": "URL of a web page",
                  "format": "uri"
                }
              }
            }
          },
          "categoryId": {
            "title": "Category ID",
            "type": "integer",
            "description": "OLX.pl numeric category id (e.g. cars = 84, flats = 15, phones = 1838). Tip: paste a category URL in Start URLs instead if you don't know the id."
          },
          "locationQuery": {
            "title": "Location (city or district name)",
            "type": "string",
            "description": "Free-text location, e.g. \"Warszawa\" or \"Kraków Podgórze\". Resolved to region/city/district ids automatically. Ignored if you set explicit ids below."
          },
          "regionId": {
            "title": "Region ID",
            "type": "integer",
            "description": "Explicit OLX region (voivodeship) id. Optional."
          },
          "cityId": {
            "title": "City ID",
            "type": "integer",
            "description": "Explicit OLX city id. Optional."
          },
          "districtId": {
            "title": "District ID",
            "type": "integer",
            "description": "Explicit OLX district id. Optional."
          },
          "distance": {
            "title": "Distance (km)",
            "minimum": 0,
            "type": "integer",
            "description": "Radius in kilometres around the selected city."
          },
          "ownerType": {
            "title": "Seller type",
            "enum": [
              "any",
              "private",
              "business"
            ],
            "type": "string",
            "description": "Restrict to private or business sellers.",
            "default": "any"
          },
          "priceMin": {
            "title": "Min price (PLN)",
            "minimum": 0,
            "type": "integer",
            "description": "Minimum price in Polish złoty."
          },
          "priceMax": {
            "title": "Max price (PLN)",
            "minimum": 0,
            "type": "integer",
            "description": "Maximum price in Polish złoty."
          },
          "sortBy": {
            "title": "Sort order",
            "enum": [
              "newest",
              "price_asc",
              "price_desc",
              "relevance"
            ],
            "type": "string",
            "description": "Ordering of results.",
            "default": "newest"
          },
          "filters": {
            "title": "Advanced filters (raw)",
            "type": "object",
            "description": "Extra OLX filter parameters passed through verbatim, e.g. {\"filter_enum_state\": [\"used\"], \"filter_float_year:from\": 2015}. For power users."
          },
          "includePhone": {
            "title": "Reveal seller phone numbers",
            "type": "boolean",
            "description": "Fetch each listing's phone number (one extra request per listing; some sellers hide it). Slower but adds direct contact data.",
            "default": false
          },
          "engine": {
            "title": "Search engine",
            "enum": [
              "graphql",
              "rest"
            ],
            "type": "string",
            "description": "GraphQL returns the richest per-listing data (business profile, delivery, all attributes) in one call. REST is a lighter alternative.",
            "default": "graphql"
          },
          "maxItems": {
            "title": "Max results",
            "minimum": 1,
            "type": "integer",
            "description": "Stop after this many listings. OLX caps deep pagination at ~1000 results per search.",
            "default": 100
          },
          "proxyConfiguration": {
            "title": "Proxy configuration",
            "type": "object",
            "description": "Optional. The OLX.pl API works proxy-free; enable a proxy only for very high volume.",
            "default": {
              "useApifyProxy": false
            }
          }
        }
      },
      "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
                  }
                }
              }
            }
          }
        }
      }
    }
  }
}