Slim 4 Tutorial


Thanks @odan, this looks like it will be very useful for those of us just transitioning to Slim!

1 Like

thanks daniel for this, helped me a lot in understanding whats going on behind the scenes.

is there a way to convince you to add a use case with jwt authentication to this tutorial?

1 Like

Hi @stefanvz Thank you :slight_smile:

That’s a good idea. I think I write a new blog post about OAuth 2.0 in combination with JWT.


Nice looking forward to it.

I wrote a tutorial on how to create and validate JWT with public/private keys using lcobucci/jwt. The tutorial also shows how to convert the token into an OAuh 2.0 Access Token Response. You can also reuse or implement your custom user authentication. You can protect single routes and/or route groups via JwtMiddleware. Read more:

If you just have static secret key, you may also try tuupola/slim-jwt-auth instead.

1 Like

thanks Daniel. good addition to your tutorial and helped me to make my solution more robust.

1 Like