> ## Documentation Index
> Fetch the complete documentation index at: https://docs.jakan.co/llms.txt
> Use this file to discover all available pages before exploring further.

# Types

> Type definitions and utilities for Stash entities.

Type definitions and utilities for Stash entities.

## Importing types

`stash_graphql_client.types` is the canonical, complete, flat import surface for every public schema type, input, enum, filter, and relationship helper. Anything in this package is importable directly from it — `from stash_graphql_client.types import GenderEnum, CustomFieldsInput, VideoFile, FileFilterType` — without reaching into the individual submodules (`.types.enums`, `.types.files`, `.types.metadata`, ...). Submodule paths still work, but `.types` is the supported, stable location and the only one that round-trips cleanly under mypy's `no-implicit-reexport`.

The top-level `stash_graphql_client` package deliberately re-exports only the curated essentials — the client, store, errors, logging, the core entity types and their create/update inputs, and the `UNSET` / `UnsetType` / `is_set` helpers. For everything else, import from `stash_graphql_client.types`. So the rule of thumb is: reach for the top-level package for the common path, and `stash_graphql_client.types` for the full type surface.

## Base Types

### StashObject

Bases: `FromGraphQLMixin`, `BaseModel`

Base interface for our Stash model implementations.

While this is not a schema interface, it represents a common pattern in the schema where many types have id, created\_at, and updated\_at fields. We use this interface to provide common functionality for these types.

Common fields (matching schema pattern): - id: Unique identifier (ID!) Note: created\_at and updated\_at are handled by Stash internally

Common functionality provided: - find\_by\_id: Find object by ID - save: Save object to Stash - to\_input: Convert to GraphQL input type - is\_dirty: Check if object has unsaved changes - mark\_clean: Mark object as having no unsaved changes - mark\_dirty: Mark object as having unsaved changes

Identity Map Integration: - Direct `Foo(id=...)` stub construction is intercepted at the metaclass level (`_StashObjectMeta.__call__`) for cache lookup, restoring the same-id-yields-same-object guarantee for `__init__` callers and eliminating Pydantic's "validator returning non-self" warning. - For multi-field construction or new server data, `from_dict` / `from_graphql` use `model_validate` and run the wrap validator's full merge logic.

#### Attributes

##### model\_config

```python theme={null}
model_config = ConfigDict(
    arbitrary_types_allowed=True,
    extra="allow",
    validate_assignment=True,
    populate_by_name=True,
)
```

##### id

```python theme={null}
id: str = ''
```

##### created\_at

```python theme={null}
created_at: Time | UnsetType = UNSET
```

##### updated\_at

```python theme={null}
updated_at: Time | UnsetType = UNSET
```

#### Functions

##### new

```python theme={null}
new(**data: Any) -> T
```

Create a new object that hasn't been saved to the server yet.

This is a convenience method that creates a new instance without providing an 'id', which triggers UUID4 auto-generation and sets \_is\_new=True.

This is equivalent to calling the constructor without an 'id' field, but makes the intent more explicit in the code.

Parameters:

| Name     | Type  | Description                                      | Default |
| -------- | ----- | ------------------------------------------------ | ------- |
| `**data` | `Any` | Field values for the new object (excluding 'id') | `{}`    |

Returns:

| Type | Description                                               |
| ---- | --------------------------------------------------------- |
| `T`  | New instance with auto-generated UUID4 and \_is\_new=True |

<Note>
  **Example**

  > > > tag = Tag.new(name="New Tag", description="A new tag") tag.is\_new() # True tag.id # '3fa85f6457174562b3fc2c963f66afa6' (UUID4 hex)
</Note>

##### is\_new

```python theme={null}
is_new() -> bool
```

Check if this is a new object not yet saved to the server.

Uses the \_is\_new flag which is set during initialization for new objects or when explicitly creating new objects with UUID4 identifiers.

Returns:

| Type   | Description                                          |
| ------ | ---------------------------------------------------- |
| `bool` | True if this object has not been saved to the server |

##### update\_id

```python theme={null}
update_id(server_id: str) -> None
```

Update the temporary UUID with the server-assigned ID.

This should be called after a successful create operation to replace the auto-generated UUID with the permanent ID from the server. Also marks the object as no longer new.

Parameters:

| Name        | Type  | Description                                   | Default    |
| ----------- | ----- | --------------------------------------------- | ---------- |
| `server_id` | `str` | The permanent ID assigned by the Stash server | *required* |

<Note>
  **Example**

  > > > scene = Scene(title="Example") # Auto-generates UUID scene.id # "a1b2c3d4e5f6..." scene.\_is\_new # True await scene.save(client) # Server assigns ID "123" scene.id # "123" scene.\_is\_new # False
</Note>

##### model\_post\_init

```python theme={null}
model_post_init(_context: Any) -> None
```

Initialize object and store snapshot after Pydantic init.

This is called by Pydantic after all fields are initialized, so it's the right place to capture the initial state for dirty tracking.

Parameters:

| Name       | Type  | Description                                         | Default    |
| ---------- | ----- | --------------------------------------------------- | ---------- |
| `_context` | `Any` | Pydantic context (unused but required by signature) | *required* |

##### is\_dirty

```python theme={null}
is_dirty() -> bool
```

Check if tracked fields have unsaved changes.

Compares current field values with snapshot using object identity for StashObjects to avoid circular reference errors during comparison.

Returns:

| Type   | Description                                               |
| ------ | --------------------------------------------------------- |
| `bool` | True if any tracked field has changed since last snapshot |

##### get\_changed\_fields

```python theme={null}
get_changed_fields() -> dict[str, Any]
```

Get fields that have changed since last snapshot.

Returns:

| Type             | Description                                                    |
| ---------------- | -------------------------------------------------------------- |
| `dict[str, Any]` | Dictionary of field names to current values for changed fields |

##### mark\_clean

```python theme={null}
mark_clean() -> None
```

Mark object as having no unsaved changes.

Updates the snapshot to match the current state and clears any pending queued side operations.

##### mark\_dirty

```python theme={null}
mark_dirty() -> None
```

Mark object as having unsaved changes.

Clears the snapshot to force all tracked fields to be considered dirty.

##### set\_primary\_file

```python theme={null}
set_primary_file(file: Any) -> None
```

Designate the primary file for this entity.

Parameters:

| Name   | Type  | Description              | Default    |
| ------ | ----- | ------------------------ | ---------- |
| `file` | `Any` | A file entity or its id. | *required* |

Raises:

| Type                  | Description                              |
| --------------------- | ---------------------------------------- |
| `NotImplementedError` | This entity type has no file collection. |

##### find\_by\_id

```python theme={null}
find_by_id(client: StashClient, id: str) -> T | None
```

Find object by ID.

Parameters:

| Name     | Type          | Description          | Default    |
| -------- | ------------- | -------------------- | ---------- |
| `client` | `StashClient` | StashClient instance | *required* |
| `id`     | `str`         | Object ID            | *required* |

Returns:

| Type        | Description                              |
| ----------- | ---------------------------------------- |
| `T \| None` | Object instance if found, None otherwise |

##### save

```python theme={null}
save(client: StashClient) -> None
```

Save object to Stash.

For new objects (created without a server ID), this performs a create operation and updates the temporary UUID with the server-assigned ID.

For existing objects, this performs an update operation, but only if there are dirty (changed) fields.

Side mutations (**side\_mutations**) are fired AFTER the main mutation so that new objects already have their server-assigned ID. Side-mutation fields are excluded from the main create/update input. When multiple fields map to the same handler (e.g., resume\_time and play\_duration both map to \_save\_activity), the handler is deduplicated and fires once.

Queued operations (\_pending\_side\_ops) fire after field-based side mutations. These are closures queued by entity methods like `increment_o()` or `reset_play_count()`.

Parameters:

| Name     | Type          | Description          | Default    |
| -------- | ------------- | -------------------- | ---------- |
| `client` | `StashClient` | StashClient instance | *required* |

Raises:

| Type         | Description   |
| ------------ | ------------- |
| `ValueError` | If save fails |

##### delete

```python theme={null}
delete(client: StashClient, **kwargs: Any) -> bool
```

Delete this object from Stash and invalidate from cache.

Builds a destroy input from `__destroy_input_type__` and executes the corresponding GraphQL destroy mutation. Extra keyword arguments are merged into the destroy input (e.g., `delete_file=True`).

Parameters:

| Name       | Type          | Description                                                             | Default    |
| ---------- | ------------- | ----------------------------------------------------------------------- | ---------- |
| `client`   | `StashClient` | StashClient instance                                                    | *required* |
| `**kwargs` | `Any`         | Additional destroy input fields (e.g., delete\_file, delete\_generated) | `{}`       |

Returns:

| Type   | Description                                 |
| ------ | ------------------------------------------- |
| `bool` | True if the object was successfully deleted |

Raises:

| Type                  | Description                                    |
| --------------------- | ---------------------------------------------- |
| `NotImplementedError` | If the type has no **destroy\_input\_type**    |
| `ValueError`          | If the object has no server ID or delete fails |

Examples:

```python theme={null}
>>> await scene.delete(client)
>>> await scene.delete(client, delete_file=True)
```

##### bulk\_destroy

```python theme={null}
bulk_destroy(
    client: StashClient, ids: list[str], **kwargs: Any
) -> bool
```

Delete multiple objects of this type from Stash.

Uses the bulk destroy mutation (e.g., `scenesDestroy`, `tagsDestroy`). Types with `__bulk_destroy_input_type__` use an input object; others use the bare `ids` parameter pattern.

Parameters:

| Name       | Type          | Description                                          | Default    |
| ---------- | ------------- | ---------------------------------------------------- | ---------- |
| `client`   | `StashClient` | StashClient instance                                 | *required* |
| `ids`      | `list[str]`   | List of entity IDs to delete                         | *required* |
| `**kwargs` | `Any`         | Additional destroy input fields (e.g., delete\_file) | `{}`       |

Returns:

| Type   | Description                  |
| ------ | ---------------------------- |
| `bool` | True if successfully deleted |

Raises:

| Type         | Description     |
| ------------ | --------------- |
| `ValueError` | If delete fails |

Examples:

```python theme={null}
>>> await Scene.bulk_destroy(client, ["1", "2", "3"])
>>> await Scene.bulk_destroy(client, ["1", "2"], delete_file=True)
```

##### merge

```python theme={null}
merge(
    client: StashClient,
    source_ids: list[str],
    destination_id: str,
    **kwargs: Any,
) -> Self | None
```

Merge source entities into a destination entity.

Not implemented on the base class: a generic selection set built from field names is invalid GraphQL for any type with nested object fields. Mergeable types (Tag, Scene, Performer) override this with their own fragment-backed mutation via `_merge_via`; every other type does not support merge.

Raises:

| Type                  | Description                             |
| --------------------- | --------------------------------------- |
| `NotImplementedError` | always — overridden by mergeable types. |

##### to\_input

```python theme={null}
to_input() -> dict[str, Any]
```

Convert to GraphQL input type.

For new objects (with temporary UUID), includes all fields. For existing objects, includes only dirty (changed) fields plus ID.

Fields with value UNSET are excluded from the input to avoid overwriting server values that were never touched locally.

Returns:

| Type             | Description                                                       |
| ---------------- | ----------------------------------------------------------------- |
| `dict[str, Any]` | Dictionary of input fields. For new objects, all non-UNSET fields |
| `dict[str, Any]` | are included. For existing objects, only changed fields plus ID.  |

### StashInput

Bases: `BaseModel`

Base class for all Stash GraphQL input types.

Configures Pydantic to accept both Python snake\_case field names and GraphQL aliases during construction, while serializing to GraphQL field names using Field aliases and by\_alias=True.

This allows tests and Python code to use Pythonic naming conventions while ensuring GraphQL compatibility.

Capability Gating (`__safe_to_eat__`): Subclasses may declare a `__safe_to_eat__` class variable containing GraphQL field names (as they appear in the schema) that are known to be absent on older server versions. When `to_graphql()` detects that the server schema lacks one of these fields, it silently strips it (with a warning) instead of raising. Unsupported fields **not** in `__safe_to_eat__` raise `ValueError`.

<Note>
  **Example**

  ```python theme={null}
  class MyInput(StashInput):
      my_field: str = Field(alias="myField")

  # Both work during construction:
  MyInput(my_field="value")    # Python style
  MyInput(myField="value")     # GraphQL style

  # Serialization always uses GraphQL style:
  obj.to_graphql()  # {"myField": "value"}
  ```
</Note>

#### Attributes

##### model\_config

```python theme={null}
model_config = ConfigDict(
    populate_by_name=True,
    ser_json_inf_nan="constants",
    extra="allow",
)
```

#### Functions

##### to\_graphql

```python theme={null}
to_graphql() -> dict[str, Any]
```

Convert to GraphQL-compatible dictionary.

Excludes UNSET sentinel values but keeps None (null) values. This allows: - UNSET fields to be omitted from the request (not sent to GraphQL) - None fields to explicitly clear/null values in GraphQL - Regular values to be sent normally

After building the dict, applies capability gating: if the `fragment_store` has detected server capabilities, every key is checked against the server schema. Fields listed in `__safe_to_eat__` are silently stripped (with a warning) when the server doesn't support them; other unsupported fields raise `ValueError`.

Returns:

| Type             | Description                                                      |
| ---------------- | ---------------------------------------------------------------- |
| `dict[str, Any]` | Dictionary ready to send to GraphQL API with GraphQL field names |

<Note>
  **Example**

  ```python theme={null}
  from .unset import UNSET

  input_obj = SceneUpdateInput(
      title="New Title",  # Send this value
      rating=None,         # Send null (clear rating)
      url=UNSET            # Don't send at all
  )
  result = input_obj.to_graphql()
  # {'title': 'New Title', 'rating': None}  # url excluded
  ```
</Note>

### StashResult

Bases: `FromGraphQLMixin`, `BaseModel`

Base class for all Stash GraphQL result/output types.

Result types wrap collections of entities returned from list queries like findScenes, findPerformers, etc.

Example result types: - FindScenesResultType - FindPerformersResultType - StatsResultType

#### Attributes

##### model\_config

```python theme={null}
model_config = ConfigDict(populate_by_name=True)
```

## Core Entity Types

### Scene

Bases: `StashObject`

Scene type from schema/types/scene.graphql.

Note: Inherits from StashObject for implementation convenience, not because Scene implements any interface in the schema. StashObject provides common functionality like find\_by\_id, save, and to\_input methods.

#### Attributes

##### title

```python theme={null}
title: str | None | UnsetType = UNSET
```

##### code

```python theme={null}
code: str | None | UnsetType = UNSET
```

##### details

```python theme={null}
details: str | None | UnsetType = UNSET
```

##### director

```python theme={null}
director: str | None | UnsetType = UNSET
```

##### date

```python theme={null}
date: str | None | UnsetType = UNSET
```

##### rating100

```python theme={null}
rating100: int | None | UnsetType = Field(
    default=UNSET, ge=0, le=100
)
```

##### o\_counter

```python theme={null}
o_counter: int | None | UnsetType = Field(
    default=UNSET, ge=0
)
```

##### studio

```python theme={null}
studio: Studio | None | UnsetType = UNSET
```

##### interactive

```python theme={null}
interactive: bool | None | UnsetType = UNSET
```

##### interactive\_speed

```python theme={null}
interactive_speed: int | None | UnsetType = UNSET
```

##### last\_played\_at

```python theme={null}
last_played_at: Time | None | UnsetType = UNSET
```

##### resume\_time

```python theme={null}
resume_time: float | None | UnsetType = UNSET
```

##### play\_duration

```python theme={null}
play_duration: float | None | UnsetType = UNSET
```

##### play\_count

```python theme={null}
play_count: int | None | UnsetType = Field(
    default=UNSET, ge=0
)
```

##### play\_history

```python theme={null}
play_history: list[Time] | None | UnsetType = UNSET
```

##### o\_history

```python theme={null}
o_history: list[Time] | None | UnsetType = UNSET
```

##### urls

```python theme={null}
urls: list[str] | UnsetType = UNSET
```

##### organized

```python theme={null}
organized: bool | UnsetType = UNSET
```

##### files

```python theme={null}
files: list[VideoFile] | UnsetType = UNSET
```

##### primary\_file\_id

```python theme={null}
primary_file_id: str | None | UnsetType = UNSET
```

##### paths

```python theme={null}
paths: ScenePathsType | UnsetType = UNSET
```

##### scene\_markers

```python theme={null}
scene_markers: list[SceneMarker] | UnsetType = UNSET
```

##### galleries

```python theme={null}
galleries: list[Gallery] | UnsetType = UNSET
```

##### groups

