Skip to content

Fastify plugin for integrating the Evervault Node.js SDK

License

Notifications You must be signed in to change notification settings

Briscoooe/fastify-evervault

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

60 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

fastify-evervault


CI js-standard-style npm

Fastify plugin for instantiating and encapsulating the Evervault client.

Install

npm i fastify-evervault

Usage

Add it to your project with register, passing in your Evervault API key.

const fastify = require('fastify')()

fastify.register(require('fastify-evervault'), {
  apiKey: 'ev:key:...',
})

fastify.get('/', async (request, reply) => {
  const { evervault } = fastify
  const encrypted = await evervault.encrypt('Hello World!')
  return encrypted
})

fastify.listen({ port: 3000 }, err => {
  if (err) throw err
})

Documentation

See the Evervault Node.js SDK for more information on the Evervault client.

License

MIT