I was going through this https://docs.microsoft.com/en-us/azure/active-directory/develop/active-directory-optional-claims. i have happy that i can get oppremise sid.
Now i also wanted to inlcude the onpremisesameaccount as part of claim.
I know i can get it using graph api https://graph.microsoft.com/v1.0/me/?$select=userPrincipalName,onPremisesSamAccountName
but i wanted to use it as part of claims token generated by azure ad inself.