```python theme={null}
groups: list[SceneGroup] | UnsetType = UNSET
```

##### tags

```python theme={null}
tags: list[Tag] | UnsetType = UNSET
```

##### performers

```python theme={null}
performers: list[Performer] | UnsetType = UNSET
```

##### stash\_ids

```python theme={null}
stash_ids: list[StashID] | UnsetType = UNSET
```

##### scene\_streams

```python theme={null}
scene_streams: list[SceneStreamEndpoint] | UnsetType = (
    Field(default=UNSET, alias="sceneStreams")
)
```

##### captions

```python theme={null}
captions: list[VideoCaption] | None | UnsetType = UNSET
```

##### custom\_fields

```python theme={null}
custom_fields: Map | UnsetType = UNSET
```

#### Functions

##### merge

```python theme={null}
merge(
    client: StashClient,
    source_ids: list[str],
    destination_id: str,
    **kwargs: Any,
) -> Scene | None
```

Merge source scenes into the destination scene (`sceneMerge`).

##### set\_primary\_file

```python theme={null}
set_primary_file(file: Any) -> None
```

Designate a file as primary (reorders `files` primary-first).

Parameters:

| Name   | Type  | Description                                                                            | Default    |
| ------ | ----- | -------------------------------------------------------------------------------------- | ---------- |
| `file` | `Any` | A VideoFile or its id; must be among this scene's files when the collection is loaded. | *required* |

##### reset\_play\_count

```python theme={null}
reset_play_count() -> None
```

Queue resetting play count to 0. Call save() to persist.

##### reset\_o

```python theme={null}
reset_o() -> None
```

Queue resetting o-counter to 0. Call save() to persist.

##### reset\_activity

```python theme={null}
reset_activity(
    reset_resume: bool = True, reset_duration: bool = True
) -> None
```

Queue resetting activity data. Call save() to persist.

##### generate\_screenshot

```python theme={null}
generate_screenshot(at: float | None = None) -> None
```

Queue screenshot generation. Call save() to persist.

##### add\_to\_gallery

```python theme={null}
add_to_gallery(gallery: Gallery) -> None
```

Add scene to gallery (syncs inverse automatically, call save() to persist).

##### remove\_from\_gallery

```python theme={null}
remove_from_gallery(gallery: Gallery) -> None
```

Remove scene from gallery (syncs inverse automatically, call save() to persist).

##### add\_performer

```python theme={null}
add_performer(performer: Performer) -> None
```

Add performer to scene (syncs inverse automatically, call save() to persist).

##### remove\_performer

```python theme={null}
remove_performer(performer: Performer) -> None
```

Remove performer from scene (syncs inverse automatically, call save() to persist).

##### add\_tag

```python theme={null}
add_tag(tag: Tag) -> None
```

Add tag to scene (syncs inverse automatically, call save() to persist).

##### remove\_tag

```python theme={null}
remove_tag(tag: Tag) -> None
```

Remove tag from scene (syncs inverse automatically, call save() to persist).

##### set\_studio

```python theme={null}
set_studio(studio: Studio | None) -> None
```

Set scene studio (call save() to persist).

### Performer

Bases: `StashObject`

Performer type from schema/types/performer.graphql.

#### Attributes

##### name

```python theme={null}
name: str | UnsetType = UNSET
```

##### alias\_list

```python theme={null}
alias_list: list[str] | UnsetType = UNSET
```

##### tags

```python theme={null}
tags: list[Tag] | UnsetType = UNSET
```

##### stash\_ids

```python theme={null}
stash_ids: list[StashID] | UnsetType = UNSET
```

##### scenes

```python theme={null}
scenes: list[Scene] | UnsetType = UNSET
```

##### groups

```python theme={null}
groups: list[Group] | UnsetType = UNSET
```

##### galleries

```python theme={null}
galleries: list[Gallery] | UnsetType = UNSET
```

##### images

```python theme={null}
images: list[Image] | UnsetType = UNSET
```

##### favorite

```python theme={null}
favorite: bool | UnsetType = UNSET
```

##### ignore\_auto\_tag

```python theme={null}
ignore_auto_tag: bool | UnsetType = UNSET
```

##### scene\_count

```python theme={null}
scene_count: int | UnsetType = Field(default=UNSET, ge=0)
```

##### image\_count

```python theme={null}
image_count: int | UnsetType = Field(default=UNSET, ge=0)
```

##### gallery\_count

```python theme={null}
gallery_count: int | UnsetType = Field(default=UNSET, ge=0)
```

##### group\_count

```python theme={null}
group_count: int | UnsetType = Field(default=UNSET, ge=0)
```

##### performer\_count

```python theme={null}
performer_count: int | UnsetType = Field(
    default=UNSET, ge=0
)
```

##### custom\_fields

```python theme={null}
custom_fields: Map | UnsetType = UNSET
```

##### disambiguation

```python theme={null}
disambiguation: str | None | UnsetType = UNSET
```

##### urls

```python theme={null}
urls: list[str] | UnsetType = UNSET
```

##### gender

```python theme={null}
gender: GenderEnum | None | UnsetType = UNSET
```

##### birthdate

```python theme={null}
birthdate: str | None | UnsetType = UNSET
```

##### rating100

```python theme={null}
rating100: int | None | UnsetType = Field(
    default=UNSET, ge=0, le=100
)
```

##### ethnicity

```python theme={null}
ethnicity: str | None | UnsetType = UNSET
```

##### country

```python theme={null}
country: str | None | UnsetType = UNSET
```

##### eye\_color

```python theme={null}
eye_color: str | None | UnsetType = UNSET
```

##### height\_cm

```python theme={null}
height_cm: int | None | UnsetType = UNSET
```

##### measurements

```python theme={null}
measurements: str | None | UnsetType = UNSET
```

##### fake\_tits

```python theme={null}
fake_tits: str | None | UnsetType = UNSET
```

##### penis\_length

```python theme={null}
penis_length: float | None | UnsetType = UNSET
```

##### circumcised

```python theme={null}
circumcised: CircumcisedEnum | None | UnsetType = UNSET
```

##### career\_length

```python theme={null}
career_length: str | None | UnsetType = UNSET
```

##### tattoos

```python theme={null}
tattoos: str | None | UnsetType = UNSET
```

##### piercings

```python theme={null}
piercings: str | None | UnsetType = UNSET
```

##### image\_path

```python theme={null}
image_path: str | None | UnsetType = UNSET
```

##### details

```python theme={null}
details: str | None | UnsetType = UNSET
```

##### death\_date

```python theme={null}
death_date: str | None | UnsetType = UNSET
```

##### hair\_color

```python theme={null}
hair_color: str | None | UnsetType = UNSET
```

##### weight

```python theme={null}
weight: int | None | UnsetType = UNSET
```

##### o\_counter

```python theme={null}
o_counter: int | None | UnsetType = Field(
    default=UNSET, ge=0
)
```

##### career\_start

```python theme={null}
career_start: str | None | UnsetType = UNSET
```

##### career\_end

```python theme={null}
career_end: str | None | UnsetType = UNSET
```

#### Functions

##### merge

```python theme={null}
merge(
    client: StashClient,
    source_ids: list[str],
    destination_id: str,
    **kwargs: Any,
) -> Performer | None
```

Merge source performers into the destination (`performerMerge`).

##### update\_avatar

```python theme={null}
update_avatar(
    client: StashClient, image_path: str | Path
) -> Performer
```

Update performer's avatar image.

Parameters:

| Name         | Type          | Description                              | Default    |
| ------------ | ------------- | ---------------------------------------- | ---------- |
| `client`     | `StashClient` | "StashClient" instance to use for update | *required* |
| `image_path` | `str \| Path` | Path to image file to use as avatar      | *required* |

Returns:

| Type        | Description                                 |
| ----------- | ------------------------------------------- |
| `Performer` | Updated Performer object with the new image |

Raises:

| Type                | Description                                 |
| ------------------- | ------------------------------------------- |
| `FileNotFoundError` | If image file doesn't exist                 |
| `ValueError`        | If image file can't be read or update fails |

##### add\_tag

```python theme={null}
add_tag(tag: Tag) -> None
```

Add tag to performer (syncs inverse automatically, call save() to persist).

##### remove\_tag

```python theme={null}
remove_tag(tag: Tag) -> None
```

Remove tag from performer (syncs inverse automatically, call save() to persist).

##### add\_scene

```python theme={null}
add_scene(scene: Scene) -> None
```

Add scene (syncs inverse automatically, call save() to persist).

##### remove\_scene

```python theme={null}
remove_scene(scene: Scene) -> None
```

Remove scene (syncs inverse automatically, call save() to persist).

##### add\_gallery

```python theme={null}
add_gallery(gallery: Gallery) -> None
```

Add gallery (syncs inverse automatically, call save() to persist).

##### remove\_gallery

```python theme={null}
remove_gallery(gallery: Gallery) -> None
```

Remove gallery (syncs inverse automatically, call save() to persist).

##### add\_image

```python theme={null}
add_image(image: Image) -> None
```

Add image (syncs inverse automatically, call save() to persist).

##### remove\_image

```python theme={null}
remove_image(image: Image) -> None
```

Remove image (syncs inverse automatically, call save() to persist).

##### find\_by\_name

```python theme={null}
find_by_name(client: StashClient, name: str) -> T | None
```

Find performer by name.

Parameters:

| Name     | Type          | Description                  | Default    |
| -------- | ------------- | ---------------------------- | ---------- |
| `client` | `StashClient` | "StashClient" instance       | *required* |
| `name`   | `str`         | Performer name to search for | *required* |

Returns:

| Type        | Description                                 |
| ----------- | ------------------------------------------- |
| `T \| None` | Performer instance if found, None otherwise |

### Gallery

Bases: `StashObject`

Gallery type from schema/types/gallery.graphql.

#### Attributes

##### title

```python theme={null}
title: str | None | UnsetType = UNSET
```

##### code

```python theme={null}
code: str | None | UnsetType = UNSET
```

##### date

```python theme={null}
date: str | None | UnsetType = UNSET
```

##### details

```python theme={null}
details: str | None | UnsetType = UNSET
```

##### photographer

```python theme={null}
photographer: str | None | UnsetType = UNSET
```

##### rating100

```python theme={null}
rating100: int | None | UnsetType = Field(
    default=UNSET, ge=0, le=100
)
```

##### folder

```python theme={null}
folder: Folder | None | UnsetType = UNSET
```

##### studio

```python theme={null}
studio: Studio | None | UnsetType = UNSET
```

##### cover

```python theme={null}
cover: Image | None | UnsetType = UNSET
```

##### urls

```python theme={null}
urls: list[str] | UnsetType = UNSET
```

##### organized

```python theme={null}
organized: bool | UnsetType = UNSET
```

##### files

```python theme={null}
files: list[GalleryFile] | UnsetType = UNSET
```

##### primary\_file\_id

```python theme={null}
primary_file_id: str | None | UnsetType = UNSET
```

##### chapters

```python theme={null}
chapters: list[GalleryChapter] | UnsetType = UNSET
```

##### scenes

```python theme={null}
scenes: list[Scene] | UnsetType = UNSET
```

##### images

```python theme={null}
images: list[Image] | UnsetType = UNSET
```

##### image\_count

```python theme={null}
image_count: int | UnsetType = Field(default=UNSET, ge=0)
```

##### tags

```python theme={null}
tags: list[Tag] | UnsetType = UNSET
```

##### performers

```python theme={null}
performers: list[Performer] | UnsetType = UNSET
```

##### paths

```python theme={null}
paths: GalleryPathsType | UnsetType = UNSET
```

##### custom\_fields

```python theme={null}
custom_fields: Map | UnsetType = UNSET
```

#### Functions

##### image

```python theme={null}
image(index: int) -> Image
```

Get image at index from this gallery.

Uses the GraphQL `gallery.image(index)` resolver to fetch a specific image by its position in the gallery.

Parameters:

| Name    | Type  | Description                                  | Default    |
| ------- | ----- | -------------------------------------------- | ---------- |
| `index` | `int` | Zero-based index of the image in the gallery | *required* |

Returns:

| Type    | Description                         |
| ------- | ----------------------------------- |
| `Image` | Image object at the specified index |

Raises:

| Type           | Description                                        |
| -------------- | -------------------------------------------------- |
| `ValueError`   | If gallery ID is not set or index is out of bounds |
| `RuntimeError` | If no StashEntityStore is configured               |

Examples:

```python theme={null}
gallery = await client.find_gallery("123")

# Get first image
first_image = await gallery.image(0)

# Get last image (if you know the count)
if is_set(gallery.image_count):
    last_image = await gallery.image(gallery.image_count - 1)
```

##### add\_image

```python theme={null}
add_image(image: Image) -> None
```

Add image (syncs Image.galleries inverse, call save() to persist).

##### remove\_image

```python theme={null}
remove_image(image: Image) -> None
```

Remove image (syncs Image.galleries inverse, call save() to persist).

##### add\_performer

```python theme={null}
add_performer(performer: Performer) -> None
```

Add performer (syncs inverse automatically, call save() to persist).

##### remove\_performer

```python theme={null}
remove_performer(performer: Performer) -> None
```

Remove performer (syncs inverse automatically, call save() to persist).

##### add\_scene

```python theme={null}
add_scene(scene: Scene) -> None
```

Add scene (syncs inverse automatically, call save() to persist).

##### remove\_scene

```python theme={null}
remove_scene(scene: Scene) -> None
```

Remove scene (syncs inverse automatically, call save() to persist).

##### add\_tag

```python theme={null}
add_tag(tag: Tag) -> None
```

Add tag (syncs inverse automatically, call save() to persist).

##### remove\_tag

```python theme={null}
remove_tag(tag: Tag) -> None
```

Remove tag (syncs inverse automatically, call save() to persist).

##### set\_primary\_file

```python theme={null}
set_primary_file(file: Any) -> None
```

Designate a file as primary (reorders `files` primary-first).

Parameters:

| Name   | Type  | Description                                                                                | Default    |
| ------ | ----- | ------------------------------------------------------------------------------------------ | ---------- |
| `file` | `Any` | A GalleryFile or its id; must be among this gallery's files when the collection is loaded. | *required* |

### Image

Bases: `StashObject`

A single image or video-as-image file managed by Stash.

`visual_files` holds the underlying files as `list[VisualFile]` — a discriminated union of `VideoFile | ImageFile`.

`o_counter` uses a side-mutation handler (`_save_o_counter`). Set it to a new value and call `save()`; the client fires `imageIncrementO` / `imageDecrementO` / `imageResetO` mutations to reach the target value.

Images are created by Stash's scanner, not this client — there is no `ImageCreateInput`, only updates and destroys.

#### Attributes

##### title

```python theme={null}
title: str | None | UnsetType = UNSET
```

##### code

```python theme={null}
code: str | None | UnsetType = UNSET
```

##### date

```python theme={null}
date: str | None | UnsetType = UNSET
```

##### rating100

```python theme={null}
rating100: int | None | UnsetType = Field(
    default=UNSET, ge=0, le=100
)
```

##### details

```python theme={null}
details: str | None | UnsetType = UNSET
```

##### photographer

```python theme={null}
photographer: str | None | UnsetType = UNSET
```

##### studio

```python theme={null}
studio: Studio | None | UnsetType = UNSET
```

##### o\_counter

```python theme={null}
o_counter: int | None | UnsetType = Field(
    default=UNSET, ge=0
)
```

##### urls

```python theme={null}
urls: list[str] | UnsetType = Field(default=UNSET)
```

##### organized

```python theme={null}
organized: bool | UnsetType = UNSET
```

##### visual\_files

```python theme={null}
visual_files: list[VisualFile] | UnsetType = Field(
    default=UNSET
)
```

##### primary\_file\_id

```python theme={null}
primary_file_id: str | None | UnsetType = UNSET
```

##### paths

```python theme={null}
paths: ImagePathsType | UnsetType = Field(default=UNSET)
```

##### galleries

```python theme={null}
galleries: list[Gallery] | UnsetType = Field(default=UNSET)
```

##### tags

```python theme={null}
tags: list[Tag] | UnsetType = Field(default=UNSET)
```

##### performers

```python theme={null}
performers: list[Performer] | UnsetType = Field(
    default=UNSET
)
```

##### custom\_fields

```python theme={null}
custom_fields: Map | UnsetType = UNSET
```

#### Functions

##### set\_primary\_file

```python theme={null}
set_primary_file(file: Any) -> None
```

Designate a file as primary (reorders `visual_files` primary-first).

Parameters:

| Name   | Type  | Description                                                                                                              | Default    |
| ------ | ----- | ------------------------------------------------------------------------------------------------------------------------ | ---------- |
| `file` | `Any` | A VisualFile (VideoFile or ImageFile) or its id; must be among this image's visual\_files when the collection is loaded. | *required* |

