{"id":16552676,"url":"https://github.com/deveshsangwan/cricketscoreapi","last_synced_at":"2025-10-08T08:25:14.963Z","repository":{"id":251329016,"uuid":"606481926","full_name":"deveshsangwan/cricketScoreApi","owner":"deveshsangwan","description":"Welcome to the Cricket Score API! This project is designed to provide real-time cricket scores using TypeScript and npm. It uses technologies like Cheerio for web scraping, Prisma for accessing MongoDB, Express-jwt for authentication, and Chai and Mocha for testing.","archived":false,"fork":false,"pushed_at":"2025-10-06T18:13:27.000Z","size":1106,"stargazers_count":3,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-10-06T20:24:25.396Z","etag":null,"topics":["api","cheerio","cricket","cricket-api","cricket-data","cricket-score","cricket-stats","docker","express","jwt-authentication","livescore","mocha-chai","mongodb","nodejs","prisma","realtime-data","rest-api","sports-data","typescript","webscraping"],"latest_commit_sha":null,"homepage":"https://cricscore.deveshsangwan.com","language":"TypeScript","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/deveshsangwan.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,"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":"2023-02-25T16:17:40.000Z","updated_at":"2025-10-06T18:10:10.000Z","dependencies_parsed_at":"2024-08-02T09:13:49.575Z","dependency_job_id":"61fd4d85-6de1-47a1-a150-b3daa4a61a23","html_url":"https://github.com/deveshsangwan/cricketScoreApi","commit_stats":null,"previous_names":["deveshsangwan/cricketscoreapi"],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/deveshsangwan/cricketScoreApi","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/deveshsangwan%2FcricketScoreApi","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/deveshsangwan%2FcricketScoreApi/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/deveshsangwan%2FcricketScoreApi/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/deveshsangwan%2FcricketScoreApi/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/deveshsangwan","download_url":"https://codeload.github.com/deveshsangwan/cricketScoreApi/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/deveshsangwan%2FcricketScoreApi/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":278911592,"owners_count":26067289,"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-08T02:00:06.501Z","response_time":56,"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":["api","cheerio","cricket","cricket-api","cricket-data","cricket-score","cricket-stats","docker","express","jwt-authentication","livescore","mocha-chai","mongodb","nodejs","prisma","realtime-data","rest-api","sports-data","typescript","webscraping"],"created_at":"2024-10-11T19:45:46.141Z","updated_at":"2025-10-08T08:25:14.958Z","avatar_url":"https://github.com/deveshsangwan.png","language":"TypeScript","readme":"# 🏏 Cricket Score Monorepo\n\nWelcome to the Cricket Score monorepo! This repository contains the frontend and backend for a real-time cricket score application.\n\n## 🚀 Projects\n\nThis monorepo contains the following projects:\n\n- **`apps/cricket-score-frontend`**: A [Next.js](https://nextjs.org/) frontend that displays live cricket scores and statistics. See the [frontend README](./apps/cricket-score-frontend/README.md) for more details.\n- **`apps/cricketscoreapi`**: A [TypeScript](https://www.typescriptlang.org/) backend exposing a **tRPC API** (via Express) for cricket data. See the [backend README](./apps/cricketscoreapi/README.md) for more details.\n- **`packages/shared-types`**: Shared TypeScript types consumed by both the backend and frontend.\n\n## 🛠️ Technologies Used\n\nThis monorepo uses [pnpm](https://pnpm.io/) for workspace management.\n\n### Frontend\n\n- [Next.js](https://nextjs.org/)\n- [React](https://reactjs.org/)\n- [TypeScript](https://www.typescriptlang.org/)\n- [Tailwind CSS](https://tailwindcss.com/)\n- [Clerk](https://clerk.com/)\n\n### Backend\n\n- [TypeScript](https://www.typescriptlang.org/)\n- [Express.js](https://expressjs.com/)\n- [tRPC](https://trpc.io/)\n- [Prisma](https://www.prisma.io/)\n- [MongoDB](https://www.mongodb.com/)\n- [Cheerio](https://cheerio.js.org/)\n- [Docker](https://www.docker.com/)\n\n## 🚀 Getting Started\n\nTo get started with this monorepo, you'll need to have [pnpm](https://pnpm.io/) installed. Then, you can install the dependencies from the root of the repository:\n\n```bash\npnpm install\n```\n\nThis will install the dependencies for all the projects in the monorepo.\n\n### Running the projects\n\nYou can run the frontend and backend projects separately using the following commands:\n\n```bash\n# Run both frontend and backend (concurrently)\npnpm dev\n\n# Or run them separately\npnpm frontend:dev\npnpm backend:dev\n```\n\nPorts:\n- Frontend: `http://localhost:3000`\n- Backend tRPC endpoint: `http://localhost:3001/trpc`\n\n## 🔄 Real-time Flow (Sequence Diagram)\n\n```mermaid\nsequenceDiagram\n  participant UI as Match Page\n  participant Hook as useOptimizedRealTimeMatchStats\n  participant TRPC as tRPC Client (splitLink)\n  participant Sub as httpSubscriptionLink (SSE)\n  participant API as cricketscoreapi Router\n\n  UI-\u003e\u003eHook: init(matchId)\n  Hook-\u003e\u003eTRPC: subscribeMatchStatsById(matchId)\n  TRPC--\u003e\u003eSub: route op: type=subscription\n  Sub-\u003e\u003eAPI: SSE connect with Authorization\n  API--\u003e\u003eSub: initial MatchStats\n  Sub--\u003e\u003eHook: data event\n  Hook--\u003e\u003eUI: set state/render\n  loop every 30s until abort\n    API--\u003e\u003eSub: updated MatchStats\n    Sub--\u003e\u003eHook: data event\n    Hook--\u003e\u003eUI: update state\n  end\n  UI-\u003e\u003eHook: unmount/abort\n  Hook-\u003e\u003eSub: close\n  Sub-\u003e\u003eAPI: abort\n```\n\n## 📜 License\n\nEach project in this monorepo has its own license. Please refer to the `LICENSE.md` file in each project's directory for more information.","funding_links":[],"categories":[],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdeveshsangwan%2Fcricketscoreapi","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fdeveshsangwan%2Fcricketscoreapi","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdeveshsangwan%2Fcricketscoreapi/lists"}