{
  "openapi": "3.0.1",
  "info": {
    "title": "Florida Contractor Directory & Leads Scraper (DBPR)",
    "description": "Export Florida contractors by county from the DBPR registry, or look up a license by DBPR number or business name: license type, status, expiration, address, phone where found. $0.002 per row, plus $0.002 per phone added (optional); a no-match is a free notice.",
    "version": "0.0",
    "x-build-id": "wI7H8PjfXdCqfyvvx"
  },
  "servers": [
    {
      "url": "https://api.apify.com/v2"
    }
  ],
  "paths": {
    "/acts/scrapebench~florida-contractor-directory-leads-scraper/run-sync-get-dataset-items": {
      "post": {
        "operationId": "run-sync-get-dataset-items-scrapebench-florida-contractor-directory-leads-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/scrapebench~florida-contractor-directory-leads-scraper/runs": {
      "post": {
        "operationId": "runs-sync-scrapebench-florida-contractor-directory-leads-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/scrapebench~florida-contractor-directory-leads-scraper/run-sync": {
      "post": {
        "operationId": "run-sync-scrapebench-florida-contractor-directory-leads-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": "Mode",
            "enum": [
              "auto",
              "lookup",
              "export"
            ],
            "type": "string",
            "description": "auto (default): licence numbers or names in 'Look up licences' run a lookup, otherwise a county export runs. lookup: find licences by DBPR licence number or business / person name, statewide. export: every licensee of the chosen licence types in the chosen counties, names and numbers ignored.",
            "default": "auto"
          },
          "queries": {
            "title": "Look up licences (numbers or names)",
            "type": "array",
            "description": "DBPR licence numbers ('CGC1514724') or business / person names, one per line. Each name is searched in DBPR's business and person indexes on the Construction Industry and Electrical Contractors boards; each match is enriched from its DBPR detail page (issue date, county) unless 'Add licence details' is off. Leave empty to export by county.",
            "default": [],
            "items": {
              "type": "string"
            }
          },
          "query": {
            "title": "Look up one licence",
            "type": "string",
            "description": "One licence number or name; same as the list above. Prefer `queries` (a list); this single field stays for saved tasks."
          },
          "includeDetails": {
            "title": "Add licence details (lookup)",
            "type": "boolean",
            "description": "Lookup only: fetch each match's DBPR detail page for issue date, county and the full licence type. Slower; same price.",
            "default": true
          },
          "listCountiesOnly": {
            "title": "List counties only (Discovery Mode)",
            "type": "boolean",
            "description": "When true, the actor returns all available Florida counties from the DBPR portal and exits immediately (< 10 seconds, no charge). Use this to discover the exact county name to pass into Scrape Mode.",
            "default": false
          },
          "county": {
            "title": "County",
            "type": "string",
            "description": "One Florida county to export: full name ('Hillsborough') or DBPR numeric code ('39'). 'Miami-Dade County' resolves to DBPR's 'Dade', 'Saint Lucie' to 'St. Lucie'. Prefer `counties` (a list); this single field stays for saved tasks. A missing or unrecognised county returns the free county list instead of failing."
          },
          "counties": {
            "title": "County (batch)",
            "type": "array",
            "description": "Preferred: several counties in ONE run, same values as 'County' (name or DBPR code). Combined with 'County' if you fill both; duplicates removed. You are charged per record returned, not per county.",
            "default": [],
            "items": {
              "type": "string"
            }
          },
          "board": {
            "title": "Board / license category code",
            "type": "string",
            "description": "DBPR board code to filter by. Default '06' = Construction Industry (the main contractor board covering General, Building, Residential, and specialty contractors). Contact DBPR or run Discovery Mode to find codes for other boards.",
            "default": "06"
          },
          "licenseType": {
            "title": "License type code",
            "type": "string",
            "description": "DBPR license type code within the selected board. Default '0605' = Certified General Contractor (Board 06). Use '0600' for all license types within the board (if supported by the portal).",
            "default": "0605"
          },
          "licenseTypes": {
            "title": "Licence types (export)",
            "type": "array",
            "description": "Several licence types in one export: DBPR codes ('0605' Certified General, '0603' Certified Roofing, '0616' Registered Roofing) or 'roofing' (= 0603 + 0616), 'CCC', 'RC', 'CGC'. Overrides 'License type code' when set.",
            "default": [],
            "items": {
              "type": "string"
            }
          },
          "statuses": {
            "title": "Statuses",
            "type": "array",
            "description": "Keep only these: active (Current, active), inactive (Current, inactive), suspended, or all. Empty = every row DBPR lists, as before.",
            "default": [],
            "items": {
              "type": "string"
            }
          },
          "status": {
            "title": "Status",
            "type": "string",
            "description": "One status; same as Statuses."
          },
          "expiresAfter": {
            "title": "Expires on or after",
            "type": "string",
            "description": "Only licences expiring on or after this date (YYYY-MM-DD). With 'Expires on or before' it lists licences due for renewal in a window."
          },
          "expiresBefore": {
            "title": "Expires on or before",
            "type": "string",
            "description": "Only licences expiring on or before this date (YYYY-MM-DD)."
          },
          "registers": {
            "title": "Registers",
            "type": "array",
            "description": "Registers to search: 'dbpr' (default when empty) = DBPR construction licences; 'fire-protection' = State Fire Marshal Fire Protection Contractors (about 4,750, every status; company, qualifier, county, street address, class; no phone or email). Give both for both; 'fire-protection' alone skips DBPR. For it, Look up licences, Counties and the Expires inputs filter and Maximum results caps; with no look-up entries it exports the register. Other DBPR inputs apply only to 'dbpr'.",
            "default": [],
            "items": {
              "type": "string"
            }
          },
          "maxResults": {
            "title": "Maximum results",
            "minimum": 1,
            "maximum": 50000,
            "type": "integer",
            "description": "Each returned row is billed ($0.002). Cap on records PER ENTRY (per county or query), not per run. A county plus license type can have thousands of rows; set it low for a first call. Default 500.",
            "default": 500
          },
          "proxyConfiguration": {
            "title": "Proxy configuration",
            "type": "object",
            "description": "Optional. The DBPR portal is usually reachable directly from Apify's datacenter IPs. Enable a proxy (e.g. residential) only if a run is blocked or served a challenge page.",
            "default": {
              "useApifyProxy": false
            }
          },
          "includeContacts": {
            "title": "Include contact details",
            "type": "boolean",
            "description": "Where the board publishes no phone for a business, add one (with its website and street address when found), looked up by business name. Charged as a separate 'Contact details found' event only on a row that gets a phone; a row without one costs only the row price. Turn off for the licence list alone.",
            "default": true
          }
        }
      },
      "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
                  }
                }
              }
            }
          }
        }
      }
    }
  }
}