##### add\_performer

```python theme={null}
add_performer(performer: Performer) -> None
```

Add performer (syncs inverse automatically, call save() to persist).

##### remove\_performer

```python theme={null}
remove_performer(performer: Performer) -> None
```

Remove performer (syncs inverse automatically, call save() to persist).

##### add\_to\_gallery

```python theme={null}
add_to_gallery(gallery: Gallery) -> None
```

Add gallery (syncs inverse automatically, call save() to persist).

##### remove\_from\_gallery

```python theme={null}
remove_from_gallery(gallery: Gallery) -> None
```

Remove gallery (syncs inverse automatically, call save() to persist).

##### add\_tag

```python theme={null}
add_tag(tag: Tag) -> None
```

Add tag (syncs inverse automatically, call save() to persist).

##### remove\_tag

```python theme={null}
remove_tag(tag: Tag) -> None
```

Remove tag (syncs inverse automatically, call save() to persist).

### Group

Bases: `StashObject`

Group type from schema.

#### Attributes

##### name

```python theme={null}
name: str | UnsetType = UNSET
```

##### urls

```python theme={null}
urls: list[str] | UnsetType = Field(default=UNSET)
```

##### tags

```python theme={null}
tags: list[Tag] | UnsetType = Field(default=UNSET)
```

##### containing\_groups

```python theme={null}
containing_groups: list[GroupDescription] | UnsetType = (
    Field(default=UNSET)
)
```

##### sub\_groups

```python theme={null}
sub_groups: list[GroupDescription] | UnsetType = Field(
    default=UNSET
)
```

##### scenes

```python theme={null}
scenes: list[Scene] | UnsetType = Field(default=UNSET)
```

##### aliases

```python theme={null}
aliases: str | None | UnsetType = UNSET
```

##### duration

```python theme={null}
duration: int | None | UnsetType = UNSET
```

##### date

```python theme={null}
date: str | None | UnsetType = UNSET
```

##### rating100

```python theme={null}
rating100: int | None | UnsetType = Field(
    default=UNSET, ge=0, le=100
)
```

##### studio

```python theme={null}
studio: Studio | None | UnsetType = UNSET
```

##### director

```python theme={null}
director: str | None | UnsetType = UNSET
```

##### synopsis

```python theme={null}
synopsis: str | None | UnsetType = UNSET
```

##### front\_image\_path

```python theme={null}
front_image_path: str | None | UnsetType = UNSET
```

##### back\_image\_path

```python theme={null}
back_image_path: str | None | UnsetType = UNSET
```

##### scene\_count

```python theme={null}
scene_count: int | None | UnsetType = Field(
    default=UNSET, ge=0
)
```

##### performer\_count

```python theme={null}
performer_count: int | None | UnsetType = Field(
    default=UNSET, ge=0
)
```

##### sub\_group\_count

```python theme={null}
sub_group_count: int | None | UnsetType = Field(
    default=UNSET, ge=0
)
```

##### o\_counter

```python theme={null}
o_counter: int | None | UnsetType = Field(
    default=UNSET, ge=0
)
```

##### custom\_fields

```python theme={null}
custom_fields: Map | UnsetType = UNSET
```

#### Functions

##### add\_sub\_group

```python theme={null}
add_sub_group(
    sub_group: Group | GroupDescription,
    description: str | None = None,
) -> None
```

Add sub-group (syncs inverse automatically, call save() to persist).

Parameters:

| Name          | Type                        | Description                                                                    | Default    |
| ------------- | --------------------------- | ------------------------------------------------------------------------------ | ---------- |
| `sub_group`   | `Group \| GroupDescription` | Either a Group object or a GroupDescription object                             | *required* |
| `description` | `str \| None`               | Optional description for the relationship (only used if sub\_group is a Group) | `None`     |

##### remove\_sub\_group

```python theme={null}
remove_sub_group(
    sub_group: Group | GroupDescription,
) -> None
```

Remove sub-group (syncs inverse automatically, call save() to persist).

Parameters:

| Name        | Type                        | Description                                                | Default    |
| ----------- | --------------------------- | ---------------------------------------------------------- | ---------- |
| `sub_group` | `Group \| GroupDescription` | Either a Group object or GroupDescription object to remove | *required* |

##### add\_containing\_group

```python theme={null}
add_containing_group(
    containing_group: Group | GroupDescription,
) -> None
```

Add containing group (syncs inverse automatically, call save() to persist).

Parameters:

| Name               | Type                        | Description                                                                                             | Default    |
| ------------------ | --------------------------- | ------------------------------------------------------------------------------------------------------- | ---------- |
| `containing_group` | `Group \| GroupDescription` | Either a Group object (will be wrapped with None description) or a GroupDescription object (used as-is) | *required* |

##### remove\_containing\_group

```python theme={null}
remove_containing_group(
    containing_group: Group | GroupDescription,
) -> None
```

Remove containing group (syncs inverse automatically, call save() to persist).

Parameters:

| Name               | Type                        | Description                                                | Default    |
| ------------------ | --------------------------- | ---------------------------------------------------------- | ---------- |
| `containing_group` | `Group \| GroupDescription` | Either a Group object or GroupDescription object to remove | *required* |

### Studio

Bases: `StashObject`

Studio type from schema/types/studio.graphql.

#### Attributes

##### name

```python theme={null}
name: str | None | UnsetType = UNSET
```

##### urls

```python theme={null}
urls: list[str] | None | UnsetType = UNSET
```

##### parent\_studio

```python theme={null}
parent_studio: Studio | None | UnsetType = UNSET
```

##### child\_studios

```python theme={null}
child_studios: list[Studio] | None | UnsetType = UNSET
```

##### aliases

```python theme={null}
aliases: list[str] | None | UnsetType = UNSET
```

##### tags

```python theme={null}
tags: list[Tag] | None | UnsetType = UNSET
```

##### ignore\_auto\_tag

```python theme={null}
ignore_auto_tag: bool | None | UnsetType = UNSET
```

##### image\_path

```python theme={null}
image_path: str | None | UnsetType = UNSET
```

##### scene\_count

```python theme={null}
scene_count: int | None | UnsetType = Field(
    default=UNSET, ge=0
)
```

##### image\_count

```python theme={null}
image_count: int | None | UnsetType = Field(
    default=UNSET, ge=0
)
```

##### gallery\_count

```python theme={null}
gallery_count: int | None | UnsetType = Field(
    default=UNSET, ge=0
)
```

##### performer\_count

```python theme={null}
performer_count: int | None | UnsetType = Field(
    default=UNSET, ge=0
)
```

##### group\_count

```python theme={null}
group_count: int | None | UnsetType = Field(
    default=UNSET, ge=0
)
```

##### stash\_ids

```python theme={null}
stash_ids: list[StashID] | None | UnsetType = UNSET
```

##### rating100

```python theme={null}
rating100: int | None | UnsetType = Field(
    default=UNSET, ge=0, le=100
)
```

##### favorite

```python theme={null}
favorite: bool | None | UnsetType = UNSET
```

##### details

```python theme={null}
details: str | None | UnsetType = UNSET
```

##### groups

```python theme={null}
groups: list[Group] | None | UnsetType = UNSET
```

##### scenes

```python theme={null}
scenes: list[Scene] | None | UnsetType = UNSET
```

##### images

```python theme={null}
images: list[Image] | None | UnsetType = UNSET
```

##### galleries

```python theme={null}
galleries: list[Gallery] | None | UnsetType = UNSET
```

##### o\_counter

```python theme={null}
o_counter: int | None | UnsetType = Field(
    default=UNSET, ge=0
)
```

##### custom\_fields

```python theme={null}
custom_fields: Map | UnsetType = UNSET
```

##### organized

```python theme={null}
organized: bool | None | UnsetType = UNSET
```

#### Functions

##### handle\_deprecated\_url

```python theme={null}
handle_deprecated_url(data: Any) -> Any
```

Convert deprecated 'url' field to 'urls' list for backward compatibility.

##### add\_scene

```python theme={null}
add_scene(scene: Scene) -> None
```

Add scene (syncs inverse automatically, call save() to persist).

##### remove\_scene

```python theme={null}
remove_scene(scene: Scene) -> None
```

Remove scene (syncs inverse automatically, call save() to persist).

##### add\_image

```python theme={null}
add_image(image: Image) -> None
```

Add image (syncs inverse automatically, call save() to persist).

##### remove\_image

```python theme={null}
remove_image(image: Image) -> None
```

Remove image (syncs inverse automatically, call save() to persist).

##### add\_gallery

```python theme={null}
add_gallery(gallery: Gallery) -> None
```

Add gallery (syncs inverse automatically, call save() to persist).

##### remove\_gallery

```python theme={null}
remove_gallery(gallery: Gallery) -> None
```

Remove gallery (syncs inverse automatically, call save() to persist).

##### add\_group

```python theme={null}
add_group(group: Group) -> None
```

Add group (syncs inverse automatically, call save() to persist).

##### remove\_group

```python theme={null}
remove_group(group: Group) -> None
```

Remove group (syncs inverse automatically, call save() to persist).

##### set\_parent\_studio

```python theme={null}
set_parent_studio(parent: Studio | None) -> None
```

Set parent studio (syncs inverse automatically, call save() to persist).

##### add\_child\_studio

```python theme={null}
add_child_studio(child: Studio) -> None
```

Add child studio (syncs inverse automatically, call save() to persist).

##### remove\_child\_studio

```python theme={null}
remove_child_studio(child: Studio) -> None
```

Remove child studio (syncs inverse automatically, call save() to persist).

### Tag

Bases: `StashObject`

A label attachable to most entity types, with hierarchy support.

`parents` and `children` are self-referential habtm lists. `*_count` fields are server-side resolvers — read-only.

Content relationship list fields are queryable here but writable only via the owning entity's bulk update mutations; assignments fire bulk-update side mutations on `save()` (see `__side_mutations__` and the Side Mutations guide).

#### Attributes

##### name

```python theme={null}
name: str | None | UnsetType = UNSET
```

##### sort\_name

```python theme={null}
sort_name: str | None | UnsetType = UNSET
```

##### description

```python theme={null}
description: str | None | UnsetType = UNSET
```

##### aliases

```python theme={null}
aliases: list[str] | None | UnsetType = UNSET
```

##### ignore\_auto\_tag

```python theme={null}
ignore_auto_tag: bool | None | UnsetType = UNSET
```

##### favorite

```python theme={null}
favorite: bool | None | UnsetType = UNSET
```

##### stash\_ids

```python theme={null}
stash_ids: list[StashID] | None | UnsetType = UNSET
```

##### image\_path

```python theme={null}
image_path: str | None | UnsetType = UNSET
```

##### scene\_count

```python theme={null}
scene_count: int | None | UnsetType = Field(
    default=UNSET, ge=0
)
```

##### scene\_marker\_count

```python theme={null}
scene_marker_count: int | None | UnsetType = Field(
    default=UNSET, ge=0
)
```

##### image\_count

```python theme={null}
image_count: int | None | UnsetType = Field(
    default=UNSET, ge=0
)
```

##### gallery\_count

```python theme={null}
gallery_count: int | None | UnsetType = Field(
    default=UNSET, ge=0
)
```

##### performer\_count

```python theme={null}
performer_count: int | None | UnsetType = Field(
    default=UNSET, ge=0
)
```

##### studio\_count

```python theme={null}
studio_count: int | None | UnsetType = Field(
    default=UNSET, ge=0
)
```

##### group\_count

```python theme={null}
group_count: int | None | UnsetType = Field(
    default=UNSET, ge=0
)
```

##### parents

```python theme={null}
parents: list[Tag] | None | UnsetType = UNSET
```

##### children

```python theme={null}
children: list[Tag] | None | UnsetType = UNSET
```

##### parent\_count

```python theme={null}
parent_count: int | None | UnsetType = Field(
    default=UNSET, ge=0
)
```

##### child\_count

```python theme={null}
child_count: int | None | UnsetType = Field(
    default=UNSET, ge=0
)
```

##### scenes

```python theme={null}
scenes: list[Scene] | UnsetType = UNSET
```

##### images

```python theme={null}
images: list[Image] | UnsetType = UNSET
```

##### galleries

```python theme={null}
galleries: list[Gallery] | UnsetType = UNSET
```

##### performers

```python theme={null}
performers: list[Performer] | UnsetType = UNSET
```

##### groups

```python theme={null}
groups: list[Group] | UnsetType = UNSET
```

##### studios

```python theme={null}
studios: list[Studio] | UnsetType = UNSET
```

##### scene\_markers

```python theme={null}
scene_markers: list[SceneMarker] | UnsetType = UNSET
```

##### custom\_fields

```python theme={null}
custom_fields: Map | UnsetType = UNSET
```

#### Functions

##### merge

```python theme={null}
merge(
    client: StashClient,
    source_ids: list[str],
    destination_id: str,
    **kwargs: Any,
) -> Tag | None
```

Merge source tags into the destination tag (`tagsMerge`).

##### add\_parent

```python theme={null}
add_parent(parent_tag: Tag) -> None
```

Add parent tag (syncs inverse automatically, call save() to persist).

##### remove\_parent

```python theme={null}
remove_parent(parent_tag: Tag) -> None
```

Remove parent tag (syncs inverse automatically, call save() to persist).

##### add\_child

```python theme={null}
add_child(child_tag: Tag) -> None
```

Add child tag (syncs inverse automatically, call save() to persist).

##### remove\_child

```python theme={null}
remove_child(child_tag: Tag) -> None
```

Remove child tag (syncs inverse automatically, call save() to persist).

##### add\_scene

```python theme={null}
add_scene(scene: Scene) -> None
```

Add scene (syncs inverse automatically, call save() to persist).

##### remove\_scene

```python theme={null}
remove_scene(scene: Scene) -> None
```

Remove scene (syncs inverse automatically, call save() to persist).

##### add\_image

```python theme={null}
add_image(image: Image) -> None
```

Add image (syncs inverse automatically, call save() to persist).

##### remove\_image

```python theme={null}
remove_image(image: Image) -> None
```

Remove image (syncs inverse automatically, call save() to persist).

##### add\_gallery

```python theme={null}
add_gallery(gallery: Gallery) -> None
```

Add gallery (syncs inverse automatically, call save() to persist).

##### remove\_gallery

```python theme={null}
remove_gallery(gallery: Gallery) -> None
```

Remove gallery (syncs inverse automatically, call save() to persist).

##### add\_performer

```python theme={null}
add_performer(performer: Performer) -> None
```

Add performer (syncs inverse automatically, call save() to persist).

##### remove\_performer

```python theme={null}
remove_performer(performer: Performer) -> None
```

Remove performer (syncs inverse automatically, call save() to persist).

##### add\_group

```python theme={null}
add_group(group: Group) -> None
```

Add group (syncs inverse automatically, call save() to persist).

##### remove\_group

```python theme={null}
remove_group(group: Group) -> None
```

Remove group (syncs inverse automatically, call save() to persist).

##### add\_scene\_marker

```python theme={null}
add_scene_marker(marker: SceneMarker) -> None
```

Add scene marker (syncs inverse automatically, call save() to persist).

##### remove\_scene\_marker

```python theme={null}
remove_scene_marker(marker: SceneMarker) -> None
```

Remove scene marker (syncs inverse automatically, call save() to persist).

##### get\_all\_descendants

```python theme={null}
get_all_descendants() -> list[Tag]
```

Get all descendant tags recursively (children, grandchildren, etc.).

Returns:

| Type        | Description                                  |
| ----------- | -------------------------------------------- |
| `list[Tag]` | List of all descendant tags in the hierarchy |

##### get\_all\_ancestors

```python theme={null}
get_all_ancestors() -> list[Tag]
```

Get all ancestor tags recursively (parents, grandparents, etc.).

Returns:

| Type        | Description                                |
| ----------- | ------------------------------------------ |
| `list[Tag]` | List of all ancestor tags in the hierarchy |

##### find\_by\_name

```python theme={null}
find_by_name(client: StashClient, name: str) -> T | None
```

Find tag by name (case-insensitive search).

Parameters:

| Name     | Type          | Description            | Default    |
| -------- | ------------- | ---------------------- | ---------- |
| `client` | `StashClient` | "StashClient" instance | *required* |
| `name`   | `str`         | Tag name to search for | *required* |

Returns:

| Type        | Description                           |
| ----------- | ------------------------------------- |
| `T \| None` | Tag instance if found, None otherwise |

### SceneMarker

Bases: `StashObject`

A timestamp marker on a Scene (title, seconds, optional end\_seconds).

