{
  "openapi": "3.0.1",
  "info": {
    "title": "Washington Contractor Licenses (L&I) with Bond & Insurance",
    "description": "Washington State contractor licences from the official L&I registry: business name, licence, address, phone, UBI, specialty and status. Find newly licensed contractors or current insurance-policy and dated surety-bond renewals. Optional principals, bond, insurance and signer joins.",
    "version": "1.0",
    "x-build-id": "opLDT1LSbW6FUbU94"
  },
  "servers": [
    {
      "url": "https://api.apify.com/v2"
    }
  ],
  "paths": {
    "/acts/jserle~wa-contractor-license-registry/run-sync-get-dataset-items": {
      "post": {
        "operationId": "run-sync-get-dataset-items-jserle-wa-contractor-license-registry",
        "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/jserle~wa-contractor-license-registry/runs": {
      "post": {
        "operationId": "runs-sync-jserle-wa-contractor-license-registry",
        "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/jserle~wa-contractor-license-registry/run-sync": {
      "post": {
        "operationId": "run-sync-jserle-wa-contractor-license-registry",
        "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": {
          "effectiveWithinDays": {
            "title": "Licence effective within the last N days",
            "minimum": 0,
            "maximum": 36500,
            "type": "integer",
            "description": "Keep licences whose effective date falls within the last N days. The normal default is 30. Insurance-policy or bond-renewal searches automatically disable this window unless you explicitly provide a value. Ignored when an explicit effective-date range is given."
          },
          "effectiveDateFrom": {
            "title": "Effective date from",
            "type": "string",
            "description": "ISO date, for example 2026-01-01. Keeps licences effective on or after this date. Overrides the N-day window."
          },
          "effectiveDateTo": {
            "title": "Effective date to",
            "type": "string",
            "description": "ISO date, for example 2026-06-30. Keeps licences effective on or before this date. Overrides the N-day window."
          },
          "expirationDateFrom": {
            "title": "Expiration date from",
            "type": "string",
            "description": "ISO date. Keeps licences that expire on or after this date. Combine with Expiration date to for renewal leads, e.g. every active licence expiring next quarter."
          },
          "expirationDateTo": {
            "title": "Expiration date to",
            "type": "string",
            "description": "ISO date. Keeps licences that expire on or before this date."
          },
          "insuranceExpirationFrom": {
            "title": "Current insurance policy expires on or after",
            "type": "string",
            "description": "Inclusive start of a current insurance-policy expiration window. Searches the actual insurance addendum first, automatically includes the complete insurance join and removes the implicit new-license window. Canceled, expired and future-effective policies do not match."
          },
          "insuranceExpirationTo": {
            "title": "Current insurance policy expires on or before",
            "type": "string",
            "description": "Inclusive end of a current insurance-policy expiration window. Both one-sided and two-sided policy windows are supported. Records without a current, dated policy do not match."
          },
          "bondExpirationFrom": {
            "title": "Current surety bond expires on or after",
            "type": "string",
            "description": "Inclusive start of a current surety-bond expiration window. Must be paired with Bond expires on or before; maximum window is 366 days. Automatically includes the complete bond join. Until Canceled bonds have no dated renewal and never match."
          },
          "bondExpirationTo": {
            "title": "Current surety bond expires on or before",
            "type": "string",
            "description": "Inclusive end of the surety-bond expiration window. Must be paired with Bond expires on or after. The source stores US dates as text, so exact padded and unpadded dates are searched without unsafe date casts."
          },
          "status": {
            "title": "Licence status",
            "enum": [
              "active",
              "expired",
              "suspended",
              "outOfBusiness",
              "inactive",
              "reLicensed",
              "any"
            ],
            "type": "string",
            "description": "L&I status of the licence. Default Active. Choose Any to include expired, suspended and out-of-business licences.",
            "default": "active"
          },
          "licenseType": {
            "title": "Licence type",
            "enum": [
              "any",
              "CC",
              "EC",
              "PC",
              "LC"
            ],
            "type": "string",
            "description": "L&I licence type: construction (CC), electrical (EC), plumbing (PC) or elevator (LC) contractor.",
            "default": "any"
          },
          "specialty": {
            "title": "Specialty",
            "type": "string",
            "description": "An L&I specialty code (for example 01 for GENERAL, CB for PAINTING/WALLCOVERING, 03 for PUMP & IRRIGATION) or a word from the specialty description (for example ROOFING). Matched against both specialty slots on the licence."
          },
          "city": {
            "title": "City",
            "type": "string",
            "description": "Case-insensitive exact match on the licence address city, for example Seattle or Spokane. The registry publishes city, state and zip but no county."
          },
          "zip": {
            "title": "ZIP code or prefix",
            "type": "string",
            "description": "Keeps licences whose ZIP starts with this, so 981 covers Seattle-area ZIPs and 98101 is one ZIP."
          },
          "state": {
            "title": "Address state",
            "type": "string",
            "description": "Two-letter state of the licence mailing address. Most licences are WA, but out-of-state contractors licensed in Washington are included in the registry. Leave blank for all."
          },
          "businessName": {
            "title": "Business name contains",
            "type": "string",
            "description": "Case-insensitive substring matched against the business name."
          },
          "licenseNumber": {
            "title": "Licence number",
            "type": "string",
            "description": "Look up one licence exactly, for example 04CONCL862CR. Overrides the N-day window."
          },
          "ubi": {
            "title": "UBI number",
            "type": "string",
            "description": "Washington Unified Business Identifier, nine digits. A UBI can carry more than one licence. Overrides the N-day window."
          },
          "join": {
            "title": "Attach related L&I data",
            "uniqueItems": true,
            "type": "array",
            "description": "Each selected join adds one extra request per 100 licences and attaches an array to every record: principals (owners with start and end dates), bond (surety firm, amount, effective and expiration dates, cancellation, impairment), insurance (carrier, policy, amount, expiration, agency), signers (people authorized to sign permits or affidavits). Joined rows are included in the record; they are not charged separately.",
            "items": {
              "type": "string",
              "enum": [
                "principals",
                "bond",
                "insurance",
                "signers"
              ],
              "enumTitles": [
                "Principals (owners)",
                "Bond",
                "Insurance",
                "Authorized signers"
              ]
            },
            "default": []
          },
          "maxResults": {
            "title": "Maximum records",
            "minimum": 1,
            "maximum": 50000,
            "type": "integer",
            "description": "How many licences to deliver, most recently effective first. You are charged per delivered record, so this is also your cost cap.",
            "default": 100
          },
          "includeRaw": {
            "title": "Include the raw source rows",
            "type": "boolean",
            "description": "Attach a `raw` object with the untouched data.wa.gov rows this record was built from (general plus any joined rows), under their L&I column names.",
            "default": false
          }
        }
      },
      "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
                  }
                }
              }
            }
          }
        }
      }
    }
  }
}