Inkloom API is a .NET 9 Web API for a blogging platform with user authentication, blog management, tagging, and asset handling. It is designed for extensibility and secure, modern web development.
- User registration, login (including SSO and magic link), and profile management
- Blog CRUD operations with support for images and rich content
- Tagging system for blogs
- Asset management (upload, serve, and manage images/files)
- Email verification and password reset
- JWT-based authentication and authorization
- Swagger/OpenAPI documentation
- Dockerized for easy deployment
Inkloom.Api- Main API project (controllers, services, DTOs, middlewares)Inkloom.Api.Data- Entity Framework Core data models and migrationsInkloom.Api.Assets- Asset and file managementInkloom.Api.Email- Email sending and SMTP integrationInkloom.Api.EmailTemplates- Email template renderingInkloom.Api.Test- xUnit test project
- .NET 9 SDK
- Docker (for local development)
Copy Inkloom.Api/appsettings.Example.json to appsettings.Development.json and fill in the required values (database, JWT, SMTP, etc).
cp Inkloom.Api/appsettings.Example.json Inkloom.Api/appsettings.Development.jsonStart the API and PostgreSQL database using Docker Compose:
docker-compose up --buildThe API will be available at http://localhost:8080.
- Ensure PostgreSQL is running and update the connection string in your appsettings.
- Run database migrations (optional, handled automatically if
MigrateDatabaseis true):dotnet ef database update --project Inkloom.Api.Data --startup-project Inkloom.Api
- Start the API:
dotnet run --project Inkloom.Api
Once running, Swagger UI is available at http://localhost:8080/swagger (in development mode).
POST /auth/register- Register a new userPOST /auth/login- Login with email/passwordPOST /auth/magic-login- Magic link loginPOST /auth/sso-login- SSO login (Google, etc.)GET /user- Get current user profilePATCH /user- Update user profilePATCH /user/change-password- Change passwordPOST /user/verify-email- Email verificationDELETE /user- Delete userGET /blog/public- List public blogsGET /blog/following- List blogs from followed usersGET /blog/{id}- Get blog by IDPOST /blog- Create blogPATCH /blog/{id}- Update blogDELETE /blog/{id}- Delete blogGET /tag- Search tagsGET /asset/{assetId}- Get asset (image/file)
Run tests with:
dotnet test Inkloom.Api.Test- ASP.NET Core 9
- Entity Framework Core 9
- AutoMapper
- Swashbuckle (Swagger)
- Npgsql (PostgreSQL)
- MailKit (SMTP)
- xUnit (testing)