High-Performance PHP Micro-Framework

Build lightning-fast REST APIs with the elegance of modern frameworks. Zero bloat, maximum flexibility, and exceptional performance.

โšก

Lightning Fast

Optimized routing engine with minimal overhead. Built for speed and efficiency.

๐Ÿ”ง

Zero Dependencies

No external dependencies except Composer. Keep your project lean and fast.

๐ŸŽฏ

Easy to Use

Clean, expressive syntax inspired by FastAPI. Get started in minutes.

๐Ÿ›ก๏ธ

Built-in CORS

Cross-origin resource sharing support out of the box. Ready for production.

๐Ÿ“ก

JSON First

Automatic JSON handling and response formatting. Perfect for modern APIs.

๐Ÿš€

Production Ready

Built with performance and scalability in mind. Deploy with confidence.

๐Ÿงช API Testing

GET
/api/
Welcome message
GET
/api/hello
Hello World endpoint
GET
/api/user/{id}
Dynamic user endpoint
POST
/api/users
Create user endpoint
Checking API status...

๐Ÿ“‹ API Routes Documentation

Complete list of all available API endpoints with HTTP methods and descriptions.

๐Ÿ“‹ GET Endpoints

GET /api/

Welcome Message

Welcome message with API documentation

Test
GET /api/hello

Hello World

Simple greeting endpoint

Test
GET /api/users

Get All Users

Retrieve all users with pagination

Test
GET /api/users/{id}

Get User by ID

Retrieve specific user with detailed profile

Test
GET /api/posts

Get All Posts

Retrieve all posts with metadata

Test
GET /api/posts/{id}

Get Post by ID

Retrieve specific post with comments

Test
GET /api/search/users

Search Users

Search users by name or email

Test
GET /api/health

Health Check

API health status

Test
GET /api/stats

API Statistics

API usage statistics

Test

โž• POST Endpoints

POST /api/users

Create User

Create a new user

POST /api/posts

Create Post

Create a new post

POST /api/auth/login

User Login

Authenticate user and get access token

POST /api/echo

Echo Test

Echo back request data for testing

๐Ÿ”„ PUT Endpoints

PUT /api/users/{id}

Update User

Fully update a user (all fields required)

PUT /api/posts/{id}

Update Post

Fully update a post (all fields required)

๐Ÿ”ง PATCH Endpoints

PATCH /api/users/{id}

Partially Update User

Partially update a user (only provided fields)

PATCH /api/posts/{id}

Partially Update Post

Partially update a post (only provided fields)

๐Ÿ—‘๏ธ DELETE Endpoints

DELETE /api/users/{id}

Delete User

Delete a user

DELETE /api/posts/{id}

Delete Post

Delete a post

โš™๏ธ Configuration Guide

1. Environment Setup
Create config/.env file:
BASE_URL="http://localhost/your-project"
2. Subdirectory Configuration
If running in subdirectory, update .htaccess:
RewriteBase /your-subdirectory/
RewriteCond %{REQUEST_URI} ^/your-subdirectory/api/
3. CORS Configuration
Edit config/cors.php for production:
'allow_all_origins' => false
'allowed_origins' => ['https://yourdomain.com']