all the tutorial video/blog i looked into do exactly the same thing, after they sett up the api gateway and cognito userpool, they try to test there endpoint in api gateway and they ofcourse get
message "Unauthorized"
becuase they need to token, they login in in hosted ui and copy the jwt token “MANUALY” btw, and it works, all the turtorial do this. i dont want to copy the jwt token and past it everytime i am calling the api gateway endpoint
i want api gateway to redirect me hosted UI, i asume there is no way of doing this, if there is someone who knows this please help.
what i did
- step 1 create HTTP API
- step 2 added Integration target (my https resource server url)
- step 3 created authorizer (JWT) and added Issuer URL (cognito Issuer URL)/ Audience (clientid)
- final step added Authorization to my endpoints
now when i go to url invoke /emails or /something
message "Unauthorized"
i read and watch videos like this “https://www.youtube.com/watch?v=o7OHogUcRmI”, “https://www.youtube.com/watch?v=oFSU6rhFETk&t=1016s” and more