SimpMusic.Lyrics.Client 1.2.0

dotnet add package SimpMusic.Lyrics.Client --version 1.2.0
                    
NuGet\Install-Package SimpMusic.Lyrics.Client -Version 1.2.0
                    
This command is intended to be used within the Package Manager Console in Visual Studio, as it uses the NuGet module's version of Install-Package.
<PackageReference Include="SimpMusic.Lyrics.Client" Version="1.2.0" />
                    
For projects that support PackageReference, copy this XML node into the project file to reference the package.
<PackageVersion Include="SimpMusic.Lyrics.Client" Version="1.2.0" />
                    
Directory.Packages.props
<PackageReference Include="SimpMusic.Lyrics.Client" />
                    
Project file
For projects that support Central Package Management (CPM), copy this XML node into the solution Directory.Packages.props file to version the package.
paket add SimpMusic.Lyrics.Client --version 1.2.0
                    
#r "nuget: SimpMusic.Lyrics.Client, 1.2.0"
                    
#r directive can be used in F# Interactive and Polyglot Notebooks. Copy this into the interactive tool or source code of the script to reference the package.
#:package SimpMusic.Lyrics.Client@1.2.0
                    
#:package directive can be used in C# file-based apps starting in .NET 10 preview 4. Copy this into a .cs file before any lines of code to reference the package.
#addin nuget:?package=SimpMusic.Lyrics.Client&version=1.2.0
                    
Install as a Cake Addin
#tool nuget:?package=SimpMusic.Lyrics.Client&version=1.2.0
                    
Install as a Cake Tool

SimpMusic.Lyrics.Client

A .NET client library for the SimpMusic Lyrics API. Provides easy access to lyrics and translations for songs.

Features

  • 🎵 Get lyrics by YouTube video ID
  • 🌍 Support for translated lyrics in multiple languages
  • 🔍 Search lyrics by title, artist, or query
  • ⬆️ Submit new lyrics and translations (requires HMAC authentication)
  • 👍 Vote for lyrics and translations
  • ⚡ Fully async/await support
  • 📦 .NET Standard 2.0 compatible

Installation

Install via NuGet:

dotnet add package SimpMusic.Lyrics.Client

Or via Package Manager:

Install-Package SimpMusic.Lyrics.Client

Quick Start

using SimpMusic.Lyrics.Client.Api;
using SimpMusic.Lyrics.Client.Model;

// Create API instance
var api = new LyricsApi();

// Get lyrics by video ID
// Note: The API returns lyrics in a wrapper format with a data array
// The client automatically extracts the first item for GetLyricsByVideoIdAsync
var lyrics = await api.GetLyricsByVideoIdAsync("Y9SmNz2RofI");

if (lyrics != null && !string.IsNullOrWhiteSpace(lyrics.PlainLyric))
{
    Console.WriteLine($"Song: {lyrics.SongTitle}");
    Console.WriteLine($"Artist: {lyrics.ArtistName}");
    Console.WriteLine($"Lyrics:\n{lyrics.PlainLyric}");
}
else
{
    Console.WriteLine("No lyrics found for this video.");
}

// Search for lyrics
var searchApi = new SearchApi();
var searchResults = await searchApi.SearchLyricsAsync("demons", limit: 5);

if (searchResults != null && searchResults.Data != null && searchResults.Data.Count > 0)
{
    Console.WriteLine($"Found {searchResults.Data.Count} results:");
    foreach (var result in searchResults.Data)
    {
        Console.WriteLine($"- {result.SongTitle} by {result.ArtistName}");
    }
}

Rate Limiting

The API enforces rate limiting:

  • 30 requests per minute per IP address
  • Rate limit headers are included in all responses:
    • X-RateLimit-Limit: Maximum requests allowed
    • X-RateLimit-Remaining: Remaining requests in current window
    • X-RateLimit-Reset: Unix timestamp when limit resets
  • When exceeded, returns HTTP 429 with Retry-After header

API Endpoints

Lyrics

  • GetLyricsByVideoIdAsync(videoId, limit?, offset?) - Get lyrics by YouTube video ID
    • Note: The API returns lyrics in a wrapper format {"type": "success", "data": [{...}], "success": true}. The client automatically extracts the first item from the data array.
  • CreateLyricAsync(body) - Create new lyric (requires HMAC auth)

Translations

  • GetTranslatedLyricsByVideoIdAsync(videoId) - Get all translations for a video
    • Returns TranslatedLyricsListResponse with Data array containing all translations
  • GetTranslatedLyricsByVideoIdAndLanguageAsync(videoId, language) - Get translation in specific language
    • Returns TranslatedLyricsListResponse with Data array
  • CreateTranslatedLyricAsync(body) - Create new translation (requires HMAC auth)
  • SearchLyricsAsync(query, limit?, offset?) - Search lyrics by query
    • Returns LyricsListResponse with Data array containing search results
  • SearchLyricsByTitleAsync(title, limit?, offset?) - Search by song title
    • Returns LyricsListResponse with Data array
  • SearchLyricsByArtistAsync(artist, limit?, offset?) - Search by artist name
    • Returns LyricsListResponse with Data array

