How to use the quicksight api / aws cli to create the default role aws-quicksight-service-role-v0

I am creating some resources to work with QS and I need to give permissions to those services to this role, but after I signup to Quicksight using a Lambda function, this role ’ aws-quicksight-service-role-v0’ gets created only after you manually add the resources. how can i automate this process.

Hello @Tanaya
When setting up Quick Sight, you have the option to choose between using a Quick Sight-managed role (the default) or an existing IAM role. However since you are using lambda functions to sign up, I assume you are creating Quick Sight account though → CreateAccountSubscription API

As documented in [+] create-account-subscription — AWS CLI 2.31.10 Command Reference

You can’t pass an existing IAM role to access other Amazon Web Services services using this API operation. To pass your existing IAM role to Amazon Quick Sight, see Passing IAM roles to Amazon Quick Sight in the Amazon Quick Sight User Guide .

So there are no API calls which we can leverage to automate the process

1 Like