A starter package to use it with Vue Lumen Starter.
- Clone the repository:
git clone https://github.com/tareq1988/lumen-starter.git
- Copy
.env.example
as.env
file and set the Database credentials - Set approprite
APP_URL
. In case using with Vue Lumen Starter, set it to the Vue App URL. - Install Dependencies:
composer install
- Run migration:
php artisan migrate
- Run Seeder:
php artisan db:seed
Done!
View contents
Send Authorization bearer token to send authenticated requestAuthorization: bearer <API_TOKEN>
View contents
[POST /register]
Params:
- `first_name` (string) - Users first name
- `last_name` (string) - The last name
- `email` (string) - The user email
- `password` (string) - The password
- `password_confirmation` (string) - The confirmation password
Response Code:
- ✅ 201: On registration success
- ❌ 422: On validation failure
View contents
[POST /login]
Params:
- `email` (string) - The user email
- `password` (string) - The password
Response Code:
- ✅ 200: On login success
- ❌ 401: On failure
View contents
[GET /me]
Response Code:
- ✅ 200: On success
- ❌ 401: On failure
View contents
[POST /me]
Params:
- `first_name` (string) - Users first name
- `last_name` (string) - The last name
Response Code:
- ✅ 200: On login success
- ❌ 422: On validation failure
View contents
[POST /me/password]
Params:
- `current` (string) - The current password
- `password` (string) - New password
- `password_confirmation` (string) - The new confirmation password
Response Code:
- ✅ 200: On success
- ❌ 422: On validation failure
View contents
[POST /password/request]
Params:
- `email` (string) - The email
Response Code:
- ✅ 200: On success
- ❌ 422: On validation failure
View contents
[POST /password/reset]
Params:
- `email` (string) - The email
- `token` (string) - The forgot password token
- `password` (string) - New password
- `password_confirmation` (string) - The new confirmation password
Response Code:
- ✅ 200: On success
- ❌ 422: On validation failure