
f12fi (f12fi) asked a question.
I'm on a trial account with Okta and trying to get a token from an app under the Authorization type grant.
it works well via Postman but I need to do the same from Node-red flows.
I see 400 Bad request The authorization code is invalid or has expired
not sure, what should I add to the Resource field. tried the full URL of my org in Okta, like https://org-trial-9637904.okta.com
Please let me know if any additional info is needed

@f12fi (f12fi) -- Looks like you just have the read scope. Which means it isn't going to generate a refresh token. So once the Access Token expires no new one is going to be generated.
I would add a second scope offline_access to account for that.
https://developer.okta.com/docs/api/oauth2/
Thank you for your reply, Tim
i added the offline_access scope but the error message didn't change - 400 Bad Request
added also openid scope
I can do Token Preview with openid, users.read
with Postman I'm using only users.read scope and it gives me a token