# @not-govuk/engine

> An engine for running NotGovUK applications.

Latest version **0.16.3** (published 2025-08-18) · MIT license · 0 weekly downloads

> **Deprecated.** This package is deprecated.

## Install

```sh
npm install @not-govuk/engine
pnpm add @not-govuk/engine
yarn add @not-govuk/engine
bun add @not-govuk/engine
```

## Health

**Score 10/100 (F)** — status: deprecated.

Negative: deprecated.

## Facts

| | |
|---|---|
| Version | 0.16.3 |
| Published | 2025-08-18 |
| First published | 2020-08-05 |
| Weekly downloads | 0 |
| License | MIT |
| TypeScript types | bundled |
| Module format | CommonJS |
| Dependencies | 10 |
| Unpacked size | 47.8 KB |
| Known vulnerabilities | 0 |
| Install scripts | no |
| Author | Daniel A.C. Martin |
| Maintainers | daniel-ac-martin |

## Links

- npm: https://www.npmjs.com/package/@not-govuk/engine
- npm.io page: https://npm.io/package/@not-govuk/engine

## Dependencies (10)

- [passport](https://npm.io/package/passport.md) ^0.7.0
- [base64url](https://npm.io/package/base64url.md) ^3.0.1
- [openid-client](https://npm.io/package/openid-client.md) ^5.7.1
- [passport-http](https://npm.io/package/passport-http.md) ^0.3.0
- [serverless-http](https://npm.io/package/serverless-http.md) ^3.2.0
- [@not-govuk/restify](https://npm.io/package/@not-govuk/restify.md) ^0.16.3
- [apollo-server-restify](https://npm.io/package/apollo-server-restify.md) ^1.3.6
- [@not-govuk/consent-cookies](https://npm.io/package/@not-govuk/consent-cookies.md) ^0.16.3
- [@not-govuk/express-adapter](https://npm.io/package/@not-govuk/express-adapter.md) ^0.16.3
- [@not-govuk/server-renderer](https://npm.io/package/@not-govuk/server-renderer.md) ^0.16.3

## Recent versions

- 0.16.3 (latest) — 2025-08-18
- 0.1.27 (pnpm-temp) — 2020-10-19
- 0.16.2 — 2025-05-30
- 0.16.1 — 2025-05-21
- 0.16.0 — 2025-05-11
- 0.15.14 — 2025-05-08
- 0.15.13 — 2025-05-07
- 0.15.12 — 2025-04-10
- 0.15.11 — 2025-04-03
- 0.15.10 — 2025-03-21
- 0.15.9 — 2025-03-17
- 0.15.8 — 2025-02-16
- 0.15.7 — 2025-02-15
- 0.15.6 — 2025-02-02
- 0.15.5 — 2025-01-21
- … 94 more at https://npm.io/package/@not-govuk/engine/versions

## README

NotGovUK - Engine
=================

An engine for running NotGovUK applications.


Using this package
------------------

First install the package into your project:

```shell
npm install -S @not-govuk/engine
```

Then use it in your code as follows:

```js
const engine = require('@not-govuk/engine');
const { resolve } = require('path');

const isReady = require('./readiness');
const graphQLSchema = require('./graphql');

const AppWrap = require('../common/app-wrap');
const ErrorPage = require('../common/error-page');
const PageWrap = require('../common/page-wrap');
const pageLoader = require('../common/page-loader');

const entrypoints = require('../../dist/public/entrypoints.json');

const app = engine({
  AppWrap,
  ErrorPage,
  PageWrap,
  assets: {
    localPath: resolve(__dirname, '..', '..', 'dist', 'public'),
    publicPath: '/public/',
    entrypoints
  },
  auth: {
    method: AuthMethod.Basic,
    username: 'guest',
    password: 'password',
    roles: [],
    sessionsSecret: 'my-secret'
  }
  env: 'production',
  graphQL: {
    schema: graphQLSchema
  },
  httpd: {
    host: '0.0.0.0',
    port: 8080,
  },
  logger: {
    level: 'info'
  },
  isReady,
  mode: 'server',
  name: 'my-app'
  pageLoader,
  privacy: false,
  ssrOnly: false
});
```


Working on this package
-----------------------

Before working on this package you must install its dependencies using
the following command:

```shell
pnpm install
```


### Building

```shell
npm run build
```


### Clean-up

```shell
npm run clean
```

---
_Source: https://npm.io/package/@not-govuk/engine · Machine-readable twin of the npm.io package page. Health data is recomputed on every publish._
