Skip to content

Latest commit

 

History

History
71 lines (54 loc) · 3.32 KB

README.md

File metadata and controls

71 lines (54 loc) · 3.32 KB

JSON API .Net Core

Build status Travis NuGet MyGet CI 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.

Examples

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.

Models

public class Article : Identifiable
{ 
    [Attr("name")]
    public string Name { get; set; }
}

Controllers

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

Middleware

public class Startup 
{
    public IServiceProvider ConfigureServices(IServiceCollection services) {
        services.AddJsonApi<AppDbContext>();
        // ...
    }

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

Development Priorities

The current priorities for future development (in order):

  1. Operations Support (#150)
  2. Minor features (#105, #144, #162)
  3. Resource to Entity Mapping (#112)

If you're interested in working on any of the above features, take a look at the Contributing Guide or hop on the project Gitter for more direct communication.