Skip to content

Queues Response Legacy Dto

immichpy.client.generated.models.queues_response_legacy_dto.QueuesResponseLegacyDto pydantic-model

Bases: BaseModel

QueuesResponseLegacyDto

Show JSON schema:
{
  "$defs": {
    "QueueResponseLegacyDto": {
      "description": "QueueResponseLegacyDto",
      "properties": {
        "jobCounts": {
          "$ref": "#/$defs/QueueStatisticsDto"
        },
        "queueStatus": {
          "$ref": "#/$defs/QueueStatusLegacyDto"
        }
      },
      "required": [
        "jobCounts",
        "queueStatus"
      ],
      "title": "QueueResponseLegacyDto",
      "type": "object"
    },
    "QueueStatisticsDto": {
      "description": "QueueStatisticsDto",
      "properties": {
        "active": {
          "description": "Number of active jobs",
          "title": "Active",
          "type": "integer"
        },
        "completed": {
          "description": "Number of completed jobs",
          "title": "Completed",
          "type": "integer"
        },
        "delayed": {
          "description": "Number of delayed jobs",
          "title": "Delayed",
          "type": "integer"
        },
        "failed": {
          "description": "Number of failed jobs",
          "title": "Failed",
          "type": "integer"
        },
        "paused": {
          "description": "Number of paused jobs",
          "title": "Paused",
          "type": "integer"
        },
        "waiting": {
          "description": "Number of waiting jobs",
          "title": "Waiting",
          "type": "integer"
        }
      },
      "required": [
        "active",
        "completed",
        "delayed",
        "failed",
        "paused",
        "waiting"
      ],
      "title": "QueueStatisticsDto",
      "type": "object"
    },
    "QueueStatusLegacyDto": {
      "description": "QueueStatusLegacyDto",
      "properties": {
        "isActive": {
          "description": "Whether the queue is currently active (has running jobs)",
          "title": "Isactive",
          "type": "boolean"
        },
        "isPaused": {
          "description": "Whether the queue is paused",
          "title": "Ispaused",
          "type": "boolean"
        }
      },
      "required": [
        "isActive",
        "isPaused"
      ],
      "title": "QueueStatusLegacyDto",
      "type": "object"
    }
  },
  "description": "QueuesResponseLegacyDto",
  "properties": {
    "backgroundTask": {
      "$ref": "#/$defs/QueueResponseLegacyDto"
    },
    "backupDatabase": {
      "$ref": "#/$defs/QueueResponseLegacyDto"
    },
    "duplicateDetection": {
      "$ref": "#/$defs/QueueResponseLegacyDto"
    },
    "editor": {
      "$ref": "#/$defs/QueueResponseLegacyDto"
    },
    "faceDetection": {
      "$ref": "#/$defs/QueueResponseLegacyDto"
    },
    "facialRecognition": {
      "$ref": "#/$defs/QueueResponseLegacyDto"
    },
    "library": {
      "$ref": "#/$defs/QueueResponseLegacyDto"
    },
    "metadataExtraction": {
      "$ref": "#/$defs/QueueResponseLegacyDto"
    },
    "migration": {
      "$ref": "#/$defs/QueueResponseLegacyDto"
    },
    "notifications": {
      "$ref": "#/$defs/QueueResponseLegacyDto"
    },
    "ocr": {
      "$ref": "#/$defs/QueueResponseLegacyDto"
    },
    "search": {
      "$ref": "#/$defs/QueueResponseLegacyDto"
    },
    "sidecar": {
      "$ref": "#/$defs/QueueResponseLegacyDto"
    },
    "smartSearch": {
      "$ref": "#/$defs/QueueResponseLegacyDto"
    },
    "storageTemplateMigration": {
      "$ref": "#/$defs/QueueResponseLegacyDto"
    },
    "thumbnailGeneration": {
      "$ref": "#/$defs/QueueResponseLegacyDto"
    },
    "videoConversion": {
      "$ref": "#/$defs/QueueResponseLegacyDto"
    },
    "workflow": {
      "$ref": "#/$defs/QueueResponseLegacyDto"
    }
  },
  "required": [
    "backgroundTask",
    "backupDatabase",
    "duplicateDetection",
    "editor",
    "faceDetection",
    "facialRecognition",
    "library",
    "metadataExtraction",
    "migration",
    "notifications",
    "ocr",
    "search",
    "sidecar",
    "smartSearch",
    "storageTemplateMigration",
    "thumbnailGeneration",
    "videoConversion",
    "workflow"
  ],
  "title": "QueuesResponseLegacyDto",
  "type": "object"
}