Voting

  • VoteForLyricAsync(body) - Vote for a lyric (requires HMAC auth)
  • VoteForTranslatedLyricAsync(body) - Vote for a translation (requires HMAC auth)

API Response Format

All API endpoints return responses in a wrapper format:

{
  "type": "success",
  "data": [...],
  "success": true
}
  • GetLyricsByVideoIdAsync: Returns a single LyricsResponse (client extracts first item from data array)
  • Search endpoints: Return LyricsListResponse with Data array containing multiple results
  • Translation endpoints: Return TranslatedLyricsListResponse with Data array containing translations

HMAC Authentication

For POST/PUT/DELETE operations, HMAC authentication is required. The client automatically handles HMAC generation when configured:

// Configure HMAC secret (default: "simpmusic-lyrics")
SimpMusic.Lyrics.Client.Configuration.Default.HmacSecretKey = "simpmusic-lyrics";

// Or configure per-instance
var config = new Configuration();
config.HmacSecretKey = "simpmusic-lyrics";
var api = new LyricsApi(config);

// The client automatically generates X-Timestamp and X-HMAC headers
// for all POST/PUT/DELETE/PATCH requests when HmacSecretKey is set

The HMAC is generated using:

  • Algorithm: HMAC-SHA256
  • Data: timestamp + request_uri
  • Output: Base64-encoded string
  • Headers: X-Timestamp (Unix timestamp in milliseconds) and X-HMAC (generated token)

Documentation

Full API documentation is available at:

Requirements

  • .NET Standard 2.0 or later
  • RestSharp 111.4.1+
  • Newtonsoft.Json 13.0.1+

License

This library is provided as-is. The SimpMusic Lyrics API is licensed under GPL-3.0.

Contributing

Contributions are welcome! Please feel free to submit a Pull Request.

Product Compatible and additional computed target framework versions.
.NET net5.0 was computed.  net5.0-windows was computed.  net6.0 was computed.  net6.0-android was computed.  net6.0-ios was computed.  net6.0-maccatalyst was computed.  net6.0-macos was computed.  net6.0-tvos was computed.  net6.0-windows was computed.  net7.0 was computed.  net7.0-android was computed.  net7.0-ios was computed.  net7.0-maccatalyst was computed.  net7.0-macos was computed.  net7.0-tvos was computed.  net7.0-windows was computed.  net8.0 was computed.  net8.0-android was computed.  net8.0-browser was computed.  net8.0-ios was computed.  net8.0-maccatalyst was computed.  net8.0-macos was computed.  net8.0-tvos was computed.  net8.0-windows was computed.  net9.0 was computed.  net9.0-android was computed.  net9.0-browser was computed.  net9.0-ios was computed.  net9.0-maccatalyst was computed.  net9.0-macos was computed.  net9.0-tvos was computed.  net9.0-windows was computed.  net10.0 was computed.  net10.0-android was computed.  net10.0-browser was computed.  net10.0-ios was computed.  net10.0-maccatalyst was computed.  net10.0-macos was computed.  net10.0-tvos was computed.  net10.0-windows was computed. 
.NET Core netcoreapp2.0 was computed.  netcoreapp2.1 was computed.  netcoreapp2.2 was computed.  netcoreapp3.0 was computed.  netcoreapp3.1 was computed. 
.NET Standard netstandard2.0 is compatible.  netstandard2.1 was computed. 
.NET Framework net461 was computed.  net462 was computed.  net463 was computed.  net47 was computed.  net471 was computed.  net472 was computed.  net48 was computed.  net481 was computed. 
MonoAndroid monoandroid was computed. 
MonoMac monomac was computed. 
MonoTouch monotouch was computed. 
Tizen tizen40 was computed.  tizen60 was computed. 
Xamarin.iOS xamarinios was computed. 
Xamarin.Mac xamarinmac was computed. 
Xamarin.TVOS xamarintvos was computed. 
Xamarin.WatchOS xamarinwatchos was computed. 
Compatible target framework(s)
Included target framework(s) (in package)
Learn more about Target Frameworks and .NET Standard.

NuGet packages

This package is not used by any NuGet packages.

GitHub repositories

This package is not used by any popular GitHub repositories.

Version Downloads Last Updated
1.2.0 118 2/1/2026
1.1.0 100 2/1/2026
1.0.1 107 2/1/2026
1.0.0 104 2/1/2026