JSONAPI Framework for ASP.Net Core
milosloub Merge pull request #458 from milosloub/feat/#406
Feat(#406): Allow filter[id] and filter[related.id]
Latest commit c633c71 Dec 11, 2018


JSON API .Net Core

Build status Travis NuGet Join the chat at https://gitter.im/json-api-dotnet-core/Lobby FIRST-TIMERS

A framework for building json:api compliant web APIs. The ultimate goal of this library is to eliminate as much boilerplate as possible by offering out-of-the-box features such as sorting, filtering and pagination. You just need to focus on defining the resources and implementing your custom business logic. This library has been designed around dependency injection making extensibility incredibly easy.

Getting Started

These are some steps you can take to help you understand what this project is and how you can use it:

Related Projects


See the examples directory for up-to-date sample applications. There is also a Todo List App that includes a JADNC API and an EmberJs client.

Installation And Usage

See the documentation for detailed usage.


public class Article : Identifiable
    public string Name { get; set; }


public class ArticlesController : JsonApiController<Article>
    public ArticlesController(
        IJsonApiContext jsonApiContext,
        IResourceService<Article> resourceService) 
    : base(jsonApiContext, resourceService) { }


public class Startup 
    public IServiceProvider ConfigureServices(IServiceCollection services) {
        // ...

    public void Configure(IApplicationBuilder app)  {
        // ...


Restore all nuget packages with:

dotnet restore


Running tests locally requires access to a postgresql database.
If you have docker installed, this can be propped up via:

docker run --rm --name jsonapi-dotnet-core-testing \
  -e POSTGRES_DB=JsonApiDotNetCoreExample \
  -e POSTGRES_USER=postgres \
  -e POSTGRES_PASSWORD=postgres \
  -p 5432:5432 \

And then to run the tests:

dotnet test


Sometimes the compiled files can be dirty / corrupt from other branches / failed builds.

dotnet clean