This simple demo codebase explains how you can integrate IdP capabilities into your website using LightSAML.
For a detailed walkthrough see https://medium.com/prosple-engineering/how-to-turn-your-php-website-into-a-saml-identity-provider-in-30-minutes-896c44724581
To generate meta data
SP : https://sptest.iamshowcase.com/
IDP : https://samltest.id/
Other Study Materials
https://imbringingsyntaxback.com/implementing-a-saml-idp-with-laravel/
https://github.com/codegreencreative/laravel-samlidp