{"id":23254886,"url":"https://github.com/vwkyc/lyriclocate","last_synced_at":"2026-02-24T01:04:45.089Z","repository":{"id":265347178,"uuid":"895817972","full_name":"vwkyc/lyriclocate","owner":"vwkyc","description":"lyrics fetch. deprecated.","archived":false,"fork":false,"pushed_at":"2025-02-21T21:33:27.000Z","size":172,"stargazers_count":3,"open_issues_count":0,"forks_count":1,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-10-27T06:33:35.634Z","etag":null,"topics":["api","fastapi","genius","genius-api","lyrics","lyrics-scraping","lyricsgenius","music","musixmatch","python","spotify"],"latest_commit_sha":null,"homepage":"","language":"Python","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"gpl-3.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/vwkyc.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,"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":"2024-11-29T01:11:19.000Z","updated_at":"2025-08-19T12:52:52.000Z","dependencies_parsed_at":null,"dependency_job_id":"bd7328c1-f8a6-4331-8cc8-08b918a19e40","html_url":"https://github.com/vwkyc/lyriclocate","commit_stats":null,"previous_names":["vwkyc/lyriclocate"],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/vwkyc/lyriclocate","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/vwkyc%2Flyriclocate","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/vwkyc%2Flyriclocate/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/vwkyc%2Flyriclocate/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/vwkyc%2Flyriclocate/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/vwkyc","download_url":"https://codeload.github.com/vwkyc/lyriclocate/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/vwkyc%2Flyriclocate/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":29765740,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-02-23T21:02:23.375Z","status":"ssl_error","status_checked_at":"2026-02-23T20:58:31.539Z","response_time":90,"last_error":"SSL_connect returned=1 errno=0 peeraddr=140.82.121.6:443 state=error: 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":["api","fastapi","genius","genius-api","lyrics","lyrics-scraping","lyricsgenius","music","musixmatch","python","spotify"],"created_at":"2024-12-19T11:17:46.474Z","updated_at":"2026-02-24T01:04:45.061Z","avatar_url":"https://github.com/vwkyc.png","language":"Python","funding_links":[],"categories":[],"sub_categories":[],"readme":"# LyricLocate Lyrics API\n\n[![Python 3.8+](https://img.shields.io/badge/python-3.8+-blue.svg)](https://www.python.org/downloads/)\n[![FastAPI](https://img.shields.io/badge/FastAPI-0.68.0+-green.svg)](https://fastapi.tiangolo.com)\n[![Better Stack Badge](https://uptime.betterstack.com/status-badges/v1/monitor/1oypl.svg)](https://vwkyc.betteruptime.com/)\n\nThis project is a FastAPI-based service that fetches song lyrics from the web. It combines multiple sources including Genius API, Spotify, Musixmatch, and Google search to find and scrape lyrics. The lyrics are cached in a local SQLite database to improve performance and reduce redundant requests.\n\n## Features\n\n- Fetch lyrics for a given song title and artist\n- Fetch lyrics directly from Spotify track URLs\n- Works with or without Genius API key (falls back to web scraping)\n- Smart caching system using SQLite database\n- Multiple lyrics sources (Genius API, Spotify, Musixmatch, Google Search)\n- Support for different languages, including English translations\n- Automatic alternate language lyrics detection and caching\n- Modern web frontend\n\n## Installation\n\n1. Clone the repository:\n   ```sh\n   git clone https://github.com/vwkyc/lyriclocate.git\n   cd lyriclocate\n   ```\n\n2. Create a virtual environment and activate it:\n   ```sh\n   python -m venv venv\n   venv\\Scripts\\activate  # On Windows\n   source venv/bin/activate  # On Unix/MacOS\n   ```\n\n3. Install the required packages:\n   ```sh\n   pip install -r requirements.txt\n   ```\n\n4. Set up environment variables:\n   Create a `.env` file in the project root:\n   ```env\n   GENIUS_CLIENT_ACCESS_TOKEN=your_genius_api_key\n   SPOTIFY_CLIENT_ID=your_spotify_client_id\n   SPOTIFY_CLIENT_SECRET=your_spotify_client_secret\n   ```\n   Note: The service can work without API keys by using web scraping methods.\n\n## Usage\n\n1. Start the server:\n   ```sh\n   cd src \u0026\u0026 python main.py\n   ```\n\n2. Access the service:\n   - Web Interface: [http://localhost:19999](http://localhost:19999)\n   - API Endpoints: \n     ```sh\n     # Using title and artist\n     curl -X GET \"http://localhost:19999/api/get_lyrics?title=Sleepless\u0026artist=deadmau5\"\n     \n     # Using Spotify URL\n     curl -X GET \"http://localhost:19999/api/get_lyrics_from_spotify?spotify_url=https://open.spotify.com/track/781KGu6ckiXdOYmgkzRJ42\"\n     ```\n\n## API Endpoints\n\n### GET /api/get_lyrics\nFetch lyrics using song title and artist.\n\n**Query Parameters:**\n- `title` (required): Song title\n- `artist` (required): Artist name\n- `language` (optional): Target language code (e.g., 'en' for English)\n\n### GET /api/get_lyrics_from_spotify\nFetch lyrics using a Spotify track URL.\n\n**Query Parameters:**\n- `spotify_url` (required): Full Spotify track URL\n- `language` (optional): Target language code (e.g., 'en' for English)\n\n**Responses:**\n- `200 OK`: Returns lyrics JSON object\n- `404 Not Found`: Lyrics not found\n\n## Database Structure\n\nThe SQLite database (`lyriclocate/cache/lyrics.db`) uses the following schemas:\n\n```sql\nCREATE TABLE IF NOT EXISTS lyrics (\n    id INTEGER PRIMARY KEY AUTOINCREMENT,\n    cache_key TEXT UNIQUE,\n    title TEXT,\n    artist TEXT,\n    language TEXT,\n    lyrics TEXT,\n    timestamp DATETIME,\n    UNIQUE(title, artist, language)\n);\n\nCREATE TABLE IF NOT EXISTS spotify_cache (\n    id INTEGER PRIMARY KEY AUTOINCREMENT,\n    spotify_url TEXT UNIQUE,\n    title TEXT,\n    artist TEXT,\n    timestamp DATETIME\n);\n```\n\n## Environment Variables\n\n- `GENIUS_CLIENT_ACCESS_TOKEN`: (Optional) Your Genius API key\n- `SPOTIFY_CLIENT_ID`: (Optional) Your Spotify API client ID\n- `SPOTIFY_CLIENT_SECRET`: (Optional) Your Spotify API client secret\n\nThe service will use web scraping as a fallback if API keys are not provided.\n\n## Development\n\nRun in development mode with auto-reload:\n```sh\nuvicorn main:app --reload --host 0.0.0.0 --port 19999\n```\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fvwkyc%2Flyriclocate","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fvwkyc%2Flyriclocate","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fvwkyc%2Flyriclocate/lists"}