Your First CRUD API

30 minutes BEGINNER

Build your first REST API with Create, Read, Update, and Delete operations. Learn the fundamentals of GEMVC 4-layer architecture step by step.

What You'll Learn

API Service Layer

Create URL endpoints and validate requests

Controller Layer

Orchestrate business logic

Model & Table Layers

Handle data logic and database operations

Video Coming Soon...

Understanding the 4-Layer Architecture

GEMVC uses a clean 4-layer architecture pattern. Each layer has a specific responsibility, and requests flow from top to bottom:

API Layer
Controller Layer
Model Layer
Table Layer

Follow the guides below to learn how to create each layer and build a complete CRUD API.

Request Flow Example

Here's how a request flows through all 4 layers:

1
API Service
POST /api/User/create → Validates schema → Calls Controller
2
Controller
Maps POST data to Model → Calls Model method
3
Model
Validates business rules → Transforms data → Calls Table
4
Table
Executes database query → Returns data → Response flows back up

🚀 Ready to Build Your First API?

Start with the API Service layer and work your way down through Controller, Model, and Table. Follow each guide to build a complete CRUD API!