Construct using relationship objects, not IDs: `SceneMarker(scene=Scene(id="1"), primary_tag=Tag(id="10"), seconds=42.0)`. `scene_id` / `primary_tag_id` exist only on `SceneMarkerCreateInput`; `to_input()` extracts IDs from the relationship objects automatically.

#### Attributes

##### scene

```python theme={null}
scene: Scene | None | UnsetType = UNSET
```

##### title

```python theme={null}
title: str | None | UnsetType = UNSET
```

##### seconds

```python theme={null}
seconds: float | None | UnsetType = UNSET
```

##### primary\_tag

```python theme={null}
primary_tag: Tag | None | UnsetType = UNSET
```

##### tags

```python theme={null}
tags: list[Tag] | None | UnsetType = UNSET
```

##### stream

```python theme={null}
stream: str | None | UnsetType = UNSET
```

##### preview

```python theme={null}
preview: str | None | UnsetType = UNSET
```

##### screenshot

```python theme={null}
screenshot: str | None | UnsetType = UNSET
```

##### end\_seconds

```python theme={null}
end_seconds: float | None | UnsetType = UNSET
```

#### Functions

##### add\_tag

```python theme={null}
add_tag(tag: Tag) -> None
```

Add tag to scene marker (syncs inverse automatically, call save() to persist).

##### remove\_tag

```python theme={null}
remove_tag(tag: Tag) -> None
```

Remove tag from scene marker (syncs inverse automatically, call save() to persist).

## UNSET Pattern

### UnsetType

Sentinel value representing an unset field.

Used throughout the type system to indicate a field has never been set, as distinct from being explicitly set to None.

This is a singleton - all instances are the same object.

### UNSET

```python theme={null}
UNSET = UnsetType()
```

## Date Utilities

### FuzzyDate

```python theme={null}
FuzzyDate(value: str)
```

Represents a date with variable precision.

Examples:

```python theme={null}
>>> date = FuzzyDate("2024")
>>> date.precision
<DatePrecision.YEAR: 'year'>
>>> date.value
'2024'
```

```python theme={null}
>>> date = FuzzyDate("2024-03")
>>> date.precision
<DatePrecision.MONTH: 'month'>
```

```python theme={null}
>>> date = FuzzyDate("2024-03-15")
>>> date.precision
<DatePrecision.DAY: 'day'>
```

Initialize a fuzzy date from a string.

Parameters:

| Name    | Type  | Description                                        | Default    |
| ------- | ----- | -------------------------------------------------- | ---------- |
| `value` | `str` | Date string in format YYYY, YYYY-MM, or YYYY-MM-DD | *required* |

Raises:

| Type                    | Description                   |
| ----------------------- | ----------------------------- |
| `StashIntegrationError` | If the date format is invalid |

#### Attributes

##### value

```python theme={null}
value = value
```

##### precision

```python theme={null}
precision = parse_date_precision(value)
```

#### Functions

##### to\_datetime

```python theme={null}
to_datetime() -> datetime
```

Convert to a datetime object (using first day of period).

Returns:

| Name       | Type       | Description                                                                                                                                                                                                                     |
| ---------- | ---------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| `datetime` | `datetime` | A datetime object representing the start of the period. - Year precision: January 1<sup>st</sup> of that year - Month precision: 1<sup>st</sup> day of that month - Day precision: That specific day (time stripped if present) |

Examples:

```python theme={null}
>>> FuzzyDate("2024").to_datetime()
datetime.datetime(2024, 1, 1, 0, 0)
>>> FuzzyDate("2024-03").to_datetime()
datetime.datetime(2024, 3, 1, 0, 0)
>>> FuzzyDate("2024-03-15").to_datetime()
datetime.datetime(2024, 3, 15, 0, 0)
```

### DatePrecision

Bases: `StrEnum`

Date precision levels supported by Stash. These correspond to the database precision values: - DAY = 0 (YYYY-MM-DD) - MONTH = 1 (YYYY-MM) - YEAR = 2 (YYYY) - OTHER = 3 (YYYY-MM-DD HH:MM:SS - more precise than day)

#### Attributes

##### DAY

```python theme={null}
DAY = 'day'
```

##### MONTH

```python theme={null}
MONTH = 'month'
```

##### YEAR

```python theme={null}
YEAR = 'year'
```

##### OTHER

```python theme={null}
OTHER = 'other'
```

### validate\_fuzzy\_date

```python theme={null}
validate_fuzzy_date(date_str: str) -> bool
```

Validate that a date string is in a supported fuzzy format.

Parameters:

| Name       | Type  | Description             | Default    |
| ---------- | ----- | ----------------------- | ---------- |
| `date_str` | `str` | Date string to validate | *required* |

Returns:

| Name   | Type   | Description                                |
| ------ | ------ | ------------------------------------------ |
| `bool` | `bool` | True if the date is valid, False otherwise |

Examples:

```python theme={null}
>>> validate_fuzzy_date("2024")
True
>>> validate_fuzzy_date("2024-03")
True
>>> validate_fuzzy_date("2024-03-15")
True
>>> validate_fuzzy_date("2024-3-15")
False
>>> validate_fuzzy_date("invalid")
False
```

### normalize\_date

```python theme={null}
normalize_date(
    date_str: str,
    target_precision: Literal["day", "month", "year"]
    | None = None,
) -> str
```

Normalize a date string to a specific precision.

Parameters:

| Name               | Type                                      | Description                                                               | Default    |
| ------------------ | ----------------------------------------- | ------------------------------------------------------------------------- | ---------- |
| `date_str`         | `str`                                     | Date string to normalize                                                  | *required* |
| `target_precision` | `Literal['day', 'month', 'year'] \| None` | Target precision level. If None, returns the date as-is after validation. | `None`     |

Returns:

| Name  | Type  | Description            |
| ----- | ----- | ---------------------- |
| `str` | `str` | Normalized date string |

Raises:

| Type                    | Description                                       |
| ----------------------- | ------------------------------------------------- |
| `StashIntegrationError` | If the date format is invalid or conversion fails |

Examples:

```python theme={null}
>>> normalize_date("2024-03-15", "month")
'2024-03'
>>> normalize_date("2024-03-15", "year")
'2024'
>>> normalize_date("2024", "day")
'2024-01-01'
```

## Enums

Enum types from schema.

### Classes

#### GenderEnum

Bases: `StrEnum`

Gender enum from schema.

##### Attributes

###### MALE

```python theme={null}
MALE = 'MALE'
```

###### FEMALE

```python theme={null}
FEMALE = 'FEMALE'
```

###### TRANSGENDER\_MALE

```python theme={null}
TRANSGENDER_MALE = 'TRANSGENDER_MALE'
```

###### TRANSGENDER\_FEMALE

```python theme={null}
TRANSGENDER_FEMALE = 'TRANSGENDER_FEMALE'
```

###### INTERSEX

```python theme={null}
INTERSEX = 'INTERSEX'
```

###### NON\_BINARY

```python theme={null}
NON_BINARY = 'NON_BINARY'
```

#### CircumcisedEnum

Bases: `StrEnum`

Circumcision enum from schema.

##### Attributes

###### CUT

```python theme={null}
CUT = 'CUT'
```

###### UNCUT

```python theme={null}
UNCUT = 'UNCUT'
```

#### BulkUpdateIdMode

Bases: `StrEnum`

Bulk update mode enum from schema.

##### Attributes

###### SET

```python theme={null}
SET = 'SET'
```

###### ADD

```python theme={null}
ADD = 'ADD'
```

###### REMOVE

```python theme={null}
REMOVE = 'REMOVE'
```

#### SortDirectionEnum

Bases: `StrEnum`

Sort direction enum from schema.

##### Attributes

###### ASC

```python theme={null}
ASC = 'ASC'
```

###### DESC

```python theme={null}
DESC = 'DESC'
```

#### ResolutionEnum

Bases: `StrEnum`

Resolution enum from schema.

##### Attributes

###### VERY\_LOW

```python theme={null}
VERY_LOW = 'VERY_LOW'
```

###### LOW

```python theme={null}
LOW = 'LOW'
```

###### R360P

```python theme={null}
R360P = 'R360P'
```

###### STANDARD

```python theme={null}
STANDARD = 'STANDARD'
```

###### WEB\_HD

```python theme={null}
WEB_HD = 'WEB_HD'
```

###### STANDARD\_HD

```python theme={null}
STANDARD_HD = 'STANDARD_HD'
```

###### FULL\_HD

```python theme={null}
FULL_HD = 'FULL_HD'
```

###### QUAD\_HD

```python theme={null}
QUAD_HD = 'QUAD_HD'
```

###### FOUR\_K

```python theme={null}
FOUR_K = 'FOUR_K'
```

###### FIVE\_K

```python theme={null}
FIVE_K = 'FIVE_K'
```

###### SIX\_K

```python theme={null}
SIX_K = 'SIX_K'
```

###### SEVEN\_K

```python theme={null}
SEVEN_K = 'SEVEN_K'
```

###### EIGHT\_K

```python theme={null}
EIGHT_K = 'EIGHT_K'
```

###### HUGE

```python theme={null}
HUGE = 'HUGE'
```

#### OrientationEnum

Bases: `StrEnum`

Orientation enum from schema.

##### Attributes

###### LANDSCAPE

```python theme={null}
LANDSCAPE = 'LANDSCAPE'
```

###### PORTRAIT

```python theme={null}
PORTRAIT = 'PORTRAIT'
```

###### SQUARE

```python theme={null}
SQUARE = 'SQUARE'
```

#### CriterionModifier

Bases: `StrEnum`

Criterion modifier enum from schema.

##### Attributes

###### EQUALS

```python theme={null}
EQUALS = 'EQUALS'
```

###### NOT\_EQUALS

```python theme={null}
NOT_EQUALS = 'NOT_EQUALS'
```

###### GREATER\_THAN

```python theme={null}
GREATER_THAN = 'GREATER_THAN'
```

###### LESS\_THAN

```python theme={null}
LESS_THAN = 'LESS_THAN'
```

###### IS\_NULL

```python theme={null}
IS_NULL = 'IS_NULL'
```

###### NOT\_NULL

```python theme={null}
NOT_NULL = 'NOT_NULL'
```

###### INCLUDES\_ALL

```python theme={null}
INCLUDES_ALL = 'INCLUDES_ALL'
```

###### INCLUDES

```python theme={null}
INCLUDES = 'INCLUDES'
```

###### EXCLUDES

```python theme={null}
EXCLUDES = 'EXCLUDES'
```

###### MATCHES\_REGEX

```python theme={null}
MATCHES_REGEX = 'MATCHES_REGEX'
```

###### NOT\_MATCHES\_REGEX

```python theme={null}
NOT_MATCHES_REGEX = 'NOT_MATCHES_REGEX'
```

###### BETWEEN

```python theme={null}
BETWEEN = 'BETWEEN'
```

###### NOT\_BETWEEN

```python theme={null}
NOT_BETWEEN = 'NOT_BETWEEN'
```

#### FilterMode

Bases: `StrEnum`

Filter mode enum from schema.

##### Attributes

###### SCENES

```python theme={null}
SCENES = 'SCENES'
```

###### PERFORMERS

```python theme={null}
PERFORMERS = 'PERFORMERS'
```

###### STUDIOS

```python theme={null}
STUDIOS = 'STUDIOS'
```

###### GALLERIES

```python theme={null}
GALLERIES = 'GALLERIES'
```

###### SCENE\_MARKERS

```python theme={null}
SCENE_MARKERS = 'SCENE_MARKERS'
```

###### MOVIES

```python theme={null}
MOVIES = 'MOVIES'
```

###### GROUPS

```python theme={null}
GROUPS = 'GROUPS'
```

###### TAGS

```python theme={null}
TAGS = 'TAGS'
```

###### IMAGES

```python theme={null}
IMAGES = 'IMAGES'
```

#### StreamingResolutionEnum

Bases: `StrEnum`

Streaming resolution enum from schema.

##### Attributes

###### LOW

```python theme={null}
LOW = 'LOW'
```

###### STANDARD

```python theme={null}
STANDARD = 'STANDARD'
```

###### STANDARD\_HD

```python theme={null}
STANDARD_HD = 'STANDARD_HD'
```

###### FULL\_HD

```python theme={null}
FULL_HD = 'FULL_HD'
```

###### FOUR\_K

```python theme={null}
FOUR_K = 'FOUR_K'
```

###### ORIGINAL

```python theme={null}
ORIGINAL = 'ORIGINAL'
```

#### PreviewPreset

Bases: `StrEnum`

Preview preset enum from schema.

##### Attributes

###### ULTRAFAST

```python theme={null}
ULTRAFAST = 'ultrafast'
```

###### VERYFAST

```python theme={null}
VERYFAST = 'veryfast'
```

###### FAST

```python theme={null}
FAST = 'fast'
```

###### MEDIUM

```python theme={null}
MEDIUM = 'medium'
```

###### SLOW

```python theme={null}
SLOW = 'slow'
```

###### SLOWER

```python theme={null}
SLOWER = 'slower'
```

###### VERYSLOW

```python theme={null}
VERYSLOW = 'veryslow'
```

#### HashAlgorithm

Bases: `StrEnum`

Hash algorithm enum from schema.

##### Attributes

###### MD5

```python theme={null}
MD5 = 'MD5'
```

###### OSHASH

```python theme={null}
OSHASH = 'OSHASH'
```

#### BlobsStorageType

Bases: `StrEnum`

Blobs storage type enum from schema.

##### Attributes

###### DATABASE

```python theme={null}
DATABASE = 'DATABASE'
```

###### FILESYSTEM

```python theme={null}
FILESYSTEM = 'FILESYSTEM'
```

#### ImageLightboxDisplayMode

Bases: `StrEnum`

Image lightbox display mode enum from schema.

##### Attributes

###### ORIGINAL

```python theme={null}
ORIGINAL = 'ORIGINAL'
```

###### FIT\_XY

```python theme={null}
FIT_XY = 'FIT_XY'
```

###### FIT\_X

```python theme={null}
FIT_X = 'FIT_X'
```

#### ImageLightboxScrollMode

Bases: `StrEnum`

Image lightbox scroll mode enum from schema.

##### Attributes

###### ZOOM

```python theme={null}
ZOOM = 'ZOOM'
```

###### PAN\_Y

```python theme={null}
PAN_Y = 'PAN_Y'
```

#### IdentifyFieldStrategy

Bases: `StrEnum`

Strategy for identifying fields from schema/types/metadata.graphql.

##### Attributes

###### IGNORE

```python theme={null}
IGNORE = 'IGNORE'
```

###### MERGE

```python theme={null}
MERGE = 'MERGE'
```

###### OVERWRITE

```python theme={null}
OVERWRITE = 'OVERWRITE'
```

#### ImportDuplicateEnum

Bases: `StrEnum`

Import duplicate behavior from schema/types/metadata.graphql.

##### Attributes

###### IGNORE

```python theme={null}
IGNORE = 'IGNORE'
```

###### OVERWRITE

```python theme={null}
OVERWRITE = 'OVERWRITE'
```

###### FAIL

```python theme={null}
FAIL = 'FAIL'
```

#### ImportMissingRefEnum

Bases: `StrEnum`

Import missing reference behavior from schema/types/metadata.graphql.

##### Attributes

###### IGNORE

```python theme={null}
IGNORE = 'IGNORE'
```

###### FAIL

```python theme={null}
FAIL = 'FAIL'
```

###### CREATE

```python theme={null}
CREATE = 'CREATE'
```

#### SystemStatusEnum

Bases: `StrEnum`

System status enum from schema/types/metadata.graphql.

##### Attributes

###### SETUP

```python theme={null}
SETUP = 'SETUP'
```

###### NEEDS\_MIGRATION

```python theme={null}
NEEDS_MIGRATION = 'NEEDS_MIGRATION'
```

###### OK

```python theme={null}
OK = 'OK'
```

#### JobStatus

Bases: `StrEnum`

Job status enum from schema/types/job.graphql.

##### Attributes

###### READY

```python theme={null}
READY = 'READY'
```

###### RUNNING

```python theme={null}
RUNNING = 'RUNNING'
```

###### FINISHED

```python theme={null}
FINISHED = 'FINISHED'
```

###### STOPPING

```python theme={null}
STOPPING = 'STOPPING'
```

###### CANCELLED

```python theme={null}
CANCELLED = 'CANCELLED'
```

###### FAILED

```python theme={null}
FAILED = 'FAILED'
```

#### JobStatusUpdateType

Bases: `StrEnum`

Job status update type enum from schema/types/job.graphql.

##### Attributes

###### ADD

```python theme={null}
ADD = 'ADD'
```

###### REMOVE

```python theme={null}
REMOVE = 'REMOVE'
```

###### UPDATE

```python theme={null}
UPDATE = 'UPDATE'
```

