snowflake.core.artifact_repository.ArtifactRepositoryResource¶
- class snowflake.core.artifact_repository.ArtifactRepositoryResource(name: str, collection_class: ArtifactRepositoryCollectionBase)¶
Bases:
ArtifactRepositoryResourceBaseRepresents a reference to a Snowflake artifact repository.
With this artifact repository reference, you can fetch information about an artifact repository, as well as perform certain actions on it.
Attributes
- database¶
The DatabaseResource this reference belongs to.
- fully_qualified_name¶
Return the fully qualified name of the object this reference points to.
- root¶
The Root object this reference belongs to.
Methods
- create_or_alter(artifact_repository: ArtifactRepository) None¶
Create or update an artifact repository.
- Parameters:
artifact_repository (ArtifactRepository) – (required)
- create_or_alter_async(artifact_repository: ArtifactRepository) PollingOperation[None]¶
An asynchronous version of
create_or_alter().Refer to
PollingOperationfor more information on asynchronous execution and the return type.
- drop(if_exists: bool | None = None) None¶
Delete an artifact repository.
- Parameters:
if_exists (bool) – Parameter that specifies how to handle the request for a resource that does not exist: - true: The endpoint does not throw an error if the resource does not exist. It returns a 200 success response, but does not take any action on the resource. - false: The endpoint throws an error if the resource doesn’t exist.
- drop_async(if_exists: bool | None = None) PollingOperation[None]¶
An asynchronous version of
drop().Refer to
PollingOperationfor more information on asynchronous execution and the return type.
- fetch() ArtifactRepository¶
Fetch an artifact repository.
- fetch_async() PollingOperation[ArtifactRepository]¶
An asynchronous version of
fetch().Refer to
PollingOperationfor more information on asynchronous execution and the return type.
- rename(target_name: str, if_exists: bool | None = None, target_database: str | None = None, target_schema: str | None = None) None¶
Changes the name of an artifact repository.
- Parameters:
target_name (str) – Name of the target resource. (required)
if_exists (bool) – Parameter that specifies how to handle the request for a resource that does not exist: - true: The endpoint does not throw an error if the resource does not exist. It returns a 200 success response, but does not take any action on the resource. - false: The endpoint throws an error if the resource doesn’t exist.
target_database (str) – Database of the target resource. Defaults to the source’s database
target_schema (str) – Schema of the target resource. Defaults to the source’s schema
- rename_async(target_name: str, if_exists: bool | None = None, target_database: str | None = None, target_schema: str | None = None) PollingOperation[None]¶
An asynchronous version of
rename().Refer to
PollingOperationfor more information on asynchronous execution and the return type.