{"id":32402254,"url":"https://github.com/afkcodes/sunoh-api","last_synced_at":"2025-10-25T10:19:21.423Z","repository":{"id":249531611,"uuid":"831767567","full_name":"afkcodes/sunoh-api","owner":"afkcodes","description":"fastify backend powering sunoh","archived":false,"fork":false,"pushed_at":"2025-08-23T14:45:02.000Z","size":105,"stargazers_count":2,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-08-24T05:04:09.965Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"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/afkcodes.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}},"created_at":"2024-07-21T15:15:55.000Z","updated_at":"2025-08-23T14:45:05.000Z","dependencies_parsed_at":"2024-11-26T08:23:42.537Z","dependency_job_id":"ff25cb52-97c2-4ecd-b0c2-aa3f27fd1ed2","html_url":"https://github.com/afkcodes/sunoh-api","commit_stats":null,"previous_names":["afkcodes/sunoh-api"],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/afkcodes/sunoh-api","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/afkcodes%2Fsunoh-api","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/afkcodes%2Fsunoh-api/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/afkcodes%2Fsunoh-api/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/afkcodes%2Fsunoh-api/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/afkcodes","download_url":"https://codeload.github.com/afkcodes/sunoh-api/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/afkcodes%2Fsunoh-api/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":280939077,"owners_count":26417068,"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-25T02:00:06.499Z","response_time":81,"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":[],"created_at":"2025-10-25T10:19:16.110Z","updated_at":"2025-10-25T10:19:21.417Z","avatar_url":"https://github.com/afkcodes.png","language":"TypeScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Sunoh API 🎵\n\n## About\n\nThis backend API is specifically built for **Sunoh Music App**, available at [www.sunoh.online](https://www.sunoh.online).\n\nSunoh is a music streaming platform that provides access to songs from multiple music sources with comprehensive search and streaming capabilities.\n\n\u003e **Note**: This repository is tailored for Sunoh's specific requirements. While the code is open source, major modifications or feature requests will only be considered if they align with Sunoh Music's roadmap and needs.\n\n## Features\n\n- 🎼 **Multi-source Music API**: Integration with various music streaming services\n- 🎤 **Lyrics Support**: Comprehensive lyrics search and fetch capabilities\n- 🔴 **Live Music**: WebSocket support for real-time music streaming\n- 🖼️ **Image Proxy**: Optimized image serving\n- ⚡ **Fast Performance**: Built with Fastify for high performance\n- 🚀 **Serverless Ready**: Optimized for Vercel deployment\n\n## API Endpoints\n\n### Music Services\n\n- `/music/*` - Music streaming API endpoints\n- `/lyrics/*` - Lyrics search and retrieval\n\n### Core Features\n\n- `/play` - Music playback endpoints\n- `/proxy` - Image proxy service\n- `/live/*` - WebSocket live music features\n\n## Installation \u0026 Setup\n\n### Prerequisites\n\n- Node.js \u003e= 18.12\n- npm or yarn package manager\n\n### Environment Setup\n\n1. **Clone the repository**\n\n   ```bash\n   git clone https://github.com/afkcodes/sunoh-api.git\n   cd sunoh-api\n   ```\n\n2. **Install dependencies**\n\n   ```bash\n   npm install\n   ```\n\n3. **Environment Configuration**\n\n   Create environment files for different stages:\n\n   ```bash\n   # Development environment\n   cp .env.development.example .env.development\n\n   # Production environment\n   cp .env.production.example .env.production\n   ```\n\n   Configure the following environment variables:\n\n   ```env\n   # Music Service Integration\n   LYRICS_TOKEN=your_music_service_bearer_token\n   MEDIA_USER_TOKEN=your_music_service_media_user_token\n\n   # Optional: Redis/Valkey for caching\n   VALKEY_URL=redis://localhost:6379\n   ```\n\n### Development\n\n```bash\n# Run development server with auto-reload\nnpm run dev\n\n# Run with Vercel CLI for serverless testing\nnpm run start:vercel\n```\n\nThe API will be available at `http://localhost:3000`\n\n### Production Build\n\n```bash\n# Build for production\nnpm run build:release\n\n# Start production server\nnpm start\n```\n\n### Deployment\n\n#### Vercel (Recommended)\n\n```bash\n# Deploy to development/staging\nnpm run deploy:dev\n\n# Deploy to production\nnpm run deploy:prod\n```\n\n## Code Quality\n\n```bash\n# Lint code\nnpm run lint\n\n# Format code\nnpm run format\n\n# Clean build artifacts\nnpm run clean\n```\n\n## API Usage Examples\n\n### Search and Get Lyrics\n\n```bash\n# Search for a song and get lyrics\nGET /lyrics/Shape%20of%20You\n\n# With optional parameters\nGET /lyrics/Despacito?storefront=us\u0026format=lrc\u0026language=en-IN\n```\n\n### Music Search\n\n```bash\nGET /music/search?query=Popular%20hits\n```\n\n### Get Song Details\n\n```bash\nGET /music/song/songId\n```\n\n## Tech Stack\n\n- **Framework**: Fastify\n- **Language**: TypeScript\n- **Deployment**: Vercel Serverless\n- **Code Quality**: Biome (linting \u0026 formatting)\n- **Process Management**: Nodemon (development)\n\n## Contributing\n\nThis project is primarily maintained for Sunoh Music App. If you have suggestions or improvements that would benefit Sunoh Music specifically, please:\n\n1. Open an issue describing the enhancement\n2. Ensure it aligns with Sunoh's music goals\n3. Submit a pull request with clear documentation\n\n## License\n\nMIT License - See [LICENSE](LICENSE) file for details.\n\n## Support\n\nFor Sunoh Music App related queries, visit [www.sunoh.online](https://www.sunoh.online)\n\nFor technical issues with this API, please open a GitHub issue.\n\n---\n\n**Built with ❤️ for Sunoh Music** 🎵\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fafkcodes%2Fsunoh-api","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fafkcodes%2Fsunoh-api","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fafkcodes%2Fsunoh-api/lists"}