Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

@google-cloud/dlp

Package Overview
Dependencies
Maintainers
13
Versions
79
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@google-cloud/dlp

DLP API client for Node.js

  • 0.1.3
  • Source
  • npm
  • Socket score

Version published
Weekly downloads
31K
decreased by-4.1%
Maintainers
13
Weekly downloads
 
Created
Source

Node.js Client for DLP API (Alpha)

DLP API: The Google Data Loss Prevention API provides methods for detection of privacy-sensitive fragments in text, images, and Google Cloud Platform storage repositories.

Quick Start

In order to use this library, you first need to go through the following steps:

  1. Select or create a Cloud Platform project.
  2. Enable the DLP API.
  3. Setup Authentication.

Installation

$ npm install --save @google-cloud/dlp

Preview

DlpServiceClient
 var dlp = require('@google-cloud/dlp');

 var client = dlp({
    // optional auth parameters.
 });

 var minLikelihood = dlp.v2beta1.types.Likelihood.POSSIBLE;
 var inspectConfig = {
     minLikelihood : minLikelihood
 };
 var type = 'text/plain';
 var value = 'my phone number is 215-512-1212';
 var itemsElement = {
     type : type,
     value : value
 };
 var items = [itemsElement];
 var request = {
     inspectConfig: inspectConfig,
     items: items
 };
 client.inspectContent(request).then(function(responses) {
     var response = responses[0];
     // doThingsWith(response)
 })
 .catch(function(err) {
     console.error(err);
 });

Next Steps

Keywords

FAQs

Package last updated on 16 Aug 2017

Did you know?

Socket

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.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc