Setting up a role for a specific AWS service always needs two pieces done correctly together: a trust policy naming the right service principal, and a permissions policy with at least the minimum actions that service actually needs to do its job. Cross-Service Role Generator scaffolds both halves at once for six common use cases, so you start from a small, named, working shape instead of a blank IAM console form.
Pick a preset — EC2 instance role (either an SSM-managed baseline with no application permissions, or an S3-read example), Lambda execution role, ECS task role, CodeBuild service role, Glue service role, or API Gateway invoking Lambda — and the tool produces the trust policy (always {"Service": "<preset's service principal>"} as Principal, with no stray Resource field) and a starting permissions policy naming a small set of actions specific to that use case: the three CloudWatch Logs actions every Lambda function needs, the Systems Manager channel actions an SSM-managed EC2 instance needs, lambda:InvokeFunction for API Gateway, and so on.
Every preset is intentionally minimal and named for exactly what it grants — this tool does not claim these scaffolds are complete least-privilege policies for your actual workload, because it cannot know what your workload actually does beyond the baseline the AWS service itself requires. An optional Resource field lets you narrow the permissions policy from the default "*" to a specific bucket, function, or other ARN when the preset supports it (for example the S3-read EC2 example, or the API Gateway/Lambda preset).
Both documents are pretty-printed JSON with their own Copy and Download controls. Neither is deployed anywhere by this tool — you still need to create the role and attach both documents yourself, and you should review the generated actions and resources against your actual use case before doing so, since this is a scaffold to start from, not a finished, audited policy.