Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/malldonado/api-restaurante
🥕 Restaurant API for RPG: Manage your virtual tavern seamlessly with AdonisJS 5 and TypeScript, complete with table management functionalities. Utilizing SQLite3 for development and MySQL for production, with TDD options for robust testing capabilities.
https://github.com/malldonado/api-restaurante
adonisjs5 api-rest mysql sqlite3 tdd typescript
Last synced: about 1 month ago
JSON representation
🥕 Restaurant API for RPG: Manage your virtual tavern seamlessly with AdonisJS 5 and TypeScript, complete with table management functionalities. Utilizing SQLite3 for development and MySQL for production, with TDD options for robust testing capabilities.
- Host: GitHub
- URL: https://github.com/malldonado/api-restaurante
- Owner: malldonado
- Created: 2024-05-03T23:07:40.000Z (9 months ago)
- Default Branch: main
- Last Pushed: 2024-07-19T10:36:08.000Z (7 months ago)
- Last Synced: 2024-11-08T10:20:21.684Z (3 months ago)
- Topics: adonisjs5, api-rest, mysql, sqlite3, tdd, typescript
- Language: TypeScript
- Homepage:
- Size: 159 KB
- Stars: 1
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# 🥕 Restaurant API
## Overview
Welcome to the Restaurant API This API allows you to manage your virtual tavern seamlessly with AdonisJS 5 and TypeScript, featuring robust table management functionalities. For development, we utilize SQLite3, while MySQL is used for production. Additionally, the API is designed with Test-Driven Development (TDD) options to ensure reliable and maintainable code.
## Features
- **Table Management:** Manage tables, reservations, and seating arrangements effortlessly.
- **TypeScript:** Enjoy type safety and modern JavaScript features.
- **AdonisJS 5:** Leverage the power of AdonisJS, a fully-featured Node.js framework.
- **SQLite3 for Development:** Lightweight and easy-to-use database for local development.
- **MySQL for Production:** Reliable and scalable database solution for production.
- **TDD:** Implement Test-Driven Development for robust testing capabilities.## Tech Stack
- **Languages:** TypeScript
- **Framework:** AdonisJS 5
- **Databases:** SQLite3 (development), MySQL (production)
- **Testing:** TDD## Getting Started
### Prerequisites
- Node.js
- npm or yarn
- SQLite3 (for development)
- MySQL (for production)### Installation
1. **Clone the repository:**
```bash
git clone https://github.com/malldonado/api-restaurante.git
cd api-restaurante/roleplay-api
```2. **Install dependencies:**
```bash
npm install
# or
yarn install
```3. **Set up the environment variables:**
Create a `.env` file in the root directory and add the following variables:
```env
NODE_ENV=development
APP_KEY=your_app_key
DB_CONNECTION=sqlite
SQLITE_FILENAME=./db.sqlite3
MYSQL_HOST=127.0.0.1
MYSQL_PORT=3306
MYSQL_USER=root
MYSQL_PASSWORD=your_mysql_password
MYSQL_DB_NAME=restaurant
```4. **Run migrations:**
```bash
node ace migration:run
```### Running the Development Server
Start the AdonisJS development server:
```bash
npm run dev
# or
yarn dev
```## Starting the Server
The server will start on http://localhost:3333.
## Testing
To run tests, use the following command:
```bash
npm run test
# or
yarn test
```# License
This project is licensed under the MIT License. See the LICENSE file for details.
# Acknowledgements
- AdonisJS
- TypeScript
- SQLite
- MySQLThis README.md provides a comprehensive overview of the API, including instructions for installation, configuration, execution, and testing, as well as details about the functionalities and the technological stack used in the project.