I've recently started looking into creating dashboards and analysis with the Quicksight API. I tried creating a datasource using the AWS SDK, the response was successful and I was also able to double-check this by calling a describe on the datasourceId. However, when I logged in to quicksight GUI it doesn't show in the list of datasources, can someone explain why this is happening.
I think that's a permission issue.
This was resolved if I add permissions when creating data sets and data sources.
const input: CreateDataSourceCommandInput = {
    ...
    Permissions: [
      {
        Actions: [
          'quicksight:DescribeDataSource',
          'quicksight:DescribeDataSourcePermissions',
          'quicksight:PassDataSource',
        ],
        Principal: 'USER_ARN',
      },
    ],
    ...
  }
To retrieve USER_ARN, refer to this guide: https://docs.aws.amazon.com/solutions/latest/discovering-hot-topics-using-machine-learning/quicksight-principal-arn.html
API document: https://docs.aws.amazon.com/quicksight/latest/APIReference/API_CreateDataSource.html#QS-CreateDataSource-request-Permissions
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With