#### LogLevel

Bases: `StrEnum`

Log level enum from schema/types/logging.graphql.

##### Attributes

###### TRACE

```python theme={null}
TRACE = 'Trace'
```

###### DEBUG

```python theme={null}
DEBUG = 'Debug'
```

###### INFO

```python theme={null}
INFO = 'Info'
```

###### PROGRESS

```python theme={null}
PROGRESS = 'Progress'
```

###### WARNING

```python theme={null}
WARNING = 'Warning'
```

###### ERROR

```python theme={null}
ERROR = 'Error'
```

#### PluginSettingTypeEnum

Bases: `StrEnum`

Plugin setting type enum from schema/types/plugin.graphql.

##### Attributes

###### STRING

```python theme={null}
STRING = 'STRING'
```

###### NUMBER

```python theme={null}
NUMBER = 'NUMBER'
```

###### BOOLEAN

```python theme={null}
BOOLEAN = 'BOOLEAN'
```

#### ScrapeContentType

Bases: `StrEnum`

Scrape content type enum from schema/types/scraper.graphql.

##### Attributes

###### GALLERY

```python theme={null}
GALLERY = 'GALLERY'
```

###### IMAGE

```python theme={null}
IMAGE = 'IMAGE'
```

###### MOVIE

```python theme={null}
MOVIE = 'MOVIE'
```

###### GROUP

```python theme={null}
GROUP = 'GROUP'
```

###### PERFORMER

```python theme={null}
PERFORMER = 'PERFORMER'
```

###### SCENE

```python theme={null}
SCENE = 'SCENE'
```

#### ScrapeType

Bases: `StrEnum`

Scrape type enum from schema/types/scraper.graphql.

##### Attributes

###### NAME

```python theme={null}
NAME = 'NAME'
```

###### FRAGMENT

```python theme={null}
FRAGMENT = 'FRAGMENT'
```

###### URL

```python theme={null}
URL = 'URL'
```

#### PackageType

Bases: `StrEnum`

Package type enum from schema.

##### Attributes

###### SCRAPER

```python theme={null}
SCRAPER = 'Scraper'
```

###### PLUGIN

```python theme={null}
PLUGIN = 'Plugin'
```

#### OnMultipleMatch

Bases: `Enum`

##### Attributes

###### RETURN\_NONE

```python theme={null}
RETURN_NONE = 0
```

###### RETURN\_LIST

```python theme={null}
RETURN_LIST = 1
```

###### RETURN\_FIRST

```python theme={null}
RETURN_FIRST = 2
```

## File Types

### VideoFile

Bases: `BaseFile`

Video file type from schema/types/file.graphql.

Implements BaseFile and inherits StashObject through it.

#### Attributes

##### format

```python theme={null}
format: str | UnsetType = UNSET
```

##### width

```python theme={null}
width: int | UnsetType = UNSET
```

##### height

```python theme={null}
height: int | UnsetType = UNSET
```

##### duration

```python theme={null}
duration: float | UnsetType = UNSET
```

##### video\_codec

```python theme={null}
video_codec: str | UnsetType = UNSET
```

##### audio\_codec

```python theme={null}
audio_codec: str | UnsetType = UNSET
```

##### frame\_rate

```python theme={null}
frame_rate: float | UnsetType = UNSET
```

##### bit\_rate

```python theme={null}
bit_rate: int | UnsetType = UNSET
```

##### scenes

```python theme={null}
scenes: list[Scene] | None | UnsetType = UNSET
```

### ImageFile

Bases: `BaseFile`

Image file type from schema/types/file.graphql.

Implements BaseFile and inherits StashObject through it.

#### Attributes

##### format

```python theme={null}
format: str | UnsetType = UNSET
```

##### width

```python theme={null}
width: int | UnsetType = UNSET
```

##### height

```python theme={null}
height: int | UnsetType = UNSET
```

##### images

```python theme={null}
images: list[Image] | None | UnsetType = UNSET
```

### GalleryFile

Bases: `BaseFile`

Gallery file type from schema/types/file.graphql.

Implements BaseFile with no additional fields and inherits StashObject through it.

#### Attributes

##### galleries

```python theme={null}
galleries: list[Gallery] | None | UnsetType = UNSET
```

### BaseFile

Bases: `StashObject`

Base interface for all file types from schema/types/file.graphql.

Note: Inherits from StashObject since it has id, created\_at, and updated\_at fields in the schema, matching the common pattern.

#### Attributes

##### path

```python theme={null}
path: str | UnsetType = UNSET
```

##### basename

```python theme={null}
basename: str | UnsetType = UNSET
```

##### parent\_folder

```python theme={null}
parent_folder: Folder | UnsetType = UNSET
```

##### mod\_time

```python theme={null}
mod_time: datetime | UnsetType = UNSET
```

##### size

```python theme={null}
size: int | UnsetType = UNSET
```

##### fingerprints

```python theme={null}
fingerprints: list[Fingerprint] | UnsetType = UNSET
```

##### zip\_file

```python theme={null}
zip_file: BasicFile | None | UnsetType = UNSET
```

#### Functions

##### to\_input

```python theme={null}
to_input() -> dict[str, Any]
```

Convert to GraphQL input.

Returns:

| Type             | Description                                                         |
| ---------------- | ------------------------------------------------------------------- |
| `dict[str, Any]` | Dictionary of input fields for move or set fingerprints operations. |

### Folder

Bases: `StashObject`

Folder type from schema/types/file.graphql.

Note: Inherits from StashObject since it has id, created\_at, and updated\_at fields in the schema, matching the common pattern.

#### Attributes

##### path

```python theme={null}
path: str | UnsetType = UNSET
```

##### mod\_time

```python theme={null}
mod_time: datetime | UnsetType = UNSET
```

##### parent\_folder

```python theme={null}
parent_folder: Folder | None | UnsetType = UNSET
```

##### zip\_file

```python theme={null}
zip_file: BasicFile | None | UnsetType = UNSET
```

##### basename

```python theme={null}
basename: str | None | UnsetType = UNSET
```

##### parent\_folders

```python theme={null}
parent_folders: list[Folder] | None | UnsetType = UNSET
```

##### sub\_folders

```python theme={null}
sub_folders: list[Folder] | None | UnsetType = UNSET
```

#### Functions

##### to\_input

```python theme={null}
to_input() -> dict[str, Any]
```

Convert to GraphQL input.

Returns:

| Type             | Description                                    |
| ---------------- | ---------------------------------------------- |
| `dict[str, Any]` | Dictionary of input fields for move operation. |

## Input Types

Input types for mutations (create, update, destroy operations).

### SceneCreateInput

Bases: `StashInput`

Input for creating scenes.

#### Attributes

##### title

```python theme={null}
title: str | None | UnsetType = UNSET
```

##### code

```python theme={null}
code: str | None | UnsetType = UNSET
```

##### details

```python theme={null}
details: str | None | UnsetType = UNSET
```

##### director

```python theme={null}
director: str | None | UnsetType = UNSET
```

##### urls

```python theme={null}
urls: list[str] | None | UnsetType = UNSET
```

##### date

```python theme={null}
date: str | None | UnsetType = UNSET
```

##### rating100

```python theme={null}
rating100: int | None | UnsetType = Field(
    default=UNSET, ge=0, le=100
)
```

##### organized

```python theme={null}
organized: bool | None | UnsetType = UNSET
```

##### studio\_id

```python theme={null}
studio_id: str | None | UnsetType = UNSET
```

##### gallery\_ids

```python theme={null}
gallery_ids: list[str] | None | UnsetType = UNSET
```

##### performer\_ids

```python theme={null}
performer_ids: list[str] | None | UnsetType = UNSET
```

##### groups

```python theme={null}
groups: list[SceneGroupInput] | None | UnsetType = UNSET
```

##### tag\_ids

```python theme={null}
tag_ids: list[str] | None | UnsetType = UNSET
```

##### cover\_image

```python theme={null}
cover_image: str | None | UnsetType = UNSET
```

##### stash\_ids

```python theme={null}
stash_ids: list[StashIDInput] | None | UnsetType = UNSET
```

##### file\_ids

```python theme={null}
file_ids: list[str] | None | UnsetType = UNSET
```

##### custom\_fields

```python theme={null}
custom_fields: dict[str, Any] | None | UnsetType = UNSET
```

### SceneUpdateInput

Bases: `StashInput`

Input for updating scenes.

#### Attributes

##### id

```python theme={null}
id: str
```

##### client\_mutation\_id

```python theme={null}
client_mutation_id: str | None | UnsetType = Field(
    default=UNSET, alias="clientMutationId"
)
```

##### title

```python theme={null}
title: str | None | UnsetType = UNSET
```

##### code

```python theme={null}
code: str | None | UnsetType = UNSET
```

##### details

```python theme={null}
details: str | None | UnsetType = UNSET
```

##### director

```python theme={null}
director: str | None | UnsetType = UNSET
```

##### urls

```python theme={null}
urls: list[str] | None | UnsetType = UNSET
```

##### date

```python theme={null}
date: str | None | UnsetType = UNSET
```

##### rating100

```python theme={null}
rating100: int | None | UnsetType = Field(
    default=UNSET, ge=0, le=100
)
```

##### organized

```python theme={null}
organized: bool | None | UnsetType = UNSET
```

##### studio\_id

```python theme={null}
studio_id: str | None | UnsetType = UNSET
```

##### gallery\_ids

```python theme={null}
gallery_ids: list[str] | None | UnsetType = UNSET
```

##### performer\_ids

```python theme={null}
performer_ids: list[str] | None | UnsetType = UNSET
```

##### groups

```python theme={null}
groups: list[SceneGroupInput] | None | UnsetType = UNSET
```

##### tag\_ids

```python theme={null}
tag_ids: list[str] | None | UnsetType = UNSET
```

##### cover\_image

```python theme={null}
cover_image: str | None | UnsetType = UNSET
```

##### stash\_ids

```python theme={null}
stash_ids: list[StashIDInput] | None | UnsetType = UNSET
```

##### resume\_time

```python theme={null}
resume_time: float | None | UnsetType = UNSET
```

##### play\_duration

```python theme={null}
play_duration: float | None | UnsetType = UNSET
```

##### primary\_file\_id

```python theme={null}
primary_file_id: str | None | UnsetType = UNSET
```

##### custom\_fields

```python theme={null}
custom_fields: CustomFieldsInput | None | UnsetType = UNSET
```

### PerformerCreateInput

Bases: `StashInput`

Input for creating performers.

#### Attributes

##### name

```python theme={null}
name: str
```

##### disambiguation

```python theme={null}
disambiguation: str | None | UnsetType = UNSET
```

##### urls

```python theme={null}
urls: list[str] | None | UnsetType = UNSET
```

##### gender

```python theme={null}
gender: GenderEnum | None | UnsetType = UNSET
```

##### birthdate

```python theme={null}
birthdate: str | None | UnsetType = UNSET
```

##### ethnicity

```python theme={null}
ethnicity: str | None | UnsetType = UNSET
```

##### country

```python theme={null}
country: str | None | UnsetType = UNSET
```

##### eye\_color

```python theme={null}
eye_color: str | None | UnsetType = UNSET
```

##### height\_cm

```python theme={null}
height_cm: int | None | UnsetType = UNSET
```

##### measurements

```python theme={null}
measurements: str | None | UnsetType = UNSET
```

##### fake\_tits

```python theme={null}
fake_tits: str | None | UnsetType = UNSET
```

##### penis\_length

```python theme={null}
penis_length: float | None | UnsetType = UNSET
```

##### circumcised

```python theme={null}
circumcised: CircumcisedEnum | None | UnsetType = UNSET
```

##### career\_length

```python theme={null}
career_length: str | None | UnsetType = UNSET
```

##### tattoos

```python theme={null}
tattoos: str | None | UnsetType = UNSET
```

##### piercings

```python theme={null}
piercings: str | None | UnsetType = UNSET
```

##### alias\_list

```python theme={null}
alias_list: list[str] | None | UnsetType = UNSET
```

##### favorite

```python theme={null}
favorite: bool | None | UnsetType = UNSET
```

##### tag\_ids

```python theme={null}
tag_ids: list[str] | None | UnsetType = UNSET
```

##### image

```python theme={null}
image: str | None | UnsetType = UNSET
```

##### stash\_ids

```python theme={null}
stash_ids: list[StashIDInput] | None | UnsetType = UNSET
```

##### rating100

```python theme={null}
rating100: int | None | UnsetType = Field(
    default=UNSET, ge=0, le=100
)
```

##### details

```python theme={null}
details: str | None | UnsetType = UNSET
```

##### death\_date

```python theme={null}
death_date: str | None | UnsetType = UNSET
```

##### hair\_color

```python theme={null}
hair_color: str | None | UnsetType = UNSET
```

##### weight

```python theme={null}
weight: int | None | UnsetType = UNSET
```

##### ignore\_auto\_tag

```python theme={null}
ignore_auto_tag: bool | None | UnsetType = UNSET
```

##### custom\_fields

```python theme={null}
custom_fields: dict[str, Any] | None | UnsetType = UNSET
```

##### career\_start

```python theme={null}
career_start: str | None | UnsetType = UNSET
```

##### career\_end

```python theme={null}
career_end: str | None | UnsetType = UNSET
```

### PerformerUpdateInput

Bases: `StashInput`

Input for updating performers.

#### Attributes

##### id

```python theme={null}
id: str
```

##### name

```python theme={null}
name: str | None | UnsetType = UNSET
```

##### disambiguation

```python theme={null}
disambiguation: str | None | UnsetType = UNSET
```

##### urls

```python theme={null}
urls: list[str] | None | UnsetType = UNSET
```

##### gender

```python theme={null}
gender: GenderEnum | None | UnsetType = UNSET
```

##### birthdate

```python theme={null}
birthdate: str | None | UnsetType = UNSET
```

##### ethnicity

```python theme={null}
ethnicity: str | None | UnsetType = UNSET
```

##### country

```python theme={null}
country: str | None | UnsetType = UNSET
```

##### eye\_color

```python theme={null}
eye_color: str | None | UnsetType = UNSET
```

##### height\_cm

```python theme={null}
height_cm: int | None | UnsetType = UNSET
```

##### measurements

```python theme={null}
measurements: str | None | UnsetType = UNSET
```

##### fake\_tits

```python theme={null}
fake_tits: str | None | UnsetType = UNSET
```

##### penis\_length

```python theme={null}
penis_length: float | None | UnsetType = UNSET
```

##### circumcised

```python theme={null}
circumcised: CircumcisedEnum | None | UnsetType = UNSET
```

##### career\_length

```python theme={null}
career_length: str | None | UnsetType = UNSET
```

##### tattoos

```python theme={null}
tattoos: str | None | UnsetType = UNSET
```

##### piercings

```python theme={null}
piercings: str | None | UnsetType = UNSET
```

##### alias\_list

```python theme={null}
alias_list: list[str] | None | UnsetType = UNSET
```

##### favorite

```python theme={null}
favorite: bool | None | UnsetType = UNSET
```

##### tag\_ids

```python theme={null}
tag_ids: list[str] | None | UnsetType = UNSET
```

##### image

```python theme={null}
image: str | None | UnsetType = UNSET
```

##### stash\_ids

```python theme={null}
stash_ids: list[StashIDInput] | None | UnsetType = UNSET
```

##### rating100

```python theme={null}
rating100: int | None | UnsetType = Field(
    default=UNSET, ge=0, le=100
)
```

##### details

```python theme={null}
details: str | None | UnsetType = UNSET
```

##### death\_date

```python theme={null}
death_date: str | None | UnsetType = UNSET
```

##### hair\_color

```python theme={null}
hair_color: str | None | UnsetType = UNSET
```

##### weight

```python theme={null}
weight: int | None | UnsetType = UNSET
```

##### ignore\_auto\_tag

```python theme={null}
ignore_auto_tag: bool | None | UnsetType = UNSET
```

##### custom\_fields

```python theme={null}
custom_fields: CustomFieldsInput | None | UnsetType = UNSET
```

##### career\_start

```python theme={null}
career_start: str | None | UnsetType = UNSET
```

##### career\_end

```python theme={null}
career_end: str | None | UnsetType = UNSET
```

### GalleryCreateInput

Bases: `StashInput`

Input for creating galleries.

#### Attributes

##### title

```python theme={null}
title: str
```

##### code

```python theme={null}
code: str | None | UnsetType = UNSET
```

##### urls

```python theme={null}
urls: list[str] | None | UnsetType = UNSET
```

##### date

```python theme={null}
date: str | None | UnsetType = UNSET
```

##### details

```python theme={null}
details: str | None | UnsetType = UNSET
```

##### photographer

