A REST API built with Laravel for a Point of Sale system. This API provides endpoints for managing sales, inventory, staff, and more with role-based access control.
- Laravel 11
- Laravel Sanctum (Authentication)
- User registration with automatic superadmin role
- Login with token generation
- Protected routes with token authentication
- User profile retrieval
- Logout functionality
- Create categories
- List all categories
- Update category details
- Delete categories
- Get single category
- Add new products
- List all products
- Update product details
- Delete products
- Stock management
- Product search
- Get single product
- Create new sale
- List all sales
- Get sale details
- Refund management
- Sales reports
- Daily/weekly/monthly statistics
- Add staff members
- List all staff
- Update staff details
- Remove staff
- Role assignment
- Staff permissions
- Store details
- Tax configurations
- Receipt customization
- General preferences
The API implements role-based access control with the following roles:
- Superadmin (Full access)
- Admin (Store management)
- Cashier (Sales and basic inventory)
- Staff (Limited access)