laravel-vue-spa icon indicating copy to clipboard operation
laravel-vue-spa copied to clipboard

Sanctum Feedback

Open cretueusebiu opened this issue 3 years ago • 4 comments

I want to replace JWT with Sanctum however it's not that straight forward...

Right now with JWT everything is stateless, meaning that you can consume any api routes from anywhere. But moving to Sanctum some api routes don't make sense to be api routes, but rather just web routes (login, logout, ouath, verify email). Because if use the api with a mobile application it would be stateless and would have other api routes for issuing tokens for example.

So the question is do you use the api routes for something more that just the web app ? And does it make sense to keep the api routes with Sanctum ? Or just move everything to use the default session guard ?

cretueusebiu avatar Aug 14 '21 19:08 cretueusebiu

So the question is do you use the api routes for something more that just the web app ?

yes, data import / export with random apps, and initiator may be at random side (my app or another).

ghost avatar Oct 02 '21 10:10 ghost

Is there a branch of your tests about this topic where we can play around and maybe help?

OzanKurt avatar Oct 19 '21 17:10 OzanKurt

Hi, what is the state of this? I think Sanctum is a must if you plan on getting up to date with Laravel 9

unsa-cdn avatar Dec 14 '21 00:12 unsa-cdn

@unsa-cdn Yeah.. I'll replace jwt with Sanctum very soon. I was also thinking to use Breeze maybe ? Since now it supports spa stack.

cretueusebiu avatar Dec 14 '21 09:12 cretueusebiu