Security News
Weekly Downloads Now Available in npm Package Search Results
Socket's package search now displays weekly downloads for npm packages, helping developers quickly assess popularity and make more informed decisions.
@evervault/sdk
Advanced tools
The Evervault Node.js SDK is a toolkit for encrypting data as it enters your server, and working with Cages. By default, initializing the SDK will result in all outbound HTTPS requests being intercepted and decrypted.
Before starting with the Evervault Node.js SDK, you will need to create an account and a team.
For full installation support, book time here.
See the Evervault Node.js SDK documentation.
Our Node.js SDK is distributed via npm, and can be installed using your preferred package manager.
npm install --save @evervault/sdk
yarn add @evervault/sdk
To make Evervault available for use in your app:
const Evervault = require('@evervault/sdk');
// Initialize the client with your team's api key
const evervaultClient = new Evervault('<API-KEY>');
// Encrypt your sensitive data
const encrypted = await evervaultClient.encrypt({ ssn: '012-34-5678' });
// Process the encrypted data in a Cage
const result = await evervaultClient.run('<CAGE_NAME>', encrypted);
The Evervault Node.js SDK exposes three functions.
evervault.encrypt()
encrypts data for use in your Cages. To encrypt data at the server, simply pass an object or string into the evervault.encrypt() function. Store the encrypted data in your database as normal.
async evervault.encrypt(data: Object | String);
Parameter | Type | Description |
---|---|---|
data | Object or String | Data to be encrypted. |
evervault.run()
invokes a Cage with a given payload.
async evervault.run(cageName: String, payload: Object[, options: Object]);
Parameter | Type | Description |
---|---|---|
cageName | String | Name of the Cage to be run |
data | Object | Payload for the Cage |
options | Object | Options for the Cage run |
Options to control how your Cage is run
Option | Type | Default | Description |
---|---|---|---|
async | Boolean | false | Run your Cage in async mode. Async Cage runs will be queued for processing. |
version | Number | undefined | Specify the version of your Cage to run. By default, the latest version will be run. |
Outbound Relay will decrypt any Evervault encrypted data sent to a domain that is configured as an Outbound Relay Destination in the UI. Setting the enableOutboundRelay
option to true
will enable and sync your Outbound Relay destinations with the SDK.
const evervaultClient = new Evervault('<API-KEY>', {
enableOutboundRelay: true
});
evervault.createRunToken()
creates a single use, time bound token for invoking a cage.
async evervault.createRunToken(cageName: String, payload: Object);
Parameter | Type | Description |
---|---|---|
cageName | String | Name of the Cage the run token should be created for |
data | Object | Payload that the token can be used with |
Bug reports and pull requests are welcome on GitHub at https://github.com/evervault/evervault-node.
Please see CONTRIBUTING.md for more details.
Questions or feedback? Let us know.
FAQs
Node.js SDK for Evervault
The npm package @evervault/sdk receives a total of 3,564 weekly downloads. As such, @evervault/sdk popularity was classified as popular.
We found that @evervault/sdk demonstrated a healthy version release cadence and project activity because the last version was released less than a year ago. It has 5 open source maintainers collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Security News
Socket's package search now displays weekly downloads for npm packages, helping developers quickly assess popularity and make more informed decisions.
Security News
A Stanford study reveals 9.5% of engineers contribute almost nothing, costing tech $90B annually, with remote work fueling the rise of "ghost engineers."
Research
Security News
Socket’s threat research team has detected six malicious npm packages typosquatting popular libraries to insert SSH backdoors.