{"id":37229564,"url":"https://github.com/bcgov/pubcode","last_synced_at":"2026-03-02T02:03:19.194Z","repository":{"id":65634481,"uuid":"575524926","full_name":"bcgov/pubcode","owner":"bcgov","description":"This repository will house all the source code and artifacts related to public code asset management of BCGov.","archived":false,"fork":false,"pushed_at":"2026-01-02T08:35:35.000Z","size":2865,"stargazers_count":11,"open_issues_count":15,"forks_count":0,"subscribers_count":2,"default_branch":"main","last_synced_at":"2026-01-06T05:15:16.384Z","etag":null,"topics":["express","mongodb","nodejs","react"],"latest_commit_sha":null,"homepage":"https://pubcode.apps.silver.devops.gov.bc.ca/","language":"JavaScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"apache-2.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/bcgov.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":"CONTRIBUTING.md","funding":null,"license":"LICENSE","code_of_conduct":"CODE_OF_CONDUCT.md","threat_model":null,"audit":null,"citation":null,"codeowners":".github/CODEOWNERS","security":"SECURITY.md","support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null,"notice":null,"maintainers":null,"copyright":null,"agents":null,"dco":null,"cla":null}},"created_at":"2022-12-07T17:51:23.000Z","updated_at":"2026-01-02T08:35:39.000Z","dependencies_parsed_at":"2023-11-10T18:31:40.903Z","dependency_job_id":"a94c4abd-6695-46f8-bb64-f252accd2909","html_url":"https://github.com/bcgov/pubcode","commit_stats":null,"previous_names":[],"tags_count":154,"template":false,"template_full_name":"bcgov/quickstart-openshift","purl":"pkg:github/bcgov/pubcode","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/bcgov%2Fpubcode","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/bcgov%2Fpubcode/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/bcgov%2Fpubcode/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/bcgov%2Fpubcode/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/bcgov","download_url":"https://codeload.github.com/bcgov/pubcode/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/bcgov%2Fpubcode/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":28442288,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-01-15T00:55:22.719Z","status":"online","status_checked_at":"2026-01-15T02:00:08.019Z","response_time":62,"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":["express","mongodb","nodejs","react"],"created_at":"2026-01-15T03:33:28.545Z","updated_at":"2026-01-15T03:33:29.205Z","avatar_url":"https://github.com/bcgov.png","language":"JavaScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"\u003c!-- PROJECT SHIELDS --\u003e\n\n\n[![Issues](https://img.shields.io/github/issues/bcgov/pubcode)](/../../issues)\n[![Pull Requests](https://img.shields.io/github/issues-pr/bcgov/pubcode)](/../../pulls)\n[![MIT License](https://img.shields.io/github/license/bcgov/pubcode.svg)](/LICENSE.md)\n[![Lifecycle](https://img.shields.io/badge/Lifecycle-Experimental-339999)](https://github.com/bcgov/repomountie/blob/master/doc/lifecycle-badges.md)\n\n\n# BCGov public code asset tracking\n\nThis contains schema definitions for yml and a web application to assist end users to create/edit bcgovpubcode.yml files, store them in a MongoDB database and retrieve them using a Node/Express API.\n\n## Architecture\n![Pub Code Architecture](.diagrams/architecture/pub-code.drawio.svg)\n\n\n## FAQ\nPlease click [here](https://github.com/bcgov/pubcode/wiki/Frequently-Asked-Questions)\n\n## Components\n\n1. Database (MongoDB): Stores all bcgovpubcode.yml files, converted to JSON, for each participating repo in the bcgov organization.\n2. Backend (Node/Express API): Provides read and write access to the database. The read endpoint is open to the public, while the write endpoint is protected by an API key. Both are rate-limited.\n3. Crawler (Node module): Crawls through GitHub repos on a schedule, collects any bcgovpubcode.yml files, converts to JSON, and stores using the API's write endpoint.\n4. Frontend (React.js and MaterialUI): Allows users to create bcgovpubcode.yml files or edit existing ones using a GitHub link.\n5. Schema (JSON Schema): The standard on which the bcgovpubcode.yml file is based.\n\n## How it works\n\n1. The Crawler runs in a [scheduled GitHub Action](.github/workflows/pubcode-crawler-on-scheduler.yml), collecting bcgovpubcode.yml files from participating GitHub repositories.\n2. Yaml is converted to JSON and sent to the API's write endpoint, which is secured with an API key.\n3. The API stores to the MongoDB database.\n4. Users can access all data from the API's read endpoint.\n5. Frontend allows users to create or edit bcgovpubcode.yml files, which are validated against the [JSON schema](schema/bcgovpubcode.json).\n\n## Note\n\nOnly the Crawler module is allowed to call the APIs post endpoint, which uses the MongoDB as its source of truth.\n\n```mermaid\nsequenceDiagram\n  participant Crawler\n  participant API\n  participant MongoDB\n  participant Frontend\n  participant JSON Schema\n  participant GitHub Repos\n\n  Crawler-\u003e\u003eGitHub Repos: Crawls through\n  GitHub Repos-\u003e\u003eCrawler: Collects bcgovpubcode.yml files\n  Crawler-\u003e\u003eAPI: Calls the secured post endpoint\n  API-\u003e\u003eMongoDB: Stores JSON data\n  Frontend-\u003e\u003eJSON Schema: Uses as standard to create or edit bcgovpubcode.yml files\n```\n\n## More Information\n\nPlease see README.md files in each component's folder to learn more.\n\n[api/README.md](api/README.md)\n\n[schema/README.md](schema/README.md)\n\n[frontend/README.md](frontend/README.md)\n\n[crawler/README.md](crawler/README.md)\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fbcgov%2Fpubcode","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fbcgov%2Fpubcode","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fbcgov%2Fpubcode/lists"}