GeniusLyricsAPI 1.0.0
dotnet add package GeniusLyricsAPI --version 1.0.0
NuGet\Install-Package GeniusLyricsAPI -Version 1.0.0
<PackageReference Include="GeniusLyricsAPI" Version="1.0.0" />
paket add GeniusLyricsAPI --version 1.0.0
#r "nuget: GeniusLyricsAPI, 1.0.0"
// Install GeniusLyricsAPI as a Cake Addin #addin nuget:?package=GeniusLyricsAPI&version=1.0.0 // Install GeniusLyricsAPI as a Cake Tool #tool nuget:?package=GeniusLyricsAPI&version=1.0.0
GeniusLyricsAPI
GeniusLyricsAPI is a library that can find information about a track and try to extract the lyrics from the genius website
Features
- Gets track info
- Search some track in Genius
- Gets track's lyrics
- Gets album's cover link
Install a package
Open a command line and switch to the directory that contains your project file.
Use the following command to install a NuGet package:
dotnet add package GeniusLyricsAPI
After the command completes, you can open the project file to see the package reference.
For example, open the .csproj file to see the added
GeniusLyricsAPI
package reference:<ItemGroup> <PackageReference Include="GeniusLyricsAPI" Version="1.0.0" /> </ItemGroup>
Usage
using GeniusLyricsAPI;
using GeniusLyricsApi.Models;
public class Program
{
static void Main(string[] args)
{
try
{
new Program().Run().Wait();
}
catch (AggregateException ex)
{
foreach (var e in ex.InnerExceptions)
{
Console.WriteLine("Error: " + e.Message);
}
}
}
private async Task Run()
{
var genius = new GeniusApi("REPLACE_ME_GeniusToken");
Song song = await genius.GetSong("8594139");
string Lyrics = await genius.GetLyrics(song.Uri);
Console.Write(Lyrics);
}
}
Contributing
Pull requests are welcome. For major changes, please open an issue first to discuss what you would like to change.
Please make sure to update tests as appropriate.
Thanks
Thank you very much farshed for writing a similar library for JavaScript. If it wasn't for the genius-lyrics-api, I wouldn't have come up with the idea of rewriting it in C# and wouldn't have written a bot for Telegram 😄
License
Product | Versions Compatible and additional computed target framework versions. |
---|---|
.NET | net7.0 is compatible. 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. |
-
net7.0
- HtmlAgilityPack (>= 1.11.52)
- Newtonsoft.Json (>= 13.0.3)
- System.Net.Http.Json (>= 7.0.1)
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.0.0 | 209 | 8/31/2023 |