Skip to content

Repository files navigation

Addresses Crud

API Endpoints


Authentication

Body Payload Verb
Register /api/auth/register name, email, password, password_confirmation POST
Login /api/auth/login email, password POST
Logout /api/auth/logout token POST
Refresh /api/auth/refresh token POST

Addresses

Endpoint Body Verb
Index /api/addresses token, ?per_page GET
Show /api/addresses/{id} token GET
Store /api/addresses token, cep, house_number, reference_point POST
Update /api/addresses/{id} token, ?fields to be updated PUT
Destroy /api/addresses/{id} token DELETE

Downloading and setting up the project

(Are you in a hurry? Run the installation script with: ./install.sh)

  1. Clone project:
$ git clone https://github.com/henri1i/address-api.git
$ cd address-api
  1. Install dependencies:
$ composer install
  1. Setting up env
$ cp .env.example .env
  1. Start the application
$ sail up -d
  1. Generate env variables
$ php artisan key:generate
$ php artisan jwt:secret
  1. Run the migrations
$ sail php artisan migrate
$ sail php artisan db:seed #Just if you want to run the seeders

Enjoy!

http://localhost:80/

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

Packages

Contributors

Languages