loopback4-starter
loopback4-starter copied to clipboard
Can't use Oauth2 resource owner login way
Describe the bug
Can't connect via auth/login-token
I have add my user's id in user_id column of auth_clients table (and save it) but i still get this error :
{
"error": {
"statusCode": 401,
"name": "UnauthorizedError",
"message": "Bearer realm=\"Users\""
}
}
The request body: (with the same body i can get the code with
{
"client_id": "webapp",
"client_secret": "saqw21!@",
"username": "super_admin",
"password": "test123!@#"
}
Hi @filol , This error denotes that 'Bearer' is not attached to the token (which is being sent in the headers in the key 'Authorization'). But for this particular api, this should not be the case. This api does not expect any token. Can you share the changes that you might have made in the api?
@mayank-SFIN571 i have just update deps (why they are so out of date ?) and activate the db migration tool of lb (the native one)
@mayank-SFIN571 can u please check which dependency is not up to date ?
https://github.com/sourcefuse/loopback4-starter/pull/65 might resolve this issue. @filol can you please check ?
@filol can you please confirm if it is okay to close this issue?