```python theme={null}
photographer: str | None | UnsetType = UNSET
```

##### rating100

```python theme={null}
rating100: int | None | UnsetType = Field(
    default=UNSET, ge=0, le=100
)
```

##### organized

```python theme={null}
organized: bool | None | UnsetType = UNSET
```

##### scene\_ids

```python theme={null}
scene_ids: list[str] | None | UnsetType = UNSET
```

##### studio\_id

```python theme={null}
studio_id: str | None | UnsetType = UNSET
```

##### tag\_ids

```python theme={null}
tag_ids: list[str] | None | UnsetType = UNSET
```

##### performer\_ids

```python theme={null}
performer_ids: list[str] | None | UnsetType = UNSET
```

##### custom\_fields

```python theme={null}
custom_fields: dict[str, Any] | None | UnsetType = UNSET
```

### GalleryUpdateInput

Bases: `StashInput`

Input for updating galleries.

#### Attributes

##### id

```python theme={null}
id: str
```

##### client\_mutation\_id

```python theme={null}
client_mutation_id: str | None | UnsetType = Field(
    default=UNSET, alias="clientMutationId"
)
```

##### title

```python theme={null}
title: str | None | UnsetType = UNSET
```

##### code

```python theme={null}
code: str | None | UnsetType = UNSET
```

##### urls

```python theme={null}
urls: list[str] | None | UnsetType = UNSET
```

##### date

```python theme={null}
date: str | None | UnsetType = UNSET
```

##### details

```python theme={null}
details: str | None | UnsetType = UNSET
```

##### photographer

```python theme={null}
photographer: str | None | UnsetType = UNSET
```

##### rating100

```python theme={null}
rating100: int | None | UnsetType = Field(
    default=UNSET, ge=0, le=100
)
```

##### organized

```python theme={null}
organized: bool | None | UnsetType = UNSET
```

##### scene\_ids

```python theme={null}
scene_ids: list[str] | None | UnsetType = UNSET
```

##### studio\_id

```python theme={null}
studio_id: str | None | UnsetType = UNSET
```

##### tag\_ids

```python theme={null}
tag_ids: list[str] | None | UnsetType = UNSET
```

##### performer\_ids

```python theme={null}
performer_ids: list[str] | None | UnsetType = UNSET
```

##### primary\_file\_id

```python theme={null}
primary_file_id: str | None | UnsetType = UNSET
```

##### custom\_fields

```python theme={null}
custom_fields: CustomFieldsInput | None | UnsetType = UNSET
```

### GroupCreateInput

Bases: `StashInput`

Input for creating groups from schema/types/group.graphql.

#### Attributes

##### name

```python theme={null}
name: str | UnsetType = UNSET
```

##### aliases

```python theme={null}
aliases: str | None | UnsetType = UNSET
```

##### duration

```python theme={null}
duration: int | None | UnsetType = UNSET
```

##### date

```python theme={null}
date: str | None | UnsetType = UNSET
```

##### rating100

```python theme={null}
rating100: int | None | UnsetType = Field(
    default=UNSET, ge=0, le=100
)
```

##### studio\_id

```python theme={null}
studio_id: str | None | UnsetType = UNSET
```

##### director

```python theme={null}
director: str | None | UnsetType = UNSET
```

##### synopsis

```python theme={null}
synopsis: str | None | UnsetType = UNSET
```

##### urls

```python theme={null}
urls: list[str] | None | UnsetType = UNSET
```

##### tag\_ids

```python theme={null}
tag_ids: list[str] | None | UnsetType = UNSET
```

##### containing\_groups

```python theme={null}
containing_groups: (
    list[GroupDescriptionInput] | None | UnsetType
) = UNSET
```

##### sub\_groups

```python theme={null}
sub_groups: (
    list[GroupDescriptionInput] | None | UnsetType
) = UNSET
```

##### front\_image

```python theme={null}
front_image: str | None | UnsetType = UNSET
```

##### back\_image

```python theme={null}
back_image: str | None | UnsetType = UNSET
```

##### custom\_fields

```python theme={null}
custom_fields: dict[str, Any] | None | UnsetType = UNSET
```

### GroupUpdateInput

Bases: `StashInput`

Input for updating groups from schema/types/group.graphql.

#### Attributes

##### id

```python theme={null}
id: str
```

##### name

```python theme={null}
name: str | None | UnsetType = UNSET
```

##### aliases

```python theme={null}
aliases: str | None | UnsetType = UNSET
```

##### duration

```python theme={null}
duration: int | None | UnsetType = UNSET
```

##### date

```python theme={null}
date: str | None | UnsetType = UNSET
```

##### rating100

```python theme={null}
rating100: int | None | UnsetType = Field(
    default=UNSET, ge=0, le=100
)
```

##### studio\_id

```python theme={null}
studio_id: str | None | UnsetType = UNSET
```

##### director

```python theme={null}
director: str | None | UnsetType = UNSET
```

##### synopsis

```python theme={null}
synopsis: str | None | UnsetType = UNSET
```

##### urls

```python theme={null}
urls: list[str] | None | UnsetType = UNSET
```

##### tag\_ids

```python theme={null}
tag_ids: list[str] | None | UnsetType = UNSET
```

##### containing\_groups

```python theme={null}
containing_groups: (
    list[GroupDescriptionInput] | None | UnsetType
) = UNSET
```

##### sub\_groups

```python theme={null}
sub_groups: (
    list[GroupDescriptionInput] | None | UnsetType
) = UNSET
```

##### front\_image

```python theme={null}
front_image: str | None | UnsetType = UNSET
```

##### back\_image

```python theme={null}
back_image: str | None | UnsetType = UNSET
```

##### custom\_fields

```python theme={null}
custom_fields: CustomFieldsInput | None | UnsetType = UNSET
```

### StudioCreateInput

Bases: `StashInput`

Input for creating studios.

#### Attributes

##### name

```python theme={null}
name: str
```

##### urls

```python theme={null}
urls: list[str] | None | UnsetType = UNSET
```

##### parent\_id

```python theme={null}
parent_id: str | None | UnsetType = UNSET
```

##### image

```python theme={null}
image: str | None | UnsetType = UNSET
```

##### stash\_ids

```python theme={null}
stash_ids: list[StashIDInput] | None | UnsetType = UNSET
```

##### rating100

```python theme={null}
rating100: int | None | UnsetType = Field(
    default=UNSET, ge=0, le=100
)
```

##### favorite

```python theme={null}
favorite: bool | None | UnsetType = UNSET
```

##### details

```python theme={null}
details: str | None | UnsetType = UNSET
```

##### aliases

```python theme={null}
aliases: list[str] | None | UnsetType = UNSET
```

##### tag\_ids

```python theme={null}
tag_ids: list[str] | None | UnsetType = UNSET
```

##### ignore\_auto\_tag

```python theme={null}
ignore_auto_tag: bool | None | UnsetType = UNSET
```

##### organized

```python theme={null}
organized: bool | None | UnsetType = UNSET
```

##### custom\_fields

```python theme={null}
custom_fields: dict[str, Any] | None | UnsetType = UNSET
```

### StudioUpdateInput

Bases: `StashInput`

Input for updating studios.

#### Attributes

##### id

```python theme={null}
id: str
```

##### name

```python theme={null}
name: str | None | UnsetType = UNSET
```

##### urls

```python theme={null}
urls: list[str] | None | UnsetType = UNSET
```

##### parent\_id

```python theme={null}
parent_id: str | None | UnsetType = UNSET
```

##### image

```python theme={null}
image: str | None | UnsetType = UNSET
```

##### stash\_ids

```python theme={null}
stash_ids: list[StashIDInput] | None | UnsetType = UNSET
```

##### rating100

```python theme={null}
rating100: int | None | UnsetType = Field(
    default=UNSET, ge=0, le=100
)
```

##### favorite

```python theme={null}
favorite: bool | None | UnsetType = UNSET
```

##### details

```python theme={null}
details: str | None | UnsetType = UNSET
```

##### aliases

```python theme={null}
aliases: list[str] | None | UnsetType = UNSET
```

##### tag\_ids

```python theme={null}
tag_ids: list[str] | None | UnsetType = UNSET
```

##### ignore\_auto\_tag

```python theme={null}
ignore_auto_tag: bool | None | UnsetType = UNSET
```

##### organized

```python theme={null}
organized: bool | None | UnsetType = UNSET
```

##### custom\_fields

```python theme={null}
custom_fields: CustomFieldsInput | None | UnsetType = UNSET
```

### TagCreateInput

Bases: `StashInput`

Input for creating tags.

#### Attributes

##### name

```python theme={null}
name: str
```

##### sort\_name

```python theme={null}
sort_name: str | None | UnsetType = UNSET
```

##### description

```python theme={null}
description: str | None | UnsetType = UNSET
```

##### aliases

```python theme={null}
aliases: list[str] | None | UnsetType = UNSET
```

##### ignore\_auto\_tag

```python theme={null}
ignore_auto_tag: bool | None | UnsetType = UNSET
```

##### favorite

```python theme={null}
favorite: bool | None | UnsetType = UNSET
```

##### image

```python theme={null}
image: str | None | UnsetType = UNSET
```

##### stash\_ids

```python theme={null}
stash_ids: list[StashIDInput] | None | UnsetType = UNSET
```

##### parent\_ids

```python theme={null}
parent_ids: list[str] | None | UnsetType = UNSET
```

##### child\_ids

```python theme={null}
child_ids: list[str] | None | UnsetType = UNSET
```

##### custom\_fields

```python theme={null}
custom_fields: dict[str, Any] | None | UnsetType = UNSET
```

### TagUpdateInput

Bases: `StashInput`

Input for updating tags.

#### Attributes

##### id

```python theme={null}
id: str
```

##### name

```python theme={null}
name: str | None | UnsetType = UNSET
```

##### sort\_name

```python theme={null}
sort_name: str | None | UnsetType = UNSET
```

##### description

```python theme={null}
description: str | None | UnsetType = UNSET
```

##### aliases

```python theme={null}
aliases: list[str] | None | UnsetType = UNSET
```

##### ignore\_auto\_tag

```python theme={null}
ignore_auto_tag: bool | None | UnsetType = UNSET
```

##### favorite

```python theme={null}
favorite: bool | None | UnsetType = UNSET
```

##### image

```python theme={null}
image: str | None | UnsetType = UNSET
```

##### stash\_ids

```python theme={null}
stash_ids: list[StashIDInput] | None | UnsetType = UNSET
```

##### parent\_ids

```python theme={null}
parent_ids: list[str] | None | UnsetType = UNSET
```

##### child\_ids

```python theme={null}
child_ids: list[str] | None | UnsetType = UNSET
```

##### custom\_fields

```python theme={null}
custom_fields: CustomFieldsInput | None | UnsetType = UNSET
```

## Filter Types

### SceneFilterType

Bases: `StashInput`

Input for scene filter.

#### Attributes

##### AND

```python theme={null}
AND: SceneFilterType | None | UnsetType = UNSET
```

##### OR

```python theme={null}
OR: SceneFilterType | None | UnsetType = UNSET
```

##### NOT

```python theme={null}
NOT: SceneFilterType | None | UnsetType = UNSET
```

##### id

```python theme={null}
id: IntCriterionInput | None | UnsetType = UNSET
```

##### title

```python theme={null}
title: StringCriterionInput | None | UnsetType = UNSET
```

##### code

```python theme={null}
code: StringCriterionInput | None | UnsetType = UNSET
```

##### details

```python theme={null}
details: StringCriterionInput | None | UnsetType = UNSET
```

##### director

```python theme={null}
director: StringCriterionInput | None | UnsetType = UNSET
```

##### oshash

```python theme={null}
oshash: StringCriterionInput | None | UnsetType = UNSET
```

##### checksum

```python theme={null}
checksum: StringCriterionInput | None | UnsetType = UNSET
```

##### phash\_distance

```python theme={null}
phash_distance: (
    PhashDistanceCriterionInput | None | UnsetType
) = UNSET
```

##### path

```python theme={null}
path: StringCriterionInput | None | UnsetType = UNSET
```

##### file\_count

```python theme={null}
file_count: IntCriterionInput | None | UnsetType = UNSET
```

##### rating100

```python theme={null}
rating100: IntCriterionInput | None | UnsetType = UNSET
```

##### organized

```python theme={null}
organized: bool | None | UnsetType = UNSET
```

##### o\_counter

```python theme={null}
o_counter: IntCriterionInput | None | UnsetType = UNSET
```

##### duplicated

```python theme={null}
duplicated: DuplicationCriterionInput | None | UnsetType = (
    UNSET
)
```

##### resolution

```python theme={null}
resolution: ResolutionCriterionInput | None | UnsetType = (
    UNSET
)
```

##### orientation

```python theme={null}
orientation: (
    OrientationCriterionInput | None | UnsetType
) = UNSET
```

##### framerate

```python theme={null}
framerate: IntCriterionInput | None | UnsetType = UNSET
```

##### bitrate

```python theme={null}
bitrate: IntCriterionInput | None | UnsetType = UNSET
```

##### video\_codec

```python theme={null}
video_codec: StringCriterionInput | None | UnsetType = UNSET
```

##### audio\_codec

```python theme={null}
audio_codec: StringCriterionInput | None | UnsetType = UNSET
```

##### duration

```python theme={null}
duration: IntCriterionInput | None | UnsetType = UNSET
```

##### has\_markers

```python theme={null}
has_markers: str | None | UnsetType = UNSET
```

##### is\_missing

```python theme={null}
is_missing: str | None | UnsetType = UNSET
```

##### studios

```python theme={null}
studios: (
    HierarchicalMultiCriterionInput | None | UnsetType
) = UNSET
```

##### groups

```python theme={null}
groups: (
    HierarchicalMultiCriterionInput | None | UnsetType
) = UNSET
```

##### galleries

```python theme={null}
galleries: MultiCriterionInput | None | UnsetType = UNSET
```

##### tags

```python theme={null}
tags: HierarchicalMultiCriterionInput | None | UnsetType = (
    UNSET
)
```

##### tag\_count

```python theme={null}
tag_count: IntCriterionInput | None | UnsetType = UNSET
```

##### performer\_tags

```python theme={null}
performer_tags: (
    HierarchicalMultiCriterionInput | None | UnsetType
) = UNSET
```

##### performer\_favorite

```python theme={null}
performer_favorite: bool | None | UnsetType = UNSET
```

##### performer\_age

```python theme={null}
performer_age: IntCriterionInput | None | UnsetType = UNSET
```

##### performers

```python theme={null}
performers: MultiCriterionInput | None | UnsetType = UNSET
```

##### performer\_count

```python theme={null}
performer_count: IntCriterionInput | None | UnsetType = (
    UNSET
)
```

##### stash\_id\_endpoint

```python theme={null}
stash_id_endpoint: (
    StashIDCriterionInput | None | UnsetType
) = UNSET
```

##### stash\_ids\_endpoint

```python theme={null}
stash_ids_endpoint: (
    StashIDsCriterionInput | None | UnsetType
) = UNSET
```

##### stash\_id\_count

```python theme={null}
stash_id_count: IntCriterionInput | None | UnsetType = UNSET
```

##### url

```python theme={null}
url: StringCriterionInput | None | UnsetType = UNSET
```

##### interactive

```python theme={null}
interactive: bool | None | UnsetType = UNSET
```

##### interactive\_speed

```python theme={null}
interactive_speed: IntCriterionInput | None | UnsetType = (
    UNSET
)
```

##### captions

```python theme={null}
captions: StringCriterionInput | None | UnsetType = UNSET
```

##### resume\_time

```python theme={null}
resume_time: IntCriterionInput | None | UnsetType = UNSET
```

##### play\_count

```python theme={null}
play_count: IntCriterionInput | None | UnsetType = UNSET
```

##### play\_duration

```python theme={null}
play_duration: IntCriterionInput | None | UnsetType = UNSET
```

##### last\_played\_at

```python theme={null}
last_played_at: (
    TimestampCriterionInput | None | UnsetType
) = UNSET
```

##### date

```python theme={null}
date: DateCriterionInput | None | UnsetType = UNSET
```

##### created\_at

```python theme={null}
created_at: TimestampCriterionInput | None | UnsetType = (
    UNSET
)
```

##### updated\_at

```python theme={null}
updated_at: TimestampCriterionInput | None | UnsetType = (
    UNSET
)
```

##### galleries\_filter

```python theme={null}
galleries_filter: GalleryFilterType | None | UnsetType = (
    UNSET
)
```

##### performers\_filter

```python theme={null}
performers_filter: (
    PerformerFilterType | None | UnsetType
) = UNSET
```

##### studios\_filter

```python theme={null}
studios_filter: StudioFilterType | None | UnsetType = UNSET
```

