{
  "openapi": "3.0.1",
  "info": {
    "title": "Avito Scraper · Парсер объявлений Авито",
    "description": "Avito listings from search results and listing pages: title, price, city, text, attributes, photos, address, seller name and profile. Объявления Авито из выдачи и со страниц: заголовок, цена, город, текст, характеристики, фото, адрес, имя и профиль продавца.",
    "version": "0.1",
    "x-build-id": "o7vTA0qa3CNwZl4qG"
  },
  "servers": [
    {
      "url": "https://api.apify.com/v2"
    }
  ],
  "paths": {
    "/acts/theshark~avito-scraper/run-sync-get-dataset-items": {
      "post": {
        "operationId": "run-sync-get-dataset-items-theshark-avito-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/theshark~avito-scraper/runs": {
      "post": {
        "operationId": "runs-sync-theshark-avito-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/theshark~avito-scraper/run-sync": {
      "post": {
        "operationId": "run-sync-theshark-avito-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": {
          "urls": {
            "title": "Avito links · Ссылки Авито",
            "type": "array",
            "description": "Links to search results or to single listings, for example a category in a city. Set links, queries, or both.<br><br>Ссылки на выдачу или на отдельные объявления, например раздел в городе. Нужны ссылки, запросы или и то и другое.",
            "default": [],
            "items": {
              "type": "string"
            }
          },
          "queries": {
            "title": "Search queries · Поисковые запросы",
            "type": "array",
            "description": "Text searches, for example «iphone 15». They run in the city below.<br><br>Текстовый поиск, например «iphone 15». Ищет в городе ниже.",
            "default": [],
            "items": {
              "type": "string"
            }
          },
          "city": {
            "title": "City for search queries · Город для запросов",
            "type": "string",
            "description": "The city as it appears in Avito links: moskva, kazan, sankt-peterburg. rossiya searches the whole country.<br><br>Город, как в ссылках Авито: moskva, kazan, sankt-peterburg. rossiya — вся страна.",
            "default": "rossiya"
          },
          "max_items": {
            "title": "Listings limit · Сколько объявлений",
            "minimum": 1,
            "maximum": 5000,
            "type": "integer",
            "description": "The most listings one run returns. It is shared evenly between your links and queries. Above 1500 from one search, it is taken newest first: in its default order Avito shows no more than 30 pages.<br><br>Больше этого запуск не отдаст. Делится поровну между ссылками и запросами. Больше 1500 с одной выдачи берутся по дате: в обычном порядке Авито показывает не больше 30 страниц.",
            "default": 100
          },
          "open_items": {
            "title": "Open listing pages · Открывать объявления",
            "type": "boolean",
            "description": "On: full text, attributes, views and the seller in full (type, since when on Avito, listings, badges) from each listing page. Off: search result cards only, faster and cheaper.<br><br>Включено: полный текст, характеристики, просмотры и продавец полностью (тип, стаж, объявления, значки) со страницы каждого объявления. Выключено: только карточки выдачи, быстрее и дешевле.",
            "default": true
          },
          "new_only": {
            "title": "Only new listings · Только новые",
            "type": "boolean",
            "description": "Skip listings returned by your previous runs (they are remembered in the history store). The search goes newest first and stops where your previous runs' listings begin.<br><br>Пропускать объявления, которые отдали прошлые запуски (они запоминаются в хранилище истории). Выдача идёт по дате и останавливается там, где начинаются объявления прошлых запусков.",
            "default": false
          },
          "track_prices": {
            "title": "Track prices · Следить за ценами",
            "type": "boolean",
            "description": "Compare each listing's price with your previous runs: price_status (new, same, cheaper, pricier), previous_price, price_change and price_history. Run it on a schedule with the same links. Not together with Only new listings.<br><br>Сравнивать цену каждого объявления с прошлыми запусками: price_status (new, same, cheaper, pricier), previous_price, price_change и price_history. Запускайте по расписанию с теми же ссылками. Не вместе с «Только новые».",
            "default": false
          },
          "sessions": {
            "title": "Sessions at once · Сессий одновременно",
            "minimum": 1,
            "maximum": 32,
            "type": "integer",
            "description": "How many anonymous visitors work at the same time, each with its own IP. More sessions need more browsers: about 2 sessions per browser.<br><br>Сколько анонимных посетителей работают одновременно, у каждого свой IP. Больше сессий — больше браузеров: примерно 2 сессии на браузер.",
            "default": 4
          },
          "browsers": {
            "title": "Browsers at once · Браузеров одновременно",
            "minimum": 1,
            "maximum": 8,
            "type": "integer",
            "description": "Browser tabs that get new sessions at the same time. Each needs 256 MB of memory: 1 GB of run memory fits 2.<br><br>Вкладки браузера, которые одновременно добывают новые сессии. Каждой нужно 256 МБ памяти: в 1 ГБ запуска помещаются 2.",
            "default": 2
          },
          "proxy": {
            "title": "Your own proxies · Свои прокси",
            "type": "string",
            "description": "Optional. One per line: user:pass@host:port. Without them the run uses its own Russian proxies.<br><br>Необязательно. По одному в строке: user:pass@host:port. Без них запуск идёт через свои российские прокси."
          },
          "history_store": {
            "title": "History store · Хранилище истории",
            "type": "string",
            "description": "Named key-value store that keeps sessions, the listings you already got and the prices between runs.<br><br>Именованное хранилище: в нём между запусками лежат сессии, уже отданные объявления и цены.",
            "default": "avito-history"
          },
          "output_language": {
            "title": "Language of the log and status · Язык лога и статуса",
            "enum": [
              "en",
              "ru"
            ],
            "type": "string",
            "description": "Avito's own data stays as the site gives it.<br><br>Данные Авито остаются как на сайте.",
            "default": "en"
          }
        }
      },
      "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
                  }
                }
              }
            }
          }
        }
      }
    }
  }
}