amazon-quicksight-embedding-sample
amazon-quicksight-embedding-sample copied to clipboard
GetDashboardEmbedURL is not authorized to perform: quicksight:GetAuthCode
I am using Quicksight Authentication (Identity Type: QUICKSIGHT) and used the CF stacks to build the components. I also updaloded the lambda code as suggested. However, while I try to test the same from API gateway it gives me error saying -
arn:aws:sts::xxxxxxxxxxxx:assumed-role/QuicksightEmbedStack-LambdaExecutionRole-5Z4UVE5XMDBG/GetDashboardEmbedURL is not authorized to perform: quicksight:GetAuthCode on resource: arn:aws:quicksight:region:xxxxxxxxxxxxxxx:user/default/username
at Object.extractError (/var/task/node_modules/aws-sdk/lib/protocol/json.js:51:27)
at Request.extractError (/var/task/node_modules/aws-sdk/lib/protocol/rest_json.js:55:8)
at Request.callListeners (/var/task/node_modules/aws-sdk/lib/sequential_executor.js:106:20)
at Request.emit (/var/task/node_modules/aws-sdk/lib/sequential_executor.js:78:10)
at Request.emit (/var/task/node_modules/aws-sdk/lib/request.js:683:14)
at Request.transition (/var/task/node_modules/aws-sdk/lib/request.js:22:10)
at AcceptorStateMachine.runTo (/var/task/node_modules/aws-sdk/lib/state_machine.js:14:12)
at /var/task/node_modules/aws-sdk/lib/state_machine.js:26:10
at Request.
Looking into the error it seems that the Lambda function does not have a the permission to perform quicksight:GetAuthcode on the quicksight user. But, I see from the policy attached to the lambda role clearly mentions about the quicksight:GetAuthCode (created through CF stack). I am not sure what exactly am I missing here. I am stuck at this point and any help is much appreciated.
Thanks