Support the ongoing development of Laravel.io →
posted 8 years ago
Authentication

I'm working on user registration in my API using Laravel Passport, and I need to return refresh_token as the response in my API on successful registration. I can only get access token using createToken() from HasApiTokens trait but it does not generate refresh token.

Is there a way to generate refresh token in Laravel Passport?

What I'm doing in my client right now is by submit the registration request, and then submit another login request to get the refresh token. Is this approach right? thanks before

Last updated 3 years ago.
0

Hey.

Have you perhaps figured this out yet. I'm sitting with the exact same issue. Thanks in advance.

0

Sign in to participate in this thread!

Eventy

Your banner here too?

edxz edxz Joined 25 Feb 2017

Moderators

We'd like to thank these amazing companies for supporting us

Your logo here?

Laravel.io

The Laravel portal for problem solving, knowledge sharing and community building.

© 2025 Laravel.io - All rights reserved.