ClearBowl/api/routes/api.php

14 lines
439 B
PHP

<?php
use Illuminate\Support\Facades\Route;
Route::group(['prefix' => 'user', 'middleware' => ['assign.guard:users']], function () {
Route::post('/register', 'UsersController@register');
Route::post('/login', 'UsersController@login');
Route::get('/me', 'UsersController@me');
});
Route::group(['prefix' => 'product', 'middleware' => ['assign.guard:users']], function () {
Route::post('/', 'ProductsController@add');
});