{
  "openapi": "3.0.1",
  "info": {
    "title": "Texas Workers' Comp Leads - Renewals & Uninsured Employers",
    "description": "Find Texas businesses whose workers' compensation policy renews soon, with their current carrier, premium and exact expiration date, plus businesses that have no workers' comp at all, from official Texas Department of Insurance data.",
    "version": "1.0",
    "x-build-id": "2Z9C5u1sec3kFMLYY"
  },
  "servers": [
    {
      "url": "https://api.apify.com/v2"
    }
  ],
  "paths": {
    "/acts/wicker_triathlon~texas-workers-comp-leads/run-sync-get-dataset-items": {
      "post": {
        "operationId": "run-sync-get-dataset-items-wicker_triathlon-texas-workers-comp-leads",
        "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/wicker_triathlon~texas-workers-comp-leads/runs": {
      "post": {
        "operationId": "runs-sync-wicker_triathlon-texas-workers-comp-leads",
        "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/wicker_triathlon~texas-workers-comp-leads/run-sync": {
      "post": {
        "operationId": "run-sync-wicker_triathlon-texas-workers-comp-leads",
        "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": {
          "leadType": {
            "title": "Lead type",
            "enum": [
              "renewals",
              "noCoverage",
              "both"
            ],
            "type": "string",
            "description": "Renewals = employers whose policy expires soon. No coverage = employers that filed to opt out of workers' comp. Both = renewals first, then no-coverage leads.",
            "default": "renewals"
          },
          "expiresWithinDays": {
            "title": "Policy expires within (days)",
            "minimum": 1,
            "maximum": 400,
            "type": "integer",
            "description": "Renewal leads only: include policies that expire between today and this many days from today. 90 is a good window for agents.",
            "default": 90
          },
          "cities": {
            "title": "Cities",
            "type": "array",
            "description": "Only employers in these cities (e.g. Houston, Dallas). Leave empty for all of Texas.",
            "items": {
              "type": "string"
            }
          },
          "zipCodes": {
            "title": "ZIP codes",
            "type": "array",
            "description": "Only employers in these 5-digit ZIP codes.",
            "items": {
              "type": "string"
            }
          },
          "employerNameContains": {
            "title": "Employer name contains",
            "type": "string",
            "description": "Only employers whose name contains this text (e.g. ROOFING). Not case-sensitive."
          },
          "minAnnualPremium": {
            "title": "Minimum annual premium ($)",
            "minimum": 0,
            "type": "integer",
            "description": "Renewal leads only: skip policies with a state standard premium below this amount. Use it to focus on bigger accounts.",
            "default": 0
          },
          "carrierNameContains": {
            "title": "Current insurance carrier contains",
            "type": "string",
            "description": "Renewal leads only: only policies with this carrier (e.g. TEXAS MUTUAL). Useful for targeting a competitor's customers."
          },
          "classCodes": {
            "title": "Class codes",
            "type": "array",
            "description": "Renewal leads only: only policies with these 4-digit workers' comp governing class codes (the industry's job code, e.g. 8810 = clerical office).",
            "items": {
              "type": "string"
            }
          },
          "sortBy": {
            "title": "Sort renewal leads by",
            "enum": [
              "expirationSoonest",
              "premiumHighest"
            ],
            "type": "string",
            "description": "Order of renewal leads.",
            "default": "expirationSoonest"
          },
          "includeCoveredEmployers": {
            "title": "Include other employers on the same policy",
            "type": "boolean",
            "description": "Off = one row per policy (the named insured). On = also list sister companies covered by the same policy.",
            "default": false
          },
          "includePeoPolicies": {
            "title": "Include employee-leasing (PEO) policies",
            "type": "boolean",
            "description": "Off = skip policies bought through a PEO / employee-leasing company, which agents usually can't replace directly.",
            "default": false
          },
          "filedWithinDays": {
            "title": "No-coverage filings received within (days)",
            "minimum": 1,
            "maximum": 3650,
            "type": "integer",
            "description": "No-coverage leads only: include employers whose opt-out filing was received in the last this-many days and that are still opted out today.",
            "default": 365
          },
          "includeLocations": {
            "title": "Include each location of no-coverage employers",
            "type": "boolean",
            "description": "No-coverage leads only: off = one row per company; on = also one row per listed work location.",
            "default": false
          },
          "maxResults": {
            "title": "Maximum results",
            "minimum": 1,
            "maximum": 100000,
            "type": "integer",
            "description": "Stop after this many leads. You are only charged for leads you receive.",
            "default": 100
          },
          "onlyNew": {
            "title": "Only new since my last run",
            "type": "boolean",
            "description": "Remembers every lead this Actor already gave you (stored privately in your own Apify account) and skips them next time, so a monthly run only returns and charges for new leads.",
            "default": false
          },
          "trackerName": {
            "title": "Memory name (for 'only new' mode)",
            "type": "string",
            "description": "Use a different name to keep separate memories, e.g. one per sales rep or territory. Default: default."
          },
          "appToken": {
            "title": "Socrata app token (optional)",
            "type": "string",
            "description": "Optional free token from data.texas.gov that avoids rate limits on very large runs. Most users can leave this empty."
          }
        }
      },
      "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
                  }
                }
              }
            }
          }
        }
      }
    }
  }
}