{
  "openapi": "3.0.1",
  "info": {
    "title": "TX Real Estate Licenses - TREC & TALCB Register",
    "description": "Texas real-estate licenses (TREC + TALCB public data): sales agents, brokers and broker companies in one register (~324k) with the agent-to-broker chain, plus appraisers (~24k) and inspectors (~9k). Verify active licenses, screen status, or find every agent under a broker.",
    "version": "0.0",
    "x-build-id": "tj7k9Dpt8mid3gnix"
  },
  "servers": [
    {
      "url": "https://api.apify.com/v2"
    }
  ],
  "paths": {
    "/acts/j0401~tx-real-estate-licenses/run-sync-get-dataset-items": {
      "post": {
        "operationId": "run-sync-get-dataset-items-j0401-tx-real-estate-licenses",
        "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/j0401~tx-real-estate-licenses/runs": {
      "post": {
        "operationId": "runs-sync-j0401-tx-real-estate-licenses",
        "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/j0401~tx-real-estate-licenses/run-sync": {
      "post": {
        "operationId": "run-sync-j0401-tx-real-estate-licenses",
        "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": {
          "type": {
            "title": "Register",
            "enum": [
              "real-estate",
              "appraiser",
              "inspector"
            ],
            "type": "string",
            "description": "real-estate = sales agents + broker individuals + broker companies in one register (~324k), with the agent-to-broker chain on every row. appraiser = TREC appraisers (~24k). inspector = TALCB real-estate inspectors (~9k).",
            "default": "real-estate"
          },
          "licenseNumber": {
            "title": "License number",
            "type": "string",
            "description": "Exact license number, e.g. 857303-SA (sales agent), 770095-B (broker), 9017226-BB (broker company), 1382201-LR (appraiser). Returns that license.",
            "default": ""
          },
          "licenseType": {
            "title": "License type",
            "type": "string",
            "description": "License type. real-estate: 'Sales Agent', 'Broker Individual', 'Broker Company'. appraiser: 'Certified Residential', 'Certified General', 'Licensed Residential', 'Trainee', 'Temporary Non-Resident'. inspector: 'Professional', 'Apprentice', 'Real Estate'. Substring, case-insensitive.",
            "default": ""
          },
          "name": {
            "title": "Name",
            "type": "string",
            "description": "License holder's last or first name (substring). For a broker company, matches the company name.",
            "default": ""
          },
          "lastName": {
            "title": "Last name",
            "type": "string",
            "description": "License holder's last name (substring). Not on broker-company rows.",
            "default": ""
          },
          "firstName": {
            "title": "First name",
            "type": "string",
            "description": "License holder's first name (substring).",
            "default": ""
          },
          "status": {
            "title": "Status",
            "type": "string",
            "description": "License status. Blank defaults to Active (the ~189k live real-estate licenses). Set to 'all' / '*' for the full register. 'expired' matches any expired status (both the <6m and >6m buckets); or use an exact value: Active, Expired less than 6 months, Expired more than 6 months, Inactive, Revoked, Suspended, Deceased, Surrendered.",
            "default": ""
          },
          "county": {
            "title": "County",
            "type": "string",
            "description": "County (substring), e.g. 'Harris', 'Dallas'. Only on the real-estate register (appraiser and inspector registers carry no county).",
            "default": ""
          },
          "relatedTo": {
            "title": "Sponsoring license number",
            "type": "string",
            "description": "Reverse lookup: find every license whose related/sponsoring license is this number. E.g. a broker-company number returns all its sales agents; a broker-individual number returns the companies they head. The agent-to-broker chain.",
            "default": ""
          },
          "aggregate": {
            "title": "Aggregate instead of licenses",
            "type": "boolean",
            "description": "When on, returns one summary record per group (see groupBy) with license count and share - instead of individual licenses. Computed server-side.",
            "default": false
          },
          "groupBy": {
            "title": "Aggregate by",
            "enum": [
              "",
              "licenseType",
              "status",
              "county",
              "relatedLicenseType"
            ],
            "type": "string",
            "description": "Which dimension to aggregate over. Blank = licenseType. For real-estate / inspector: licenseType (sales agent vs broker), status, county. For appraiser: licenseType, status.",
            "default": ""
          },
          "maxResults": {
            "title": "Max records",
            "minimum": 0,
            "type": "integer",
            "description": "Cap the number of records pushed (0 = unlimited, up to ~10k rows per run). A license query can reach the run's charge cap; an aggregate over a register has at most a few dozen groups.",
            "default": 200
          }
        }
      },
      "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
                  }
                }
              }
            }
          }
        }
      }
    }
  }
}