Laravel - 登录时返回用户和身份验证详细信息

时间:2018-02-17 10:56:11

标签: php json laravel api

我是Laravel的新手,我正在尝试使用Passport身份验证进行登录调用。该调用返回用户身份验证详细信息:

warning: An error occurred while preparing SDK package Google Repository: Cannot download 'https://dl.google.com/android/repository/google_m2repository_gms_v11_3_rc05_wear_2_0_5.zip': Tag mismatch!

但我也想在同一回复中获取用户详细信息:

{
    "token_type": "Bearer",
    "expires_in": 600,
    "access_token": "...",
    "refresh_token": "..."
}

这可能吗?这是我的控制器代码:

 {
    "user_id": "1",
    "forename": "Mustafa",
    "surname": "Tortelini",
    "email": "mustafaaaa@gmail.com"
     ...
    "access_token": "...",
    "refresh_token": "..."
}

0 个答案:

没有答案