# Unexpected cannot list data sets in the command line interface

**URL:** <https://community.amazonquick.com/t/unexpected-cannot-list-data-sets-in-the-command-line-interface/10325>\
**Category:** Q&A\
**Tags:** qls-cli-automate, quick-sight\
**Created:** [February 22, 2023, 7:04pm UTC](https://community.amazonquick.com/t/unexpected-cannot-list-data-sets-in-the-command-line-interface/10325 "2023-02-22T19:04:33Z")\
**Posts on this page:** 5\
**Page:** 1

<div class="post-metadata">

**Author:** ![jens](https://d2orw1595917va.cloudfront.net/user_avatar/community.amazonquick.com/jens/32/287_2.png) [@jens](https://community.amazonquick.com/u/jens)\
**Post date:** [February 22, 2023, 7:04pm UTC](https://community.amazonquick.com/t/unexpected-cannot-list-data-sets-in-the-command-line-interface/10325/1 "2023-02-22T19:04:33Z")

</div>

i have an admin account on our quicksight instance. i have not used the aws quicksight cli before, but i am now trying to. i am confused about which account id to use: my organisation has a root account and i have an account under that root account. then we have different roles defined, and our quicksight is under a production role that my account can switch to. it has a number of datasets in there, but when i try to list the ids i get an unexpected error:

> ~/\> aws quicksight list-data-sets --aws-account-id   
> An error occurred (AccessDeniedException) when calling the ListDataSets operation: User: arn:aws:iam:::user/is not authorized to access this resource

any suggestions?

---

<div class="post-metadata">

**Author:** ![Ashok](https://d2orw1595917va.cloudfront.net/user_avatar/community.amazonquick.com/ashok/32/3419_2.png) [@Ashok](https://community.amazonquick.com/u/Ashok)\
**Post date:** [February 22, 2023, 7:08pm UTC](https://community.amazonquick.com/t/unexpected-cannot-list-data-sets-in-the-command-line-interface/10325/2 "2023-02-22T19:08:21Z")

</div>

On Quick Sight page, click on user profile icon on top right of the UI and select info.  
This page will show the Quick Sight account name and ID. This is the ID you need to use to execute CLI commands.

 ![image](https://d1wl4jav5dp96l.cloudfront.net/original/2X/d/d240784fd42856fbf46e62db37f69c47a6b97c22.png)

---

<div class="post-metadata">

**Author:** ![Ashok](https://d2orw1595917va.cloudfront.net/user_avatar/community.amazonquick.com/ashok/32/3419_2.png) [@Ashok](https://community.amazonquick.com/u/Ashok)\
**Post date:** [February 22, 2023, 7:09pm UTC](https://community.amazonquick.com/t/unexpected-cannot-list-data-sets-in-the-command-line-interface/10325/3 "2023-02-22T19:09:15Z")

</div>

If you are executing the CLI from local, make sure to configure correct Security and Access keys from your AWS account for programmatic access

---

<div class="post-metadata">

**Author:** ![jens](https://d2orw1595917va.cloudfront.net/user_avatar/community.amazonquick.com/jens/32/287_2.png) [@jens](https://community.amazonquick.com/u/jens)\
**Post date:** [February 22, 2023, 7:30pm UTC](https://community.amazonquick.com/t/unexpected-cannot-list-data-sets-in-the-command-line-interface/10325/4 "2023-02-22T19:30:38Z")

</div>

yes, that is where i got the account id, the id that occurs in the error message is different.

---

<div class="post-metadata">

**Author:** ![jens](https://d2orw1595917va.cloudfront.net/user_avatar/community.amazonquick.com/jens/32/287_2.png) [@jens](https://community.amazonquick.com/u/jens)\
**Post date:** [February 22, 2023, 7:31pm UTC](https://community.amazonquick.com/t/unexpected-cannot-list-data-sets-in-the-command-line-interface/10325/5 "2023-02-22T19:31:33Z")

</div>

> make sure to configure correct Security and Access keys from your AWS account for programmatic access

i think that was the issue. need my admin to help me out here.
