{"id":31322822,"url":"https://github.com/multum/metalize","last_synced_at":"2025-09-25T19:17:30.875Z","repository":{"id":52969426,"uuid":"205390787","full_name":"multum/metalize","owner":"multum","description":"Node.js tool for easy reading database metadata","archived":false,"fork":false,"pushed_at":"2021-04-12T02:07:16.000Z","size":175,"stargazers_count":12,"open_issues_count":0,"forks_count":1,"subscribers_count":2,"default_branch":"main","last_synced_at":"2025-09-21T05:35:28.498Z","etag":null,"topics":["database","metadata","mysql","postgres","postgresql","structure"],"latest_commit_sha":null,"homepage":"https://multum.github.io/metalize","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/multum.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":"CONTRIBUTING.md","funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2019-08-30T13:45:27.000Z","updated_at":"2023-05-06T05:39:40.000Z","dependencies_parsed_at":"2022-08-19T23:50:17.492Z","dependency_job_id":null,"html_url":"https://github.com/multum/metalize","commit_stats":null,"previous_names":[],"tags_count":12,"template":false,"template_full_name":null,"purl":"pkg:github/multum/metalize","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/multum%2Fmetalize","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/multum%2Fmetalize/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/multum%2Fmetalize/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/multum%2Fmetalize/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/multum","download_url":"https://codeload.github.com/multum/metalize/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/multum%2Fmetalize/sbom","scorecard":{"id":667982,"data":{"date":"2025-08-18","repo":{"name":"github.com/multum/metalize","commit":"64f268b8895b9ec0252dff07c98fa97f089936f8"},"scorecard":{"version":"v5.2.1-41-g40576783","commit":"40576783fda6698350fcbbeaea760ff827433034"},"score":3.4,"checks":[{"name":"Maintained","score":0,"reason":"0 commit(s) and 0 issue activity found in the last 90 days -- score normalized to 0","details":null,"documentation":{"short":"Determines if the project is \"actively maintained\".","url":"https://github.com/ossf/scorecard/blob/40576783fda6698350fcbbeaea760ff827433034/docs/checks.md#maintained"}},{"name":"Dangerous-Workflow","score":10,"reason":"no dangerous workflow patterns detected","details":null,"documentation":{"short":"Determines if the project's GitHub Action workflows avoid dangerous patterns.","url":"https://github.com/ossf/scorecard/blob/40576783fda6698350fcbbeaea760ff827433034/docs/checks.md#dangerous-workflow"}},{"name":"Packaging","score":-1,"reason":"packaging workflow not detected","details":["Warn: no GitHub/GitLab publishing workflow detected."],"documentation":{"short":"Determines if the project is published as a package that others can easily download, install, easily update, and uninstall.","url":"https://github.com/ossf/scorecard/blob/40576783fda6698350fcbbeaea760ff827433034/docs/checks.md#packaging"}},{"name":"Code-Review","score":0,"reason":"Found 0/27 approved changesets -- score normalized to 0","details":null,"documentation":{"short":"Determines if the project requires human code review before pull requests (aka merge requests) are merged.","url":"https://github.com/ossf/scorecard/blob/40576783fda6698350fcbbeaea760ff827433034/docs/checks.md#code-review"}},{"name":"Token-Permissions","score":0,"reason":"detected GitHub workflow tokens with excessive permissions","details":["Warn: no topLevel permission defined: .github/workflows/test.yml:1","Info: no jobLevel write permissions found"],"documentation":{"short":"Determines if the project's workflows follow the principle of least privilege.","url":"https://github.com/ossf/scorecard/blob/40576783fda6698350fcbbeaea760ff827433034/docs/checks.md#token-permissions"}},{"name":"CII-Best-Practices","score":0,"reason":"no effort to earn an OpenSSF best practices badge detected","details":null,"documentation":{"short":"Determines if the project has an OpenSSF (formerly CII) Best Practices Badge.","url":"https://github.com/ossf/scorecard/blob/40576783fda6698350fcbbeaea760ff827433034/docs/checks.md#cii-best-practices"}},{"name":"Pinned-Dependencies","score":0,"reason":"dependency not pinned by hash detected -- score normalized to 0","details":["Warn: GitHub-owned GitHubAction not pinned by hash: .github/workflows/test.yml:10: update your workflow using https://app.stepsecurity.io/secureworkflow/multum/metalize/test.yml/main?enable=pin","Warn: GitHub-owned GitHubAction not pinned by hash: .github/workflows/test.yml:13: update your workflow using https://app.stepsecurity.io/secureworkflow/multum/metalize/test.yml/main?enable=pin","Warn: downloadThenRun not pinned by hash: .github/workflows/test.yml:36","Info:   0 out of   2 GitHub-owned GitHubAction dependencies pinned","Info:   0 out of   1 downloadThenRun dependencies pinned"],"documentation":{"short":"Determines if the project has declared and pinned the dependencies of its build process.","url":"https://github.com/ossf/scorecard/blob/40576783fda6698350fcbbeaea760ff827433034/docs/checks.md#pinned-dependencies"}},{"name":"Binary-Artifacts","score":10,"reason":"no binaries found in the repo","details":null,"documentation":{"short":"Determines if the project has generated executable (binary) artifacts in the source repository.","url":"https://github.com/ossf/scorecard/blob/40576783fda6698350fcbbeaea760ff827433034/docs/checks.md#binary-artifacts"}},{"name":"Security-Policy","score":0,"reason":"security policy file not detected","details":["Warn: no security policy file detected","Warn: no security file to analyze","Warn: no security file to analyze","Warn: no security file to analyze"],"documentation":{"short":"Determines if the project has published a security policy.","url":"https://github.com/ossf/scorecard/blob/40576783fda6698350fcbbeaea760ff827433034/docs/checks.md#security-policy"}},{"name":"Vulnerabilities","score":10,"reason":"0 existing vulnerabilities detected","details":null,"documentation":{"short":"Determines if the project has open, known unfixed vulnerabilities.","url":"https://github.com/ossf/scorecard/blob/40576783fda6698350fcbbeaea760ff827433034/docs/checks.md#vulnerabilities"}},{"name":"Fuzzing","score":0,"reason":"project is not fuzzed","details":["Warn: no fuzzer integrations found"],"documentation":{"short":"Determines if the project uses fuzzing.","url":"https://github.com/ossf/scorecard/blob/40576783fda6698350fcbbeaea760ff827433034/docs/checks.md#fuzzing"}},{"name":"License","score":10,"reason":"license file detected","details":["Info: project has a license file: LICENSE:0","Info: FSF or OSI recognized license: MIT License: LICENSE:0"],"documentation":{"short":"Determines if the project has defined a license.","url":"https://github.com/ossf/scorecard/blob/40576783fda6698350fcbbeaea760ff827433034/docs/checks.md#license"}},{"name":"Branch-Protection","score":0,"reason":"branch protection not enabled on development/release branches","details":["Warn: branch protection not enabled for branch 'main'"],"documentation":{"short":"Determines if the default and release branches are protected with GitHub's branch protection settings.","url":"https://github.com/ossf/scorecard/blob/40576783fda6698350fcbbeaea760ff827433034/docs/checks.md#branch-protection"}},{"name":"Signed-Releases","score":-1,"reason":"no releases found","details":null,"documentation":{"short":"Determines if the project cryptographically signs release artifacts.","url":"https://github.com/ossf/scorecard/blob/40576783fda6698350fcbbeaea760ff827433034/docs/checks.md#signed-releases"}},{"name":"SAST","score":0,"reason":"SAST tool is not run on all commits -- score normalized to 0","details":["Warn: 0 commits out of 5 are checked with a SAST tool"],"documentation":{"short":"Determines if the project uses static code analysis.","url":"https://github.com/ossf/scorecard/blob/40576783fda6698350fcbbeaea760ff827433034/docs/checks.md#sast"}}]},"last_synced_at":"2025-08-21T18:48:47.606Z","repository_id":52969426,"created_at":"2025-08-21T18:48:47.606Z","updated_at":"2025-08-21T18:48:47.606Z"},"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":276967008,"owners_count":25736912,"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","status":"online","status_checked_at":"2025-09-25T02:00:09.612Z","response_time":80,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"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":["database","metadata","mysql","postgres","postgresql","structure"],"created_at":"2025-09-25T19:17:29.713Z","updated_at":"2025-09-25T19:17:30.859Z","avatar_url":"https://github.com/multum.png","language":"JavaScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"\u003cbr/\u003e\n\u003cbr/\u003e\n\n\u003cp align='center'\u003e\n  \u003cimg src='https://multum.github.io/metalize/logo.svg' alt='metalize' width='500px'\u003e\n\u003c/p\u003e\n\u003cp align='center'\u003eNode.js tool for easy work with \u003cstrong\u003edatabase metadata\u003c/strong\u003e\u003c/p\u003e\n\n\u003cp align='center'\u003e\n  \u003cimg src='https://github.com/multum/metalize/workflows/Lint%20and%20test/badge.svg' alt=''/\u003e\n  \u003ca href='https://github.com/multum/metalize/blob/main/LICENSE'\u003e\u003cimg src='https://img.shields.io/npm/l/metalize.svg?style=flat' alt=''\u003e\u003c/a\u003e\n  \u003ca href='https://www.npmjs.com/package/metalize'\u003e\u003cimg src='https://img.shields.io/npm/v/metalize.svg?style=flat' alt=''\u003e\u003c/a\u003e\n  \u003cimg src='https://img.shields.io/codecov/c/github/multum/metalize.svg?style=flat' alt=''\u003e\n\u003c/p\u003e\n\n\u003cbr/\u003e\n\n## Features\n\n- Fully tested\n- Fully documented\n- **PostgreSQL** and **MySQL** dialects\n- [**Tables**](https://multum.github.io/metalize/#/metadata/table)\n  - Detailed [column](https://multum.github.io/metalize/#/metadata/column) metadata\n  - Multi-column constraints\n  - [Indexes](https://multum.github.io/metalize/#/metadata/index)\n- [**Sequences**](https://multum.github.io/metalize/#/metadata/sequence)\n\n## Documentation\n\n- [Documentation](https://multum.github.io/metalize/#/)\n- [Contributing](https://github.com/multum/metalize/blob/main/CONTRIBUTING.md)\n\n## Getting Started\n\n```bash\nnpm install metalize pg       # postgres\nnpm install metalize mysql2   # mysql\n```\n\n\u003e **Do not use quotes** in the name of the object. `Metalize` automatically adds them when needed\n\n```javascript\nconst Metalize = require('metalize');\n\nconst metalize = new Metalize({\n  dialect: 'postgres', // one of [ 'postgres', 'mysql' ]\n  connectionConfig: {\n    host: '127.0.0.1',\n    port: 5432,\n    // other connection options for dialect\n  },\n});\n\nmetalize\n  .find({\n    tables: ['public.users', 'public.events'],\n    sequences: ['public.usersSeq'], // only for 'postgres' dialect\n  })\n  .then((result) =\u003e console.log(result));\n\n/**\nResult {\n  'tables': Map {\n    'public.users' =\u003e {\n        columns: [ ... ],\n        primaryKey: { ... },\n        foreignKeys: [ ... ],\n        unique: [ ... ],\n        indexes: [ ... ],\n        checks: [ ... ]\n    },\n    'public.events' =\u003e { ... }\n  }\n  'sequences': Map {\n    'public.usersSeq' =\u003e {\n      start: '1',\n      min: '1',\n      max: '9999',\n      increment: '1',\n      cycle: true,\n    }\n  }\n}\n*/\n```\n\n## Using an existing connection\n\n```javascript\nconst Metalize = require('metalize');\nconst { Client } = require('pg');\n\nconst client = new Client({\n  host: '127.0.0.1',\n  port: 5432,\n  database: 'postgres',\n  user: 'postgres',\n  password: 'postgres',\n});\n\nclient.connect();\n\n/**\n * or using 'mysql' dialect\n * @example\n * const { createConnection } = require('mysql2/promise');\n * const client = await createConnection(...)\n */\n\nconst metalize = new Metalize('postgres');\n\nmetalize\n  .find({ tables: ['public.users'] }, { client })\n  .then((result) =\u003e console.log(result));\n\n/**\n * A new connection will not be opened\n * Instead, the connection from the 'options' will be used\n */\n```\n\n## License\n\n**Metalize** is open source software [licensed as MIT](https://github.com/multum/metalize/blob/main/LICENSE).\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmultum%2Fmetalize","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fmultum%2Fmetalize","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmultum%2Fmetalize/lists"}