---
title: "POST /accounts/{AwsAccountId}/data-sets"
method: POST
path: "/accounts/{AwsAccountId}/data-sets"
---

# POST /accounts/{AwsAccountId}/data-sets

`POST /accounts/{AwsAccountId}/data-sets`

Creates a dataset. This operation doesn't support datasets that include uploaded files as a source.

## Path parameters

- `AwsAccountId` string, required

## Request body

- object
  - `DataSetId` string, required — An ID for the dataset that you want to create. This ID is unique per Amazon Web Services Region for each Amazon Web Services account.
  - `Name` string, required — The display name for the dataset.
  - `PhysicalTableMap` object, required — Declares the physical tables that are available in the underlying data sources.
  - `LogicalTableMap` object — Configures the combination and transformation of the data from the physical tables.
  - `ImportMode` 'SPICE' | 'DIRECT_QUERY', required — Indicates whether you want to import the data into SPICE.
  - `ColumnGroups` ColumnGroup[] — Groupings of columns that work together in certain Amazon QuickSight features. Currently, only geospatial hierarchy is supported.
    - `GeoSpatialColumnGroup` object — Geospatial column group that denotes a hierarchy.
      - `Name` string, required — A display name for the hierarchy.
      - `CountryCode` 'US' — Country code.
      - `Columns` ColumnName[], required — Columns in this hierarchy.
  - `FieldFolders` object — The folder that contains fields and nested subfolders for your dataset.
  - `Permissions` ResourcePermission[] — A list of resource permissions on the dataset.
    - `Principal` string, required — <p>The Amazon Resource Name (ARN) of the principal. This can be one of the following:</p> <ul> <li> <p>The ARN of an Amazon QuickSight user or group associated with a data source or dataset. (This is common.)</p> </li> <li> <p>The ARN of an Amazon QuickSight user, group, or namespace associated with an analysis, dashboard, template, or theme. (This is common.)</p> </li> <li> <p>The ARN of an Amazon Web Services account root: This is an IAM ARN rather than a QuickSight ARN. Use this option only to share resources (templates) across Amazon Web Services accounts. (This is less common.) </p> </li> </ul>
    - `Actions` String[], required — The IAM action to grant or revoke permissions on.
  - `RowLevelPermissionDataSet` object — <p>Information about a dataset that contains permissions for row-level security (RLS). The permissions dataset maps fields to users or groups. For more information, see <a href="https://docs.aws.amazon.com/quicksight/latest/user/restrict-access-to-a-data-set-using-row-level-security.html">Using Row-Level Security (RLS) to Restrict Access to a Dataset</a> in the <i>Amazon QuickSight User Guide</i>.</p> <p>The option to deny permissions by setting <code>PermissionPolicy</code> to <code>DENY_ACCESS</code> is not supported for new RLS datasets.</p>
    - `Namespace` string — The namespace associated with the dataset that contains permissions for RLS.
    - `Arn` string — The Amazon Resource Name (ARN) of the dataset that contains permissions for RLS.
    - `PermissionPolicy` 'GRANT_ACCESS' | 'DENY_ACCESS' — The type of permissions to use when interpreting the permissions for RLS. <code>DENY_ACCESS</code> is included for backward compatibility only.
    - `FormatVersion` 'VERSION_1' | 'VERSION_2' — <p>The user or group rules associated with the dataset that contains permissions for RLS.</p> <p>By default, <code>FormatVersion</code> is <code>VERSION_1</code>. When <code>FormatVersion</code> is <code>VERSION_1</code>, <code>UserName</code> and <code>GroupName</code> are required. When <code>FormatVersion</code> is <code>VERSION_2</code>, <code>UserARN</code> and <code>GroupARN</code> are required, and <code>Namespace</code> must not exist.</p>
    - `Status` 'ENABLED' | 'DISABLED' — The status of the row-level security permission dataset. If enabled, the status is <code>ENABLED</code>. If disabled, the status is <code>DISABLED</code>.
  - `RowLevelPermissionTagConfiguration` object — The configuration of tags on a dataset to set row-level security.
    - `Status` 'ENABLED' | 'DISABLED' — The status of row-level security tags. If enabled, the status is <code>ENABLED</code>. If disabled, the status is <code>DISABLED</code>.
    - `TagRules` RowLevelPermissionTagRule[] — A set of rules associated with row-level security, such as the tag names and columns that they are assigned to.
      - `TagKey` string, required — The unique key for a tag.
      - `ColumnName` string, required — The column name that a tag key is assigned to.
      - `TagMultiValueDelimiter` string — A string that you want to use to delimit the values when you pass the values at run time. For example, you can delimit the values with a comma.
      - `MatchAllValue` string, password — A string that you want to use to filter by all the values in a column in the dataset and don’t want to list the values one by one. For example, you can use an asterisk as your match all value.
    - `TagRuleConfigurations` RowLevelPermissionTagRuleConfiguration[] — A list of tag configuration rules to apply to a dataset. All tag configurations have the OR condition. Tags within each tile will be joined (AND). At least one rule in this structure must have all tag values assigned to it to apply Row-level security (RLS) to the dataset.
      - SessionTagKey[]
  - `ColumnLevelPermissionRules` ColumnLevelPermissionRule[] — A set of one or more definitions of a <code> <a href="https://docs.aws.amazon.com/quicksight/latest/APIReference/API_ColumnLevelPermissionRule.html">ColumnLevelPermissionRule</a> </code>.
    - `Principals` String[] — An array of Amazon Resource Names (ARNs) for Amazon QuickSight users or groups.
    - `ColumnNames` String[] — An array of column names.
  - `Tags` Tag[] — Contains a map of the key-value pairs for the resource tag or tags assigned to the dataset.
    - `Key` string, required — Tag key.
    - `Value` string, required — Tag value.
  - `DataSetUsageConfiguration` object — The usage configuration to apply to child datasets that reference this dataset as a source.
    - `DisableUseAsDirectQuerySource` boolean — An option that controls whether a child dataset of a direct query can use this dataset as a source.
    - `DisableUseAsImportedSource` boolean — An option that controls whether a child dataset that's stored in QuickSight can use this dataset as a source.

## Response `200`

Success

- CreateDataSetResponse
  - `Arn` string — The Amazon Resource Name (ARN) of the dataset.
  - `DataSetId` string — The ID for the dataset that you want to create. This ID is unique per Amazon Web Services Region for each Amazon Web Services account.
  - `IngestionArn` string — The ARN for the ingestion, which is triggered as a result of dataset creation if the import mode is SPICE.
  - `IngestionId` string — The ID of the ingestion, which is triggered as a result of dataset creation if the import mode is SPICE.
  - `RequestId` string — The Amazon Web Services request ID for this operation.
  - `Status` integer — The HTTP status of the request.

## Other responses

- `480` — AccessDeniedException
- `481` — ConflictException
- `482` — InvalidParameterValueException
- `483` — LimitExceededException
- `484` — ResourceExistsException
- `485` — ResourceNotFoundException
- `486` — ThrottlingException
- `487` — UnsupportedUserEditionException
- `488` — InternalFailureException

---

[API](https://skmtc.net/aws/apis/quicksight.md) · [All operations](https://skmtc.net/aws/apis/quicksight/llms.txt) · [OpenAPI document](https://skmtc-service-staging.skmtc.workers.dev/v1/apis/aws/quicksight/versions/2f2bbd7e70ca/schema)
