Home

Awesome

RickAndMorty.Net.Api

alt text

.NET client for Rick And Morty knowledge base api: https://rickandmortyapi.com/

Get from nuget

https://www.nuget.org/packages/RickAndMorty.Net.Api/

Package Manager:
Install-Package RickAndMorty.Net.Api

.NET CLI
dotnet add package RickAndMorty.Net.Api

Usage

Get service from factory class:

var service = RickAndMortyApiFactory.Create();
var result = service.GetCharacter(5);

Or register DI module (for now AutoFac only):

builder.RegisterModule(new RickAndMortyModule());

To get service interface:

public class A
{
  public A(IRickAndMortyService service)
  { 
  }
}

Methods

Service contains all methods availible from api https://rickandmortyapi.com/documentation