{"id":20533648,"url":"https://github.com/inthepocket/npm-license-scraper","last_synced_at":"2025-04-14T06:51:58.666Z","repository":{"id":36066221,"uuid":"221244488","full_name":"inthepocket/npm-license-scraper","owner":"inthepocket","description":"📜 Dead simple license scraper for npm packages (with zero real dependencies)","archived":false,"fork":false,"pushed_at":"2024-06-16T10:10:55.000Z","size":937,"stargazers_count":7,"open_issues_count":2,"forks_count":3,"subscribers_count":22,"default_branch":"master","last_synced_at":"2025-01-29T15:59:33.078Z","etag":null,"topics":["cli","license","npm","scraper","typescript"],"latest_commit_sha":null,"homepage":null,"language":"TypeScript","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/inthepocket.png","metadata":{"files":{"readme":"README.md","changelog":null,"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":"2019-11-12T15:01:50.000Z","updated_at":"2024-05-12T06:42:48.000Z","dependencies_parsed_at":"2024-03-07T14:30:26.009Z","dependency_job_id":"a3022e9b-9363-4c64-90cf-9245ac74b135","html_url":"https://github.com/inthepocket/npm-license-scraper","commit_stats":{"total_commits":38,"total_committers":5,"mean_commits":7.6,"dds":0.631578947368421,"last_synced_commit":"31245b57cbba39da4781828073d291a968db3b00"},"previous_names":[],"tags_count":5,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/inthepocket%2Fnpm-license-scraper","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/inthepocket%2Fnpm-license-scraper/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/inthepocket%2Fnpm-license-scraper/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/inthepocket%2Fnpm-license-scraper/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/inthepocket","download_url":"https://codeload.github.com/inthepocket/npm-license-scraper/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":248837274,"owners_count":21169373,"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":["cli","license","npm","scraper","typescript"],"created_at":"2024-11-16T00:22:59.409Z","updated_at":"2025-04-14T06:51:58.636Z","avatar_url":"https://github.com/inthepocket.png","language":"TypeScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"\u003cimg src=\"./banner.png\" alt=\"NPM license scraper by In The Pocket\" width=\"100%\"\u003e\n\n### 📜 Dead simple license scraper with zero dependencies\n\n[![npm](https://img.shields.io/npm/v/@inthepocket/npm-license-scraper)](https://www.npmjs.com/package/@inthepocket/npm-license-scraper)\n![License: MIT](https://img.shields.io/badge/License-MIT-brightgreen.svg)\n\n## Introduction\n\n`npm-license-scraper` will scan your `package.json` and `node_modules` to generate a JSON file including the licenses of all open source packages that are being used.\n\n## Usage\n\n```shell\n$ npm i -D @inthepocket/npm-license-scraper\n\n# Via npx\n$ npx npm-license-scraper\n\n# Directly\n$ node node_modules/.bin/npm-license-scraper\n```\n\n### Options\n\n- `--export [filename]`: Export to a JSON file. (default `./licenses.json`)\n- `--includeDev`: Include dev dependencies in output (default `false`)\n- `--exclude [package|package,package,package]`: Ignore certain packages from the check (e.g submodules, monorepo or private packages)\n\n## Output format\n\nThe exported JSON file has the following format:\n\n```ts\ntype JSON = Array\u003c{\n  name: string;\n  version: string;\n  license: string;\n  url: string;\n  isValid: boolean;\n}\u003e;\n```\n\nExample:\n\n```json\n[\n  {\n    \"package\": \"react\",\n    \"version\": \"18.0.0\",\n    \"license\": \"MIT\",\n    \"url\": \"https://reactjs.org/\",\n    \"isValid\": true\n  },\n  {\n    \"package\": \"react-native\",\n    \"version\": \"0.69.3\",\n    \"license\": \"MIT\",\n    \"url\": \"https://npmjs.com/package/react-native\",\n    \"isValid\": true\n  }\n]\n```\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Finthepocket%2Fnpm-license-scraper","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Finthepocket%2Fnpm-license-scraper","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Finthepocket%2Fnpm-license-scraper/lists"}