{"id":22096490,"url":"https://github.com/uphold/ein-validator","last_synced_at":"2025-07-24T22:32:04.305Z","repository":{"id":50266224,"uuid":"43765685","full_name":"uphold/ein-validator","owner":"uphold","description":"Validate and mask a U.S. Employer Identification Number (EIN)","archived":false,"fork":false,"pushed_at":"2023-04-27T16:05:13.000Z","size":17,"stargazers_count":2,"open_issues_count":1,"forks_count":5,"subscribers_count":9,"default_branch":"master","last_synced_at":"2024-11-28T13:18:45.622Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":"","language":"JavaScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/uphold.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.md","contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2015-10-06T17:14:58.000Z","updated_at":"2024-10-09T20:00:42.000Z","dependencies_parsed_at":"2024-06-18T21:23:18.747Z","dependency_job_id":"7f0792ba-af6f-415a-86a0-975ff0c9d9ec","html_url":"https://github.com/uphold/ein-validator","commit_stats":{"total_commits":11,"total_committers":7,"mean_commits":"1.5714285714285714","dds":0.7272727272727273,"last_synced_commit":"fb1b649c9e69c9062eb5cd0d259b12d301d5661c"},"previous_names":[],"tags_count":4,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/uphold%2Fein-validator","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/uphold%2Fein-validator/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/uphold%2Fein-validator/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/uphold%2Fein-validator/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/uphold","download_url":"https://codeload.github.com/uphold/ein-validator/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":227482486,"owners_count":17779968,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2024-12-01T04:11:12.958Z","updated_at":"2024-12-01T04:11:13.489Z","avatar_url":"https://github.com/uphold.png","language":"JavaScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# ein-validator\nValidate and mask a U.S. Employer Identification Number (EIN).\n\n## Status\n[![npm version][npm-image]][npm-url] [![build status][travis-image]][travis-url]\n\n## Installation\nInstall the package via `npm`:\n\n```sh\nnpm install ein-validator --save\n```\n\n## Usage\n### `isValid(value)`\nThis method validates if the given value is a valid `Employer Identification Number`.\n\n#### Arguments\n1. `value` _(*)_: The value to validate.\n\n#### Returns\n_(boolean)_:  Returns whether the input value is a valid EIN or not.\n\n#### Example\n\n```js\nisValid({});\n// =\u003e false\n\nisValid('0112345-67');\n// =\u003e false\n\nisValid('01-1234567');\n// =\u003e true\n\nisValid('011234567');\n// =\u003e true\n```\n\n--------------------------------------------------------------------------------\n\n### `mask(value)`\nThis method will help you protect this sensitive piece of information by obfuscating some digits.\n\n#### Arguments\n1. `value` _(*)_: The value to mask.\n\n#### Returns\n_(string)_: Returns the masked value by replacing value certain digits by 'X'.\n\n#### Example\n\n```js\nmask({});\n// Throws an Error.\n\nmask('0112345-67');\n// Throws an Error.\n\nmask('01-1234567');\n// =\u003e XX-XXX0000\n\nmask('011234567');\n// =\u003e XXXXX4567\n```\n\n--------------------------------------------------------------------------------\n\n## Tests\nTo test using a local installation of `node.js`:\n\n```sh\nnpm test\n```\n\nTo test using Docker exclusively:\n\n```sh\ndocker-compose run --rm sut\n```\n\n## Release\n\n```sh\nnpm version [\u003cnewversion\u003e | major | minor | patch] -m \"Release %s\"\n```\n\n## License\nMIT\n\n[npm-image]: https://img.shields.io/npm/v/ein-validator.svg?style=flat-square\n[npm-url]: https://npmjs.org/package/ein-validator\n[travis-image]: https://img.shields.io/travis/uphold/ein-validator.svg?style=flat-square\n[travis-url]: https://img.shields.io/travis/uphold/ein-validator.svg?style=flat-square\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fuphold%2Fein-validator","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fuphold%2Fein-validator","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fuphold%2Fein-validator/lists"}