{"id":26675261,"url":"https://github.com/128technology/ply","last_synced_at":"2025-10-12T11:50:13.047Z","repository":{"id":32433379,"uuid":"132802492","full_name":"128technology/ply","owner":"128technology","description":"Presentation Language for Yinz","archived":false,"fork":false,"pushed_at":"2022-12-30T18:45:17.000Z","size":508,"stargazers_count":2,"open_issues_count":4,"forks_count":1,"subscribers_count":8,"default_branch":"master","last_synced_at":"2025-08-23T05:13:04.687Z","etag":null,"topics":["datamodel","model","presentation","typescript","yang","yin"],"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/128technology.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":"2018-05-09T19:16:05.000Z","updated_at":"2021-08-10T14:46:26.000Z","dependencies_parsed_at":"2023-01-14T21:11:46.955Z","dependency_job_id":null,"html_url":"https://github.com/128technology/ply","commit_stats":null,"previous_names":[],"tags_count":15,"template":false,"template_full_name":null,"purl":"pkg:github/128technology/ply","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/128technology%2Fply","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/128technology%2Fply/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/128technology%2Fply/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/128technology%2Fply/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/128technology","download_url":"https://codeload.github.com/128technology/ply/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/128technology%2Fply/sbom","scorecard":{"id":1375,"data":{"date":"2025-08-11","repo":{"name":"github.com/128technology/ply","commit":"6281702d6ef130a89260a84c5a06096f27be8514"},"scorecard":{"version":"v5.2.1-40-gf6ed084d","commit":"f6ed084d17c9236477efd66e5b258b9d4cc7b389"},"score":3,"checks":[{"name":"Code-Review","score":0,"reason":"Found 0/14 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":"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/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#dangerous-workflow"}},{"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":0,"reason":"detected GitHub workflow tokens with excessive permissions","details":["Warn: no topLevel permission defined: .github/workflows/ci.js.yml:1","Warn: no topLevel permission defined: .github/workflows/publish.js.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/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":"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/ci.js.yml:10: update your workflow using https://app.stepsecurity.io/secureworkflow/128technology/ply/ci.js.yml/master?enable=pin","Warn: GitHub-owned GitHubAction not pinned by hash: .github/workflows/ci.js.yml:12: update your workflow using https://app.stepsecurity.io/secureworkflow/128technology/ply/ci.js.yml/master?enable=pin","Warn: GitHub-owned GitHubAction not pinned by hash: .github/workflows/publish.js.yml:9: update your workflow using https://app.stepsecurity.io/secureworkflow/128technology/ply/publish.js.yml/master?enable=pin","Warn: GitHub-owned GitHubAction not pinned by hash: .github/workflows/publish.js.yml:11: update your workflow using https://app.stepsecurity.io/secureworkflow/128technology/ply/publish.js.yml/master?enable=pin","Warn: npmCommand not pinned by hash: .github/workflows/ci.js.yml:16","Warn: npmCommand not pinned by hash: .github/workflows/publish.js.yml:16","Info:   0 out of   4 GitHub-owned GitHubAction dependencies pinned","Info:   0 out of   2 npmCommand 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/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#pinned-dependencies"}},{"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":"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":"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":-1,"reason":"internal error: error during branchesHandler.setup: internal error: githubv4.Query: Resource not accessible by integration","details":null,"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":"Vulnerabilities","score":0,"reason":"17 existing vulnerabilities detected","details":["Warn: Project is vulnerable to: GHSA-93q8-gq69-wqmw","Warn: Project is vulnerable to: GHSA-v6h2-p8h4-qcjw","Warn: Project is vulnerable to: GHSA-gxpj-cx7g-858c","Warn: Project is vulnerable to: GHSA-2j2x-2gpw-g8fm","Warn: Project is vulnerable to: GHSA-78h3-pg4x-j8cv","Warn: Project is vulnerable to: GHSA-mjr4-7xg5-pfvh","Warn: Project is vulnerable to: GHSA-f8q6-p94x-37v3","Warn: Project is vulnerable to: GHSA-xvch-5gv4-984h","Warn: Project is vulnerable to: GHSA-r683-j2x4-v87g","Warn: Project is vulnerable to: GHSA-hj48-42vr-x3v9","Warn: Project is vulnerable to: GHSA-c2qf-rxjj-qqgw","Warn: Project is vulnerable to: GHSA-3jfq-g458-7qm9","Warn: Project is vulnerable to: GHSA-r628-mhmh-qjhw","Warn: Project is vulnerable to: GHSA-9r2w-394v-53qc","Warn: Project is vulnerable to: GHSA-5955-9wpr-37jh","Warn: Project is vulnerable to: GHSA-qq89-hq3f-393p","Warn: Project is vulnerable to: GHSA-f5x3-32g6-xq36"],"documentation":{"short":"Determines if the project has open, known unfixed vulnerabilities.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#vulnerabilities"}},{"name":"SAST","score":-1,"reason":"internal error: internal error: Client.Checks.ListCheckRunsForRef: error during graphqlHandler.setupCheckRuns: non-200 OK status code: 502 Bad Gateway body: \"\u003chtml\u003e\\r\\n\u003chead\u003e\u003ctitle\u003e502 Bad Gateway\u003c/title\u003e\u003c/head\u003e\\r\\n\u003cbody\u003e\\r\\n\u003ccenter\u003e\u003ch1\u003e502 Bad Gateway\u003c/h1\u003e\u003c/center\u003e\\r\\n\u003chr\u003e\u003ccenter\u003enginx\u003c/center\u003e\\r\\n\u003c/body\u003e\\r\\n\u003c/html\u003e\\r\\n\"","details":null,"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-14T12:36:37.642Z","repository_id":32433379,"created_at":"2025-08-14T12:36:37.642Z","updated_at":"2025-08-14T12:36:37.642Z"},"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":279011187,"owners_count":26084900,"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-10-12T02:00:06.719Z","response_time":53,"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":["datamodel","model","presentation","typescript","yang","yin"],"created_at":"2025-03-26T03:17:20.346Z","updated_at":"2025-10-12T11:50:13.012Z","avatar_url":"https://github.com/128technology.png","language":"TypeScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# PLY ![Node.js CI](https://github.com/128technology/ply/workflows/Node.js%20CI/badge.svg) ![npm version](https://badge.fury.io/js/%40128technology%2Fply.svg)\n\nPLY (**P**resentation **L**anguage for **Y**inz) is a library to manage JSON files that model a GUI for configuring a YANG (RFC 6020) datastore. It directly integrates with the [Yinz](https://github.com/128technology/yinz) library which manages both the datamodel and instance data associated with that datamodel.\n\nPLY intends to provide the following functionality:\n* Ingest a presentation model described by one or more JSON files.\n* Ingest a datamodel and associate it with the presentation model. The datamodel will be used to look up information from fields.\n* Injest an instance of the model and associate the values from the instance with presentation fields.\n* Serialize this *presentation instance* to JSON that can be sent to a client to draw a GUI.\n* Validate that a presentation model is both syntactically and semantically valid.\n* Given a datamodel, ensure that all aspects of the datamodel have a corresponding entry in the presentation model.\n\n# Model Format\n\n## Pages\nA page is typically broken out into it's own JSON file. Pages generally represent containers and instances of list items.  For example, if the model has a list of routers, there would probably be a page named `router.json` which describes what an instance of a router would look like.  The schema of a page is pretty simple, it contains a `title`, an `id`, and an array of `sections`.  The most basic page would like like the following:\n```json\n{\n  \"id\": \"my-new-page\",\n  \"title\": \"My New Page\",\n  \"sections\": []\n}\n```\n\nGenerally it is a good idea for the page `id` to match the name of the file.  For example, `router.json` would have an `id` of `router`.\n\n## Sections\n\n### `leaf-section`\nIf you have a section of basic fields (e.g. no containers, lists, or leaf-lists), then this is the section type you would want to use. This section type has an `id`, a `title`, and an array of `fields`. Generally the `id` for the section has the format `page-id.section-id`, so if it was on the `router` page it might look something like `router.settings`. **If you do not specify a type for a section it will default to this type.**  A basic `leaf-section` looks like the following:\n```json\n{\n  \"id\": \"my-new-page.my-new-section\",\n  \"title\": \"My New Section\",\n  \"fields\": []\n}\n```\n\nIf you chose to specify the type explicitly it would look like:\n```json\n{\n  \"id\": \"my-new-page.my-leaf-section\",\n  \"title\": \"My Leaf Section\",\n  \"type\": \"leaf-section\",\n  \"fields\": []\n}\n```\n\n### `list-section`\nAll lists need to be contained in their own `list-section`. A `list-section` will have exactly one field which references the list itself.  A `list-section`'s `title` field is explicitly set to `null` and the `label` of the list field inside the section is used instead. The specifics of the single list field are outlined in the Fields section, including descriptions of the `link` and `columns` properties.  A basic `list-section` looks like the following:\n```json\n{\n  \"id\": \"my-new-page.my-list-section\",\n  \"title\": null,\n  \"type\": \"list-section\",\n  \"fields\": [{\n    \"link\": \"dog\",\n    \"id\": \"id.to.a.list\",\n    \"label\": \"Dogs\"\n  }]\n}\n```\n\n### `list-table`\nAll leaf-lists need to be contained in their own `list-table` section.  Similarly to the `list-section` a `list-table` section has exactly one field describing the leaf-list.  It also has a `title` explicitly set to `null`.  An example `list-table` section looks like the following:\n```json\n{\n  \"id\": \"my-new-page.my-list-table-section\",\n  \"title\": null,\n  \"type\": \"list-table\",\n  \"fields\": [{\n    \"id\": \"id.to.a.leaf-list\",\n    \"label\": \"Cats\",\n    \"columnLabels\": [{\n      \"id\": \"name\",\n      \"label\": \"Cat\"\n    }]\n  }]\n}\n```\n\n### `container-list-section`\nIf you want links that dive into one or more containers/pages in a section, you will want to use the `container-list-section`.  An example looks like the following:\n```json\n{\n  \"id\": \"my-new-page.my-link-section\",\n  \"title\": \"Example Container Links\",\n  \"type\": \"container-list-section\",\n  \"fields\": [{\n    \"id\": \"id.to.a.container\",\n    \"link\": \"container-1\",\n    \"label\": \"Container 1\"\n  }]\n}\n```\n\n## Fields\n\n### `leaf`\n```json\n{\n  \"id\": \"id.to.a.leaf\",\n  \"label\": \"My Leaf Field\"\n}\n```\n\n### `choice`\nWhile a choice field technically has no value in the `running` config, it will be populated with the cases in the model and the selected case is inferred at runtime.\n```json\n{\n  \"id\": \"id.to.a.choice\",\n  \"label\": \"My Choice Field\"\n}\n```\n\n### `container`\nContainers do not have to be represented in the presentation model.  They should be used in cases where a link to a page representing the container is desired. The `link` **MUST** correspond to an `id` of another page.\n```json\n{\n  \"id\": \"id.to.a.container\",\n  \"label\": \"My Container Field\",\n  \"link\": \"page-for-container\"\n}\n```\n\n### `leaf-list`\nThe `columnLabels` property is used to describe a label for the columns of a table displaying the `leaf-list`.  In this case since a `leaf-list` only has one column, this array should only contain one item. **A `leaf-list` field can only by contained in a `list-table` section.** \n```json\n{\n  \"id\": \"id.to.a.leaf-list\",\n  \"label\": \"My Leaf List Field\",\n  \"columnLabels\": [{\n    \"id\": \"thing\",\n    \"label\": \"thing\"\n  }]\n}\n```\n\n### `list`\nThe `columns` property of a list field is optional.  It is intended to denote which columns (leafs) should be displayed if the list if presented in a table.  Otherwise typically only the key fields would be presented in a table.  The `link` **MUST** correspond to an `id` of the page for the list instance.  For example if the list field describes the list of all routers, then the link must correspond to the `router` page describing an individual router.  **A `list` field can only by contained in a `list-section`.** \n ```json\n{\n  \"id\": \"id.to.a.leaf-list\",\n  \"label\": \"My List Field\",\n  \"link\": \"my-list-instance\",\n  \"columns\": [\"name\", \"description\"]\n}\n```\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2F128technology%2Fply","html_url":"https://awesome.ecosyste.ms/projects/github.com%2F128technology%2Fply","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2F128technology%2Fply/lists"}