{
  "openapi": "3.0.1",
  "info": {
    "title": "Imenik Serbia Scraper",
    "description": "Scrape imenik.rs, Serbia's business directory. Search by keyword, browse by city or category, and extract business name, address, phone, email, website, working hours, rating, and description.",
    "version": "1.0",
    "x-build-id": "vnz5od48F09jyjbyL"
  },
  "servers": [
    {
      "url": "https://api.apify.com/v2"
    }
  ],
  "paths": {
    "/acts/crawlerbros~imenik-rs-scraper/run-sync-get-dataset-items": {
      "post": {
        "operationId": "run-sync-get-dataset-items-crawlerbros-imenik-rs-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/crawlerbros~imenik-rs-scraper/runs": {
      "post": {
        "operationId": "runs-sync-crawlerbros-imenik-rs-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/crawlerbros~imenik-rs-scraper/run-sync": {
      "post": {
        "operationId": "run-sync-crawlerbros-imenik-rs-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",
        "required": [
          "mode"
        ],
        "properties": {
          "mode": {
            "title": "Mode",
            "enum": [
              "search",
              "byCity",
              "byCategory"
            ],
            "type": "string",
            "description": "What to fetch: free-text keyword search, browse all businesses in a city, or browse all businesses in a category.",
            "default": "search"
          },
          "searchQuery": {
            "title": "Search query (mode=search)",
            "type": "string",
            "description": "Free-text keyword: a business name, trade, or service, e.g. \"restoran\", \"advokat\", \"auto servis\". Can be combined with City and Category below to narrow results.",
            "default": "restoran"
          },
          "city": {
            "title": "City (mode=byCity)",
            "enum": [
              "",
              "Beograd",
              "Novi Sad",
              "Niš",
              "Kragujevac",
              "Subotica",
              "Zrenjanin",
              "Pančevo",
              "Čačak",
              "Kraljevo",
              "Novi Pazar",
              "Leskovac",
              "Vranje",
              "Šabac",
              "Sombor",
              "Požarevac",
              "Pirot",
              "Zaječar",
              "Kruševac",
              "Valjevo",
              "Užice",
              "Vršac",
              "Bor",
              "Prokuplje",
              "Smederevo",
              "Sremska Mitrovica",
              "Loznica",
              "Jagodina",
              "Vrbas",
              "Inđija",
              "Ruma",
              "Senta",
              "Kikinda",
              "Bačka Palanka",
              "Sremski Karlovci",
              "Aranđelovac",
              "Gornji Milanovac",
              "Paraćin",
              "Trstenik",
              "Vrnjačka Banja",
              "Sjenica",
              "Tutin",
              "Priboj",
              "Ivanjica",
              "Sokobanja",
              "Bečej",
              "Temerin",
              "Stara Pazova",
              "Pećinci"
            ],
            "type": "string",
            "description": "A curated list of Serbia's major cities and towns. Required for mode=byCity; optional filter for search/byCategory. Leave as \"No city filter\" together with 'Custom city' below for nationwide results.",
            "default": ""
          },
          "customCity": {
            "title": "Custom city (overrides selection above)",
            "type": "string",
            "description": "Any Serbian city, town, or village not in the curated list above, matched against imenik.rs's own ~594 registered locations (diacritics-insensitive, e.g. \"Backa Topola\" matches \"Bačka Topola\"). Takes priority over 'City' when set."
          },
          "category": {
            "title": "Category (mode=byCategory)",
            "enum": [
              "",
              "Automobili",
              "Deca, Bebe",
              "Država i društvo",
              "Građevinarstvo",
              "Hoteli, Putovanja",
              "Hrana, Piće",
              "Industrija",
              "Kuća, Bašta",
              "Kućni ljubimci",
              "Kultura, Zabava",
              "Lepota, Spa",
              "Mašine, Alati",
              "Medicina, Zdravlje",
              "Mediji, Marketing",
              "Odeća, Moda",
              "Poljoprivreda",
              "Poslovni svet",
              "Restorani, Cafe",
              "Servisi, usluge",
              "Škole, Fakulteti",
              "Sport, Fitness",
              "Tehnika, Elektronika",
              "Transport, Špedicija",
              "Trgovina"
            ],
            "type": "string",
            "description": "One of imenik.rs's 24 top-level business categories. Required for mode=byCategory; optional filter for search/byCity. Leave as \"No category filter\" together with 'Custom subcategory' below for all categories.",
            "default": ""
          },
          "customSubcategory": {
            "title": "Custom subcategory (overrides selection above)",
            "type": "string",
            "description": "Any of imenik.rs's ~376 subcategories not exposed above, matched by exact Serbian name (diacritics-insensitive), e.g. \"Auto servisi\", \"Advokati\", \"Frizerski saloni\", \"Veterinari\". Takes priority over 'Category' when set. See the README for the full subcategory list."
          },
          "sortBy": {
            "title": "Sort order",
            "enum": [
              "relevance",
              "rating",
              "name"
            ],
            "type": "string",
            "description": "How to order results after fetching. imenik.rs itself only returns relevance/listing order; 'rating' and 'name' are applied client-side across the fetched batch.",
            "default": "relevance"
          },
          "minRating": {
            "title": "Minimum rating",
            "minimum": 0,
            "maximum": 5,
            "type": "integer",
            "description": "Only return businesses rated at least this many stars, e.g. 4 for 4.0+. 0 means no minimum. Businesses with no rating are excluded once this is set above 0.",
            "default": 0
          },
          "maxItems": {
            "title": "Max items",
            "minimum": 1,
            "maximum": 500,
            "type": "integer",
            "description": "Hard cap on the number of business records to return.",
            "default": 20
          }
        }
      },
      "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
                  }
                }
              }
            }
          }
        }
      }
    }
  }
}