{
  "openapi": "3.0.1",
  "info": {
    "title": "UK Companies House Company List & Lookup (bulk, cheap)",
    "description": "Filter UK companies by SIC code, postcode, town, status, type and dates, or look them up by number, from the official Companies House free monthly file. Company fields only: no director, officer or care-of names. Snapshot date on every row.",
    "version": "1.0",
    "x-build-id": "XZapdzcHBl34u7GDG"
  },
  "servers": [
    {
      "url": "https://api.apify.com/v2"
    }
  ],
  "paths": {
    "/acts/gapforge~uk-company-list/run-sync-get-dataset-items": {
      "post": {
        "operationId": "run-sync-get-dataset-items-gapforge-uk-company-list",
        "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/gapforge~uk-company-list/runs": {
      "post": {
        "operationId": "runs-sync-gapforge-uk-company-list",
        "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/gapforge~uk-company-list/run-sync": {
      "post": {
        "operationId": "run-sync-gapforge-uk-company-list",
        "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": [
              "search",
              "lookup",
              "refresh"
            ],
            "type": "string",
            "description": "Search: companies that match the filters below. Lookup: the companies whose numbers you list under Lookup (the filters are not used). Refresh: only make sure the newest monthly snapshot is stored; it returns no rows and costs nothing per company.",
            "default": "search"
          },
          "sicCodes": {
            "title": "SIC codes or prefixes",
            "maxItems": 50,
            "type": "array",
            "description": "Industry codes (UK SIC 2007), 1 to 5 digits. A prefix matches codes that start with it: 62 matches 62010 and 62020, never 16200 or 46620. A company matches when any of its codes matches.",
            "items": {
              "type": "string",
              "pattern": "^\\d{1,5}$"
            }
          },
          "postcodePrefixes": {
            "title": "Postcode areas or districts",
            "maxItems": 50,
            "type": "array",
            "description": "Registered office postcodes. An area (M, SW) matches only that area, so M does not match ME. A district (M1, SW1A) matches only that district, so M1 does not match M11. A sector (SW1A 1) or a full postcode also works.",
            "items": {
              "type": "string",
              "maxLength": 8
            }
          },
          "postTowns": {
            "title": "Post towns",
            "maxItems": 50,
            "type": "array",
            "description": "Registered office post towns, matched whole and without regard to upper or lower case (LEEDS = Leeds). A search with only towns and no SIC code or postcode reads the whole snapshot, so it takes longer.",
            "items": {
              "type": "string",
              "maxLength": 120
            }
          },
          "companyStatus": {
            "title": "Company status",
            "maxItems": 20,
            "type": "array",
            "description": "Keep only these statuses, written as in the file (for example Active, or Active - Proposal to Strike off). Matched whole, without regard to case. Empty keeps every status.",
            "items": {
              "type": "string",
              "maxLength": 120
            }
          },
          "companyCategory": {
            "title": "Company type",
            "maxItems": 20,
            "type": "array",
            "description": "Keep only these company types, written as in the file (for example Private Limited Company, or Limited Liability Partnership). Matched whole, without regard to case. Empty keeps every type.",
            "items": {
              "type": "string",
              "maxLength": 120
            }
          },
          "incorporatedFrom": {
            "title": "Incorporated on or after",
            "pattern": "^(\\d{4}-\\d{2}-\\d{2})?$",
            "maxLength": 10,
            "type": "string",
            "description": "Earliest incorporation date (YYYY-MM-DD). A company without an incorporation date is left out when a date is set."
          },
          "incorporatedTo": {
            "title": "Incorporated on or before",
            "pattern": "^(\\d{4}-\\d{2}-\\d{2})?$",
            "maxLength": 10,
            "type": "string",
            "description": "Latest incorporation date (YYYY-MM-DD), included."
          },
          "accountsOverdue": {
            "title": "Accounts overdue",
            "enum": [
              "any",
              "overdue",
              "not_overdue"
            ],
            "type": "string",
            "description": "Overdue means the next accounts due date is before the snapshot date. Any keeps every company.",
            "default": "any"
          },
          "confirmationStatementOverdue": {
            "title": "Confirmation statement overdue",
            "enum": [
              "any",
              "overdue",
              "not_overdue"
            ],
            "type": "string",
            "description": "Overdue means the next confirmation statement due date is before the snapshot date. Any keeps every company.",
            "default": "any"
          },
          "companyNumbers": {
            "title": "Company numbers",
            "maxItems": 1000,
            "type": "array",
            "description": "Lookup mode only: up to 1,000 Companies House numbers. Leading zeros may be left out (6 = 00000006, SC1234 = SC001234). A number that is not in the monthly file gets a free not-found row.",
            "items": {
              "type": "string",
              "maxLength": 12
            }
          },
          "maxResults": {
            "title": "Maximum results",
            "minimum": 1,
            "maximum": 50000,
            "type": "integer",
            "description": "Search mode: deliver at most this many companies. You pay per company delivered, so this also caps the cost.",
            "default": 1000
          }
        }
      },
      "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
                  }
                }
              }
            }
          }
        }
      }
    }
  }
}