{
  "openapi": "3.0.1",
  "info": {
    "title": "New Company Registrations: France, Norway, Finland, UK",
    "description": "Daily feed of newly registered companies in France (BODACC), Norway (Brreg), Finland (PRH) and the UK (Companies House). Filter by sector, city, postal code and legal form, and skip companies already delivered on a previous scheduled run. Pay per new company.",
    "version": "1.0",
    "x-build-id": "kZrNQMMPDHvj3XRmP"
  },
  "servers": [
    {
      "url": "https://api.apify.com/v2"
    }
  ],
  "paths": {
    "/acts/datacraft-studio~new-company-registrations-europe/run-sync-get-dataset-items": {
      "post": {
        "operationId": "run-sync-get-dataset-items-datacraft-studio-new-company-registrations-europe",
        "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/datacraft-studio~new-company-registrations-europe/runs": {
      "post": {
        "operationId": "runs-sync-datacraft-studio-new-company-registrations-europe",
        "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/datacraft-studio~new-company-registrations-europe/run-sync": {
      "post": {
        "operationId": "run-sync-datacraft-studio-new-company-registrations-europe",
        "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": {
          "countries": {
            "title": "Countries",
            "type": "array",
            "description": "Countries to read. FR is France (BODACC immatriculations), NO is Norway (Brreg), FI is Finland (PRH) and UK is Companies House. Aliases such as France, GB and Finland are accepted.",
            "default": [
              "FR",
              "NO",
              "FI",
              "UK"
            ],
            "items": {
              "type": "string"
            }
          },
          "lookbackDays": {
            "title": "Lookback days",
            "minimum": 1,
            "maximum": 31,
            "type": "integer",
            "description": "How many civil days to include, ending today in Europe/Paris. 1 is today only. 2 is yesterday and today. Ignored when both dateFrom and dateTo are set. Maximum 31.",
            "default": 2
          },
          "dateFrom": {
            "title": "Date from",
            "type": "string",
            "description": "Inclusive start date, YYYY-MM-DD. Set both dateFrom and dateTo to replace lookbackDays. The span cannot exceed 31 days."
          },
          "dateTo": {
            "title": "Date to",
            "type": "string",
            "description": "Inclusive end date, YYYY-MM-DD."
          },
          "naceCodes": {
            "title": "Activity code prefixes",
            "type": "array",
            "description": "Optional prefixes matched per country: French NAF (62 or 62.01Z), Norwegian NACE (47.8), Finnish TOL (62 or 62100) and UK SIC (62012). Punctuation is ignored. A company matches when any of its codes starts with any prefix.",
            "items": {
              "type": "string"
            }
          },
          "cities": {
            "title": "Cities",
            "type": "array",
            "description": "Optional city names. Matching ignores case and accents. Paris matches Paris 2 and not Parisot. Norway also matches the municipality.",
            "items": {
              "type": "string"
            }
          },
          "postalCodePrefixes": {
            "title": "Postal code prefixes",
            "type": "array",
            "description": "Optional prefixes. 750 matches 75002. SW1 matches SW1A 1AA. Spaces are ignored.",
            "items": {
              "type": "string"
            }
          },
          "legalForms": {
            "title": "Legal forms",
            "type": "array",
            "description": "Optional forms, matched against the native code or the label. Examples: SARL, 5710, SAS, AS, ENK, OY, ltd, plc.",
            "items": {
              "type": "string"
            }
          },
          "excludeSoleTraders": {
            "title": "Exclude sole traders",
            "type": "boolean",
            "description": "Drop French entrepreneurs individuels (personne physique), Norwegian ENK and Finnish toiminimi. UK sole traders are not on Companies House, so this has no effect there.",
            "default": false
          },
          "maxCompanyAgeDays": {
            "title": "Maximum company age (days)",
            "minimum": 0,
            "maximum": 3650,
            "type": "integer",
            "description": "France: BODACC creation notices also announce a new branch, a purchased business or a re-registered sole trader of an older company. A company whose SIRENE creation date is more than this many days before the window start is skipped and not charged. 0 keeps every notice. Norway, Finland and the UK already filter on the registration date.",
            "default": 60
          },
          "onlyNew": {
            "title": "Only companies not delivered before",
            "type": "boolean",
            "description": "When true, a company already stored in the named key-value store is skipped and not charged. Leave this on for a daily schedule. Turn it off to export the window again.",
            "default": true
          },
          "stateStoreName": {
            "title": "Dedup state store",
            "type": "string",
            "description": "Named key-value store used when onlyNew is true. The same name across scheduled runs is what stops a company from being delivered twice.",
            "default": "new-company-registrations-state"
          },
          "maxItems": {
            "title": "Maximum companies",
            "minimum": 1,
            "maximum": 20000,
            "type": "integer",
            "description": "Stop after this many delivered companies. Filtered, duplicate and failed items do not count. A full French publication day can exceed the default.",
            "default": 1000
          },
          "companiesHouseApiKey": {
            "title": "Companies House API key",
            "type": "string",
            "description": "Optional. Overrides the COMPANIES_HOUSE_API_KEY secret for this run. Sent as the HTTP Basic username. Leave blank to use the Actor secret. Do not put the key in a Make, Zapier or n8n scenario."
          }
        }
      },
      "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
                  }
                }
              }
            }
          }
        }
      }
    }
  }
}