{
  "openapi": "3.0.1",
  "info": {
    "title": "Njuskalo Scraper: Croatian Classified Ads Search",
    "description": "Search Njuskalo, the Croatian classifieds site, by keyword or category. Each ad has title, price, date, link and main photo. Also the newest ads, ad counts, search suggestions, category trees, filter lists, popular brands and place lookups.",
    "version": "1.0",
    "x-build-id": "f4siiG9g86ooBTHUm"
  },
  "servers": [
    {
      "url": "https://api.apify.com/v2"
    }
  ],
  "paths": {
    "/acts/happyendpoint~njuskalo-classifieds-search-scraper/run-sync-get-dataset-items": {
      "post": {
        "operationId": "run-sync-get-dataset-items-happyendpoint-njuskalo-classifieds-search-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/happyendpoint~njuskalo-classifieds-search-scraper/runs": {
      "post": {
        "operationId": "runs-sync-happyendpoint-njuskalo-classifieds-search-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/happyendpoint~njuskalo-classifieds-search-scraper/run-sync": {
      "post": {
        "operationId": "run-sync-happyendpoint-njuskalo-classifieds-search-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": [
          "operation"
        ],
        "properties": {
          "operation": {
            "title": "Operation",
            "enum": [
              "searchSuggestions",
              "search",
              "searchCount",
              "searchByCategory",
              "latest",
              "geocode",
              "reverseGeocode",
              "categoryNavigation",
              "categoryDetail",
              "filterOptions",
              "recommendedCategories",
              "trendingCategories",
              "popularBrands"
            ],
            "type": "string",
            "description": "Which data to fetch. Each option is one kind of request."
          },
          "maxItems": {
            "title": "Maximum results",
            "minimum": 1,
            "maximum": 1000,
            "type": "integer",
            "description": "The most results to return. The run stops once it has this many.",
            "default": 100
          },
          "query": {
            "title": "Search words",
            "maxLength": 200,
            "type": "string",
            "description": "Words to look for in the ads. For Search suggestions they are the start of a term. Search ads and Count matching ads cannot run without them. Used by: Search suggestions, Search ads, Count matching ads."
          },
          "mainCategory": {
            "title": "Main category number",
            "minimum": 0,
            "maximum": 2000000000,
            "type": "integer",
            "description": "The number of a top-level category, the ID of a Trending categories or Recommended categories row. Ads in a category, Category navigation and Filter options cannot run without it. Latest ads can use it to narrow the list. Used by: Ads in a category, Latest ads, Category navigation, Filter options."
          },
          "category": {
            "title": "Subcategory number",
            "minimum": 0,
            "maximum": 2000000000,
            "type": "integer",
            "description": "Narrows Ads in a category to one subcategory of the main category. It must be a category with no further subcategories, marked as a leaf in Category navigation. Used by: Ads in a category."
          },
          "categoryIds": {
            "title": "Category numbers",
            "pattern": "^[0-9]{1,10}(,[0-9]{1,10}){0,49}$",
            "type": "string",
            "description": "Category numbers to describe, separated by commas. Used by: Category details."
          },
          "location": {
            "title": "Place text",
            "maxLength": 200,
            "type": "string",
            "description": "The start of a town, district or address, for Find a place. Used by: Find a place."
          },
          "locationId": {
            "title": "Place number",
            "minimum": 0,
            "maximum": 2000000000,
            "type": "integer",
            "description": "Only ads from this county. Use a top-level number from the locality list of a Find a place row. Used by: Ads in a category."
          },
          "latitude": {
            "title": "Latitude",
            "minimum": -90,
            "maximum": 90,
            "type": "number",
            "description": "Latitude of a map point in decimal degrees. Place at coordinates cannot run without it. Used by: Place at coordinates."
          },
          "longitude": {
            "title": "Longitude",
            "minimum": -180,
            "maximum": 180,
            "type": "number",
            "description": "Longitude of a map point in decimal degrees. Pair it with Latitude. Used by: Place at coordinates."
          },
          "minPrice": {
            "title": "Lowest price",
            "minimum": 0,
            "maximum": 1000000000,
            "type": "number",
            "description": "Only ads priced at or above this amount. Used by: Search ads, Count matching ads, Ads in a category."
          },
          "maxPrice": {
            "title": "Highest price",
            "minimum": 0,
            "maximum": 1000000000,
            "type": "number",
            "description": "Only ads priced at or below this amount. Used by: Search ads, Count matching ads, Ads in a category."
          },
          "hasPhotos": {
            "title": "Only ads with photos",
            "type": "boolean",
            "description": "Skip ads that have no photo. Used by: Search ads, Count matching ads, Ads in a category."
          },
          "titleOnly": {
            "title": "Search titles only",
            "type": "boolean",
            "description": "Look for the search words in ad titles alone; ad texts are skipped. Used by: Search ads, Count matching ads."
          },
          "payProtect": {
            "title": "Payment protection only",
            "type": "boolean",
            "description": "Only ads marked with the site's payment protection option. Used by: Search ads, Count matching ads, Ads in a category."
          },
          "sort": {
            "title": "Order of results",
            "enum": [
              "relevance",
              "old",
              "new",
              "expensive",
              "cheap"
            ],
            "type": "string",
            "description": "How to order the ads. Leave it empty for the site default. Used by: Search ads, Ads in a category."
          }
        }
      },
      "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
                  }
                }
              }
            }
          }
        }
      }
    }
  }
}