Config:

  • populate_by_name: True
  • validate_assignment: True
  • protected_namespaces: ()

Fields:

from_dict classmethod

from_dict(obj: Optional[Dict[str, Any]]) -> Optional[Self]

Create an instance of QueuesResponseLegacyDto from a dict

Source code in immichpy/client/generated/models/queues_response_legacy_dto.py
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
@classmethod
def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
    """Create an instance of QueuesResponseLegacyDto from a dict"""
    if obj is None:
        return None

    if not isinstance(obj, dict):
        return cls.model_validate(obj)

    _obj = cls.model_validate(
        {
            "backgroundTask": QueueResponseLegacyDto.from_dict(
                obj["backgroundTask"]
            )
            if obj.get("backgroundTask") is not None
            else None,
            "backupDatabase": QueueResponseLegacyDto.from_dict(
                obj["backupDatabase"]
            )
            if obj.get("backupDatabase") is not None
            else None,
            "duplicateDetection": QueueResponseLegacyDto.from_dict(
                obj["duplicateDetection"]
            )
            if obj.get("duplicateDetection") is not None
            else None,
            "editor": QueueResponseLegacyDto.from_dict(obj["editor"])
            if obj.get("editor") is not None
            else None,
            "faceDetection": QueueResponseLegacyDto.from_dict(obj["faceDetection"])
            if obj.get("faceDetection") is not None
            else None,
            "facialRecognition": QueueResponseLegacyDto.from_dict(
                obj["facialRecognition"]
            )
            if obj.get("facialRecognition") is not None
            else None,
            "library": QueueResponseLegacyDto.from_dict(obj["library"])
            if obj.get("library") is not None
            else None,
            "metadataExtraction": QueueResponseLegacyDto.from_dict(
                obj["metadataExtraction"]
            )
            if obj.get("metadataExtraction") is not None
            else None,
            "migration": QueueResponseLegacyDto.from_dict(obj["migration"])
            if obj.get("migration") is not None
            else None,
            "notifications": QueueResponseLegacyDto.from_dict(obj["notifications"])
            if obj.get("notifications") is not None
            else None,
            "ocr": QueueResponseLegacyDto.from_dict(obj["ocr"])
            if obj.get("ocr") is not None
            else None,
            "search": QueueResponseLegacyDto.from_dict(obj["search"])
            if obj.get("search") is not None
            else None,
            "sidecar": QueueResponseLegacyDto.from_dict(obj["sidecar"])
            if obj.get("sidecar") is not None
            else None,
            "smartSearch": QueueResponseLegacyDto.from_dict(obj["smartSearch"])
            if obj.get("smartSearch") is not None
            else None,
            "storageTemplateMigration": QueueResponseLegacyDto.from_dict(
                obj["storageTemplateMigration"]
            )
            if obj.get("storageTemplateMigration") is not None
            else None,
            "thumbnailGeneration": QueueResponseLegacyDto.from_dict(
                obj["thumbnailGeneration"]
            )
            if obj.get("thumbnailGeneration") is not None
            else None,
            "videoConversion": QueueResponseLegacyDto.from_dict(
                obj["videoConversion"]
            )
            if obj.get("videoConversion") is not None
            else None,
            "workflow": QueueResponseLegacyDto.from_dict(obj["workflow"])
            if obj.get("workflow") is not None
            else None,
        }
    )
    return _obj

from_json classmethod

from_json(json_str: str) -> Optional[Self]

Create an instance of QueuesResponseLegacyDto from a JSON string

Source code in immichpy/client/generated/models/queues_response_legacy_dto.py
89
90
91
92
@classmethod
def from_json(cls, json_str: str) -> Optional[Self]:
    """Create an instance of QueuesResponseLegacyDto from a JSON string"""
    return cls.from_dict(json.loads(json_str))

to_dict

to_dict() -> Dict[str, Any]

Return the dictionary representation of the model using alias.

