Laravel is a web application framework with expressive, elegant syntax. We believe development must be an enjoyable and creative experience to be truly fulfilling. Laravel takes the pain out of development by easing common tasks used in many web projects, such as:
- Simple, fast routing engine.
- Powerful dependency injection container.
- Multiple back-ends for session and cache storage.
- Expressive, intuitive database ORM.
- Database agnostic schema migrations.
- Robust background job processing.
- Real-time event broadcasting.
Laravel is accessible, powerful, and provides tools required for large, robust applications.
A backend system for a vending machine built with Laravel. This application manages drink options, user orders, and integrates with vending machine hardware via APIs.
- Menu with four drinks: Tea, Karak, Masala, and Nescafe.
- Configurable sweetness level for drinks.
- Generates unique random codes for each order.
- API to validate codes and update order statuses.
- Receipt generation with download functionality.
- PHP 8.1 or higher
- Composer
- MySQL
- Node.js (for frontend assets, if needed)
-
Clone the repository:
git clone https://github.com/do11ir/CoffeeVendingMachine-IOT cd vending-backend -
Install dependencies:
composer install
-
Set up the .env file:
cp .env.example .env
-
Generate the application key:
php artisan key:generate Run migrations:
-
Run migrations:
php artisan migrate
| Endpoint | Method | Description |
|---|---|---|
/api/validate-code |
POST | Validates order random codes. |
- Fork the repository.
- Create a new branch:
git checkout -b feature-name
- Commit your changes:
git commit -m "Add feature-name" Push to the branch: - Push to the branch:
git push origin feature-name Open a pull request.
- Open a pull request.
This project is open-source and available under the MIT License.