Unable to find the controller for path \"/api/token/refresh\". The route is wrongly configured.
mlcpro opened this issue · 2 comments
mlcpro commented
Hello in Symfony 6 it seems that the controller is not supported with the /api... route can you update the bundle please
jewome62 commented
No problem in symfony 6 and 7 with that in routes.yaml
api_refresh_token:
path: /api/token/refresh
noxerlito commented
I had the same issue and I found a solution by not using the route name in the check_path, use the path directly instead
firewalls:
api:
pattern: ^/api
stateless: true
entry_point: jwt
json_login:
check_path: /api/login # or, if you have defined a route for your login path, the route name you used
success_handler: lexik_jwt_authentication.handler.authentication_success
failure_handler: lexik_jwt_authentication.handler.authentication_failure
jwt: ~
refresh_jwt:
check_path: /api/token/refresh