cyberchief-bolt
v0.0.50
Published
The node agent for Cyberchief Bolt API security.
Downloads
10
Readme
Installation
Currently cyberchief-bolt's Node Agent supports 3 frameworks:
- Express
- Koa
- Fastify
It can be installed from npm
by running:
npm install cyberchief-bolt
Or from yarn
by running:
yarn add cyberchief-bolt
Configuration
Express
Cyberchief-bolt can be included as a standard Express Middleware:
import { initExpress as cyberchief_bolt } from "cyberchief-bolt";
// Or using require
const cyberchief_bolt = require("cyberchief-bolt").initExpress;
...
const app = express();
...
app.use(
cyberchief_bolt(
{
key: <YOUR_CYBERCHIEF_BOLT_API_KEY>,
host: <YOUR_CYBERCHIEF_BOLT_HOST>,
}
)
);
Koa
Cyberchief-bolt can be included as a standard Koa Middleware:
import { initKoa as cyberchief_bolt } from "cyberchief-bolt";
// Or using require
const cyberchief_bolt = require("cyberchief-bolt").initKoa;
...
const app = new Koa();
...
app.use(
cyberchief_bolt(
{
key: <YOUR_CYBERCHIEF_BOLT_API_KEY>,
host: <YOUR_CYBERCHIEF_BOLT_HOST>,
}
)
);
Fastify
Cyberchief-bolt can be included as a standard Fastify plugin:
import { initFastify as cyberchief_bolt } from "cyberchief-bolt";
// Or using require
const cyberchief_bolt = require("cyberchief-bolt").initFastify;
...
const fastify = Fastify();
...
fastify.register(
cyberchief_bolt(
{
key: <YOUR_CYBERCHIEF_BOLT_API_KEY>,
host: <YOUR_CYBERCHIEF_BOLT_HOST>,
}
)
);