{"id":24430574,"url":"https://github.com/katsew/oq-mapper","last_synced_at":"2026-04-13T12:01:22.154Z","repository":{"id":57315930,"uuid":"95740089","full_name":"katsew/oq-mapper","owner":"katsew","description":"Object/Query mapper for Node.js","archived":false,"fork":false,"pushed_at":"2017-07-20T11:50:29.000Z","size":76,"stargazers_count":2,"open_issues_count":0,"forks_count":1,"subscribers_count":1,"default_branch":"master","last_synced_at":"2025-12-30T21:23:17.080Z","etag":null,"topics":["javascript","json","mapper","nodejs","parser","pegjs","sql","sql-parser"],"latest_commit_sha":null,"homepage":"","language":"JavaScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/katsew.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2017-06-29T04:57:48.000Z","updated_at":"2017-11-22T03:02:31.000Z","dependencies_parsed_at":"2022-08-25T22:40:52.709Z","dependency_job_id":null,"html_url":"https://github.com/katsew/oq-mapper","commit_stats":null,"previous_names":[],"tags_count":11,"template":false,"template_full_name":null,"purl":"pkg:github/katsew/oq-mapper","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/katsew%2Foq-mapper","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/katsew%2Foq-mapper/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/katsew%2Foq-mapper/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/katsew%2Foq-mapper/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/katsew","download_url":"https://codeload.github.com/katsew/oq-mapper/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/katsew%2Foq-mapper/sbom","scorecard":{"id":551699,"data":{"date":"2025-08-11","repo":{"name":"github.com/katsew/oq-mapper","commit":"f065fcaf1f500e6511818b8c0418f3bfe1652c59"},"scorecard":{"version":"v5.2.1-40-gf6ed084d","commit":"f6ed084d17c9236477efd66e5b258b9d4cc7b389"},"score":2.6,"checks":[{"name":"Token-Permissions","score":-1,"reason":"No tokens found","details":null,"documentation":{"short":"Determines if the project's workflows follow the principle of least privilege.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#token-permissions"}},{"name":"Code-Review","score":0,"reason":"Found 0/30 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/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#code-review"}},{"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/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#packaging"}},{"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/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#maintained"}},{"name":"Pinned-Dependencies","score":-1,"reason":"no dependencies found","details":null,"documentation":{"short":"Determines if the project has declared and pinned the dependencies of its build process.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#pinned-dependencies"}},{"name":"SAST","score":0,"reason":"no SAST tool detected","details":["Warn: no pull requests merged into dev branch"],"documentation":{"short":"Determines if the project uses static code analysis.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#sast"}},{"name":"Dangerous-Workflow","score":-1,"reason":"no workflows found","details":null,"documentation":{"short":"Determines if the project's GitHub Action workflows avoid dangerous patterns.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#dangerous-workflow"}},{"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/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#binary-artifacts"}},{"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/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#cii-best-practices"}},{"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/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#security-policy"}},{"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/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#fuzzing"}},{"name":"License","score":0,"reason":"license file not detected","details":["Warn: project does not have a license file"],"documentation":{"short":"Determines if the project has defined a license.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#license"}},{"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/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#signed-releases"}},{"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/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#vulnerabilities"}},{"name":"Branch-Protection","score":0,"reason":"branch protection not enabled on development/release branches","details":["Warn: branch protection not enabled for branch 'master'"],"documentation":{"short":"Determines if the default and release branches are protected with GitHub's branch protection settings.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#branch-protection"}}]},"last_synced_at":"2025-08-20T11:03:51.304Z","repository_id":57315930,"created_at":"2025-08-20T11:03:51.304Z","updated_at":"2025-08-20T11:03:51.304Z"},"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":31751705,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-04-13T09:16:15.125Z","status":"ssl_error","status_checked_at":"2026-04-13T09:16:05.023Z","response_time":93,"last_error":"SSL_connect returned=1 errno=0 peeraddr=140.82.121.6:443 state=error: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"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":["javascript","json","mapper","nodejs","parser","pegjs","sql","sql-parser"],"created_at":"2025-01-20T14:31:45.831Z","updated_at":"2026-04-13T12:01:22.126Z","avatar_url":"https://github.com/katsew.png","language":"JavaScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Abstract\n\nObject/Query mapper for Node.js.\n\n:zap: Currently support only `CREATE TABLE` statement.\n\n# Use the module as command-line tool\n\nInstall via npm.\n\n```\nnpm install -g oq-mapper\n```\n\nThen, run command\n\n```\noq-mapper \u003cfile\u003e \u003coutput\u003e\n```\n\nOutput file is compatible with JSON.\n\n# Behaviour\n\nThis query outputs...\n\n```\n\nCREATE TABLE IF NOT EXISTS `dvd_collection`.`movies` (\n  `movie_id` INT NOT NULL AUTO_INCREMENT,\n  `movie_title` VARCHAR(45) NOT NULL,\n  `release_date` DATE NULL,\n  PRIMARY KEY (`movie_id`))\nENGINE = InnoDB\n\n```\n\nThis kind of object structure!\n\n```\n\n[\n   {\n      \"dbName\": \"dvd_collection\",\n      \"tableName\": \"movies\",\n      \"pk\": [\n         \"movie_id\"\n      ],\n      \"fields\": [\n         {\n            \"name\": \"movie_id\",\n            \"type\": \"int\",\n            \"sign\": \"signed\",\n            \"length\": 0,\n            \"min\": -2147483648,\n            \"max\": 2147483647,\n            \"bites\": 4,\n            \"allowNull\": false,\n            \"default\": 0,\n            \"autoIncrement\": true\n         },\n         {\n            \"name\": \"movie_title\",\n            \"type\": \"varchar\",\n            \"length\": 0,\n            \"allowNull\": false,\n            \"default\": \"\",\n            \"autoIncrement\": false\n         },\n         {\n            \"name\": \"release_date\",\n            \"type\": \"date\",\n            \"allowNull\": true,\n            \"default\": \"CURRENT_TIMESTAMP\",\n            \"autoIncrement\": false\n         }\n      ],\n      \"constraint\": [],\n      \"index\": []\n   }\n]\n\n```\n\n# Features\n\n## Parse tags in comment\n\nWhen you add comment with tags, like [Go#StructTag](https://golang.org/pkg/reflect/#example_StructTag), \n\n```\n\nCREATE TABLE IF NOT EXISTS `dvd_collection`.`movies` (\n  `movie_id` INT NOT NULL AUTO_INCREMENT,\n  `movie_title` VARCHAR(45) NOT NULL,\n  `is_sold` tinyint(1) unsigned NOT NULL DEFAULT '0' COMMENT '`types:\"0,1\" strategy:\"random\"`',\n  `release_date` DATE NULL,\n  PRIMARY KEY (`movie_id`))\nENGINE = InnoDB\n\n```\n\nparse that tag, and create object like following.\n\n```\n[\n  ...\n  \"fields\": [\n    {\n      \"name\": \"is_sold\",\n      ...\n      \"comment\": \"`types:'0, 1' strategy:'random'`\",\n      \"tags\": [\n          {\n            \"types\": \"0,1\"\n          },\n          {\n            \"strategy\": \"random\"\n          }\n      ]\n    }\n  ]\n  ...\n]\n```","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fkatsew%2Foq-mapper","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fkatsew%2Foq-mapper","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fkatsew%2Foq-mapper/lists"}