Skip to content

Instantly share code, notes, and snippets.

@ymhuang0808

ymhuang0808/routes.php

Last active Dec 7, 2015
Embed
What would you like to do?
JWT-Auth for refreshing token
$api = app('Dingo\Api\Routing\Router');
// Version 1.0
$api->version('v1.0', function ($api) {
// ignore other endpoints
/*
|--------------------------------------------------------------------------
| Refresh token endpoint
|--------------------------------------------------------------------------
|
| Refresh a new JWT
|
*/
$api->group(['middleware' => ['jwt.refresh']], function ($api) {
// For refresh token
$api->post('auth/refresh_token', function () { return response(null, 204); });
});
});
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.