This has the following differences from calling pydantic's self.model_dump(by_alias=True):

  • None is only added to the output dict for nullable fields that were set at model initialization. Other fields with value None are ignored.
Source code in immichpy/client/generated/models/queues_response_legacy_dto.py
 94
 95
 96
 97
 98
 99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
def to_dict(self) -> Dict[str, Any]:
    """Return the dictionary representation of the model using alias.

    This has the following differences from calling pydantic's
    `self.model_dump(by_alias=True)`:

    * `None` is only added to the output dict for nullable fields that
      were set at model initialization. Other fields with value `None`
      are ignored.
    """
    excluded_fields: Set[str] = set([])

    _dict = self.model_dump(
        by_alias=True,
        exclude=excluded_fields,
        exclude_none=True,
    )
    # override the default output from pydantic by calling `to_dict()` of background_task
    if self.background_task:
        _dict["backgroundTask"] = self.background_task.to_dict()
    # override the default output from pydantic by calling `to_dict()` of backup_database
    if self.backup_database:
        _dict["backupDatabase"] = self.backup_database.to_dict()
    # override the default output from pydantic by calling `to_dict()` of duplicate_detection
    if self.duplicate_detection:
        _dict["duplicateDetection"] = self.duplicate_detection.to_dict()
    # override the default output from pydantic by calling `to_dict()` of editor
    if self.editor:
        _dict["editor"] = self.editor.to_dict()
    # override the default output from pydantic by calling `to_dict()` of face_detection
    if self.face_detection:
        _dict["faceDetection"] = self.face_detection.to_dict()
    # override the default output from pydantic by calling `to_dict()` of facial_recognition
    if self.facial_recognition:
        _dict["facialRecognition"] = self.facial_recognition.to_dict()
    # override the default output from pydantic by calling `to_dict()` of library
    if self.library:
        _dict["library"] = self.library.to_dict()
    # override the default output from pydantic by calling `to_dict()` of metadata_extraction
    if self.metadata_extraction:
        _dict["metadataExtraction"] = self.metadata_extraction.to_dict()
    # override the default output from pydantic by calling `to_dict()` of migration
    if self.migration:
        _dict["migration"] = self.migration.to_dict()
    # override the default output from pydantic by calling `to_dict()` of notifications
    if self.notifications:
        _dict["notifications"] = self.notifications.to_dict()
    # override the default output from pydantic by calling `to_dict()` of ocr
    if self.ocr:
        _dict["ocr"] = self.ocr.to_dict()
    # override the default output from pydantic by calling `to_dict()` of search
    if self.search:
        _dict["search"] = self.search.to_dict()
    # override the default output from pydantic by calling `to_dict()` of sidecar
    if self.sidecar:
        _dict["sidecar"] = self.sidecar.to_dict()
    # override the default output from pydantic by calling `to_dict()` of smart_search
    if self.smart_search:
        _dict["smartSearch"] = self.smart_search.to_dict()
    # override the default output from pydantic by calling `to_dict()` of storage_template_migration
    if self.storage_template_migration:
        _dict["storageTemplateMigration"] = (
            self.storage_template_migration.to_dict()
        )
    # override the default output from pydantic by calling `to_dict()` of thumbnail_generation
    if self.thumbnail_generation:
        _dict["thumbnailGeneration"] = self.thumbnail_generation.to_dict()
    # override the default output from pydantic by calling `to_dict()` of video_conversion
    if self.video_conversion:
        _dict["videoConversion"] = self.video_conversion.to_dict()
    # override the default output from pydantic by calling `to_dict()` of workflow
    if self.workflow:
        _dict["workflow"] = self.workflow.to_dict()
    return _dict

to_json

to_json() -> str

Returns the JSON representation of the model using alias

Source code in immichpy/client/generated/models/queues_response_legacy_dto.py
84
85
86
87
def to_json(self) -> str:
    """Returns the JSON representation of the model using alias"""
    # TODO: pydantic v2: use .model_dump_json(by_alias=True, exclude_unset=True) instead
    return json.dumps(self.to_dict())

to_str

to_str() -> str

Returns the string representation of the model using alias

Source code in immichpy/client/generated/models/queues_response_legacy_dto.py
80
81
82
def to_str(self) -> str:
    """Returns the string representation of the model using alias"""
    return pprint.pformat(self.model_dump(by_alias=True))