awswrangler.quicksight.create_athena_data_source

awswrangler.quicksight.create_athena_data_source(name: str, workgroup: str = 'primary', allowed_to_use: Optional[List[str]] = None, allowed_to_manage: Optional[List[str]] = None, tags: Optional[Dict[str, str]] = None, account_id: Optional[str] = None, boto3_session: Optional[boto3.session.Session] = None, namespace: str = 'default')None

Create a QuickSight data source pointing to an Athena/Workgroup.

Note

You will not be able to see the the data source in the console if you not pass your user to one of the allowed_* arguments.

Parameters
  • name (str) – Data source name.

  • workgroup (str) – Athena workgroup.

  • tags (Dict[str, str], optional) – Key/Value collection to put on the Cluster. e.g. {“foo”: “boo”, “bar”: “xoo”})

  • allowed_to_use (optional) – List of principals that will be allowed to see and use the data source. e.g. [“John”]

  • allowed_to_manage (optional) – List of principals that will be allowed to see, use, update and delete the data source. e.g. [“Mary”]

  • account_id (str, optional) – If None, the account ID will be inferred from your boto3 session.

  • boto3_session (boto3.Session(), optional) – Boto3 Session. The default boto3 session will be used if boto3_session receive None.

  • namespace (str) – The namespace. Currently, you should set this to default.

Returns

None.

Return type

None

Examples

>>> import awswrangler as wr
>>> wr.quicksight.create_athena_data_source(
...     name="...",
...     allowed_to_manage=["john"]
... )