
Product
Introducing Socket Fix for Safe, Automated Dependency Upgrades
Automatically fix and test dependency updates with socket fix—a new CLI tool that turns CVE alerts into safe, automated upgrades.
@elevate_security/customer-data-validators
Advanced tools
[](https://badge.fury.io/js/%40elevate_security%2Fcustomer-data-validators) [. spec.html (HTML version)
The CLI is self-documented, just execute and it will output the available commands.
Example, to check the src/tests/test_files/2019-10-30-00_58_46.csv
file with people/v1
integration type:
./dist/es-cdv-cli.nodejs.js check src/tests/test_files/2019-10-30-00_58_46.csv people/v1 # return code = 3 because there are invalid lines and no valid lines
./dist/es-cdv-cli.nodejs.js check src/tests/test_files/valid.csv people/v1 # return code = 0 because file is valid
echo $? # will see 0
Return codes of the CLI
As a CLI:
By cloning the source code
git clone git@github.com:ElevateSecurity/customer-data-validators.git
cd customer-data-validators
npm install
./dist/es-cdv-cli.nodejs.js -h # for help
./dist/es-cdv-cli.nodejs.js check src/tests/test_files/2019-10-30-00_58_46.csv people/v1 # running the command
If you prefer to install a specific version of the package and run it as a binary
npm install @elevate_security/customer-data-validators
npm link
customer-data-validator -h
If you don't want to install the package up-front and just want to execute the command as a one-off:
npx --package @elevate_security/customer-data-validators customer-data-validator -h
If
npx
is not installed:npm install -g npx
In a browser application
We're importing the library as an external script, to always get the latest available patch/minor version of the pinned major version (here below, version 1.x.y). This avoids rebuilding the UI everytime a new version of the validators is published.
<script src="https://unpkg.com/@elevate_security/customer-data-validators@^1"></script>
Then the library is available as esCustomerDataValidator
in the global object, you can use it like this:
const {CustomerDataValidator} = window.esCustomerDataValidator;
const results = await CustomerDataValidator(fileContent, 'people/v1')
Update the type-config.yml
. Then run npm run convert
to update the type-config.json
.
To rebuild the package, run npm run build:prod
For cli and functional tests:
npm run test
And for UI tests, run:
npm run test:ui
This happens automatically when merging a feature PR to the master
branch. After the CirclecI Job finishes on the master
branch, CircleCI will create a PR to bump the version number. Make sure you merge this "Bump version" PR promptly to avoid version conflicts.
Since some other projects like the scoring platform need to access the type definitions, CircleCI pushes the distribution files built from this repo to a public S3 bucket es-use1prod-assets (see .circleci/config.yml. Files are accessible from https://docs.elevatesecurity.com/__apps/customer-data-validators/master/config/type-config.yml (master
can be replaced by any branch name from this repository and config/type-config.yml
can be replaced by any file from the dist folder)
FAQs
[](https://badge.fury.io/js/%40elevate_security%2Fcustomer-data-validators) [![CircleCI](https://circleci.com/gh/ElevateSecurity/customer-data-validators.svg?style
The npm package @elevate_security/customer-data-validators receives a total of 47 weekly downloads. As such, @elevate_security/customer-data-validators popularity was classified as not popular.
We found that @elevate_security/customer-data-validators demonstrated a not healthy version release cadence and project activity because the last version was released 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.
Product
Automatically fix and test dependency updates with socket fix—a new CLI tool that turns CVE alerts into safe, automated upgrades.
Security News
CISA denies CVE funding issues amid backlash over a new CVE foundation formed by board members, raising concerns about transparency and program governance.
Product
We’re excited to announce a powerful new capability in Socket: historical data and enhanced analytics.