MangaDexSharp 1.0.14

.NET Standard 2.1
dotnet add package MangaDexSharp --version 1.0.14
NuGet\Install-Package MangaDexSharp -Version 1.0.14
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="MangaDexSharp" Version="1.0.14" />
For projects that support PackageReference, copy this XML node into the project file to reference the package.
paket add MangaDexSharp --version 1.0.14
#r "nuget: MangaDexSharp, 1.0.14"
#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.
// Install MangaDexSharp as a Cake Addin
#addin nuget:?package=MangaDexSharp&version=1.0.14

// Install MangaDexSharp as a Cake Tool
#tool nuget:?package=MangaDexSharp&version=1.0.14


A C# API for


You can install the nuget package with Visual Studio. It targets .net standard 2.1 to take advantage of most of the new features within C# and .net.

PM> Install-Package MangaDexSharp


You can either use it directly or via dependency injection (for use with core).

Depdency Injection:

using MangaDexSharp;

var builder = WebApplication.CreateBuilder(args);


//This will find the authentication token in your configuration file (appsettings.json) under: "MangaDex:Token"
//Or, if you want to inject the token directly you can use this (You don't need both of these.):
builder.Services.AddMangaDex("<AUTH TOKEN HERE>");

var app = builder.Build();

Then you can inject the API into any of your controllers or other services:

using MangaDexSharp;
using Microsoft.AspNetCore.Mvc;

namespace SomeApplication;

public class SomeController : ControllerBase
    private readonly IMangaDex _md;

    public SomeController(IMangaDex md)
        _md = md;

    [HttpGet, Route("manga/{id}")]
    public async Task<IActionResult> Get(string id)
        return Ok(await _md.Manga.Get(id));


using MangaDexSharp;

//You cannot access authed routes if you use this option.
var api = MangaDex.Create();

//However, you can specify the token like so:
var api = MangaDex.Create("<AUTH TOKEN HERE>");

var manga = await api.Manga.Get("some-manga-id-here");


The API follows the docs pretty closely. With the root object for the api being the IMangaDex interface. Once you have an instance (see above), you can access any of the sub-sections within it. Here are some common use cases:

var api = MangaDex.Create();

//Fetching a manga by manga ID:
var manga = await api.Manga.Get("fc0a7b86-992e-4126-b30f-ca04811979bf");

//Searching for a manga via it's title:
var results = await api.Manga.List(new MangaFilter 
    Title = "The Unrivaled Mememori-kun"

//Get all of the chapters from a manga by manga ID:
var chapters = await api.Manga.Feed("fc0a7b86-992e-4126-b30f-ca04811979bf");

//Fetch a chapter by chapter ID:
var chapter = await api.Chapter.Get("2c98fbe9-a63f-47c2-9862-ecc9199610a2");

//Get all of the pages of a specific chapter by chapter ID:
var pages = await api.Pages.Pages("2c98fbe9-a63f-47c2-9862-ecc9199610a2");


MangaDex switched to authorization bearer tokens via an OAuth2 flow recently. In order to access any resources that require an account, you will need to get one of those tokens (you can read more here once they update the docs). Once you have a bearer token, you can either add it at an API level or for a specific request, you can also create your own token service provider.

Note: You can see an example of how to fetch bearer tokens for the new OAuth2 flow in the src/MangaDexSharp.OAuthLocal.Web project.

Legacy Authentication method:

You can use the legacy login method to fetch the session token like so:

var api = MangaDex.Create();

var result = await api.User.Login("<username>", "<password>");

var token = result.Data.Session;

//You can either pass the token into authenticated routes
var me = await api.User.Me(token);

//Or you can create an authenticated api
var authedApi = MangaDex.Create(token);
var me = await authedApi.User.Me();

Note: These methods are technically deprecated on mangadex's docs, so they are marked as [Obsolete] and will show up as warnings.

API Level:

You have 2 primary options for using this, you can either specify it directly when you create a client or inject it via configuration.

//You can apply it directly like this:
var api = MangaDex.Create("<AUTH TOKEN HERE>");

//Or if you're using dependency injection, you can provide it here:
builder.Services.AddMangaDex("<AUTH TOKEN HERE>");

//Or you can include it in your appsettings.json (or environment variables):
//And then add a "MangaDex:Token": "<AUTH TOKEN HERE>" to your environment variables.
//Note: you can change the name of the environment variable by setting doing this:
MangaDexSharp.ConfigurationCredentialsService.TokenPath = "SomeEnvironmentVariableName";

Alternatively, you can create your own ICredentialsService implementation and then add it via dependency injection:

using MangaDexSharp;

//This has access to your services if you're using Dependency Injection.
public class MyCustomCredentialsService : ICredentialsService
    public async Task<string> GetToken() 
        return "Some-token resolved here";
//Then add your service like so:

Specific Request

Any request that requires authentication within the API has a string? token = null parameter on the method. The API will default to using this parameter if it's set.

var api = MangaDex.Create();

//Follow a manga
await api.Manga.Follow("fc0a7b86-992e-4126-b30f-ca04811979bf", "<AUTH TOKEN HERE>");
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. 
.NET Core netcoreapp3.0 was computed.  netcoreapp3.1 was computed. 
.NET Standard netstandard2.1 is compatible. 
MonoAndroid monoandroid was computed. 
MonoMac monomac was computed. 
MonoTouch monotouch was computed. 
Tizen 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)
Additional computed target framework(s)
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.0.14 121 5/14/2023
1.0.13 60 5/1/2023
1.0.12 75 4/26/2023
1.0.11 82 4/26/2023
1.0.10 78 4/26/2023
1.0.9 170 3/30/2023
1.0.8 130 3/24/2023
1.0.7 165 2/21/2023
1.0.6 158 2/15/2023
1.0.5 167 2/10/2023
1.0.4 165 2/10/2023
1.0.3 157 2/10/2023
1.0.2 162 2/10/2023
1.0.1 173 2/10/2023
1.0.0 175 2/10/2023