I'm looking for the best way to control the access to different parts of my API. The api is being called via federated identities which get temporary credentials (STS) that map to a specific IAM role. This ensures that only logged in users can call the API which is great. However, I would like to control access for example for user management related API endpoints in a more fine grained way. Currently I use lambda functions and a dynamo db table to achieve this, but it seems tedious to drag the authorization part in every lambda function or even only create the lambda function for this purpose. I have looked into custom authorizers but was not able to find documentation on how to validate the STS token in there and actually I would like to avoid dealing with it.
So is there an elegant way of per resource / method authorization while still using AWS_IAM as authorizer for the authentication?