##### tags\_filter

```python theme={null}
tags_filter: TagFilterType | None | UnsetType = UNSET
```

##### groups\_filter

```python theme={null}
groups_filter: GroupFilterType | None | UnsetType = UNSET
```

##### markers\_filter

```python theme={null}
markers_filter: SceneMarkerFilterType | None | UnsetType = (
    UNSET
)
```

##### files\_filter

```python theme={null}
files_filter: FileFilterType | None | UnsetType = UNSET
```

##### custom\_fields

```python theme={null}
custom_fields: (
    list[CustomFieldCriterionInput] | None | UnsetType
) = UNSET
```

### PerformerFilterType

Bases: `StashInput`

Input for performer filter.

#### Attributes

##### AND

```python theme={null}
AND: PerformerFilterType | None | UnsetType = UNSET
```

##### OR

```python theme={null}
OR: PerformerFilterType | None | UnsetType = UNSET
```

##### NOT

```python theme={null}
NOT: PerformerFilterType | None | UnsetType = UNSET
```

##### name

```python theme={null}
name: StringCriterionInput | None | UnsetType = UNSET
```

##### disambiguation

```python theme={null}
disambiguation: StringCriterionInput | None | UnsetType = (
    UNSET
)
```

##### details

```python theme={null}
details: StringCriterionInput | None | UnsetType = UNSET
```

##### filter\_favorites

```python theme={null}
filter_favorites: bool | None | UnsetType = UNSET
```

##### birth\_year

```python theme={null}
birth_year: IntCriterionInput | None | UnsetType = UNSET
```

##### age

```python theme={null}
age: IntCriterionInput | None | UnsetType = UNSET
```

##### ethnicity

```python theme={null}
ethnicity: StringCriterionInput | None | UnsetType = UNSET
```

##### country

```python theme={null}
country: StringCriterionInput | None | UnsetType = UNSET
```

##### eye\_color

```python theme={null}
eye_color: StringCriterionInput | None | UnsetType = UNSET
```

##### height\_cm

```python theme={null}
height_cm: IntCriterionInput | None | UnsetType = UNSET
```

##### measurements

```python theme={null}
measurements: StringCriterionInput | None | UnsetType = (
    UNSET
)
```

##### fake\_tits

```python theme={null}
fake_tits: StringCriterionInput | None | UnsetType = UNSET
```

##### penis\_length

```python theme={null}
penis_length: FloatCriterionInput | None | UnsetType = UNSET
```

##### circumcised

```python theme={null}
circumcised: (
    CircumcisionCriterionInput | None | UnsetType
) = UNSET
```

##### career\_length

```python theme={null}
career_length: StringCriterionInput | None | UnsetType = (
    UNSET
)
```

##### career\_start

```python theme={null}
career_start: DateCriterionInput | None | UnsetType = UNSET
```

##### career\_end

```python theme={null}
career_end: DateCriterionInput | None | UnsetType = UNSET
```

##### tattoos

```python theme={null}
tattoos: StringCriterionInput | None | UnsetType = UNSET
```

##### piercings

```python theme={null}
piercings: StringCriterionInput | None | UnsetType = UNSET
```

##### aliases

```python theme={null}
aliases: StringCriterionInput | None | UnsetType = UNSET
```

##### gender

```python theme={null}
gender: GenderCriterionInput | None | UnsetType = UNSET
```

##### is\_missing

```python theme={null}
is_missing: str | None | UnsetType = UNSET
```

##### tags

```python theme={null}
tags: HierarchicalMultiCriterionInput | None | UnsetType = (
    UNSET
)
```

##### tag\_count

```python theme={null}
tag_count: IntCriterionInput | None | UnsetType = UNSET
```

##### scene\_count

```python theme={null}
scene_count: IntCriterionInput | None | UnsetType = UNSET
```

##### image\_count

```python theme={null}
image_count: IntCriterionInput | None | UnsetType = UNSET
```

##### gallery\_count

```python theme={null}
gallery_count: IntCriterionInput | None | UnsetType = UNSET
```

##### play\_count

```python theme={null}
play_count: IntCriterionInput | None | UnsetType = UNSET
```

##### o\_counter

```python theme={null}
o_counter: IntCriterionInput | None | UnsetType = UNSET
```

##### stash\_id\_endpoint

```python theme={null}
stash_id_endpoint: (
    StashIDCriterionInput | None | UnsetType
) = UNSET
```

##### stash\_ids\_endpoint

```python theme={null}
stash_ids_endpoint: (
    StashIDsCriterionInput | None | UnsetType
) = UNSET
```

##### rating100

```python theme={null}
rating100: IntCriterionInput | None | UnsetType = UNSET
```

##### url

```python theme={null}
url: StringCriterionInput | None | UnsetType = UNSET
```

##### hair\_color

```python theme={null}
hair_color: StringCriterionInput | None | UnsetType = UNSET
```

##### weight

```python theme={null}
weight: IntCriterionInput | None | UnsetType = UNSET
```

##### death\_year

```python theme={null}
death_year: IntCriterionInput | None | UnsetType = UNSET
```

##### studios

```python theme={null}
studios: (
    HierarchicalMultiCriterionInput | None | UnsetType
) = UNSET
```

##### groups

```python theme={null}
groups: (
    HierarchicalMultiCriterionInput | None | UnsetType
) = UNSET
```

##### performers

```python theme={null}
performers: MultiCriterionInput | None | UnsetType = UNSET
```

##### ignore\_auto\_tag

```python theme={null}
ignore_auto_tag: bool | None | UnsetType = UNSET
```

##### birthdate

```python theme={null}
birthdate: DateCriterionInput | None | UnsetType = UNSET
```

##### death\_date

```python theme={null}
death_date: DateCriterionInput | None | UnsetType = UNSET
```

##### scenes\_filter

```python theme={null}
scenes_filter: SceneFilterType | None | UnsetType = UNSET
```

##### images\_filter

```python theme={null}
images_filter: ImageFilterType | None | UnsetType = UNSET
```

##### galleries\_filter

```python theme={null}
galleries_filter: GalleryFilterType | None | UnsetType = (
    UNSET
)
```

##### tags\_filter

```python theme={null}
tags_filter: TagFilterType | None | UnsetType = UNSET
```

##### markers\_filter

```python theme={null}
markers_filter: SceneMarkerFilterType | None | UnsetType = (
    UNSET
)
```

##### created\_at

```python theme={null}
created_at: TimestampCriterionInput | None | UnsetType = (
    UNSET
)
```

##### updated\_at

```python theme={null}
updated_at: TimestampCriterionInput | None | UnsetType = (
    UNSET
)
```

##### marker\_count

```python theme={null}
marker_count: IntCriterionInput | None | UnsetType = UNSET
```

##### custom\_fields

```python theme={null}
custom_fields: (
    list[CustomFieldCriterionInput] | None | UnsetType
) = UNSET
```

### GalleryFilterType

Bases: `StashInput`

Input for gallery filter.

#### Attributes

##### AND

```python theme={null}
AND: GalleryFilterType | None | UnsetType = UNSET
```

##### OR

```python theme={null}
OR: GalleryFilterType | None | UnsetType = UNSET
```

##### NOT

```python theme={null}
NOT: GalleryFilterType | None | UnsetType = UNSET
```

##### id

```python theme={null}
id: IntCriterionInput | None | UnsetType = UNSET
```

##### title

```python theme={null}
title: StringCriterionInput | None | UnsetType = UNSET
```

##### details

```python theme={null}
details: StringCriterionInput | None | UnsetType = UNSET
```

##### checksum

```python theme={null}
checksum: StringCriterionInput | None | UnsetType = UNSET
```

##### path

```python theme={null}
path: StringCriterionInput | None | UnsetType = UNSET
```

##### file\_count

```python theme={null}
file_count: IntCriterionInput | None | UnsetType = UNSET
```

##### is\_missing

```python theme={null}
is_missing: str | None | UnsetType = UNSET
```

##### is\_zip

```python theme={null}
is_zip: bool | None | UnsetType = UNSET
```

##### rating100

```python theme={null}
rating100: IntCriterionInput | None | UnsetType = UNSET
```

##### organized

```python theme={null}
organized: bool | None | UnsetType = UNSET
```

##### average\_resolution

```python theme={null}
average_resolution: (
    ResolutionCriterionInput | None | UnsetType
) = UNSET
```

##### has\_chapters

```python theme={null}
has_chapters: str | None | UnsetType = UNSET
```

##### scenes

```python theme={null}
scenes: MultiCriterionInput | None | UnsetType = UNSET
```

##### studios

```python theme={null}
studios: (
    HierarchicalMultiCriterionInput | None | UnsetType
) = UNSET
```

##### tags

```python theme={null}
tags: HierarchicalMultiCriterionInput | None | UnsetType = (
    UNSET
)
```

##### tag\_count

```python theme={null}
tag_count: IntCriterionInput | None | UnsetType = UNSET
```

##### performer\_tags

```python theme={null}
performer_tags: (
    HierarchicalMultiCriterionInput | None | UnsetType
) = UNSET
```

##### performers

```python theme={null}
performers: MultiCriterionInput | None | UnsetType = UNSET
```

##### performer\_count

```python theme={null}
performer_count: IntCriterionInput | None | UnsetType = (
    UNSET
)
```

##### performer\_favorite

```python theme={null}
performer_favorite: bool | None | UnsetType = UNSET
```

##### performer\_age

```python theme={null}
performer_age: IntCriterionInput | None | UnsetType = UNSET
```

##### image\_count

```python theme={null}
image_count: IntCriterionInput | None | UnsetType = UNSET
```

##### url

```python theme={null}
url: StringCriterionInput | None | UnsetType = UNSET
```

##### date

```python theme={null}
date: DateCriterionInput | None | UnsetType = UNSET
```

##### created\_at

```python theme={null}
created_at: TimestampCriterionInput | None | UnsetType = (
    UNSET
)
```

##### updated\_at

```python theme={null}
updated_at: TimestampCriterionInput | None | UnsetType = (
    UNSET
)
```

##### code

```python theme={null}
code: StringCriterionInput | None | UnsetType = UNSET
```

##### photographer

```python theme={null}
photographer: StringCriterionInput | None | UnsetType = (
    UNSET
)
```

##### scenes\_filter

```python theme={null}
scenes_filter: SceneFilterType | None | UnsetType = UNSET
```

##### images\_filter

```python theme={null}
images_filter: ImageFilterType | None | UnsetType = UNSET
```

##### performers\_filter

```python theme={null}
performers_filter: (
    PerformerFilterType | None | UnsetType
) = UNSET
```

##### studios\_filter

```python theme={null}
studios_filter: StudioFilterType | None | UnsetType = UNSET
```

##### tags\_filter

```python theme={null}
tags_filter: TagFilterType | None | UnsetType = UNSET
```

##### files\_filter

```python theme={null}
files_filter: FileFilterType | None | UnsetType = UNSET
```

##### folders\_filter

```python theme={null}
folders_filter: FolderFilterType | None | UnsetType = UNSET
```

##### parent\_folder

```python theme={null}
parent_folder: (
    HierarchicalMultiCriterionInput | None | UnsetType
) = UNSET
```

##### custom\_fields

```python theme={null}
custom_fields: (
    list[CustomFieldCriterionInput] | None | UnsetType
) = UNSET
```

### ImageFilterType

Bases: `StashInput`

Input for image filter.

#### Attributes

##### AND

```python theme={null}
AND: ImageFilterType | None | UnsetType = UNSET
```

##### OR

```python theme={null}
OR: ImageFilterType | None | UnsetType = UNSET
```

##### NOT

```python theme={null}
NOT: ImageFilterType | None | UnsetType = UNSET
```

##### title

```python theme={null}
title: StringCriterionInput | None | UnsetType = UNSET
```

##### details

```python theme={null}
details: StringCriterionInput | None | UnsetType = UNSET
```

##### id

```python theme={null}
id: IntCriterionInput | None | UnsetType = UNSET
```

##### checksum

```python theme={null}
checksum: StringCriterionInput | None | UnsetType = UNSET
```

##### path

```python theme={null}
path: StringCriterionInput | None | UnsetType = UNSET
```

##### file\_count

```python theme={null}
file_count: IntCriterionInput | None | UnsetType = UNSET
```

##### rating100

```python theme={null}
rating100: IntCriterionInput | None | UnsetType = UNSET
```

##### date

```python theme={null}
date: DateCriterionInput | None | UnsetType = UNSET
```

##### url

```python theme={null}
url: StringCriterionInput | None | UnsetType = UNSET
```

##### organized

```python theme={null}
organized: bool | None | UnsetType = UNSET
```

##### o\_counter

```python theme={null}
o_counter: IntCriterionInput | None | UnsetType = UNSET
```

##### resolution

```python theme={null}
resolution: ResolutionCriterionInput | None | UnsetType = (
    UNSET
)
```

##### orientation

```python theme={null}
orientation: (
    OrientationCriterionInput | None | UnsetType
) = UNSET
```

##### is\_missing

```python theme={null}
is_missing: str | None | UnsetType = UNSET
```

##### studios

```python theme={null}
studios: (
    HierarchicalMultiCriterionInput | None | UnsetType
) = UNSET
```

##### tags

```python theme={null}
tags: HierarchicalMultiCriterionInput | None | UnsetType = (
    UNSET
)
```

##### tag\_count

```python theme={null}
tag_count: IntCriterionInput | None | UnsetType = UNSET
```

##### performer\_tags

```python theme={null}
performer_tags: (
    HierarchicalMultiCriterionInput | None | UnsetType
) = UNSET
```

##### performers

```python theme={null}
performers: MultiCriterionInput | None | UnsetType = UNSET
```

##### performer\_count

```python theme={null}
performer_count: IntCriterionInput | None | UnsetType = (
    UNSET
)
```

##### performer\_favorite

```python theme={null}
performer_favorite: bool | None | UnsetType = UNSET
```

##### performer\_age

```python theme={null}
performer_age: IntCriterionInput | None | UnsetType = UNSET
```

##### galleries

```python theme={null}
galleries: MultiCriterionInput | None | UnsetType = UNSET
```

##### created\_at

```python theme={null}
created_at: TimestampCriterionInput | None | UnsetType = (
    UNSET
)
```

##### updated\_at

```python theme={null}
updated_at: TimestampCriterionInput | None | UnsetType = (
    UNSET
)
```

##### code

```python theme={null}
code: StringCriterionInput | None | UnsetType = UNSET
```

##### photographer

```python theme={null}
photographer: StringCriterionInput | None | UnsetType = (
    UNSET
)
```

##### galleries\_filter

```python theme={null}
galleries_filter: GalleryFilterType | None | UnsetType = (
    UNSET
)
```

##### performers\_filter

```python theme={null}
performers_filter: (
    PerformerFilterType | None | UnsetType
) = UNSET
```

##### studios\_filter

```python theme={null}
studios_filter: StudioFilterType | None | UnsetType = UNSET
```

##### tags\_filter

```python theme={null}
tags_filter: TagFilterType | None | UnsetType = UNSET
```

##### files\_filter

```python theme={null}
files_filter: FileFilterType | None | UnsetType = UNSET
```

##### phash\_distance

```python theme={null}
phash_distance: (
    PhashDistanceCriterionInput | None | UnsetType
) = UNSET
```

##### custom\_fields

```python theme={null}
custom_fields: (
    list[CustomFieldCriterionInput] | None | UnsetType
) = UNSET
```

## Result Types

### FindScenesResultType

Bases: `StashResult`

Result type for finding scenes from schema/types/scene.graphql.

#### Attributes

##### count

```python theme={null}
count: int | UnsetType = UNSET
```

##### duration

```python theme={null}
duration: float | UnsetType = UNSET
```

##### filesize

```python theme={null}
filesize: float | UnsetType = UNSET
```

##### scenes

```python theme={null}
scenes: list[Scene] | UnsetType = UNSET
```

### FindPerformersResultType

Bases: `StashResult`

Result type for finding performers from schema/types/performer.graphql.

#### Attributes

##### count

```python theme={null}
count: int | UnsetType = UNSET
```

##### performers

```python theme={null}
performers: list[Performer] | UnsetType = UNSET
```

### FindGalleriesResultType

Bases: `StashResult`

Result type for finding galleries.

#### Attributes

##### count

```python theme={null}
count: int
```

##### galleries

```python theme={null}
galleries: list[Gallery]
```

### FindImagesResultType

Bases: `StashResult`

Result type for finding images from schema/types/image.graphql.

#### Attributes

##### count

```python theme={null}
count: int | UnsetType = UNSET
```

##### megapixels

```python theme={null}
megapixels: float | UnsetType = UNSET
```

##### filesize

