{"id":26723012,"url":"https://github.com/shiwano/typhen-json-schema","last_synced_at":"2026-03-07T19:33:26.580Z","repository":{"id":26032262,"uuid":"29475302","full_name":"shiwano/typhen-json-schema","owner":"shiwano","description":"Converts TypeScript Interfaces to JSON Schema.","archived":false,"fork":false,"pushed_at":"2017-04-20T17:48:03.000Z","size":34,"stargazers_count":20,"open_issues_count":1,"forks_count":8,"subscribers_count":3,"default_branch":"master","last_synced_at":"2026-02-06T13:32:23.844Z","etag":null,"topics":["json-schema"],"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/shiwano.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}},"created_at":"2015-01-19T14:44:55.000Z","updated_at":"2020-04-22T03:18:05.000Z","dependencies_parsed_at":"2022-08-24T14:19:44.238Z","dependency_job_id":null,"html_url":"https://github.com/shiwano/typhen-json-schema","commit_stats":null,"previous_names":[],"tags_count":10,"template":false,"template_full_name":null,"purl":"pkg:github/shiwano/typhen-json-schema","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/shiwano%2Ftyphen-json-schema","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/shiwano%2Ftyphen-json-schema/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/shiwano%2Ftyphen-json-schema/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/shiwano%2Ftyphen-json-schema/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/shiwano","download_url":"https://codeload.github.com/shiwano/typhen-json-schema/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/shiwano%2Ftyphen-json-schema/sbom","scorecard":{"id":819779,"data":{"date":"2025-08-11","repo":{"name":"github.com/shiwano/typhen-json-schema","commit":"3496f4ff6b8f418f2ca0b89d4eacf1f5ae5bceef"},"scorecard":{"version":"v5.2.1-40-gf6ed084d","commit":"f6ed084d17c9236477efd66e5b258b9d4cc7b389"},"score":3,"checks":[{"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":"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":"Code-Review","score":0,"reason":"Found 2/28 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":"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":"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":"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":"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":"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":"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":"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":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/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":"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"}},{"name":"SAST","score":0,"reason":"SAST tool is not run on all commits -- score normalized to 0","details":["Warn: 0 commits out of 4 are checked with a SAST tool"],"documentation":{"short":"Determines if the project uses static code analysis.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#sast"}}]},"last_synced_at":"2025-08-23T15:11:01.880Z","repository_id":26032262,"created_at":"2025-08-23T15:11:01.880Z","updated_at":"2025-08-23T15:11:01.880Z"},"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":29362205,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-02-12T08:51:36.827Z","status":"ssl_error","status_checked_at":"2026-02-12T08:51:26.849Z","response_time":55,"last_error":"SSL_read: 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":["json-schema"],"created_at":"2025-03-27T20:39:08.504Z","updated_at":"2026-03-07T19:33:26.558Z","avatar_url":"https://github.com/shiwano.png","language":"JavaScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# typhen-json-schema [![Build Status](https://secure.travis-ci.org/shiwano/typhen-json-schema.png?branch=master)](http://travis-ci.org/shiwano/typhen-json-schema) [![npm version](https://badge.fury.io/js/typhen-json-schema.svg)](http://badge.fury.io/js/typhen-json-schema)\n\n\u003e Converts TypeScript Interfaces to JSON Schema\n\n## Getting Started\nIf you haven't used [typhen](https://github.com/shiwano/typhen) before, be sure to check out the README.\n\n```sh\n$ npm install --save-dev typhen-json-schema\n$ vi tsconfig.json # Add settings.\n$ typhen\n```\n\n```sh\n$ npm install -g typhen-json-schema\n$ typhen --plugin typhen-json-schema --dest generated definitions.d.ts\n```\n\n## The \"typhen-json-schema\" plugin\n\n### Overview\nIn your project's tsconfig.json, add settings for using the plugin.\n\n```js\n{\n  \"files\": [\n    \"src/index.ts\"\n  ],\n  \"compilerOptions\": {\n    \"module\": \"commonjs\",\n    \"target\": \"ES5\"\n  },\n  \"typhen\": [\n    {\n      \"plugin\": \"typhen-json-schema\",\n      \"pluginOptions\": {\n        \"baseUri\": \"http://example.com/my-schema\",\n        \"enumType\": \"string\"\n      },\n      \"outDir\": \"output-directory\",\n      \"files\": [ \"typings/json.d.ts\" ]\n    }\n  ]\n}\n```\n\nIf you want to use an `integer` type of JSON Schema, you will add the interface declaration to the beginning of a file, or add `@integer` tag to number's documentation comments.\n\n```ts\ninterface integer {}\n```\n\n```ts\n  /**\n    @integer\n   */\n  age: number;\n```\n\n### Options\n\n#### baseUri\nType: `String`\nDefault value: `''`\n\nThe base uri that is used to define a reference to another JSON Schema.\n\n#### enumType\nType: `String`\nDefault value: `'integer'`\n\nA value that specifies enum value. It is either `string` or `integer`.\n\n### Validations\n\nYou can define validation rules by adding tags in documentation comments like the below.\n\n```ts\n  /**\n    @minimum 0\n    @exclusiveMinimum\n   */\n  price: number;\n```\n\n#### string validations\n\n* @minLength {number}\n* @maxLength {number}\n* @pattern {string}\n* @format {string}\n* @default {string}\n\n#### number or integer validations\n\n* @multipleOf {number}\n* @minimum {number}\n* @maximum {number}\n* @exclusiveMinimum\n* @exclusiveMaximum\n* @default {number}\n\n#### object validations\n\n* @minProperties {number}\n* @maxProperties {number}\n\n#### array validations\n\n* @minItems {number}\n* @maxItems {number}\n* @uniqueItems\n\n## Contributing\nIn lieu of a formal styleguide, take care to maintain the existing coding style. Add unit tests for any new or changed functionality. Lint and test your code using [gulp.js](http://gulpjs.com/).\n\n## Contributors\n\n* Shogo Iwano (@shiwano)\n* Horiuchi_H (@horiuchi)\n* @nabilnaffar\n\n## License\nCopyright (c) 2015 Shogo Iwano\nLicensed under the MIT license.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fshiwano%2Ftyphen-json-schema","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fshiwano%2Ftyphen-json-schema","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fshiwano%2Ftyphen-json-schema/lists"}