2025/03/14 - AWS Lake Formation - 9 updated api methods
Changes This release added "condition" to LakeFormation OptIn APIs, also added WithPrivilegedAccess flag to RegisterResource and DescribeResource.
{'Entries': {'Condition': {'Expression': 'string'}}}Response
{'Failures': {'RequestEntry': {'Condition': {'Expression': 'string'}}}}
Batch operation to grant permissions to the principal.
See also: AWS API Documentation
Request Syntax
client.batch_grant_permissions( CatalogId='string', Entries=[ { 'Id': 'string', 'Principal': { 'DataLakePrincipalIdentifier': 'string' }, 'Resource': { 'Catalog': { 'Id': 'string' }, 'Database': { 'CatalogId': 'string', 'Name': 'string' }, 'Table': { 'CatalogId': 'string', 'DatabaseName': 'string', 'Name': 'string', 'TableWildcard': {} }, 'TableWithColumns': { 'CatalogId': 'string', 'DatabaseName': 'string', 'Name': 'string', 'ColumnNames': [ 'string', ], 'ColumnWildcard': { 'ExcludedColumnNames': [ 'string', ] } }, 'DataLocation': { 'CatalogId': 'string', 'ResourceArn': 'string' }, 'DataCellsFilter': { 'TableCatalogId': 'string', 'DatabaseName': 'string', 'TableName': 'string', 'Name': 'string' }, 'LFTag': { 'CatalogId': 'string', 'TagKey': 'string', 'TagValues': [ 'string', ] }, 'LFTagPolicy': { 'CatalogId': 'string', 'ResourceType': 'DATABASE'|'TABLE', 'Expression': [ { 'TagKey': 'string', 'TagValues': [ 'string', ] }, ], 'ExpressionName': 'string' }, 'LFTagExpression': { 'CatalogId': 'string', 'Name': 'string' } }, 'Permissions': [ 'ALL'|'SELECT'|'ALTER'|'DROP'|'DELETE'|'INSERT'|'DESCRIBE'|'CREATE_DATABASE'|'CREATE_TABLE'|'DATA_LOCATION_ACCESS'|'CREATE_LF_TAG'|'ASSOCIATE'|'GRANT_WITH_LF_TAG_EXPRESSION'|'CREATE_LF_TAG_EXPRESSION'|'CREATE_CATALOG'|'SUPER_USER', ], 'Condition': { 'Expression': 'string' }, 'PermissionsWithGrantOption': [ 'ALL'|'SELECT'|'ALTER'|'DROP'|'DELETE'|'INSERT'|'DESCRIBE'|'CREATE_DATABASE'|'CREATE_TABLE'|'DATA_LOCATION_ACCESS'|'CREATE_LF_TAG'|'ASSOCIATE'|'GRANT_WITH_LF_TAG_EXPRESSION'|'CREATE_LF_TAG_EXPRESSION'|'CREATE_CATALOG'|'SUPER_USER', ] }, ] )
string
The identifier for the Data Catalog. By default, the account ID. The Data Catalog is the persistent metadata store. It contains database definitions, table definitions, and other control information to manage your Lake Formation environment.
list
[REQUIRED]
A list of up to 20 entries for resource permissions to be granted by batch operation to the principal.
(dict) --
A permission to a resource granted by batch operation to the principal.
Id (string) -- [REQUIRED]
A unique identifier for the batch permissions request entry.
Principal (dict) --
The principal to be granted a permission.
DataLakePrincipalIdentifier (string) --
An identifier for the Lake Formation principal.
Resource (dict) --
The resource to which the principal is to be granted a permission.
Catalog (dict) --
The identifier for the Data Catalog. By default, the account ID. The Data Catalog is the persistent metadata store. It contains database definitions, table definitions, and other control information to manage your Lake Formation environment.
Id (string) --
An identifier for the catalog resource.
Database (dict) --
The database for the resource. Unique to the Data Catalog. A database is a set of associated table definitions organized into a logical group. You can Grant and Revoke database permissions to a principal.
CatalogId (string) --
The identifier for the Data Catalog. By default, it is the account ID of the caller.
Name (string) -- [REQUIRED]
The name of the database resource. Unique to the Data Catalog.
Table (dict) --
The table for the resource. A table is a metadata definition that represents your data. You can Grant and Revoke table privileges to a principal.
CatalogId (string) --
The identifier for the Data Catalog. By default, it is the account ID of the caller.
DatabaseName (string) -- [REQUIRED]
The name of the database for the table. Unique to a Data Catalog. A database is a set of associated table definitions organized into a logical group. You can Grant and Revoke database privileges to a principal.
Name (string) --
The name of the table.
TableWildcard (dict) --
A wildcard object representing every table under a database.
At least one of TableResource$Name or TableResource$TableWildcard is required.
TableWithColumns (dict) --
The table with columns for the resource. A principal with permissions to this resource can select metadata from the columns of a table in the Data Catalog and the underlying data in Amazon S3.
CatalogId (string) --
The identifier for the Data Catalog. By default, it is the account ID of the caller.
DatabaseName (string) -- [REQUIRED]
The name of the database for the table with columns resource. Unique to the Data Catalog. A database is a set of associated table definitions organized into a logical group. You can Grant and Revoke database privileges to a principal.
Name (string) -- [REQUIRED]
The name of the table resource. A table is a metadata definition that represents your data. You can Grant and Revoke table privileges to a principal.
ColumnNames (list) --
The list of column names for the table. At least one of ColumnNames or ColumnWildcard is required.
(string) --
ColumnWildcard (dict) --
A wildcard specified by a ColumnWildcard object. At least one of ColumnNames or ColumnWildcard is required.
ExcludedColumnNames (list) --
Excludes column names. Any column with this name will be excluded.
(string) --
DataLocation (dict) --
The location of an Amazon S3 path where permissions are granted or revoked.
CatalogId (string) --
The identifier for the Data Catalog where the location is registered with Lake Formation. By default, it is the account ID of the caller.
ResourceArn (string) -- [REQUIRED]
The Amazon Resource Name (ARN) that uniquely identifies the data location resource.
DataCellsFilter (dict) --
A data cell filter.
TableCatalogId (string) --
The ID of the catalog to which the table belongs.
DatabaseName (string) --
A database in the Glue Data Catalog.
TableName (string) --
The name of the table.
Name (string) --
The name of the data cells filter.
LFTag (dict) --
The LF-tag key and values attached to a resource.
CatalogId (string) --
The identifier for the Data Catalog. By default, the account ID. The Data Catalog is the persistent metadata store. It contains database definitions, table definitions, and other control information to manage your Lake Formation environment.
TagKey (string) -- [REQUIRED]
The key-name for the LF-tag.
TagValues (list) -- [REQUIRED]
A list of possible values an attribute can take.
(string) --
LFTagPolicy (dict) --
A list of LF-tag conditions or saved LF-Tag expressions that define a resource's LF-tag policy.
CatalogId (string) --
The identifier for the Data Catalog. By default, the account ID. The Data Catalog is the persistent metadata store. It contains database definitions, table definitions, and other control information to manage your Lake Formation environment.
ResourceType (string) -- [REQUIRED]
The resource type for which the LF-tag policy applies.
Expression (list) --
A list of LF-tag conditions or a saved expression that apply to the resource's LF-tag policy.
(dict) --
A structure that allows an admin to grant user permissions on certain conditions. For example, granting a role access to all columns that do not have the LF-tag 'PII' in tables that have the LF-tag 'Prod'.
TagKey (string) -- [REQUIRED]
The key-name for the LF-tag.
TagValues (list) -- [REQUIRED]
A list of possible values an attribute can take.
The maximum number of values that can be defined for a LF-Tag is 1000. A single API call supports 50 values. You can use multiple API calls to add more values.
(string) --
ExpressionName (string) --
If provided, permissions are granted to the Data Catalog resources whose assigned LF-Tags match the expression body of the saved expression under the provided ExpressionName.
LFTagExpression (dict) --
LF-Tag expression resource. A logical expression composed of one or more LF-Tag key:value pairs.
CatalogId (string) --
The identifier for the Data Catalog. By default, the account ID.
Name (string) -- [REQUIRED]
The name of the LF-Tag expression to grant permissions on.
Permissions (list) --
The permissions to be granted.
(string) --
Condition (dict) --
A Lake Formation condition, which applies to permissions and opt-ins that contain an expression.
Expression (string) --
An expression written based on the Cedar Policy Language used to match the principal attributes.
PermissionsWithGrantOption (list) --
Indicates if the option to pass permissions is granted.
(string) --
dict
Response Syntax
{ 'Failures': [ { 'RequestEntry': { 'Id': 'string', 'Principal': { 'DataLakePrincipalIdentifier': 'string' }, 'Resource': { 'Catalog': { 'Id': 'string' }, 'Database': { 'CatalogId': 'string', 'Name': 'string' }, 'Table': { 'CatalogId': 'string', 'DatabaseName': 'string', 'Name': 'string', 'TableWildcard': {} }, 'TableWithColumns': { 'CatalogId': 'string', 'DatabaseName': 'string', 'Name': 'string', 'ColumnNames': [ 'string', ], 'ColumnWildcard': { 'ExcludedColumnNames': [ 'string', ] } }, 'DataLocation': { 'CatalogId': 'string', 'ResourceArn': 'string' }, 'DataCellsFilter': { 'TableCatalogId': 'string', 'DatabaseName': 'string', 'TableName': 'string', 'Name': 'string' }, 'LFTag': { 'CatalogId': 'string', 'TagKey': 'string', 'TagValues': [ 'string', ] }, 'LFTagPolicy': { 'CatalogId': 'string', 'ResourceType': 'DATABASE'|'TABLE', 'Expression': [ { 'TagKey': 'string', 'TagValues': [ 'string', ] }, ], 'ExpressionName': 'string' }, 'LFTagExpression': { 'CatalogId': 'string', 'Name': 'string' } }, 'Permissions': [ 'ALL'|'SELECT'|'ALTER'|'DROP'|'DELETE'|'INSERT'|'DESCRIBE'|'CREATE_DATABASE'|'CREATE_TABLE'|'DATA_LOCATION_ACCESS'|'CREATE_LF_TAG'|'ASSOCIATE'|'GRANT_WITH_LF_TAG_EXPRESSION'|'CREATE_LF_TAG_EXPRESSION'|'CREATE_CATALOG'|'SUPER_USER', ], 'Condition': { 'Expression': 'string' }, 'PermissionsWithGrantOption': [ 'ALL'|'SELECT'|'ALTER'|'DROP'|'DELETE'|'INSERT'|'DESCRIBE'|'CREATE_DATABASE'|'CREATE_TABLE'|'DATA_LOCATION_ACCESS'|'CREATE_LF_TAG'|'ASSOCIATE'|'GRANT_WITH_LF_TAG_EXPRESSION'|'CREATE_LF_TAG_EXPRESSION'|'CREATE_CATALOG'|'SUPER_USER', ] }, 'Error': { 'ErrorCode': 'string', 'ErrorMessage': 'string' } }, ] }
Response Structure
(dict) --
Failures (list) --
A list of failures to grant permissions to the resources.
(dict) --
A list of failures when performing a batch grant or batch revoke operation.
RequestEntry (dict) --
An identifier for an entry of the batch request.
Id (string) --
A unique identifier for the batch permissions request entry.
Principal (dict) --
The principal to be granted a permission.
DataLakePrincipalIdentifier (string) --
An identifier for the Lake Formation principal.
Resource (dict) --
The resource to which the principal is to be granted a permission.
Catalog (dict) --
The identifier for the Data Catalog. By default, the account ID. The Data Catalog is the persistent metadata store. It contains database definitions, table definitions, and other control information to manage your Lake Formation environment.
Id (string) --
An identifier for the catalog resource.
Database (dict) --
The database for the resource. Unique to the Data Catalog. A database is a set of associated table definitions organized into a logical group. You can Grant and Revoke database permissions to a principal.
CatalogId (string) --
The identifier for the Data Catalog. By default, it is the account ID of the caller.
Name (string) --
The name of the database resource. Unique to the Data Catalog.
Table (dict) --
The table for the resource. A table is a metadata definition that represents your data. You can Grant and Revoke table privileges to a principal.
CatalogId (string) --
The identifier for the Data Catalog. By default, it is the account ID of the caller.
DatabaseName (string) --
The name of the database for the table. Unique to a Data Catalog. A database is a set of associated table definitions organized into a logical group. You can Grant and Revoke database privileges to a principal.
Name (string) --
The name of the table.
TableWildcard (dict) --
A wildcard object representing every table under a database.
At least one of TableResource$Name or TableResource$TableWildcard is required.
TableWithColumns (dict) --
The table with columns for the resource. A principal with permissions to this resource can select metadata from the columns of a table in the Data Catalog and the underlying data in Amazon S3.
CatalogId (string) --
The identifier for the Data Catalog. By default, it is the account ID of the caller.
DatabaseName (string) --
The name of the database for the table with columns resource. Unique to the Data Catalog. A database is a set of associated table definitions organized into a logical group. You can Grant and Revoke database privileges to a principal.
Name (string) --
The name of the table resource. A table is a metadata definition that represents your data. You can Grant and Revoke table privileges to a principal.
ColumnNames (list) --
The list of column names for the table. At least one of ColumnNames or ColumnWildcard is required.
(string) --
ColumnWildcard (dict) --
A wildcard specified by a ColumnWildcard object. At least one of ColumnNames or ColumnWildcard is required.
ExcludedColumnNames (list) --
Excludes column names. Any column with this name will be excluded.
(string) --
DataLocation (dict) --
The location of an Amazon S3 path where permissions are granted or revoked.
CatalogId (string) --
The identifier for the Data Catalog where the location is registered with Lake Formation. By default, it is the account ID of the caller.
ResourceArn (string) --
The Amazon Resource Name (ARN) that uniquely identifies the data location resource.
DataCellsFilter (dict) --
A data cell filter.
TableCatalogId (string) --
The ID of the catalog to which the table belongs.
DatabaseName (string) --
A database in the Glue Data Catalog.
TableName (string) --
The name of the table.
Name (string) --
The name of the data cells filter.
LFTag (dict) --
The LF-tag key and values attached to a resource.
CatalogId (string) --
The identifier for the Data Catalog. By default, the account ID. The Data Catalog is the persistent metadata store. It contains database definitions, table definitions, and other control information to manage your Lake Formation environment.
TagKey (string) --
The key-name for the LF-tag.
TagValues (list) --
A list of possible values an attribute can take.
(string) --
LFTagPolicy (dict) --
A list of LF-tag conditions or saved LF-Tag expressions that define a resource's LF-tag policy.
CatalogId (string) --
The identifier for the Data Catalog. By default, the account ID. The Data Catalog is the persistent metadata store. It contains database definitions, table definitions, and other control information to manage your Lake Formation environment.
ResourceType (string) --
The resource type for which the LF-tag policy applies.
Expression (list) --
A list of LF-tag conditions or a saved expression that apply to the resource's LF-tag policy.
(dict) --
A structure that allows an admin to grant user permissions on certain conditions. For example, granting a role access to all columns that do not have the LF-tag 'PII' in tables that have the LF-tag 'Prod'.
TagKey (string) --
The key-name for the LF-tag.
TagValues (list) --
A list of possible values an attribute can take.
The maximum number of values that can be defined for a LF-Tag is 1000. A single API call supports 50 values. You can use multiple API calls to add more values.
(string) --
ExpressionName (string) --
If provided, permissions are granted to the Data Catalog resources whose assigned LF-Tags match the expression body of the saved expression under the provided ExpressionName.
LFTagExpression (dict) --
LF-Tag expression resource. A logical expression composed of one or more LF-Tag key:value pairs.
CatalogId (string) --
The identifier for the Data Catalog. By default, the account ID.
Name (string) --
The name of the LF-Tag expression to grant permissions on.
Permissions (list) --
The permissions to be granted.
(string) --
Condition (dict) --
A Lake Formation condition, which applies to permissions and opt-ins that contain an expression.
Expression (string) --
An expression written based on the Cedar Policy Language used to match the principal attributes.
PermissionsWithGrantOption (list) --
Indicates if the option to pass permissions is granted.
(string) --
Error (dict) --
An error message that applies to the failure of the entry.
ErrorCode (string) --
The code associated with this error.
ErrorMessage (string) --
A message describing the error.
{'Entries': {'Condition': {'Expression': 'string'}}}Response
{'Failures': {'RequestEntry': {'Condition': {'Expression': 'string'}}}}
Batch operation to revoke permissions from the principal.
See also: AWS API Documentation
Request Syntax
client.batch_revoke_permissions( CatalogId='string', Entries=[ { 'Id': 'string', 'Principal': { 'DataLakePrincipalIdentifier': 'string' }, 'Resource': { 'Catalog': { 'Id': 'string' }, 'Database': { 'CatalogId': 'string', 'Name': 'string' }, 'Table': { 'CatalogId': 'string', 'DatabaseName': 'string', 'Name': 'string', 'TableWildcard': {} }, 'TableWithColumns': { 'CatalogId': 'string', 'DatabaseName': 'string', 'Name': 'string', 'ColumnNames': [ 'string', ], 'ColumnWildcard': { 'ExcludedColumnNames': [ 'string', ] } }, 'DataLocation': { 'CatalogId': 'string', 'ResourceArn': 'string' }, 'DataCellsFilter': { 'TableCatalogId': 'string', 'DatabaseName': 'string', 'TableName': 'string', 'Name': 'string' }, 'LFTag': { 'CatalogId': 'string', 'TagKey': 'string', 'TagValues': [ 'string', ] }, 'LFTagPolicy': { 'CatalogId': 'string', 'ResourceType': 'DATABASE'|'TABLE', 'Expression': [ { 'TagKey': 'string', 'TagValues': [ 'string', ] }, ], 'ExpressionName': 'string' }, 'LFTagExpression': { 'CatalogId': 'string', 'Name': 'string' } }, 'Permissions': [ 'ALL'|'SELECT'|'ALTER'|'DROP'|'DELETE'|'INSERT'|'DESCRIBE'|'CREATE_DATABASE'|'CREATE_TABLE'|'DATA_LOCATION_ACCESS'|'CREATE_LF_TAG'|'ASSOCIATE'|'GRANT_WITH_LF_TAG_EXPRESSION'|'CREATE_LF_TAG_EXPRESSION'|'CREATE_CATALOG'|'SUPER_USER', ], 'Condition': { 'Expression': 'string' }, 'PermissionsWithGrantOption': [ 'ALL'|'SELECT'|'ALTER'|'DROP'|'DELETE'|'INSERT'|'DESCRIBE'|'CREATE_DATABASE'|'CREATE_TABLE'|'DATA_LOCATION_ACCESS'|'CREATE_LF_TAG'|'ASSOCIATE'|'GRANT_WITH_LF_TAG_EXPRESSION'|'CREATE_LF_TAG_EXPRESSION'|'CREATE_CATALOG'|'SUPER_USER', ] }, ] )
string
The identifier for the Data Catalog. By default, the account ID. The Data Catalog is the persistent metadata store. It contains database definitions, table definitions, and other control information to manage your Lake Formation environment.
list
[REQUIRED]
A list of up to 20 entries for resource permissions to be revoked by batch operation to the principal.
(dict) --
A permission to a resource granted by batch operation to the principal.
Id (string) -- [REQUIRED]
A unique identifier for the batch permissions request entry.
Principal (dict) --
The principal to be granted a permission.
DataLakePrincipalIdentifier (string) --
An identifier for the Lake Formation principal.
Resource (dict) --
The resource to which the principal is to be granted a permission.
Catalog (dict) --
The identifier for the Data Catalog. By default, the account ID. The Data Catalog is the persistent metadata store. It contains database definitions, table definitions, and other control information to manage your Lake Formation environment.
Id (string) --
An identifier for the catalog resource.
Database (dict) --
The database for the resource. Unique to the Data Catalog. A database is a set of associated table definitions organized into a logical group. You can Grant and Revoke database permissions to a principal.
CatalogId (string) --
The identifier for the Data Catalog. By default, it is the account ID of the caller.
Name (string) -- [REQUIRED]
The name of the database resource. Unique to the Data Catalog.
Table (dict) --
The table for the resource. A table is a metadata definition that represents your data. You can Grant and Revoke table privileges to a principal.
CatalogId (string) --
The identifier for the Data Catalog. By default, it is the account ID of the caller.
DatabaseName (string) -- [REQUIRED]
The name of the database for the table. Unique to a Data Catalog. A database is a set of associated table definitions organized into a logical group. You can Grant and Revoke database privileges to a principal.
Name (string) --
The name of the table.
TableWildcard (dict) --
A wildcard object representing every table under a database.
At least one of TableResource$Name or TableResource$TableWildcard is required.
TableWithColumns (dict) --
The table with columns for the resource. A principal with permissions to this resource can select metadata from the columns of a table in the Data Catalog and the underlying data in Amazon S3.
CatalogId (string) --
The identifier for the Data Catalog. By default, it is the account ID of the caller.
DatabaseName (string) -- [REQUIRED]
The name of the database for the table with columns resource. Unique to the Data Catalog. A database is a set of associated table definitions organized into a logical group. You can Grant and Revoke database privileges to a principal.
Name (string) -- [REQUIRED]
The name of the table resource. A table is a metadata definition that represents your data. You can Grant and Revoke table privileges to a principal.
ColumnNames (list) --
The list of column names for the table. At least one of ColumnNames or ColumnWildcard is required.
(string) --
ColumnWildcard (dict) --
A wildcard specified by a ColumnWildcard object. At least one of ColumnNames or ColumnWildcard is required.
ExcludedColumnNames (list) --
Excludes column names. Any column with this name will be excluded.
(string) --
DataLocation (dict) --
The location of an Amazon S3 path where permissions are granted or revoked.
CatalogId (string) --
The identifier for the Data Catalog where the location is registered with Lake Formation. By default, it is the account ID of the caller.
ResourceArn (string) -- [REQUIRED]
The Amazon Resource Name (ARN) that uniquely identifies the data location resource.
DataCellsFilter (dict) --
A data cell filter.
TableCatalogId (string) --
The ID of the catalog to which the table belongs.
DatabaseName (string) --
A database in the Glue Data Catalog.
TableName (string) --
The name of the table.
Name (string) --
The name of the data cells filter.
LFTag (dict) --
The LF-tag key and values attached to a resource.
CatalogId (string) --
The identifier for the Data Catalog. By default, the account ID. The Data Catalog is the persistent metadata store. It contains database definitions, table definitions, and other control information to manage your Lake Formation environment.
TagKey (string) -- [REQUIRED]
The key-name for the LF-tag.
TagValues (list) -- [REQUIRED]
A list of possible values an attribute can take.
(string) --
LFTagPolicy (dict) --
A list of LF-tag conditions or saved LF-Tag expressions that define a resource's LF-tag policy.
CatalogId (string) --
The identifier for the Data Catalog. By default, the account ID. The Data Catalog is the persistent metadata store. It contains database definitions, table definitions, and other control information to manage your Lake Formation environment.
ResourceType (string) -- [REQUIRED]
The resource type for which the LF-tag policy applies.
Expression (list) --
A list of LF-tag conditions or a saved expression that apply to the resource's LF-tag policy.
(dict) --
A structure that allows an admin to grant user permissions on certain conditions. For example, granting a role access to all columns that do not have the LF-tag 'PII' in tables that have the LF-tag 'Prod'.
TagKey (string) -- [REQUIRED]
The key-name for the LF-tag.
TagValues (list) -- [REQUIRED]
A list of possible values an attribute can take.
The maximum number of values that can be defined for a LF-Tag is 1000. A single API call supports 50 values. You can use multiple API calls to add more values.
(string) --
ExpressionName (string) --
If provided, permissions are granted to the Data Catalog resources whose assigned LF-Tags match the expression body of the saved expression under the provided ExpressionName.
LFTagExpression (dict) --
LF-Tag expression resource. A logical expression composed of one or more LF-Tag key:value pairs.
CatalogId (string) --
The identifier for the Data Catalog. By default, the account ID.
Name (string) -- [REQUIRED]
The name of the LF-Tag expression to grant permissions on.
Permissions (list) --
The permissions to be granted.
(string) --
Condition (dict) --
A Lake Formation condition, which applies to permissions and opt-ins that contain an expression.
Expression (string) --
An expression written based on the Cedar Policy Language used to match the principal attributes.
PermissionsWithGrantOption (list) --
Indicates if the option to pass permissions is granted.
(string) --
dict
Response Syntax
{ 'Failures': [ { 'RequestEntry': { 'Id': 'string', 'Principal': { 'DataLakePrincipalIdentifier': 'string' }, 'Resource': { 'Catalog': { 'Id': 'string' }, 'Database': { 'CatalogId': 'string', 'Name': 'string' }, 'Table': { 'CatalogId': 'string', 'DatabaseName': 'string', 'Name': 'string', 'TableWildcard': {} }, 'TableWithColumns': { 'CatalogId': 'string', 'DatabaseName': 'string', 'Name': 'string', 'ColumnNames': [ 'string', ], 'ColumnWildcard': { 'ExcludedColumnNames': [ 'string', ] } }, 'DataLocation': { 'CatalogId': 'string', 'ResourceArn': 'string' }, 'DataCellsFilter': { 'TableCatalogId': 'string', 'DatabaseName': 'string', 'TableName': 'string', 'Name': 'string' }, 'LFTag': { 'CatalogId': 'string', 'TagKey': 'string', 'TagValues': [ 'string', ] }, 'LFTagPolicy': { 'CatalogId': 'string', 'ResourceType': 'DATABASE'|'TABLE', 'Expression': [ { 'TagKey': 'string', 'TagValues': [ 'string', ] }, ], 'ExpressionName': 'string' }, 'LFTagExpression': { 'CatalogId': 'string', 'Name': 'string' } }, 'Permissions': [ 'ALL'|'SELECT'|'ALTER'|'DROP'|'DELETE'|'INSERT'|'DESCRIBE'|'CREATE_DATABASE'|'CREATE_TABLE'|'DATA_LOCATION_ACCESS'|'CREATE_LF_TAG'|'ASSOCIATE'|'GRANT_WITH_LF_TAG_EXPRESSION'|'CREATE_LF_TAG_EXPRESSION'|'CREATE_CATALOG'|'SUPER_USER', ], 'Condition': { 'Expression': 'string' }, 'PermissionsWithGrantOption': [ 'ALL'|'SELECT'|'ALTER'|'DROP'|'DELETE'|'INSERT'|'DESCRIBE'|'CREATE_DATABASE'|'CREATE_TABLE'|'DATA_LOCATION_ACCESS'|'CREATE_LF_TAG'|'ASSOCIATE'|'GRANT_WITH_LF_TAG_EXPRESSION'|'CREATE_LF_TAG_EXPRESSION'|'CREATE_CATALOG'|'SUPER_USER', ] }, 'Error': { 'ErrorCode': 'string', 'ErrorMessage': 'string' } }, ] }
Response Structure
(dict) --
Failures (list) --
A list of failures to revoke permissions to the resources.
(dict) --
A list of failures when performing a batch grant or batch revoke operation.
RequestEntry (dict) --
An identifier for an entry of the batch request.
Id (string) --
A unique identifier for the batch permissions request entry.
Principal (dict) --
The principal to be granted a permission.
DataLakePrincipalIdentifier (string) --
An identifier for the Lake Formation principal.
Resource (dict) --
The resource to which the principal is to be granted a permission.
Catalog (dict) --
The identifier for the Data Catalog. By default, the account ID. The Data Catalog is the persistent metadata store. It contains database definitions, table definitions, and other control information to manage your Lake Formation environment.
Id (string) --
An identifier for the catalog resource.
Database (dict) --
The database for the resource. Unique to the Data Catalog. A database is a set of associated table definitions organized into a logical group. You can Grant and Revoke database permissions to a principal.
CatalogId (string) --
The identifier for the Data Catalog. By default, it is the account ID of the caller.
Name (string) --
The name of the database resource. Unique to the Data Catalog.
Table (dict) --
The table for the resource. A table is a metadata definition that represents your data. You can Grant and Revoke table privileges to a principal.
CatalogId (string) --
The identifier for the Data Catalog. By default, it is the account ID of the caller.
DatabaseName (string) --
The name of the database for the table. Unique to a Data Catalog. A database is a set of associated table definitions organized into a logical group. You can Grant and Revoke database privileges to a principal.
Name (string) --
The name of the table.
TableWildcard (dict) --
A wildcard object representing every table under a database.
At least one of TableResource$Name or TableResource$TableWildcard is required.
TableWithColumns (dict) --
The table with columns for the resource. A principal with permissions to this resource can select metadata from the columns of a table in the Data Catalog and the underlying data in Amazon S3.
CatalogId (string) --
The identifier for the Data Catalog. By default, it is the account ID of the caller.
DatabaseName (string) --
The name of the database for the table with columns resource. Unique to the Data Catalog. A database is a set of associated table definitions organized into a logical group. You can Grant and Revoke database privileges to a principal.
Name (string) --
The name of the table resource. A table is a metadata definition that represents your data. You can Grant and Revoke table privileges to a principal.
ColumnNames (list) --
The list of column names for the table. At least one of ColumnNames or ColumnWildcard is required.
(string) --
ColumnWildcard (dict) --
A wildcard specified by a ColumnWildcard object. At least one of ColumnNames or ColumnWildcard is required.
ExcludedColumnNames (list) --
Excludes column names. Any column with this name will be excluded.
(string) --
DataLocation (dict) --
The location of an Amazon S3 path where permissions are granted or revoked.
CatalogId (string) --
The identifier for the Data Catalog where the location is registered with Lake Formation. By default, it is the account ID of the caller.
ResourceArn (string) --
The Amazon Resource Name (ARN) that uniquely identifies the data location resource.
DataCellsFilter (dict) --
A data cell filter.
TableCatalogId (string) --
The ID of the catalog to which the table belongs.
DatabaseName (string) --
A database in the Glue Data Catalog.
TableName (string) --
The name of the table.
Name (string) --
The name of the data cells filter.
LFTag (dict) --
The LF-tag key and values attached to a resource.
CatalogId (string) --
The identifier for the Data Catalog. By default, the account ID. The Data Catalog is the persistent metadata store. It contains database definitions, table definitions, and other control information to manage your Lake Formation environment.
TagKey (string) --
The key-name for the LF-tag.
TagValues (list) --
A list of possible values an attribute can take.
(string) --
LFTagPolicy (dict) --
A list of LF-tag conditions or saved LF-Tag expressions that define a resource's LF-tag policy.
CatalogId (string) --
The identifier for the Data Catalog. By default, the account ID. The Data Catalog is the persistent metadata store. It contains database definitions, table definitions, and other control information to manage your Lake Formation environment.
ResourceType (string) --
The resource type for which the LF-tag policy applies.
Expression (list) --
A list of LF-tag conditions or a saved expression that apply to the resource's LF-tag policy.
(dict) --
A structure that allows an admin to grant user permissions on certain conditions. For example, granting a role access to all columns that do not have the LF-tag 'PII' in tables that have the LF-tag 'Prod'.
TagKey (string) --
The key-name for the LF-tag.
TagValues (list) --
A list of possible values an attribute can take.
The maximum number of values that can be defined for a LF-Tag is 1000. A single API call supports 50 values. You can use multiple API calls to add more values.
(string) --
ExpressionName (string) --
If provided, permissions are granted to the Data Catalog resources whose assigned LF-Tags match the expression body of the saved expression under the provided ExpressionName.
LFTagExpression (dict) --
LF-Tag expression resource. A logical expression composed of one or more LF-Tag key:value pairs.
CatalogId (string) --
The identifier for the Data Catalog. By default, the account ID.
Name (string) --
The name of the LF-Tag expression to grant permissions on.
Permissions (list) --
The permissions to be granted.
(string) --
Condition (dict) --
A Lake Formation condition, which applies to permissions and opt-ins that contain an expression.
Expression (string) --
An expression written based on the Cedar Policy Language used to match the principal attributes.
PermissionsWithGrantOption (list) --
Indicates if the option to pass permissions is granted.
(string) --
Error (dict) --
An error message that applies to the failure of the entry.
ErrorCode (string) --
The code associated with this error.
ErrorMessage (string) --
A message describing the error.
{'Condition': {'Expression': 'string'}}
Enforce Lake Formation permissions for the given databases, tables, and principals.
See also: AWS API Documentation
Request Syntax
client.create_lake_formation_opt_in( Principal={ 'DataLakePrincipalIdentifier': 'string' }, Resource={ 'Catalog': { 'Id': 'string' }, 'Database': { 'CatalogId': 'string', 'Name': 'string' }, 'Table': { 'CatalogId': 'string', 'DatabaseName': 'string', 'Name': 'string', 'TableWildcard': {} }, 'TableWithColumns': { 'CatalogId': 'string', 'DatabaseName': 'string', 'Name': 'string', 'ColumnNames': [ 'string', ], 'ColumnWildcard': { 'ExcludedColumnNames': [ 'string', ] } }, 'DataLocation': { 'CatalogId': 'string', 'ResourceArn': 'string' }, 'DataCellsFilter': { 'TableCatalogId': 'string', 'DatabaseName': 'string', 'TableName': 'string', 'Name': 'string' }, 'LFTag': { 'CatalogId': 'string', 'TagKey': 'string', 'TagValues': [ 'string', ] }, 'LFTagPolicy': { 'CatalogId': 'string', 'ResourceType': 'DATABASE'|'TABLE', 'Expression': [ { 'TagKey': 'string', 'TagValues': [ 'string', ] }, ], 'ExpressionName': 'string' }, 'LFTagExpression': { 'CatalogId': 'string', 'Name': 'string' } }, Condition={ 'Expression': 'string' } )
dict
[REQUIRED]
The Lake Formation principal. Supported principals are IAM users or IAM roles.
DataLakePrincipalIdentifier (string) --
An identifier for the Lake Formation principal.
dict
[REQUIRED]
A structure for the resource.
Catalog (dict) --
The identifier for the Data Catalog. By default, the account ID. The Data Catalog is the persistent metadata store. It contains database definitions, table definitions, and other control information to manage your Lake Formation environment.
Id (string) --
An identifier for the catalog resource.
Database (dict) --
The database for the resource. Unique to the Data Catalog. A database is a set of associated table definitions organized into a logical group. You can Grant and Revoke database permissions to a principal.
CatalogId (string) --
The identifier for the Data Catalog. By default, it is the account ID of the caller.
Name (string) -- [REQUIRED]
The name of the database resource. Unique to the Data Catalog.
Table (dict) --
The table for the resource. A table is a metadata definition that represents your data. You can Grant and Revoke table privileges to a principal.
CatalogId (string) --
The identifier for the Data Catalog. By default, it is the account ID of the caller.
DatabaseName (string) -- [REQUIRED]
The name of the database for the table. Unique to a Data Catalog. A database is a set of associated table definitions organized into a logical group. You can Grant and Revoke database privileges to a principal.
Name (string) --
The name of the table.
TableWildcard (dict) --
A wildcard object representing every table under a database.
At least one of TableResource$Name or TableResource$TableWildcard is required.
TableWithColumns (dict) --
The table with columns for the resource. A principal with permissions to this resource can select metadata from the columns of a table in the Data Catalog and the underlying data in Amazon S3.
CatalogId (string) --
The identifier for the Data Catalog. By default, it is the account ID of the caller.
DatabaseName (string) -- [REQUIRED]
The name of the database for the table with columns resource. Unique to the Data Catalog. A database is a set of associated table definitions organized into a logical group. You can Grant and Revoke database privileges to a principal.
Name (string) -- [REQUIRED]
The name of the table resource. A table is a metadata definition that represents your data. You can Grant and Revoke table privileges to a principal.
ColumnNames (list) --
The list of column names for the table. At least one of ColumnNames or ColumnWildcard is required.
(string) --
ColumnWildcard (dict) --
A wildcard specified by a ColumnWildcard object. At least one of ColumnNames or ColumnWildcard is required.
ExcludedColumnNames (list) --
Excludes column names. Any column with this name will be excluded.
(string) --
DataLocation (dict) --
The location of an Amazon S3 path where permissions are granted or revoked.
CatalogId (string) --
The identifier for the Data Catalog where the location is registered with Lake Formation. By default, it is the account ID of the caller.
ResourceArn (string) -- [REQUIRED]
The Amazon Resource Name (ARN) that uniquely identifies the data location resource.
DataCellsFilter (dict) --
A data cell filter.
TableCatalogId (string) --
The ID of the catalog to which the table belongs.
DatabaseName (string) --
A database in the Glue Data Catalog.
TableName (string) --
The name of the table.
Name (string) --
The name of the data cells filter.
LFTag (dict) --
The LF-tag key and values attached to a resource.
CatalogId (string) --
The identifier for the Data Catalog. By default, the account ID. The Data Catalog is the persistent metadata store. It contains database definitions, table definitions, and other control information to manage your Lake Formation environment.
TagKey (string) -- [REQUIRED]
The key-name for the LF-tag.
TagValues (list) -- [REQUIRED]
A list of possible values an attribute can take.
(string) --
LFTagPolicy (dict) --
A list of LF-tag conditions or saved LF-Tag expressions that define a resource's LF-tag policy.
CatalogId (string) --
The identifier for the Data Catalog. By default, the account ID. The Data Catalog is the persistent metadata store. It contains database definitions, table definitions, and other control information to manage your Lake Formation environment.
ResourceType (string) -- [REQUIRED]
The resource type for which the LF-tag policy applies.
Expression (list) --
A list of LF-tag conditions or a saved expression that apply to the resource's LF-tag policy.
(dict) --
A structure that allows an admin to grant user permissions on certain conditions. For example, granting a role access to all columns that do not have the LF-tag 'PII' in tables that have the LF-tag 'Prod'.
TagKey (string) -- [REQUIRED]
The key-name for the LF-tag.
TagValues (list) -- [REQUIRED]
A list of possible values an attribute can take.
The maximum number of values that can be defined for a LF-Tag is 1000. A single API call supports 50 values. You can use multiple API calls to add more values.
(string) --
ExpressionName (string) --
If provided, permissions are granted to the Data Catalog resources whose assigned LF-Tags match the expression body of the saved expression under the provided ExpressionName.
LFTagExpression (dict) --
LF-Tag expression resource. A logical expression composed of one or more LF-Tag key:value pairs.
CatalogId (string) --
The identifier for the Data Catalog. By default, the account ID.
Name (string) -- [REQUIRED]
The name of the LF-Tag expression to grant permissions on.
dict
A Lake Formation condition, which applies to permissions and opt-ins that contain an expression.
Expression (string) --
An expression written based on the Cedar Policy Language used to match the principal attributes.
dict
Response Syntax
{}
Response Structure
(dict) --
{'Condition': {'Expression': 'string'}}
Remove the Lake Formation permissions enforcement of the given databases, tables, and principals.
See also: AWS API Documentation
Request Syntax
client.delete_lake_formation_opt_in( Principal={ 'DataLakePrincipalIdentifier': 'string' }, Resource={ 'Catalog': { 'Id': 'string' }, 'Database': { 'CatalogId': 'string', 'Name': 'string' }, 'Table': { 'CatalogId': 'string', 'DatabaseName': 'string', 'Name': 'string', 'TableWildcard': {} }, 'TableWithColumns': { 'CatalogId': 'string', 'DatabaseName': 'string', 'Name': 'string', 'ColumnNames': [ 'string', ], 'ColumnWildcard': { 'ExcludedColumnNames': [ 'string', ] } }, 'DataLocation': { 'CatalogId': 'string', 'ResourceArn': 'string' }, 'DataCellsFilter': { 'TableCatalogId': 'string', 'DatabaseName': 'string', 'TableName': 'string', 'Name': 'string' }, 'LFTag': { 'CatalogId': 'string', 'TagKey': 'string', 'TagValues': [ 'string', ] }, 'LFTagPolicy': { 'CatalogId': 'string', 'ResourceType': 'DATABASE'|'TABLE', 'Expression': [ { 'TagKey': 'string', 'TagValues': [ 'string', ] }, ], 'ExpressionName': 'string' }, 'LFTagExpression': { 'CatalogId': 'string', 'Name': 'string' } }, Condition={ 'Expression': 'string' } )
dict
[REQUIRED]
The Lake Formation principal. Supported principals are IAM users or IAM roles.
DataLakePrincipalIdentifier (string) --
An identifier for the Lake Formation principal.
dict
[REQUIRED]
A structure for the resource.
Catalog (dict) --
The identifier for the Data Catalog. By default, the account ID. The Data Catalog is the persistent metadata store. It contains database definitions, table definitions, and other control information to manage your Lake Formation environment.
Id (string) --
An identifier for the catalog resource.
Database (dict) --
The database for the resource. Unique to the Data Catalog. A database is a set of associated table definitions organized into a logical group. You can Grant and Revoke database permissions to a principal.
CatalogId (string) --
The identifier for the Data Catalog. By default, it is the account ID of the caller.
Name (string) -- [REQUIRED]
The name of the database resource. Unique to the Data Catalog.
Table (dict) --
The table for the resource. A table is a metadata definition that represents your data. You can Grant and Revoke table privileges to a principal.
CatalogId (string) --
The identifier for the Data Catalog. By default, it is the account ID of the caller.
DatabaseName (string) -- [REQUIRED]
The name of the database for the table. Unique to a Data Catalog. A database is a set of associated table definitions organized into a logical group. You can Grant and Revoke database privileges to a principal.
Name (string) --
The name of the table.
TableWildcard (dict) --
A wildcard object representing every table under a database.
At least one of TableResource$Name or TableResource$TableWildcard is required.
TableWithColumns (dict) --
The table with columns for the resource. A principal with permissions to this resource can select metadata from the columns of a table in the Data Catalog and the underlying data in Amazon S3.
CatalogId (string) --
The identifier for the Data Catalog. By default, it is the account ID of the caller.
DatabaseName (string) -- [REQUIRED]
The name of the database for the table with columns resource. Unique to the Data Catalog. A database is a set of associated table definitions organized into a logical group. You can Grant and Revoke database privileges to a principal.
Name (string) -- [REQUIRED]
The name of the table resource. A table is a metadata definition that represents your data. You can Grant and Revoke table privileges to a principal.
ColumnNames (list) --
The list of column names for the table. At least one of ColumnNames or ColumnWildcard is required.
(string) --
ColumnWildcard (dict) --
A wildcard specified by a ColumnWildcard object. At least one of ColumnNames or ColumnWildcard is required.
ExcludedColumnNames (list) --
Excludes column names. Any column with this name will be excluded.
(string) --
DataLocation (dict) --
The location of an Amazon S3 path where permissions are granted or revoked.
CatalogId (string) --
The identifier for the Data Catalog where the location is registered with Lake Formation. By default, it is the account ID of the caller.
ResourceArn (string) -- [REQUIRED]
The Amazon Resource Name (ARN) that uniquely identifies the data location resource.
DataCellsFilter (dict) --
A data cell filter.
TableCatalogId (string) --
The ID of the catalog to which the table belongs.
DatabaseName (string) --
A database in the Glue Data Catalog.
TableName (string) --
The name of the table.
Name (string) --
The name of the data cells filter.
LFTag (dict) --
The LF-tag key and values attached to a resource.
CatalogId (string) --
The identifier for the Data Catalog. By default, the account ID. The Data Catalog is the persistent metadata store. It contains database definitions, table definitions, and other control information to manage your Lake Formation environment.
TagKey (string) -- [REQUIRED]
The key-name for the LF-tag.
TagValues (list) -- [REQUIRED]
A list of possible values an attribute can take.
(string) --
LFTagPolicy (dict) --
A list of LF-tag conditions or saved LF-Tag expressions that define a resource's LF-tag policy.
CatalogId (string) --
The identifier for the Data Catalog. By default, the account ID. The Data Catalog is the persistent metadata store. It contains database definitions, table definitions, and other control information to manage your Lake Formation environment.
ResourceType (string) -- [REQUIRED]
The resource type for which the LF-tag policy applies.
Expression (list) --
A list of LF-tag conditions or a saved expression that apply to the resource's LF-tag policy.
(dict) --
A structure that allows an admin to grant user permissions on certain conditions. For example, granting a role access to all columns that do not have the LF-tag 'PII' in tables that have the LF-tag 'Prod'.
TagKey (string) -- [REQUIRED]
The key-name for the LF-tag.
TagValues (list) -- [REQUIRED]
A list of possible values an attribute can take.
The maximum number of values that can be defined for a LF-Tag is 1000. A single API call supports 50 values. You can use multiple API calls to add more values.
(string) --
ExpressionName (string) --
If provided, permissions are granted to the Data Catalog resources whose assigned LF-Tags match the expression body of the saved expression under the provided ExpressionName.
LFTagExpression (dict) --
LF-Tag expression resource. A logical expression composed of one or more LF-Tag key:value pairs.
CatalogId (string) --
The identifier for the Data Catalog. By default, the account ID.
Name (string) -- [REQUIRED]
The name of the LF-Tag expression to grant permissions on.
dict
A Lake Formation condition, which applies to permissions and opt-ins that contain an expression.
Expression (string) --
An expression written based on the Cedar Policy Language used to match the principal attributes.
dict
Response Syntax
{}
Response Structure
(dict) --
{'ResourceInfo': {'WithPrivilegedAccess': 'boolean'}}
Retrieves the current data access role for the given resource registered in Lake Formation.
See also: AWS API Documentation
Request Syntax
client.describe_resource( ResourceArn='string' )
string
[REQUIRED]
The resource ARN.
dict
Response Syntax
{ 'ResourceInfo': { 'ResourceArn': 'string', 'RoleArn': 'string', 'LastModified': datetime(2015, 1, 1), 'WithFederation': True|False, 'HybridAccessEnabled': True|False, 'WithPrivilegedAccess': True|False } }
Response Structure
(dict) --
ResourceInfo (dict) --
A structure containing information about an Lake Formation resource.
ResourceArn (string) --
The Amazon Resource Name (ARN) of the resource.
RoleArn (string) --
The IAM role that registered a resource.
LastModified (datetime) --
The date and time the resource was last modified.
WithFederation (boolean) --
Whether or not the resource is a federated resource.
HybridAccessEnabled (boolean) --
Indicates whether the data access of tables pointing to the location can be managed by both Lake Formation permissions as well as Amazon S3 bucket policies.
WithPrivilegedAccess (boolean) --
Grants the calling principal the permissions to perform all supported Lake Formation operations on the registered data location.
{'Condition': {'Expression': 'string'}}
Grants permissions to the principal to access metadata in the Data Catalog and data organized in underlying data storage such as Amazon S3.
For information about permissions, see Security and Access Control to Metadata and Data.
See also: AWS API Documentation
Request Syntax
client.grant_permissions( CatalogId='string', Principal={ 'DataLakePrincipalIdentifier': 'string' }, Resource={ 'Catalog': { 'Id': 'string' }, 'Database': { 'CatalogId': 'string', 'Name': 'string' }, 'Table': { 'CatalogId': 'string', 'DatabaseName': 'string', 'Name': 'string', 'TableWildcard': {} }, 'TableWithColumns': { 'CatalogId': 'string', 'DatabaseName': 'string', 'Name': 'string', 'ColumnNames': [ 'string', ], 'ColumnWildcard': { 'ExcludedColumnNames': [ 'string', ] } }, 'DataLocation': { 'CatalogId': 'string', 'ResourceArn': 'string' }, 'DataCellsFilter': { 'TableCatalogId': 'string', 'DatabaseName': 'string', 'TableName': 'string', 'Name': 'string' }, 'LFTag': { 'CatalogId': 'string', 'TagKey': 'string', 'TagValues': [ 'string', ] }, 'LFTagPolicy': { 'CatalogId': 'string', 'ResourceType': 'DATABASE'|'TABLE', 'Expression': [ { 'TagKey': 'string', 'TagValues': [ 'string', ] }, ], 'ExpressionName': 'string' }, 'LFTagExpression': { 'CatalogId': 'string', 'Name': 'string' } }, Permissions=[ 'ALL'|'SELECT'|'ALTER'|'DROP'|'DELETE'|'INSERT'|'DESCRIBE'|'CREATE_DATABASE'|'CREATE_TABLE'|'DATA_LOCATION_ACCESS'|'CREATE_LF_TAG'|'ASSOCIATE'|'GRANT_WITH_LF_TAG_EXPRESSION'|'CREATE_LF_TAG_EXPRESSION'|'CREATE_CATALOG'|'SUPER_USER', ], Condition={ 'Expression': 'string' }, PermissionsWithGrantOption=[ 'ALL'|'SELECT'|'ALTER'|'DROP'|'DELETE'|'INSERT'|'DESCRIBE'|'CREATE_DATABASE'|'CREATE_TABLE'|'DATA_LOCATION_ACCESS'|'CREATE_LF_TAG'|'ASSOCIATE'|'GRANT_WITH_LF_TAG_EXPRESSION'|'CREATE_LF_TAG_EXPRESSION'|'CREATE_CATALOG'|'SUPER_USER', ] )
string
The identifier for the Data Catalog. By default, the account ID. The Data Catalog is the persistent metadata store. It contains database definitions, table definitions, and other control information to manage your Lake Formation environment.
dict
[REQUIRED]
The principal to be granted the permissions on the resource. Supported principals are IAM users or IAM roles, and they are defined by their principal type and their ARN.
Note that if you define a resource with a particular ARN, then later delete, and recreate a resource with that same ARN, the resource maintains the permissions already granted.
DataLakePrincipalIdentifier (string) --
An identifier for the Lake Formation principal.
dict
[REQUIRED]
The resource to which permissions are to be granted. Resources in Lake Formation are the Data Catalog, databases, and tables.
Catalog (dict) --
The identifier for the Data Catalog. By default, the account ID. The Data Catalog is the persistent metadata store. It contains database definitions, table definitions, and other control information to manage your Lake Formation environment.
Id (string) --
An identifier for the catalog resource.
Database (dict) --
The database for the resource. Unique to the Data Catalog. A database is a set of associated table definitions organized into a logical group. You can Grant and Revoke database permissions to a principal.
CatalogId (string) --
The identifier for the Data Catalog. By default, it is the account ID of the caller.
Name (string) -- [REQUIRED]
The name of the database resource. Unique to the Data Catalog.
Table (dict) --
The table for the resource. A table is a metadata definition that represents your data. You can Grant and Revoke table privileges to a principal.
CatalogId (string) --
The identifier for the Data Catalog. By default, it is the account ID of the caller.
DatabaseName (string) -- [REQUIRED]
The name of the database for the table. Unique to a Data Catalog. A database is a set of associated table definitions organized into a logical group. You can Grant and Revoke database privileges to a principal.
Name (string) --
The name of the table.
TableWildcard (dict) --
A wildcard object representing every table under a database.
At least one of TableResource$Name or TableResource$TableWildcard is required.
TableWithColumns (dict) --
The table with columns for the resource. A principal with permissions to this resource can select metadata from the columns of a table in the Data Catalog and the underlying data in Amazon S3.
CatalogId (string) --
The identifier for the Data Catalog. By default, it is the account ID of the caller.
DatabaseName (string) -- [REQUIRED]
The name of the database for the table with columns resource. Unique to the Data Catalog. A database is a set of associated table definitions organized into a logical group. You can Grant and Revoke database privileges to a principal.
Name (string) -- [REQUIRED]
The name of the table resource. A table is a metadata definition that represents your data. You can Grant and Revoke table privileges to a principal.
ColumnNames (list) --
The list of column names for the table. At least one of ColumnNames or ColumnWildcard is required.
(string) --
ColumnWildcard (dict) --
A wildcard specified by a ColumnWildcard object. At least one of ColumnNames or ColumnWildcard is required.
ExcludedColumnNames (list) --
Excludes column names. Any column with this name will be excluded.
(string) --
DataLocation (dict) --
The location of an Amazon S3 path where permissions are granted or revoked.
CatalogId (string) --
The identifier for the Data Catalog where the location is registered with Lake Formation. By default, it is the account ID of the caller.
ResourceArn (string) -- [REQUIRED]
The Amazon Resource Name (ARN) that uniquely identifies the data location resource.
DataCellsFilter (dict) --
A data cell filter.
TableCatalogId (string) --
The ID of the catalog to which the table belongs.
DatabaseName (string) --
A database in the Glue Data Catalog.
TableName (string) --
The name of the table.
Name (string) --
The name of the data cells filter.
LFTag (dict) --
The LF-tag key and values attached to a resource.
CatalogId (string) --
The identifier for the Data Catalog. By default, the account ID. The Data Catalog is the persistent metadata store. It contains database definitions, table definitions, and other control information to manage your Lake Formation environment.
TagKey (string) -- [REQUIRED]
The key-name for the LF-tag.
TagValues (list) -- [REQUIRED]
A list of possible values an attribute can take.
(string) --
LFTagPolicy (dict) --
A list of LF-tag conditions or saved LF-Tag expressions that define a resource's LF-tag policy.
CatalogId (string) --
The identifier for the Data Catalog. By default, the account ID. The Data Catalog is the persistent metadata store. It contains database definitions, table definitions, and other control information to manage your Lake Formation environment.
ResourceType (string) -- [REQUIRED]
The resource type for which the LF-tag policy applies.
Expression (list) --
A list of LF-tag conditions or a saved expression that apply to the resource's LF-tag policy.
(dict) --
A structure that allows an admin to grant user permissions on certain conditions. For example, granting a role access to all columns that do not have the LF-tag 'PII' in tables that have the LF-tag 'Prod'.
TagKey (string) -- [REQUIRED]
The key-name for the LF-tag.
TagValues (list) -- [REQUIRED]
A list of possible values an attribute can take.
The maximum number of values that can be defined for a LF-Tag is 1000. A single API call supports 50 values. You can use multiple API calls to add more values.
(string) --
ExpressionName (string) --
If provided, permissions are granted to the Data Catalog resources whose assigned LF-Tags match the expression body of the saved expression under the provided ExpressionName.
LFTagExpression (dict) --
LF-Tag expression resource. A logical expression composed of one or more LF-Tag key:value pairs.
CatalogId (string) --
The identifier for the Data Catalog. By default, the account ID.
Name (string) -- [REQUIRED]
The name of the LF-Tag expression to grant permissions on.
list
[REQUIRED]
The permissions granted to the principal on the resource. Lake Formation defines privileges to grant and revoke access to metadata in the Data Catalog and data organized in underlying data storage such as Amazon S3. Lake Formation requires that each principal be authorized to perform a specific task on Lake Formation resources.
(string) --
dict
A Lake Formation condition, which applies to permissions and opt-ins that contain an expression.
Expression (string) --
An expression written based on the Cedar Policy Language used to match the principal attributes.
list
Indicates a list of the granted permissions that the principal may pass to other users. These permissions may only be a subset of the permissions granted in the Privileges.
(string) --
dict
Response Syntax
{}
Response Structure
(dict) --
{'ResourceInfoList': {'WithPrivilegedAccess': 'boolean'}}
Lists the resources registered to be managed by the Data Catalog.
See also: AWS API Documentation
Request Syntax
client.list_resources( FilterConditionList=[ { 'Field': 'RESOURCE_ARN'|'ROLE_ARN'|'LAST_MODIFIED', 'ComparisonOperator': 'EQ'|'NE'|'LE'|'LT'|'GE'|'GT'|'CONTAINS'|'NOT_CONTAINS'|'BEGINS_WITH'|'IN'|'BETWEEN', 'StringValueList': [ 'string', ] }, ], MaxResults=123, NextToken='string' )
list
Any applicable row-level and/or column-level filtering conditions for the resources.
(dict) --
This structure describes the filtering of columns in a table based on a filter condition.
Field (string) --
The field to filter in the filter condition.
ComparisonOperator (string) --
The comparison operator used in the filter condition.
StringValueList (list) --
A string with values used in evaluating the filter condition.
(string) --
integer
The maximum number of resource results.
string
A continuation token, if this is not the first call to retrieve these resources.
dict
Response Syntax
{ 'ResourceInfoList': [ { 'ResourceArn': 'string', 'RoleArn': 'string', 'LastModified': datetime(2015, 1, 1), 'WithFederation': True|False, 'HybridAccessEnabled': True|False, 'WithPrivilegedAccess': True|False }, ], 'NextToken': 'string' }
Response Structure
(dict) --
ResourceInfoList (list) --
A summary of the data lake resources.
(dict) --
A structure containing information about an Lake Formation resource.
ResourceArn (string) --
The Amazon Resource Name (ARN) of the resource.
RoleArn (string) --
The IAM role that registered a resource.
LastModified (datetime) --
The date and time the resource was last modified.
WithFederation (boolean) --
Whether or not the resource is a federated resource.
HybridAccessEnabled (boolean) --
Indicates whether the data access of tables pointing to the location can be managed by both Lake Formation permissions as well as Amazon S3 bucket policies.
WithPrivilegedAccess (boolean) --
Grants the calling principal the permissions to perform all supported Lake Formation operations on the registered data location.
NextToken (string) --
A continuation token, if this is not the first call to retrieve these resources.
{'WithPrivilegedAccess': 'boolean'}
Registers the resource as managed by the Data Catalog.
To add or update data, Lake Formation needs read/write access to the chosen data location. Choose a role that you know has permission to do this, or choose the AWSServiceRoleForLakeFormationDataAccess service-linked role. When you register the first Amazon S3 path, the service-linked role and a new inline policy are created on your behalf. Lake Formation adds the first path to the inline policy and attaches it to the service-linked role. When you register subsequent paths, Lake Formation adds the path to the existing policy.
The following request registers a new location and gives Lake Formation permission to use the service-linked role to access that location.
ResourceArn = arn:aws:s3:::my-bucket/ UseServiceLinkedRole = true
If UseServiceLinkedRole is not set to true, you must provide or set the RoleArn:
arn:aws:iam::12345:role/my-data-access-role
See also: AWS API Documentation
Request Syntax
client.register_resource( ResourceArn='string', UseServiceLinkedRole=True|False, RoleArn='string', WithFederation=True|False, HybridAccessEnabled=True|False, WithPrivilegedAccess=True|False )
string
[REQUIRED]
The Amazon Resource Name (ARN) of the resource that you want to register.
boolean
Designates an Identity and Access Management (IAM) service-linked role by registering this role with the Data Catalog. A service-linked role is a unique type of IAM role that is linked directly to Lake Formation.
For more information, see Using Service-Linked Roles for Lake Formation.
string
The identifier for the role that registers the resource.
boolean
Whether or not the resource is a federated resource.
boolean
Specifies whether the data access of tables pointing to the location can be managed by both Lake Formation permissions as well as Amazon S3 bucket policies.
boolean
Grants the calling principal the permissions to perform all supported Lake Formation operations on the registered data location.
dict
Response Syntax
{}
Response Structure
(dict) --
{'Condition': {'Expression': 'string'}}
Revokes permissions to the principal to access metadata in the Data Catalog and data organized in underlying data storage such as Amazon S3.
See also: AWS API Documentation
Request Syntax
client.revoke_permissions( CatalogId='string', Principal={ 'DataLakePrincipalIdentifier': 'string' }, Resource={ 'Catalog': { 'Id': 'string' }, 'Database': { 'CatalogId': 'string', 'Name': 'string' }, 'Table': { 'CatalogId': 'string', 'DatabaseName': 'string', 'Name': 'string', 'TableWildcard': {} }, 'TableWithColumns': { 'CatalogId': 'string', 'DatabaseName': 'string', 'Name': 'string', 'ColumnNames': [ 'string', ], 'ColumnWildcard': { 'ExcludedColumnNames': [ 'string', ] } }, 'DataLocation': { 'CatalogId': 'string', 'ResourceArn': 'string' }, 'DataCellsFilter': { 'TableCatalogId': 'string', 'DatabaseName': 'string', 'TableName': 'string', 'Name': 'string' }, 'LFTag': { 'CatalogId': 'string', 'TagKey': 'string', 'TagValues': [ 'string', ] }, 'LFTagPolicy': { 'CatalogId': 'string', 'ResourceType': 'DATABASE'|'TABLE', 'Expression': [ { 'TagKey': 'string', 'TagValues': [ 'string', ] }, ], 'ExpressionName': 'string' }, 'LFTagExpression': { 'CatalogId': 'string', 'Name': 'string' } }, Permissions=[ 'ALL'|'SELECT'|'ALTER'|'DROP'|'DELETE'|'INSERT'|'DESCRIBE'|'CREATE_DATABASE'|'CREATE_TABLE'|'DATA_LOCATION_ACCESS'|'CREATE_LF_TAG'|'ASSOCIATE'|'GRANT_WITH_LF_TAG_EXPRESSION'|'CREATE_LF_TAG_EXPRESSION'|'CREATE_CATALOG'|'SUPER_USER', ], Condition={ 'Expression': 'string' }, PermissionsWithGrantOption=[ 'ALL'|'SELECT'|'ALTER'|'DROP'|'DELETE'|'INSERT'|'DESCRIBE'|'CREATE_DATABASE'|'CREATE_TABLE'|'DATA_LOCATION_ACCESS'|'CREATE_LF_TAG'|'ASSOCIATE'|'GRANT_WITH_LF_TAG_EXPRESSION'|'CREATE_LF_TAG_EXPRESSION'|'CREATE_CATALOG'|'SUPER_USER', ] )
string
The identifier for the Data Catalog. By default, the account ID. The Data Catalog is the persistent metadata store. It contains database definitions, table definitions, and other control information to manage your Lake Formation environment.
dict
[REQUIRED]
The principal to be revoked permissions on the resource.
DataLakePrincipalIdentifier (string) --
An identifier for the Lake Formation principal.
dict
[REQUIRED]
The resource to which permissions are to be revoked.
Catalog (dict) --
The identifier for the Data Catalog. By default, the account ID. The Data Catalog is the persistent metadata store. It contains database definitions, table definitions, and other control information to manage your Lake Formation environment.
Id (string) --
An identifier for the catalog resource.
Database (dict) --
The database for the resource. Unique to the Data Catalog. A database is a set of associated table definitions organized into a logical group. You can Grant and Revoke database permissions to a principal.
CatalogId (string) --
The identifier for the Data Catalog. By default, it is the account ID of the caller.
Name (string) -- [REQUIRED]
The name of the database resource. Unique to the Data Catalog.
Table (dict) --
The table for the resource. A table is a metadata definition that represents your data. You can Grant and Revoke table privileges to a principal.
CatalogId (string) --
The identifier for the Data Catalog. By default, it is the account ID of the caller.
DatabaseName (string) -- [REQUIRED]
The name of the database for the table. Unique to a Data Catalog. A database is a set of associated table definitions organized into a logical group. You can Grant and Revoke database privileges to a principal.
Name (string) --
The name of the table.
TableWildcard (dict) --
A wildcard object representing every table under a database.
At least one of TableResource$Name or TableResource$TableWildcard is required.
TableWithColumns (dict) --
The table with columns for the resource. A principal with permissions to this resource can select metadata from the columns of a table in the Data Catalog and the underlying data in Amazon S3.
CatalogId (string) --
The identifier for the Data Catalog. By default, it is the account ID of the caller.
DatabaseName (string) -- [REQUIRED]
The name of the database for the table with columns resource. Unique to the Data Catalog. A database is a set of associated table definitions organized into a logical group. You can Grant and Revoke database privileges to a principal.
Name (string) -- [REQUIRED]
The name of the table resource. A table is a metadata definition that represents your data. You can Grant and Revoke table privileges to a principal.
ColumnNames (list) --
The list of column names for the table. At least one of ColumnNames or ColumnWildcard is required.
(string) --
ColumnWildcard (dict) --
A wildcard specified by a ColumnWildcard object. At least one of ColumnNames or ColumnWildcard is required.
ExcludedColumnNames (list) --
Excludes column names. Any column with this name will be excluded.
(string) --
DataLocation (dict) --
The location of an Amazon S3 path where permissions are granted or revoked.
CatalogId (string) --
The identifier for the Data Catalog where the location is registered with Lake Formation. By default, it is the account ID of the caller.
ResourceArn (string) -- [REQUIRED]
The Amazon Resource Name (ARN) that uniquely identifies the data location resource.
DataCellsFilter (dict) --
A data cell filter.
TableCatalogId (string) --
The ID of the catalog to which the table belongs.
DatabaseName (string) --
A database in the Glue Data Catalog.
TableName (string) --
The name of the table.
Name (string) --
The name of the data cells filter.
LFTag (dict) --
The LF-tag key and values attached to a resource.
CatalogId (string) --
The identifier for the Data Catalog. By default, the account ID. The Data Catalog is the persistent metadata store. It contains database definitions, table definitions, and other control information to manage your Lake Formation environment.
TagKey (string) -- [REQUIRED]
The key-name for the LF-tag.
TagValues (list) -- [REQUIRED]
A list of possible values an attribute can take.
(string) --
LFTagPolicy (dict) --
A list of LF-tag conditions or saved LF-Tag expressions that define a resource's LF-tag policy.
CatalogId (string) --
The identifier for the Data Catalog. By default, the account ID. The Data Catalog is the persistent metadata store. It contains database definitions, table definitions, and other control information to manage your Lake Formation environment.
ResourceType (string) -- [REQUIRED]
The resource type for which the LF-tag policy applies.
Expression (list) --
A list of LF-tag conditions or a saved expression that apply to the resource's LF-tag policy.
(dict) --
A structure that allows an admin to grant user permissions on certain conditions. For example, granting a role access to all columns that do not have the LF-tag 'PII' in tables that have the LF-tag 'Prod'.
TagKey (string) -- [REQUIRED]
The key-name for the LF-tag.
TagValues (list) -- [REQUIRED]
A list of possible values an attribute can take.
The maximum number of values that can be defined for a LF-Tag is 1000. A single API call supports 50 values. You can use multiple API calls to add more values.
(string) --
ExpressionName (string) --
If provided, permissions are granted to the Data Catalog resources whose assigned LF-Tags match the expression body of the saved expression under the provided ExpressionName.
LFTagExpression (dict) --
LF-Tag expression resource. A logical expression composed of one or more LF-Tag key:value pairs.
CatalogId (string) --
The identifier for the Data Catalog. By default, the account ID.
Name (string) -- [REQUIRED]
The name of the LF-Tag expression to grant permissions on.
list
[REQUIRED]
The permissions revoked to the principal on the resource. For information about permissions, see Security and Access Control to Metadata and Data.
(string) --
dict
A Lake Formation condition, which applies to permissions and opt-ins that contain an expression.
Expression (string) --
An expression written based on the Cedar Policy Language used to match the principal attributes.
list
Indicates a list of permissions for which to revoke the grant option allowing the principal to pass permissions to other principals.
(string) --
dict
Response Syntax
{}
Response Structure
(dict) --