{
  "openapi": "3.0.1",
  "info": {
    "title": "Florida Building Permits & Code Violation Leads",
    "description": "Fresh Florida building permits and open code-violation cases from official Miami, Miami-Dade and Orlando open-data feeds. Filter by trade, value or keyword; optional 0-100 lead scores for roofers, solar/HVAC installers, suppliers and property investors. No phones or emails scraped.",
    "version": "0.0",
    "x-build-id": "rMyXzwdx7jU1lZ3c4"
  },
  "servers": [
    {
      "url": "https://api.apify.com/v2"
    }
  ],
  "paths": {
    "/acts/open-records-data~florida-building-permits-code-violations/run-sync-get-dataset-items": {
      "post": {
        "operationId": "run-sync-get-dataset-items-open-records-data-florida-building-permits-code-violations",
        "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/open-records-data~florida-building-permits-code-violations/runs": {
      "post": {
        "operationId": "runs-sync-open-records-data-florida-building-permits-code-violations",
        "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/open-records-data~florida-building-permits-code-violations/run-sync": {
      "post": {
        "operationId": "run-sync-open-records-data-florida-building-permits-code-violations",
        "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": {
          "dataType": {
            "title": "What to fetch",
            "enum": [
              "permits",
              "codeViolations",
              "both"
            ],
            "type": "string",
            "description": "Building permits (new projects), code violations (distressed / neglected properties), or both mixed together.",
            "default": "permits"
          },
          "sources": {
            "title": "Where (jurisdictions)",
            "type": "array",
            "description": "Permits: City of Orlando, Miami-Dade County, City of Miami. Code violations: City of Orlando and Miami-Dade County (code compliance + building violations). Leave all selected for statewide-style coverage of South and Central Florida.",
            "items": {
              "type": "string",
              "enum": [
                "orlando",
                "miami-dade",
                "miami-city"
              ],
              "enumTitles": [
                "City of Orlando",
                "Miami-Dade County",
                "City of Miami"
              ]
            },
            "default": [
              "orlando",
              "miami-dade",
              "miami-city"
            ]
          },
          "daysBack": {
            "title": "Days back",
            "minimum": 1,
            "maximum": 365,
            "type": "integer",
            "description": "Only records from the last N days: applications processed (Orlando permits), permits issued (Miami-Dade and City of Miami) or cases opened (code violations).",
            "default": 30
          },
          "commercialOnly": {
            "title": "Commercial permits only",
            "type": "boolean",
            "description": "Permits only. Skip residential permits.",
            "default": false
          },
          "minEstimatedValue": {
            "title": "Minimum project value (USD)",
            "minimum": 0,
            "type": "integer",
            "description": "Permits only. Skip permits below this estimated value.",
            "default": 0
          },
          "keywords": {
            "title": "Keywords (any match)",
            "type": "array",
            "description": "Keep only records that mention any of these words in the type, description, address, contractor or issue flags. Trade examples: roof, solar, hvac, pool, demolition, electrical, plumbing, fire sprinkler, sign, unsafe, vacant.",
            "items": {
              "type": "string"
            }
          },
          "codeStatus": {
            "title": "Code case status",
            "enum": [
              "open",
              "all"
            ],
            "type": "string",
            "description": "Code violations only. \"Open\" means not closed - including cases already escalated to a lien, civil penalty or collections referral (the best distressed-property signals).",
            "default": "open"
          },
          "includeTickets": {
            "title": "Include ticket-type code cases",
            "type": "boolean",
            "description": "Code violations only. Orlando \"ticket\" cases (mostly street-level transient enforcement) are skipped by default; cases with no street address are always skipped.",
            "default": false
          },
          "enrich": {
            "title": "Add lead scores",
            "type": "boolean",
            "description": "Adds a 0-100 lead score with plain-English reasons, trade tags (permits) and cases-at-address counts (code violations), and sorts the best leads first. Billed at the higher scored-lead rate.",
            "default": false
          },
          "maxResults": {
            "title": "Max results",
            "minimum": 1,
            "maximum": 5000,
            "type": "integer",
            "description": "Upper bound on records returned and billed. Your run's maximum-charge setting is honoured too, so you can never be billed more than you set.",
            "default": 100
          },
          "socrataAppToken": {
            "title": "Socrata app token (optional)",
            "type": "string",
            "description": "Optional. Raises the City of Orlando API rate limit. Free from the Socrata developer portal."
          }
        }
      },
      "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
                  }
                }
              }
            }
          }
        }
      }
    }
  }
}