/routes/api.php
https://bitbucket.org/ErickJoaquin/pruebainformatik · PHP · 18 lines · 5 code · 3 blank · 10 comment · 0 complexity · 6f9c7fe6968b8f2d0198a78b9ab271d6 MD5 · raw file
- <?php
- use Illuminate\Http\Request;
- /*
- |--------------------------------------------------------------------------
- | API Routes
- |--------------------------------------------------------------------------
- |
- | Here is where you can register API routes for your application. These
- | routes are loaded by the RouteServiceProvider within a group which
- | is assigned the "api" middleware group. Enjoy building your API!
- |
- */
- Route::middleware('auth:api')->get('/user', function (Request $request) {
- return $request->user();
- });