{
  "openapi": "3.0.1",
  "info": {
    "title": "Companies House API: UK Company Search & Data (Official API)",
    "description": "Official Companies House API for UK company data: look up by company number, search by name, or list new companies by SIC code, location and incorporation date. Status, address, SIC, accounts due dates; directors, PSC, filings optional. Try with no API key (10 per run). $2 per 1,000.",
    "version": "1.0",
    "x-build-id": "M1wZjeFEH06BZSkKo"
  },
  "servers": [
    {
      "url": "https://api.apify.com/v2"
    }
  ],
  "paths": {
    "/acts/terracotta_hauyne~uk-companies-house-company-data/run-sync-get-dataset-items": {
      "post": {
        "operationId": "run-sync-get-dataset-items-terracotta_hauyne-uk-companies-house-company-data",
        "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/terracotta_hauyne~uk-companies-house-company-data/runs": {
      "post": {
        "operationId": "runs-sync-terracotta_hauyne-uk-companies-house-company-data",
        "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/terracotta_hauyne~uk-companies-house-company-data/run-sync": {
      "post": {
        "operationId": "run-sync-terracotta_hauyne-uk-companies-house-company-data",
        "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": {
          "apiKey": {
            "title": "Companies House API key (recommended)",
            "type": "string",
            "description": "Optional. Leave empty to try the Actor in trial mode (at most 10 companies per run). With your own free REST API key there is no cap. To get one (about 2 minutes), register at https://developer.company-information.service.gov.uk/, then go to 'Your applications' (https://developer.company-information.service.gov.uk/manage-applications), create an application for the live environment and add a key of type 'REST' (API key). Paste the key only, without spaces. Do not restrict the key to an IP address, because Apify runs on changing servers. The key is stored encrypted and used only for requests to Companies House."
          },
          "companyNumbers": {
            "title": "Company numbers",
            "type": "array",
            "description": "Company number lookup: Companies House company numbers, e.g. 00000006, SC123456, OC301234. Short numbers are padded with zeros and Companies House page URLs are accepted.",
            "items": {
              "type": "string"
            }
          },
          "searchQueries": {
            "title": "Search by company name",
            "type": "array",
            "description": "UK company search by name (same as the search box on the Companies House website), e.g. 'bakery manchester'. Each matching company is fetched in full.",
            "items": {
              "type": "string"
            }
          },
          "maxResultsPerSearch": {
            "title": "Max companies per search",
            "minimum": 1,
            "maximum": 5000,
            "type": "integer",
            "description": "Maximum companies taken from each name search and from the filter search below.",
            "default": 100
          },
          "searchActiveCompaniesOnly": {
            "title": "Searches: active companies only",
            "type": "boolean",
            "description": "Skip dissolved, liquidated and other non-active companies in search results.",
            "default": false
          },
          "sicCodes": {
            "title": "SIC codes",
            "type": "array",
            "description": "5-digit SIC 2007 codes, e.g. 10710 (bread and cakes), 62012 (software development).",
            "items": {
              "type": "string"
            }
          },
          "location": {
            "title": "Location",
            "type": "string",
            "description": "Town, city or postcode area in the registered office address, e.g. Manchester or M1."
          },
          "companyStatus": {
            "title": "Company status",
            "type": "array",
            "description": "Only companies with one of these statuses.",
            "items": {
              "type": "string",
              "enum": [
                "active",
                "dissolved",
                "open",
                "closed",
                "converted-closed",
                "receivership",
                "administration",
                "liquidation",
                "insolvency-proceedings",
                "voluntary-arrangement",
                "registered",
                "removed"
              ]
            }
          },
          "companyType": {
            "title": "Company type",
            "type": "array",
            "description": "Companies House company type codes, e.g. ltd, plc, llp, private-limited-guarant-nsc.",
            "items": {
              "type": "string"
            }
          },
          "companyNameIncludes": {
            "title": "Company name includes",
            "type": "string",
            "description": "Only companies whose name contains this text."
          },
          "companyNameExcludes": {
            "title": "Company name excludes",
            "type": "string",
            "description": "Skip companies whose name contains this text."
          },
          "incorporatedFrom": {
            "title": "Incorporated from",
            "type": "string",
            "description": "Incorporated on or after this date (YYYY-MM-DD). Use with 'Incorporated to' for a new-companies list."
          },
          "incorporatedTo": {
            "title": "Incorporated to",
            "type": "string",
            "description": "Incorporated on or before this date (YYYY-MM-DD)."
          },
          "dissolvedFrom": {
            "title": "Dissolved from",
            "type": "string",
            "description": "Dissolved on or after this date (YYYY-MM-DD)."
          },
          "dissolvedTo": {
            "title": "Dissolved to",
            "type": "string",
            "description": "Dissolved on or before this date (YYYY-MM-DD)."
          },
          "includeOfficers": {
            "title": "Include officers (personal data)",
            "type": "boolean",
            "description": "Add directors, secretaries and LLP members: name, role, appointment dates, nationality, occupation, country of residence and service (correspondence) address. This is personal data: enable it only if you have a lawful basis under UK GDPR; you are the controller of your copy. One extra API request per 100 officers.",
            "default": false
          },
          "includePersonsWithSignificantControl": {
            "title": "Include persons with significant control (personal data)",
            "type": "boolean",
            "description": "Add PSCs (beneficial owners): name, kind, natures of control, notified/ceased dates, nationality, country of residence, service address; for corporate PSCs legal form and registration number. Personal data: see 'Include officers'.",
            "default": false
          },
          "includeResignedOfficersAndCeasedPsc": {
            "title": "Also include resigned officers and ceased PSCs",
            "type": "boolean",
            "description": "By default only current officers and PSCs are output.",
            "default": false
          },
          "includeBirthMonthYear": {
            "title": "Include month and year of birth",
            "type": "boolean",
            "description": "Off by default (data minimisation). Companies House publishes only month and year of birth; the day is never output.",
            "default": false
          },
          "includeFilingHistory": {
            "title": "Include filing history",
            "type": "boolean",
            "description": "Add the latest filings: date, type, category, description and a link to the PDF document on the Companies House website.",
            "default": false
          },
          "maxFilingHistoryItems": {
            "title": "Max filings per company",
            "minimum": 1,
            "maximum": 1000,
            "type": "integer",
            "description": "Latest filings to include per company (one API request per 100 filings).",
            "default": 25
          },
          "maxResults": {
            "title": "Max companies in total",
            "minimum": 1,
            "type": "integer",
            "description": "Stop after this many companies (each company is one result). Leave empty for no limit other than your maximum cost per run."
          },
          "requestsPerFiveMinutes": {
            "title": "Max API requests per 5 minutes",
            "minimum": 1,
            "maximum": 600,
            "type": "integer",
            "description": "Companies House allows 600 requests per 5 minutes per key. The actor paces itself to this number (default 575). Lower it if other applications use the same key at the same time.",
            "default": 575
          }
        }
      },
      "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
                  }
                }
              }
            }
          }
        }
      }
    }
  }
}