You are viewing documentation about an older version (0.9.0). View latest version

snowflake.core.grant.Grants

class snowflake.core.grant.Grants(root: Root)

Bases: object

The entry point of the Snowflake Core Python APIs to manage Snowflake Grants.

Parameters:

root – A Root instance.

Methods

__init__(root: Root) None
grant(grant: Grant) None

Grant the specified privilege(s) on the named securable to the named grantee.

Parameters:

grant – an instance of Grant

Example

Apply a grant to test role >>> root.grants.apply(Grant( >>> grantee=Grantees.role(name=role_name), >>> securable=Securables.current_account, >>> privileges=[Privileges.create_database]))