DEV Community

Discussion on: Get started with FastAPI JWT authentication – Part 2

Collapse
 
hy86592 profile image
hy86592

Great tutorial. Thank you. I just have one issue: I cloned your code and ran the app. I get an error:

File "./main.py", line 36, in login
access_token = auth_handler.encode_token(user['key'])

"TypeError: Expected a string value"

Collapse
 
hy86592 profile image
hy86592

Nevermind, this was because I did not set the APP_SECRET_STRING value.