```python theme={null}
filesize: float | UnsetType = UNSET
```

##### images

```python theme={null}
images: list[Image] | UnsetType = Field(default=UNSET)
```

## Job Types

### Job

Bases: `FromGraphQLMixin`, `BaseModel`

Job type from schema/types/job.graphql.

#### Attributes

##### id

```python theme={null}
id: str | None | UnsetType = UNSET
```

##### status

```python theme={null}
status: JobStatus | None | UnsetType = UNSET
```

##### sub\_tasks

```python theme={null}
sub_tasks: list[str] | None | UnsetType = Field(
    default=UNSET, alias="subTasks"
)
```

##### description

```python theme={null}
description: str | None | UnsetType = UNSET
```

##### progress

```python theme={null}
progress: float | None | UnsetType = UNSET
```

##### start\_time

```python theme={null}
start_time: Time | None | UnsetType = Field(
    default=UNSET, alias="startTime"
)
```

##### end\_time

```python theme={null}
end_time: Time | None | UnsetType = Field(
    default=UNSET, alias="endTime"
)
```

##### add\_time

```python theme={null}
add_time: Time | None | UnsetType = Field(
    default=UNSET, alias="addTime"
)
```

##### error

```python theme={null}
error: str | None | UnsetType = UNSET
```

### JobStatus

Bases: `StrEnum`

Job status enum from schema/types/job.graphql.

#### Attributes

##### READY

```python theme={null}
READY = 'READY'
```

##### RUNNING

```python theme={null}
RUNNING = 'RUNNING'
```

##### FINISHED

```python theme={null}
FINISHED = 'FINISHED'
```

##### STOPPING

```python theme={null}
STOPPING = 'STOPPING'
```

##### CANCELLED

```python theme={null}
CANCELLED = 'CANCELLED'
```

##### FAILED

```python theme={null}
FAILED = 'FAILED'
```

## Configuration Types

### ConfigResult

Bases: `FromGraphQLMixin`, `BaseModel`

Result type for all configuration.

#### Attributes

##### general

```python theme={null}
general: ConfigGeneralResult | UnsetType = UNSET
```

##### interface

```python theme={null}
interface: ConfigInterfaceResult | UnsetType = UNSET
```

##### dlna

```python theme={null}
dlna: ConfigDLNAResult | UnsetType = UNSET
```

##### scraping

```python theme={null}
scraping: ConfigScrapingResult | UnsetType = UNSET
```

##### defaults

```python theme={null}
defaults: ConfigDefaultSettingsResult | UnsetType = UNSET
```

##### ui

```python theme={null}
ui: dict[str, Any] | UnsetType = UNSET
```

##### plugins

```python theme={null}
plugins: PluginConfigMap | UnsetType = UNSET
```

### StashConfig

Bases: `FromGraphQLMixin`, `BaseModel`

Result type for stash configuration.

#### Attributes

##### path

```python theme={null}
path: str | UnsetType = UNSET
```

##### exclude\_video

```python theme={null}
exclude_video: bool | UnsetType = Field(
    default=UNSET, alias="excludeVideo"
)
```

##### exclude\_image

```python theme={null}
exclude_image: bool | UnsetType = Field(
    default=UNSET, alias="excludeImage"
)
```

## Metadata Types

### ScanMetadataInput

Bases: `StashInput`

Input for metadata scanning from schema/types/metadata.graphql.

#### Attributes

##### paths

```python theme={null}
paths: list[str] | UnsetType = UNSET
```

##### rescan

```python theme={null}
rescan: bool | None | UnsetType = UNSET
```

##### scanGenerateCovers

```python theme={null}
scanGenerateCovers: bool | None | UnsetType = UNSET
```

##### scanGeneratePreviews

```python theme={null}
scanGeneratePreviews: bool | None | UnsetType = UNSET
```

##### scanGenerateImagePreviews

```python theme={null}
scanGenerateImagePreviews: bool | None | UnsetType = UNSET
```

##### scanGenerateSprites

```python theme={null}
scanGenerateSprites: bool | None | UnsetType = UNSET
```

##### scanGeneratePhashes

```python theme={null}
scanGeneratePhashes: bool | None | UnsetType = UNSET
```

##### scanGenerateThumbnails

```python theme={null}
scanGenerateThumbnails: bool | None | UnsetType = UNSET
```

##### scanGenerateClipPreviews

```python theme={null}
scanGenerateClipPreviews: bool | None | UnsetType = UNSET
```

##### scanGenerateImagePhashes

```python theme={null}
scanGenerateImagePhashes: bool | None | UnsetType = UNSET
```

##### filter

```python theme={null}
filter: ScanMetaDataFilterInput | None | UnsetType = UNSET
```

### GenerateMetadataInput

Bases: `StashInput`

Input for metadata generation from schema/types/metadata.graphql.

#### Attributes

##### covers

```python theme={null}
covers: bool | UnsetType = UNSET
```

##### sprites

```python theme={null}
sprites: bool | UnsetType = UNSET
```

##### previews

```python theme={null}
previews: bool | UnsetType = UNSET
```

##### imagePreviews

```python theme={null}
imagePreviews: bool | UnsetType = UNSET
```

##### previewOptions

```python theme={null}
previewOptions: (
    GeneratePreviewOptionsInput | None | UnsetType
) = UNSET
```

##### markers

```python theme={null}
markers: bool | UnsetType = UNSET
```

##### markerImagePreviews

```python theme={null}
markerImagePreviews: bool | UnsetType = UNSET
```

##### markerScreenshots

```python theme={null}
markerScreenshots: bool | UnsetType = UNSET
```

##### transcodes

```python theme={null}
transcodes: bool | UnsetType = UNSET
```

##### forceTranscodes

```python theme={null}
forceTranscodes: bool | UnsetType = UNSET
```

##### phashes

```python theme={null}
phashes: bool | UnsetType = UNSET
```

##### interactiveHeatmapsSpeeds

```python theme={null}
interactiveHeatmapsSpeeds: bool | UnsetType = UNSET
```

##### imageThumbnails

```python theme={null}
imageThumbnails: bool | UnsetType = UNSET
```

##### clipPreviews

```python theme={null}
clipPreviews: bool | UnsetType = UNSET
```

##### imagePhashes

```python theme={null}
imagePhashes: bool | UnsetType = UNSET
```

##### imageIDs

```python theme={null}
imageIDs: list[str] | None | UnsetType = UNSET
```

##### galleryIDs

```python theme={null}
galleryIDs: list[str] | None | UnsetType = UNSET
```

##### paths

```python theme={null}
paths: list[str] | None | UnsetType = UNSET
```

##### sceneIDs

```python theme={null}
sceneIDs: list[str] | None | UnsetType = UNSET
```

##### markerIDs

```python theme={null}
markerIDs: list[str] | None | UnsetType = UNSET
```

##### overwrite

```python theme={null}
overwrite: bool | UnsetType = UNSET
```

### AutoTagMetadataInput

Bases: `StashInput`

Input for auto-tagging metadata from schema/types/metadata.graphql.

#### Attributes

##### paths

```python theme={null}
paths: list[str] | None | UnsetType = UNSET
```

##### performers

```python theme={null}
performers: list[str] | None | UnsetType = UNSET
```

##### studios

```python theme={null}
studios: list[str] | None | UnsetType = UNSET
```

##### tags

```python theme={null}
tags: list[str] | None | UnsetType = UNSET
```

## Plugin Types

### Plugin

Bases: `FromGraphQLMixin`, `BaseModel`

Plugin type from schema/types/plugin.graphql.

#### Attributes

##### id

```python theme={null}
id: str
```

##### name

```python theme={null}
name: str | UnsetType = UNSET
```

##### enabled

```python theme={null}
enabled: bool | UnsetType = UNSET
```

##### paths

```python theme={null}
paths: PluginPaths | UnsetType = UNSET
```

##### description

```python theme={null}
description: str | None | UnsetType = UNSET
```

##### url

```python theme={null}
url: str | None | UnsetType = UNSET
```

##### version

```python theme={null}
version: str | None | UnsetType = UNSET
```

##### tasks

```python theme={null}
tasks: list[PluginTask] | None | UnsetType = UNSET
```

##### hooks

```python theme={null}
hooks: list[PluginHook] | None | UnsetType = UNSET
```

##### settings

```python theme={null}
settings: list[PluginSetting] | None | UnsetType = UNSET
```

##### requires

```python theme={null}
requires: list[str] | None | UnsetType = UNSET
```

### PluginTask

Bases: `FromGraphQLMixin`, `BaseModel`

Plugin task type from schema/types/plugin.graphql.

#### Attributes

##### name

```python theme={null}
name: str | UnsetType = UNSET
```

##### plugin

```python theme={null}
plugin: Plugin | UnsetType = UNSET
```

##### description

```python theme={null}
description: str | None | UnsetType = UNSET
```

## Package Types

### Package

Bases: `FromGraphQLMixin`, `BaseModel`

Package type from schema/types/package.graphql.

#### Attributes

##### package\_id

```python theme={null}
package_id: str | UnsetType = UNSET
```

##### name

```python theme={null}
name: str | UnsetType = UNSET
```

##### version

```python theme={null}
version: str | None | UnsetType = UNSET
```

##### date

```python theme={null}
date: Timestamp | None | UnsetType = UNSET
```

##### requires

```python theme={null}
requires: list[Package] | UnsetType = UNSET
```

##### source\_url

```python theme={null}
source_url: str | UnsetType = Field(
    default=UNSET, alias="sourceURL"
)
```

##### source\_package

```python theme={null}
source_package: Package | None | UnsetType = UNSET
```

##### metadata

```python theme={null}
metadata: Map | UnsetType = UNSET
```

## Scraper Types

### Scraper

Bases: `FromGraphQLMixin`, `BaseModel`

Scraper from schema/types/scraper.graphql.

#### Attributes

##### id

```python theme={null}
id: str | None | UnsetType = UNSET
```

##### name

```python theme={null}
name: str | None | UnsetType = UNSET
```

##### performer

```python theme={null}
performer: ScraperSpec | None | UnsetType = UNSET
```

##### scene

```python theme={null}
scene: ScraperSpec | None | UnsetType = UNSET
```

##### gallery

```python theme={null}
gallery: ScraperSpec | None | UnsetType = UNSET
```

##### image

```python theme={null}
image: ScraperSpec | None | UnsetType = UNSET
```

##### group

```python theme={null}
group: ScraperSpec | None | UnsetType = UNSET
```

### ScrapedScene

Bases: `FromGraphQLMixin`, `BaseModel`

Scene data from scraper from schema/types/scraper.graphql.

#### Attributes

##### title

```python theme={null}
title: str | None | UnsetType = UNSET
```

##### code

```python theme={null}
code: str | None | UnsetType = UNSET
```

##### details

```python theme={null}
details: str | None | UnsetType = UNSET
```

##### director

```python theme={null}
director: str | None | UnsetType = UNSET
```

##### urls

```python theme={null}
urls: list[str] | None | UnsetType = UNSET
```

##### date

```python theme={null}
date: str | None | UnsetType = UNSET
```

##### image

```python theme={null}
image: str | None | UnsetType = UNSET
```

##### file

```python theme={null}
file: SceneFileType | None | UnsetType = UNSET
```

##### studio

```python theme={null}
studio: ScrapedStudio | None | UnsetType = UNSET
```

##### tags

```python theme={null}
tags: list[ScrapedTag] | None | UnsetType = UNSET
```

##### performers

```python theme={null}
performers: list[ScrapedPerformer] | None | UnsetType = (
    UNSET
)
```

##### groups

```python theme={null}
groups: list[ScrapedGroup] | None | UnsetType = UNSET
```

##### remote\_site\_id

```python theme={null}
remote_site_id: str | None | UnsetType = UNSET
```

##### duration

```python theme={null}
duration: int | None | UnsetType = UNSET
```

##### fingerprints

```python theme={null}
fingerprints: (
    list[StashBoxFingerprint] | None | UnsetType
) = UNSET
```

### ScrapedPerformer

Bases: `FromGraphQLMixin`, `BaseModel`

A performer from a scraping operation from schema/types/scraped-performer.graphql.

#### Attributes

##### stored\_id

```python theme={null}
stored_id: str | None | UnsetType = UNSET
```

##### name

```python theme={null}
name: str | None | UnsetType = UNSET
```

##### disambiguation

```python theme={null}
disambiguation: str | None | UnsetType = UNSET
```

##### gender

```python theme={null}
gender: str | None | UnsetType = UNSET
```

##### urls

```python theme={null}
urls: list[str] | None | UnsetType = UNSET
```

##### birthdate

```python theme={null}
birthdate: str | None | UnsetType = UNSET
```

##### ethnicity

```python theme={null}
ethnicity: str | None | UnsetType = UNSET
```

##### country

```python theme={null}
country: str | None | UnsetType = UNSET
```

##### eye\_color

```python theme={null}
eye_color: str | None | UnsetType = UNSET
```

##### height

```python theme={null}
height: str | None | UnsetType = UNSET
```

##### measurements

```python theme={null}
measurements: str | None | UnsetType = UNSET
```

##### fake\_tits

```python theme={null}
fake_tits: str | None | UnsetType = UNSET
```

##### penis\_length

```python theme={null}
penis_length: str | None | UnsetType = UNSET
```

##### circumcised

```python theme={null}
circumcised: str | None | UnsetType = UNSET
```

##### career\_length

```python theme={null}
career_length: str | None | UnsetType = UNSET
```

##### career\_start

```python theme={null}
career_start: str | None | UnsetType = UNSET
```

##### career\_end

```python theme={null}
career_end: str | None | UnsetType = UNSET
```

##### tattoos

```python theme={null}
tattoos: str | None | UnsetType = UNSET
```

##### piercings

```python theme={null}
piercings: str | None | UnsetType = UNSET
```

##### aliases

```python theme={null}
aliases: str | None | UnsetType = UNSET
```

##### tags

```python theme={null}
tags: list[ScrapedTag] | None | UnsetType = UNSET
```

##### images

```python theme={null}
images: list[str] | None | UnsetType = UNSET
```

##### details

```python theme={null}
details: str | None | UnsetType = UNSET
```

##### death\_date

```python theme={null}
death_date: str | None | UnsetType = UNSET
```

##### hair\_color

```python theme={null}
hair_color: str | None | UnsetType = UNSET
```

##### weight

```python theme={null}
weight: str | None | UnsetType = UNSET
```

##### remote\_site\_id

```python theme={null}
remote_site_id: str | None | UnsetType = UNSET
```

## StashBox Types

### StashBox

Bases: `BaseModel`

StashBox configuration from schema/types/stash-box.graphql.

#### Attributes

##### endpoint

```python theme={null}
endpoint: str | None | UnsetType = UNSET
```

##### api\_key

```python theme={null}
api_key: str | None | UnsetType = UNSET
```

##### name

```python theme={null}
name: str | None | UnsetType = UNSET
```

##### max\_requests\_per\_minute

```python theme={null}
max_requests_per_minute: int | None | UnsetType = UNSET
```

## Logging Types

### LogEntry

Bases: `BaseModel`

Log entry type from schema/types/logging.graphql.

#### Attributes

##### time

```python theme={null}
time: Time | None | UnsetType = UNSET
```

##### level

```python theme={null}
level: LogLevel | None | UnsetType = UNSET
```

##### message

```python theme={null}
message: str | None | UnsetType = UNSET
```

### LogLevel

Bases: `StrEnum`

Log level enum from schema/types/logging.graphql.

#### Attributes

##### TRACE

```python theme={null}
TRACE = 'Trace'
```

##### DEBUG

```python theme={null}
DEBUG = 'Debug'
```

##### INFO

```python theme={null}
INFO = 'Info'
```

##### PROGRESS

```python theme={null}
PROGRESS = 'Progress'
```

##### WARNING

```python theme={null}
WARNING = 'Warning'
```

##### ERROR

```python theme={null}
ERROR = 'Error'
```

## Version Types

### Version

Bases: `FromGraphQLMixin`, `BaseModel`

Version information.

#### Attributes

##### version

```python theme={null}
version: str | None | UnsetType = UNSET
```

##### hash

```python theme={null}
hash: str | UnsetType = UNSET
```

##### build\_time

```python theme={null}
build_time: str | UnsetType = UNSET
```

### LatestVersion

Bases: `FromGraphQLMixin`, `BaseModel`

Latest version information.

#### Attributes

##### version

```python theme={null}
version: str | UnsetType = UNSET
```

##### shorthash

```python theme={null}
shorthash: str | UnsetType = UNSET
```

##### release\_date

```python theme={null}
release_date: str | UnsetType = UNSET
```

##### url

```python theme={null}
url: str | UnsetType = UNSET
```
