{
  "openapi": "3.0.1",
  "info": {
    "title": "Subito.it Scraper - Italian Classifieds & Seller Leads",
    "description": "Scrape Subito.it, Italy's #1 classifieds. Cars, motorbikes, real estate, jobs, electronics & more — real prices, full geo (region/province/town), car & property specs, images, descriptions and the advertiser. Filter by category, location, price & ad type. Export JSON, CSV, Excel.",
    "version": "0.1",
    "x-build-id": "3DZpBwxyp9alr9VTc"
  },
  "servers": [
    {
      "url": "https://api.apify.com/v2"
    }
  ],
  "paths": {
    "/acts/scrapesage~subito-scraper/run-sync-get-dataset-items": {
      "post": {
        "operationId": "run-sync-get-dataset-items-scrapesage-subito-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/scrapesage~subito-scraper/runs": {
      "post": {
        "operationId": "runs-sync-scrapesage-subito-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/scrapesage~subito-scraper/run-sync": {
      "post": {
        "operationId": "run-sync-scrapesage-subito-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": {
          "mode": {
            "title": "What to scrape",
            "enum": [
              "listings",
              "sellerLeads"
            ],
            "type": "string",
            "description": "<b>Listings</b> = classified ads matching your search (the default). <b>Seller leads</b> = deduplicated <i>business</i> advertisers (pro shops, dealers, agencies) aggregated into B2B lead records with shop name, location, listing count, price range & a 0–100 lead score.",
            "default": "listings"
          },
          "searchQueries": {
            "title": "Search queries",
            "type": "array",
            "description": "Keywords to search on Subito, e.g. <code>iphone 15</code>, <code>bici da corsa</code>, <code>divano</code>, <code>bmw serie 3</code>. Each query is combined with the filters below. Leave empty to browse purely by category and/or location.",
            "items": {
              "type": "string"
            }
          },
          "startUrls": {
            "title": "Start URLs",
            "type": "array",
            "description": "Direct Subito URLs: search/listing pages (<code>https://www.subito.it/annunci-lombardia/vendita/usato/?q=...</code>) or individual ad pages (<code>.../...-123456789.htm</code>). Used in addition to search queries; query parameters in the URL (q, category, region, price) are honored.",
            "items": {
              "type": "object",
              "required": [
                "url"
              ],
              "properties": {
                "url": {
                  "type": "string",
                  "title": "URL of a web page",
                  "format": "uri"
                }
              }
            }
          },
          "category": {
            "title": "Category",
            "type": "string",
            "description": "Filter by category — Italian name or numeric id. Macro categories: <code>Motori</code>, <code>Immobili</code>, <code>Lavoro e Servizi</code>, <code>Elettronica</code>, <code>Per la casa e la persona</code>, <code>Sports e Hobby</code>. Common sub-categories: <code>Auto</code>, <code>Moto e Scooter</code>, <code>Appartamenti</code>, <code>Offerte di lavoro</code>, <code>Telefonia</code>, <code>Informatica</code>, <code>Arredamento e Casalinghi</code>, <code>Abbigliamento e Accessori</code>, <code>Biciclette</code>."
          },
          "adType": {
            "title": "Ad type",
            "enum": [
              "sale",
              "wanted",
              "any"
            ],
            "type": "string",
            "description": "<b>For sale</b> (default) = items/properties/jobs offered. <b>Wanted</b> = \"cerco\" ads from buyers looking for something. <b>Any</b> = both.",
            "default": "sale"
          },
          "region": {
            "title": "Region",
            "type": "string",
            "description": "Italian region name to limit results to, e.g. <code>Lombardia</code>, <code>Lazio</code>, <code>Campania</code>, <code>Veneto</code>, <code>Sicilia</code>, <code>Piemonte</code>, <code>Toscana</code>. Leave empty for all of Italy."
          },
          "city": {
            "title": "Province / city",
            "type": "string",
            "description": "Province (provincia) name within the region, e.g. <code>Milano</code>, <code>Roma</code>, <code>Napoli</code>, <code>Torino</code>, <code>Bologna</code>. Requires a region."
          },
          "town": {
            "title": "Town (comune)",
            "type": "string",
            "description": "Specific town/comune within the province, e.g. <code>Monza</code>, <code>Sesto San Giovanni</code>. Requires region + province."
          },
          "priceMin": {
            "title": "Min price (€)",
            "minimum": 0,
            "type": "integer",
            "description": "Only ads at or above this price, in euros."
          },
          "priceMax": {
            "title": "Max price (€)",
            "minimum": 0,
            "type": "integer",
            "description": "Only ads at or below this price, in euros."
          },
          "advertiserType": {
            "title": "Advertiser type",
            "enum": [
              "any",
              "private",
              "business"
            ],
            "type": "string",
            "description": "Filter by who is selling. <b>Business</b> = pro shops, dealers and agencies only (great for lead-gen). <b>Private</b> = individuals only. <b>Any</b> = both.",
            "default": "any"
          },
          "onlyShippable": {
            "title": "Shippable only",
            "type": "boolean",
            "description": "Only ads available for shipping (TuttoSubito).",
            "default": false
          },
          "onlyUrgent": {
            "title": "Urgent only",
            "type": "boolean",
            "description": "Only ads flagged as urgent.",
            "default": false
          },
          "searchTitleOnly": {
            "title": "Search in title only",
            "type": "boolean",
            "description": "Match the search query against the ad title only (not the description) for tighter, higher-relevance results.",
            "default": false
          },
          "sort": {
            "title": "Sort order",
            "enum": [
              "newest",
              "relevance",
              "price_asc",
              "price_desc"
            ],
            "type": "string",
            "description": "How to order results.",
            "default": "newest"
          },
          "emitSellerLeads": {
            "title": "Also emit business seller leads (Listings mode)",
            "type": "boolean",
            "description": "In Listings mode, also push one deduplicated lead record (type = \"sellerLead\") for every unique <i>business</i> advertiser found — with shop name, location, listing count, price range and a 0–100 lead score.",
            "default": false
          },
          "businessSellersOnly": {
            "title": "Business sellers only (Listings mode)",
            "type": "boolean",
            "description": "In Listings mode, restrict the ads themselves to business / pro advertisers (excludes private individuals).",
            "default": false
          },
          "maxResults": {
            "title": "Max results",
            "minimum": 1,
            "type": "integer",
            "description": "Maximum number of listings to scrape across all queries. Subito has tens of thousands of ads per query — use category, location and price filters to focus.",
            "default": 200
          },
          "maxSellerLeads": {
            "title": "Max seller leads",
            "minimum": 1,
            "type": "integer",
            "description": "Maximum number of business seller-lead records to emit (Seller-leads mode, or when \"also emit seller leads\" is on).",
            "default": 500
          },
          "deduplicateResults": {
            "title": "Deduplicate within a run",
            "type": "boolean",
            "description": "Skip records already emitted in this run (recommended).",
            "default": true
          },
          "monitorMode": {
            "title": "Monitoring mode — only new records",
            "type": "boolean",
            "description": "Remember ids across runs in a named key-value store and emit ONLY records not seen before (new ads, new sellers). Perfect for deal alerts and price-watching. Works with Apify Schedules.",
            "default": false
          },
          "monitorKey": {
            "title": "Monitor key",
            "type": "string",
            "description": "Names the memory used by monitoring mode. Use a distinct key per saved search so different watches don't share state.",
            "default": "default"
          },
          "maxConcurrency": {
            "title": "Max concurrency",
            "minimum": 1,
            "maximum": 20,
            "type": "integer",
            "description": "Maximum parallel requests. Subito's API is fast; 6–10 is a good balance.",
            "default": 6
          },
          "proxyConfiguration": {
            "title": "Proxy configuration",
            "type": "object",
            "description": "Proxy settings. Residential proxies (Italy) are strongly recommended and used by default — Subito's data API serves residential IPs reliably; datacenter IPs are throttled.",
            "default": {
              "useApifyProxy": true,
              "apifyProxyGroups": [
                "RESIDENTIAL"
              ],
              "apifyProxyCountry": "IT"
            }
          },
          "urlsFromFile": {
            "title": "Import URLs from a file",
            "type": "string",
            "description": "Paste a list of URLs (one per line), OR one link to a .txt/.csv file, Google Sheet or Google Drive file containing them. Lets you import many Start URLs at once instead of typing each. Google Sheet/Drive share links are handled automatically."
          }
        }
      },
      "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
                  }
                }
              }
            }
          }
        }
      }
    }
  }
}