The Parking App API is a Laravel-based RESTful API that provides endpoints for managing parking-related operations. It serves as the backend for a parking app, allowing users to perform actions such as booking parking slots, checking availability, and retrieving parking information.
The API is designed to be efficient, scalable, and secure, providing a seamless experience for both the app users and administrators. It follows industry best practices and includes unit tests to ensure the reliability and stability of the codebase.
To get the Parking App API up and running on your local machine, follow these steps:
-
Clone the repository:
git clone https://github.com/your-username/parking-app-api.git
-
Navigate to the project directory:
cd parking-app-api
-
Install the dependencies using Composer:
composer install
-
Create a copy of the
.env.example
file and rename it to.env
. Update the necessary environment variables, such as the database configuration. -
Generate an application key:
php artisan key:generate
-
Run the database migrations:
php artisan migrate
-
Optionally, you can seed the database with sample data:
php artisan db:seed
-
Start the development server:
php artisan serve
To generate the API documentation, you can use the Scribe package. Follow the steps below to generate and view the documentation:
-
Ensure that you have the necessary dependencies installed. Run composer install, if haven't yet.
-
Once the dependencies are installed, you can generate the documentation by running the following command:
php artisan scribe:generate
-
By default, the documentation files are stored in the
public/docs
directory. However, to prevent the documentation files from being committed to the repository, thedocs
folder is included in the.gitignore
file. This is done to avoid duplicating the documentation when you have multiple instances of the project. To access the generated documentation, you can run the project and navigate to the/docs
endpoint in your browser. For example, if you're running the project locally, the URL would behttp://localhost:8000/docs
. Note: Remember to generate the documentation whenever there are changes to your API endpoints or their documentation.
This project is licensed under the MIT License. Feel free to use and modify it as per the terms of the license.