Skip to main content
Operations for managing studios (production companies). Bases: StashClientProtocol Mixin for studio-related client methods.

Functions

find_studio

Find a studio by its ID. Parameters: Returns:

find_studios

Find studios matching the given filters. Parameters: Returns:

create_studio

Create a new studio in Stash. Parameters: Returns: Raises:

update_studio

Update an existing studio in Stash. Parameters: Returns: Raises:

studio_destroy

Delete a studio. Parameters: Returns: Raises:

studios_destroy

Delete multiple studios. Parameters: Returns: Raises:

bulk_studio_update

Bulk update studios. Parameters: Returns:

find_studio_hierarchy

Get full parent chain from root to this studio. Recursively traverses the parent_studio relationship to build a complete hierarchy from the root studio down to the specified studio. Parameters: Returns: Examples: Get studio hierarchy:
Check if studio has parents:

find_studio_root

Find the top-level parent studio. Traverses the parent chain to find the root studio (the one with no parent). Parameters: Returns: Examples: Get root studio:
Compare studio with its root:

map_studio_ids

Convert studio names/objects to IDs, optionally creating missing studios. This is a convenience method to resolve studio references to their IDs, reducing boilerplate when working with studio relationships. Parameters: Returns: Examples: Map studio names to IDs:
Auto-create missing studios:
Mix of strings and Studio objects:
Use in scene creation: