EC.Spotify 1.1.1

dotnet add package EC.Spotify --version 1.1.1
                    
NuGet\Install-Package EC.Spotify -Version 1.1.1
                    
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="EC.Spotify" Version="1.1.1" />
                    
For projects that support PackageReference, copy this XML node into the project file to reference the package.
<PackageVersion Include="EC.Spotify" Version="1.1.1" />
                    
Directory.Packages.props
<PackageReference Include="EC.Spotify" />
                    
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 EC.Spotify --version 1.1.1
                    
#r "nuget: EC.Spotify, 1.1.1"
                    
#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 EC.Spotify@1.1.1
                    
#: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=EC.Spotify&version=1.1.1
                    
Install as a Cake Addin
#tool nuget:?package=EC.Spotify&version=1.1.1
                    
Install as a Cake Tool

EC.Spotify

Build And Test Pack And Publish NuGet Version NuGet Downloads

A comprehensive .NET client library for the Spotify Web API, providing strongly-typed access to albums, artists, tracks, playlists, playback control, library management, and more.

Full documentation is available in the Wiki.

Latest News - 2026.04.25

Version 1.1.1 - Deployment

Had to rework IPlaylist and had some bad test track data causing testing errors. Had some stuff come up so i am a week behind on my deployment. If you have any feedback or issues, please let me know. Thanks for using EC.Spotify!

Installation

Package Manager Console

Install-Package EC.Spotify

.NET CLI

dotnet add package EC.Spotify

Configuration

Register EC.Spotify in your IServiceCollection using either a configuration delegate or an IConfiguration section. See the Getting Started wiki page for full setup instructions.

builder.Services.AddSpotify(options =>
{
    options.ClientId = "your-client-id";
    options.ClientSecret = "your-client-secret";
    options.RedirectUri = "https://localhost:5001/callback";
    options.Scopes = ["user-read-playback-state", "user-library-read"];
});

ISpotifyClient

Inject ISpotifyClient to access all services:

Property Service Wiki
Albums IAlbumService Albums
Artists IArtistService Artists
Audiobooks IAudiobookService Audiobooks
Authorization IAuthorizationService Authorization
Chapters IChapterService Chapters
Episodes IEpisodeService Episodes
Library ILibraryService Library
Player IPlayerService Player
Playlists IPlaylistService Playlists
Search ISearchService Search
Shows IShowService Shows
Tracks ITrackService Tracks
User IUserService User

Error Handling

All service methods return SpotifyResult<T>:

  • IsSuccesstrue when the request succeeded
  • Data — the result data (populated on success)
  • Error — a SpotifyError with Status, Message, and Reason (populated on failure)
var result = await _spotifyClient.Albums.AlbumGetAsync(albumId);
if (result.IsSuccess)
    Console.WriteLine(result.Data.Name);
else
    Console.WriteLine($"{result.Error?.Status}: {result.Error?.Message}");

Requirements

  • .NET 10
  • Valid Spotify Developer credentials (Get them here)
  • Valid Spotify Premium account for playback control features

License

This project is licensed under the MIT License. See the LICENSE file for details.

Contributing

Bring issues to the table, or suggest features! Contributions are welcome and appreciated.

Support

For issues, questions, or contributions, please visit the GitHub repository.

Acknowledgments

Built for people who enjoy their Spotify Premium account and want to interact with its API features. Great appreciation for the Spotify development team!

Product Compatible and additional computed target framework versions.
.NET net10.0 is compatible.  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. 
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.1.1 95 4/25/2026
1.1.0 103 4/5/2026
1.0.5 109 3/28/2026
1.0.4 98 3/20/2026
1.0.3 112 3/14/2026