TCDev.APIGenerator.Data 0.6.0-RC1

.NET 6.0
This is a prerelease version of TCDev.APIGenerator.Data.
There is a newer version of this package available.
See the version list below for details.
NuGet\Install-Package TCDev.APIGenerator.Data -Version 0.6.0-RC1
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.
dotnet add package TCDev.APIGenerator.Data --version 0.6.0-RC1
<PackageReference Include="TCDev.APIGenerator.Data" Version="0.6.0-RC1" />
For projects that support PackageReference, copy this XML node into the project file to reference the package.
paket add TCDev.APIGenerator.Data --version 0.6.0-RC1
#r "nuget: TCDev.APIGenerator.Data, 0.6.0-RC1"
#r directive can be used in F# Interactive, C# scripting and .NET Interactive. Copy this into the interactive tool or source code of the script to reference the package.
// Install TCDev.APIGenerator.Data as a Cake Addin
#addin nuget:?package=TCDev.APIGenerator.Data&version=0.6.0-RC1&prerelease

// Install TCDev.APIGenerator.Data as a Cake Tool
#tool nuget:?package=TCDev.APIGenerator.Data&version=0.6.0-RC1&prerelease

image Getting Started | Samples | Walkthrough Video

Turn your models into fully working APIs in minutes

<a href=""><img src=""></a> <a href=""><img src=""></a> <a href=""><img src="" /> </a>

Build & Nuget Status

Version Build Nuget
Main <img src=""> 0.1.3 Build Status Installer pipeline
VNext <img src=""> 0.1.2-alpha-6ffff


The API Generator automatically generates a fully working CRUD Microservice from just your Model (C# Classes) or a JSON Definition. Everything from routes, database handling, migrations, openapi spec, OData etc is working magically out of the box! You just write your model and get a fully working CRUD api with filtering, sorting, selectable fields and everything else OData and classic REST offers.

By using the API Generator, this little code snippet is already a working CRUD API

/// <summary>
/// This is the minimal sample, yes this is a working api ;)
/// </summary>
public class MinimalSample : IObjectBase<int>
  public int Id { get; set; }
  public string Name { get; set; }
  public int Value { get; set; }

Heres another sample:

 [Api("/people", ApiMethodsToGenerate.All )]
 public class Person : Trackable, 
    IBeforeUpdate<Person>, // Before Update Hook
    IBeforeDelete<Person>, // BeforeDelete Hook
    public string Name { get; set; }
    public DateTime Date { get; set; }
    public string Description { get; set; }
    public int Age { get; set; }
    public Guid Id { get; set; }

And this is also the FULL code for a working API using the JSON mode:

      "name": "Car",
      "route": "/cars",
      "caching": true,
      "cacheLiveTime": 1000,
      "events": "POST,PUT,DELETE",
      "idType":  "int", 
      "Fields": [
          "name": "Name",
          "type": "String",
          "maxLength": "200",
          "nullable": false

Getting Started & Docoumentation

Read this for a more detailed guide → Or just follow these steps:

  • Install the package
dotnet add package TCDev.ApiGenerator --prerelease

after the package is installed add this to your program.cs (or startup.cs)

// Add API Generator and load data
builder.Services.AddApiGeneratorServices(builder.Configuration, Assembly.GetExecutingAssembly());

Documentation →


Product Versions
.NET net6.0 net6.0-android net6.0-ios net6.0-maccatalyst net6.0-macos net6.0-tvos net6.0-windows
Compatible target framework(s)
Additional computed target framework(s)
Learn more about Target Frameworks and .NET Standard.

NuGet packages (1)

Showing the top 1 NuGet packages that depend on TCDev.APIGenerator.Data:

Package Downloads

Creates fully working CRUD Apis from just models

GitHub repositories

This package is not used by any popular GitHub repositories.

Version Downloads Last updated
0.7.0-RC1 62 7/25/2022
0.6.0 162 6/24/2022
0.6.0-RC2 66 6/24/2022
0.6.0-RC1 60 6/24/2022