My aggregated monorepo of OCaml code, automaintained
0
fork

Configure Feed

Select the types of activity you want to include in your feed.

Add ocaml-immich: Generated Immich API client

Generated from Immich OpenAPI spec v2.4.1 using ocaml-openapi.

Provides typed OCaml bindings for the Immich photo management API:
- Types.* modules for all API data structures
- Client module with typed request/response functions
- Wrapped as Immich.Types and Immich.Client

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>

+16891
+3382
ocaml-immich/client.ml
··· 1 + (** Immich API 2 + 3 + @version 2.4.1 *) 4 + 5 + (** Client connection type *) 6 + type t = { 7 + session : Requests.t; 8 + base_url : string; 9 + } 10 + 11 + (** Create a new API client. 12 + @param session Optional existing requests session 13 + @param sw Eio switch for managing resources 14 + @param env Eio environment 15 + @param base_url Base URL for the API *) 16 + let create ?session ~sw env ~base_url = 17 + let session = match session with 18 + | Some s -> s 19 + | None -> Requests.create ~sw env 20 + in 21 + { session; base_url } 22 + 23 + (** Get the base URL *) 24 + let base_url t = t.base_url 25 + 26 + (** Get the underlying requests session *) 27 + let session t = t.session 28 + 29 + (** List all activities 30 + 31 + Returns a list of activities for the selected asset or album. The activities are returned in sorted order, with the oldest activities appearing first. *) 32 + let get_activities ~album_id ?asset_id ?level ?type_ ?user_id t () = 33 + let url_path = "/activities" in 34 + let query = Openapi.Runtime.Query.encode (List.concat [ 35 + Openapi.Runtime.Query.singleton ~key:"albumId" ~value:album_id; 36 + Openapi.Runtime.Query.optional ~key:"assetId" ~value:asset_id; 37 + Openapi.Runtime.Query.optional ~key:"level" ~value:level; 38 + Openapi.Runtime.Query.optional ~key:"type" ~value:type_; 39 + Openapi.Runtime.Query.optional ~key:"userId" ~value:user_id 40 + ]) in 41 + let url = t.base_url ^ url_path ^ query in 42 + let response = Requests.get t.session url in 43 + if Requests.Response.ok response then 44 + Openapi.Runtime.Json.decode_json_exn (Jsont.list Types.ActivityResponseDto.t_jsont) (Requests.Response.json response) 45 + else 46 + failwith (Printf.sprintf "HTTP %d: %s" (Requests.Response.status_code response) (Requests.Response.text response)) 47 + 48 + (** Create an activity 49 + 50 + Create a like or a comment for an album, or an asset in an album. *) 51 + let create_activity ~body t () = 52 + let url_path = "/activities" in 53 + let query = "" in 54 + let url = t.base_url ^ url_path ^ query in 55 + let response = Requests.post t.session ~body:(Requests.Body.json (Openapi.Runtime.Json.encode_json Types.ActivityCreateDto.t_jsont body)) url in 56 + if Requests.Response.ok response then 57 + Openapi.Runtime.Json.decode_json_exn Types.ActivityResponseDto.t_jsont (Requests.Response.json response) 58 + else 59 + failwith (Printf.sprintf "HTTP %d: %s" (Requests.Response.status_code response) (Requests.Response.text response)) 60 + 61 + (** Retrieve activity statistics 62 + 63 + Returns the number of likes and comments for a given album or asset in an album. *) 64 + let get_activity_statistics ~album_id ?asset_id t () = 65 + let url_path = "/activities/statistics" in 66 + let query = Openapi.Runtime.Query.encode (List.concat [ 67 + Openapi.Runtime.Query.singleton ~key:"albumId" ~value:album_id; 68 + Openapi.Runtime.Query.optional ~key:"assetId" ~value:asset_id 69 + ]) in 70 + let url = t.base_url ^ url_path ^ query in 71 + let response = Requests.get t.session url in 72 + if Requests.Response.ok response then 73 + Openapi.Runtime.Json.decode_json_exn Types.ActivityStatisticsResponseDto.t_jsont (Requests.Response.json response) 74 + else 75 + failwith (Printf.sprintf "HTTP %d: %s" (Requests.Response.status_code response) (Requests.Response.text response)) 76 + 77 + (** Delete an activity 78 + 79 + Removes a like or comment from a given album or asset in an album. *) 80 + let delete_activity ~id t () = 81 + let url_path = Openapi.Runtime.Path.render ~params:[("id", id)] "/activities/{id}" in 82 + let query = "" in 83 + let url = t.base_url ^ url_path ^ query in 84 + let response = Requests.delete t.session url in 85 + if Requests.Response.ok response then 86 + Requests.Response.json response 87 + else 88 + failwith (Printf.sprintf "HTTP %d: %s" (Requests.Response.status_code response) (Requests.Response.text response)) 89 + 90 + (** Unlink all OAuth accounts 91 + 92 + Unlinks all OAuth accounts associated with user accounts in the system. *) 93 + let unlink_all_oauth_accounts_admin t () = 94 + let url_path = "/admin/auth/unlink-all" in 95 + let query = "" in 96 + let url = t.base_url ^ url_path ^ query in 97 + let response = Requests.post t.session url in 98 + if Requests.Response.ok response then 99 + Requests.Response.json response 100 + else 101 + failwith (Printf.sprintf "HTTP %d: %s" (Requests.Response.status_code response) (Requests.Response.text response)) 102 + 103 + (** List database backups 104 + 105 + Get the list of the successful and failed backups *) 106 + let list_database_backups t () = 107 + let url_path = "/admin/database-backups" in 108 + let query = "" in 109 + let url = t.base_url ^ url_path ^ query in 110 + let response = Requests.get t.session url in 111 + if Requests.Response.ok response then 112 + Openapi.Runtime.Json.decode_json_exn Types.DatabaseBackupListResponseDto.t_jsont (Requests.Response.json response) 113 + else 114 + failwith (Printf.sprintf "HTTP %d: %s" (Requests.Response.status_code response) (Requests.Response.text response)) 115 + 116 + (** Delete database backup 117 + 118 + Delete a backup by its filename *) 119 + let delete_database_backup t () = 120 + let url_path = "/admin/database-backups" in 121 + let query = "" in 122 + let url = t.base_url ^ url_path ^ query in 123 + let response = Requests.delete t.session url in 124 + if Requests.Response.ok response then 125 + Requests.Response.json response 126 + else 127 + failwith (Printf.sprintf "HTTP %d: %s" (Requests.Response.status_code response) (Requests.Response.text response)) 128 + 129 + (** Start database backup restore flow 130 + 131 + Put Immich into maintenance mode to restore a backup (Immich must not be configured) *) 132 + let start_database_restore_flow t () = 133 + let url_path = "/admin/database-backups/start-restore" in 134 + let query = "" in 135 + let url = t.base_url ^ url_path ^ query in 136 + let response = Requests.post t.session url in 137 + if Requests.Response.ok response then 138 + Requests.Response.json response 139 + else 140 + failwith (Printf.sprintf "HTTP %d: %s" (Requests.Response.status_code response) (Requests.Response.text response)) 141 + 142 + (** Upload database backup 143 + 144 + Uploads .sql/.sql.gz file to restore backup from *) 145 + let upload_database_backup ~body t () = 146 + let url_path = "/admin/database-backups/upload" in 147 + let query = "" in 148 + let url = t.base_url ^ url_path ^ query in 149 + let response = Requests.post t.session ~body:(Requests.Body.json (Openapi.Runtime.Json.encode_json Jsont.json body)) url in 150 + if Requests.Response.ok response then 151 + Requests.Response.json response 152 + else 153 + failwith (Printf.sprintf "HTTP %d: %s" (Requests.Response.status_code response) (Requests.Response.text response)) 154 + 155 + (** Download database backup 156 + 157 + Downloads the database backup file *) 158 + let download_database_backup ~filename t () = 159 + let url_path = Openapi.Runtime.Path.render ~params:[("filename", filename)] "/admin/database-backups/{filename}" in 160 + let query = "" in 161 + let url = t.base_url ^ url_path ^ query in 162 + let response = Requests.get t.session url in 163 + if Requests.Response.ok response then 164 + Requests.Response.json response 165 + else 166 + failwith (Printf.sprintf "HTTP %d: %s" (Requests.Response.status_code response) (Requests.Response.text response)) 167 + 168 + (** Set maintenance mode 169 + 170 + Put Immich into or take it out of maintenance mode *) 171 + let set_maintenance_mode ~body t () = 172 + let url_path = "/admin/maintenance" in 173 + let query = "" in 174 + let url = t.base_url ^ url_path ^ query in 175 + let response = Requests.post t.session ~body:(Requests.Body.json (Openapi.Runtime.Json.encode_json Types.SetMaintenanceModeDto.t_jsont body)) url in 176 + if Requests.Response.ok response then 177 + Requests.Response.json response 178 + else 179 + failwith (Printf.sprintf "HTTP %d: %s" (Requests.Response.status_code response) (Requests.Response.text response)) 180 + 181 + (** Detect existing install 182 + 183 + Collect integrity checks and other heuristics about local data. *) 184 + let detect_prior_install t () = 185 + let url_path = "/admin/maintenance/detect-install" in 186 + let query = "" in 187 + let url = t.base_url ^ url_path ^ query in 188 + let response = Requests.get t.session url in 189 + if Requests.Response.ok response then 190 + Openapi.Runtime.Json.decode_json_exn Types.MaintenanceDetectInstallResponseDto.t_jsont (Requests.Response.json response) 191 + else 192 + failwith (Printf.sprintf "HTTP %d: %s" (Requests.Response.status_code response) (Requests.Response.text response)) 193 + 194 + (** Log into maintenance mode 195 + 196 + Login with maintenance token or cookie to receive current information and perform further actions. *) 197 + let maintenance_login ~body t () = 198 + let url_path = "/admin/maintenance/login" in 199 + let query = "" in 200 + let url = t.base_url ^ url_path ^ query in 201 + let response = Requests.post t.session ~body:(Requests.Body.json (Openapi.Runtime.Json.encode_json Types.MaintenanceLoginDto.t_jsont body)) url in 202 + if Requests.Response.ok response then 203 + Openapi.Runtime.Json.decode_json_exn Types.MaintenanceAuthDto.t_jsont (Requests.Response.json response) 204 + else 205 + failwith (Printf.sprintf "HTTP %d: %s" (Requests.Response.status_code response) (Requests.Response.text response)) 206 + 207 + (** Get maintenance mode status 208 + 209 + Fetch information about the currently running maintenance action. *) 210 + let get_maintenance_status t () = 211 + let url_path = "/admin/maintenance/status" in 212 + let query = "" in 213 + let url = t.base_url ^ url_path ^ query in 214 + let response = Requests.get t.session url in 215 + if Requests.Response.ok response then 216 + Openapi.Runtime.Json.decode_json_exn Types.MaintenanceStatusResponseDto.t_jsont (Requests.Response.json response) 217 + else 218 + failwith (Printf.sprintf "HTTP %d: %s" (Requests.Response.status_code response) (Requests.Response.text response)) 219 + 220 + (** Create a notification 221 + 222 + Create a new notification for a specific user. *) 223 + let create_notification ~body t () = 224 + let url_path = "/admin/notifications" in 225 + let query = "" in 226 + let url = t.base_url ^ url_path ^ query in 227 + let response = Requests.post t.session ~body:(Requests.Body.json (Openapi.Runtime.Json.encode_json Types.NotificationCreateDto.t_jsont body)) url in 228 + if Requests.Response.ok response then 229 + Openapi.Runtime.Json.decode_json_exn Types.NotificationDto.t_jsont (Requests.Response.json response) 230 + else 231 + failwith (Printf.sprintf "HTTP %d: %s" (Requests.Response.status_code response) (Requests.Response.text response)) 232 + 233 + (** Render email template 234 + 235 + Retrieve a preview of the provided email template. *) 236 + let get_notification_template_admin ~name ~body t () = 237 + let url_path = Openapi.Runtime.Path.render ~params:[("name", name)] "/admin/notifications/templates/{name}" in 238 + let query = "" in 239 + let url = t.base_url ^ url_path ^ query in 240 + let response = Requests.post t.session ~body:(Requests.Body.json (Openapi.Runtime.Json.encode_json Types.TemplateDto.t_jsont body)) url in 241 + if Requests.Response.ok response then 242 + Openapi.Runtime.Json.decode_json_exn Types.TemplateResponseDto.t_jsont (Requests.Response.json response) 243 + else 244 + failwith (Printf.sprintf "HTTP %d: %s" (Requests.Response.status_code response) (Requests.Response.text response)) 245 + 246 + (** Send test email 247 + 248 + Send a test email using the provided SMTP configuration. *) 249 + let send_test_email_admin ~body t () = 250 + let url_path = "/admin/notifications/test-email" in 251 + let query = "" in 252 + let url = t.base_url ^ url_path ^ query in 253 + let response = Requests.post t.session ~body:(Requests.Body.json (Openapi.Runtime.Json.encode_json Types.SystemConfigSmtpDto.t_jsont body)) url in 254 + if Requests.Response.ok response then 255 + Openapi.Runtime.Json.decode_json_exn Types.TestEmailResponseDto.t_jsont (Requests.Response.json response) 256 + else 257 + failwith (Printf.sprintf "HTTP %d: %s" (Requests.Response.status_code response) (Requests.Response.text response)) 258 + 259 + (** Search users 260 + 261 + Search for users. *) 262 + let search_users_admin ?id ?with_deleted t () = 263 + let url_path = "/admin/users" in 264 + let query = Openapi.Runtime.Query.encode (List.concat [ 265 + Openapi.Runtime.Query.optional ~key:"id" ~value:id; 266 + Openapi.Runtime.Query.optional ~key:"withDeleted" ~value:with_deleted 267 + ]) in 268 + let url = t.base_url ^ url_path ^ query in 269 + let response = Requests.get t.session url in 270 + if Requests.Response.ok response then 271 + Openapi.Runtime.Json.decode_json_exn (Jsont.list Types.UserAdminResponseDto.t_jsont) (Requests.Response.json response) 272 + else 273 + failwith (Printf.sprintf "HTTP %d: %s" (Requests.Response.status_code response) (Requests.Response.text response)) 274 + 275 + (** Create a user 276 + 277 + Create a new user. *) 278 + let create_user_admin ~body t () = 279 + let url_path = "/admin/users" in 280 + let query = "" in 281 + let url = t.base_url ^ url_path ^ query in 282 + let response = Requests.post t.session ~body:(Requests.Body.json (Openapi.Runtime.Json.encode_json Types.UserAdminCreateDto.t_jsont body)) url in 283 + if Requests.Response.ok response then 284 + Openapi.Runtime.Json.decode_json_exn Types.UserAdminResponseDto.t_jsont (Requests.Response.json response) 285 + else 286 + failwith (Printf.sprintf "HTTP %d: %s" (Requests.Response.status_code response) (Requests.Response.text response)) 287 + 288 + (** Retrieve a user 289 + 290 + Retrieve a specific user by their ID. *) 291 + let get_user_admin ~id t () = 292 + let url_path = Openapi.Runtime.Path.render ~params:[("id", id)] "/admin/users/{id}" in 293 + let query = "" in 294 + let url = t.base_url ^ url_path ^ query in 295 + let response = Requests.get t.session url in 296 + if Requests.Response.ok response then 297 + Openapi.Runtime.Json.decode_json_exn Types.UserAdminResponseDto.t_jsont (Requests.Response.json response) 298 + else 299 + failwith (Printf.sprintf "HTTP %d: %s" (Requests.Response.status_code response) (Requests.Response.text response)) 300 + 301 + (** Update a user 302 + 303 + Update an existing user. *) 304 + let update_user_admin ~id ~body t () = 305 + let url_path = Openapi.Runtime.Path.render ~params:[("id", id)] "/admin/users/{id}" in 306 + let query = "" in 307 + let url = t.base_url ^ url_path ^ query in 308 + let response = Requests.put t.session ~body:(Requests.Body.json (Openapi.Runtime.Json.encode_json Types.UserAdminUpdateDto.t_jsont body)) url in 309 + if Requests.Response.ok response then 310 + Openapi.Runtime.Json.decode_json_exn Types.UserAdminResponseDto.t_jsont (Requests.Response.json response) 311 + else 312 + failwith (Printf.sprintf "HTTP %d: %s" (Requests.Response.status_code response) (Requests.Response.text response)) 313 + 314 + (** Delete a user 315 + 316 + Delete a user. *) 317 + let delete_user_admin ~id t () = 318 + let url_path = Openapi.Runtime.Path.render ~params:[("id", id)] "/admin/users/{id}" in 319 + let query = "" in 320 + let url = t.base_url ^ url_path ^ query in 321 + let response = Requests.delete t.session url in 322 + if Requests.Response.ok response then 323 + Openapi.Runtime.Json.decode_json_exn Types.UserAdminResponseDto.t_jsont (Requests.Response.json response) 324 + else 325 + failwith (Printf.sprintf "HTTP %d: %s" (Requests.Response.status_code response) (Requests.Response.text response)) 326 + 327 + (** Retrieve user preferences 328 + 329 + Retrieve the preferences of a specific user. *) 330 + let get_user_preferences_admin ~id t () = 331 + let url_path = Openapi.Runtime.Path.render ~params:[("id", id)] "/admin/users/{id}/preferences" in 332 + let query = "" in 333 + let url = t.base_url ^ url_path ^ query in 334 + let response = Requests.get t.session url in 335 + if Requests.Response.ok response then 336 + Openapi.Runtime.Json.decode_json_exn Types.UserPreferencesResponseDto.t_jsont (Requests.Response.json response) 337 + else 338 + failwith (Printf.sprintf "HTTP %d: %s" (Requests.Response.status_code response) (Requests.Response.text response)) 339 + 340 + (** Update user preferences 341 + 342 + Update the preferences of a specific user. *) 343 + let update_user_preferences_admin ~id ~body t () = 344 + let url_path = Openapi.Runtime.Path.render ~params:[("id", id)] "/admin/users/{id}/preferences" in 345 + let query = "" in 346 + let url = t.base_url ^ url_path ^ query in 347 + let response = Requests.put t.session ~body:(Requests.Body.json (Openapi.Runtime.Json.encode_json Types.UserPreferencesUpdateDto.t_jsont body)) url in 348 + if Requests.Response.ok response then 349 + Openapi.Runtime.Json.decode_json_exn Types.UserPreferencesResponseDto.t_jsont (Requests.Response.json response) 350 + else 351 + failwith (Printf.sprintf "HTTP %d: %s" (Requests.Response.status_code response) (Requests.Response.text response)) 352 + 353 + (** Restore a deleted user 354 + 355 + Restore a previously deleted user. *) 356 + let restore_user_admin ~id t () = 357 + let url_path = Openapi.Runtime.Path.render ~params:[("id", id)] "/admin/users/{id}/restore" in 358 + let query = "" in 359 + let url = t.base_url ^ url_path ^ query in 360 + let response = Requests.post t.session url in 361 + if Requests.Response.ok response then 362 + Openapi.Runtime.Json.decode_json_exn Types.UserAdminResponseDto.t_jsont (Requests.Response.json response) 363 + else 364 + failwith (Printf.sprintf "HTTP %d: %s" (Requests.Response.status_code response) (Requests.Response.text response)) 365 + 366 + (** Retrieve user sessions 367 + 368 + Retrieve all sessions for a specific user. *) 369 + let get_user_sessions_admin ~id t () = 370 + let url_path = Openapi.Runtime.Path.render ~params:[("id", id)] "/admin/users/{id}/sessions" in 371 + let query = "" in 372 + let url = t.base_url ^ url_path ^ query in 373 + let response = Requests.get t.session url in 374 + if Requests.Response.ok response then 375 + Openapi.Runtime.Json.decode_json_exn (Jsont.list Types.SessionResponseDto.t_jsont) (Requests.Response.json response) 376 + else 377 + failwith (Printf.sprintf "HTTP %d: %s" (Requests.Response.status_code response) (Requests.Response.text response)) 378 + 379 + (** Retrieve user statistics 380 + 381 + Retrieve asset statistics for a specific user. *) 382 + let get_user_statistics_admin ~id ?is_favorite ?is_trashed ?visibility t () = 383 + let url_path = Openapi.Runtime.Path.render ~params:[("id", id)] "/admin/users/{id}/statistics" in 384 + let query = Openapi.Runtime.Query.encode (List.concat [ 385 + Openapi.Runtime.Query.optional ~key:"isFavorite" ~value:is_favorite; 386 + Openapi.Runtime.Query.optional ~key:"isTrashed" ~value:is_trashed; 387 + Openapi.Runtime.Query.optional ~key:"visibility" ~value:visibility 388 + ]) in 389 + let url = t.base_url ^ url_path ^ query in 390 + let response = Requests.get t.session url in 391 + if Requests.Response.ok response then 392 + Openapi.Runtime.Json.decode_json_exn Types.AssetStatsResponseDto.t_jsont (Requests.Response.json response) 393 + else 394 + failwith (Printf.sprintf "HTTP %d: %s" (Requests.Response.status_code response) (Requests.Response.text response)) 395 + 396 + (** List all albums 397 + 398 + Retrieve a list of albums available to the authenticated user. *) 399 + let get_all_albums ?asset_id ?shared t () = 400 + let url_path = "/albums" in 401 + let query = Openapi.Runtime.Query.encode (List.concat [ 402 + Openapi.Runtime.Query.optional ~key:"assetId" ~value:asset_id; 403 + Openapi.Runtime.Query.optional ~key:"shared" ~value:shared 404 + ]) in 405 + let url = t.base_url ^ url_path ^ query in 406 + let response = Requests.get t.session url in 407 + if Requests.Response.ok response then 408 + Openapi.Runtime.Json.decode_json_exn (Jsont.list Types.AlbumResponseDto.t_jsont) (Requests.Response.json response) 409 + else 410 + failwith (Printf.sprintf "HTTP %d: %s" (Requests.Response.status_code response) (Requests.Response.text response)) 411 + 412 + (** Create an album 413 + 414 + Create a new album. The album can also be created with initial users and assets. *) 415 + let create_album ~body t () = 416 + let url_path = "/albums" in 417 + let query = "" in 418 + let url = t.base_url ^ url_path ^ query in 419 + let response = Requests.post t.session ~body:(Requests.Body.json (Openapi.Runtime.Json.encode_json Types.CreateAlbumDto.t_jsont body)) url in 420 + if Requests.Response.ok response then 421 + Openapi.Runtime.Json.decode_json_exn Types.AlbumResponseDto.t_jsont (Requests.Response.json response) 422 + else 423 + failwith (Printf.sprintf "HTTP %d: %s" (Requests.Response.status_code response) (Requests.Response.text response)) 424 + 425 + (** Add assets to albums 426 + 427 + Send a list of asset IDs and album IDs to add each asset to each album. *) 428 + let add_assets_to_albums ?key ?slug ~body t () = 429 + let url_path = "/albums/assets" in 430 + let query = Openapi.Runtime.Query.encode (List.concat [ 431 + Openapi.Runtime.Query.optional ~key:"key" ~value:key; 432 + Openapi.Runtime.Query.optional ~key:"slug" ~value:slug 433 + ]) in 434 + let url = t.base_url ^ url_path ^ query in 435 + let response = Requests.put t.session ~body:(Requests.Body.json (Openapi.Runtime.Json.encode_json Types.AlbumsAddAssetsDto.t_jsont body)) url in 436 + if Requests.Response.ok response then 437 + Openapi.Runtime.Json.decode_json_exn Types.AlbumsAddAssetsResponseDto.t_jsont (Requests.Response.json response) 438 + else 439 + failwith (Printf.sprintf "HTTP %d: %s" (Requests.Response.status_code response) (Requests.Response.text response)) 440 + 441 + (** Retrieve album statistics 442 + 443 + Returns statistics about the albums available to the authenticated user. *) 444 + let get_album_statistics t () = 445 + let url_path = "/albums/statistics" in 446 + let query = "" in 447 + let url = t.base_url ^ url_path ^ query in 448 + let response = Requests.get t.session url in 449 + if Requests.Response.ok response then 450 + Openapi.Runtime.Json.decode_json_exn Types.AlbumStatisticsResponseDto.t_jsont (Requests.Response.json response) 451 + else 452 + failwith (Printf.sprintf "HTTP %d: %s" (Requests.Response.status_code response) (Requests.Response.text response)) 453 + 454 + (** Retrieve an album 455 + 456 + Retrieve information about a specific album by its ID. *) 457 + let get_album_info ~id ?key ?slug ?without_assets t () = 458 + let url_path = Openapi.Runtime.Path.render ~params:[("id", id)] "/albums/{id}" in 459 + let query = Openapi.Runtime.Query.encode (List.concat [ 460 + Openapi.Runtime.Query.optional ~key:"key" ~value:key; 461 + Openapi.Runtime.Query.optional ~key:"slug" ~value:slug; 462 + Openapi.Runtime.Query.optional ~key:"withoutAssets" ~value:without_assets 463 + ]) in 464 + let url = t.base_url ^ url_path ^ query in 465 + let response = Requests.get t.session url in 466 + if Requests.Response.ok response then 467 + Openapi.Runtime.Json.decode_json_exn Types.AlbumResponseDto.t_jsont (Requests.Response.json response) 468 + else 469 + failwith (Printf.sprintf "HTTP %d: %s" (Requests.Response.status_code response) (Requests.Response.text response)) 470 + 471 + (** Delete an album 472 + 473 + Delete a specific album by its ID. Note the album is initially trashed and then immediately scheduled for deletion, but relies on a background job to complete the process. *) 474 + let delete_album ~id t () = 475 + let url_path = Openapi.Runtime.Path.render ~params:[("id", id)] "/albums/{id}" in 476 + let query = "" in 477 + let url = t.base_url ^ url_path ^ query in 478 + let response = Requests.delete t.session url in 479 + if Requests.Response.ok response then 480 + Requests.Response.json response 481 + else 482 + failwith (Printf.sprintf "HTTP %d: %s" (Requests.Response.status_code response) (Requests.Response.text response)) 483 + 484 + (** Update an album 485 + 486 + Update the information of a specific album by its ID. This endpoint can be used to update the album name, description, sort order, etc. However, it is not used to add or remove assets or users from the album. *) 487 + let update_album_info ~id ~body t () = 488 + let url_path = Openapi.Runtime.Path.render ~params:[("id", id)] "/albums/{id}" in 489 + let query = "" in 490 + let url = t.base_url ^ url_path ^ query in 491 + let response = Requests.patch t.session ~body:(Requests.Body.json (Openapi.Runtime.Json.encode_json Types.UpdateAlbumDto.t_jsont body)) url in 492 + if Requests.Response.ok response then 493 + Openapi.Runtime.Json.decode_json_exn Types.AlbumResponseDto.t_jsont (Requests.Response.json response) 494 + else 495 + failwith (Printf.sprintf "HTTP %d: %s" (Requests.Response.status_code response) (Requests.Response.text response)) 496 + 497 + (** Add assets to an album 498 + 499 + Add multiple assets to a specific album by its ID. *) 500 + let add_assets_to_album ~id ?key ?slug ~body t () = 501 + let url_path = Openapi.Runtime.Path.render ~params:[("id", id)] "/albums/{id}/assets" in 502 + let query = Openapi.Runtime.Query.encode (List.concat [ 503 + Openapi.Runtime.Query.optional ~key:"key" ~value:key; 504 + Openapi.Runtime.Query.optional ~key:"slug" ~value:slug 505 + ]) in 506 + let url = t.base_url ^ url_path ^ query in 507 + let response = Requests.put t.session ~body:(Requests.Body.json (Openapi.Runtime.Json.encode_json Types.BulkIdsDto.t_jsont body)) url in 508 + if Requests.Response.ok response then 509 + Openapi.Runtime.Json.decode_json_exn (Jsont.list Types.BulkIdResponseDto.t_jsont) (Requests.Response.json response) 510 + else 511 + failwith (Printf.sprintf "HTTP %d: %s" (Requests.Response.status_code response) (Requests.Response.text response)) 512 + 513 + (** Remove assets from an album 514 + 515 + Remove multiple assets from a specific album by its ID. *) 516 + let remove_asset_from_album ~id t () = 517 + let url_path = Openapi.Runtime.Path.render ~params:[("id", id)] "/albums/{id}/assets" in 518 + let query = "" in 519 + let url = t.base_url ^ url_path ^ query in 520 + let response = Requests.delete t.session url in 521 + if Requests.Response.ok response then 522 + Openapi.Runtime.Json.decode_json_exn (Jsont.list Types.BulkIdResponseDto.t_jsont) (Requests.Response.json response) 523 + else 524 + failwith (Printf.sprintf "HTTP %d: %s" (Requests.Response.status_code response) (Requests.Response.text response)) 525 + 526 + (** Update user role 527 + 528 + Change the role for a specific user in a specific album. *) 529 + let update_album_user ~id ~user_id ~body t () = 530 + let url_path = Openapi.Runtime.Path.render ~params:[("id", id); ("userId", user_id)] "/albums/{id}/user/{userId}" in 531 + let query = "" in 532 + let url = t.base_url ^ url_path ^ query in 533 + let response = Requests.put t.session ~body:(Requests.Body.json (Openapi.Runtime.Json.encode_json Types.UpdateAlbumUserDto.t_jsont body)) url in 534 + if Requests.Response.ok response then 535 + Requests.Response.json response 536 + else 537 + failwith (Printf.sprintf "HTTP %d: %s" (Requests.Response.status_code response) (Requests.Response.text response)) 538 + 539 + (** Remove user from album 540 + 541 + Remove a user from an album. Use an ID of "me" to leave a shared album. *) 542 + let remove_user_from_album ~id ~user_id t () = 543 + let url_path = Openapi.Runtime.Path.render ~params:[("id", id); ("userId", user_id)] "/albums/{id}/user/{userId}" in 544 + let query = "" in 545 + let url = t.base_url ^ url_path ^ query in 546 + let response = Requests.delete t.session url in 547 + if Requests.Response.ok response then 548 + Requests.Response.json response 549 + else 550 + failwith (Printf.sprintf "HTTP %d: %s" (Requests.Response.status_code response) (Requests.Response.text response)) 551 + 552 + (** Share album with users 553 + 554 + Share an album with multiple users. Each user can be given a specific role in the album. *) 555 + let add_users_to_album ~id ~body t () = 556 + let url_path = Openapi.Runtime.Path.render ~params:[("id", id)] "/albums/{id}/users" in 557 + let query = "" in 558 + let url = t.base_url ^ url_path ^ query in 559 + let response = Requests.put t.session ~body:(Requests.Body.json (Openapi.Runtime.Json.encode_json Types.AddUsersDto.t_jsont body)) url in 560 + if Requests.Response.ok response then 561 + Openapi.Runtime.Json.decode_json_exn Types.AlbumResponseDto.t_jsont (Requests.Response.json response) 562 + else 563 + failwith (Printf.sprintf "HTTP %d: %s" (Requests.Response.status_code response) (Requests.Response.text response)) 564 + 565 + (** List all API keys 566 + 567 + Retrieve all API keys of the current user. *) 568 + let get_api_keys t () = 569 + let url_path = "/api-keys" in 570 + let query = "" in 571 + let url = t.base_url ^ url_path ^ query in 572 + let response = Requests.get t.session url in 573 + if Requests.Response.ok response then 574 + Openapi.Runtime.Json.decode_json_exn (Jsont.list Types.ApikeyResponseDto.t_jsont) (Requests.Response.json response) 575 + else 576 + failwith (Printf.sprintf "HTTP %d: %s" (Requests.Response.status_code response) (Requests.Response.text response)) 577 + 578 + (** Create an API key 579 + 580 + Creates a new API key. It will be limited to the permissions specified. *) 581 + let create_api_key ~body t () = 582 + let url_path = "/api-keys" in 583 + let query = "" in 584 + let url = t.base_url ^ url_path ^ query in 585 + let response = Requests.post t.session ~body:(Requests.Body.json (Openapi.Runtime.Json.encode_json Types.ApikeyCreateDto.t_jsont body)) url in 586 + if Requests.Response.ok response then 587 + Openapi.Runtime.Json.decode_json_exn Types.ApikeyCreateResponseDto.t_jsont (Requests.Response.json response) 588 + else 589 + failwith (Printf.sprintf "HTTP %d: %s" (Requests.Response.status_code response) (Requests.Response.text response)) 590 + 591 + (** Retrieve the current API key 592 + 593 + Retrieve the API key that is used to access this endpoint. *) 594 + let get_my_api_key t () = 595 + let url_path = "/api-keys/me" in 596 + let query = "" in 597 + let url = t.base_url ^ url_path ^ query in 598 + let response = Requests.get t.session url in 599 + if Requests.Response.ok response then 600 + Openapi.Runtime.Json.decode_json_exn Types.ApikeyResponseDto.t_jsont (Requests.Response.json response) 601 + else 602 + failwith (Printf.sprintf "HTTP %d: %s" (Requests.Response.status_code response) (Requests.Response.text response)) 603 + 604 + (** Retrieve an API key 605 + 606 + Retrieve an API key by its ID. The current user must own this API key. *) 607 + let get_api_key ~id t () = 608 + let url_path = Openapi.Runtime.Path.render ~params:[("id", id)] "/api-keys/{id}" in 609 + let query = "" in 610 + let url = t.base_url ^ url_path ^ query in 611 + let response = Requests.get t.session url in 612 + if Requests.Response.ok response then 613 + Openapi.Runtime.Json.decode_json_exn Types.ApikeyResponseDto.t_jsont (Requests.Response.json response) 614 + else 615 + failwith (Printf.sprintf "HTTP %d: %s" (Requests.Response.status_code response) (Requests.Response.text response)) 616 + 617 + (** Update an API key 618 + 619 + Updates the name and permissions of an API key by its ID. The current user must own this API key. *) 620 + let update_api_key ~id ~body t () = 621 + let url_path = Openapi.Runtime.Path.render ~params:[("id", id)] "/api-keys/{id}" in 622 + let query = "" in 623 + let url = t.base_url ^ url_path ^ query in 624 + let response = Requests.put t.session ~body:(Requests.Body.json (Openapi.Runtime.Json.encode_json Types.ApikeyUpdateDto.t_jsont body)) url in 625 + if Requests.Response.ok response then 626 + Openapi.Runtime.Json.decode_json_exn Types.ApikeyResponseDto.t_jsont (Requests.Response.json response) 627 + else 628 + failwith (Printf.sprintf "HTTP %d: %s" (Requests.Response.status_code response) (Requests.Response.text response)) 629 + 630 + (** Delete an API key 631 + 632 + Deletes an API key identified by its ID. The current user must own this API key. *) 633 + let delete_api_key ~id t () = 634 + let url_path = Openapi.Runtime.Path.render ~params:[("id", id)] "/api-keys/{id}" in 635 + let query = "" in 636 + let url = t.base_url ^ url_path ^ query in 637 + let response = Requests.delete t.session url in 638 + if Requests.Response.ok response then 639 + Requests.Response.json response 640 + else 641 + failwith (Printf.sprintf "HTTP %d: %s" (Requests.Response.status_code response) (Requests.Response.text response)) 642 + 643 + (** Upload asset 644 + 645 + Uploads a new asset to the server. *) 646 + let upload_asset ?key ?slug ~body t () = 647 + let url_path = "/assets" in 648 + let query = Openapi.Runtime.Query.encode (List.concat [ 649 + Openapi.Runtime.Query.optional ~key:"key" ~value:key; 650 + Openapi.Runtime.Query.optional ~key:"slug" ~value:slug 651 + ]) in 652 + let url = t.base_url ^ url_path ^ query in 653 + let response = Requests.post t.session ~body:(Requests.Body.json (Openapi.Runtime.Json.encode_json Jsont.json body)) url in 654 + if Requests.Response.ok response then 655 + Openapi.Runtime.Json.decode_json_exn Types.AssetMediaResponseDto.t_jsont (Requests.Response.json response) 656 + else 657 + failwith (Printf.sprintf "HTTP %d: %s" (Requests.Response.status_code response) (Requests.Response.text response)) 658 + 659 + (** Update assets 660 + 661 + Updates multiple assets at the same time. *) 662 + let update_assets ~body t () = 663 + let url_path = "/assets" in 664 + let query = "" in 665 + let url = t.base_url ^ url_path ^ query in 666 + let response = Requests.put t.session ~body:(Requests.Body.json (Openapi.Runtime.Json.encode_json Types.AssetBulkUpdateDto.t_jsont body)) url in 667 + if Requests.Response.ok response then 668 + Requests.Response.json response 669 + else 670 + failwith (Printf.sprintf "HTTP %d: %s" (Requests.Response.status_code response) (Requests.Response.text response)) 671 + 672 + (** Delete assets 673 + 674 + Deletes multiple assets at the same time. *) 675 + let delete_assets t () = 676 + let url_path = "/assets" in 677 + let query = "" in 678 + let url = t.base_url ^ url_path ^ query in 679 + let response = Requests.delete t.session url in 680 + if Requests.Response.ok response then 681 + Requests.Response.json response 682 + else 683 + failwith (Printf.sprintf "HTTP %d: %s" (Requests.Response.status_code response) (Requests.Response.text response)) 684 + 685 + (** Check bulk upload 686 + 687 + Determine which assets have already been uploaded to the server based on their SHA1 checksums. *) 688 + let check_bulk_upload ~body t () = 689 + let url_path = "/assets/bulk-upload-check" in 690 + let query = "" in 691 + let url = t.base_url ^ url_path ^ query in 692 + let response = Requests.post t.session ~body:(Requests.Body.json (Openapi.Runtime.Json.encode_json Types.AssetBulkUploadCheckDto.t_jsont body)) url in 693 + if Requests.Response.ok response then 694 + Openapi.Runtime.Json.decode_json_exn Types.AssetBulkUploadCheckResponseDto.t_jsont (Requests.Response.json response) 695 + else 696 + failwith (Printf.sprintf "HTTP %d: %s" (Requests.Response.status_code response) (Requests.Response.text response)) 697 + 698 + (** Copy asset 699 + 700 + Copy asset information like albums, tags, etc. from one asset to another. *) 701 + let copy_asset ~body t () = 702 + let url_path = "/assets/copy" in 703 + let query = "" in 704 + let url = t.base_url ^ url_path ^ query in 705 + let response = Requests.put t.session ~body:(Requests.Body.json (Openapi.Runtime.Json.encode_json Types.AssetCopyDto.t_jsont body)) url in 706 + if Requests.Response.ok response then 707 + Requests.Response.json response 708 + else 709 + failwith (Printf.sprintf "HTTP %d: %s" (Requests.Response.status_code response) (Requests.Response.text response)) 710 + 711 + (** Retrieve assets by device ID 712 + 713 + Get all asset of a device that are in the database, ID only. *) 714 + let get_all_user_assets_by_device_id ~device_id t () = 715 + let url_path = Openapi.Runtime.Path.render ~params:[("deviceId", device_id)] "/assets/device/{deviceId}" in 716 + let query = "" in 717 + let url = t.base_url ^ url_path ^ query in 718 + let response = Requests.get t.session url in 719 + if Requests.Response.ok response then 720 + Requests.Response.json response 721 + else 722 + failwith (Printf.sprintf "HTTP %d: %s" (Requests.Response.status_code response) (Requests.Response.text response)) 723 + 724 + (** Check existing assets 725 + 726 + Checks if multiple assets exist on the server and returns all existing - used by background backup *) 727 + let check_existing_assets ~body t () = 728 + let url_path = "/assets/exist" in 729 + let query = "" in 730 + let url = t.base_url ^ url_path ^ query in 731 + let response = Requests.post t.session ~body:(Requests.Body.json (Openapi.Runtime.Json.encode_json Types.CheckExistingAssetsDto.t_jsont body)) url in 732 + if Requests.Response.ok response then 733 + Openapi.Runtime.Json.decode_json_exn Types.CheckExistingAssetsResponseDto.t_jsont (Requests.Response.json response) 734 + else 735 + failwith (Printf.sprintf "HTTP %d: %s" (Requests.Response.status_code response) (Requests.Response.text response)) 736 + 737 + (** Run an asset job 738 + 739 + Run a specific job on a set of assets. *) 740 + let run_asset_jobs ~body t () = 741 + let url_path = "/assets/jobs" in 742 + let query = "" in 743 + let url = t.base_url ^ url_path ^ query in 744 + let response = Requests.post t.session ~body:(Requests.Body.json (Openapi.Runtime.Json.encode_json Types.AssetJobsDto.t_jsont body)) url in 745 + if Requests.Response.ok response then 746 + Requests.Response.json response 747 + else 748 + failwith (Printf.sprintf "HTTP %d: %s" (Requests.Response.status_code response) (Requests.Response.text response)) 749 + 750 + (** Upsert asset metadata 751 + 752 + Upsert metadata key-value pairs for multiple assets. *) 753 + let update_bulk_asset_metadata ~body t () = 754 + let url_path = "/assets/metadata" in 755 + let query = "" in 756 + let url = t.base_url ^ url_path ^ query in 757 + let response = Requests.put t.session ~body:(Requests.Body.json (Openapi.Runtime.Json.encode_json Types.AssetMetadataBulkUpsertDto.t_jsont body)) url in 758 + if Requests.Response.ok response then 759 + Openapi.Runtime.Json.decode_json_exn (Jsont.list Types.AssetMetadataBulkResponseDto.t_jsont) (Requests.Response.json response) 760 + else 761 + failwith (Printf.sprintf "HTTP %d: %s" (Requests.Response.status_code response) (Requests.Response.text response)) 762 + 763 + (** Delete asset metadata 764 + 765 + Delete metadata key-value pairs for multiple assets. *) 766 + let delete_bulk_asset_metadata t () = 767 + let url_path = "/assets/metadata" in 768 + let query = "" in 769 + let url = t.base_url ^ url_path ^ query in 770 + let response = Requests.delete t.session url in 771 + if Requests.Response.ok response then 772 + Requests.Response.json response 773 + else 774 + failwith (Printf.sprintf "HTTP %d: %s" (Requests.Response.status_code response) (Requests.Response.text response)) 775 + 776 + (** Get random assets 777 + 778 + Retrieve a specified number of random assets for the authenticated user. *) 779 + let get_random ?count t () = 780 + let url_path = "/assets/random" in 781 + let query = Openapi.Runtime.Query.encode (List.concat [ 782 + Openapi.Runtime.Query.optional ~key:"count" ~value:count 783 + ]) in 784 + let url = t.base_url ^ url_path ^ query in 785 + let response = Requests.get t.session url in 786 + if Requests.Response.ok response then 787 + Openapi.Runtime.Json.decode_json_exn (Jsont.list Types.AssetResponseDto.t_jsont) (Requests.Response.json response) 788 + else 789 + failwith (Printf.sprintf "HTTP %d: %s" (Requests.Response.status_code response) (Requests.Response.text response)) 790 + 791 + (** Get asset statistics 792 + 793 + Retrieve various statistics about the assets owned by the authenticated user. *) 794 + let get_asset_statistics ?is_favorite ?is_trashed ?visibility t () = 795 + let url_path = "/assets/statistics" in 796 + let query = Openapi.Runtime.Query.encode (List.concat [ 797 + Openapi.Runtime.Query.optional ~key:"isFavorite" ~value:is_favorite; 798 + Openapi.Runtime.Query.optional ~key:"isTrashed" ~value:is_trashed; 799 + Openapi.Runtime.Query.optional ~key:"visibility" ~value:visibility 800 + ]) in 801 + let url = t.base_url ^ url_path ^ query in 802 + let response = Requests.get t.session url in 803 + if Requests.Response.ok response then 804 + Openapi.Runtime.Json.decode_json_exn Types.AssetStatsResponseDto.t_jsont (Requests.Response.json response) 805 + else 806 + failwith (Printf.sprintf "HTTP %d: %s" (Requests.Response.status_code response) (Requests.Response.text response)) 807 + 808 + (** Retrieve an asset 809 + 810 + Retrieve detailed information about a specific asset. *) 811 + let get_asset_info ~id ?key ?slug t () = 812 + let url_path = Openapi.Runtime.Path.render ~params:[("id", id)] "/assets/{id}" in 813 + let query = Openapi.Runtime.Query.encode (List.concat [ 814 + Openapi.Runtime.Query.optional ~key:"key" ~value:key; 815 + Openapi.Runtime.Query.optional ~key:"slug" ~value:slug 816 + ]) in 817 + let url = t.base_url ^ url_path ^ query in 818 + let response = Requests.get t.session url in 819 + if Requests.Response.ok response then 820 + Openapi.Runtime.Json.decode_json_exn Types.AssetResponseDto.t_jsont (Requests.Response.json response) 821 + else 822 + failwith (Printf.sprintf "HTTP %d: %s" (Requests.Response.status_code response) (Requests.Response.text response)) 823 + 824 + (** Update an asset 825 + 826 + Update information of a specific asset. *) 827 + let update_asset ~id ~body t () = 828 + let url_path = Openapi.Runtime.Path.render ~params:[("id", id)] "/assets/{id}" in 829 + let query = "" in 830 + let url = t.base_url ^ url_path ^ query in 831 + let response = Requests.put t.session ~body:(Requests.Body.json (Openapi.Runtime.Json.encode_json Types.UpdateAssetDto.t_jsont body)) url in 832 + if Requests.Response.ok response then 833 + Openapi.Runtime.Json.decode_json_exn Types.AssetResponseDto.t_jsont (Requests.Response.json response) 834 + else 835 + failwith (Printf.sprintf "HTTP %d: %s" (Requests.Response.status_code response) (Requests.Response.text response)) 836 + 837 + (** Retrieve edits for an existing asset 838 + 839 + Retrieve a series of edit actions (crop, rotate, mirror) associated with the specified asset. *) 840 + let get_asset_edits ~id t () = 841 + let url_path = Openapi.Runtime.Path.render ~params:[("id", id)] "/assets/{id}/edits" in 842 + let query = "" in 843 + let url = t.base_url ^ url_path ^ query in 844 + let response = Requests.get t.session url in 845 + if Requests.Response.ok response then 846 + Openapi.Runtime.Json.decode_json_exn Types.AssetEditsDto.t_jsont (Requests.Response.json response) 847 + else 848 + failwith (Printf.sprintf "HTTP %d: %s" (Requests.Response.status_code response) (Requests.Response.text response)) 849 + 850 + (** Apply edits to an existing asset 851 + 852 + Apply a series of edit actions (crop, rotate, mirror) to the specified asset. *) 853 + let edit_asset ~id ~body t () = 854 + let url_path = Openapi.Runtime.Path.render ~params:[("id", id)] "/assets/{id}/edits" in 855 + let query = "" in 856 + let url = t.base_url ^ url_path ^ query in 857 + let response = Requests.put t.session ~body:(Requests.Body.json (Openapi.Runtime.Json.encode_json Types.AssetEditActionListDto.t_jsont body)) url in 858 + if Requests.Response.ok response then 859 + Openapi.Runtime.Json.decode_json_exn Types.AssetEditsDto.t_jsont (Requests.Response.json response) 860 + else 861 + failwith (Printf.sprintf "HTTP %d: %s" (Requests.Response.status_code response) (Requests.Response.text response)) 862 + 863 + (** Remove edits from an existing asset 864 + 865 + Removes all edit actions (crop, rotate, mirror) associated with the specified asset. *) 866 + let remove_asset_edits ~id t () = 867 + let url_path = Openapi.Runtime.Path.render ~params:[("id", id)] "/assets/{id}/edits" in 868 + let query = "" in 869 + let url = t.base_url ^ url_path ^ query in 870 + let response = Requests.delete t.session url in 871 + if Requests.Response.ok response then 872 + Requests.Response.json response 873 + else 874 + failwith (Printf.sprintf "HTTP %d: %s" (Requests.Response.status_code response) (Requests.Response.text response)) 875 + 876 + (** Get asset metadata 877 + 878 + Retrieve all metadata key-value pairs associated with the specified asset. *) 879 + let get_asset_metadata ~id t () = 880 + let url_path = Openapi.Runtime.Path.render ~params:[("id", id)] "/assets/{id}/metadata" in 881 + let query = "" in 882 + let url = t.base_url ^ url_path ^ query in 883 + let response = Requests.get t.session url in 884 + if Requests.Response.ok response then 885 + Openapi.Runtime.Json.decode_json_exn (Jsont.list Types.AssetMetadataResponseDto.t_jsont) (Requests.Response.json response) 886 + else 887 + failwith (Printf.sprintf "HTTP %d: %s" (Requests.Response.status_code response) (Requests.Response.text response)) 888 + 889 + (** Update asset metadata 890 + 891 + Update or add metadata key-value pairs for the specified asset. *) 892 + let update_asset_metadata ~id ~body t () = 893 + let url_path = Openapi.Runtime.Path.render ~params:[("id", id)] "/assets/{id}/metadata" in 894 + let query = "" in 895 + let url = t.base_url ^ url_path ^ query in 896 + let response = Requests.put t.session ~body:(Requests.Body.json (Openapi.Runtime.Json.encode_json Types.AssetMetadataUpsertDto.t_jsont body)) url in 897 + if Requests.Response.ok response then 898 + Openapi.Runtime.Json.decode_json_exn (Jsont.list Types.AssetMetadataResponseDto.t_jsont) (Requests.Response.json response) 899 + else 900 + failwith (Printf.sprintf "HTTP %d: %s" (Requests.Response.status_code response) (Requests.Response.text response)) 901 + 902 + (** Retrieve asset metadata by key 903 + 904 + Retrieve the value of a specific metadata key associated with the specified asset. *) 905 + let get_asset_metadata_by_key ~id ~key t () = 906 + let url_path = Openapi.Runtime.Path.render ~params:[("id", id); ("key", key)] "/assets/{id}/metadata/{key}" in 907 + let query = "" in 908 + let url = t.base_url ^ url_path ^ query in 909 + let response = Requests.get t.session url in 910 + if Requests.Response.ok response then 911 + Openapi.Runtime.Json.decode_json_exn Types.AssetMetadataResponseDto.t_jsont (Requests.Response.json response) 912 + else 913 + failwith (Printf.sprintf "HTTP %d: %s" (Requests.Response.status_code response) (Requests.Response.text response)) 914 + 915 + (** Delete asset metadata by key 916 + 917 + Delete a specific metadata key-value pair associated with the specified asset. *) 918 + let delete_asset_metadata ~id ~key t () = 919 + let url_path = Openapi.Runtime.Path.render ~params:[("id", id); ("key", key)] "/assets/{id}/metadata/{key}" in 920 + let query = "" in 921 + let url = t.base_url ^ url_path ^ query in 922 + let response = Requests.delete t.session url in 923 + if Requests.Response.ok response then 924 + Requests.Response.json response 925 + else 926 + failwith (Printf.sprintf "HTTP %d: %s" (Requests.Response.status_code response) (Requests.Response.text response)) 927 + 928 + (** Retrieve asset OCR data 929 + 930 + Retrieve all OCR (Optical Character Recognition) data associated with the specified asset. *) 931 + let get_asset_ocr ~id t () = 932 + let url_path = Openapi.Runtime.Path.render ~params:[("id", id)] "/assets/{id}/ocr" in 933 + let query = "" in 934 + let url = t.base_url ^ url_path ^ query in 935 + let response = Requests.get t.session url in 936 + if Requests.Response.ok response then 937 + Openapi.Runtime.Json.decode_json_exn (Jsont.list Types.AssetOcrResponseDto.t_jsont) (Requests.Response.json response) 938 + else 939 + failwith (Printf.sprintf "HTTP %d: %s" (Requests.Response.status_code response) (Requests.Response.text response)) 940 + 941 + (** Download original asset 942 + 943 + Downloads the original file of the specified asset. *) 944 + let download_asset ~id ?edited ?key ?slug t () = 945 + let url_path = Openapi.Runtime.Path.render ~params:[("id", id)] "/assets/{id}/original" in 946 + let query = Openapi.Runtime.Query.encode (List.concat [ 947 + Openapi.Runtime.Query.optional ~key:"edited" ~value:edited; 948 + Openapi.Runtime.Query.optional ~key:"key" ~value:key; 949 + Openapi.Runtime.Query.optional ~key:"slug" ~value:slug 950 + ]) in 951 + let url = t.base_url ^ url_path ^ query in 952 + let response = Requests.get t.session url in 953 + if Requests.Response.ok response then 954 + Requests.Response.json response 955 + else 956 + failwith (Printf.sprintf "HTTP %d: %s" (Requests.Response.status_code response) (Requests.Response.text response)) 957 + 958 + (** Replace asset 959 + 960 + Replace the asset with new file, without changing its id. *) 961 + let replace_asset ~id ?key ?slug ~body t () = 962 + let url_path = Openapi.Runtime.Path.render ~params:[("id", id)] "/assets/{id}/original" in 963 + let query = Openapi.Runtime.Query.encode (List.concat [ 964 + Openapi.Runtime.Query.optional ~key:"key" ~value:key; 965 + Openapi.Runtime.Query.optional ~key:"slug" ~value:slug 966 + ]) in 967 + let url = t.base_url ^ url_path ^ query in 968 + let response = Requests.put t.session ~body:(Requests.Body.json (Openapi.Runtime.Json.encode_json Jsont.json body)) url in 969 + if Requests.Response.ok response then 970 + Openapi.Runtime.Json.decode_json_exn Types.AssetMediaResponseDto.t_jsont (Requests.Response.json response) 971 + else 972 + failwith (Printf.sprintf "HTTP %d: %s" (Requests.Response.status_code response) (Requests.Response.text response)) 973 + 974 + (** View asset thumbnail 975 + 976 + Retrieve the thumbnail image for the specified asset. Viewing the fullsize thumbnail might redirect to downloadAsset, which requires a different permission. *) 977 + let view_asset ~id ?edited ?key ?size ?slug t () = 978 + let url_path = Openapi.Runtime.Path.render ~params:[("id", id)] "/assets/{id}/thumbnail" in 979 + let query = Openapi.Runtime.Query.encode (List.concat [ 980 + Openapi.Runtime.Query.optional ~key:"edited" ~value:edited; 981 + Openapi.Runtime.Query.optional ~key:"key" ~value:key; 982 + Openapi.Runtime.Query.optional ~key:"size" ~value:size; 983 + Openapi.Runtime.Query.optional ~key:"slug" ~value:slug 984 + ]) in 985 + let url = t.base_url ^ url_path ^ query in 986 + let response = Requests.get t.session url in 987 + if Requests.Response.ok response then 988 + Requests.Response.json response 989 + else 990 + failwith (Printf.sprintf "HTTP %d: %s" (Requests.Response.status_code response) (Requests.Response.text response)) 991 + 992 + (** Play asset video 993 + 994 + Streams the video file for the specified asset. This endpoint also supports byte range requests. *) 995 + let play_asset_video ~id ?key ?slug t () = 996 + let url_path = Openapi.Runtime.Path.render ~params:[("id", id)] "/assets/{id}/video/playback" in 997 + let query = Openapi.Runtime.Query.encode (List.concat [ 998 + Openapi.Runtime.Query.optional ~key:"key" ~value:key; 999 + Openapi.Runtime.Query.optional ~key:"slug" ~value:slug 1000 + ]) in 1001 + let url = t.base_url ^ url_path ^ query in 1002 + let response = Requests.get t.session url in 1003 + if Requests.Response.ok response then 1004 + Requests.Response.json response 1005 + else 1006 + failwith (Printf.sprintf "HTTP %d: %s" (Requests.Response.status_code response) (Requests.Response.text response)) 1007 + 1008 + (** Register admin 1009 + 1010 + Create the first admin user in the system. *) 1011 + let sign_up_admin ~body t () = 1012 + let url_path = "/auth/admin-sign-up" in 1013 + let query = "" in 1014 + let url = t.base_url ^ url_path ^ query in 1015 + let response = Requests.post t.session ~body:(Requests.Body.json (Openapi.Runtime.Json.encode_json Types.SignUpDto.t_jsont body)) url in 1016 + if Requests.Response.ok response then 1017 + Openapi.Runtime.Json.decode_json_exn Types.UserAdminResponseDto.t_jsont (Requests.Response.json response) 1018 + else 1019 + failwith (Printf.sprintf "HTTP %d: %s" (Requests.Response.status_code response) (Requests.Response.text response)) 1020 + 1021 + (** Change password 1022 + 1023 + Change the password of the current user. *) 1024 + let change_password ~body t () = 1025 + let url_path = "/auth/change-password" in 1026 + let query = "" in 1027 + let url = t.base_url ^ url_path ^ query in 1028 + let response = Requests.post t.session ~body:(Requests.Body.json (Openapi.Runtime.Json.encode_json Types.ChangePasswordDto.t_jsont body)) url in 1029 + if Requests.Response.ok response then 1030 + Openapi.Runtime.Json.decode_json_exn Types.UserAdminResponseDto.t_jsont (Requests.Response.json response) 1031 + else 1032 + failwith (Printf.sprintf "HTTP %d: %s" (Requests.Response.status_code response) (Requests.Response.text response)) 1033 + 1034 + (** Login 1035 + 1036 + Login with username and password and receive a session token. *) 1037 + let login ~body t () = 1038 + let url_path = "/auth/login" in 1039 + let query = "" in 1040 + let url = t.base_url ^ url_path ^ query in 1041 + let response = Requests.post t.session ~body:(Requests.Body.json (Openapi.Runtime.Json.encode_json Types.LoginCredentialDto.t_jsont body)) url in 1042 + if Requests.Response.ok response then 1043 + Openapi.Runtime.Json.decode_json_exn Types.LoginResponseDto.t_jsont (Requests.Response.json response) 1044 + else 1045 + failwith (Printf.sprintf "HTTP %d: %s" (Requests.Response.status_code response) (Requests.Response.text response)) 1046 + 1047 + (** Logout 1048 + 1049 + Logout the current user and invalidate the session token. *) 1050 + let logout t () = 1051 + let url_path = "/auth/logout" in 1052 + let query = "" in 1053 + let url = t.base_url ^ url_path ^ query in 1054 + let response = Requests.post t.session url in 1055 + if Requests.Response.ok response then 1056 + Openapi.Runtime.Json.decode_json_exn Types.LogoutResponseDto.t_jsont (Requests.Response.json response) 1057 + else 1058 + failwith (Printf.sprintf "HTTP %d: %s" (Requests.Response.status_code response) (Requests.Response.text response)) 1059 + 1060 + (** Setup pin code 1061 + 1062 + Setup a new pin code for the current user. *) 1063 + let setup_pin_code ~body t () = 1064 + let url_path = "/auth/pin-code" in 1065 + let query = "" in 1066 + let url = t.base_url ^ url_path ^ query in 1067 + let response = Requests.post t.session ~body:(Requests.Body.json (Openapi.Runtime.Json.encode_json Types.PinCodeSetupDto.t_jsont body)) url in 1068 + if Requests.Response.ok response then 1069 + Requests.Response.json response 1070 + else 1071 + failwith (Printf.sprintf "HTTP %d: %s" (Requests.Response.status_code response) (Requests.Response.text response)) 1072 + 1073 + (** Change pin code 1074 + 1075 + Change the pin code for the current user. *) 1076 + let change_pin_code ~body t () = 1077 + let url_path = "/auth/pin-code" in 1078 + let query = "" in 1079 + let url = t.base_url ^ url_path ^ query in 1080 + let response = Requests.put t.session ~body:(Requests.Body.json (Openapi.Runtime.Json.encode_json Types.PinCodeChangeDto.t_jsont body)) url in 1081 + if Requests.Response.ok response then 1082 + Requests.Response.json response 1083 + else 1084 + failwith (Printf.sprintf "HTTP %d: %s" (Requests.Response.status_code response) (Requests.Response.text response)) 1085 + 1086 + (** Reset pin code 1087 + 1088 + Reset the pin code for the current user by providing the account password *) 1089 + let reset_pin_code t () = 1090 + let url_path = "/auth/pin-code" in 1091 + let query = "" in 1092 + let url = t.base_url ^ url_path ^ query in 1093 + let response = Requests.delete t.session url in 1094 + if Requests.Response.ok response then 1095 + Requests.Response.json response 1096 + else 1097 + failwith (Printf.sprintf "HTTP %d: %s" (Requests.Response.status_code response) (Requests.Response.text response)) 1098 + 1099 + (** Lock auth session 1100 + 1101 + Remove elevated access to locked assets from the current session. *) 1102 + let lock_auth_session t () = 1103 + let url_path = "/auth/session/lock" in 1104 + let query = "" in 1105 + let url = t.base_url ^ url_path ^ query in 1106 + let response = Requests.post t.session url in 1107 + if Requests.Response.ok response then 1108 + Requests.Response.json response 1109 + else 1110 + failwith (Printf.sprintf "HTTP %d: %s" (Requests.Response.status_code response) (Requests.Response.text response)) 1111 + 1112 + (** Unlock auth session 1113 + 1114 + Temporarily grant the session elevated access to locked assets by providing the correct PIN code. *) 1115 + let unlock_auth_session ~body t () = 1116 + let url_path = "/auth/session/unlock" in 1117 + let query = "" in 1118 + let url = t.base_url ^ url_path ^ query in 1119 + let response = Requests.post t.session ~body:(Requests.Body.json (Openapi.Runtime.Json.encode_json Types.SessionUnlockDto.t_jsont body)) url in 1120 + if Requests.Response.ok response then 1121 + Requests.Response.json response 1122 + else 1123 + failwith (Printf.sprintf "HTTP %d: %s" (Requests.Response.status_code response) (Requests.Response.text response)) 1124 + 1125 + (** Retrieve auth status 1126 + 1127 + Get information about the current session, including whether the user has a password, and if the session can access locked assets. *) 1128 + let get_auth_status t () = 1129 + let url_path = "/auth/status" in 1130 + let query = "" in 1131 + let url = t.base_url ^ url_path ^ query in 1132 + let response = Requests.get t.session url in 1133 + if Requests.Response.ok response then 1134 + Openapi.Runtime.Json.decode_json_exn Types.AuthStatusResponseDto.t_jsont (Requests.Response.json response) 1135 + else 1136 + failwith (Printf.sprintf "HTTP %d: %s" (Requests.Response.status_code response) (Requests.Response.text response)) 1137 + 1138 + (** Validate access token 1139 + 1140 + Validate the current authorization method is still valid. *) 1141 + let validate_access_token t () = 1142 + let url_path = "/auth/validateToken" in 1143 + let query = "" in 1144 + let url = t.base_url ^ url_path ^ query in 1145 + let response = Requests.post t.session url in 1146 + if Requests.Response.ok response then 1147 + Openapi.Runtime.Json.decode_json_exn Types.ValidateAccessTokenResponseDto.t_jsont (Requests.Response.json response) 1148 + else 1149 + failwith (Printf.sprintf "HTTP %d: %s" (Requests.Response.status_code response) (Requests.Response.text response)) 1150 + 1151 + (** Download asset archive 1152 + 1153 + Download a ZIP archive containing the specified assets. The assets must have been previously requested via the "getDownloadInfo" endpoint. *) 1154 + let download_archive ?key ?slug ~body t () = 1155 + let url_path = "/download/archive" in 1156 + let query = Openapi.Runtime.Query.encode (List.concat [ 1157 + Openapi.Runtime.Query.optional ~key:"key" ~value:key; 1158 + Openapi.Runtime.Query.optional ~key:"slug" ~value:slug 1159 + ]) in 1160 + let url = t.base_url ^ url_path ^ query in 1161 + let response = Requests.post t.session ~body:(Requests.Body.json (Openapi.Runtime.Json.encode_json Types.AssetIdsDto.t_jsont body)) url in 1162 + if Requests.Response.ok response then 1163 + Requests.Response.json response 1164 + else 1165 + failwith (Printf.sprintf "HTTP %d: %s" (Requests.Response.status_code response) (Requests.Response.text response)) 1166 + 1167 + (** Retrieve download information 1168 + 1169 + Retrieve information about how to request a download for the specified assets or album. The response includes groups of assets that can be downloaded together. *) 1170 + let get_download_info ?key ?slug ~body t () = 1171 + let url_path = "/download/info" in 1172 + let query = Openapi.Runtime.Query.encode (List.concat [ 1173 + Openapi.Runtime.Query.optional ~key:"key" ~value:key; 1174 + Openapi.Runtime.Query.optional ~key:"slug" ~value:slug 1175 + ]) in 1176 + let url = t.base_url ^ url_path ^ query in 1177 + let response = Requests.post t.session ~body:(Requests.Body.json (Openapi.Runtime.Json.encode_json Types.DownloadInfoDto.t_jsont body)) url in 1178 + if Requests.Response.ok response then 1179 + Openapi.Runtime.Json.decode_json_exn Types.DownloadResponseDto.t_jsont (Requests.Response.json response) 1180 + else 1181 + failwith (Printf.sprintf "HTTP %d: %s" (Requests.Response.status_code response) (Requests.Response.text response)) 1182 + 1183 + (** Retrieve duplicates 1184 + 1185 + Retrieve a list of duplicate assets available to the authenticated user. *) 1186 + let get_asset_duplicates t () = 1187 + let url_path = "/duplicates" in 1188 + let query = "" in 1189 + let url = t.base_url ^ url_path ^ query in 1190 + let response = Requests.get t.session url in 1191 + if Requests.Response.ok response then 1192 + Openapi.Runtime.Json.decode_json_exn (Jsont.list Types.DuplicateResponseDto.t_jsont) (Requests.Response.json response) 1193 + else 1194 + failwith (Printf.sprintf "HTTP %d: %s" (Requests.Response.status_code response) (Requests.Response.text response)) 1195 + 1196 + (** Delete duplicates 1197 + 1198 + Delete multiple duplicate assets specified by their IDs. *) 1199 + let delete_duplicates t () = 1200 + let url_path = "/duplicates" in 1201 + let query = "" in 1202 + let url = t.base_url ^ url_path ^ query in 1203 + let response = Requests.delete t.session url in 1204 + if Requests.Response.ok response then 1205 + Requests.Response.json response 1206 + else 1207 + failwith (Printf.sprintf "HTTP %d: %s" (Requests.Response.status_code response) (Requests.Response.text response)) 1208 + 1209 + (** Delete a duplicate 1210 + 1211 + Delete a single duplicate asset specified by its ID. *) 1212 + let delete_duplicate ~id t () = 1213 + let url_path = Openapi.Runtime.Path.render ~params:[("id", id)] "/duplicates/{id}" in 1214 + let query = "" in 1215 + let url = t.base_url ^ url_path ^ query in 1216 + let response = Requests.delete t.session url in 1217 + if Requests.Response.ok response then 1218 + Requests.Response.json response 1219 + else 1220 + failwith (Printf.sprintf "HTTP %d: %s" (Requests.Response.status_code response) (Requests.Response.text response)) 1221 + 1222 + (** Retrieve faces for asset 1223 + 1224 + Retrieve all faces belonging to an asset. *) 1225 + let get_faces ~id t () = 1226 + let url_path = "/faces" in 1227 + let query = Openapi.Runtime.Query.encode (List.concat [ 1228 + Openapi.Runtime.Query.singleton ~key:"id" ~value:id 1229 + ]) in 1230 + let url = t.base_url ^ url_path ^ query in 1231 + let response = Requests.get t.session url in 1232 + if Requests.Response.ok response then 1233 + Openapi.Runtime.Json.decode_json_exn (Jsont.list Types.AssetFaceResponseDto.t_jsont) (Requests.Response.json response) 1234 + else 1235 + failwith (Printf.sprintf "HTTP %d: %s" (Requests.Response.status_code response) (Requests.Response.text response)) 1236 + 1237 + (** Create a face 1238 + 1239 + Create a new face that has not been discovered by facial recognition. The content of the bounding box is considered a face. *) 1240 + let create_face ~body t () = 1241 + let url_path = "/faces" in 1242 + let query = "" in 1243 + let url = t.base_url ^ url_path ^ query in 1244 + let response = Requests.post t.session ~body:(Requests.Body.json (Openapi.Runtime.Json.encode_json Types.AssetFaceCreateDto.t_jsont body)) url in 1245 + if Requests.Response.ok response then 1246 + Requests.Response.json response 1247 + else 1248 + failwith (Printf.sprintf "HTTP %d: %s" (Requests.Response.status_code response) (Requests.Response.text response)) 1249 + 1250 + (** Re-assign a face to another person 1251 + 1252 + Re-assign the face provided in the body to the person identified by the id in the path parameter. *) 1253 + let reassign_faces_by_id ~id ~body t () = 1254 + let url_path = Openapi.Runtime.Path.render ~params:[("id", id)] "/faces/{id}" in 1255 + let query = "" in 1256 + let url = t.base_url ^ url_path ^ query in 1257 + let response = Requests.put t.session ~body:(Requests.Body.json (Openapi.Runtime.Json.encode_json Types.FaceDto.t_jsont body)) url in 1258 + if Requests.Response.ok response then 1259 + Openapi.Runtime.Json.decode_json_exn Types.PersonResponseDto.t_jsont (Requests.Response.json response) 1260 + else 1261 + failwith (Printf.sprintf "HTTP %d: %s" (Requests.Response.status_code response) (Requests.Response.text response)) 1262 + 1263 + (** Delete a face 1264 + 1265 + Delete a face identified by the id. Optionally can be force deleted. *) 1266 + let delete_face ~id t () = 1267 + let url_path = Openapi.Runtime.Path.render ~params:[("id", id)] "/faces/{id}" in 1268 + let query = "" in 1269 + let url = t.base_url ^ url_path ^ query in 1270 + let response = Requests.delete t.session url in 1271 + if Requests.Response.ok response then 1272 + Requests.Response.json response 1273 + else 1274 + failwith (Printf.sprintf "HTTP %d: %s" (Requests.Response.status_code response) (Requests.Response.text response)) 1275 + 1276 + (** Retrieve queue counts and status 1277 + 1278 + Retrieve the counts of the current queue, as well as the current status. *) 1279 + let get_queues_legacy t () = 1280 + let url_path = "/jobs" in 1281 + let query = "" in 1282 + let url = t.base_url ^ url_path ^ query in 1283 + let response = Requests.get t.session url in 1284 + if Requests.Response.ok response then 1285 + Openapi.Runtime.Json.decode_json_exn Types.QueuesResponseLegacyDto.t_jsont (Requests.Response.json response) 1286 + else 1287 + failwith (Printf.sprintf "HTTP %d: %s" (Requests.Response.status_code response) (Requests.Response.text response)) 1288 + 1289 + (** Create a manual job 1290 + 1291 + Run a specific job. Most jobs are queued automatically, but this endpoint allows for manual creation of a handful of jobs, including various cleanup tasks, as well as creating a new database backup. *) 1292 + let create_job ~body t () = 1293 + let url_path = "/jobs" in 1294 + let query = "" in 1295 + let url = t.base_url ^ url_path ^ query in 1296 + let response = Requests.post t.session ~body:(Requests.Body.json (Openapi.Runtime.Json.encode_json Types.JobCreateDto.t_jsont body)) url in 1297 + if Requests.Response.ok response then 1298 + Requests.Response.json response 1299 + else 1300 + failwith (Printf.sprintf "HTTP %d: %s" (Requests.Response.status_code response) (Requests.Response.text response)) 1301 + 1302 + (** Run jobs 1303 + 1304 + Queue all assets for a specific job type. Defaults to only queueing assets that have not yet been processed, but the force command can be used to re-process all assets. *) 1305 + let run_queue_command_legacy ~name ~body t () = 1306 + let url_path = Openapi.Runtime.Path.render ~params:[("name", name)] "/jobs/{name}" in 1307 + let query = "" in 1308 + let url = t.base_url ^ url_path ^ query in 1309 + let response = Requests.put t.session ~body:(Requests.Body.json (Openapi.Runtime.Json.encode_json Types.QueueCommandDto.t_jsont body)) url in 1310 + if Requests.Response.ok response then 1311 + Openapi.Runtime.Json.decode_json_exn Types.QueueResponseLegacyDto.t_jsont (Requests.Response.json response) 1312 + else 1313 + failwith (Printf.sprintf "HTTP %d: %s" (Requests.Response.status_code response) (Requests.Response.text response)) 1314 + 1315 + (** Retrieve libraries 1316 + 1317 + Retrieve a list of external libraries. *) 1318 + let get_all_libraries t () = 1319 + let url_path = "/libraries" in 1320 + let query = "" in 1321 + let url = t.base_url ^ url_path ^ query in 1322 + let response = Requests.get t.session url in 1323 + if Requests.Response.ok response then 1324 + Openapi.Runtime.Json.decode_json_exn (Jsont.list Types.LibraryResponseDto.t_jsont) (Requests.Response.json response) 1325 + else 1326 + failwith (Printf.sprintf "HTTP %d: %s" (Requests.Response.status_code response) (Requests.Response.text response)) 1327 + 1328 + (** Create a library 1329 + 1330 + Create a new external library. *) 1331 + let create_library ~body t () = 1332 + let url_path = "/libraries" in 1333 + let query = "" in 1334 + let url = t.base_url ^ url_path ^ query in 1335 + let response = Requests.post t.session ~body:(Requests.Body.json (Openapi.Runtime.Json.encode_json Types.CreateLibraryDto.t_jsont body)) url in 1336 + if Requests.Response.ok response then 1337 + Openapi.Runtime.Json.decode_json_exn Types.LibraryResponseDto.t_jsont (Requests.Response.json response) 1338 + else 1339 + failwith (Printf.sprintf "HTTP %d: %s" (Requests.Response.status_code response) (Requests.Response.text response)) 1340 + 1341 + (** Retrieve a library 1342 + 1343 + Retrieve an external library by its ID. *) 1344 + let get_library ~id t () = 1345 + let url_path = Openapi.Runtime.Path.render ~params:[("id", id)] "/libraries/{id}" in 1346 + let query = "" in 1347 + let url = t.base_url ^ url_path ^ query in 1348 + let response = Requests.get t.session url in 1349 + if Requests.Response.ok response then 1350 + Openapi.Runtime.Json.decode_json_exn Types.LibraryResponseDto.t_jsont (Requests.Response.json response) 1351 + else 1352 + failwith (Printf.sprintf "HTTP %d: %s" (Requests.Response.status_code response) (Requests.Response.text response)) 1353 + 1354 + (** Update a library 1355 + 1356 + Update an existing external library. *) 1357 + let update_library ~id ~body t () = 1358 + let url_path = Openapi.Runtime.Path.render ~params:[("id", id)] "/libraries/{id}" in 1359 + let query = "" in 1360 + let url = t.base_url ^ url_path ^ query in 1361 + let response = Requests.put t.session ~body:(Requests.Body.json (Openapi.Runtime.Json.encode_json Types.UpdateLibraryDto.t_jsont body)) url in 1362 + if Requests.Response.ok response then 1363 + Openapi.Runtime.Json.decode_json_exn Types.LibraryResponseDto.t_jsont (Requests.Response.json response) 1364 + else 1365 + failwith (Printf.sprintf "HTTP %d: %s" (Requests.Response.status_code response) (Requests.Response.text response)) 1366 + 1367 + (** Delete a library 1368 + 1369 + Delete an external library by its ID. *) 1370 + let delete_library ~id t () = 1371 + let url_path = Openapi.Runtime.Path.render ~params:[("id", id)] "/libraries/{id}" in 1372 + let query = "" in 1373 + let url = t.base_url ^ url_path ^ query in 1374 + let response = Requests.delete t.session url in 1375 + if Requests.Response.ok response then 1376 + Requests.Response.json response 1377 + else 1378 + failwith (Printf.sprintf "HTTP %d: %s" (Requests.Response.status_code response) (Requests.Response.text response)) 1379 + 1380 + (** Scan a library 1381 + 1382 + Queue a scan for the external library to find and import new assets. *) 1383 + let scan_library ~id t () = 1384 + let url_path = Openapi.Runtime.Path.render ~params:[("id", id)] "/libraries/{id}/scan" in 1385 + let query = "" in 1386 + let url = t.base_url ^ url_path ^ query in 1387 + let response = Requests.post t.session url in 1388 + if Requests.Response.ok response then 1389 + Requests.Response.json response 1390 + else 1391 + failwith (Printf.sprintf "HTTP %d: %s" (Requests.Response.status_code response) (Requests.Response.text response)) 1392 + 1393 + (** Retrieve library statistics 1394 + 1395 + Retrieve statistics for a specific external library, including number of videos, images, and storage usage. *) 1396 + let get_library_statistics ~id t () = 1397 + let url_path = Openapi.Runtime.Path.render ~params:[("id", id)] "/libraries/{id}/statistics" in 1398 + let query = "" in 1399 + let url = t.base_url ^ url_path ^ query in 1400 + let response = Requests.get t.session url in 1401 + if Requests.Response.ok response then 1402 + Openapi.Runtime.Json.decode_json_exn Types.LibraryStatsResponseDto.t_jsont (Requests.Response.json response) 1403 + else 1404 + failwith (Printf.sprintf "HTTP %d: %s" (Requests.Response.status_code response) (Requests.Response.text response)) 1405 + 1406 + (** Validate library settings 1407 + 1408 + Validate the settings of an external library. *) 1409 + let validate ~id ~body t () = 1410 + let url_path = Openapi.Runtime.Path.render ~params:[("id", id)] "/libraries/{id}/validate" in 1411 + let query = "" in 1412 + let url = t.base_url ^ url_path ^ query in 1413 + let response = Requests.post t.session ~body:(Requests.Body.json (Openapi.Runtime.Json.encode_json Types.ValidateLibraryDto.t_jsont body)) url in 1414 + if Requests.Response.ok response then 1415 + Openapi.Runtime.Json.decode_json_exn Types.ValidateLibraryResponseDto.t_jsont (Requests.Response.json response) 1416 + else 1417 + failwith (Printf.sprintf "HTTP %d: %s" (Requests.Response.status_code response) (Requests.Response.text response)) 1418 + 1419 + (** Retrieve map markers 1420 + 1421 + Retrieve a list of latitude and longitude coordinates for every asset with location data. *) 1422 + let get_map_markers ?file_created_after ?file_created_before ?is_archived ?is_favorite ?with_partners ?with_shared_albums t () = 1423 + let url_path = "/map/markers" in 1424 + let query = Openapi.Runtime.Query.encode (List.concat [ 1425 + Openapi.Runtime.Query.optional ~key:"fileCreatedAfter" ~value:file_created_after; 1426 + Openapi.Runtime.Query.optional ~key:"fileCreatedBefore" ~value:file_created_before; 1427 + Openapi.Runtime.Query.optional ~key:"isArchived" ~value:is_archived; 1428 + Openapi.Runtime.Query.optional ~key:"isFavorite" ~value:is_favorite; 1429 + Openapi.Runtime.Query.optional ~key:"withPartners" ~value:with_partners; 1430 + Openapi.Runtime.Query.optional ~key:"withSharedAlbums" ~value:with_shared_albums 1431 + ]) in 1432 + let url = t.base_url ^ url_path ^ query in 1433 + let response = Requests.get t.session url in 1434 + if Requests.Response.ok response then 1435 + Openapi.Runtime.Json.decode_json_exn (Jsont.list Types.MapMarkerResponseDto.t_jsont) (Requests.Response.json response) 1436 + else 1437 + failwith (Printf.sprintf "HTTP %d: %s" (Requests.Response.status_code response) (Requests.Response.text response)) 1438 + 1439 + (** Reverse geocode coordinates 1440 + 1441 + Retrieve location information (e.g., city, country) for given latitude and longitude coordinates. *) 1442 + let reverse_geocode ~lat ~lon t () = 1443 + let url_path = "/map/reverse-geocode" in 1444 + let query = Openapi.Runtime.Query.encode (List.concat [ 1445 + Openapi.Runtime.Query.singleton ~key:"lat" ~value:lat; 1446 + Openapi.Runtime.Query.singleton ~key:"lon" ~value:lon 1447 + ]) in 1448 + let url = t.base_url ^ url_path ^ query in 1449 + let response = Requests.get t.session url in 1450 + if Requests.Response.ok response then 1451 + Openapi.Runtime.Json.decode_json_exn (Jsont.list Types.MapReverseGeocodeResponseDto.t_jsont) (Requests.Response.json response) 1452 + else 1453 + failwith (Printf.sprintf "HTTP %d: %s" (Requests.Response.status_code response) (Requests.Response.text response)) 1454 + 1455 + (** Retrieve memories 1456 + 1457 + Retrieve a list of memories. Memories are sorted descending by creation date by default, although they can also be sorted in ascending order, or randomly. *) 1458 + let search_memories ?for_ ?is_saved ?is_trashed ?order ?size ?type_ t () = 1459 + let url_path = "/memories" in 1460 + let query = Openapi.Runtime.Query.encode (List.concat [ 1461 + Openapi.Runtime.Query.optional ~key:"for" ~value:for_; 1462 + Openapi.Runtime.Query.optional ~key:"isSaved" ~value:is_saved; 1463 + Openapi.Runtime.Query.optional ~key:"isTrashed" ~value:is_trashed; 1464 + Openapi.Runtime.Query.optional ~key:"order" ~value:order; 1465 + Openapi.Runtime.Query.optional ~key:"size" ~value:size; 1466 + Openapi.Runtime.Query.optional ~key:"type" ~value:type_ 1467 + ]) in 1468 + let url = t.base_url ^ url_path ^ query in 1469 + let response = Requests.get t.session url in 1470 + if Requests.Response.ok response then 1471 + Openapi.Runtime.Json.decode_json_exn (Jsont.list Types.MemoryResponseDto.t_jsont) (Requests.Response.json response) 1472 + else 1473 + failwith (Printf.sprintf "HTTP %d: %s" (Requests.Response.status_code response) (Requests.Response.text response)) 1474 + 1475 + (** Create a memory 1476 + 1477 + Create a new memory by providing a name, description, and a list of asset IDs to include in the memory. *) 1478 + let create_memory ~body t () = 1479 + let url_path = "/memories" in 1480 + let query = "" in 1481 + let url = t.base_url ^ url_path ^ query in 1482 + let response = Requests.post t.session ~body:(Requests.Body.json (Openapi.Runtime.Json.encode_json Types.MemoryCreateDto.t_jsont body)) url in 1483 + if Requests.Response.ok response then 1484 + Openapi.Runtime.Json.decode_json_exn Types.MemoryResponseDto.t_jsont (Requests.Response.json response) 1485 + else 1486 + failwith (Printf.sprintf "HTTP %d: %s" (Requests.Response.status_code response) (Requests.Response.text response)) 1487 + 1488 + (** Retrieve memories statistics 1489 + 1490 + Retrieve statistics about memories, such as total count and other relevant metrics. *) 1491 + let memories_statistics ?for_ ?is_saved ?is_trashed ?order ?size ?type_ t () = 1492 + let url_path = "/memories/statistics" in 1493 + let query = Openapi.Runtime.Query.encode (List.concat [ 1494 + Openapi.Runtime.Query.optional ~key:"for" ~value:for_; 1495 + Openapi.Runtime.Query.optional ~key:"isSaved" ~value:is_saved; 1496 + Openapi.Runtime.Query.optional ~key:"isTrashed" ~value:is_trashed; 1497 + Openapi.Runtime.Query.optional ~key:"order" ~value:order; 1498 + Openapi.Runtime.Query.optional ~key:"size" ~value:size; 1499 + Openapi.Runtime.Query.optional ~key:"type" ~value:type_ 1500 + ]) in 1501 + let url = t.base_url ^ url_path ^ query in 1502 + let response = Requests.get t.session url in 1503 + if Requests.Response.ok response then 1504 + Openapi.Runtime.Json.decode_json_exn Types.MemoryStatisticsResponseDto.t_jsont (Requests.Response.json response) 1505 + else 1506 + failwith (Printf.sprintf "HTTP %d: %s" (Requests.Response.status_code response) (Requests.Response.text response)) 1507 + 1508 + (** Retrieve a memory 1509 + 1510 + Retrieve a specific memory by its ID. *) 1511 + let get_memory ~id t () = 1512 + let url_path = Openapi.Runtime.Path.render ~params:[("id", id)] "/memories/{id}" in 1513 + let query = "" in 1514 + let url = t.base_url ^ url_path ^ query in 1515 + let response = Requests.get t.session url in 1516 + if Requests.Response.ok response then 1517 + Openapi.Runtime.Json.decode_json_exn Types.MemoryResponseDto.t_jsont (Requests.Response.json response) 1518 + else 1519 + failwith (Printf.sprintf "HTTP %d: %s" (Requests.Response.status_code response) (Requests.Response.text response)) 1520 + 1521 + (** Update a memory 1522 + 1523 + Update an existing memory by its ID. *) 1524 + let update_memory ~id ~body t () = 1525 + let url_path = Openapi.Runtime.Path.render ~params:[("id", id)] "/memories/{id}" in 1526 + let query = "" in 1527 + let url = t.base_url ^ url_path ^ query in 1528 + let response = Requests.put t.session ~body:(Requests.Body.json (Openapi.Runtime.Json.encode_json Types.MemoryUpdateDto.t_jsont body)) url in 1529 + if Requests.Response.ok response then 1530 + Openapi.Runtime.Json.decode_json_exn Types.MemoryResponseDto.t_jsont (Requests.Response.json response) 1531 + else 1532 + failwith (Printf.sprintf "HTTP %d: %s" (Requests.Response.status_code response) (Requests.Response.text response)) 1533 + 1534 + (** Delete a memory 1535 + 1536 + Delete a specific memory by its ID. *) 1537 + let delete_memory ~id t () = 1538 + let url_path = Openapi.Runtime.Path.render ~params:[("id", id)] "/memories/{id}" in 1539 + let query = "" in 1540 + let url = t.base_url ^ url_path ^ query in 1541 + let response = Requests.delete t.session url in 1542 + if Requests.Response.ok response then 1543 + Requests.Response.json response 1544 + else 1545 + failwith (Printf.sprintf "HTTP %d: %s" (Requests.Response.status_code response) (Requests.Response.text response)) 1546 + 1547 + (** Add assets to a memory 1548 + 1549 + Add a list of asset IDs to a specific memory. *) 1550 + let add_memory_assets ~id ~body t () = 1551 + let url_path = Openapi.Runtime.Path.render ~params:[("id", id)] "/memories/{id}/assets" in 1552 + let query = "" in 1553 + let url = t.base_url ^ url_path ^ query in 1554 + let response = Requests.put t.session ~body:(Requests.Body.json (Openapi.Runtime.Json.encode_json Types.BulkIdsDto.t_jsont body)) url in 1555 + if Requests.Response.ok response then 1556 + Openapi.Runtime.Json.decode_json_exn (Jsont.list Types.BulkIdResponseDto.t_jsont) (Requests.Response.json response) 1557 + else 1558 + failwith (Printf.sprintf "HTTP %d: %s" (Requests.Response.status_code response) (Requests.Response.text response)) 1559 + 1560 + (** Remove assets from a memory 1561 + 1562 + Remove a list of asset IDs from a specific memory. *) 1563 + let remove_memory_assets ~id t () = 1564 + let url_path = Openapi.Runtime.Path.render ~params:[("id", id)] "/memories/{id}/assets" in 1565 + let query = "" in 1566 + let url = t.base_url ^ url_path ^ query in 1567 + let response = Requests.delete t.session url in 1568 + if Requests.Response.ok response then 1569 + Openapi.Runtime.Json.decode_json_exn (Jsont.list Types.BulkIdResponseDto.t_jsont) (Requests.Response.json response) 1570 + else 1571 + failwith (Printf.sprintf "HTTP %d: %s" (Requests.Response.status_code response) (Requests.Response.text response)) 1572 + 1573 + (** Retrieve notifications 1574 + 1575 + Retrieve a list of notifications. *) 1576 + let get_notifications ?id ?level ?type_ ?unread t () = 1577 + let url_path = "/notifications" in 1578 + let query = Openapi.Runtime.Query.encode (List.concat [ 1579 + Openapi.Runtime.Query.optional ~key:"id" ~value:id; 1580 + Openapi.Runtime.Query.optional ~key:"level" ~value:level; 1581 + Openapi.Runtime.Query.optional ~key:"type" ~value:type_; 1582 + Openapi.Runtime.Query.optional ~key:"unread" ~value:unread 1583 + ]) in 1584 + let url = t.base_url ^ url_path ^ query in 1585 + let response = Requests.get t.session url in 1586 + if Requests.Response.ok response then 1587 + Openapi.Runtime.Json.decode_json_exn (Jsont.list Types.NotificationDto.t_jsont) (Requests.Response.json response) 1588 + else 1589 + failwith (Printf.sprintf "HTTP %d: %s" (Requests.Response.status_code response) (Requests.Response.text response)) 1590 + 1591 + (** Update notifications 1592 + 1593 + Update a list of notifications. Allows to bulk-set the read status of notifications. *) 1594 + let update_notifications ~body t () = 1595 + let url_path = "/notifications" in 1596 + let query = "" in 1597 + let url = t.base_url ^ url_path ^ query in 1598 + let response = Requests.put t.session ~body:(Requests.Body.json (Openapi.Runtime.Json.encode_json Types.NotificationUpdateAllDto.t_jsont body)) url in 1599 + if Requests.Response.ok response then 1600 + Requests.Response.json response 1601 + else 1602 + failwith (Printf.sprintf "HTTP %d: %s" (Requests.Response.status_code response) (Requests.Response.text response)) 1603 + 1604 + (** Delete notifications 1605 + 1606 + Delete a list of notifications at once. *) 1607 + let delete_notifications t () = 1608 + let url_path = "/notifications" in 1609 + let query = "" in 1610 + let url = t.base_url ^ url_path ^ query in 1611 + let response = Requests.delete t.session url in 1612 + if Requests.Response.ok response then 1613 + Requests.Response.json response 1614 + else 1615 + failwith (Printf.sprintf "HTTP %d: %s" (Requests.Response.status_code response) (Requests.Response.text response)) 1616 + 1617 + (** Get a notification 1618 + 1619 + Retrieve a specific notification identified by id. *) 1620 + let get_notification ~id t () = 1621 + let url_path = Openapi.Runtime.Path.render ~params:[("id", id)] "/notifications/{id}" in 1622 + let query = "" in 1623 + let url = t.base_url ^ url_path ^ query in 1624 + let response = Requests.get t.session url in 1625 + if Requests.Response.ok response then 1626 + Openapi.Runtime.Json.decode_json_exn Types.NotificationDto.t_jsont (Requests.Response.json response) 1627 + else 1628 + failwith (Printf.sprintf "HTTP %d: %s" (Requests.Response.status_code response) (Requests.Response.text response)) 1629 + 1630 + (** Update a notification 1631 + 1632 + Update a specific notification to set its read status. *) 1633 + let update_notification ~id ~body t () = 1634 + let url_path = Openapi.Runtime.Path.render ~params:[("id", id)] "/notifications/{id}" in 1635 + let query = "" in 1636 + let url = t.base_url ^ url_path ^ query in 1637 + let response = Requests.put t.session ~body:(Requests.Body.json (Openapi.Runtime.Json.encode_json Types.NotificationUpdateDto.t_jsont body)) url in 1638 + if Requests.Response.ok response then 1639 + Openapi.Runtime.Json.decode_json_exn Types.NotificationDto.t_jsont (Requests.Response.json response) 1640 + else 1641 + failwith (Printf.sprintf "HTTP %d: %s" (Requests.Response.status_code response) (Requests.Response.text response)) 1642 + 1643 + (** Delete a notification 1644 + 1645 + Delete a specific notification. *) 1646 + let delete_notification ~id t () = 1647 + let url_path = Openapi.Runtime.Path.render ~params:[("id", id)] "/notifications/{id}" in 1648 + let query = "" in 1649 + let url = t.base_url ^ url_path ^ query in 1650 + let response = Requests.delete t.session url in 1651 + if Requests.Response.ok response then 1652 + Requests.Response.json response 1653 + else 1654 + failwith (Printf.sprintf "HTTP %d: %s" (Requests.Response.status_code response) (Requests.Response.text response)) 1655 + 1656 + (** Start OAuth 1657 + 1658 + Initiate the OAuth authorization process. *) 1659 + let start_oauth ~body t () = 1660 + let url_path = "/oauth/authorize" in 1661 + let query = "" in 1662 + let url = t.base_url ^ url_path ^ query in 1663 + let response = Requests.post t.session ~body:(Requests.Body.json (Openapi.Runtime.Json.encode_json Types.OauthConfigDto.t_jsont body)) url in 1664 + if Requests.Response.ok response then 1665 + Openapi.Runtime.Json.decode_json_exn Types.OauthAuthorizeResponseDto.t_jsont (Requests.Response.json response) 1666 + else 1667 + failwith (Printf.sprintf "HTTP %d: %s" (Requests.Response.status_code response) (Requests.Response.text response)) 1668 + 1669 + (** Finish OAuth 1670 + 1671 + Complete the OAuth authorization process by exchanging the authorization code for a session token. *) 1672 + let finish_oauth ~body t () = 1673 + let url_path = "/oauth/callback" in 1674 + let query = "" in 1675 + let url = t.base_url ^ url_path ^ query in 1676 + let response = Requests.post t.session ~body:(Requests.Body.json (Openapi.Runtime.Json.encode_json Types.OauthCallbackDto.t_jsont body)) url in 1677 + if Requests.Response.ok response then 1678 + Openapi.Runtime.Json.decode_json_exn Types.LoginResponseDto.t_jsont (Requests.Response.json response) 1679 + else 1680 + failwith (Printf.sprintf "HTTP %d: %s" (Requests.Response.status_code response) (Requests.Response.text response)) 1681 + 1682 + (** Link OAuth account 1683 + 1684 + Link an OAuth account to the authenticated user. *) 1685 + let link_oauth_account ~body t () = 1686 + let url_path = "/oauth/link" in 1687 + let query = "" in 1688 + let url = t.base_url ^ url_path ^ query in 1689 + let response = Requests.post t.session ~body:(Requests.Body.json (Openapi.Runtime.Json.encode_json Types.OauthCallbackDto.t_jsont body)) url in 1690 + if Requests.Response.ok response then 1691 + Openapi.Runtime.Json.decode_json_exn Types.UserAdminResponseDto.t_jsont (Requests.Response.json response) 1692 + else 1693 + failwith (Printf.sprintf "HTTP %d: %s" (Requests.Response.status_code response) (Requests.Response.text response)) 1694 + 1695 + (** Redirect OAuth to mobile 1696 + 1697 + Requests to this URL are automatically forwarded to the mobile app, and is used in some cases for OAuth redirecting. *) 1698 + let redirect_oauth_to_mobile t () = 1699 + let url_path = "/oauth/mobile-redirect" in 1700 + let query = "" in 1701 + let url = t.base_url ^ url_path ^ query in 1702 + let response = Requests.get t.session url in 1703 + if Requests.Response.ok response then 1704 + Requests.Response.json response 1705 + else 1706 + failwith (Printf.sprintf "HTTP %d: %s" (Requests.Response.status_code response) (Requests.Response.text response)) 1707 + 1708 + (** Unlink OAuth account 1709 + 1710 + Unlink the OAuth account from the authenticated user. *) 1711 + let unlink_oauth_account t () = 1712 + let url_path = "/oauth/unlink" in 1713 + let query = "" in 1714 + let url = t.base_url ^ url_path ^ query in 1715 + let response = Requests.post t.session url in 1716 + if Requests.Response.ok response then 1717 + Openapi.Runtime.Json.decode_json_exn Types.UserAdminResponseDto.t_jsont (Requests.Response.json response) 1718 + else 1719 + failwith (Printf.sprintf "HTTP %d: %s" (Requests.Response.status_code response) (Requests.Response.text response)) 1720 + 1721 + (** Retrieve partners 1722 + 1723 + Retrieve a list of partners with whom assets are shared. *) 1724 + let get_partners ~direction t () = 1725 + let url_path = "/partners" in 1726 + let query = Openapi.Runtime.Query.encode (List.concat [ 1727 + Openapi.Runtime.Query.singleton ~key:"direction" ~value:direction 1728 + ]) in 1729 + let url = t.base_url ^ url_path ^ query in 1730 + let response = Requests.get t.session url in 1731 + if Requests.Response.ok response then 1732 + Openapi.Runtime.Json.decode_json_exn (Jsont.list Types.PartnerResponseDto.t_jsont) (Requests.Response.json response) 1733 + else 1734 + failwith (Printf.sprintf "HTTP %d: %s" (Requests.Response.status_code response) (Requests.Response.text response)) 1735 + 1736 + (** Create a partner 1737 + 1738 + Create a new partner to share assets with. *) 1739 + let create_partner ~body t () = 1740 + let url_path = "/partners" in 1741 + let query = "" in 1742 + let url = t.base_url ^ url_path ^ query in 1743 + let response = Requests.post t.session ~body:(Requests.Body.json (Openapi.Runtime.Json.encode_json Types.PartnerCreateDto.t_jsont body)) url in 1744 + if Requests.Response.ok response then 1745 + Openapi.Runtime.Json.decode_json_exn Types.PartnerResponseDto.t_jsont (Requests.Response.json response) 1746 + else 1747 + failwith (Printf.sprintf "HTTP %d: %s" (Requests.Response.status_code response) (Requests.Response.text response)) 1748 + 1749 + (** Create a partner 1750 + 1751 + Create a new partner to share assets with. *) 1752 + let create_partner_deprecated ~id t () = 1753 + let url_path = Openapi.Runtime.Path.render ~params:[("id", id)] "/partners/{id}" in 1754 + let query = "" in 1755 + let url = t.base_url ^ url_path ^ query in 1756 + let response = Requests.post t.session url in 1757 + if Requests.Response.ok response then 1758 + Openapi.Runtime.Json.decode_json_exn Types.PartnerResponseDto.t_jsont (Requests.Response.json response) 1759 + else 1760 + failwith (Printf.sprintf "HTTP %d: %s" (Requests.Response.status_code response) (Requests.Response.text response)) 1761 + 1762 + (** Update a partner 1763 + 1764 + Specify whether a partner's assets should appear in the user's timeline. *) 1765 + let update_partner ~id ~body t () = 1766 + let url_path = Openapi.Runtime.Path.render ~params:[("id", id)] "/partners/{id}" in 1767 + let query = "" in 1768 + let url = t.base_url ^ url_path ^ query in 1769 + let response = Requests.put t.session ~body:(Requests.Body.json (Openapi.Runtime.Json.encode_json Types.PartnerUpdateDto.t_jsont body)) url in 1770 + if Requests.Response.ok response then 1771 + Openapi.Runtime.Json.decode_json_exn Types.PartnerResponseDto.t_jsont (Requests.Response.json response) 1772 + else 1773 + failwith (Printf.sprintf "HTTP %d: %s" (Requests.Response.status_code response) (Requests.Response.text response)) 1774 + 1775 + (** Remove a partner 1776 + 1777 + Stop sharing assets with a partner. *) 1778 + let remove_partner ~id t () = 1779 + let url_path = Openapi.Runtime.Path.render ~params:[("id", id)] "/partners/{id}" in 1780 + let query = "" in 1781 + let url = t.base_url ^ url_path ^ query in 1782 + let response = Requests.delete t.session url in 1783 + if Requests.Response.ok response then 1784 + Requests.Response.json response 1785 + else 1786 + failwith (Printf.sprintf "HTTP %d: %s" (Requests.Response.status_code response) (Requests.Response.text response)) 1787 + 1788 + (** Get all people 1789 + 1790 + Retrieve a list of all people. *) 1791 + let get_all_people ?closest_asset_id ?closest_person_id ?page ?size ?with_hidden t () = 1792 + let url_path = "/people" in 1793 + let query = Openapi.Runtime.Query.encode (List.concat [ 1794 + Openapi.Runtime.Query.optional ~key:"closestAssetId" ~value:closest_asset_id; 1795 + Openapi.Runtime.Query.optional ~key:"closestPersonId" ~value:closest_person_id; 1796 + Openapi.Runtime.Query.optional ~key:"page" ~value:page; 1797 + Openapi.Runtime.Query.optional ~key:"size" ~value:size; 1798 + Openapi.Runtime.Query.optional ~key:"withHidden" ~value:with_hidden 1799 + ]) in 1800 + let url = t.base_url ^ url_path ^ query in 1801 + let response = Requests.get t.session url in 1802 + if Requests.Response.ok response then 1803 + Openapi.Runtime.Json.decode_json_exn Types.PeopleResponseDto.t_jsont (Requests.Response.json response) 1804 + else 1805 + failwith (Printf.sprintf "HTTP %d: %s" (Requests.Response.status_code response) (Requests.Response.text response)) 1806 + 1807 + (** Create a person 1808 + 1809 + Create a new person that can have multiple faces assigned to them. *) 1810 + let create_person ~body t () = 1811 + let url_path = "/people" in 1812 + let query = "" in 1813 + let url = t.base_url ^ url_path ^ query in 1814 + let response = Requests.post t.session ~body:(Requests.Body.json (Openapi.Runtime.Json.encode_json Types.PersonCreateDto.t_jsont body)) url in 1815 + if Requests.Response.ok response then 1816 + Openapi.Runtime.Json.decode_json_exn Types.PersonResponseDto.t_jsont (Requests.Response.json response) 1817 + else 1818 + failwith (Printf.sprintf "HTTP %d: %s" (Requests.Response.status_code response) (Requests.Response.text response)) 1819 + 1820 + (** Update people 1821 + 1822 + Bulk update multiple people at once. *) 1823 + let update_people ~body t () = 1824 + let url_path = "/people" in 1825 + let query = "" in 1826 + let url = t.base_url ^ url_path ^ query in 1827 + let response = Requests.put t.session ~body:(Requests.Body.json (Openapi.Runtime.Json.encode_json Types.PeopleUpdateDto.t_jsont body)) url in 1828 + if Requests.Response.ok response then 1829 + Openapi.Runtime.Json.decode_json_exn (Jsont.list Types.BulkIdResponseDto.t_jsont) (Requests.Response.json response) 1830 + else 1831 + failwith (Printf.sprintf "HTTP %d: %s" (Requests.Response.status_code response) (Requests.Response.text response)) 1832 + 1833 + (** Delete people 1834 + 1835 + Bulk delete a list of people at once. *) 1836 + let delete_people t () = 1837 + let url_path = "/people" in 1838 + let query = "" in 1839 + let url = t.base_url ^ url_path ^ query in 1840 + let response = Requests.delete t.session url in 1841 + if Requests.Response.ok response then 1842 + Requests.Response.json response 1843 + else 1844 + failwith (Printf.sprintf "HTTP %d: %s" (Requests.Response.status_code response) (Requests.Response.text response)) 1845 + 1846 + (** Get a person 1847 + 1848 + Retrieve a person by id. *) 1849 + let get_person ~id t () = 1850 + let url_path = Openapi.Runtime.Path.render ~params:[("id", id)] "/people/{id}" in 1851 + let query = "" in 1852 + let url = t.base_url ^ url_path ^ query in 1853 + let response = Requests.get t.session url in 1854 + if Requests.Response.ok response then 1855 + Openapi.Runtime.Json.decode_json_exn Types.PersonResponseDto.t_jsont (Requests.Response.json response) 1856 + else 1857 + failwith (Printf.sprintf "HTTP %d: %s" (Requests.Response.status_code response) (Requests.Response.text response)) 1858 + 1859 + (** Update person 1860 + 1861 + Update an individual person. *) 1862 + let update_person ~id ~body t () = 1863 + let url_path = Openapi.Runtime.Path.render ~params:[("id", id)] "/people/{id}" in 1864 + let query = "" in 1865 + let url = t.base_url ^ url_path ^ query in 1866 + let response = Requests.put t.session ~body:(Requests.Body.json (Openapi.Runtime.Json.encode_json Types.PersonUpdateDto.t_jsont body)) url in 1867 + if Requests.Response.ok response then 1868 + Openapi.Runtime.Json.decode_json_exn Types.PersonResponseDto.t_jsont (Requests.Response.json response) 1869 + else 1870 + failwith (Printf.sprintf "HTTP %d: %s" (Requests.Response.status_code response) (Requests.Response.text response)) 1871 + 1872 + (** Delete person 1873 + 1874 + Delete an individual person. *) 1875 + let delete_person ~id t () = 1876 + let url_path = Openapi.Runtime.Path.render ~params:[("id", id)] "/people/{id}" in 1877 + let query = "" in 1878 + let url = t.base_url ^ url_path ^ query in 1879 + let response = Requests.delete t.session url in 1880 + if Requests.Response.ok response then 1881 + Requests.Response.json response 1882 + else 1883 + failwith (Printf.sprintf "HTTP %d: %s" (Requests.Response.status_code response) (Requests.Response.text response)) 1884 + 1885 + (** Merge people 1886 + 1887 + Merge a list of people into the person specified in the path parameter. *) 1888 + let merge_person ~id ~body t () = 1889 + let url_path = Openapi.Runtime.Path.render ~params:[("id", id)] "/people/{id}/merge" in 1890 + let query = "" in 1891 + let url = t.base_url ^ url_path ^ query in 1892 + let response = Requests.post t.session ~body:(Requests.Body.json (Openapi.Runtime.Json.encode_json Types.MergePersonDto.t_jsont body)) url in 1893 + if Requests.Response.ok response then 1894 + Openapi.Runtime.Json.decode_json_exn (Jsont.list Types.BulkIdResponseDto.t_jsont) (Requests.Response.json response) 1895 + else 1896 + failwith (Printf.sprintf "HTTP %d: %s" (Requests.Response.status_code response) (Requests.Response.text response)) 1897 + 1898 + (** Reassign faces 1899 + 1900 + Bulk reassign a list of faces to a different person. *) 1901 + let reassign_faces ~id ~body t () = 1902 + let url_path = Openapi.Runtime.Path.render ~params:[("id", id)] "/people/{id}/reassign" in 1903 + let query = "" in 1904 + let url = t.base_url ^ url_path ^ query in 1905 + let response = Requests.put t.session ~body:(Requests.Body.json (Openapi.Runtime.Json.encode_json Types.AssetFaceUpdateDto.t_jsont body)) url in 1906 + if Requests.Response.ok response then 1907 + Openapi.Runtime.Json.decode_json_exn (Jsont.list Types.PersonResponseDto.t_jsont) (Requests.Response.json response) 1908 + else 1909 + failwith (Printf.sprintf "HTTP %d: %s" (Requests.Response.status_code response) (Requests.Response.text response)) 1910 + 1911 + (** Get person statistics 1912 + 1913 + Retrieve statistics about a specific person. *) 1914 + let get_person_statistics ~id t () = 1915 + let url_path = Openapi.Runtime.Path.render ~params:[("id", id)] "/people/{id}/statistics" in 1916 + let query = "" in 1917 + let url = t.base_url ^ url_path ^ query in 1918 + let response = Requests.get t.session url in 1919 + if Requests.Response.ok response then 1920 + Openapi.Runtime.Json.decode_json_exn Types.PersonStatisticsResponseDto.t_jsont (Requests.Response.json response) 1921 + else 1922 + failwith (Printf.sprintf "HTTP %d: %s" (Requests.Response.status_code response) (Requests.Response.text response)) 1923 + 1924 + (** Get person thumbnail 1925 + 1926 + Retrieve the thumbnail file for a person. *) 1927 + let get_person_thumbnail ~id t () = 1928 + let url_path = Openapi.Runtime.Path.render ~params:[("id", id)] "/people/{id}/thumbnail" in 1929 + let query = "" in 1930 + let url = t.base_url ^ url_path ^ query in 1931 + let response = Requests.get t.session url in 1932 + if Requests.Response.ok response then 1933 + Requests.Response.json response 1934 + else 1935 + failwith (Printf.sprintf "HTTP %d: %s" (Requests.Response.status_code response) (Requests.Response.text response)) 1936 + 1937 + (** List all plugins 1938 + 1939 + Retrieve a list of plugins available to the authenticated user. *) 1940 + let get_plugins t () = 1941 + let url_path = "/plugins" in 1942 + let query = "" in 1943 + let url = t.base_url ^ url_path ^ query in 1944 + let response = Requests.get t.session url in 1945 + if Requests.Response.ok response then 1946 + Openapi.Runtime.Json.decode_json_exn (Jsont.list Types.PluginResponseDto.t_jsont) (Requests.Response.json response) 1947 + else 1948 + failwith (Printf.sprintf "HTTP %d: %s" (Requests.Response.status_code response) (Requests.Response.text response)) 1949 + 1950 + (** List all plugin triggers 1951 + 1952 + Retrieve a list of all available plugin triggers. *) 1953 + let get_plugin_triggers t () = 1954 + let url_path = "/plugins/triggers" in 1955 + let query = "" in 1956 + let url = t.base_url ^ url_path ^ query in 1957 + let response = Requests.get t.session url in 1958 + if Requests.Response.ok response then 1959 + Openapi.Runtime.Json.decode_json_exn (Jsont.list Types.PluginTriggerResponseDto.t_jsont) (Requests.Response.json response) 1960 + else 1961 + failwith (Printf.sprintf "HTTP %d: %s" (Requests.Response.status_code response) (Requests.Response.text response)) 1962 + 1963 + (** Retrieve a plugin 1964 + 1965 + Retrieve information about a specific plugin by its ID. *) 1966 + let get_plugin ~id t () = 1967 + let url_path = Openapi.Runtime.Path.render ~params:[("id", id)] "/plugins/{id}" in 1968 + let query = "" in 1969 + let url = t.base_url ^ url_path ^ query in 1970 + let response = Requests.get t.session url in 1971 + if Requests.Response.ok response then 1972 + Openapi.Runtime.Json.decode_json_exn Types.PluginResponseDto.t_jsont (Requests.Response.json response) 1973 + else 1974 + failwith (Printf.sprintf "HTTP %d: %s" (Requests.Response.status_code response) (Requests.Response.text response)) 1975 + 1976 + (** List all queues 1977 + 1978 + Retrieves a list of queues. *) 1979 + let get_queues t () = 1980 + let url_path = "/queues" in 1981 + let query = "" in 1982 + let url = t.base_url ^ url_path ^ query in 1983 + let response = Requests.get t.session url in 1984 + if Requests.Response.ok response then 1985 + Openapi.Runtime.Json.decode_json_exn (Jsont.list Types.QueueResponseDto.t_jsont) (Requests.Response.json response) 1986 + else 1987 + failwith (Printf.sprintf "HTTP %d: %s" (Requests.Response.status_code response) (Requests.Response.text response)) 1988 + 1989 + (** Retrieve a queue 1990 + 1991 + Retrieves a specific queue by its name. *) 1992 + let get_queue ~name t () = 1993 + let url_path = Openapi.Runtime.Path.render ~params:[("name", name)] "/queues/{name}" in 1994 + let query = "" in 1995 + let url = t.base_url ^ url_path ^ query in 1996 + let response = Requests.get t.session url in 1997 + if Requests.Response.ok response then 1998 + Openapi.Runtime.Json.decode_json_exn Types.QueueResponseDto.t_jsont (Requests.Response.json response) 1999 + else 2000 + failwith (Printf.sprintf "HTTP %d: %s" (Requests.Response.status_code response) (Requests.Response.text response)) 2001 + 2002 + (** Update a queue 2003 + 2004 + Change the paused status of a specific queue. *) 2005 + let update_queue ~name ~body t () = 2006 + let url_path = Openapi.Runtime.Path.render ~params:[("name", name)] "/queues/{name}" in 2007 + let query = "" in 2008 + let url = t.base_url ^ url_path ^ query in 2009 + let response = Requests.put t.session ~body:(Requests.Body.json (Openapi.Runtime.Json.encode_json Types.QueueUpdateDto.t_jsont body)) url in 2010 + if Requests.Response.ok response then 2011 + Openapi.Runtime.Json.decode_json_exn Types.QueueResponseDto.t_jsont (Requests.Response.json response) 2012 + else 2013 + failwith (Printf.sprintf "HTTP %d: %s" (Requests.Response.status_code response) (Requests.Response.text response)) 2014 + 2015 + (** Retrieve queue jobs 2016 + 2017 + Retrieves a list of queue jobs from the specified queue. *) 2018 + let get_queue_jobs ~name ?status t () = 2019 + let url_path = Openapi.Runtime.Path.render ~params:[("name", name)] "/queues/{name}/jobs" in 2020 + let query = Openapi.Runtime.Query.encode (List.concat [ 2021 + Openapi.Runtime.Query.optional ~key:"status" ~value:status 2022 + ]) in 2023 + let url = t.base_url ^ url_path ^ query in 2024 + let response = Requests.get t.session url in 2025 + if Requests.Response.ok response then 2026 + Openapi.Runtime.Json.decode_json_exn (Jsont.list Types.QueueJobResponseDto.t_jsont) (Requests.Response.json response) 2027 + else 2028 + failwith (Printf.sprintf "HTTP %d: %s" (Requests.Response.status_code response) (Requests.Response.text response)) 2029 + 2030 + (** Empty a queue 2031 + 2032 + Removes all jobs from the specified queue. *) 2033 + let empty_queue ~name t () = 2034 + let url_path = Openapi.Runtime.Path.render ~params:[("name", name)] "/queues/{name}/jobs" in 2035 + let query = "" in 2036 + let url = t.base_url ^ url_path ^ query in 2037 + let response = Requests.delete t.session url in 2038 + if Requests.Response.ok response then 2039 + Requests.Response.json response 2040 + else 2041 + failwith (Printf.sprintf "HTTP %d: %s" (Requests.Response.status_code response) (Requests.Response.text response)) 2042 + 2043 + (** Retrieve assets by city 2044 + 2045 + Retrieve a list of assets with each asset belonging to a different city. This endpoint is used on the places pages to show a single thumbnail for each city the user has assets in. *) 2046 + let get_assets_by_city t () = 2047 + let url_path = "/search/cities" in 2048 + let query = "" in 2049 + let url = t.base_url ^ url_path ^ query in 2050 + let response = Requests.get t.session url in 2051 + if Requests.Response.ok response then 2052 + Openapi.Runtime.Json.decode_json_exn (Jsont.list Types.AssetResponseDto.t_jsont) (Requests.Response.json response) 2053 + else 2054 + failwith (Printf.sprintf "HTTP %d: %s" (Requests.Response.status_code response) (Requests.Response.text response)) 2055 + 2056 + (** Retrieve explore data 2057 + 2058 + Retrieve data for the explore section, such as popular people and places. *) 2059 + let get_explore_data t () = 2060 + let url_path = "/search/explore" in 2061 + let query = "" in 2062 + let url = t.base_url ^ url_path ^ query in 2063 + let response = Requests.get t.session url in 2064 + if Requests.Response.ok response then 2065 + Openapi.Runtime.Json.decode_json_exn (Jsont.list Types.SearchExploreResponseDto.t_jsont) (Requests.Response.json response) 2066 + else 2067 + failwith (Printf.sprintf "HTTP %d: %s" (Requests.Response.status_code response) (Requests.Response.text response)) 2068 + 2069 + (** Search large assets 2070 + 2071 + Search for assets that are considered large based on specified criteria. *) 2072 + let search_large_assets ?album_ids ?city ?country ?created_after ?created_before ?device_id ?is_encoded ?is_favorite ?is_motion ?is_not_in_album ?is_offline ?lens_model ?library_id ?make ?min_file_size ?model ?ocr ?person_ids ?rating ?size ?state ?tag_ids ?taken_after ?taken_before ?trashed_after ?trashed_before ?type_ ?updated_after ?updated_before ?visibility ?with_deleted ?with_exif t () = 2073 + let url_path = "/search/large-assets" in 2074 + let query = Openapi.Runtime.Query.encode (List.concat [ 2075 + Openapi.Runtime.Query.optional ~key:"albumIds" ~value:album_ids; 2076 + Openapi.Runtime.Query.optional ~key:"city" ~value:city; 2077 + Openapi.Runtime.Query.optional ~key:"country" ~value:country; 2078 + Openapi.Runtime.Query.optional ~key:"createdAfter" ~value:created_after; 2079 + Openapi.Runtime.Query.optional ~key:"createdBefore" ~value:created_before; 2080 + Openapi.Runtime.Query.optional ~key:"deviceId" ~value:device_id; 2081 + Openapi.Runtime.Query.optional ~key:"isEncoded" ~value:is_encoded; 2082 + Openapi.Runtime.Query.optional ~key:"isFavorite" ~value:is_favorite; 2083 + Openapi.Runtime.Query.optional ~key:"isMotion" ~value:is_motion; 2084 + Openapi.Runtime.Query.optional ~key:"isNotInAlbum" ~value:is_not_in_album; 2085 + Openapi.Runtime.Query.optional ~key:"isOffline" ~value:is_offline; 2086 + Openapi.Runtime.Query.optional ~key:"lensModel" ~value:lens_model; 2087 + Openapi.Runtime.Query.optional ~key:"libraryId" ~value:library_id; 2088 + Openapi.Runtime.Query.optional ~key:"make" ~value:make; 2089 + Openapi.Runtime.Query.optional ~key:"minFileSize" ~value:min_file_size; 2090 + Openapi.Runtime.Query.optional ~key:"model" ~value:model; 2091 + Openapi.Runtime.Query.optional ~key:"ocr" ~value:ocr; 2092 + Openapi.Runtime.Query.optional ~key:"personIds" ~value:person_ids; 2093 + Openapi.Runtime.Query.optional ~key:"rating" ~value:rating; 2094 + Openapi.Runtime.Query.optional ~key:"size" ~value:size; 2095 + Openapi.Runtime.Query.optional ~key:"state" ~value:state; 2096 + Openapi.Runtime.Query.optional ~key:"tagIds" ~value:tag_ids; 2097 + Openapi.Runtime.Query.optional ~key:"takenAfter" ~value:taken_after; 2098 + Openapi.Runtime.Query.optional ~key:"takenBefore" ~value:taken_before; 2099 + Openapi.Runtime.Query.optional ~key:"trashedAfter" ~value:trashed_after; 2100 + Openapi.Runtime.Query.optional ~key:"trashedBefore" ~value:trashed_before; 2101 + Openapi.Runtime.Query.optional ~key:"type" ~value:type_; 2102 + Openapi.Runtime.Query.optional ~key:"updatedAfter" ~value:updated_after; 2103 + Openapi.Runtime.Query.optional ~key:"updatedBefore" ~value:updated_before; 2104 + Openapi.Runtime.Query.optional ~key:"visibility" ~value:visibility; 2105 + Openapi.Runtime.Query.optional ~key:"withDeleted" ~value:with_deleted; 2106 + Openapi.Runtime.Query.optional ~key:"withExif" ~value:with_exif 2107 + ]) in 2108 + let url = t.base_url ^ url_path ^ query in 2109 + let response = Requests.post t.session url in 2110 + if Requests.Response.ok response then 2111 + Openapi.Runtime.Json.decode_json_exn (Jsont.list Types.AssetResponseDto.t_jsont) (Requests.Response.json response) 2112 + else 2113 + failwith (Printf.sprintf "HTTP %d: %s" (Requests.Response.status_code response) (Requests.Response.text response)) 2114 + 2115 + (** Search assets by metadata 2116 + 2117 + Search for assets based on various metadata criteria. *) 2118 + let search_assets ~body t () = 2119 + let url_path = "/search/metadata" in 2120 + let query = "" in 2121 + let url = t.base_url ^ url_path ^ query in 2122 + let response = Requests.post t.session ~body:(Requests.Body.json (Openapi.Runtime.Json.encode_json Types.MetadataSearchDto.t_jsont body)) url in 2123 + if Requests.Response.ok response then 2124 + Openapi.Runtime.Json.decode_json_exn Types.SearchResponseDto.t_jsont (Requests.Response.json response) 2125 + else 2126 + failwith (Printf.sprintf "HTTP %d: %s" (Requests.Response.status_code response) (Requests.Response.text response)) 2127 + 2128 + (** Search people 2129 + 2130 + Search for people by name. *) 2131 + let search_person ~name ?with_hidden t () = 2132 + let url_path = "/search/person" in 2133 + let query = Openapi.Runtime.Query.encode (List.concat [ 2134 + Openapi.Runtime.Query.singleton ~key:"name" ~value:name; 2135 + Openapi.Runtime.Query.optional ~key:"withHidden" ~value:with_hidden 2136 + ]) in 2137 + let url = t.base_url ^ url_path ^ query in 2138 + let response = Requests.get t.session url in 2139 + if Requests.Response.ok response then 2140 + Openapi.Runtime.Json.decode_json_exn (Jsont.list Types.PersonResponseDto.t_jsont) (Requests.Response.json response) 2141 + else 2142 + failwith (Printf.sprintf "HTTP %d: %s" (Requests.Response.status_code response) (Requests.Response.text response)) 2143 + 2144 + (** Search places 2145 + 2146 + Search for places by name. *) 2147 + let search_places ~name t () = 2148 + let url_path = "/search/places" in 2149 + let query = Openapi.Runtime.Query.encode (List.concat [ 2150 + Openapi.Runtime.Query.singleton ~key:"name" ~value:name 2151 + ]) in 2152 + let url = t.base_url ^ url_path ^ query in 2153 + let response = Requests.get t.session url in 2154 + if Requests.Response.ok response then 2155 + Openapi.Runtime.Json.decode_json_exn (Jsont.list Types.PlacesResponseDto.t_jsont) (Requests.Response.json response) 2156 + else 2157 + failwith (Printf.sprintf "HTTP %d: %s" (Requests.Response.status_code response) (Requests.Response.text response)) 2158 + 2159 + (** Search random assets 2160 + 2161 + Retrieve a random selection of assets based on the provided criteria. *) 2162 + let search_random ~body t () = 2163 + let url_path = "/search/random" in 2164 + let query = "" in 2165 + let url = t.base_url ^ url_path ^ query in 2166 + let response = Requests.post t.session ~body:(Requests.Body.json (Openapi.Runtime.Json.encode_json Types.RandomSearchDto.t_jsont body)) url in 2167 + if Requests.Response.ok response then 2168 + Openapi.Runtime.Json.decode_json_exn (Jsont.list Types.AssetResponseDto.t_jsont) (Requests.Response.json response) 2169 + else 2170 + failwith (Printf.sprintf "HTTP %d: %s" (Requests.Response.status_code response) (Requests.Response.text response)) 2171 + 2172 + (** Smart asset search 2173 + 2174 + Perform a smart search for assets by using machine learning vectors to determine relevance. *) 2175 + let search_smart ~body t () = 2176 + let url_path = "/search/smart" in 2177 + let query = "" in 2178 + let url = t.base_url ^ url_path ^ query in 2179 + let response = Requests.post t.session ~body:(Requests.Body.json (Openapi.Runtime.Json.encode_json Types.SmartSearchDto.t_jsont body)) url in 2180 + if Requests.Response.ok response then 2181 + Openapi.Runtime.Json.decode_json_exn Types.SearchResponseDto.t_jsont (Requests.Response.json response) 2182 + else 2183 + failwith (Printf.sprintf "HTTP %d: %s" (Requests.Response.status_code response) (Requests.Response.text response)) 2184 + 2185 + (** Search asset statistics 2186 + 2187 + Retrieve statistical data about assets based on search criteria, such as the total matching count. *) 2188 + let search_asset_statistics ~body t () = 2189 + let url_path = "/search/statistics" in 2190 + let query = "" in 2191 + let url = t.base_url ^ url_path ^ query in 2192 + let response = Requests.post t.session ~body:(Requests.Body.json (Openapi.Runtime.Json.encode_json Types.StatisticsSearchDto.t_jsont body)) url in 2193 + if Requests.Response.ok response then 2194 + Openapi.Runtime.Json.decode_json_exn Types.SearchStatisticsResponseDto.t_jsont (Requests.Response.json response) 2195 + else 2196 + failwith (Printf.sprintf "HTTP %d: %s" (Requests.Response.status_code response) (Requests.Response.text response)) 2197 + 2198 + (** Retrieve search suggestions 2199 + 2200 + Retrieve search suggestions based on partial input. This endpoint is used for typeahead search features. *) 2201 + let get_search_suggestions ?country ?include_null ?lens_model ?make ?model ?state ~type_ t () = 2202 + let url_path = "/search/suggestions" in 2203 + let query = Openapi.Runtime.Query.encode (List.concat [ 2204 + Openapi.Runtime.Query.optional ~key:"country" ~value:country; 2205 + Openapi.Runtime.Query.optional ~key:"includeNull" ~value:include_null; 2206 + Openapi.Runtime.Query.optional ~key:"lensModel" ~value:lens_model; 2207 + Openapi.Runtime.Query.optional ~key:"make" ~value:make; 2208 + Openapi.Runtime.Query.optional ~key:"model" ~value:model; 2209 + Openapi.Runtime.Query.optional ~key:"state" ~value:state; 2210 + Openapi.Runtime.Query.singleton ~key:"type" ~value:type_ 2211 + ]) in 2212 + let url = t.base_url ^ url_path ^ query in 2213 + let response = Requests.get t.session url in 2214 + if Requests.Response.ok response then 2215 + Requests.Response.json response 2216 + else 2217 + failwith (Printf.sprintf "HTTP %d: %s" (Requests.Response.status_code response) (Requests.Response.text response)) 2218 + 2219 + (** Get server information 2220 + 2221 + Retrieve a list of information about the server. *) 2222 + let get_about_info t () = 2223 + let url_path = "/server/about" in 2224 + let query = "" in 2225 + let url = t.base_url ^ url_path ^ query in 2226 + let response = Requests.get t.session url in 2227 + if Requests.Response.ok response then 2228 + Openapi.Runtime.Json.decode_json_exn Types.ServerAboutResponseDto.t_jsont (Requests.Response.json response) 2229 + else 2230 + failwith (Printf.sprintf "HTTP %d: %s" (Requests.Response.status_code response) (Requests.Response.text response)) 2231 + 2232 + (** Get APK links 2233 + 2234 + Retrieve links to the APKs for the current server version. *) 2235 + let get_apk_links t () = 2236 + let url_path = "/server/apk-links" in 2237 + let query = "" in 2238 + let url = t.base_url ^ url_path ^ query in 2239 + let response = Requests.get t.session url in 2240 + if Requests.Response.ok response then 2241 + Openapi.Runtime.Json.decode_json_exn Types.ServerApkLinksDto.t_jsont (Requests.Response.json response) 2242 + else 2243 + failwith (Printf.sprintf "HTTP %d: %s" (Requests.Response.status_code response) (Requests.Response.text response)) 2244 + 2245 + (** Get config 2246 + 2247 + Retrieve the current server configuration. *) 2248 + let get_server_config t () = 2249 + let url_path = "/server/config" in 2250 + let query = "" in 2251 + let url = t.base_url ^ url_path ^ query in 2252 + let response = Requests.get t.session url in 2253 + if Requests.Response.ok response then 2254 + Openapi.Runtime.Json.decode_json_exn Types.ServerConfigDto.t_jsont (Requests.Response.json response) 2255 + else 2256 + failwith (Printf.sprintf "HTTP %d: %s" (Requests.Response.status_code response) (Requests.Response.text response)) 2257 + 2258 + (** Get features 2259 + 2260 + Retrieve available features supported by this server. *) 2261 + let get_server_features t () = 2262 + let url_path = "/server/features" in 2263 + let query = "" in 2264 + let url = t.base_url ^ url_path ^ query in 2265 + let response = Requests.get t.session url in 2266 + if Requests.Response.ok response then 2267 + Openapi.Runtime.Json.decode_json_exn Types.ServerFeaturesDto.t_jsont (Requests.Response.json response) 2268 + else 2269 + failwith (Printf.sprintf "HTTP %d: %s" (Requests.Response.status_code response) (Requests.Response.text response)) 2270 + 2271 + (** Get product key 2272 + 2273 + Retrieve information about whether the server currently has a product key registered. *) 2274 + let get_server_license t () = 2275 + let url_path = "/server/license" in 2276 + let query = "" in 2277 + let url = t.base_url ^ url_path ^ query in 2278 + let response = Requests.get t.session url in 2279 + if Requests.Response.ok response then 2280 + Openapi.Runtime.Json.decode_json_exn Types.LicenseResponseDto.t_jsont (Requests.Response.json response) 2281 + else 2282 + failwith (Printf.sprintf "HTTP %d: %s" (Requests.Response.status_code response) (Requests.Response.text response)) 2283 + 2284 + (** Set server product key 2285 + 2286 + Validate and set the server product key if successful. *) 2287 + let set_server_license ~body t () = 2288 + let url_path = "/server/license" in 2289 + let query = "" in 2290 + let url = t.base_url ^ url_path ^ query in 2291 + let response = Requests.put t.session ~body:(Requests.Body.json (Openapi.Runtime.Json.encode_json Types.LicenseKeyDto.t_jsont body)) url in 2292 + if Requests.Response.ok response then 2293 + Openapi.Runtime.Json.decode_json_exn Types.LicenseResponseDto.t_jsont (Requests.Response.json response) 2294 + else 2295 + failwith (Printf.sprintf "HTTP %d: %s" (Requests.Response.status_code response) (Requests.Response.text response)) 2296 + 2297 + (** Delete server product key 2298 + 2299 + Delete the currently set server product key. *) 2300 + let delete_server_license t () = 2301 + let url_path = "/server/license" in 2302 + let query = "" in 2303 + let url = t.base_url ^ url_path ^ query in 2304 + let response = Requests.delete t.session url in 2305 + if Requests.Response.ok response then 2306 + Requests.Response.json response 2307 + else 2308 + failwith (Printf.sprintf "HTTP %d: %s" (Requests.Response.status_code response) (Requests.Response.text response)) 2309 + 2310 + (** Get supported media types 2311 + 2312 + Retrieve all media types supported by the server. *) 2313 + let get_supported_media_types t () = 2314 + let url_path = "/server/media-types" in 2315 + let query = "" in 2316 + let url = t.base_url ^ url_path ^ query in 2317 + let response = Requests.get t.session url in 2318 + if Requests.Response.ok response then 2319 + Openapi.Runtime.Json.decode_json_exn Types.ServerMediaTypesResponseDto.t_jsont (Requests.Response.json response) 2320 + else 2321 + failwith (Printf.sprintf "HTTP %d: %s" (Requests.Response.status_code response) (Requests.Response.text response)) 2322 + 2323 + (** Ping 2324 + 2325 + Pong *) 2326 + let ping_server t () = 2327 + let url_path = "/server/ping" in 2328 + let query = "" in 2329 + let url = t.base_url ^ url_path ^ query in 2330 + let response = Requests.get t.session url in 2331 + if Requests.Response.ok response then 2332 + Openapi.Runtime.Json.decode_json_exn Types.ServerPingResponse.t_jsont (Requests.Response.json response) 2333 + else 2334 + failwith (Printf.sprintf "HTTP %d: %s" (Requests.Response.status_code response) (Requests.Response.text response)) 2335 + 2336 + (** Get statistics 2337 + 2338 + Retrieve statistics about the entire Immich instance such as asset counts. *) 2339 + let get_server_statistics t () = 2340 + let url_path = "/server/statistics" in 2341 + let query = "" in 2342 + let url = t.base_url ^ url_path ^ query in 2343 + let response = Requests.get t.session url in 2344 + if Requests.Response.ok response then 2345 + Openapi.Runtime.Json.decode_json_exn Types.ServerStatsResponseDto.t_jsont (Requests.Response.json response) 2346 + else 2347 + failwith (Printf.sprintf "HTTP %d: %s" (Requests.Response.status_code response) (Requests.Response.text response)) 2348 + 2349 + (** Get storage 2350 + 2351 + Retrieve the current storage utilization information of the server. *) 2352 + let get_storage t () = 2353 + let url_path = "/server/storage" in 2354 + let query = "" in 2355 + let url = t.base_url ^ url_path ^ query in 2356 + let response = Requests.get t.session url in 2357 + if Requests.Response.ok response then 2358 + Openapi.Runtime.Json.decode_json_exn Types.ServerStorageResponseDto.t_jsont (Requests.Response.json response) 2359 + else 2360 + failwith (Printf.sprintf "HTTP %d: %s" (Requests.Response.status_code response) (Requests.Response.text response)) 2361 + 2362 + (** Get theme 2363 + 2364 + Retrieve the custom CSS, if existent. *) 2365 + let get_theme t () = 2366 + let url_path = "/server/theme" in 2367 + let query = "" in 2368 + let url = t.base_url ^ url_path ^ query in 2369 + let response = Requests.get t.session url in 2370 + if Requests.Response.ok response then 2371 + Openapi.Runtime.Json.decode_json_exn Types.ServerThemeDto.t_jsont (Requests.Response.json response) 2372 + else 2373 + failwith (Printf.sprintf "HTTP %d: %s" (Requests.Response.status_code response) (Requests.Response.text response)) 2374 + 2375 + (** Get server version 2376 + 2377 + Retrieve the current server version in semantic versioning (semver) format. *) 2378 + let get_server_version t () = 2379 + let url_path = "/server/version" in 2380 + let query = "" in 2381 + let url = t.base_url ^ url_path ^ query in 2382 + let response = Requests.get t.session url in 2383 + if Requests.Response.ok response then 2384 + Openapi.Runtime.Json.decode_json_exn Types.ServerVersionResponseDto.t_jsont (Requests.Response.json response) 2385 + else 2386 + failwith (Printf.sprintf "HTTP %d: %s" (Requests.Response.status_code response) (Requests.Response.text response)) 2387 + 2388 + (** Get version check status 2389 + 2390 + Retrieve information about the last time the version check ran. *) 2391 + let get_version_check t () = 2392 + let url_path = "/server/version-check" in 2393 + let query = "" in 2394 + let url = t.base_url ^ url_path ^ query in 2395 + let response = Requests.get t.session url in 2396 + if Requests.Response.ok response then 2397 + Openapi.Runtime.Json.decode_json_exn Types.VersionCheckStateResponseDto.t_jsont (Requests.Response.json response) 2398 + else 2399 + failwith (Printf.sprintf "HTTP %d: %s" (Requests.Response.status_code response) (Requests.Response.text response)) 2400 + 2401 + (** Get version history 2402 + 2403 + Retrieve a list of past versions the server has been on. *) 2404 + let get_version_history t () = 2405 + let url_path = "/server/version-history" in 2406 + let query = "" in 2407 + let url = t.base_url ^ url_path ^ query in 2408 + let response = Requests.get t.session url in 2409 + if Requests.Response.ok response then 2410 + Openapi.Runtime.Json.decode_json_exn (Jsont.list Types.ServerVersionHistoryResponseDto.t_jsont) (Requests.Response.json response) 2411 + else 2412 + failwith (Printf.sprintf "HTTP %d: %s" (Requests.Response.status_code response) (Requests.Response.text response)) 2413 + 2414 + (** Retrieve sessions 2415 + 2416 + Retrieve a list of sessions for the user. *) 2417 + let get_sessions t () = 2418 + let url_path = "/sessions" in 2419 + let query = "" in 2420 + let url = t.base_url ^ url_path ^ query in 2421 + let response = Requests.get t.session url in 2422 + if Requests.Response.ok response then 2423 + Openapi.Runtime.Json.decode_json_exn (Jsont.list Types.SessionResponseDto.t_jsont) (Requests.Response.json response) 2424 + else 2425 + failwith (Printf.sprintf "HTTP %d: %s" (Requests.Response.status_code response) (Requests.Response.text response)) 2426 + 2427 + (** Create a session 2428 + 2429 + Create a session as a child to the current session. This endpoint is used for casting. *) 2430 + let create_session ~body t () = 2431 + let url_path = "/sessions" in 2432 + let query = "" in 2433 + let url = t.base_url ^ url_path ^ query in 2434 + let response = Requests.post t.session ~body:(Requests.Body.json (Openapi.Runtime.Json.encode_json Types.SessionCreateDto.t_jsont body)) url in 2435 + if Requests.Response.ok response then 2436 + Openapi.Runtime.Json.decode_json_exn Types.SessionCreateResponseDto.t_jsont (Requests.Response.json response) 2437 + else 2438 + failwith (Printf.sprintf "HTTP %d: %s" (Requests.Response.status_code response) (Requests.Response.text response)) 2439 + 2440 + (** Delete all sessions 2441 + 2442 + Delete all sessions for the user. This will not delete the current session. *) 2443 + let delete_all_sessions t () = 2444 + let url_path = "/sessions" in 2445 + let query = "" in 2446 + let url = t.base_url ^ url_path ^ query in 2447 + let response = Requests.delete t.session url in 2448 + if Requests.Response.ok response then 2449 + Requests.Response.json response 2450 + else 2451 + failwith (Printf.sprintf "HTTP %d: %s" (Requests.Response.status_code response) (Requests.Response.text response)) 2452 + 2453 + (** Update a session 2454 + 2455 + Update a specific session identified by id. *) 2456 + let update_session ~id ~body t () = 2457 + let url_path = Openapi.Runtime.Path.render ~params:[("id", id)] "/sessions/{id}" in 2458 + let query = "" in 2459 + let url = t.base_url ^ url_path ^ query in 2460 + let response = Requests.put t.session ~body:(Requests.Body.json (Openapi.Runtime.Json.encode_json Types.SessionUpdateDto.t_jsont body)) url in 2461 + if Requests.Response.ok response then 2462 + Openapi.Runtime.Json.decode_json_exn Types.SessionResponseDto.t_jsont (Requests.Response.json response) 2463 + else 2464 + failwith (Printf.sprintf "HTTP %d: %s" (Requests.Response.status_code response) (Requests.Response.text response)) 2465 + 2466 + (** Delete a session 2467 + 2468 + Delete a specific session by id. *) 2469 + let delete_session ~id t () = 2470 + let url_path = Openapi.Runtime.Path.render ~params:[("id", id)] "/sessions/{id}" in 2471 + let query = "" in 2472 + let url = t.base_url ^ url_path ^ query in 2473 + let response = Requests.delete t.session url in 2474 + if Requests.Response.ok response then 2475 + Requests.Response.json response 2476 + else 2477 + failwith (Printf.sprintf "HTTP %d: %s" (Requests.Response.status_code response) (Requests.Response.text response)) 2478 + 2479 + (** Lock a session 2480 + 2481 + Lock a specific session by id. *) 2482 + let lock_session ~id t () = 2483 + let url_path = Openapi.Runtime.Path.render ~params:[("id", id)] "/sessions/{id}/lock" in 2484 + let query = "" in 2485 + let url = t.base_url ^ url_path ^ query in 2486 + let response = Requests.post t.session url in 2487 + if Requests.Response.ok response then 2488 + Requests.Response.json response 2489 + else 2490 + failwith (Printf.sprintf "HTTP %d: %s" (Requests.Response.status_code response) (Requests.Response.text response)) 2491 + 2492 + (** Retrieve all shared links 2493 + 2494 + Retrieve a list of all shared links. *) 2495 + let get_all_shared_links ?album_id ?id t () = 2496 + let url_path = "/shared-links" in 2497 + let query = Openapi.Runtime.Query.encode (List.concat [ 2498 + Openapi.Runtime.Query.optional ~key:"albumId" ~value:album_id; 2499 + Openapi.Runtime.Query.optional ~key:"id" ~value:id 2500 + ]) in 2501 + let url = t.base_url ^ url_path ^ query in 2502 + let response = Requests.get t.session url in 2503 + if Requests.Response.ok response then 2504 + Openapi.Runtime.Json.decode_json_exn (Jsont.list Types.SharedLinkResponseDto.t_jsont) (Requests.Response.json response) 2505 + else 2506 + failwith (Printf.sprintf "HTTP %d: %s" (Requests.Response.status_code response) (Requests.Response.text response)) 2507 + 2508 + (** Create a shared link 2509 + 2510 + Create a new shared link. *) 2511 + let create_shared_link ~body t () = 2512 + let url_path = "/shared-links" in 2513 + let query = "" in 2514 + let url = t.base_url ^ url_path ^ query in 2515 + let response = Requests.post t.session ~body:(Requests.Body.json (Openapi.Runtime.Json.encode_json Types.SharedLinkCreateDto.t_jsont body)) url in 2516 + if Requests.Response.ok response then 2517 + Openapi.Runtime.Json.decode_json_exn Types.SharedLinkResponseDto.t_jsont (Requests.Response.json response) 2518 + else 2519 + failwith (Printf.sprintf "HTTP %d: %s" (Requests.Response.status_code response) (Requests.Response.text response)) 2520 + 2521 + (** Retrieve current shared link 2522 + 2523 + Retrieve the current shared link associated with authentication method. *) 2524 + let get_my_shared_link ?key ?password ?slug ?token t () = 2525 + let url_path = "/shared-links/me" in 2526 + let query = Openapi.Runtime.Query.encode (List.concat [ 2527 + Openapi.Runtime.Query.optional ~key:"key" ~value:key; 2528 + Openapi.Runtime.Query.optional ~key:"password" ~value:password; 2529 + Openapi.Runtime.Query.optional ~key:"slug" ~value:slug; 2530 + Openapi.Runtime.Query.optional ~key:"token" ~value:token 2531 + ]) in 2532 + let url = t.base_url ^ url_path ^ query in 2533 + let response = Requests.get t.session url in 2534 + if Requests.Response.ok response then 2535 + Openapi.Runtime.Json.decode_json_exn Types.SharedLinkResponseDto.t_jsont (Requests.Response.json response) 2536 + else 2537 + failwith (Printf.sprintf "HTTP %d: %s" (Requests.Response.status_code response) (Requests.Response.text response)) 2538 + 2539 + (** Retrieve a shared link 2540 + 2541 + Retrieve a specific shared link by its ID. *) 2542 + let get_shared_link_by_id ~id t () = 2543 + let url_path = Openapi.Runtime.Path.render ~params:[("id", id)] "/shared-links/{id}" in 2544 + let query = "" in 2545 + let url = t.base_url ^ url_path ^ query in 2546 + let response = Requests.get t.session url in 2547 + if Requests.Response.ok response then 2548 + Openapi.Runtime.Json.decode_json_exn Types.SharedLinkResponseDto.t_jsont (Requests.Response.json response) 2549 + else 2550 + failwith (Printf.sprintf "HTTP %d: %s" (Requests.Response.status_code response) (Requests.Response.text response)) 2551 + 2552 + (** Delete a shared link 2553 + 2554 + Delete a specific shared link by its ID. *) 2555 + let remove_shared_link ~id t () = 2556 + let url_path = Openapi.Runtime.Path.render ~params:[("id", id)] "/shared-links/{id}" in 2557 + let query = "" in 2558 + let url = t.base_url ^ url_path ^ query in 2559 + let response = Requests.delete t.session url in 2560 + if Requests.Response.ok response then 2561 + Requests.Response.json response 2562 + else 2563 + failwith (Printf.sprintf "HTTP %d: %s" (Requests.Response.status_code response) (Requests.Response.text response)) 2564 + 2565 + (** Update a shared link 2566 + 2567 + Update an existing shared link by its ID. *) 2568 + let update_shared_link ~id ~body t () = 2569 + let url_path = Openapi.Runtime.Path.render ~params:[("id", id)] "/shared-links/{id}" in 2570 + let query = "" in 2571 + let url = t.base_url ^ url_path ^ query in 2572 + let response = Requests.patch t.session ~body:(Requests.Body.json (Openapi.Runtime.Json.encode_json Types.SharedLinkEditDto.t_jsont body)) url in 2573 + if Requests.Response.ok response then 2574 + Openapi.Runtime.Json.decode_json_exn Types.SharedLinkResponseDto.t_jsont (Requests.Response.json response) 2575 + else 2576 + failwith (Printf.sprintf "HTTP %d: %s" (Requests.Response.status_code response) (Requests.Response.text response)) 2577 + 2578 + (** Add assets to a shared link 2579 + 2580 + Add assets to a specific shared link by its ID. This endpoint is only relevant for shared link of type individual. *) 2581 + let add_shared_link_assets ~id ?key ?slug ~body t () = 2582 + let url_path = Openapi.Runtime.Path.render ~params:[("id", id)] "/shared-links/{id}/assets" in 2583 + let query = Openapi.Runtime.Query.encode (List.concat [ 2584 + Openapi.Runtime.Query.optional ~key:"key" ~value:key; 2585 + Openapi.Runtime.Query.optional ~key:"slug" ~value:slug 2586 + ]) in 2587 + let url = t.base_url ^ url_path ^ query in 2588 + let response = Requests.put t.session ~body:(Requests.Body.json (Openapi.Runtime.Json.encode_json Types.AssetIdsDto.t_jsont body)) url in 2589 + if Requests.Response.ok response then 2590 + Openapi.Runtime.Json.decode_json_exn (Jsont.list Types.AssetIdsResponseDto.t_jsont) (Requests.Response.json response) 2591 + else 2592 + failwith (Printf.sprintf "HTTP %d: %s" (Requests.Response.status_code response) (Requests.Response.text response)) 2593 + 2594 + (** Remove assets from a shared link 2595 + 2596 + Remove assets from a specific shared link by its ID. This endpoint is only relevant for shared link of type individual. *) 2597 + let remove_shared_link_assets ~id ?key ?slug t () = 2598 + let url_path = Openapi.Runtime.Path.render ~params:[("id", id)] "/shared-links/{id}/assets" in 2599 + let query = Openapi.Runtime.Query.encode (List.concat [ 2600 + Openapi.Runtime.Query.optional ~key:"key" ~value:key; 2601 + Openapi.Runtime.Query.optional ~key:"slug" ~value:slug 2602 + ]) in 2603 + let url = t.base_url ^ url_path ^ query in 2604 + let response = Requests.delete t.session url in 2605 + if Requests.Response.ok response then 2606 + Openapi.Runtime.Json.decode_json_exn (Jsont.list Types.AssetIdsResponseDto.t_jsont) (Requests.Response.json response) 2607 + else 2608 + failwith (Printf.sprintf "HTTP %d: %s" (Requests.Response.status_code response) (Requests.Response.text response)) 2609 + 2610 + (** Retrieve stacks 2611 + 2612 + Retrieve a list of stacks. *) 2613 + let search_stacks ?primary_asset_id t () = 2614 + let url_path = "/stacks" in 2615 + let query = Openapi.Runtime.Query.encode (List.concat [ 2616 + Openapi.Runtime.Query.optional ~key:"primaryAssetId" ~value:primary_asset_id 2617 + ]) in 2618 + let url = t.base_url ^ url_path ^ query in 2619 + let response = Requests.get t.session url in 2620 + if Requests.Response.ok response then 2621 + Openapi.Runtime.Json.decode_json_exn (Jsont.list Types.StackResponseDto.t_jsont) (Requests.Response.json response) 2622 + else 2623 + failwith (Printf.sprintf "HTTP %d: %s" (Requests.Response.status_code response) (Requests.Response.text response)) 2624 + 2625 + (** Create a stack 2626 + 2627 + Create a new stack by providing a name and a list of asset IDs to include in the stack. If any of the provided asset IDs are primary assets of an existing stack, the existing stack will be merged into the newly created stack. *) 2628 + let create_stack ~body t () = 2629 + let url_path = "/stacks" in 2630 + let query = "" in 2631 + let url = t.base_url ^ url_path ^ query in 2632 + let response = Requests.post t.session ~body:(Requests.Body.json (Openapi.Runtime.Json.encode_json Types.StackCreateDto.t_jsont body)) url in 2633 + if Requests.Response.ok response then 2634 + Openapi.Runtime.Json.decode_json_exn Types.StackResponseDto.t_jsont (Requests.Response.json response) 2635 + else 2636 + failwith (Printf.sprintf "HTTP %d: %s" (Requests.Response.status_code response) (Requests.Response.text response)) 2637 + 2638 + (** Delete stacks 2639 + 2640 + Delete multiple stacks by providing a list of stack IDs. *) 2641 + let delete_stacks t () = 2642 + let url_path = "/stacks" in 2643 + let query = "" in 2644 + let url = t.base_url ^ url_path ^ query in 2645 + let response = Requests.delete t.session url in 2646 + if Requests.Response.ok response then 2647 + Requests.Response.json response 2648 + else 2649 + failwith (Printf.sprintf "HTTP %d: %s" (Requests.Response.status_code response) (Requests.Response.text response)) 2650 + 2651 + (** Retrieve a stack 2652 + 2653 + Retrieve a specific stack by its ID. *) 2654 + let get_stack ~id t () = 2655 + let url_path = Openapi.Runtime.Path.render ~params:[("id", id)] "/stacks/{id}" in 2656 + let query = "" in 2657 + let url = t.base_url ^ url_path ^ query in 2658 + let response = Requests.get t.session url in 2659 + if Requests.Response.ok response then 2660 + Openapi.Runtime.Json.decode_json_exn Types.StackResponseDto.t_jsont (Requests.Response.json response) 2661 + else 2662 + failwith (Printf.sprintf "HTTP %d: %s" (Requests.Response.status_code response) (Requests.Response.text response)) 2663 + 2664 + (** Update a stack 2665 + 2666 + Update an existing stack by its ID. *) 2667 + let update_stack ~id ~body t () = 2668 + let url_path = Openapi.Runtime.Path.render ~params:[("id", id)] "/stacks/{id}" in 2669 + let query = "" in 2670 + let url = t.base_url ^ url_path ^ query in 2671 + let response = Requests.put t.session ~body:(Requests.Body.json (Openapi.Runtime.Json.encode_json Types.StackUpdateDto.t_jsont body)) url in 2672 + if Requests.Response.ok response then 2673 + Openapi.Runtime.Json.decode_json_exn Types.StackResponseDto.t_jsont (Requests.Response.json response) 2674 + else 2675 + failwith (Printf.sprintf "HTTP %d: %s" (Requests.Response.status_code response) (Requests.Response.text response)) 2676 + 2677 + (** Delete a stack 2678 + 2679 + Delete a specific stack by its ID. *) 2680 + let delete_stack ~id t () = 2681 + let url_path = Openapi.Runtime.Path.render ~params:[("id", id)] "/stacks/{id}" in 2682 + let query = "" in 2683 + let url = t.base_url ^ url_path ^ query in 2684 + let response = Requests.delete t.session url in 2685 + if Requests.Response.ok response then 2686 + Requests.Response.json response 2687 + else 2688 + failwith (Printf.sprintf "HTTP %d: %s" (Requests.Response.status_code response) (Requests.Response.text response)) 2689 + 2690 + (** Remove an asset from a stack 2691 + 2692 + Remove a specific asset from a stack by providing the stack ID and asset ID. *) 2693 + let remove_asset_from_stack ~asset_id ~id t () = 2694 + let url_path = Openapi.Runtime.Path.render ~params:[("assetId", asset_id); ("id", id)] "/stacks/{id}/assets/{assetId}" in 2695 + let query = "" in 2696 + let url = t.base_url ^ url_path ^ query in 2697 + let response = Requests.delete t.session url in 2698 + if Requests.Response.ok response then 2699 + Requests.Response.json response 2700 + else 2701 + failwith (Printf.sprintf "HTTP %d: %s" (Requests.Response.status_code response) (Requests.Response.text response)) 2702 + 2703 + (** Retrieve acknowledgements 2704 + 2705 + Retrieve the synchronization acknowledgments for the current session. *) 2706 + let get_sync_ack t () = 2707 + let url_path = "/sync/ack" in 2708 + let query = "" in 2709 + let url = t.base_url ^ url_path ^ query in 2710 + let response = Requests.get t.session url in 2711 + if Requests.Response.ok response then 2712 + Openapi.Runtime.Json.decode_json_exn (Jsont.list Types.SyncAckDto.t_jsont) (Requests.Response.json response) 2713 + else 2714 + failwith (Printf.sprintf "HTTP %d: %s" (Requests.Response.status_code response) (Requests.Response.text response)) 2715 + 2716 + (** Acknowledge changes 2717 + 2718 + Send a list of synchronization acknowledgements to confirm that the latest changes have been received. *) 2719 + let send_sync_ack ~body t () = 2720 + let url_path = "/sync/ack" in 2721 + let query = "" in 2722 + let url = t.base_url ^ url_path ^ query in 2723 + let response = Requests.post t.session ~body:(Requests.Body.json (Openapi.Runtime.Json.encode_json Types.SyncAckSetDto.t_jsont body)) url in 2724 + if Requests.Response.ok response then 2725 + Requests.Response.json response 2726 + else 2727 + failwith (Printf.sprintf "HTTP %d: %s" (Requests.Response.status_code response) (Requests.Response.text response)) 2728 + 2729 + (** Delete acknowledgements 2730 + 2731 + Delete specific synchronization acknowledgments. *) 2732 + let delete_sync_ack t () = 2733 + let url_path = "/sync/ack" in 2734 + let query = "" in 2735 + let url = t.base_url ^ url_path ^ query in 2736 + let response = Requests.delete t.session url in 2737 + if Requests.Response.ok response then 2738 + Requests.Response.json response 2739 + else 2740 + failwith (Printf.sprintf "HTTP %d: %s" (Requests.Response.status_code response) (Requests.Response.text response)) 2741 + 2742 + (** Get delta sync for user 2743 + 2744 + Retrieve changed assets since the last sync for the authenticated user. *) 2745 + let get_delta_sync ~body t () = 2746 + let url_path = "/sync/delta-sync" in 2747 + let query = "" in 2748 + let url = t.base_url ^ url_path ^ query in 2749 + let response = Requests.post t.session ~body:(Requests.Body.json (Openapi.Runtime.Json.encode_json Types.AssetDeltaSyncDto.t_jsont body)) url in 2750 + if Requests.Response.ok response then 2751 + Openapi.Runtime.Json.decode_json_exn Types.AssetDeltaSyncResponseDto.t_jsont (Requests.Response.json response) 2752 + else 2753 + failwith (Printf.sprintf "HTTP %d: %s" (Requests.Response.status_code response) (Requests.Response.text response)) 2754 + 2755 + (** Get full sync for user 2756 + 2757 + Retrieve all assets for a full synchronization for the authenticated user. *) 2758 + let get_full_sync_for_user ~body t () = 2759 + let url_path = "/sync/full-sync" in 2760 + let query = "" in 2761 + let url = t.base_url ^ url_path ^ query in 2762 + let response = Requests.post t.session ~body:(Requests.Body.json (Openapi.Runtime.Json.encode_json Types.AssetFullSyncDto.t_jsont body)) url in 2763 + if Requests.Response.ok response then 2764 + Openapi.Runtime.Json.decode_json_exn (Jsont.list Types.AssetResponseDto.t_jsont) (Requests.Response.json response) 2765 + else 2766 + failwith (Printf.sprintf "HTTP %d: %s" (Requests.Response.status_code response) (Requests.Response.text response)) 2767 + 2768 + (** Stream sync changes 2769 + 2770 + Retrieve a JSON lines streamed response of changes for synchronization. This endpoint is used by the mobile app to efficiently stay up to date with changes. *) 2771 + let get_sync_stream ~body t () = 2772 + let url_path = "/sync/stream" in 2773 + let query = "" in 2774 + let url = t.base_url ^ url_path ^ query in 2775 + let response = Requests.post t.session ~body:(Requests.Body.json (Openapi.Runtime.Json.encode_json Types.SyncStreamDto.t_jsont body)) url in 2776 + if Requests.Response.ok response then 2777 + Requests.Response.json response 2778 + else 2779 + failwith (Printf.sprintf "HTTP %d: %s" (Requests.Response.status_code response) (Requests.Response.text response)) 2780 + 2781 + (** Get system configuration 2782 + 2783 + Retrieve the current system configuration. *) 2784 + let get_config t () = 2785 + let url_path = "/system-config" in 2786 + let query = "" in 2787 + let url = t.base_url ^ url_path ^ query in 2788 + let response = Requests.get t.session url in 2789 + if Requests.Response.ok response then 2790 + Openapi.Runtime.Json.decode_json_exn Types.SystemConfigDto.t_jsont (Requests.Response.json response) 2791 + else 2792 + failwith (Printf.sprintf "HTTP %d: %s" (Requests.Response.status_code response) (Requests.Response.text response)) 2793 + 2794 + (** Update system configuration 2795 + 2796 + Update the system configuration with a new system configuration. *) 2797 + let update_config ~body t () = 2798 + let url_path = "/system-config" in 2799 + let query = "" in 2800 + let url = t.base_url ^ url_path ^ query in 2801 + let response = Requests.put t.session ~body:(Requests.Body.json (Openapi.Runtime.Json.encode_json Types.SystemConfigDto.t_jsont body)) url in 2802 + if Requests.Response.ok response then 2803 + Openapi.Runtime.Json.decode_json_exn Types.SystemConfigDto.t_jsont (Requests.Response.json response) 2804 + else 2805 + failwith (Printf.sprintf "HTTP %d: %s" (Requests.Response.status_code response) (Requests.Response.text response)) 2806 + 2807 + (** Get system configuration defaults 2808 + 2809 + Retrieve the default values for the system configuration. *) 2810 + let get_config_defaults t () = 2811 + let url_path = "/system-config/defaults" in 2812 + let query = "" in 2813 + let url = t.base_url ^ url_path ^ query in 2814 + let response = Requests.get t.session url in 2815 + if Requests.Response.ok response then 2816 + Openapi.Runtime.Json.decode_json_exn Types.SystemConfigDto.t_jsont (Requests.Response.json response) 2817 + else 2818 + failwith (Printf.sprintf "HTTP %d: %s" (Requests.Response.status_code response) (Requests.Response.text response)) 2819 + 2820 + (** Get storage template options 2821 + 2822 + Retrieve exemplary storage template options. *) 2823 + let get_storage_template_options t () = 2824 + let url_path = "/system-config/storage-template-options" in 2825 + let query = "" in 2826 + let url = t.base_url ^ url_path ^ query in 2827 + let response = Requests.get t.session url in 2828 + if Requests.Response.ok response then 2829 + Openapi.Runtime.Json.decode_json_exn Types.SystemConfigTemplateStorageOptionDto.t_jsont (Requests.Response.json response) 2830 + else 2831 + failwith (Printf.sprintf "HTTP %d: %s" (Requests.Response.status_code response) (Requests.Response.text response)) 2832 + 2833 + (** Retrieve admin onboarding 2834 + 2835 + Retrieve the current admin onboarding status. *) 2836 + let get_admin_onboarding t () = 2837 + let url_path = "/system-metadata/admin-onboarding" in 2838 + let query = "" in 2839 + let url = t.base_url ^ url_path ^ query in 2840 + let response = Requests.get t.session url in 2841 + if Requests.Response.ok response then 2842 + Openapi.Runtime.Json.decode_json_exn Types.AdminOnboardingUpdateDto.t_jsont (Requests.Response.json response) 2843 + else 2844 + failwith (Printf.sprintf "HTTP %d: %s" (Requests.Response.status_code response) (Requests.Response.text response)) 2845 + 2846 + (** Update admin onboarding 2847 + 2848 + Update the admin onboarding status. *) 2849 + let update_admin_onboarding ~body t () = 2850 + let url_path = "/system-metadata/admin-onboarding" in 2851 + let query = "" in 2852 + let url = t.base_url ^ url_path ^ query in 2853 + let response = Requests.post t.session ~body:(Requests.Body.json (Openapi.Runtime.Json.encode_json Types.AdminOnboardingUpdateDto.t_jsont body)) url in 2854 + if Requests.Response.ok response then 2855 + Requests.Response.json response 2856 + else 2857 + failwith (Printf.sprintf "HTTP %d: %s" (Requests.Response.status_code response) (Requests.Response.text response)) 2858 + 2859 + (** Retrieve reverse geocoding state 2860 + 2861 + Retrieve the current state of the reverse geocoding import. *) 2862 + let get_reverse_geocoding_state t () = 2863 + let url_path = "/system-metadata/reverse-geocoding-state" in 2864 + let query = "" in 2865 + let url = t.base_url ^ url_path ^ query in 2866 + let response = Requests.get t.session url in 2867 + if Requests.Response.ok response then 2868 + Openapi.Runtime.Json.decode_json_exn Types.ReverseGeocodingStateResponseDto.t_jsont (Requests.Response.json response) 2869 + else 2870 + failwith (Printf.sprintf "HTTP %d: %s" (Requests.Response.status_code response) (Requests.Response.text response)) 2871 + 2872 + (** Retrieve version check state 2873 + 2874 + Retrieve the current state of the version check process. *) 2875 + let get_version_check_state t () = 2876 + let url_path = "/system-metadata/version-check-state" in 2877 + let query = "" in 2878 + let url = t.base_url ^ url_path ^ query in 2879 + let response = Requests.get t.session url in 2880 + if Requests.Response.ok response then 2881 + Openapi.Runtime.Json.decode_json_exn Types.VersionCheckStateResponseDto.t_jsont (Requests.Response.json response) 2882 + else 2883 + failwith (Printf.sprintf "HTTP %d: %s" (Requests.Response.status_code response) (Requests.Response.text response)) 2884 + 2885 + (** Retrieve tags 2886 + 2887 + Retrieve a list of all tags. *) 2888 + let get_all_tags t () = 2889 + let url_path = "/tags" in 2890 + let query = "" in 2891 + let url = t.base_url ^ url_path ^ query in 2892 + let response = Requests.get t.session url in 2893 + if Requests.Response.ok response then 2894 + Openapi.Runtime.Json.decode_json_exn (Jsont.list Types.TagResponseDto.t_jsont) (Requests.Response.json response) 2895 + else 2896 + failwith (Printf.sprintf "HTTP %d: %s" (Requests.Response.status_code response) (Requests.Response.text response)) 2897 + 2898 + (** Create a tag 2899 + 2900 + Create a new tag by providing a name and optional color. *) 2901 + let create_tag ~body t () = 2902 + let url_path = "/tags" in 2903 + let query = "" in 2904 + let url = t.base_url ^ url_path ^ query in 2905 + let response = Requests.post t.session ~body:(Requests.Body.json (Openapi.Runtime.Json.encode_json Types.TagCreateDto.t_jsont body)) url in 2906 + if Requests.Response.ok response then 2907 + Openapi.Runtime.Json.decode_json_exn Types.TagResponseDto.t_jsont (Requests.Response.json response) 2908 + else 2909 + failwith (Printf.sprintf "HTTP %d: %s" (Requests.Response.status_code response) (Requests.Response.text response)) 2910 + 2911 + (** Upsert tags 2912 + 2913 + Create or update multiple tags in a single request. *) 2914 + let upsert_tags ~body t () = 2915 + let url_path = "/tags" in 2916 + let query = "" in 2917 + let url = t.base_url ^ url_path ^ query in 2918 + let response = Requests.put t.session ~body:(Requests.Body.json (Openapi.Runtime.Json.encode_json Types.TagUpsertDto.t_jsont body)) url in 2919 + if Requests.Response.ok response then 2920 + Openapi.Runtime.Json.decode_json_exn (Jsont.list Types.TagResponseDto.t_jsont) (Requests.Response.json response) 2921 + else 2922 + failwith (Printf.sprintf "HTTP %d: %s" (Requests.Response.status_code response) (Requests.Response.text response)) 2923 + 2924 + (** Tag assets 2925 + 2926 + Add multiple tags to multiple assets in a single request. *) 2927 + let bulk_tag_assets ~body t () = 2928 + let url_path = "/tags/assets" in 2929 + let query = "" in 2930 + let url = t.base_url ^ url_path ^ query in 2931 + let response = Requests.put t.session ~body:(Requests.Body.json (Openapi.Runtime.Json.encode_json Types.TagBulkAssetsDto.t_jsont body)) url in 2932 + if Requests.Response.ok response then 2933 + Openapi.Runtime.Json.decode_json_exn Types.TagBulkAssetsResponseDto.t_jsont (Requests.Response.json response) 2934 + else 2935 + failwith (Printf.sprintf "HTTP %d: %s" (Requests.Response.status_code response) (Requests.Response.text response)) 2936 + 2937 + (** Retrieve a tag 2938 + 2939 + Retrieve a specific tag by its ID. *) 2940 + let get_tag_by_id ~id t () = 2941 + let url_path = Openapi.Runtime.Path.render ~params:[("id", id)] "/tags/{id}" in 2942 + let query = "" in 2943 + let url = t.base_url ^ url_path ^ query in 2944 + let response = Requests.get t.session url in 2945 + if Requests.Response.ok response then 2946 + Openapi.Runtime.Json.decode_json_exn Types.TagResponseDto.t_jsont (Requests.Response.json response) 2947 + else 2948 + failwith (Printf.sprintf "HTTP %d: %s" (Requests.Response.status_code response) (Requests.Response.text response)) 2949 + 2950 + (** Update a tag 2951 + 2952 + Update an existing tag identified by its ID. *) 2953 + let update_tag ~id ~body t () = 2954 + let url_path = Openapi.Runtime.Path.render ~params:[("id", id)] "/tags/{id}" in 2955 + let query = "" in 2956 + let url = t.base_url ^ url_path ^ query in 2957 + let response = Requests.put t.session ~body:(Requests.Body.json (Openapi.Runtime.Json.encode_json Types.TagUpdateDto.t_jsont body)) url in 2958 + if Requests.Response.ok response then 2959 + Openapi.Runtime.Json.decode_json_exn Types.TagResponseDto.t_jsont (Requests.Response.json response) 2960 + else 2961 + failwith (Printf.sprintf "HTTP %d: %s" (Requests.Response.status_code response) (Requests.Response.text response)) 2962 + 2963 + (** Delete a tag 2964 + 2965 + Delete a specific tag by its ID. *) 2966 + let delete_tag ~id t () = 2967 + let url_path = Openapi.Runtime.Path.render ~params:[("id", id)] "/tags/{id}" in 2968 + let query = "" in 2969 + let url = t.base_url ^ url_path ^ query in 2970 + let response = Requests.delete t.session url in 2971 + if Requests.Response.ok response then 2972 + Requests.Response.json response 2973 + else 2974 + failwith (Printf.sprintf "HTTP %d: %s" (Requests.Response.status_code response) (Requests.Response.text response)) 2975 + 2976 + (** Tag assets 2977 + 2978 + Add a tag to all the specified assets. *) 2979 + let tag_assets ~id ~body t () = 2980 + let url_path = Openapi.Runtime.Path.render ~params:[("id", id)] "/tags/{id}/assets" in 2981 + let query = "" in 2982 + let url = t.base_url ^ url_path ^ query in 2983 + let response = Requests.put t.session ~body:(Requests.Body.json (Openapi.Runtime.Json.encode_json Types.BulkIdsDto.t_jsont body)) url in 2984 + if Requests.Response.ok response then 2985 + Openapi.Runtime.Json.decode_json_exn (Jsont.list Types.BulkIdResponseDto.t_jsont) (Requests.Response.json response) 2986 + else 2987 + failwith (Printf.sprintf "HTTP %d: %s" (Requests.Response.status_code response) (Requests.Response.text response)) 2988 + 2989 + (** Untag assets 2990 + 2991 + Remove a tag from all the specified assets. *) 2992 + let untag_assets ~id t () = 2993 + let url_path = Openapi.Runtime.Path.render ~params:[("id", id)] "/tags/{id}/assets" in 2994 + let query = "" in 2995 + let url = t.base_url ^ url_path ^ query in 2996 + let response = Requests.delete t.session url in 2997 + if Requests.Response.ok response then 2998 + Openapi.Runtime.Json.decode_json_exn (Jsont.list Types.BulkIdResponseDto.t_jsont) (Requests.Response.json response) 2999 + else 3000 + failwith (Printf.sprintf "HTTP %d: %s" (Requests.Response.status_code response) (Requests.Response.text response)) 3001 + 3002 + (** Get time bucket 3003 + 3004 + Retrieve a string of all asset ids in a given time bucket. *) 3005 + let get_time_bucket ?album_id ?is_favorite ?is_trashed ?key ?order ?person_id ?slug ?tag_id ~time_bucket ?user_id ?visibility ?with_coordinates ?with_partners ?with_stacked t () = 3006 + let url_path = "/timeline/bucket" in 3007 + let query = Openapi.Runtime.Query.encode (List.concat [ 3008 + Openapi.Runtime.Query.optional ~key:"albumId" ~value:album_id; 3009 + Openapi.Runtime.Query.optional ~key:"isFavorite" ~value:is_favorite; 3010 + Openapi.Runtime.Query.optional ~key:"isTrashed" ~value:is_trashed; 3011 + Openapi.Runtime.Query.optional ~key:"key" ~value:key; 3012 + Openapi.Runtime.Query.optional ~key:"order" ~value:order; 3013 + Openapi.Runtime.Query.optional ~key:"personId" ~value:person_id; 3014 + Openapi.Runtime.Query.optional ~key:"slug" ~value:slug; 3015 + Openapi.Runtime.Query.optional ~key:"tagId" ~value:tag_id; 3016 + Openapi.Runtime.Query.singleton ~key:"timeBucket" ~value:time_bucket; 3017 + Openapi.Runtime.Query.optional ~key:"userId" ~value:user_id; 3018 + Openapi.Runtime.Query.optional ~key:"visibility" ~value:visibility; 3019 + Openapi.Runtime.Query.optional ~key:"withCoordinates" ~value:with_coordinates; 3020 + Openapi.Runtime.Query.optional ~key:"withPartners" ~value:with_partners; 3021 + Openapi.Runtime.Query.optional ~key:"withStacked" ~value:with_stacked 3022 + ]) in 3023 + let url = t.base_url ^ url_path ^ query in 3024 + let response = Requests.get t.session url in 3025 + if Requests.Response.ok response then 3026 + Openapi.Runtime.Json.decode_json_exn Types.TimeBucketAssetResponseDto.t_jsont (Requests.Response.json response) 3027 + else 3028 + failwith (Printf.sprintf "HTTP %d: %s" (Requests.Response.status_code response) (Requests.Response.text response)) 3029 + 3030 + (** Get time buckets 3031 + 3032 + Retrieve a list of all minimal time buckets. *) 3033 + let get_time_buckets ?album_id ?is_favorite ?is_trashed ?key ?order ?person_id ?slug ?tag_id ?user_id ?visibility ?with_coordinates ?with_partners ?with_stacked t () = 3034 + let url_path = "/timeline/buckets" in 3035 + let query = Openapi.Runtime.Query.encode (List.concat [ 3036 + Openapi.Runtime.Query.optional ~key:"albumId" ~value:album_id; 3037 + Openapi.Runtime.Query.optional ~key:"isFavorite" ~value:is_favorite; 3038 + Openapi.Runtime.Query.optional ~key:"isTrashed" ~value:is_trashed; 3039 + Openapi.Runtime.Query.optional ~key:"key" ~value:key; 3040 + Openapi.Runtime.Query.optional ~key:"order" ~value:order; 3041 + Openapi.Runtime.Query.optional ~key:"personId" ~value:person_id; 3042 + Openapi.Runtime.Query.optional ~key:"slug" ~value:slug; 3043 + Openapi.Runtime.Query.optional ~key:"tagId" ~value:tag_id; 3044 + Openapi.Runtime.Query.optional ~key:"userId" ~value:user_id; 3045 + Openapi.Runtime.Query.optional ~key:"visibility" ~value:visibility; 3046 + Openapi.Runtime.Query.optional ~key:"withCoordinates" ~value:with_coordinates; 3047 + Openapi.Runtime.Query.optional ~key:"withPartners" ~value:with_partners; 3048 + Openapi.Runtime.Query.optional ~key:"withStacked" ~value:with_stacked 3049 + ]) in 3050 + let url = t.base_url ^ url_path ^ query in 3051 + let response = Requests.get t.session url in 3052 + if Requests.Response.ok response then 3053 + Openapi.Runtime.Json.decode_json_exn (Jsont.list Types.TimeBucketsResponseDto.t_jsont) (Requests.Response.json response) 3054 + else 3055 + failwith (Printf.sprintf "HTTP %d: %s" (Requests.Response.status_code response) (Requests.Response.text response)) 3056 + 3057 + (** Empty trash 3058 + 3059 + Permanently delete all items in the trash. *) 3060 + let empty_trash t () = 3061 + let url_path = "/trash/empty" in 3062 + let query = "" in 3063 + let url = t.base_url ^ url_path ^ query in 3064 + let response = Requests.post t.session url in 3065 + if Requests.Response.ok response then 3066 + Openapi.Runtime.Json.decode_json_exn Types.TrashResponseDto.t_jsont (Requests.Response.json response) 3067 + else 3068 + failwith (Printf.sprintf "HTTP %d: %s" (Requests.Response.status_code response) (Requests.Response.text response)) 3069 + 3070 + (** Restore trash 3071 + 3072 + Restore all items in the trash. *) 3073 + let restore_trash t () = 3074 + let url_path = "/trash/restore" in 3075 + let query = "" in 3076 + let url = t.base_url ^ url_path ^ query in 3077 + let response = Requests.post t.session url in 3078 + if Requests.Response.ok response then 3079 + Openapi.Runtime.Json.decode_json_exn Types.TrashResponseDto.t_jsont (Requests.Response.json response) 3080 + else 3081 + failwith (Printf.sprintf "HTTP %d: %s" (Requests.Response.status_code response) (Requests.Response.text response)) 3082 + 3083 + (** Restore assets 3084 + 3085 + Restore specific assets from the trash. *) 3086 + let restore_assets ~body t () = 3087 + let url_path = "/trash/restore/assets" in 3088 + let query = "" in 3089 + let url = t.base_url ^ url_path ^ query in 3090 + let response = Requests.post t.session ~body:(Requests.Body.json (Openapi.Runtime.Json.encode_json Types.BulkIdsDto.t_jsont body)) url in 3091 + if Requests.Response.ok response then 3092 + Openapi.Runtime.Json.decode_json_exn Types.TrashResponseDto.t_jsont (Requests.Response.json response) 3093 + else 3094 + failwith (Printf.sprintf "HTTP %d: %s" (Requests.Response.status_code response) (Requests.Response.text response)) 3095 + 3096 + (** Get all users 3097 + 3098 + Retrieve a list of all users on the server. *) 3099 + let search_users t () = 3100 + let url_path = "/users" in 3101 + let query = "" in 3102 + let url = t.base_url ^ url_path ^ query in 3103 + let response = Requests.get t.session url in 3104 + if Requests.Response.ok response then 3105 + Openapi.Runtime.Json.decode_json_exn (Jsont.list Types.UserResponseDto.t_jsont) (Requests.Response.json response) 3106 + else 3107 + failwith (Printf.sprintf "HTTP %d: %s" (Requests.Response.status_code response) (Requests.Response.text response)) 3108 + 3109 + (** Get current user 3110 + 3111 + Retrieve information about the user making the API request. *) 3112 + let get_my_user t () = 3113 + let url_path = "/users/me" in 3114 + let query = "" in 3115 + let url = t.base_url ^ url_path ^ query in 3116 + let response = Requests.get t.session url in 3117 + if Requests.Response.ok response then 3118 + Openapi.Runtime.Json.decode_json_exn Types.UserAdminResponseDto.t_jsont (Requests.Response.json response) 3119 + else 3120 + failwith (Printf.sprintf "HTTP %d: %s" (Requests.Response.status_code response) (Requests.Response.text response)) 3121 + 3122 + (** Update current user 3123 + 3124 + Update the current user making teh API request. *) 3125 + let update_my_user ~body t () = 3126 + let url_path = "/users/me" in 3127 + let query = "" in 3128 + let url = t.base_url ^ url_path ^ query in 3129 + let response = Requests.put t.session ~body:(Requests.Body.json (Openapi.Runtime.Json.encode_json Types.UserUpdateMeDto.t_jsont body)) url in 3130 + if Requests.Response.ok response then 3131 + Openapi.Runtime.Json.decode_json_exn Types.UserAdminResponseDto.t_jsont (Requests.Response.json response) 3132 + else 3133 + failwith (Printf.sprintf "HTTP %d: %s" (Requests.Response.status_code response) (Requests.Response.text response)) 3134 + 3135 + (** Retrieve user product key 3136 + 3137 + Retrieve information about whether the current user has a registered product key. *) 3138 + let get_user_license t () = 3139 + let url_path = "/users/me/license" in 3140 + let query = "" in 3141 + let url = t.base_url ^ url_path ^ query in 3142 + let response = Requests.get t.session url in 3143 + if Requests.Response.ok response then 3144 + Openapi.Runtime.Json.decode_json_exn Types.LicenseResponseDto.t_jsont (Requests.Response.json response) 3145 + else 3146 + failwith (Printf.sprintf "HTTP %d: %s" (Requests.Response.status_code response) (Requests.Response.text response)) 3147 + 3148 + (** Set user product key 3149 + 3150 + Register a product key for the current user. *) 3151 + let set_user_license ~body t () = 3152 + let url_path = "/users/me/license" in 3153 + let query = "" in 3154 + let url = t.base_url ^ url_path ^ query in 3155 + let response = Requests.put t.session ~body:(Requests.Body.json (Openapi.Runtime.Json.encode_json Types.LicenseKeyDto.t_jsont body)) url in 3156 + if Requests.Response.ok response then 3157 + Openapi.Runtime.Json.decode_json_exn Types.LicenseResponseDto.t_jsont (Requests.Response.json response) 3158 + else 3159 + failwith (Printf.sprintf "HTTP %d: %s" (Requests.Response.status_code response) (Requests.Response.text response)) 3160 + 3161 + (** Delete user product key 3162 + 3163 + Delete the registered product key for the current user. *) 3164 + let delete_user_license t () = 3165 + let url_path = "/users/me/license" in 3166 + let query = "" in 3167 + let url = t.base_url ^ url_path ^ query in 3168 + let response = Requests.delete t.session url in 3169 + if Requests.Response.ok response then 3170 + Requests.Response.json response 3171 + else 3172 + failwith (Printf.sprintf "HTTP %d: %s" (Requests.Response.status_code response) (Requests.Response.text response)) 3173 + 3174 + (** Retrieve user onboarding 3175 + 3176 + Retrieve the onboarding status of the current user. *) 3177 + let get_user_onboarding t () = 3178 + let url_path = "/users/me/onboarding" in 3179 + let query = "" in 3180 + let url = t.base_url ^ url_path ^ query in 3181 + let response = Requests.get t.session url in 3182 + if Requests.Response.ok response then 3183 + Openapi.Runtime.Json.decode_json_exn Types.OnboardingResponseDto.t_jsont (Requests.Response.json response) 3184 + else 3185 + failwith (Printf.sprintf "HTTP %d: %s" (Requests.Response.status_code response) (Requests.Response.text response)) 3186 + 3187 + (** Update user onboarding 3188 + 3189 + Update the onboarding status of the current user. *) 3190 + let set_user_onboarding ~body t () = 3191 + let url_path = "/users/me/onboarding" in 3192 + let query = "" in 3193 + let url = t.base_url ^ url_path ^ query in 3194 + let response = Requests.put t.session ~body:(Requests.Body.json (Openapi.Runtime.Json.encode_json Types.OnboardingDto.t_jsont body)) url in 3195 + if Requests.Response.ok response then 3196 + Openapi.Runtime.Json.decode_json_exn Types.OnboardingResponseDto.t_jsont (Requests.Response.json response) 3197 + else 3198 + failwith (Printf.sprintf "HTTP %d: %s" (Requests.Response.status_code response) (Requests.Response.text response)) 3199 + 3200 + (** Delete user onboarding 3201 + 3202 + Delete the onboarding status of the current user. *) 3203 + let delete_user_onboarding t () = 3204 + let url_path = "/users/me/onboarding" in 3205 + let query = "" in 3206 + let url = t.base_url ^ url_path ^ query in 3207 + let response = Requests.delete t.session url in 3208 + if Requests.Response.ok response then 3209 + Requests.Response.json response 3210 + else 3211 + failwith (Printf.sprintf "HTTP %d: %s" (Requests.Response.status_code response) (Requests.Response.text response)) 3212 + 3213 + (** Get my preferences 3214 + 3215 + Retrieve the preferences for the current user. *) 3216 + let get_my_preferences t () = 3217 + let url_path = "/users/me/preferences" in 3218 + let query = "" in 3219 + let url = t.base_url ^ url_path ^ query in 3220 + let response = Requests.get t.session url in 3221 + if Requests.Response.ok response then 3222 + Openapi.Runtime.Json.decode_json_exn Types.UserPreferencesResponseDto.t_jsont (Requests.Response.json response) 3223 + else 3224 + failwith (Printf.sprintf "HTTP %d: %s" (Requests.Response.status_code response) (Requests.Response.text response)) 3225 + 3226 + (** Update my preferences 3227 + 3228 + Update the preferences of the current user. *) 3229 + let update_my_preferences ~body t () = 3230 + let url_path = "/users/me/preferences" in 3231 + let query = "" in 3232 + let url = t.base_url ^ url_path ^ query in 3233 + let response = Requests.put t.session ~body:(Requests.Body.json (Openapi.Runtime.Json.encode_json Types.UserPreferencesUpdateDto.t_jsont body)) url in 3234 + if Requests.Response.ok response then 3235 + Openapi.Runtime.Json.decode_json_exn Types.UserPreferencesResponseDto.t_jsont (Requests.Response.json response) 3236 + else 3237 + failwith (Printf.sprintf "HTTP %d: %s" (Requests.Response.status_code response) (Requests.Response.text response)) 3238 + 3239 + (** Create user profile image 3240 + 3241 + Upload and set a new profile image for the current user. *) 3242 + let create_profile_image ~body t () = 3243 + let url_path = "/users/profile-image" in 3244 + let query = "" in 3245 + let url = t.base_url ^ url_path ^ query in 3246 + let response = Requests.post t.session ~body:(Requests.Body.json (Openapi.Runtime.Json.encode_json Jsont.json body)) url in 3247 + if Requests.Response.ok response then 3248 + Openapi.Runtime.Json.decode_json_exn Types.CreateProfileImageResponseDto.t_jsont (Requests.Response.json response) 3249 + else 3250 + failwith (Printf.sprintf "HTTP %d: %s" (Requests.Response.status_code response) (Requests.Response.text response)) 3251 + 3252 + (** Delete user profile image 3253 + 3254 + Delete the profile image of the current user. *) 3255 + let delete_profile_image t () = 3256 + let url_path = "/users/profile-image" in 3257 + let query = "" in 3258 + let url = t.base_url ^ url_path ^ query in 3259 + let response = Requests.delete t.session url in 3260 + if Requests.Response.ok response then 3261 + Requests.Response.json response 3262 + else 3263 + failwith (Printf.sprintf "HTTP %d: %s" (Requests.Response.status_code response) (Requests.Response.text response)) 3264 + 3265 + (** Retrieve a user 3266 + 3267 + Retrieve a specific user by their ID. *) 3268 + let get_user ~id t () = 3269 + let url_path = Openapi.Runtime.Path.render ~params:[("id", id)] "/users/{id}" in 3270 + let query = "" in 3271 + let url = t.base_url ^ url_path ^ query in 3272 + let response = Requests.get t.session url in 3273 + if Requests.Response.ok response then 3274 + Openapi.Runtime.Json.decode_json_exn Types.UserResponseDto.t_jsont (Requests.Response.json response) 3275 + else 3276 + failwith (Printf.sprintf "HTTP %d: %s" (Requests.Response.status_code response) (Requests.Response.text response)) 3277 + 3278 + (** Retrieve user profile image 3279 + 3280 + Retrieve the profile image file for a user. *) 3281 + let get_profile_image ~id t () = 3282 + let url_path = Openapi.Runtime.Path.render ~params:[("id", id)] "/users/{id}/profile-image" in 3283 + let query = "" in 3284 + let url = t.base_url ^ url_path ^ query in 3285 + let response = Requests.get t.session url in 3286 + if Requests.Response.ok response then 3287 + Requests.Response.json response 3288 + else 3289 + failwith (Printf.sprintf "HTTP %d: %s" (Requests.Response.status_code response) (Requests.Response.text response)) 3290 + 3291 + (** Retrieve assets by original path 3292 + 3293 + Retrieve assets that are children of a specific folder. *) 3294 + let get_assets_by_original_path ~path t () = 3295 + let url_path = "/view/folder" in 3296 + let query = Openapi.Runtime.Query.encode (List.concat [ 3297 + Openapi.Runtime.Query.singleton ~key:"path" ~value:path 3298 + ]) in 3299 + let url = t.base_url ^ url_path ^ query in 3300 + let response = Requests.get t.session url in 3301 + if Requests.Response.ok response then 3302 + Openapi.Runtime.Json.decode_json_exn (Jsont.list Types.AssetResponseDto.t_jsont) (Requests.Response.json response) 3303 + else 3304 + failwith (Printf.sprintf "HTTP %d: %s" (Requests.Response.status_code response) (Requests.Response.text response)) 3305 + 3306 + (** Retrieve unique paths 3307 + 3308 + Retrieve a list of unique folder paths from asset original paths. *) 3309 + let get_unique_original_paths t () = 3310 + let url_path = "/view/folder/unique-paths" in 3311 + let query = "" in 3312 + let url = t.base_url ^ url_path ^ query in 3313 + let response = Requests.get t.session url in 3314 + if Requests.Response.ok response then 3315 + Requests.Response.json response 3316 + else 3317 + failwith (Printf.sprintf "HTTP %d: %s" (Requests.Response.status_code response) (Requests.Response.text response)) 3318 + 3319 + (** List all workflows 3320 + 3321 + Retrieve a list of workflows available to the authenticated user. *) 3322 + let get_workflows t () = 3323 + let url_path = "/workflows" in 3324 + let query = "" in 3325 + let url = t.base_url ^ url_path ^ query in 3326 + let response = Requests.get t.session url in 3327 + if Requests.Response.ok response then 3328 + Openapi.Runtime.Json.decode_json_exn (Jsont.list Types.WorkflowResponseDto.t_jsont) (Requests.Response.json response) 3329 + else 3330 + failwith (Printf.sprintf "HTTP %d: %s" (Requests.Response.status_code response) (Requests.Response.text response)) 3331 + 3332 + (** Create a workflow 3333 + 3334 + Create a new workflow, the workflow can also be created with empty filters and actions. *) 3335 + let create_workflow ~body t () = 3336 + let url_path = "/workflows" in 3337 + let query = "" in 3338 + let url = t.base_url ^ url_path ^ query in 3339 + let response = Requests.post t.session ~body:(Requests.Body.json (Openapi.Runtime.Json.encode_json Types.WorkflowCreateDto.t_jsont body)) url in 3340 + if Requests.Response.ok response then 3341 + Openapi.Runtime.Json.decode_json_exn Types.WorkflowResponseDto.t_jsont (Requests.Response.json response) 3342 + else 3343 + failwith (Printf.sprintf "HTTP %d: %s" (Requests.Response.status_code response) (Requests.Response.text response)) 3344 + 3345 + (** Retrieve a workflow 3346 + 3347 + Retrieve information about a specific workflow by its ID. *) 3348 + let get_workflow ~id t () = 3349 + let url_path = Openapi.Runtime.Path.render ~params:[("id", id)] "/workflows/{id}" in 3350 + let query = "" in 3351 + let url = t.base_url ^ url_path ^ query in 3352 + let response = Requests.get t.session url in 3353 + if Requests.Response.ok response then 3354 + Openapi.Runtime.Json.decode_json_exn Types.WorkflowResponseDto.t_jsont (Requests.Response.json response) 3355 + else 3356 + failwith (Printf.sprintf "HTTP %d: %s" (Requests.Response.status_code response) (Requests.Response.text response)) 3357 + 3358 + (** Update a workflow 3359 + 3360 + Update the information of a specific workflow by its ID. This endpoint can be used to update the workflow name, description, trigger type, filters and actions order, etc. *) 3361 + let update_workflow ~id ~body t () = 3362 + let url_path = Openapi.Runtime.Path.render ~params:[("id", id)] "/workflows/{id}" in 3363 + let query = "" in 3364 + let url = t.base_url ^ url_path ^ query in 3365 + let response = Requests.put t.session ~body:(Requests.Body.json (Openapi.Runtime.Json.encode_json Types.WorkflowUpdateDto.t_jsont body)) url in 3366 + if Requests.Response.ok response then 3367 + Openapi.Runtime.Json.decode_json_exn Types.WorkflowResponseDto.t_jsont (Requests.Response.json response) 3368 + else 3369 + failwith (Printf.sprintf "HTTP %d: %s" (Requests.Response.status_code response) (Requests.Response.text response)) 3370 + 3371 + (** Delete a workflow 3372 + 3373 + Delete a workflow by its ID. *) 3374 + let delete_workflow ~id t () = 3375 + let url_path = Openapi.Runtime.Path.render ~params:[("id", id)] "/workflows/{id}" in 3376 + let query = "" in 3377 + let url = t.base_url ^ url_path ^ query in 3378 + let response = Requests.delete t.session url in 3379 + if Requests.Response.ok response then 3380 + Requests.Response.json response 3381 + else 3382 + failwith (Printf.sprintf "HTTP %d: %s" (Requests.Response.status_code response) (Requests.Response.text response))
+1239
ocaml-immich/client.mli
··· 1 + (** Immich API 2 + 3 + @version 2.4.1 *) 4 + 5 + (** Client connection type *) 6 + type t 7 + 8 + (** Create a new API client. 9 + @param session Optional existing requests session 10 + @param sw Eio switch for managing resources 11 + @param env Eio environment 12 + @param base_url Base URL for the API *) 13 + val create : 14 + ?session:Requests.t -> 15 + sw:Eio.Switch.t -> 16 + < net : _ Eio.Net.t ; fs : Eio.Fs.dir_ty Eio.Path.t ; clock : _ Eio.Time.clock ; .. > -> 17 + base_url:string -> 18 + t 19 + 20 + (** Get the base URL *) 21 + val base_url : t -> string 22 + 23 + (** Get the underlying requests session *) 24 + val session : t -> Requests.t 25 + 26 + (** List all activities 27 + 28 + Returns a list of activities for the selected asset or album. The activities are returned in sorted order, with the oldest activities appearing first. *) 29 + val get_activities : album_id:string -> ?asset_id:string -> ?level:string -> ?type_:string -> ?user_id:string -> t -> unit -> Types.ActivityResponseDto.t list 30 + 31 + (** Create an activity 32 + 33 + Create a like or a comment for an album, or an asset in an album. *) 34 + val create_activity : body:Types.ActivityCreateDto.t -> t -> unit -> Types.ActivityResponseDto.t 35 + 36 + (** Retrieve activity statistics 37 + 38 + Returns the number of likes and comments for a given album or asset in an album. *) 39 + val get_activity_statistics : album_id:string -> ?asset_id:string -> t -> unit -> Types.ActivityStatisticsResponseDto.t 40 + 41 + (** Delete an activity 42 + 43 + Removes a like or comment from a given album or asset in an album. *) 44 + val delete_activity : id:string -> t -> unit -> Jsont.json 45 + 46 + (** Unlink all OAuth accounts 47 + 48 + Unlinks all OAuth accounts associated with user accounts in the system. *) 49 + val unlink_all_oauth_accounts_admin : t -> unit -> Jsont.json 50 + 51 + (** List database backups 52 + 53 + Get the list of the successful and failed backups *) 54 + val list_database_backups : t -> unit -> Types.DatabaseBackupListResponseDto.t 55 + 56 + (** Delete database backup 57 + 58 + Delete a backup by its filename *) 59 + val delete_database_backup : t -> unit -> Jsont.json 60 + 61 + (** Start database backup restore flow 62 + 63 + Put Immich into maintenance mode to restore a backup (Immich must not be configured) *) 64 + val start_database_restore_flow : t -> unit -> Jsont.json 65 + 66 + (** Upload database backup 67 + 68 + Uploads .sql/.sql.gz file to restore backup from *) 69 + val upload_database_backup : body:Jsont.json -> t -> unit -> Jsont.json 70 + 71 + (** Download database backup 72 + 73 + Downloads the database backup file *) 74 + val download_database_backup : filename:string -> t -> unit -> Jsont.json 75 + 76 + (** Set maintenance mode 77 + 78 + Put Immich into or take it out of maintenance mode *) 79 + val set_maintenance_mode : body:Types.SetMaintenanceModeDto.t -> t -> unit -> Jsont.json 80 + 81 + (** Detect existing install 82 + 83 + Collect integrity checks and other heuristics about local data. *) 84 + val detect_prior_install : t -> unit -> Types.MaintenanceDetectInstallResponseDto.t 85 + 86 + (** Log into maintenance mode 87 + 88 + Login with maintenance token or cookie to receive current information and perform further actions. *) 89 + val maintenance_login : body:Types.MaintenanceLoginDto.t -> t -> unit -> Types.MaintenanceAuthDto.t 90 + 91 + (** Get maintenance mode status 92 + 93 + Fetch information about the currently running maintenance action. *) 94 + val get_maintenance_status : t -> unit -> Types.MaintenanceStatusResponseDto.t 95 + 96 + (** Create a notification 97 + 98 + Create a new notification for a specific user. *) 99 + val create_notification : body:Types.NotificationCreateDto.t -> t -> unit -> Types.NotificationDto.t 100 + 101 + (** Render email template 102 + 103 + Retrieve a preview of the provided email template. *) 104 + val get_notification_template_admin : name:string -> body:Types.TemplateDto.t -> t -> unit -> Types.TemplateResponseDto.t 105 + 106 + (** Send test email 107 + 108 + Send a test email using the provided SMTP configuration. *) 109 + val send_test_email_admin : body:Types.SystemConfigSmtpDto.t -> t -> unit -> Types.TestEmailResponseDto.t 110 + 111 + (** Search users 112 + 113 + Search for users. *) 114 + val search_users_admin : ?id:string -> ?with_deleted:string -> t -> unit -> Types.UserAdminResponseDto.t list 115 + 116 + (** Create a user 117 + 118 + Create a new user. *) 119 + val create_user_admin : body:Types.UserAdminCreateDto.t -> t -> unit -> Types.UserAdminResponseDto.t 120 + 121 + (** Retrieve a user 122 + 123 + Retrieve a specific user by their ID. *) 124 + val get_user_admin : id:string -> t -> unit -> Types.UserAdminResponseDto.t 125 + 126 + (** Update a user 127 + 128 + Update an existing user. *) 129 + val update_user_admin : id:string -> body:Types.UserAdminUpdateDto.t -> t -> unit -> Types.UserAdminResponseDto.t 130 + 131 + (** Delete a user 132 + 133 + Delete a user. *) 134 + val delete_user_admin : id:string -> t -> unit -> Types.UserAdminResponseDto.t 135 + 136 + (** Retrieve user preferences 137 + 138 + Retrieve the preferences of a specific user. *) 139 + val get_user_preferences_admin : id:string -> t -> unit -> Types.UserPreferencesResponseDto.t 140 + 141 + (** Update user preferences 142 + 143 + Update the preferences of a specific user. *) 144 + val update_user_preferences_admin : id:string -> body:Types.UserPreferencesUpdateDto.t -> t -> unit -> Types.UserPreferencesResponseDto.t 145 + 146 + (** Restore a deleted user 147 + 148 + Restore a previously deleted user. *) 149 + val restore_user_admin : id:string -> t -> unit -> Types.UserAdminResponseDto.t 150 + 151 + (** Retrieve user sessions 152 + 153 + Retrieve all sessions for a specific user. *) 154 + val get_user_sessions_admin : id:string -> t -> unit -> Types.SessionResponseDto.t list 155 + 156 + (** Retrieve user statistics 157 + 158 + Retrieve asset statistics for a specific user. *) 159 + val get_user_statistics_admin : id:string -> ?is_favorite:string -> ?is_trashed:string -> ?visibility:string -> t -> unit -> Types.AssetStatsResponseDto.t 160 + 161 + (** List all albums 162 + 163 + Retrieve a list of albums available to the authenticated user. *) 164 + val get_all_albums : ?asset_id:string -> ?shared:string -> t -> unit -> Types.AlbumResponseDto.t list 165 + 166 + (** Create an album 167 + 168 + Create a new album. The album can also be created with initial users and assets. *) 169 + val create_album : body:Types.CreateAlbumDto.t -> t -> unit -> Types.AlbumResponseDto.t 170 + 171 + (** Add assets to albums 172 + 173 + Send a list of asset IDs and album IDs to add each asset to each album. *) 174 + val add_assets_to_albums : ?key:string -> ?slug:string -> body:Types.AlbumsAddAssetsDto.t -> t -> unit -> Types.AlbumsAddAssetsResponseDto.t 175 + 176 + (** Retrieve album statistics 177 + 178 + Returns statistics about the albums available to the authenticated user. *) 179 + val get_album_statistics : t -> unit -> Types.AlbumStatisticsResponseDto.t 180 + 181 + (** Retrieve an album 182 + 183 + Retrieve information about a specific album by its ID. *) 184 + val get_album_info : id:string -> ?key:string -> ?slug:string -> ?without_assets:string -> t -> unit -> Types.AlbumResponseDto.t 185 + 186 + (** Delete an album 187 + 188 + Delete a specific album by its ID. Note the album is initially trashed and then immediately scheduled for deletion, but relies on a background job to complete the process. *) 189 + val delete_album : id:string -> t -> unit -> Jsont.json 190 + 191 + (** Update an album 192 + 193 + Update the information of a specific album by its ID. This endpoint can be used to update the album name, description, sort order, etc. However, it is not used to add or remove assets or users from the album. *) 194 + val update_album_info : id:string -> body:Types.UpdateAlbumDto.t -> t -> unit -> Types.AlbumResponseDto.t 195 + 196 + (** Add assets to an album 197 + 198 + Add multiple assets to a specific album by its ID. *) 199 + val add_assets_to_album : id:string -> ?key:string -> ?slug:string -> body:Types.BulkIdsDto.t -> t -> unit -> Types.BulkIdResponseDto.t list 200 + 201 + (** Remove assets from an album 202 + 203 + Remove multiple assets from a specific album by its ID. *) 204 + val remove_asset_from_album : id:string -> t -> unit -> Types.BulkIdResponseDto.t list 205 + 206 + (** Update user role 207 + 208 + Change the role for a specific user in a specific album. *) 209 + val update_album_user : id:string -> user_id:string -> body:Types.UpdateAlbumUserDto.t -> t -> unit -> Jsont.json 210 + 211 + (** Remove user from album 212 + 213 + Remove a user from an album. Use an ID of "me" to leave a shared album. *) 214 + val remove_user_from_album : id:string -> user_id:string -> t -> unit -> Jsont.json 215 + 216 + (** Share album with users 217 + 218 + Share an album with multiple users. Each user can be given a specific role in the album. *) 219 + val add_users_to_album : id:string -> body:Types.AddUsersDto.t -> t -> unit -> Types.AlbumResponseDto.t 220 + 221 + (** List all API keys 222 + 223 + Retrieve all API keys of the current user. *) 224 + val get_api_keys : t -> unit -> Types.ApikeyResponseDto.t list 225 + 226 + (** Create an API key 227 + 228 + Creates a new API key. It will be limited to the permissions specified. *) 229 + val create_api_key : body:Types.ApikeyCreateDto.t -> t -> unit -> Types.ApikeyCreateResponseDto.t 230 + 231 + (** Retrieve the current API key 232 + 233 + Retrieve the API key that is used to access this endpoint. *) 234 + val get_my_api_key : t -> unit -> Types.ApikeyResponseDto.t 235 + 236 + (** Retrieve an API key 237 + 238 + Retrieve an API key by its ID. The current user must own this API key. *) 239 + val get_api_key : id:string -> t -> unit -> Types.ApikeyResponseDto.t 240 + 241 + (** Update an API key 242 + 243 + Updates the name and permissions of an API key by its ID. The current user must own this API key. *) 244 + val update_api_key : id:string -> body:Types.ApikeyUpdateDto.t -> t -> unit -> Types.ApikeyResponseDto.t 245 + 246 + (** Delete an API key 247 + 248 + Deletes an API key identified by its ID. The current user must own this API key. *) 249 + val delete_api_key : id:string -> t -> unit -> Jsont.json 250 + 251 + (** Upload asset 252 + 253 + Uploads a new asset to the server. *) 254 + val upload_asset : ?key:string -> ?slug:string -> body:Jsont.json -> t -> unit -> Types.AssetMediaResponseDto.t 255 + 256 + (** Update assets 257 + 258 + Updates multiple assets at the same time. *) 259 + val update_assets : body:Types.AssetBulkUpdateDto.t -> t -> unit -> Jsont.json 260 + 261 + (** Delete assets 262 + 263 + Deletes multiple assets at the same time. *) 264 + val delete_assets : t -> unit -> Jsont.json 265 + 266 + (** Check bulk upload 267 + 268 + Determine which assets have already been uploaded to the server based on their SHA1 checksums. *) 269 + val check_bulk_upload : body:Types.AssetBulkUploadCheckDto.t -> t -> unit -> Types.AssetBulkUploadCheckResponseDto.t 270 + 271 + (** Copy asset 272 + 273 + Copy asset information like albums, tags, etc. from one asset to another. *) 274 + val copy_asset : body:Types.AssetCopyDto.t -> t -> unit -> Jsont.json 275 + 276 + (** Retrieve assets by device ID 277 + 278 + Get all asset of a device that are in the database, ID only. *) 279 + val get_all_user_assets_by_device_id : device_id:string -> t -> unit -> Jsont.json 280 + 281 + (** Check existing assets 282 + 283 + Checks if multiple assets exist on the server and returns all existing - used by background backup *) 284 + val check_existing_assets : body:Types.CheckExistingAssetsDto.t -> t -> unit -> Types.CheckExistingAssetsResponseDto.t 285 + 286 + (** Run an asset job 287 + 288 + Run a specific job on a set of assets. *) 289 + val run_asset_jobs : body:Types.AssetJobsDto.t -> t -> unit -> Jsont.json 290 + 291 + (** Upsert asset metadata 292 + 293 + Upsert metadata key-value pairs for multiple assets. *) 294 + val update_bulk_asset_metadata : body:Types.AssetMetadataBulkUpsertDto.t -> t -> unit -> Types.AssetMetadataBulkResponseDto.t list 295 + 296 + (** Delete asset metadata 297 + 298 + Delete metadata key-value pairs for multiple assets. *) 299 + val delete_bulk_asset_metadata : t -> unit -> Jsont.json 300 + 301 + (** Get random assets 302 + 303 + Retrieve a specified number of random assets for the authenticated user. *) 304 + val get_random : ?count:string -> t -> unit -> Types.AssetResponseDto.t list 305 + 306 + (** Get asset statistics 307 + 308 + Retrieve various statistics about the assets owned by the authenticated user. *) 309 + val get_asset_statistics : ?is_favorite:string -> ?is_trashed:string -> ?visibility:string -> t -> unit -> Types.AssetStatsResponseDto.t 310 + 311 + (** Retrieve an asset 312 + 313 + Retrieve detailed information about a specific asset. *) 314 + val get_asset_info : id:string -> ?key:string -> ?slug:string -> t -> unit -> Types.AssetResponseDto.t 315 + 316 + (** Update an asset 317 + 318 + Update information of a specific asset. *) 319 + val update_asset : id:string -> body:Types.UpdateAssetDto.t -> t -> unit -> Types.AssetResponseDto.t 320 + 321 + (** Retrieve edits for an existing asset 322 + 323 + Retrieve a series of edit actions (crop, rotate, mirror) associated with the specified asset. *) 324 + val get_asset_edits : id:string -> t -> unit -> Types.AssetEditsDto.t 325 + 326 + (** Apply edits to an existing asset 327 + 328 + Apply a series of edit actions (crop, rotate, mirror) to the specified asset. *) 329 + val edit_asset : id:string -> body:Types.AssetEditActionListDto.t -> t -> unit -> Types.AssetEditsDto.t 330 + 331 + (** Remove edits from an existing asset 332 + 333 + Removes all edit actions (crop, rotate, mirror) associated with the specified asset. *) 334 + val remove_asset_edits : id:string -> t -> unit -> Jsont.json 335 + 336 + (** Get asset metadata 337 + 338 + Retrieve all metadata key-value pairs associated with the specified asset. *) 339 + val get_asset_metadata : id:string -> t -> unit -> Types.AssetMetadataResponseDto.t list 340 + 341 + (** Update asset metadata 342 + 343 + Update or add metadata key-value pairs for the specified asset. *) 344 + val update_asset_metadata : id:string -> body:Types.AssetMetadataUpsertDto.t -> t -> unit -> Types.AssetMetadataResponseDto.t list 345 + 346 + (** Retrieve asset metadata by key 347 + 348 + Retrieve the value of a specific metadata key associated with the specified asset. *) 349 + val get_asset_metadata_by_key : id:string -> key:string -> t -> unit -> Types.AssetMetadataResponseDto.t 350 + 351 + (** Delete asset metadata by key 352 + 353 + Delete a specific metadata key-value pair associated with the specified asset. *) 354 + val delete_asset_metadata : id:string -> key:string -> t -> unit -> Jsont.json 355 + 356 + (** Retrieve asset OCR data 357 + 358 + Retrieve all OCR (Optical Character Recognition) data associated with the specified asset. *) 359 + val get_asset_ocr : id:string -> t -> unit -> Types.AssetOcrResponseDto.t list 360 + 361 + (** Download original asset 362 + 363 + Downloads the original file of the specified asset. *) 364 + val download_asset : id:string -> ?edited:string -> ?key:string -> ?slug:string -> t -> unit -> Jsont.json 365 + 366 + (** Replace asset 367 + 368 + Replace the asset with new file, without changing its id. *) 369 + val replace_asset : id:string -> ?key:string -> ?slug:string -> body:Jsont.json -> t -> unit -> Types.AssetMediaResponseDto.t 370 + 371 + (** View asset thumbnail 372 + 373 + Retrieve the thumbnail image for the specified asset. Viewing the fullsize thumbnail might redirect to downloadAsset, which requires a different permission. *) 374 + val view_asset : id:string -> ?edited:string -> ?key:string -> ?size:string -> ?slug:string -> t -> unit -> Jsont.json 375 + 376 + (** Play asset video 377 + 378 + Streams the video file for the specified asset. This endpoint also supports byte range requests. *) 379 + val play_asset_video : id:string -> ?key:string -> ?slug:string -> t -> unit -> Jsont.json 380 + 381 + (** Register admin 382 + 383 + Create the first admin user in the system. *) 384 + val sign_up_admin : body:Types.SignUpDto.t -> t -> unit -> Types.UserAdminResponseDto.t 385 + 386 + (** Change password 387 + 388 + Change the password of the current user. *) 389 + val change_password : body:Types.ChangePasswordDto.t -> t -> unit -> Types.UserAdminResponseDto.t 390 + 391 + (** Login 392 + 393 + Login with username and password and receive a session token. *) 394 + val login : body:Types.LoginCredentialDto.t -> t -> unit -> Types.LoginResponseDto.t 395 + 396 + (** Logout 397 + 398 + Logout the current user and invalidate the session token. *) 399 + val logout : t -> unit -> Types.LogoutResponseDto.t 400 + 401 + (** Setup pin code 402 + 403 + Setup a new pin code for the current user. *) 404 + val setup_pin_code : body:Types.PinCodeSetupDto.t -> t -> unit -> Jsont.json 405 + 406 + (** Change pin code 407 + 408 + Change the pin code for the current user. *) 409 + val change_pin_code : body:Types.PinCodeChangeDto.t -> t -> unit -> Jsont.json 410 + 411 + (** Reset pin code 412 + 413 + Reset the pin code for the current user by providing the account password *) 414 + val reset_pin_code : t -> unit -> Jsont.json 415 + 416 + (** Lock auth session 417 + 418 + Remove elevated access to locked assets from the current session. *) 419 + val lock_auth_session : t -> unit -> Jsont.json 420 + 421 + (** Unlock auth session 422 + 423 + Temporarily grant the session elevated access to locked assets by providing the correct PIN code. *) 424 + val unlock_auth_session : body:Types.SessionUnlockDto.t -> t -> unit -> Jsont.json 425 + 426 + (** Retrieve auth status 427 + 428 + Get information about the current session, including whether the user has a password, and if the session can access locked assets. *) 429 + val get_auth_status : t -> unit -> Types.AuthStatusResponseDto.t 430 + 431 + (** Validate access token 432 + 433 + Validate the current authorization method is still valid. *) 434 + val validate_access_token : t -> unit -> Types.ValidateAccessTokenResponseDto.t 435 + 436 + (** Download asset archive 437 + 438 + Download a ZIP archive containing the specified assets. The assets must have been previously requested via the "getDownloadInfo" endpoint. *) 439 + val download_archive : ?key:string -> ?slug:string -> body:Types.AssetIdsDto.t -> t -> unit -> Jsont.json 440 + 441 + (** Retrieve download information 442 + 443 + Retrieve information about how to request a download for the specified assets or album. The response includes groups of assets that can be downloaded together. *) 444 + val get_download_info : ?key:string -> ?slug:string -> body:Types.DownloadInfoDto.t -> t -> unit -> Types.DownloadResponseDto.t 445 + 446 + (** Retrieve duplicates 447 + 448 + Retrieve a list of duplicate assets available to the authenticated user. *) 449 + val get_asset_duplicates : t -> unit -> Types.DuplicateResponseDto.t list 450 + 451 + (** Delete duplicates 452 + 453 + Delete multiple duplicate assets specified by their IDs. *) 454 + val delete_duplicates : t -> unit -> Jsont.json 455 + 456 + (** Delete a duplicate 457 + 458 + Delete a single duplicate asset specified by its ID. *) 459 + val delete_duplicate : id:string -> t -> unit -> Jsont.json 460 + 461 + (** Retrieve faces for asset 462 + 463 + Retrieve all faces belonging to an asset. *) 464 + val get_faces : id:string -> t -> unit -> Types.AssetFaceResponseDto.t list 465 + 466 + (** Create a face 467 + 468 + Create a new face that has not been discovered by facial recognition. The content of the bounding box is considered a face. *) 469 + val create_face : body:Types.AssetFaceCreateDto.t -> t -> unit -> Jsont.json 470 + 471 + (** Re-assign a face to another person 472 + 473 + Re-assign the face provided in the body to the person identified by the id in the path parameter. *) 474 + val reassign_faces_by_id : id:string -> body:Types.FaceDto.t -> t -> unit -> Types.PersonResponseDto.t 475 + 476 + (** Delete a face 477 + 478 + Delete a face identified by the id. Optionally can be force deleted. *) 479 + val delete_face : id:string -> t -> unit -> Jsont.json 480 + 481 + (** Retrieve queue counts and status 482 + 483 + Retrieve the counts of the current queue, as well as the current status. *) 484 + val get_queues_legacy : t -> unit -> Types.QueuesResponseLegacyDto.t 485 + 486 + (** Create a manual job 487 + 488 + Run a specific job. Most jobs are queued automatically, but this endpoint allows for manual creation of a handful of jobs, including various cleanup tasks, as well as creating a new database backup. *) 489 + val create_job : body:Types.JobCreateDto.t -> t -> unit -> Jsont.json 490 + 491 + (** Run jobs 492 + 493 + Queue all assets for a specific job type. Defaults to only queueing assets that have not yet been processed, but the force command can be used to re-process all assets. *) 494 + val run_queue_command_legacy : name:string -> body:Types.QueueCommandDto.t -> t -> unit -> Types.QueueResponseLegacyDto.t 495 + 496 + (** Retrieve libraries 497 + 498 + Retrieve a list of external libraries. *) 499 + val get_all_libraries : t -> unit -> Types.LibraryResponseDto.t list 500 + 501 + (** Create a library 502 + 503 + Create a new external library. *) 504 + val create_library : body:Types.CreateLibraryDto.t -> t -> unit -> Types.LibraryResponseDto.t 505 + 506 + (** Retrieve a library 507 + 508 + Retrieve an external library by its ID. *) 509 + val get_library : id:string -> t -> unit -> Types.LibraryResponseDto.t 510 + 511 + (** Update a library 512 + 513 + Update an existing external library. *) 514 + val update_library : id:string -> body:Types.UpdateLibraryDto.t -> t -> unit -> Types.LibraryResponseDto.t 515 + 516 + (** Delete a library 517 + 518 + Delete an external library by its ID. *) 519 + val delete_library : id:string -> t -> unit -> Jsont.json 520 + 521 + (** Scan a library 522 + 523 + Queue a scan for the external library to find and import new assets. *) 524 + val scan_library : id:string -> t -> unit -> Jsont.json 525 + 526 + (** Retrieve library statistics 527 + 528 + Retrieve statistics for a specific external library, including number of videos, images, and storage usage. *) 529 + val get_library_statistics : id:string -> t -> unit -> Types.LibraryStatsResponseDto.t 530 + 531 + (** Validate library settings 532 + 533 + Validate the settings of an external library. *) 534 + val validate : id:string -> body:Types.ValidateLibraryDto.t -> t -> unit -> Types.ValidateLibraryResponseDto.t 535 + 536 + (** Retrieve map markers 537 + 538 + Retrieve a list of latitude and longitude coordinates for every asset with location data. *) 539 + val get_map_markers : ?file_created_after:string -> ?file_created_before:string -> ?is_archived:string -> ?is_favorite:string -> ?with_partners:string -> ?with_shared_albums:string -> t -> unit -> Types.MapMarkerResponseDto.t list 540 + 541 + (** Reverse geocode coordinates 542 + 543 + Retrieve location information (e.g., city, country) for given latitude and longitude coordinates. *) 544 + val reverse_geocode : lat:string -> lon:string -> t -> unit -> Types.MapReverseGeocodeResponseDto.t list 545 + 546 + (** Retrieve memories 547 + 548 + Retrieve a list of memories. Memories are sorted descending by creation date by default, although they can also be sorted in ascending order, or randomly. *) 549 + val search_memories : ?for_:string -> ?is_saved:string -> ?is_trashed:string -> ?order:string -> ?size:string -> ?type_:string -> t -> unit -> Types.MemoryResponseDto.t list 550 + 551 + (** Create a memory 552 + 553 + Create a new memory by providing a name, description, and a list of asset IDs to include in the memory. *) 554 + val create_memory : body:Types.MemoryCreateDto.t -> t -> unit -> Types.MemoryResponseDto.t 555 + 556 + (** Retrieve memories statistics 557 + 558 + Retrieve statistics about memories, such as total count and other relevant metrics. *) 559 + val memories_statistics : ?for_:string -> ?is_saved:string -> ?is_trashed:string -> ?order:string -> ?size:string -> ?type_:string -> t -> unit -> Types.MemoryStatisticsResponseDto.t 560 + 561 + (** Retrieve a memory 562 + 563 + Retrieve a specific memory by its ID. *) 564 + val get_memory : id:string -> t -> unit -> Types.MemoryResponseDto.t 565 + 566 + (** Update a memory 567 + 568 + Update an existing memory by its ID. *) 569 + val update_memory : id:string -> body:Types.MemoryUpdateDto.t -> t -> unit -> Types.MemoryResponseDto.t 570 + 571 + (** Delete a memory 572 + 573 + Delete a specific memory by its ID. *) 574 + val delete_memory : id:string -> t -> unit -> Jsont.json 575 + 576 + (** Add assets to a memory 577 + 578 + Add a list of asset IDs to a specific memory. *) 579 + val add_memory_assets : id:string -> body:Types.BulkIdsDto.t -> t -> unit -> Types.BulkIdResponseDto.t list 580 + 581 + (** Remove assets from a memory 582 + 583 + Remove a list of asset IDs from a specific memory. *) 584 + val remove_memory_assets : id:string -> t -> unit -> Types.BulkIdResponseDto.t list 585 + 586 + (** Retrieve notifications 587 + 588 + Retrieve a list of notifications. *) 589 + val get_notifications : ?id:string -> ?level:string -> ?type_:string -> ?unread:string -> t -> unit -> Types.NotificationDto.t list 590 + 591 + (** Update notifications 592 + 593 + Update a list of notifications. Allows to bulk-set the read status of notifications. *) 594 + val update_notifications : body:Types.NotificationUpdateAllDto.t -> t -> unit -> Jsont.json 595 + 596 + (** Delete notifications 597 + 598 + Delete a list of notifications at once. *) 599 + val delete_notifications : t -> unit -> Jsont.json 600 + 601 + (** Get a notification 602 + 603 + Retrieve a specific notification identified by id. *) 604 + val get_notification : id:string -> t -> unit -> Types.NotificationDto.t 605 + 606 + (** Update a notification 607 + 608 + Update a specific notification to set its read status. *) 609 + val update_notification : id:string -> body:Types.NotificationUpdateDto.t -> t -> unit -> Types.NotificationDto.t 610 + 611 + (** Delete a notification 612 + 613 + Delete a specific notification. *) 614 + val delete_notification : id:string -> t -> unit -> Jsont.json 615 + 616 + (** Start OAuth 617 + 618 + Initiate the OAuth authorization process. *) 619 + val start_oauth : body:Types.OauthConfigDto.t -> t -> unit -> Types.OauthAuthorizeResponseDto.t 620 + 621 + (** Finish OAuth 622 + 623 + Complete the OAuth authorization process by exchanging the authorization code for a session token. *) 624 + val finish_oauth : body:Types.OauthCallbackDto.t -> t -> unit -> Types.LoginResponseDto.t 625 + 626 + (** Link OAuth account 627 + 628 + Link an OAuth account to the authenticated user. *) 629 + val link_oauth_account : body:Types.OauthCallbackDto.t -> t -> unit -> Types.UserAdminResponseDto.t 630 + 631 + (** Redirect OAuth to mobile 632 + 633 + Requests to this URL are automatically forwarded to the mobile app, and is used in some cases for OAuth redirecting. *) 634 + val redirect_oauth_to_mobile : t -> unit -> Jsont.json 635 + 636 + (** Unlink OAuth account 637 + 638 + Unlink the OAuth account from the authenticated user. *) 639 + val unlink_oauth_account : t -> unit -> Types.UserAdminResponseDto.t 640 + 641 + (** Retrieve partners 642 + 643 + Retrieve a list of partners with whom assets are shared. *) 644 + val get_partners : direction:string -> t -> unit -> Types.PartnerResponseDto.t list 645 + 646 + (** Create a partner 647 + 648 + Create a new partner to share assets with. *) 649 + val create_partner : body:Types.PartnerCreateDto.t -> t -> unit -> Types.PartnerResponseDto.t 650 + 651 + (** Create a partner 652 + 653 + Create a new partner to share assets with. *) 654 + val create_partner_deprecated : id:string -> t -> unit -> Types.PartnerResponseDto.t 655 + 656 + (** Update a partner 657 + 658 + Specify whether a partner's assets should appear in the user's timeline. *) 659 + val update_partner : id:string -> body:Types.PartnerUpdateDto.t -> t -> unit -> Types.PartnerResponseDto.t 660 + 661 + (** Remove a partner 662 + 663 + Stop sharing assets with a partner. *) 664 + val remove_partner : id:string -> t -> unit -> Jsont.json 665 + 666 + (** Get all people 667 + 668 + Retrieve a list of all people. *) 669 + val get_all_people : ?closest_asset_id:string -> ?closest_person_id:string -> ?page:string -> ?size:string -> ?with_hidden:string -> t -> unit -> Types.PeopleResponseDto.t 670 + 671 + (** Create a person 672 + 673 + Create a new person that can have multiple faces assigned to them. *) 674 + val create_person : body:Types.PersonCreateDto.t -> t -> unit -> Types.PersonResponseDto.t 675 + 676 + (** Update people 677 + 678 + Bulk update multiple people at once. *) 679 + val update_people : body:Types.PeopleUpdateDto.t -> t -> unit -> Types.BulkIdResponseDto.t list 680 + 681 + (** Delete people 682 + 683 + Bulk delete a list of people at once. *) 684 + val delete_people : t -> unit -> Jsont.json 685 + 686 + (** Get a person 687 + 688 + Retrieve a person by id. *) 689 + val get_person : id:string -> t -> unit -> Types.PersonResponseDto.t 690 + 691 + (** Update person 692 + 693 + Update an individual person. *) 694 + val update_person : id:string -> body:Types.PersonUpdateDto.t -> t -> unit -> Types.PersonResponseDto.t 695 + 696 + (** Delete person 697 + 698 + Delete an individual person. *) 699 + val delete_person : id:string -> t -> unit -> Jsont.json 700 + 701 + (** Merge people 702 + 703 + Merge a list of people into the person specified in the path parameter. *) 704 + val merge_person : id:string -> body:Types.MergePersonDto.t -> t -> unit -> Types.BulkIdResponseDto.t list 705 + 706 + (** Reassign faces 707 + 708 + Bulk reassign a list of faces to a different person. *) 709 + val reassign_faces : id:string -> body:Types.AssetFaceUpdateDto.t -> t -> unit -> Types.PersonResponseDto.t list 710 + 711 + (** Get person statistics 712 + 713 + Retrieve statistics about a specific person. *) 714 + val get_person_statistics : id:string -> t -> unit -> Types.PersonStatisticsResponseDto.t 715 + 716 + (** Get person thumbnail 717 + 718 + Retrieve the thumbnail file for a person. *) 719 + val get_person_thumbnail : id:string -> t -> unit -> Jsont.json 720 + 721 + (** List all plugins 722 + 723 + Retrieve a list of plugins available to the authenticated user. *) 724 + val get_plugins : t -> unit -> Types.PluginResponseDto.t list 725 + 726 + (** List all plugin triggers 727 + 728 + Retrieve a list of all available plugin triggers. *) 729 + val get_plugin_triggers : t -> unit -> Types.PluginTriggerResponseDto.t list 730 + 731 + (** Retrieve a plugin 732 + 733 + Retrieve information about a specific plugin by its ID. *) 734 + val get_plugin : id:string -> t -> unit -> Types.PluginResponseDto.t 735 + 736 + (** List all queues 737 + 738 + Retrieves a list of queues. *) 739 + val get_queues : t -> unit -> Types.QueueResponseDto.t list 740 + 741 + (** Retrieve a queue 742 + 743 + Retrieves a specific queue by its name. *) 744 + val get_queue : name:string -> t -> unit -> Types.QueueResponseDto.t 745 + 746 + (** Update a queue 747 + 748 + Change the paused status of a specific queue. *) 749 + val update_queue : name:string -> body:Types.QueueUpdateDto.t -> t -> unit -> Types.QueueResponseDto.t 750 + 751 + (** Retrieve queue jobs 752 + 753 + Retrieves a list of queue jobs from the specified queue. *) 754 + val get_queue_jobs : name:string -> ?status:string -> t -> unit -> Types.QueueJobResponseDto.t list 755 + 756 + (** Empty a queue 757 + 758 + Removes all jobs from the specified queue. *) 759 + val empty_queue : name:string -> t -> unit -> Jsont.json 760 + 761 + (** Retrieve assets by city 762 + 763 + Retrieve a list of assets with each asset belonging to a different city. This endpoint is used on the places pages to show a single thumbnail for each city the user has assets in. *) 764 + val get_assets_by_city : t -> unit -> Types.AssetResponseDto.t list 765 + 766 + (** Retrieve explore data 767 + 768 + Retrieve data for the explore section, such as popular people and places. *) 769 + val get_explore_data : t -> unit -> Types.SearchExploreResponseDto.t list 770 + 771 + (** Search large assets 772 + 773 + Search for assets that are considered large based on specified criteria. *) 774 + val search_large_assets : ?album_ids:string -> ?city:string -> ?country:string -> ?created_after:string -> ?created_before:string -> ?device_id:string -> ?is_encoded:string -> ?is_favorite:string -> ?is_motion:string -> ?is_not_in_album:string -> ?is_offline:string -> ?lens_model:string -> ?library_id:string -> ?make:string -> ?min_file_size:string -> ?model:string -> ?ocr:string -> ?person_ids:string -> ?rating:string -> ?size:string -> ?state:string -> ?tag_ids:string -> ?taken_after:string -> ?taken_before:string -> ?trashed_after:string -> ?trashed_before:string -> ?type_:string -> ?updated_after:string -> ?updated_before:string -> ?visibility:string -> ?with_deleted:string -> ?with_exif:string -> t -> unit -> Types.AssetResponseDto.t list 775 + 776 + (** Search assets by metadata 777 + 778 + Search for assets based on various metadata criteria. *) 779 + val search_assets : body:Types.MetadataSearchDto.t -> t -> unit -> Types.SearchResponseDto.t 780 + 781 + (** Search people 782 + 783 + Search for people by name. *) 784 + val search_person : name:string -> ?with_hidden:string -> t -> unit -> Types.PersonResponseDto.t list 785 + 786 + (** Search places 787 + 788 + Search for places by name. *) 789 + val search_places : name:string -> t -> unit -> Types.PlacesResponseDto.t list 790 + 791 + (** Search random assets 792 + 793 + Retrieve a random selection of assets based on the provided criteria. *) 794 + val search_random : body:Types.RandomSearchDto.t -> t -> unit -> Types.AssetResponseDto.t list 795 + 796 + (** Smart asset search 797 + 798 + Perform a smart search for assets by using machine learning vectors to determine relevance. *) 799 + val search_smart : body:Types.SmartSearchDto.t -> t -> unit -> Types.SearchResponseDto.t 800 + 801 + (** Search asset statistics 802 + 803 + Retrieve statistical data about assets based on search criteria, such as the total matching count. *) 804 + val search_asset_statistics : body:Types.StatisticsSearchDto.t -> t -> unit -> Types.SearchStatisticsResponseDto.t 805 + 806 + (** Retrieve search suggestions 807 + 808 + Retrieve search suggestions based on partial input. This endpoint is used for typeahead search features. *) 809 + val get_search_suggestions : ?country:string -> ?include_null:string -> ?lens_model:string -> ?make:string -> ?model:string -> ?state:string -> type_:string -> t -> unit -> Jsont.json 810 + 811 + (** Get server information 812 + 813 + Retrieve a list of information about the server. *) 814 + val get_about_info : t -> unit -> Types.ServerAboutResponseDto.t 815 + 816 + (** Get APK links 817 + 818 + Retrieve links to the APKs for the current server version. *) 819 + val get_apk_links : t -> unit -> Types.ServerApkLinksDto.t 820 + 821 + (** Get config 822 + 823 + Retrieve the current server configuration. *) 824 + val get_server_config : t -> unit -> Types.ServerConfigDto.t 825 + 826 + (** Get features 827 + 828 + Retrieve available features supported by this server. *) 829 + val get_server_features : t -> unit -> Types.ServerFeaturesDto.t 830 + 831 + (** Get product key 832 + 833 + Retrieve information about whether the server currently has a product key registered. *) 834 + val get_server_license : t -> unit -> Types.LicenseResponseDto.t 835 + 836 + (** Set server product key 837 + 838 + Validate and set the server product key if successful. *) 839 + val set_server_license : body:Types.LicenseKeyDto.t -> t -> unit -> Types.LicenseResponseDto.t 840 + 841 + (** Delete server product key 842 + 843 + Delete the currently set server product key. *) 844 + val delete_server_license : t -> unit -> Jsont.json 845 + 846 + (** Get supported media types 847 + 848 + Retrieve all media types supported by the server. *) 849 + val get_supported_media_types : t -> unit -> Types.ServerMediaTypesResponseDto.t 850 + 851 + (** Ping 852 + 853 + Pong *) 854 + val ping_server : t -> unit -> Types.ServerPingResponse.t 855 + 856 + (** Get statistics 857 + 858 + Retrieve statistics about the entire Immich instance such as asset counts. *) 859 + val get_server_statistics : t -> unit -> Types.ServerStatsResponseDto.t 860 + 861 + (** Get storage 862 + 863 + Retrieve the current storage utilization information of the server. *) 864 + val get_storage : t -> unit -> Types.ServerStorageResponseDto.t 865 + 866 + (** Get theme 867 + 868 + Retrieve the custom CSS, if existent. *) 869 + val get_theme : t -> unit -> Types.ServerThemeDto.t 870 + 871 + (** Get server version 872 + 873 + Retrieve the current server version in semantic versioning (semver) format. *) 874 + val get_server_version : t -> unit -> Types.ServerVersionResponseDto.t 875 + 876 + (** Get version check status 877 + 878 + Retrieve information about the last time the version check ran. *) 879 + val get_version_check : t -> unit -> Types.VersionCheckStateResponseDto.t 880 + 881 + (** Get version history 882 + 883 + Retrieve a list of past versions the server has been on. *) 884 + val get_version_history : t -> unit -> Types.ServerVersionHistoryResponseDto.t list 885 + 886 + (** Retrieve sessions 887 + 888 + Retrieve a list of sessions for the user. *) 889 + val get_sessions : t -> unit -> Types.SessionResponseDto.t list 890 + 891 + (** Create a session 892 + 893 + Create a session as a child to the current session. This endpoint is used for casting. *) 894 + val create_session : body:Types.SessionCreateDto.t -> t -> unit -> Types.SessionCreateResponseDto.t 895 + 896 + (** Delete all sessions 897 + 898 + Delete all sessions for the user. This will not delete the current session. *) 899 + val delete_all_sessions : t -> unit -> Jsont.json 900 + 901 + (** Update a session 902 + 903 + Update a specific session identified by id. *) 904 + val update_session : id:string -> body:Types.SessionUpdateDto.t -> t -> unit -> Types.SessionResponseDto.t 905 + 906 + (** Delete a session 907 + 908 + Delete a specific session by id. *) 909 + val delete_session : id:string -> t -> unit -> Jsont.json 910 + 911 + (** Lock a session 912 + 913 + Lock a specific session by id. *) 914 + val lock_session : id:string -> t -> unit -> Jsont.json 915 + 916 + (** Retrieve all shared links 917 + 918 + Retrieve a list of all shared links. *) 919 + val get_all_shared_links : ?album_id:string -> ?id:string -> t -> unit -> Types.SharedLinkResponseDto.t list 920 + 921 + (** Create a shared link 922 + 923 + Create a new shared link. *) 924 + val create_shared_link : body:Types.SharedLinkCreateDto.t -> t -> unit -> Types.SharedLinkResponseDto.t 925 + 926 + (** Retrieve current shared link 927 + 928 + Retrieve the current shared link associated with authentication method. *) 929 + val get_my_shared_link : ?key:string -> ?password:string -> ?slug:string -> ?token:string -> t -> unit -> Types.SharedLinkResponseDto.t 930 + 931 + (** Retrieve a shared link 932 + 933 + Retrieve a specific shared link by its ID. *) 934 + val get_shared_link_by_id : id:string -> t -> unit -> Types.SharedLinkResponseDto.t 935 + 936 + (** Delete a shared link 937 + 938 + Delete a specific shared link by its ID. *) 939 + val remove_shared_link : id:string -> t -> unit -> Jsont.json 940 + 941 + (** Update a shared link 942 + 943 + Update an existing shared link by its ID. *) 944 + val update_shared_link : id:string -> body:Types.SharedLinkEditDto.t -> t -> unit -> Types.SharedLinkResponseDto.t 945 + 946 + (** Add assets to a shared link 947 + 948 + Add assets to a specific shared link by its ID. This endpoint is only relevant for shared link of type individual. *) 949 + val add_shared_link_assets : id:string -> ?key:string -> ?slug:string -> body:Types.AssetIdsDto.t -> t -> unit -> Types.AssetIdsResponseDto.t list 950 + 951 + (** Remove assets from a shared link 952 + 953 + Remove assets from a specific shared link by its ID. This endpoint is only relevant for shared link of type individual. *) 954 + val remove_shared_link_assets : id:string -> ?key:string -> ?slug:string -> t -> unit -> Types.AssetIdsResponseDto.t list 955 + 956 + (** Retrieve stacks 957 + 958 + Retrieve a list of stacks. *) 959 + val search_stacks : ?primary_asset_id:string -> t -> unit -> Types.StackResponseDto.t list 960 + 961 + (** Create a stack 962 + 963 + Create a new stack by providing a name and a list of asset IDs to include in the stack. If any of the provided asset IDs are primary assets of an existing stack, the existing stack will be merged into the newly created stack. *) 964 + val create_stack : body:Types.StackCreateDto.t -> t -> unit -> Types.StackResponseDto.t 965 + 966 + (** Delete stacks 967 + 968 + Delete multiple stacks by providing a list of stack IDs. *) 969 + val delete_stacks : t -> unit -> Jsont.json 970 + 971 + (** Retrieve a stack 972 + 973 + Retrieve a specific stack by its ID. *) 974 + val get_stack : id:string -> t -> unit -> Types.StackResponseDto.t 975 + 976 + (** Update a stack 977 + 978 + Update an existing stack by its ID. *) 979 + val update_stack : id:string -> body:Types.StackUpdateDto.t -> t -> unit -> Types.StackResponseDto.t 980 + 981 + (** Delete a stack 982 + 983 + Delete a specific stack by its ID. *) 984 + val delete_stack : id:string -> t -> unit -> Jsont.json 985 + 986 + (** Remove an asset from a stack 987 + 988 + Remove a specific asset from a stack by providing the stack ID and asset ID. *) 989 + val remove_asset_from_stack : asset_id:string -> id:string -> t -> unit -> Jsont.json 990 + 991 + (** Retrieve acknowledgements 992 + 993 + Retrieve the synchronization acknowledgments for the current session. *) 994 + val get_sync_ack : t -> unit -> Types.SyncAckDto.t list 995 + 996 + (** Acknowledge changes 997 + 998 + Send a list of synchronization acknowledgements to confirm that the latest changes have been received. *) 999 + val send_sync_ack : body:Types.SyncAckSetDto.t -> t -> unit -> Jsont.json 1000 + 1001 + (** Delete acknowledgements 1002 + 1003 + Delete specific synchronization acknowledgments. *) 1004 + val delete_sync_ack : t -> unit -> Jsont.json 1005 + 1006 + (** Get delta sync for user 1007 + 1008 + Retrieve changed assets since the last sync for the authenticated user. *) 1009 + val get_delta_sync : body:Types.AssetDeltaSyncDto.t -> t -> unit -> Types.AssetDeltaSyncResponseDto.t 1010 + 1011 + (** Get full sync for user 1012 + 1013 + Retrieve all assets for a full synchronization for the authenticated user. *) 1014 + val get_full_sync_for_user : body:Types.AssetFullSyncDto.t -> t -> unit -> Types.AssetResponseDto.t list 1015 + 1016 + (** Stream sync changes 1017 + 1018 + Retrieve a JSON lines streamed response of changes for synchronization. This endpoint is used by the mobile app to efficiently stay up to date with changes. *) 1019 + val get_sync_stream : body:Types.SyncStreamDto.t -> t -> unit -> Jsont.json 1020 + 1021 + (** Get system configuration 1022 + 1023 + Retrieve the current system configuration. *) 1024 + val get_config : t -> unit -> Types.SystemConfigDto.t 1025 + 1026 + (** Update system configuration 1027 + 1028 + Update the system configuration with a new system configuration. *) 1029 + val update_config : body:Types.SystemConfigDto.t -> t -> unit -> Types.SystemConfigDto.t 1030 + 1031 + (** Get system configuration defaults 1032 + 1033 + Retrieve the default values for the system configuration. *) 1034 + val get_config_defaults : t -> unit -> Types.SystemConfigDto.t 1035 + 1036 + (** Get storage template options 1037 + 1038 + Retrieve exemplary storage template options. *) 1039 + val get_storage_template_options : t -> unit -> Types.SystemConfigTemplateStorageOptionDto.t 1040 + 1041 + (** Retrieve admin onboarding 1042 + 1043 + Retrieve the current admin onboarding status. *) 1044 + val get_admin_onboarding : t -> unit -> Types.AdminOnboardingUpdateDto.t 1045 + 1046 + (** Update admin onboarding 1047 + 1048 + Update the admin onboarding status. *) 1049 + val update_admin_onboarding : body:Types.AdminOnboardingUpdateDto.t -> t -> unit -> Jsont.json 1050 + 1051 + (** Retrieve reverse geocoding state 1052 + 1053 + Retrieve the current state of the reverse geocoding import. *) 1054 + val get_reverse_geocoding_state : t -> unit -> Types.ReverseGeocodingStateResponseDto.t 1055 + 1056 + (** Retrieve version check state 1057 + 1058 + Retrieve the current state of the version check process. *) 1059 + val get_version_check_state : t -> unit -> Types.VersionCheckStateResponseDto.t 1060 + 1061 + (** Retrieve tags 1062 + 1063 + Retrieve a list of all tags. *) 1064 + val get_all_tags : t -> unit -> Types.TagResponseDto.t list 1065 + 1066 + (** Create a tag 1067 + 1068 + Create a new tag by providing a name and optional color. *) 1069 + val create_tag : body:Types.TagCreateDto.t -> t -> unit -> Types.TagResponseDto.t 1070 + 1071 + (** Upsert tags 1072 + 1073 + Create or update multiple tags in a single request. *) 1074 + val upsert_tags : body:Types.TagUpsertDto.t -> t -> unit -> Types.TagResponseDto.t list 1075 + 1076 + (** Tag assets 1077 + 1078 + Add multiple tags to multiple assets in a single request. *) 1079 + val bulk_tag_assets : body:Types.TagBulkAssetsDto.t -> t -> unit -> Types.TagBulkAssetsResponseDto.t 1080 + 1081 + (** Retrieve a tag 1082 + 1083 + Retrieve a specific tag by its ID. *) 1084 + val get_tag_by_id : id:string -> t -> unit -> Types.TagResponseDto.t 1085 + 1086 + (** Update a tag 1087 + 1088 + Update an existing tag identified by its ID. *) 1089 + val update_tag : id:string -> body:Types.TagUpdateDto.t -> t -> unit -> Types.TagResponseDto.t 1090 + 1091 + (** Delete a tag 1092 + 1093 + Delete a specific tag by its ID. *) 1094 + val delete_tag : id:string -> t -> unit -> Jsont.json 1095 + 1096 + (** Tag assets 1097 + 1098 + Add a tag to all the specified assets. *) 1099 + val tag_assets : id:string -> body:Types.BulkIdsDto.t -> t -> unit -> Types.BulkIdResponseDto.t list 1100 + 1101 + (** Untag assets 1102 + 1103 + Remove a tag from all the specified assets. *) 1104 + val untag_assets : id:string -> t -> unit -> Types.BulkIdResponseDto.t list 1105 + 1106 + (** Get time bucket 1107 + 1108 + Retrieve a string of all asset ids in a given time bucket. *) 1109 + val get_time_bucket : ?album_id:string -> ?is_favorite:string -> ?is_trashed:string -> ?key:string -> ?order:string -> ?person_id:string -> ?slug:string -> ?tag_id:string -> time_bucket:string -> ?user_id:string -> ?visibility:string -> ?with_coordinates:string -> ?with_partners:string -> ?with_stacked:string -> t -> unit -> Types.TimeBucketAssetResponseDto.t 1110 + 1111 + (** Get time buckets 1112 + 1113 + Retrieve a list of all minimal time buckets. *) 1114 + val get_time_buckets : ?album_id:string -> ?is_favorite:string -> ?is_trashed:string -> ?key:string -> ?order:string -> ?person_id:string -> ?slug:string -> ?tag_id:string -> ?user_id:string -> ?visibility:string -> ?with_coordinates:string -> ?with_partners:string -> ?with_stacked:string -> t -> unit -> Types.TimeBucketsResponseDto.t list 1115 + 1116 + (** Empty trash 1117 + 1118 + Permanently delete all items in the trash. *) 1119 + val empty_trash : t -> unit -> Types.TrashResponseDto.t 1120 + 1121 + (** Restore trash 1122 + 1123 + Restore all items in the trash. *) 1124 + val restore_trash : t -> unit -> Types.TrashResponseDto.t 1125 + 1126 + (** Restore assets 1127 + 1128 + Restore specific assets from the trash. *) 1129 + val restore_assets : body:Types.BulkIdsDto.t -> t -> unit -> Types.TrashResponseDto.t 1130 + 1131 + (** Get all users 1132 + 1133 + Retrieve a list of all users on the server. *) 1134 + val search_users : t -> unit -> Types.UserResponseDto.t list 1135 + 1136 + (** Get current user 1137 + 1138 + Retrieve information about the user making the API request. *) 1139 + val get_my_user : t -> unit -> Types.UserAdminResponseDto.t 1140 + 1141 + (** Update current user 1142 + 1143 + Update the current user making teh API request. *) 1144 + val update_my_user : body:Types.UserUpdateMeDto.t -> t -> unit -> Types.UserAdminResponseDto.t 1145 + 1146 + (** Retrieve user product key 1147 + 1148 + Retrieve information about whether the current user has a registered product key. *) 1149 + val get_user_license : t -> unit -> Types.LicenseResponseDto.t 1150 + 1151 + (** Set user product key 1152 + 1153 + Register a product key for the current user. *) 1154 + val set_user_license : body:Types.LicenseKeyDto.t -> t -> unit -> Types.LicenseResponseDto.t 1155 + 1156 + (** Delete user product key 1157 + 1158 + Delete the registered product key for the current user. *) 1159 + val delete_user_license : t -> unit -> Jsont.json 1160 + 1161 + (** Retrieve user onboarding 1162 + 1163 + Retrieve the onboarding status of the current user. *) 1164 + val get_user_onboarding : t -> unit -> Types.OnboardingResponseDto.t 1165 + 1166 + (** Update user onboarding 1167 + 1168 + Update the onboarding status of the current user. *) 1169 + val set_user_onboarding : body:Types.OnboardingDto.t -> t -> unit -> Types.OnboardingResponseDto.t 1170 + 1171 + (** Delete user onboarding 1172 + 1173 + Delete the onboarding status of the current user. *) 1174 + val delete_user_onboarding : t -> unit -> Jsont.json 1175 + 1176 + (** Get my preferences 1177 + 1178 + Retrieve the preferences for the current user. *) 1179 + val get_my_preferences : t -> unit -> Types.UserPreferencesResponseDto.t 1180 + 1181 + (** Update my preferences 1182 + 1183 + Update the preferences of the current user. *) 1184 + val update_my_preferences : body:Types.UserPreferencesUpdateDto.t -> t -> unit -> Types.UserPreferencesResponseDto.t 1185 + 1186 + (** Create user profile image 1187 + 1188 + Upload and set a new profile image for the current user. *) 1189 + val create_profile_image : body:Jsont.json -> t -> unit -> Types.CreateProfileImageResponseDto.t 1190 + 1191 + (** Delete user profile image 1192 + 1193 + Delete the profile image of the current user. *) 1194 + val delete_profile_image : t -> unit -> Jsont.json 1195 + 1196 + (** Retrieve a user 1197 + 1198 + Retrieve a specific user by their ID. *) 1199 + val get_user : id:string -> t -> unit -> Types.UserResponseDto.t 1200 + 1201 + (** Retrieve user profile image 1202 + 1203 + Retrieve the profile image file for a user. *) 1204 + val get_profile_image : id:string -> t -> unit -> Jsont.json 1205 + 1206 + (** Retrieve assets by original path 1207 + 1208 + Retrieve assets that are children of a specific folder. *) 1209 + val get_assets_by_original_path : path:string -> t -> unit -> Types.AssetResponseDto.t list 1210 + 1211 + (** Retrieve unique paths 1212 + 1213 + Retrieve a list of unique folder paths from asset original paths. *) 1214 + val get_unique_original_paths : t -> unit -> Jsont.json 1215 + 1216 + (** List all workflows 1217 + 1218 + Retrieve a list of workflows available to the authenticated user. *) 1219 + val get_workflows : t -> unit -> Types.WorkflowResponseDto.t list 1220 + 1221 + (** Create a workflow 1222 + 1223 + Create a new workflow, the workflow can also be created with empty filters and actions. *) 1224 + val create_workflow : body:Types.WorkflowCreateDto.t -> t -> unit -> Types.WorkflowResponseDto.t 1225 + 1226 + (** Retrieve a workflow 1227 + 1228 + Retrieve information about a specific workflow by its ID. *) 1229 + val get_workflow : id:string -> t -> unit -> Types.WorkflowResponseDto.t 1230 + 1231 + (** Update a workflow 1232 + 1233 + Update the information of a specific workflow by its ID. This endpoint can be used to update the workflow name, description, trigger type, filters and actions order, etc. *) 1234 + val update_workflow : id:string -> body:Types.WorkflowUpdateDto.t -> t -> unit -> Types.WorkflowResponseDto.t 1235 + 1236 + (** Delete a workflow 1237 + 1238 + Delete a workflow by its ID. *) 1239 + val delete_workflow : id:string -> t -> unit -> Jsont.json
+6
ocaml-immich/dune
··· 1 + (library 2 + (name immich) 3 + (libraries openapi jsont jsont.bytesrw requests ptime) 4 + (wrapped true)) 5 + 6 + (include dune.inc)
+1
ocaml-immich/dune.inc
··· 1 + ; No spec path provided - regeneration rules not generated
+8
ocaml-immich/immich.ml
··· 1 + (** {1 Immich} 2 + 3 + Immich API 4 + 5 + @version 2.4.1 *) 6 + 7 + module Types = Types 8 + module Client = Client
+11
ocaml-immich/immich.mli
··· 1 + (** {1 Immich} 2 + 3 + Immich API 4 + 5 + @version 2.4.1 *) 6 + 7 + (** Type definitions for API data structures *) 8 + module Types = Types 9 + 10 + (** API client functions *) 11 + module Client = Client
+7969
ocaml-immich/types.ml
··· 1 + (** Immich API 2 + 3 + @version 2.4.1 *) 4 + 5 + module ActivityStatisticsResponseDto = struct 6 + type t = { 7 + comments : int; 8 + likes : int; 9 + } 10 + 11 + let t_jsont : t Jsont.t = 12 + Jsont.Object.map ~kind:"t" 13 + (fun comments likes -> { comments; likes }) 14 + |> Jsont.Object.mem "comments" Jsont.int ~enc:(fun r -> r.comments) 15 + |> Jsont.Object.mem "likes" Jsont.int ~enc:(fun r -> r.likes) 16 + |> Jsont.Object.skip_unknown 17 + |> Jsont.Object.finish 18 + end 19 + 20 + module AdminOnboardingUpdateDto = struct 21 + type t = { 22 + is_onboarded : bool; 23 + } 24 + 25 + let t_jsont : t Jsont.t = 26 + Jsont.Object.map ~kind:"t" 27 + (fun is_onboarded -> { is_onboarded }) 28 + |> Jsont.Object.mem "isOnboarded" Jsont.bool ~enc:(fun r -> r.is_onboarded) 29 + |> Jsont.Object.skip_unknown 30 + |> Jsont.Object.finish 31 + end 32 + 33 + module AlbumStatisticsResponseDto = struct 34 + type t = { 35 + not_shared : int; 36 + owned : int; 37 + shared : int; 38 + } 39 + 40 + let t_jsont : t Jsont.t = 41 + Jsont.Object.map ~kind:"t" 42 + (fun not_shared owned shared -> { not_shared; owned; shared }) 43 + |> Jsont.Object.mem "notShared" Jsont.int ~enc:(fun r -> r.not_shared) 44 + |> Jsont.Object.mem "owned" Jsont.int ~enc:(fun r -> r.owned) 45 + |> Jsont.Object.mem "shared" Jsont.int ~enc:(fun r -> r.shared) 46 + |> Jsont.Object.skip_unknown 47 + |> Jsont.Object.finish 48 + end 49 + 50 + module AlbumUserRole = struct 51 + type t = 52 + | Editor 53 + | Viewer 54 + 55 + let t_jsont : t Jsont.t = 56 + Jsont.map Jsont.string ~kind:"t" 57 + ~dec:(function 58 + | "editor" -> Editor 59 + | "viewer" -> Viewer 60 + | s -> Jsont.Error.msgf Jsont.Meta.none "Unknown t: %s" s) 61 + ~enc:(function 62 + | Editor -> "editor" 63 + | Viewer -> "viewer") 64 + end 65 + 66 + module AlbumsAddAssetsDto = struct 67 + type t = { 68 + album_ids : string list; 69 + asset_ids : string list; 70 + } 71 + 72 + let t_jsont : t Jsont.t = 73 + Jsont.Object.map ~kind:"t" 74 + (fun album_ids asset_ids -> { album_ids; asset_ids }) 75 + |> Jsont.Object.mem "albumIds" Jsont.(list Jsont.string) ~enc:(fun r -> r.album_ids) 76 + |> Jsont.Object.mem "assetIds" Jsont.(list Jsont.string) ~enc:(fun r -> r.asset_ids) 77 + |> Jsont.Object.skip_unknown 78 + |> Jsont.Object.finish 79 + end 80 + 81 + module AssetBulkDeleteDto = struct 82 + type t = { 83 + force : bool option; 84 + ids : string list; 85 + } 86 + 87 + let t_jsont : t Jsont.t = 88 + Jsont.Object.map ~kind:"t" 89 + (fun force ids -> { force; ids }) 90 + |> Jsont.Object.opt_mem "force" Jsont.bool ~enc:(fun r -> r.force) 91 + |> Jsont.Object.mem "ids" Jsont.(list Jsont.string) ~enc:(fun r -> r.ids) 92 + |> Jsont.Object.skip_unknown 93 + |> Jsont.Object.finish 94 + end 95 + 96 + module AssetBulkUploadCheckItem = struct 97 + type t = { 98 + checksum : string; (** base64 or hex encoded sha1 hash *) 99 + id : string; 100 + } 101 + 102 + let t_jsont : t Jsont.t = 103 + Jsont.Object.map ~kind:"t" 104 + (fun checksum id -> { checksum; id }) 105 + |> Jsont.Object.mem "checksum" Jsont.string ~enc:(fun r -> r.checksum) 106 + |> Jsont.Object.mem "id" Jsont.string ~enc:(fun r -> r.id) 107 + |> Jsont.Object.skip_unknown 108 + |> Jsont.Object.finish 109 + end 110 + 111 + module AssetBulkUploadCheckResult = struct 112 + type t = { 113 + action : string; 114 + asset_id : string option; 115 + id : string; 116 + is_trashed : bool option; 117 + reason : string option; 118 + } 119 + 120 + let t_jsont : t Jsont.t = 121 + Jsont.Object.map ~kind:"t" 122 + (fun action asset_id id is_trashed reason -> { action; asset_id; id; is_trashed; reason }) 123 + |> Jsont.Object.mem "action" Jsont.string ~enc:(fun r -> r.action) 124 + |> Jsont.Object.opt_mem "assetId" Jsont.string ~enc:(fun r -> r.asset_id) 125 + |> Jsont.Object.mem "id" Jsont.string ~enc:(fun r -> r.id) 126 + |> Jsont.Object.opt_mem "isTrashed" Jsont.bool ~enc:(fun r -> r.is_trashed) 127 + |> Jsont.Object.opt_mem "reason" Jsont.string ~enc:(fun r -> r.reason) 128 + |> Jsont.Object.skip_unknown 129 + |> Jsont.Object.finish 130 + end 131 + 132 + module AssetCopyDto = struct 133 + type t = { 134 + albums : bool option; 135 + favorite : bool option; 136 + shared_links : bool option; 137 + sidecar : bool option; 138 + source_id : string; 139 + stack : bool option; 140 + target_id : string; 141 + } 142 + 143 + let t_jsont : t Jsont.t = 144 + Jsont.Object.map ~kind:"t" 145 + (fun albums favorite shared_links sidecar source_id stack target_id -> { albums; favorite; shared_links; sidecar; source_id; stack; target_id }) 146 + |> Jsont.Object.opt_mem "albums" Jsont.bool ~enc:(fun r -> r.albums) 147 + |> Jsont.Object.opt_mem "favorite" Jsont.bool ~enc:(fun r -> r.favorite) 148 + |> Jsont.Object.opt_mem "sharedLinks" Jsont.bool ~enc:(fun r -> r.shared_links) 149 + |> Jsont.Object.opt_mem "sidecar" Jsont.bool ~enc:(fun r -> r.sidecar) 150 + |> Jsont.Object.mem "sourceId" Jsont.string ~enc:(fun r -> r.source_id) 151 + |> Jsont.Object.opt_mem "stack" Jsont.bool ~enc:(fun r -> r.stack) 152 + |> Jsont.Object.mem "targetId" Jsont.string ~enc:(fun r -> r.target_id) 153 + |> Jsont.Object.skip_unknown 154 + |> Jsont.Object.finish 155 + end 156 + 157 + module AssetDeltaSyncDto = struct 158 + type t = { 159 + updated_after : Ptime.t; 160 + user_ids : string list; 161 + } 162 + 163 + let t_jsont : t Jsont.t = 164 + Jsont.Object.map ~kind:"t" 165 + (fun updated_after user_ids -> { updated_after; user_ids }) 166 + |> Jsont.Object.mem "updatedAfter" Openapi.Runtime.ptime_jsont ~enc:(fun r -> r.updated_after) 167 + |> Jsont.Object.mem "userIds" Jsont.(list Jsont.string) ~enc:(fun r -> r.user_ids) 168 + |> Jsont.Object.skip_unknown 169 + |> Jsont.Object.finish 170 + end 171 + 172 + module AssetEditAction = struct 173 + type t = 174 + | Crop 175 + | Rotate 176 + | Mirror 177 + 178 + let t_jsont : t Jsont.t = 179 + Jsont.map Jsont.string ~kind:"t" 180 + ~dec:(function 181 + | "crop" -> Crop 182 + | "rotate" -> Rotate 183 + | "mirror" -> Mirror 184 + | s -> Jsont.Error.msgf Jsont.Meta.none "Unknown t: %s" s) 185 + ~enc:(function 186 + | Crop -> "crop" 187 + | Rotate -> "rotate" 188 + | Mirror -> "mirror") 189 + end 190 + 191 + module AssetFaceCreateDto = struct 192 + type t = { 193 + asset_id : string; 194 + height : int; 195 + image_height : int; 196 + image_width : int; 197 + person_id : string; 198 + width : int; 199 + x : int; 200 + y : int; 201 + } 202 + 203 + let t_jsont : t Jsont.t = 204 + Jsont.Object.map ~kind:"t" 205 + (fun asset_id height image_height image_width person_id width x y -> { asset_id; height; image_height; image_width; person_id; width; x; y }) 206 + |> Jsont.Object.mem "assetId" Jsont.string ~enc:(fun r -> r.asset_id) 207 + |> Jsont.Object.mem "height" Jsont.int ~enc:(fun r -> r.height) 208 + |> Jsont.Object.mem "imageHeight" Jsont.int ~enc:(fun r -> r.image_height) 209 + |> Jsont.Object.mem "imageWidth" Jsont.int ~enc:(fun r -> r.image_width) 210 + |> Jsont.Object.mem "personId" Jsont.string ~enc:(fun r -> r.person_id) 211 + |> Jsont.Object.mem "width" Jsont.int ~enc:(fun r -> r.width) 212 + |> Jsont.Object.mem "x" Jsont.int ~enc:(fun r -> r.x) 213 + |> Jsont.Object.mem "y" Jsont.int ~enc:(fun r -> r.y) 214 + |> Jsont.Object.skip_unknown 215 + |> Jsont.Object.finish 216 + end 217 + 218 + module AssetFaceDeleteDto = struct 219 + type t = { 220 + force : bool; 221 + } 222 + 223 + let t_jsont : t Jsont.t = 224 + Jsont.Object.map ~kind:"t" 225 + (fun force -> { force }) 226 + |> Jsont.Object.mem "force" Jsont.bool ~enc:(fun r -> r.force) 227 + |> Jsont.Object.skip_unknown 228 + |> Jsont.Object.finish 229 + end 230 + 231 + module AssetFaceUpdateItem = struct 232 + type t = { 233 + asset_id : string; 234 + person_id : string; 235 + } 236 + 237 + let t_jsont : t Jsont.t = 238 + Jsont.Object.map ~kind:"t" 239 + (fun asset_id person_id -> { asset_id; person_id }) 240 + |> Jsont.Object.mem "assetId" Jsont.string ~enc:(fun r -> r.asset_id) 241 + |> Jsont.Object.mem "personId" Jsont.string ~enc:(fun r -> r.person_id) 242 + |> Jsont.Object.skip_unknown 243 + |> Jsont.Object.finish 244 + end 245 + 246 + module AssetFullSyncDto = struct 247 + type t = { 248 + last_id : string option; 249 + limit : int; 250 + updated_until : Ptime.t; 251 + user_id : string option; 252 + } 253 + 254 + let t_jsont : t Jsont.t = 255 + Jsont.Object.map ~kind:"t" 256 + (fun last_id limit updated_until user_id -> { last_id; limit; updated_until; user_id }) 257 + |> Jsont.Object.opt_mem "lastId" Jsont.string ~enc:(fun r -> r.last_id) 258 + |> Jsont.Object.mem "limit" Jsont.int ~enc:(fun r -> r.limit) 259 + |> Jsont.Object.mem "updatedUntil" Openapi.Runtime.ptime_jsont ~enc:(fun r -> r.updated_until) 260 + |> Jsont.Object.opt_mem "userId" Jsont.string ~enc:(fun r -> r.user_id) 261 + |> Jsont.Object.skip_unknown 262 + |> Jsont.Object.finish 263 + end 264 + 265 + module AssetIdsDto = struct 266 + type t = { 267 + asset_ids : string list; 268 + } 269 + 270 + let t_jsont : t Jsont.t = 271 + Jsont.Object.map ~kind:"t" 272 + (fun asset_ids -> { asset_ids }) 273 + |> Jsont.Object.mem "assetIds" Jsont.(list Jsont.string) ~enc:(fun r -> r.asset_ids) 274 + |> Jsont.Object.skip_unknown 275 + |> Jsont.Object.finish 276 + end 277 + 278 + module AssetIdsResponseDto = struct 279 + type t = { 280 + asset_id : string; 281 + error : string option; 282 + success : bool; 283 + } 284 + 285 + let t_jsont : t Jsont.t = 286 + Jsont.Object.map ~kind:"t" 287 + (fun asset_id error success -> { asset_id; error; success }) 288 + |> Jsont.Object.mem "assetId" Jsont.string ~enc:(fun r -> r.asset_id) 289 + |> Jsont.Object.opt_mem "error" Jsont.string ~enc:(fun r -> r.error) 290 + |> Jsont.Object.mem "success" Jsont.bool ~enc:(fun r -> r.success) 291 + |> Jsont.Object.skip_unknown 292 + |> Jsont.Object.finish 293 + end 294 + 295 + module AssetJobName = struct 296 + type t = 297 + | Refresh_faces 298 + | Refresh_metadata 299 + | Regenerate_thumbnail 300 + | Transcode_video 301 + 302 + let t_jsont : t Jsont.t = 303 + Jsont.map Jsont.string ~kind:"t" 304 + ~dec:(function 305 + | "refresh-faces" -> Refresh_faces 306 + | "refresh-metadata" -> Refresh_metadata 307 + | "regenerate-thumbnail" -> Regenerate_thumbnail 308 + | "transcode-video" -> Transcode_video 309 + | s -> Jsont.Error.msgf Jsont.Meta.none "Unknown t: %s" s) 310 + ~enc:(function 311 + | Refresh_faces -> "refresh-faces" 312 + | Refresh_metadata -> "refresh-metadata" 313 + | Regenerate_thumbnail -> "regenerate-thumbnail" 314 + | Transcode_video -> "transcode-video") 315 + end 316 + 317 + module AssetMediaReplaceDto = struct 318 + type t = { 319 + asset_data : string; 320 + device_asset_id : string; 321 + device_id : string; 322 + duration : string option; 323 + file_created_at : Ptime.t; 324 + file_modified_at : Ptime.t; 325 + filename : string option; 326 + } 327 + 328 + let t_jsont : t Jsont.t = 329 + Jsont.Object.map ~kind:"t" 330 + (fun asset_data device_asset_id device_id duration file_created_at file_modified_at filename -> { asset_data; device_asset_id; device_id; duration; file_created_at; file_modified_at; filename }) 331 + |> Jsont.Object.mem "assetData" Jsont.string ~enc:(fun r -> r.asset_data) 332 + |> Jsont.Object.mem "deviceAssetId" Jsont.string ~enc:(fun r -> r.device_asset_id) 333 + |> Jsont.Object.mem "deviceId" Jsont.string ~enc:(fun r -> r.device_id) 334 + |> Jsont.Object.opt_mem "duration" Jsont.string ~enc:(fun r -> r.duration) 335 + |> Jsont.Object.mem "fileCreatedAt" Openapi.Runtime.ptime_jsont ~enc:(fun r -> r.file_created_at) 336 + |> Jsont.Object.mem "fileModifiedAt" Openapi.Runtime.ptime_jsont ~enc:(fun r -> r.file_modified_at) 337 + |> Jsont.Object.opt_mem "filename" Jsont.string ~enc:(fun r -> r.filename) 338 + |> Jsont.Object.skip_unknown 339 + |> Jsont.Object.finish 340 + end 341 + 342 + module AssetMediaSize = struct 343 + type t = 344 + | Original 345 + | Fullsize 346 + | Preview 347 + | Thumbnail 348 + 349 + let t_jsont : t Jsont.t = 350 + Jsont.map Jsont.string ~kind:"t" 351 + ~dec:(function 352 + | "original" -> Original 353 + | "fullsize" -> Fullsize 354 + | "preview" -> Preview 355 + | "thumbnail" -> Thumbnail 356 + | s -> Jsont.Error.msgf Jsont.Meta.none "Unknown t: %s" s) 357 + ~enc:(function 358 + | Original -> "original" 359 + | Fullsize -> "fullsize" 360 + | Preview -> "preview" 361 + | Thumbnail -> "thumbnail") 362 + end 363 + 364 + module AssetMediaStatus = struct 365 + type t = 366 + | Created 367 + | Replaced 368 + | Duplicate 369 + 370 + let t_jsont : t Jsont.t = 371 + Jsont.map Jsont.string ~kind:"t" 372 + ~dec:(function 373 + | "created" -> Created 374 + | "replaced" -> Replaced 375 + | "duplicate" -> Duplicate 376 + | s -> Jsont.Error.msgf Jsont.Meta.none "Unknown t: %s" s) 377 + ~enc:(function 378 + | Created -> "created" 379 + | Replaced -> "replaced" 380 + | Duplicate -> "duplicate") 381 + end 382 + 383 + module AssetMetadataBulkDeleteItemDto = struct 384 + type t = { 385 + asset_id : string; 386 + key : string; 387 + } 388 + 389 + let t_jsont : t Jsont.t = 390 + Jsont.Object.map ~kind:"t" 391 + (fun asset_id key -> { asset_id; key }) 392 + |> Jsont.Object.mem "assetId" Jsont.string ~enc:(fun r -> r.asset_id) 393 + |> Jsont.Object.mem "key" Jsont.string ~enc:(fun r -> r.key) 394 + |> Jsont.Object.skip_unknown 395 + |> Jsont.Object.finish 396 + end 397 + 398 + module AssetMetadataBulkResponseDto = struct 399 + type t = { 400 + asset_id : string; 401 + key : string; 402 + updated_at : Ptime.t; 403 + value : Jsont.json; 404 + } 405 + 406 + let t_jsont : t Jsont.t = 407 + Jsont.Object.map ~kind:"t" 408 + (fun asset_id key updated_at value -> { asset_id; key; updated_at; value }) 409 + |> Jsont.Object.mem "assetId" Jsont.string ~enc:(fun r -> r.asset_id) 410 + |> Jsont.Object.mem "key" Jsont.string ~enc:(fun r -> r.key) 411 + |> Jsont.Object.mem "updatedAt" Openapi.Runtime.ptime_jsont ~enc:(fun r -> r.updated_at) 412 + |> Jsont.Object.mem "value" Jsont.json ~enc:(fun r -> r.value) 413 + |> Jsont.Object.skip_unknown 414 + |> Jsont.Object.finish 415 + end 416 + 417 + module AssetMetadataBulkUpsertItemDto = struct 418 + type t = { 419 + asset_id : string; 420 + key : string; 421 + value : Jsont.json; 422 + } 423 + 424 + let t_jsont : t Jsont.t = 425 + Jsont.Object.map ~kind:"t" 426 + (fun asset_id key value -> { asset_id; key; value }) 427 + |> Jsont.Object.mem "assetId" Jsont.string ~enc:(fun r -> r.asset_id) 428 + |> Jsont.Object.mem "key" Jsont.string ~enc:(fun r -> r.key) 429 + |> Jsont.Object.mem "value" Jsont.json ~enc:(fun r -> r.value) 430 + |> Jsont.Object.skip_unknown 431 + |> Jsont.Object.finish 432 + end 433 + 434 + module AssetMetadataResponseDto = struct 435 + type t = { 436 + key : string; 437 + updated_at : Ptime.t; 438 + value : Jsont.json; 439 + } 440 + 441 + let t_jsont : t Jsont.t = 442 + Jsont.Object.map ~kind:"t" 443 + (fun key updated_at value -> { key; updated_at; value }) 444 + |> Jsont.Object.mem "key" Jsont.string ~enc:(fun r -> r.key) 445 + |> Jsont.Object.mem "updatedAt" Openapi.Runtime.ptime_jsont ~enc:(fun r -> r.updated_at) 446 + |> Jsont.Object.mem "value" Jsont.json ~enc:(fun r -> r.value) 447 + |> Jsont.Object.skip_unknown 448 + |> Jsont.Object.finish 449 + end 450 + 451 + module AssetMetadataUpsertItemDto = struct 452 + type t = { 453 + key : string; 454 + value : Jsont.json; 455 + } 456 + 457 + let t_jsont : t Jsont.t = 458 + Jsont.Object.map ~kind:"t" 459 + (fun key value -> { key; value }) 460 + |> Jsont.Object.mem "key" Jsont.string ~enc:(fun r -> r.key) 461 + |> Jsont.Object.mem "value" Jsont.json ~enc:(fun r -> r.value) 462 + |> Jsont.Object.skip_unknown 463 + |> Jsont.Object.finish 464 + end 465 + 466 + module AssetOcrResponseDto = struct 467 + type t = { 468 + asset_id : string; 469 + box_score : float; (** Confidence score for text detection box *) 470 + id : string; 471 + text : string; (** Recognized text *) 472 + text_score : float; (** Confidence score for text recognition *) 473 + x1 : float; (** Normalized x coordinate of box corner 1 (0-1) *) 474 + x2 : float; (** Normalized x coordinate of box corner 2 (0-1) *) 475 + x3 : float; (** Normalized x coordinate of box corner 3 (0-1) *) 476 + x4 : float; (** Normalized x coordinate of box corner 4 (0-1) *) 477 + y1 : float; (** Normalized y coordinate of box corner 1 (0-1) *) 478 + y2 : float; (** Normalized y coordinate of box corner 2 (0-1) *) 479 + y3 : float; (** Normalized y coordinate of box corner 3 (0-1) *) 480 + y4 : float; (** Normalized y coordinate of box corner 4 (0-1) *) 481 + } 482 + 483 + let t_jsont : t Jsont.t = 484 + Jsont.Object.map ~kind:"t" 485 + (fun asset_id box_score id text text_score x1 x2 x3 x4 y1 y2 y3 y4 -> { asset_id; box_score; id; text; text_score; x1; x2; x3; x4; y1; y2; y3; y4 }) 486 + |> Jsont.Object.mem "assetId" Jsont.string ~enc:(fun r -> r.asset_id) 487 + |> Jsont.Object.mem "boxScore" Jsont.number ~enc:(fun r -> r.box_score) 488 + |> Jsont.Object.mem "id" Jsont.string ~enc:(fun r -> r.id) 489 + |> Jsont.Object.mem "text" Jsont.string ~enc:(fun r -> r.text) 490 + |> Jsont.Object.mem "textScore" Jsont.number ~enc:(fun r -> r.text_score) 491 + |> Jsont.Object.mem "x1" Jsont.number ~enc:(fun r -> r.x1) 492 + |> Jsont.Object.mem "x2" Jsont.number ~enc:(fun r -> r.x2) 493 + |> Jsont.Object.mem "x3" Jsont.number ~enc:(fun r -> r.x3) 494 + |> Jsont.Object.mem "x4" Jsont.number ~enc:(fun r -> r.x4) 495 + |> Jsont.Object.mem "y1" Jsont.number ~enc:(fun r -> r.y1) 496 + |> Jsont.Object.mem "y2" Jsont.number ~enc:(fun r -> r.y2) 497 + |> Jsont.Object.mem "y3" Jsont.number ~enc:(fun r -> r.y3) 498 + |> Jsont.Object.mem "y4" Jsont.number ~enc:(fun r -> r.y4) 499 + |> Jsont.Object.skip_unknown 500 + |> Jsont.Object.finish 501 + end 502 + 503 + module AssetOrder = struct 504 + type t = 505 + | Asc 506 + | Desc 507 + 508 + let t_jsont : t Jsont.t = 509 + Jsont.map Jsont.string ~kind:"t" 510 + ~dec:(function 511 + | "asc" -> Asc 512 + | "desc" -> Desc 513 + | s -> Jsont.Error.msgf Jsont.Meta.none "Unknown t: %s" s) 514 + ~enc:(function 515 + | Asc -> "asc" 516 + | Desc -> "desc") 517 + end 518 + 519 + module AssetStackResponseDto = struct 520 + type t = { 521 + asset_count : int; 522 + id : string; 523 + primary_asset_id : string; 524 + } 525 + 526 + let t_jsont : t Jsont.t = 527 + Jsont.Object.map ~kind:"t" 528 + (fun asset_count id primary_asset_id -> { asset_count; id; primary_asset_id }) 529 + |> Jsont.Object.mem "assetCount" Jsont.int ~enc:(fun r -> r.asset_count) 530 + |> Jsont.Object.mem "id" Jsont.string ~enc:(fun r -> r.id) 531 + |> Jsont.Object.mem "primaryAssetId" Jsont.string ~enc:(fun r -> r.primary_asset_id) 532 + |> Jsont.Object.skip_unknown 533 + |> Jsont.Object.finish 534 + end 535 + 536 + module AssetStatsResponseDto = struct 537 + type t = { 538 + images : int; 539 + total : int; 540 + videos : int; 541 + } 542 + 543 + let t_jsont : t Jsont.t = 544 + Jsont.Object.map ~kind:"t" 545 + (fun images total videos -> { images; total; videos }) 546 + |> Jsont.Object.mem "images" Jsont.int ~enc:(fun r -> r.images) 547 + |> Jsont.Object.mem "total" Jsont.int ~enc:(fun r -> r.total) 548 + |> Jsont.Object.mem "videos" Jsont.int ~enc:(fun r -> r.videos) 549 + |> Jsont.Object.skip_unknown 550 + |> Jsont.Object.finish 551 + end 552 + 553 + module AssetTypeEnum = struct 554 + type t = 555 + | Image 556 + | Video 557 + | Audio 558 + | Other 559 + 560 + let t_jsont : t Jsont.t = 561 + Jsont.map Jsont.string ~kind:"t" 562 + ~dec:(function 563 + | "IMAGE" -> Image 564 + | "VIDEO" -> Video 565 + | "AUDIO" -> Audio 566 + | "OTHER" -> Other 567 + | s -> Jsont.Error.msgf Jsont.Meta.none "Unknown t: %s" s) 568 + ~enc:(function 569 + | Image -> "IMAGE" 570 + | Video -> "VIDEO" 571 + | Audio -> "AUDIO" 572 + | Other -> "OTHER") 573 + end 574 + 575 + module AssetVisibility = struct 576 + type t = 577 + | Archive 578 + | Timeline 579 + | Hidden 580 + | Locked 581 + 582 + let t_jsont : t Jsont.t = 583 + Jsont.map Jsont.string ~kind:"t" 584 + ~dec:(function 585 + | "archive" -> Archive 586 + | "timeline" -> Timeline 587 + | "hidden" -> Hidden 588 + | "locked" -> Locked 589 + | s -> Jsont.Error.msgf Jsont.Meta.none "Unknown t: %s" s) 590 + ~enc:(function 591 + | Archive -> "archive" 592 + | Timeline -> "timeline" 593 + | Hidden -> "hidden" 594 + | Locked -> "locked") 595 + end 596 + 597 + module AudioCodec = struct 598 + type t = 599 + | Mp3 600 + | Aac 601 + | Libopus 602 + | Pcm_s16le 603 + 604 + let t_jsont : t Jsont.t = 605 + Jsont.map Jsont.string ~kind:"t" 606 + ~dec:(function 607 + | "mp3" -> Mp3 608 + | "aac" -> Aac 609 + | "libopus" -> Libopus 610 + | "pcm_s16le" -> Pcm_s16le 611 + | s -> Jsont.Error.msgf Jsont.Meta.none "Unknown t: %s" s) 612 + ~enc:(function 613 + | Mp3 -> "mp3" 614 + | Aac -> "aac" 615 + | Libopus -> "libopus" 616 + | Pcm_s16le -> "pcm_s16le") 617 + end 618 + 619 + module AuthStatusResponseDto = struct 620 + type t = { 621 + expires_at : string option; 622 + is_elevated : bool; 623 + password : bool; 624 + pin_code : bool; 625 + pin_expires_at : string option; 626 + } 627 + 628 + let t_jsont : t Jsont.t = 629 + Jsont.Object.map ~kind:"t" 630 + (fun expires_at is_elevated password pin_code pin_expires_at -> { expires_at; is_elevated; password; pin_code; pin_expires_at }) 631 + |> Jsont.Object.opt_mem "expiresAt" Jsont.string ~enc:(fun r -> r.expires_at) 632 + |> Jsont.Object.mem "isElevated" Jsont.bool ~enc:(fun r -> r.is_elevated) 633 + |> Jsont.Object.mem "password" Jsont.bool ~enc:(fun r -> r.password) 634 + |> Jsont.Object.mem "pinCode" Jsont.bool ~enc:(fun r -> r.pin_code) 635 + |> Jsont.Object.opt_mem "pinExpiresAt" Jsont.string ~enc:(fun r -> r.pin_expires_at) 636 + |> Jsont.Object.skip_unknown 637 + |> Jsont.Object.finish 638 + end 639 + 640 + module BulkIdErrorReason = struct 641 + type t = 642 + | Duplicate 643 + | No_permission 644 + | Not_found 645 + | Unknown 646 + 647 + let t_jsont : t Jsont.t = 648 + Jsont.map Jsont.string ~kind:"t" 649 + ~dec:(function 650 + | "duplicate" -> Duplicate 651 + | "no_permission" -> No_permission 652 + | "not_found" -> Not_found 653 + | "unknown" -> Unknown 654 + | s -> Jsont.Error.msgf Jsont.Meta.none "Unknown t: %s" s) 655 + ~enc:(function 656 + | Duplicate -> "duplicate" 657 + | No_permission -> "no_permission" 658 + | Not_found -> "not_found" 659 + | Unknown -> "unknown") 660 + end 661 + 662 + module BulkIdResponseDto = struct 663 + type t = { 664 + error : string option; 665 + id : string; 666 + success : bool; 667 + } 668 + 669 + let t_jsont : t Jsont.t = 670 + Jsont.Object.map ~kind:"t" 671 + (fun error id success -> { error; id; success }) 672 + |> Jsont.Object.opt_mem "error" Jsont.string ~enc:(fun r -> r.error) 673 + |> Jsont.Object.mem "id" Jsont.string ~enc:(fun r -> r.id) 674 + |> Jsont.Object.mem "success" Jsont.bool ~enc:(fun r -> r.success) 675 + |> Jsont.Object.skip_unknown 676 + |> Jsont.Object.finish 677 + end 678 + 679 + module BulkIdsDto = struct 680 + type t = { 681 + ids : string list; 682 + } 683 + 684 + let t_jsont : t Jsont.t = 685 + Jsont.Object.map ~kind:"t" 686 + (fun ids -> { ids }) 687 + |> Jsont.Object.mem "ids" Jsont.(list Jsont.string) ~enc:(fun r -> r.ids) 688 + |> Jsont.Object.skip_unknown 689 + |> Jsont.Object.finish 690 + end 691 + 692 + module Clipconfig = struct 693 + type t = { 694 + enabled : bool; 695 + model_name : string; 696 + } 697 + 698 + let t_jsont : t Jsont.t = 699 + Jsont.Object.map ~kind:"t" 700 + (fun enabled model_name -> { enabled; model_name }) 701 + |> Jsont.Object.mem "enabled" Jsont.bool ~enc:(fun r -> r.enabled) 702 + |> Jsont.Object.mem "modelName" Jsont.string ~enc:(fun r -> r.model_name) 703 + |> Jsont.Object.skip_unknown 704 + |> Jsont.Object.finish 705 + end 706 + 707 + module Cqmode = struct 708 + type t = 709 + | Auto 710 + | Cqp 711 + | Icq 712 + 713 + let t_jsont : t Jsont.t = 714 + Jsont.map Jsont.string ~kind:"t" 715 + ~dec:(function 716 + | "auto" -> Auto 717 + | "cqp" -> Cqp 718 + | "icq" -> Icq 719 + | s -> Jsont.Error.msgf Jsont.Meta.none "Unknown t: %s" s) 720 + ~enc:(function 721 + | Auto -> "auto" 722 + | Cqp -> "cqp" 723 + | Icq -> "icq") 724 + end 725 + 726 + module CastResponse = struct 727 + type t = { 728 + g_cast_enabled : bool; 729 + } 730 + 731 + let t_jsont : t Jsont.t = 732 + Jsont.Object.map ~kind:"t" 733 + (fun g_cast_enabled -> { g_cast_enabled }) 734 + |> Jsont.Object.mem "gCastEnabled" Jsont.bool ~enc:(fun r -> r.g_cast_enabled) 735 + |> Jsont.Object.skip_unknown 736 + |> Jsont.Object.finish 737 + end 738 + 739 + module CastUpdate = struct 740 + type t = { 741 + g_cast_enabled : bool option; 742 + } 743 + 744 + let t_jsont : t Jsont.t = 745 + Jsont.Object.map ~kind:"t" 746 + (fun g_cast_enabled -> { g_cast_enabled }) 747 + |> Jsont.Object.opt_mem "gCastEnabled" Jsont.bool ~enc:(fun r -> r.g_cast_enabled) 748 + |> Jsont.Object.skip_unknown 749 + |> Jsont.Object.finish 750 + end 751 + 752 + module ChangePasswordDto = struct 753 + type t = { 754 + invalidate_sessions : bool option; 755 + new_password : string; 756 + password : string; 757 + } 758 + 759 + let t_jsont : t Jsont.t = 760 + Jsont.Object.map ~kind:"t" 761 + (fun invalidate_sessions new_password password -> { invalidate_sessions; new_password; password }) 762 + |> Jsont.Object.opt_mem "invalidateSessions" Jsont.bool ~enc:(fun r -> r.invalidate_sessions) 763 + |> Jsont.Object.mem "newPassword" Jsont.string ~enc:(fun r -> r.new_password) 764 + |> Jsont.Object.mem "password" Jsont.string ~enc:(fun r -> r.password) 765 + |> Jsont.Object.skip_unknown 766 + |> Jsont.Object.finish 767 + end 768 + 769 + module CheckExistingAssetsDto = struct 770 + type t = { 771 + device_asset_ids : string list; 772 + device_id : string; 773 + } 774 + 775 + let t_jsont : t Jsont.t = 776 + Jsont.Object.map ~kind:"t" 777 + (fun device_asset_ids device_id -> { device_asset_ids; device_id }) 778 + |> Jsont.Object.mem "deviceAssetIds" Jsont.(list Jsont.string) ~enc:(fun r -> r.device_asset_ids) 779 + |> Jsont.Object.mem "deviceId" Jsont.string ~enc:(fun r -> r.device_id) 780 + |> Jsont.Object.skip_unknown 781 + |> Jsont.Object.finish 782 + end 783 + 784 + module CheckExistingAssetsResponseDto = struct 785 + type t = { 786 + existing_ids : string list; 787 + } 788 + 789 + let t_jsont : t Jsont.t = 790 + Jsont.Object.map ~kind:"t" 791 + (fun existing_ids -> { existing_ids }) 792 + |> Jsont.Object.mem "existingIds" Jsont.(list Jsont.string) ~enc:(fun r -> r.existing_ids) 793 + |> Jsont.Object.skip_unknown 794 + |> Jsont.Object.finish 795 + end 796 + 797 + module Colorspace = struct 798 + type t = 799 + | Srgb 800 + | P3 801 + 802 + let t_jsont : t Jsont.t = 803 + Jsont.map Jsont.string ~kind:"t" 804 + ~dec:(function 805 + | "srgb" -> Srgb 806 + | "p3" -> P3 807 + | s -> Jsont.Error.msgf Jsont.Meta.none "Unknown t: %s" s) 808 + ~enc:(function 809 + | Srgb -> "srgb" 810 + | P3 -> "p3") 811 + end 812 + 813 + module ContributorCountResponseDto = struct 814 + type t = { 815 + asset_count : int; 816 + user_id : string; 817 + } 818 + 819 + let t_jsont : t Jsont.t = 820 + Jsont.Object.map ~kind:"t" 821 + (fun asset_count user_id -> { asset_count; user_id }) 822 + |> Jsont.Object.mem "assetCount" Jsont.int ~enc:(fun r -> r.asset_count) 823 + |> Jsont.Object.mem "userId" Jsont.string ~enc:(fun r -> r.user_id) 824 + |> Jsont.Object.skip_unknown 825 + |> Jsont.Object.finish 826 + end 827 + 828 + module CreateLibraryDto = struct 829 + type t = { 830 + exclusion_patterns : string list option; 831 + import_paths : string list option; 832 + name : string option; 833 + owner_id : string; 834 + } 835 + 836 + let t_jsont : t Jsont.t = 837 + Jsont.Object.map ~kind:"t" 838 + (fun exclusion_patterns import_paths name owner_id -> { exclusion_patterns; import_paths; name; owner_id }) 839 + |> Jsont.Object.opt_mem "exclusionPatterns" Jsont.(list Jsont.string) ~enc:(fun r -> r.exclusion_patterns) 840 + |> Jsont.Object.opt_mem "importPaths" Jsont.(list Jsont.string) ~enc:(fun r -> r.import_paths) 841 + |> Jsont.Object.opt_mem "name" Jsont.string ~enc:(fun r -> r.name) 842 + |> Jsont.Object.mem "ownerId" Jsont.string ~enc:(fun r -> r.owner_id) 843 + |> Jsont.Object.skip_unknown 844 + |> Jsont.Object.finish 845 + end 846 + 847 + module CreateProfileImageDto = struct 848 + type t = { 849 + file : string; 850 + } 851 + 852 + let t_jsont : t Jsont.t = 853 + Jsont.Object.map ~kind:"t" 854 + (fun file -> { file }) 855 + |> Jsont.Object.mem "file" Jsont.string ~enc:(fun r -> r.file) 856 + |> Jsont.Object.skip_unknown 857 + |> Jsont.Object.finish 858 + end 859 + 860 + module CreateProfileImageResponseDto = struct 861 + type t = { 862 + profile_changed_at : Ptime.t; 863 + profile_image_path : string; 864 + user_id : string; 865 + } 866 + 867 + let t_jsont : t Jsont.t = 868 + Jsont.Object.map ~kind:"t" 869 + (fun profile_changed_at profile_image_path user_id -> { profile_changed_at; profile_image_path; user_id }) 870 + |> Jsont.Object.mem "profileChangedAt" Openapi.Runtime.ptime_jsont ~enc:(fun r -> r.profile_changed_at) 871 + |> Jsont.Object.mem "profileImagePath" Jsont.string ~enc:(fun r -> r.profile_image_path) 872 + |> Jsont.Object.mem "userId" Jsont.string ~enc:(fun r -> r.user_id) 873 + |> Jsont.Object.skip_unknown 874 + |> Jsont.Object.finish 875 + end 876 + 877 + module CropParameters = struct 878 + type t = { 879 + height : float; (** Height of the crop *) 880 + width : float; (** Width of the crop *) 881 + x : float; (** Top-Left X coordinate of crop *) 882 + y : float; (** Top-Left Y coordinate of crop *) 883 + } 884 + 885 + let t_jsont : t Jsont.t = 886 + Jsont.Object.map ~kind:"t" 887 + (fun height width x y -> { height; width; x; y }) 888 + |> Jsont.Object.mem "height" Jsont.number ~enc:(fun r -> r.height) 889 + |> Jsont.Object.mem "width" Jsont.number ~enc:(fun r -> r.width) 890 + |> Jsont.Object.mem "x" Jsont.number ~enc:(fun r -> r.x) 891 + |> Jsont.Object.mem "y" Jsont.number ~enc:(fun r -> r.y) 892 + |> Jsont.Object.skip_unknown 893 + |> Jsont.Object.finish 894 + end 895 + 896 + module DatabaseBackupConfig = struct 897 + type t = { 898 + cron_expression : string; 899 + enabled : bool; 900 + keep_last_amount : float; 901 + } 902 + 903 + let t_jsont : t Jsont.t = 904 + Jsont.Object.map ~kind:"t" 905 + (fun cron_expression enabled keep_last_amount -> { cron_expression; enabled; keep_last_amount }) 906 + |> Jsont.Object.mem "cronExpression" Jsont.string ~enc:(fun r -> r.cron_expression) 907 + |> Jsont.Object.mem "enabled" Jsont.bool ~enc:(fun r -> r.enabled) 908 + |> Jsont.Object.mem "keepLastAmount" Jsont.number ~enc:(fun r -> r.keep_last_amount) 909 + |> Jsont.Object.skip_unknown 910 + |> Jsont.Object.finish 911 + end 912 + 913 + module DatabaseBackupDeleteDto = struct 914 + type t = { 915 + backups : string list; 916 + } 917 + 918 + let t_jsont : t Jsont.t = 919 + Jsont.Object.map ~kind:"t" 920 + (fun backups -> { backups }) 921 + |> Jsont.Object.mem "backups" Jsont.(list Jsont.string) ~enc:(fun r -> r.backups) 922 + |> Jsont.Object.skip_unknown 923 + |> Jsont.Object.finish 924 + end 925 + 926 + module DatabaseBackupDto = struct 927 + type t = { 928 + filename : string; 929 + filesize : float; 930 + } 931 + 932 + let t_jsont : t Jsont.t = 933 + Jsont.Object.map ~kind:"t" 934 + (fun filename filesize -> { filename; filesize }) 935 + |> Jsont.Object.mem "filename" Jsont.string ~enc:(fun r -> r.filename) 936 + |> Jsont.Object.mem "filesize" Jsont.number ~enc:(fun r -> r.filesize) 937 + |> Jsont.Object.skip_unknown 938 + |> Jsont.Object.finish 939 + end 940 + 941 + module DatabaseBackupUploadDto = struct 942 + type t = { 943 + file : string option; 944 + } 945 + 946 + let t_jsont : t Jsont.t = 947 + Jsont.Object.map ~kind:"t" 948 + (fun file -> { file }) 949 + |> Jsont.Object.opt_mem "file" Jsont.string ~enc:(fun r -> r.file) 950 + |> Jsont.Object.skip_unknown 951 + |> Jsont.Object.finish 952 + end 953 + 954 + module DownloadArchiveInfo = struct 955 + type t = { 956 + asset_ids : string list; 957 + size : int; 958 + } 959 + 960 + let t_jsont : t Jsont.t = 961 + Jsont.Object.map ~kind:"t" 962 + (fun asset_ids size -> { asset_ids; size }) 963 + |> Jsont.Object.mem "assetIds" Jsont.(list Jsont.string) ~enc:(fun r -> r.asset_ids) 964 + |> Jsont.Object.mem "size" Jsont.int ~enc:(fun r -> r.size) 965 + |> Jsont.Object.skip_unknown 966 + |> Jsont.Object.finish 967 + end 968 + 969 + module DownloadInfoDto = struct 970 + type t = { 971 + album_id : string option; 972 + archive_size : int option; 973 + asset_ids : string list option; 974 + user_id : string option; 975 + } 976 + 977 + let t_jsont : t Jsont.t = 978 + Jsont.Object.map ~kind:"t" 979 + (fun album_id archive_size asset_ids user_id -> { album_id; archive_size; asset_ids; user_id }) 980 + |> Jsont.Object.opt_mem "albumId" Jsont.string ~enc:(fun r -> r.album_id) 981 + |> Jsont.Object.opt_mem "archiveSize" Jsont.int ~enc:(fun r -> r.archive_size) 982 + |> Jsont.Object.opt_mem "assetIds" Jsont.(list Jsont.string) ~enc:(fun r -> r.asset_ids) 983 + |> Jsont.Object.opt_mem "userId" Jsont.string ~enc:(fun r -> r.user_id) 984 + |> Jsont.Object.skip_unknown 985 + |> Jsont.Object.finish 986 + end 987 + 988 + module DownloadResponse = struct 989 + type t = { 990 + archive_size : int; 991 + include_embedded_videos : bool; 992 + } 993 + 994 + let t_jsont : t Jsont.t = 995 + Jsont.Object.map ~kind:"t" 996 + (fun archive_size include_embedded_videos -> { archive_size; include_embedded_videos }) 997 + |> Jsont.Object.mem "archiveSize" Jsont.int ~enc:(fun r -> r.archive_size) 998 + |> Jsont.Object.mem "includeEmbeddedVideos" Jsont.bool ~enc:(fun r -> r.include_embedded_videos) 999 + |> Jsont.Object.skip_unknown 1000 + |> Jsont.Object.finish 1001 + end 1002 + 1003 + module DownloadUpdate = struct 1004 + type t = { 1005 + archive_size : int option; 1006 + include_embedded_videos : bool option; 1007 + } 1008 + 1009 + let t_jsont : t Jsont.t = 1010 + Jsont.Object.map ~kind:"t" 1011 + (fun archive_size include_embedded_videos -> { archive_size; include_embedded_videos }) 1012 + |> Jsont.Object.opt_mem "archiveSize" Jsont.int ~enc:(fun r -> r.archive_size) 1013 + |> Jsont.Object.opt_mem "includeEmbeddedVideos" Jsont.bool ~enc:(fun r -> r.include_embedded_videos) 1014 + |> Jsont.Object.skip_unknown 1015 + |> Jsont.Object.finish 1016 + end 1017 + 1018 + module DuplicateDetectionConfig = struct 1019 + type t = { 1020 + enabled : bool; 1021 + max_distance : float; 1022 + } 1023 + 1024 + let t_jsont : t Jsont.t = 1025 + Jsont.Object.map ~kind:"t" 1026 + (fun enabled max_distance -> { enabled; max_distance }) 1027 + |> Jsont.Object.mem "enabled" Jsont.bool ~enc:(fun r -> r.enabled) 1028 + |> Jsont.Object.mem "maxDistance" Jsont.number ~enc:(fun r -> r.max_distance) 1029 + |> Jsont.Object.skip_unknown 1030 + |> Jsont.Object.finish 1031 + end 1032 + 1033 + module EmailNotificationsResponse = struct 1034 + type t = { 1035 + album_invite : bool; 1036 + album_update : bool; 1037 + enabled : bool; 1038 + } 1039 + 1040 + let t_jsont : t Jsont.t = 1041 + Jsont.Object.map ~kind:"t" 1042 + (fun album_invite album_update enabled -> { album_invite; album_update; enabled }) 1043 + |> Jsont.Object.mem "albumInvite" Jsont.bool ~enc:(fun r -> r.album_invite) 1044 + |> Jsont.Object.mem "albumUpdate" Jsont.bool ~enc:(fun r -> r.album_update) 1045 + |> Jsont.Object.mem "enabled" Jsont.bool ~enc:(fun r -> r.enabled) 1046 + |> Jsont.Object.skip_unknown 1047 + |> Jsont.Object.finish 1048 + end 1049 + 1050 + module EmailNotificationsUpdate = struct 1051 + type t = { 1052 + album_invite : bool option; 1053 + album_update : bool option; 1054 + enabled : bool option; 1055 + } 1056 + 1057 + let t_jsont : t Jsont.t = 1058 + Jsont.Object.map ~kind:"t" 1059 + (fun album_invite album_update enabled -> { album_invite; album_update; enabled }) 1060 + |> Jsont.Object.opt_mem "albumInvite" Jsont.bool ~enc:(fun r -> r.album_invite) 1061 + |> Jsont.Object.opt_mem "albumUpdate" Jsont.bool ~enc:(fun r -> r.album_update) 1062 + |> Jsont.Object.opt_mem "enabled" Jsont.bool ~enc:(fun r -> r.enabled) 1063 + |> Jsont.Object.skip_unknown 1064 + |> Jsont.Object.finish 1065 + end 1066 + 1067 + module ExifResponseDto = struct 1068 + type t = { 1069 + city : string option; 1070 + country : string option; 1071 + date_time_original : Ptime.t option; 1072 + description : string option; 1073 + exif_image_height : float option; 1074 + exif_image_width : float option; 1075 + exposure_time : string option; 1076 + f_number : float option; 1077 + file_size_in_byte : int64 option; 1078 + focal_length : float option; 1079 + iso : float option; 1080 + latitude : float option; 1081 + lens_model : string option; 1082 + longitude : float option; 1083 + make : string option; 1084 + model : string option; 1085 + modify_date : Ptime.t option; 1086 + orientation : string option; 1087 + projection_type : string option; 1088 + rating : float option; 1089 + state : string option; 1090 + time_zone : string option; 1091 + } 1092 + 1093 + let t_jsont : t Jsont.t = 1094 + Jsont.Object.map ~kind:"t" 1095 + (fun city country date_time_original description exif_image_height exif_image_width exposure_time f_number file_size_in_byte focal_length iso latitude lens_model longitude make model modify_date orientation projection_type rating state time_zone -> { city; country; date_time_original; description; exif_image_height; exif_image_width; exposure_time; f_number; file_size_in_byte; focal_length; iso; latitude; lens_model; longitude; make; model; modify_date; orientation; projection_type; rating; state; time_zone }) 1096 + |> Jsont.Object.opt_mem "city" Jsont.string ~enc:(fun r -> r.city) 1097 + |> Jsont.Object.opt_mem "country" Jsont.string ~enc:(fun r -> r.country) 1098 + |> Jsont.Object.opt_mem "dateTimeOriginal" Openapi.Runtime.ptime_jsont ~enc:(fun r -> r.date_time_original) 1099 + |> Jsont.Object.opt_mem "description" Jsont.string ~enc:(fun r -> r.description) 1100 + |> Jsont.Object.opt_mem "exifImageHeight" Jsont.number ~enc:(fun r -> r.exif_image_height) 1101 + |> Jsont.Object.opt_mem "exifImageWidth" Jsont.number ~enc:(fun r -> r.exif_image_width) 1102 + |> Jsont.Object.opt_mem "exposureTime" Jsont.string ~enc:(fun r -> r.exposure_time) 1103 + |> Jsont.Object.opt_mem "fNumber" Jsont.number ~enc:(fun r -> r.f_number) 1104 + |> Jsont.Object.opt_mem "fileSizeInByte" Jsont.int64 ~enc:(fun r -> r.file_size_in_byte) 1105 + |> Jsont.Object.opt_mem "focalLength" Jsont.number ~enc:(fun r -> r.focal_length) 1106 + |> Jsont.Object.opt_mem "iso" Jsont.number ~enc:(fun r -> r.iso) 1107 + |> Jsont.Object.opt_mem "latitude" Jsont.number ~enc:(fun r -> r.latitude) 1108 + |> Jsont.Object.opt_mem "lensModel" Jsont.string ~enc:(fun r -> r.lens_model) 1109 + |> Jsont.Object.opt_mem "longitude" Jsont.number ~enc:(fun r -> r.longitude) 1110 + |> Jsont.Object.opt_mem "make" Jsont.string ~enc:(fun r -> r.make) 1111 + |> Jsont.Object.opt_mem "model" Jsont.string ~enc:(fun r -> r.model) 1112 + |> Jsont.Object.opt_mem "modifyDate" Openapi.Runtime.ptime_jsont ~enc:(fun r -> r.modify_date) 1113 + |> Jsont.Object.opt_mem "orientation" Jsont.string ~enc:(fun r -> r.orientation) 1114 + |> Jsont.Object.opt_mem "projectionType" Jsont.string ~enc:(fun r -> r.projection_type) 1115 + |> Jsont.Object.opt_mem "rating" Jsont.number ~enc:(fun r -> r.rating) 1116 + |> Jsont.Object.opt_mem "state" Jsont.string ~enc:(fun r -> r.state) 1117 + |> Jsont.Object.opt_mem "timeZone" Jsont.string ~enc:(fun r -> r.time_zone) 1118 + |> Jsont.Object.skip_unknown 1119 + |> Jsont.Object.finish 1120 + end 1121 + 1122 + module FaceDto = struct 1123 + type t = { 1124 + id : string; 1125 + } 1126 + 1127 + let t_jsont : t Jsont.t = 1128 + Jsont.Object.map ~kind:"t" 1129 + (fun id -> { id }) 1130 + |> Jsont.Object.mem "id" Jsont.string ~enc:(fun r -> r.id) 1131 + |> Jsont.Object.skip_unknown 1132 + |> Jsont.Object.finish 1133 + end 1134 + 1135 + module FacialRecognitionConfig = struct 1136 + type t = { 1137 + enabled : bool; 1138 + max_distance : float; 1139 + min_faces : int; 1140 + min_score : float; 1141 + model_name : string; 1142 + } 1143 + 1144 + let t_jsont : t Jsont.t = 1145 + Jsont.Object.map ~kind:"t" 1146 + (fun enabled max_distance min_faces min_score model_name -> { enabled; max_distance; min_faces; min_score; model_name }) 1147 + |> Jsont.Object.mem "enabled" Jsont.bool ~enc:(fun r -> r.enabled) 1148 + |> Jsont.Object.mem "maxDistance" Jsont.number ~enc:(fun r -> r.max_distance) 1149 + |> Jsont.Object.mem "minFaces" Jsont.int ~enc:(fun r -> r.min_faces) 1150 + |> Jsont.Object.mem "minScore" Jsont.number ~enc:(fun r -> r.min_score) 1151 + |> Jsont.Object.mem "modelName" Jsont.string ~enc:(fun r -> r.model_name) 1152 + |> Jsont.Object.skip_unknown 1153 + |> Jsont.Object.finish 1154 + end 1155 + 1156 + module FoldersResponse = struct 1157 + type t = { 1158 + enabled : bool; 1159 + sidebar_web : bool; 1160 + } 1161 + 1162 + let t_jsont : t Jsont.t = 1163 + Jsont.Object.map ~kind:"t" 1164 + (fun enabled sidebar_web -> { enabled; sidebar_web }) 1165 + |> Jsont.Object.mem "enabled" Jsont.bool ~enc:(fun r -> r.enabled) 1166 + |> Jsont.Object.mem "sidebarWeb" Jsont.bool ~enc:(fun r -> r.sidebar_web) 1167 + |> Jsont.Object.skip_unknown 1168 + |> Jsont.Object.finish 1169 + end 1170 + 1171 + module FoldersUpdate = struct 1172 + type t = { 1173 + enabled : bool option; 1174 + sidebar_web : bool option; 1175 + } 1176 + 1177 + let t_jsont : t Jsont.t = 1178 + Jsont.Object.map ~kind:"t" 1179 + (fun enabled sidebar_web -> { enabled; sidebar_web }) 1180 + |> Jsont.Object.opt_mem "enabled" Jsont.bool ~enc:(fun r -> r.enabled) 1181 + |> Jsont.Object.opt_mem "sidebarWeb" Jsont.bool ~enc:(fun r -> r.sidebar_web) 1182 + |> Jsont.Object.skip_unknown 1183 + |> Jsont.Object.finish 1184 + end 1185 + 1186 + module ImageFormat = struct 1187 + type t = 1188 + | Jpeg 1189 + | Webp 1190 + 1191 + let t_jsont : t Jsont.t = 1192 + Jsont.map Jsont.string ~kind:"t" 1193 + ~dec:(function 1194 + | "jpeg" -> Jpeg 1195 + | "webp" -> Webp 1196 + | s -> Jsont.Error.msgf Jsont.Meta.none "Unknown t: %s" s) 1197 + ~enc:(function 1198 + | Jpeg -> "jpeg" 1199 + | Webp -> "webp") 1200 + end 1201 + 1202 + module JobName = struct 1203 + type t = 1204 + | Asset_delete 1205 + | Asset_delete_check 1206 + | Asset_detect_faces_queue_all 1207 + | Asset_detect_faces 1208 + | Asset_detect_duplicates_queue_all 1209 + | Asset_detect_duplicates 1210 + | Asset_edit_thumbnail_generation 1211 + | Asset_encode_video_queue_all 1212 + | Asset_encode_video 1213 + | Asset_empty_trash 1214 + | Asset_extract_metadata_queue_all 1215 + | Asset_extract_metadata 1216 + | Asset_file_migration 1217 + | Asset_generate_thumbnails_queue_all 1218 + | Asset_generate_thumbnails 1219 + | Audit_log_cleanup 1220 + | Audit_table_cleanup 1221 + | Database_backup 1222 + | Facial_recognition_queue_all 1223 + | Facial_recognition 1224 + | File_delete 1225 + | File_migration_queue_all 1226 + | Library_delete_check 1227 + | Library_delete 1228 + | Library_remove_asset 1229 + | Library_scan_assets_queue_all 1230 + | Library_sync_assets 1231 + | Library_sync_files_queue_all 1232 + | Library_sync_files 1233 + | Library_scan_queue_all 1234 + | Memory_cleanup 1235 + | Memory_generate 1236 + | Notifications_cleanup 1237 + | Notify_user_signup 1238 + | Notify_album_invite 1239 + | Notify_album_update 1240 + | User_delete 1241 + | User_delete_check 1242 + | User_sync_usage 1243 + | Person_cleanup 1244 + | Person_file_migration 1245 + | Person_generate_thumbnail 1246 + | Session_cleanup 1247 + | Send_mail 1248 + | Sidecar_queue_all 1249 + | Sidecar_check 1250 + | Sidecar_write 1251 + | Smart_search_queue_all 1252 + | Smart_search 1253 + | Storage_template_migration 1254 + | Storage_template_migration_single 1255 + | Tag_cleanup 1256 + | Version_check 1257 + | Ocr_queue_all 1258 + | Ocr 1259 + | Workflow_run 1260 + 1261 + let t_jsont : t Jsont.t = 1262 + Jsont.map Jsont.string ~kind:"t" 1263 + ~dec:(function 1264 + | "AssetDelete" -> Asset_delete 1265 + | "AssetDeleteCheck" -> Asset_delete_check 1266 + | "AssetDetectFacesQueueAll" -> Asset_detect_faces_queue_all 1267 + | "AssetDetectFaces" -> Asset_detect_faces 1268 + | "AssetDetectDuplicatesQueueAll" -> Asset_detect_duplicates_queue_all 1269 + | "AssetDetectDuplicates" -> Asset_detect_duplicates 1270 + | "AssetEditThumbnailGeneration" -> Asset_edit_thumbnail_generation 1271 + | "AssetEncodeVideoQueueAll" -> Asset_encode_video_queue_all 1272 + | "AssetEncodeVideo" -> Asset_encode_video 1273 + | "AssetEmptyTrash" -> Asset_empty_trash 1274 + | "AssetExtractMetadataQueueAll" -> Asset_extract_metadata_queue_all 1275 + | "AssetExtractMetadata" -> Asset_extract_metadata 1276 + | "AssetFileMigration" -> Asset_file_migration 1277 + | "AssetGenerateThumbnailsQueueAll" -> Asset_generate_thumbnails_queue_all 1278 + | "AssetGenerateThumbnails" -> Asset_generate_thumbnails 1279 + | "AuditLogCleanup" -> Audit_log_cleanup 1280 + | "AuditTableCleanup" -> Audit_table_cleanup 1281 + | "DatabaseBackup" -> Database_backup 1282 + | "FacialRecognitionQueueAll" -> Facial_recognition_queue_all 1283 + | "FacialRecognition" -> Facial_recognition 1284 + | "FileDelete" -> File_delete 1285 + | "FileMigrationQueueAll" -> File_migration_queue_all 1286 + | "LibraryDeleteCheck" -> Library_delete_check 1287 + | "LibraryDelete" -> Library_delete 1288 + | "LibraryRemoveAsset" -> Library_remove_asset 1289 + | "LibraryScanAssetsQueueAll" -> Library_scan_assets_queue_all 1290 + | "LibrarySyncAssets" -> Library_sync_assets 1291 + | "LibrarySyncFilesQueueAll" -> Library_sync_files_queue_all 1292 + | "LibrarySyncFiles" -> Library_sync_files 1293 + | "LibraryScanQueueAll" -> Library_scan_queue_all 1294 + | "MemoryCleanup" -> Memory_cleanup 1295 + | "MemoryGenerate" -> Memory_generate 1296 + | "NotificationsCleanup" -> Notifications_cleanup 1297 + | "NotifyUserSignup" -> Notify_user_signup 1298 + | "NotifyAlbumInvite" -> Notify_album_invite 1299 + | "NotifyAlbumUpdate" -> Notify_album_update 1300 + | "UserDelete" -> User_delete 1301 + | "UserDeleteCheck" -> User_delete_check 1302 + | "UserSyncUsage" -> User_sync_usage 1303 + | "PersonCleanup" -> Person_cleanup 1304 + | "PersonFileMigration" -> Person_file_migration 1305 + | "PersonGenerateThumbnail" -> Person_generate_thumbnail 1306 + | "SessionCleanup" -> Session_cleanup 1307 + | "SendMail" -> Send_mail 1308 + | "SidecarQueueAll" -> Sidecar_queue_all 1309 + | "SidecarCheck" -> Sidecar_check 1310 + | "SidecarWrite" -> Sidecar_write 1311 + | "SmartSearchQueueAll" -> Smart_search_queue_all 1312 + | "SmartSearch" -> Smart_search 1313 + | "StorageTemplateMigration" -> Storage_template_migration 1314 + | "StorageTemplateMigrationSingle" -> Storage_template_migration_single 1315 + | "TagCleanup" -> Tag_cleanup 1316 + | "VersionCheck" -> Version_check 1317 + | "OcrQueueAll" -> Ocr_queue_all 1318 + | "Ocr" -> Ocr 1319 + | "WorkflowRun" -> Workflow_run 1320 + | s -> Jsont.Error.msgf Jsont.Meta.none "Unknown t: %s" s) 1321 + ~enc:(function 1322 + | Asset_delete -> "AssetDelete" 1323 + | Asset_delete_check -> "AssetDeleteCheck" 1324 + | Asset_detect_faces_queue_all -> "AssetDetectFacesQueueAll" 1325 + | Asset_detect_faces -> "AssetDetectFaces" 1326 + | Asset_detect_duplicates_queue_all -> "AssetDetectDuplicatesQueueAll" 1327 + | Asset_detect_duplicates -> "AssetDetectDuplicates" 1328 + | Asset_edit_thumbnail_generation -> "AssetEditThumbnailGeneration" 1329 + | Asset_encode_video_queue_all -> "AssetEncodeVideoQueueAll" 1330 + | Asset_encode_video -> "AssetEncodeVideo" 1331 + | Asset_empty_trash -> "AssetEmptyTrash" 1332 + | Asset_extract_metadata_queue_all -> "AssetExtractMetadataQueueAll" 1333 + | Asset_extract_metadata -> "AssetExtractMetadata" 1334 + | Asset_file_migration -> "AssetFileMigration" 1335 + | Asset_generate_thumbnails_queue_all -> "AssetGenerateThumbnailsQueueAll" 1336 + | Asset_generate_thumbnails -> "AssetGenerateThumbnails" 1337 + | Audit_log_cleanup -> "AuditLogCleanup" 1338 + | Audit_table_cleanup -> "AuditTableCleanup" 1339 + | Database_backup -> "DatabaseBackup" 1340 + | Facial_recognition_queue_all -> "FacialRecognitionQueueAll" 1341 + | Facial_recognition -> "FacialRecognition" 1342 + | File_delete -> "FileDelete" 1343 + | File_migration_queue_all -> "FileMigrationQueueAll" 1344 + | Library_delete_check -> "LibraryDeleteCheck" 1345 + | Library_delete -> "LibraryDelete" 1346 + | Library_remove_asset -> "LibraryRemoveAsset" 1347 + | Library_scan_assets_queue_all -> "LibraryScanAssetsQueueAll" 1348 + | Library_sync_assets -> "LibrarySyncAssets" 1349 + | Library_sync_files_queue_all -> "LibrarySyncFilesQueueAll" 1350 + | Library_sync_files -> "LibrarySyncFiles" 1351 + | Library_scan_queue_all -> "LibraryScanQueueAll" 1352 + | Memory_cleanup -> "MemoryCleanup" 1353 + | Memory_generate -> "MemoryGenerate" 1354 + | Notifications_cleanup -> "NotificationsCleanup" 1355 + | Notify_user_signup -> "NotifyUserSignup" 1356 + | Notify_album_invite -> "NotifyAlbumInvite" 1357 + | Notify_album_update -> "NotifyAlbumUpdate" 1358 + | User_delete -> "UserDelete" 1359 + | User_delete_check -> "UserDeleteCheck" 1360 + | User_sync_usage -> "UserSyncUsage" 1361 + | Person_cleanup -> "PersonCleanup" 1362 + | Person_file_migration -> "PersonFileMigration" 1363 + | Person_generate_thumbnail -> "PersonGenerateThumbnail" 1364 + | Session_cleanup -> "SessionCleanup" 1365 + | Send_mail -> "SendMail" 1366 + | Sidecar_queue_all -> "SidecarQueueAll" 1367 + | Sidecar_check -> "SidecarCheck" 1368 + | Sidecar_write -> "SidecarWrite" 1369 + | Smart_search_queue_all -> "SmartSearchQueueAll" 1370 + | Smart_search -> "SmartSearch" 1371 + | Storage_template_migration -> "StorageTemplateMigration" 1372 + | Storage_template_migration_single -> "StorageTemplateMigrationSingle" 1373 + | Tag_cleanup -> "TagCleanup" 1374 + | Version_check -> "VersionCheck" 1375 + | Ocr_queue_all -> "OcrQueueAll" 1376 + | Ocr -> "Ocr" 1377 + | Workflow_run -> "WorkflowRun") 1378 + end 1379 + 1380 + module JobSettingsDto = struct 1381 + type t = { 1382 + concurrency : int; 1383 + } 1384 + 1385 + let t_jsont : t Jsont.t = 1386 + Jsont.Object.map ~kind:"t" 1387 + (fun concurrency -> { concurrency }) 1388 + |> Jsont.Object.mem "concurrency" Jsont.int ~enc:(fun r -> r.concurrency) 1389 + |> Jsont.Object.skip_unknown 1390 + |> Jsont.Object.finish 1391 + end 1392 + 1393 + module LibraryResponseDto = struct 1394 + type t = { 1395 + asset_count : int; 1396 + created_at : Ptime.t; 1397 + exclusion_patterns : string list; 1398 + id : string; 1399 + import_paths : string list; 1400 + name : string; 1401 + owner_id : string; 1402 + refreshed_at : Ptime.t; 1403 + updated_at : Ptime.t; 1404 + } 1405 + 1406 + let t_jsont : t Jsont.t = 1407 + Jsont.Object.map ~kind:"t" 1408 + (fun asset_count created_at exclusion_patterns id import_paths name owner_id refreshed_at updated_at -> { asset_count; created_at; exclusion_patterns; id; import_paths; name; owner_id; refreshed_at; updated_at }) 1409 + |> Jsont.Object.mem "assetCount" Jsont.int ~enc:(fun r -> r.asset_count) 1410 + |> Jsont.Object.mem "createdAt" Openapi.Runtime.ptime_jsont ~enc:(fun r -> r.created_at) 1411 + |> Jsont.Object.mem "exclusionPatterns" Jsont.(list Jsont.string) ~enc:(fun r -> r.exclusion_patterns) 1412 + |> Jsont.Object.mem "id" Jsont.string ~enc:(fun r -> r.id) 1413 + |> Jsont.Object.mem "importPaths" Jsont.(list Jsont.string) ~enc:(fun r -> r.import_paths) 1414 + |> Jsont.Object.mem "name" Jsont.string ~enc:(fun r -> r.name) 1415 + |> Jsont.Object.mem "ownerId" Jsont.string ~enc:(fun r -> r.owner_id) 1416 + |> Jsont.Object.mem "refreshedAt" Openapi.Runtime.ptime_jsont ~enc:(fun r -> r.refreshed_at) 1417 + |> Jsont.Object.mem "updatedAt" Openapi.Runtime.ptime_jsont ~enc:(fun r -> r.updated_at) 1418 + |> Jsont.Object.skip_unknown 1419 + |> Jsont.Object.finish 1420 + end 1421 + 1422 + module LibraryStatsResponseDto = struct 1423 + type t = { 1424 + photos : int; 1425 + total : int; 1426 + usage : int64; 1427 + videos : int; 1428 + } 1429 + 1430 + let t_jsont : t Jsont.t = 1431 + Jsont.Object.map ~kind:"t" 1432 + (fun photos total usage videos -> { photos; total; usage; videos }) 1433 + |> Jsont.Object.mem "photos" Jsont.int ~enc:(fun r -> r.photos) 1434 + |> Jsont.Object.mem "total" Jsont.int ~enc:(fun r -> r.total) 1435 + |> Jsont.Object.mem "usage" Jsont.int64 ~enc:(fun r -> r.usage) 1436 + |> Jsont.Object.mem "videos" Jsont.int ~enc:(fun r -> r.videos) 1437 + |> Jsont.Object.skip_unknown 1438 + |> Jsont.Object.finish 1439 + end 1440 + 1441 + module LicenseKeyDto = struct 1442 + type t = { 1443 + activation_key : string; 1444 + license_key : string; 1445 + } 1446 + 1447 + let t_jsont : t Jsont.t = 1448 + Jsont.Object.map ~kind:"t" 1449 + (fun activation_key license_key -> { activation_key; license_key }) 1450 + |> Jsont.Object.mem "activationKey" Jsont.string ~enc:(fun r -> r.activation_key) 1451 + |> Jsont.Object.mem "licenseKey" Jsont.string ~enc:(fun r -> r.license_key) 1452 + |> Jsont.Object.skip_unknown 1453 + |> Jsont.Object.finish 1454 + end 1455 + 1456 + module LicenseResponseDto = struct 1457 + type t = { 1458 + activated_at : Ptime.t; 1459 + activation_key : string; 1460 + license_key : string; 1461 + } 1462 + 1463 + let t_jsont : t Jsont.t = 1464 + Jsont.Object.map ~kind:"t" 1465 + (fun activated_at activation_key license_key -> { activated_at; activation_key; license_key }) 1466 + |> Jsont.Object.mem "activatedAt" Openapi.Runtime.ptime_jsont ~enc:(fun r -> r.activated_at) 1467 + |> Jsont.Object.mem "activationKey" Jsont.string ~enc:(fun r -> r.activation_key) 1468 + |> Jsont.Object.mem "licenseKey" Jsont.string ~enc:(fun r -> r.license_key) 1469 + |> Jsont.Object.skip_unknown 1470 + |> Jsont.Object.finish 1471 + end 1472 + 1473 + module LogLevel = struct 1474 + type t = 1475 + | Verbose 1476 + | Debug 1477 + | Log 1478 + | Warn 1479 + | Error 1480 + | Fatal 1481 + 1482 + let t_jsont : t Jsont.t = 1483 + Jsont.map Jsont.string ~kind:"t" 1484 + ~dec:(function 1485 + | "verbose" -> Verbose 1486 + | "debug" -> Debug 1487 + | "log" -> Log 1488 + | "warn" -> Warn 1489 + | "error" -> Error 1490 + | "fatal" -> Fatal 1491 + | s -> Jsont.Error.msgf Jsont.Meta.none "Unknown t: %s" s) 1492 + ~enc:(function 1493 + | Verbose -> "verbose" 1494 + | Debug -> "debug" 1495 + | Log -> "log" 1496 + | Warn -> "warn" 1497 + | Error -> "error" 1498 + | Fatal -> "fatal") 1499 + end 1500 + 1501 + module LoginCredentialDto = struct 1502 + type t = { 1503 + email : string; 1504 + password : string; 1505 + } 1506 + 1507 + let t_jsont : t Jsont.t = 1508 + Jsont.Object.map ~kind:"t" 1509 + (fun email password -> { email; password }) 1510 + |> Jsont.Object.mem "email" Jsont.string ~enc:(fun r -> r.email) 1511 + |> Jsont.Object.mem "password" Jsont.string ~enc:(fun r -> r.password) 1512 + |> Jsont.Object.skip_unknown 1513 + |> Jsont.Object.finish 1514 + end 1515 + 1516 + module LoginResponseDto = struct 1517 + type t = { 1518 + access_token : string; 1519 + is_admin : bool; 1520 + is_onboarded : bool; 1521 + name : string; 1522 + profile_image_path : string; 1523 + should_change_password : bool; 1524 + user_email : string; 1525 + user_id : string; 1526 + } 1527 + 1528 + let t_jsont : t Jsont.t = 1529 + Jsont.Object.map ~kind:"t" 1530 + (fun access_token is_admin is_onboarded name profile_image_path should_change_password user_email user_id -> { access_token; is_admin; is_onboarded; name; profile_image_path; should_change_password; user_email; user_id }) 1531 + |> Jsont.Object.mem "accessToken" Jsont.string ~enc:(fun r -> r.access_token) 1532 + |> Jsont.Object.mem "isAdmin" Jsont.bool ~enc:(fun r -> r.is_admin) 1533 + |> Jsont.Object.mem "isOnboarded" Jsont.bool ~enc:(fun r -> r.is_onboarded) 1534 + |> Jsont.Object.mem "name" Jsont.string ~enc:(fun r -> r.name) 1535 + |> Jsont.Object.mem "profileImagePath" Jsont.string ~enc:(fun r -> r.profile_image_path) 1536 + |> Jsont.Object.mem "shouldChangePassword" Jsont.bool ~enc:(fun r -> r.should_change_password) 1537 + |> Jsont.Object.mem "userEmail" Jsont.string ~enc:(fun r -> r.user_email) 1538 + |> Jsont.Object.mem "userId" Jsont.string ~enc:(fun r -> r.user_id) 1539 + |> Jsont.Object.skip_unknown 1540 + |> Jsont.Object.finish 1541 + end 1542 + 1543 + module LogoutResponseDto = struct 1544 + type t = { 1545 + redirect_uri : string; 1546 + successful : bool; 1547 + } 1548 + 1549 + let t_jsont : t Jsont.t = 1550 + Jsont.Object.map ~kind:"t" 1551 + (fun redirect_uri successful -> { redirect_uri; successful }) 1552 + |> Jsont.Object.mem "redirectUri" Jsont.string ~enc:(fun r -> r.redirect_uri) 1553 + |> Jsont.Object.mem "successful" Jsont.bool ~enc:(fun r -> r.successful) 1554 + |> Jsont.Object.skip_unknown 1555 + |> Jsont.Object.finish 1556 + end 1557 + 1558 + module MachineLearningAvailabilityChecksDto = struct 1559 + type t = { 1560 + enabled : bool; 1561 + interval : float; 1562 + timeout : float; 1563 + } 1564 + 1565 + let t_jsont : t Jsont.t = 1566 + Jsont.Object.map ~kind:"t" 1567 + (fun enabled interval timeout -> { enabled; interval; timeout }) 1568 + |> Jsont.Object.mem "enabled" Jsont.bool ~enc:(fun r -> r.enabled) 1569 + |> Jsont.Object.mem "interval" Jsont.number ~enc:(fun r -> r.interval) 1570 + |> Jsont.Object.mem "timeout" Jsont.number ~enc:(fun r -> r.timeout) 1571 + |> Jsont.Object.skip_unknown 1572 + |> Jsont.Object.finish 1573 + end 1574 + 1575 + module MaintenanceAction = struct 1576 + type t = 1577 + | Start 1578 + | End_ 1579 + | Select_database_restore 1580 + | Restore_database 1581 + 1582 + let t_jsont : t Jsont.t = 1583 + Jsont.map Jsont.string ~kind:"t" 1584 + ~dec:(function 1585 + | "start" -> Start 1586 + | "end" -> End_ 1587 + | "select_database_restore" -> Select_database_restore 1588 + | "restore_database" -> Restore_database 1589 + | s -> Jsont.Error.msgf Jsont.Meta.none "Unknown t: %s" s) 1590 + ~enc:(function 1591 + | Start -> "start" 1592 + | End_ -> "end" 1593 + | Select_database_restore -> "select_database_restore" 1594 + | Restore_database -> "restore_database") 1595 + end 1596 + 1597 + module MaintenanceAuthDto = struct 1598 + type t = { 1599 + username : string; 1600 + } 1601 + 1602 + let t_jsont : t Jsont.t = 1603 + Jsont.Object.map ~kind:"t" 1604 + (fun username -> { username }) 1605 + |> Jsont.Object.mem "username" Jsont.string ~enc:(fun r -> r.username) 1606 + |> Jsont.Object.skip_unknown 1607 + |> Jsont.Object.finish 1608 + end 1609 + 1610 + module MaintenanceLoginDto = struct 1611 + type t = { 1612 + token : string option; 1613 + } 1614 + 1615 + let t_jsont : t Jsont.t = 1616 + Jsont.Object.map ~kind:"t" 1617 + (fun token -> { token }) 1618 + |> Jsont.Object.opt_mem "token" Jsont.string ~enc:(fun r -> r.token) 1619 + |> Jsont.Object.skip_unknown 1620 + |> Jsont.Object.finish 1621 + end 1622 + 1623 + module ManualJobName = struct 1624 + type t = 1625 + | Person_cleanup 1626 + | Tag_cleanup 1627 + | User_cleanup 1628 + | Memory_cleanup 1629 + | Memory_create 1630 + | Backup_database 1631 + 1632 + let t_jsont : t Jsont.t = 1633 + Jsont.map Jsont.string ~kind:"t" 1634 + ~dec:(function 1635 + | "person-cleanup" -> Person_cleanup 1636 + | "tag-cleanup" -> Tag_cleanup 1637 + | "user-cleanup" -> User_cleanup 1638 + | "memory-cleanup" -> Memory_cleanup 1639 + | "memory-create" -> Memory_create 1640 + | "backup-database" -> Backup_database 1641 + | s -> Jsont.Error.msgf Jsont.Meta.none "Unknown t: %s" s) 1642 + ~enc:(function 1643 + | Person_cleanup -> "person-cleanup" 1644 + | Tag_cleanup -> "tag-cleanup" 1645 + | User_cleanup -> "user-cleanup" 1646 + | Memory_cleanup -> "memory-cleanup" 1647 + | Memory_create -> "memory-create" 1648 + | Backup_database -> "backup-database") 1649 + end 1650 + 1651 + module MapMarkerResponseDto = struct 1652 + type t = { 1653 + city : string; 1654 + country : string; 1655 + id : string; 1656 + lat : float; 1657 + lon : float; 1658 + state : string; 1659 + } 1660 + 1661 + let t_jsont : t Jsont.t = 1662 + Jsont.Object.map ~kind:"t" 1663 + (fun city country id lat lon state -> { city; country; id; lat; lon; state }) 1664 + |> Jsont.Object.mem "city" Jsont.string ~enc:(fun r -> r.city) 1665 + |> Jsont.Object.mem "country" Jsont.string ~enc:(fun r -> r.country) 1666 + |> Jsont.Object.mem "id" Jsont.string ~enc:(fun r -> r.id) 1667 + |> Jsont.Object.mem "lat" Jsont.number ~enc:(fun r -> r.lat) 1668 + |> Jsont.Object.mem "lon" Jsont.number ~enc:(fun r -> r.lon) 1669 + |> Jsont.Object.mem "state" Jsont.string ~enc:(fun r -> r.state) 1670 + |> Jsont.Object.skip_unknown 1671 + |> Jsont.Object.finish 1672 + end 1673 + 1674 + module MapReverseGeocodeResponseDto = struct 1675 + type t = { 1676 + city : string; 1677 + country : string; 1678 + state : string; 1679 + } 1680 + 1681 + let t_jsont : t Jsont.t = 1682 + Jsont.Object.map ~kind:"t" 1683 + (fun city country state -> { city; country; state }) 1684 + |> Jsont.Object.mem "city" Jsont.string ~enc:(fun r -> r.city) 1685 + |> Jsont.Object.mem "country" Jsont.string ~enc:(fun r -> r.country) 1686 + |> Jsont.Object.mem "state" Jsont.string ~enc:(fun r -> r.state) 1687 + |> Jsont.Object.skip_unknown 1688 + |> Jsont.Object.finish 1689 + end 1690 + 1691 + module MemoriesResponse = struct 1692 + type t = { 1693 + duration : int; 1694 + enabled : bool; 1695 + } 1696 + 1697 + let t_jsont : t Jsont.t = 1698 + Jsont.Object.map ~kind:"t" 1699 + (fun duration enabled -> { duration; enabled }) 1700 + |> Jsont.Object.mem "duration" Jsont.int ~enc:(fun r -> r.duration) 1701 + |> Jsont.Object.mem "enabled" Jsont.bool ~enc:(fun r -> r.enabled) 1702 + |> Jsont.Object.skip_unknown 1703 + |> Jsont.Object.finish 1704 + end 1705 + 1706 + module MemoriesUpdate = struct 1707 + type t = { 1708 + duration : int option; 1709 + enabled : bool option; 1710 + } 1711 + 1712 + let t_jsont : t Jsont.t = 1713 + Jsont.Object.map ~kind:"t" 1714 + (fun duration enabled -> { duration; enabled }) 1715 + |> Jsont.Object.opt_mem "duration" Jsont.int ~enc:(fun r -> r.duration) 1716 + |> Jsont.Object.opt_mem "enabled" Jsont.bool ~enc:(fun r -> r.enabled) 1717 + |> Jsont.Object.skip_unknown 1718 + |> Jsont.Object.finish 1719 + end 1720 + 1721 + module MemorySearchOrder = struct 1722 + type t = 1723 + | Asc 1724 + | Desc 1725 + | Random 1726 + 1727 + let t_jsont : t Jsont.t = 1728 + Jsont.map Jsont.string ~kind:"t" 1729 + ~dec:(function 1730 + | "asc" -> Asc 1731 + | "desc" -> Desc 1732 + | "random" -> Random 1733 + | s -> Jsont.Error.msgf Jsont.Meta.none "Unknown t: %s" s) 1734 + ~enc:(function 1735 + | Asc -> "asc" 1736 + | Desc -> "desc" 1737 + | Random -> "random") 1738 + end 1739 + 1740 + module MemoryStatisticsResponseDto = struct 1741 + type t = { 1742 + total : int; 1743 + } 1744 + 1745 + let t_jsont : t Jsont.t = 1746 + Jsont.Object.map ~kind:"t" 1747 + (fun total -> { total }) 1748 + |> Jsont.Object.mem "total" Jsont.int ~enc:(fun r -> r.total) 1749 + |> Jsont.Object.skip_unknown 1750 + |> Jsont.Object.finish 1751 + end 1752 + 1753 + module MemoryType = struct 1754 + type t = 1755 + | On_this_day 1756 + 1757 + let t_jsont : t Jsont.t = 1758 + Jsont.map Jsont.string ~kind:"t" 1759 + ~dec:(function 1760 + | "on_this_day" -> On_this_day 1761 + | s -> Jsont.Error.msgf Jsont.Meta.none "Unknown t: %s" s) 1762 + ~enc:(function 1763 + | On_this_day -> "on_this_day") 1764 + end 1765 + 1766 + module MemoryUpdateDto = struct 1767 + type t = { 1768 + is_saved : bool option; 1769 + memory_at : Ptime.t option; 1770 + seen_at : Ptime.t option; 1771 + } 1772 + 1773 + let t_jsont : t Jsont.t = 1774 + Jsont.Object.map ~kind:"t" 1775 + (fun is_saved memory_at seen_at -> { is_saved; memory_at; seen_at }) 1776 + |> Jsont.Object.opt_mem "isSaved" Jsont.bool ~enc:(fun r -> r.is_saved) 1777 + |> Jsont.Object.opt_mem "memoryAt" Openapi.Runtime.ptime_jsont ~enc:(fun r -> r.memory_at) 1778 + |> Jsont.Object.opt_mem "seenAt" Openapi.Runtime.ptime_jsont ~enc:(fun r -> r.seen_at) 1779 + |> Jsont.Object.skip_unknown 1780 + |> Jsont.Object.finish 1781 + end 1782 + 1783 + module MergePersonDto = struct 1784 + type t = { 1785 + ids : string list; 1786 + } 1787 + 1788 + let t_jsont : t Jsont.t = 1789 + Jsont.Object.map ~kind:"t" 1790 + (fun ids -> { ids }) 1791 + |> Jsont.Object.mem "ids" Jsont.(list Jsont.string) ~enc:(fun r -> r.ids) 1792 + |> Jsont.Object.skip_unknown 1793 + |> Jsont.Object.finish 1794 + end 1795 + 1796 + module MirrorAxis = struct 1797 + (** Axis to mirror along *) 1798 + type t = 1799 + | Horizontal 1800 + | Vertical 1801 + 1802 + let t_jsont : t Jsont.t = 1803 + Jsont.map Jsont.string ~kind:"t" 1804 + ~dec:(function 1805 + | "horizontal" -> Horizontal 1806 + | "vertical" -> Vertical 1807 + | s -> Jsont.Error.msgf Jsont.Meta.none "Unknown t: %s" s) 1808 + ~enc:(function 1809 + | Horizontal -> "horizontal" 1810 + | Vertical -> "vertical") 1811 + end 1812 + 1813 + module NotificationDeleteAllDto = struct 1814 + type t = { 1815 + ids : string list; 1816 + } 1817 + 1818 + let t_jsont : t Jsont.t = 1819 + Jsont.Object.map ~kind:"t" 1820 + (fun ids -> { ids }) 1821 + |> Jsont.Object.mem "ids" Jsont.(list Jsont.string) ~enc:(fun r -> r.ids) 1822 + |> Jsont.Object.skip_unknown 1823 + |> Jsont.Object.finish 1824 + end 1825 + 1826 + module NotificationLevel = struct 1827 + type t = 1828 + | Success 1829 + | Error 1830 + | Warning 1831 + | Info 1832 + 1833 + let t_jsont : t Jsont.t = 1834 + Jsont.map Jsont.string ~kind:"t" 1835 + ~dec:(function 1836 + | "success" -> Success 1837 + | "error" -> Error 1838 + | "warning" -> Warning 1839 + | "info" -> Info 1840 + | s -> Jsont.Error.msgf Jsont.Meta.none "Unknown t: %s" s) 1841 + ~enc:(function 1842 + | Success -> "success" 1843 + | Error -> "error" 1844 + | Warning -> "warning" 1845 + | Info -> "info") 1846 + end 1847 + 1848 + module NotificationType = struct 1849 + type t = 1850 + | Job_failed 1851 + | Backup_failed 1852 + | System_message 1853 + | Album_invite 1854 + | Album_update 1855 + | Custom 1856 + 1857 + let t_jsont : t Jsont.t = 1858 + Jsont.map Jsont.string ~kind:"t" 1859 + ~dec:(function 1860 + | "JobFailed" -> Job_failed 1861 + | "BackupFailed" -> Backup_failed 1862 + | "SystemMessage" -> System_message 1863 + | "AlbumInvite" -> Album_invite 1864 + | "AlbumUpdate" -> Album_update 1865 + | "Custom" -> Custom 1866 + | s -> Jsont.Error.msgf Jsont.Meta.none "Unknown t: %s" s) 1867 + ~enc:(function 1868 + | Job_failed -> "JobFailed" 1869 + | Backup_failed -> "BackupFailed" 1870 + | System_message -> "SystemMessage" 1871 + | Album_invite -> "AlbumInvite" 1872 + | Album_update -> "AlbumUpdate" 1873 + | Custom -> "Custom") 1874 + end 1875 + 1876 + module NotificationUpdateAllDto = struct 1877 + type t = { 1878 + ids : string list; 1879 + read_at : Ptime.t option; 1880 + } 1881 + 1882 + let t_jsont : t Jsont.t = 1883 + Jsont.Object.map ~kind:"t" 1884 + (fun ids read_at -> { ids; read_at }) 1885 + |> Jsont.Object.mem "ids" Jsont.(list Jsont.string) ~enc:(fun r -> r.ids) 1886 + |> Jsont.Object.opt_mem "readAt" Openapi.Runtime.ptime_jsont ~enc:(fun r -> r.read_at) 1887 + |> Jsont.Object.skip_unknown 1888 + |> Jsont.Object.finish 1889 + end 1890 + 1891 + module NotificationUpdateDto = struct 1892 + type t = { 1893 + read_at : Ptime.t option; 1894 + } 1895 + 1896 + let t_jsont : t Jsont.t = 1897 + Jsont.Object.map ~kind:"t" 1898 + (fun read_at -> { read_at }) 1899 + |> Jsont.Object.opt_mem "readAt" Openapi.Runtime.ptime_jsont ~enc:(fun r -> r.read_at) 1900 + |> Jsont.Object.skip_unknown 1901 + |> Jsont.Object.finish 1902 + end 1903 + 1904 + module OauthAuthorizeResponseDto = struct 1905 + type t = { 1906 + url : string; 1907 + } 1908 + 1909 + let t_jsont : t Jsont.t = 1910 + Jsont.Object.map ~kind:"t" 1911 + (fun url -> { url }) 1912 + |> Jsont.Object.mem "url" Jsont.string ~enc:(fun r -> r.url) 1913 + |> Jsont.Object.skip_unknown 1914 + |> Jsont.Object.finish 1915 + end 1916 + 1917 + module OauthCallbackDto = struct 1918 + type t = { 1919 + code_verifier : string option; 1920 + state : string option; 1921 + url : string; 1922 + } 1923 + 1924 + let t_jsont : t Jsont.t = 1925 + Jsont.Object.map ~kind:"t" 1926 + (fun code_verifier state url -> { code_verifier; state; url }) 1927 + |> Jsont.Object.opt_mem "codeVerifier" Jsont.string ~enc:(fun r -> r.code_verifier) 1928 + |> Jsont.Object.opt_mem "state" Jsont.string ~enc:(fun r -> r.state) 1929 + |> Jsont.Object.mem "url" Jsont.string ~enc:(fun r -> r.url) 1930 + |> Jsont.Object.skip_unknown 1931 + |> Jsont.Object.finish 1932 + end 1933 + 1934 + module OauthConfigDto = struct 1935 + type t = { 1936 + code_challenge : string option; 1937 + redirect_uri : string; 1938 + state : string option; 1939 + } 1940 + 1941 + let t_jsont : t Jsont.t = 1942 + Jsont.Object.map ~kind:"t" 1943 + (fun code_challenge redirect_uri state -> { code_challenge; redirect_uri; state }) 1944 + |> Jsont.Object.opt_mem "codeChallenge" Jsont.string ~enc:(fun r -> r.code_challenge) 1945 + |> Jsont.Object.mem "redirectUri" Jsont.string ~enc:(fun r -> r.redirect_uri) 1946 + |> Jsont.Object.opt_mem "state" Jsont.string ~enc:(fun r -> r.state) 1947 + |> Jsont.Object.skip_unknown 1948 + |> Jsont.Object.finish 1949 + end 1950 + 1951 + module OauthTokenEndpointAuthMethod = struct 1952 + type t = 1953 + | Client_secret_post 1954 + | Client_secret_basic 1955 + 1956 + let t_jsont : t Jsont.t = 1957 + Jsont.map Jsont.string ~kind:"t" 1958 + ~dec:(function 1959 + | "client_secret_post" -> Client_secret_post 1960 + | "client_secret_basic" -> Client_secret_basic 1961 + | s -> Jsont.Error.msgf Jsont.Meta.none "Unknown t: %s" s) 1962 + ~enc:(function 1963 + | Client_secret_post -> "client_secret_post" 1964 + | Client_secret_basic -> "client_secret_basic") 1965 + end 1966 + 1967 + module OcrConfig = struct 1968 + type t = { 1969 + enabled : bool; 1970 + max_resolution : int; 1971 + min_detection_score : float; 1972 + min_recognition_score : float; 1973 + model_name : string; 1974 + } 1975 + 1976 + let t_jsont : t Jsont.t = 1977 + Jsont.Object.map ~kind:"t" 1978 + (fun enabled max_resolution min_detection_score min_recognition_score model_name -> { enabled; max_resolution; min_detection_score; min_recognition_score; model_name }) 1979 + |> Jsont.Object.mem "enabled" Jsont.bool ~enc:(fun r -> r.enabled) 1980 + |> Jsont.Object.mem "maxResolution" Jsont.int ~enc:(fun r -> r.max_resolution) 1981 + |> Jsont.Object.mem "minDetectionScore" Jsont.number ~enc:(fun r -> r.min_detection_score) 1982 + |> Jsont.Object.mem "minRecognitionScore" Jsont.number ~enc:(fun r -> r.min_recognition_score) 1983 + |> Jsont.Object.mem "modelName" Jsont.string ~enc:(fun r -> r.model_name) 1984 + |> Jsont.Object.skip_unknown 1985 + |> Jsont.Object.finish 1986 + end 1987 + 1988 + module OnThisDayDto = struct 1989 + type t = { 1990 + year : float; 1991 + } 1992 + 1993 + let t_jsont : t Jsont.t = 1994 + Jsont.Object.map ~kind:"t" 1995 + (fun year -> { year }) 1996 + |> Jsont.Object.mem "year" Jsont.number ~enc:(fun r -> r.year) 1997 + |> Jsont.Object.skip_unknown 1998 + |> Jsont.Object.finish 1999 + end 2000 + 2001 + module OnboardingDto = struct 2002 + type t = { 2003 + is_onboarded : bool; 2004 + } 2005 + 2006 + let t_jsont : t Jsont.t = 2007 + Jsont.Object.map ~kind:"t" 2008 + (fun is_onboarded -> { is_onboarded }) 2009 + |> Jsont.Object.mem "isOnboarded" Jsont.bool ~enc:(fun r -> r.is_onboarded) 2010 + |> Jsont.Object.skip_unknown 2011 + |> Jsont.Object.finish 2012 + end 2013 + 2014 + module OnboardingResponseDto = struct 2015 + type t = { 2016 + is_onboarded : bool; 2017 + } 2018 + 2019 + let t_jsont : t Jsont.t = 2020 + Jsont.Object.map ~kind:"t" 2021 + (fun is_onboarded -> { is_onboarded }) 2022 + |> Jsont.Object.mem "isOnboarded" Jsont.bool ~enc:(fun r -> r.is_onboarded) 2023 + |> Jsont.Object.skip_unknown 2024 + |> Jsont.Object.finish 2025 + end 2026 + 2027 + module PartnerCreateDto = struct 2028 + type t = { 2029 + shared_with_id : string; 2030 + } 2031 + 2032 + let t_jsont : t Jsont.t = 2033 + Jsont.Object.map ~kind:"t" 2034 + (fun shared_with_id -> { shared_with_id }) 2035 + |> Jsont.Object.mem "sharedWithId" Jsont.string ~enc:(fun r -> r.shared_with_id) 2036 + |> Jsont.Object.skip_unknown 2037 + |> Jsont.Object.finish 2038 + end 2039 + 2040 + module PartnerDirection = struct 2041 + type t = 2042 + | Shared_by 2043 + | Shared_with 2044 + 2045 + let t_jsont : t Jsont.t = 2046 + Jsont.map Jsont.string ~kind:"t" 2047 + ~dec:(function 2048 + | "shared-by" -> Shared_by 2049 + | "shared-with" -> Shared_with 2050 + | s -> Jsont.Error.msgf Jsont.Meta.none "Unknown t: %s" s) 2051 + ~enc:(function 2052 + | Shared_by -> "shared-by" 2053 + | Shared_with -> "shared-with") 2054 + end 2055 + 2056 + module PartnerUpdateDto = struct 2057 + type t = { 2058 + in_timeline : bool; 2059 + } 2060 + 2061 + let t_jsont : t Jsont.t = 2062 + Jsont.Object.map ~kind:"t" 2063 + (fun in_timeline -> { in_timeline }) 2064 + |> Jsont.Object.mem "inTimeline" Jsont.bool ~enc:(fun r -> r.in_timeline) 2065 + |> Jsont.Object.skip_unknown 2066 + |> Jsont.Object.finish 2067 + end 2068 + 2069 + module PeopleResponse = struct 2070 + type t = { 2071 + enabled : bool; 2072 + sidebar_web : bool; 2073 + } 2074 + 2075 + let t_jsont : t Jsont.t = 2076 + Jsont.Object.map ~kind:"t" 2077 + (fun enabled sidebar_web -> { enabled; sidebar_web }) 2078 + |> Jsont.Object.mem "enabled" Jsont.bool ~enc:(fun r -> r.enabled) 2079 + |> Jsont.Object.mem "sidebarWeb" Jsont.bool ~enc:(fun r -> r.sidebar_web) 2080 + |> Jsont.Object.skip_unknown 2081 + |> Jsont.Object.finish 2082 + end 2083 + 2084 + module PeopleUpdate = struct 2085 + type t = { 2086 + enabled : bool option; 2087 + sidebar_web : bool option; 2088 + } 2089 + 2090 + let t_jsont : t Jsont.t = 2091 + Jsont.Object.map ~kind:"t" 2092 + (fun enabled sidebar_web -> { enabled; sidebar_web }) 2093 + |> Jsont.Object.opt_mem "enabled" Jsont.bool ~enc:(fun r -> r.enabled) 2094 + |> Jsont.Object.opt_mem "sidebarWeb" Jsont.bool ~enc:(fun r -> r.sidebar_web) 2095 + |> Jsont.Object.skip_unknown 2096 + |> Jsont.Object.finish 2097 + end 2098 + 2099 + module PeopleUpdateItem = struct 2100 + type t = { 2101 + birth_date : string option; (** Person date of birth. 2102 + Note: the mobile app cannot currently set the birth date to null. *) 2103 + color : string option; 2104 + feature_face_asset_id : string option; (** Asset is used to get the feature face thumbnail. *) 2105 + id : string; (** Person id. *) 2106 + is_favorite : bool option; 2107 + is_hidden : bool option; (** Person visibility *) 2108 + name : string option; (** Person name. *) 2109 + } 2110 + 2111 + let t_jsont : t Jsont.t = 2112 + Jsont.Object.map ~kind:"t" 2113 + (fun birth_date color feature_face_asset_id id is_favorite is_hidden name -> { birth_date; color; feature_face_asset_id; id; is_favorite; is_hidden; name }) 2114 + |> Jsont.Object.opt_mem "birthDate" Jsont.string ~enc:(fun r -> r.birth_date) 2115 + |> Jsont.Object.opt_mem "color" Jsont.string ~enc:(fun r -> r.color) 2116 + |> Jsont.Object.opt_mem "featureFaceAssetId" Jsont.string ~enc:(fun r -> r.feature_face_asset_id) 2117 + |> Jsont.Object.mem "id" Jsont.string ~enc:(fun r -> r.id) 2118 + |> Jsont.Object.opt_mem "isFavorite" Jsont.bool ~enc:(fun r -> r.is_favorite) 2119 + |> Jsont.Object.opt_mem "isHidden" Jsont.bool ~enc:(fun r -> r.is_hidden) 2120 + |> Jsont.Object.opt_mem "name" Jsont.string ~enc:(fun r -> r.name) 2121 + |> Jsont.Object.skip_unknown 2122 + |> Jsont.Object.finish 2123 + end 2124 + 2125 + module Permission = struct 2126 + type t = 2127 + | All 2128 + | Activity_create 2129 + | Activity_read 2130 + | Activity_update 2131 + | Activity_delete 2132 + | Activity_statistics 2133 + | Api_key_create 2134 + | Api_key_read 2135 + | Api_key_update 2136 + | Api_key_delete 2137 + | Asset_read 2138 + | Asset_update 2139 + | Asset_delete 2140 + | Asset_statistics 2141 + | Asset_share 2142 + | Asset_view 2143 + | Asset_download 2144 + | Asset_upload 2145 + | Asset_replace 2146 + | Asset_copy 2147 + | Asset_derive 2148 + | Asset_edit_get 2149 + | Asset_edit_create 2150 + | Asset_edit_delete 2151 + | Album_create 2152 + | Album_read 2153 + | Album_update 2154 + | Album_delete 2155 + | Album_statistics 2156 + | Album_share 2157 + | Album_download 2158 + | Album_asset_create 2159 + | Album_asset_delete 2160 + | Album_user_create 2161 + | Album_user_update 2162 + | Album_user_delete 2163 + | Auth_change_password 2164 + | Auth_device_delete 2165 + | Archive_read 2166 + | Backup_list 2167 + | Backup_download 2168 + | Backup_upload 2169 + | Backup_delete 2170 + | Duplicate_read 2171 + | Duplicate_delete 2172 + | Face_create 2173 + | Face_read 2174 + | Face_update 2175 + | Face_delete 2176 + | Folder_read 2177 + | Job_create 2178 + | Job_read 2179 + | Library_create 2180 + | Library_read 2181 + | Library_update 2182 + | Library_delete 2183 + | Library_statistics 2184 + | Timeline_read 2185 + | Timeline_download 2186 + | Maintenance 2187 + | Map_read 2188 + | Map_search 2189 + | Memory_create 2190 + | Memory_read 2191 + | Memory_update 2192 + | Memory_delete 2193 + | Memory_statistics 2194 + | Memory_asset_create 2195 + | Memory_asset_delete 2196 + | Notification_create 2197 + | Notification_read 2198 + | Notification_update 2199 + | Notification_delete 2200 + | Partner_create 2201 + | Partner_read 2202 + | Partner_update 2203 + | Partner_delete 2204 + | Person_create 2205 + | Person_read 2206 + | Person_update 2207 + | Person_delete 2208 + | Person_statistics 2209 + | Person_merge 2210 + | Person_reassign 2211 + | Pin_code_create 2212 + | Pin_code_update 2213 + | Pin_code_delete 2214 + | Plugin_create 2215 + | Plugin_read 2216 + | Plugin_update 2217 + | Plugin_delete 2218 + | Server_about 2219 + | Server_apk_links 2220 + | Server_storage 2221 + | Server_statistics 2222 + | Server_version_check 2223 + | Server_license_read 2224 + | Server_license_update 2225 + | Server_license_delete 2226 + | Session_create 2227 + | Session_read 2228 + | Session_update 2229 + | Session_delete 2230 + | Session_lock 2231 + | Shared_link_create 2232 + | Shared_link_read 2233 + | Shared_link_update 2234 + | Shared_link_delete 2235 + | Stack_create 2236 + | Stack_read 2237 + | Stack_update 2238 + | Stack_delete 2239 + | Sync_stream 2240 + | Sync_checkpoint_read 2241 + | Sync_checkpoint_update 2242 + | Sync_checkpoint_delete 2243 + | System_config_read 2244 + | System_config_update 2245 + | System_metadata_read 2246 + | System_metadata_update 2247 + | Tag_create 2248 + | Tag_read 2249 + | Tag_update 2250 + | Tag_delete 2251 + | Tag_asset 2252 + | User_read 2253 + | User_update 2254 + | User_license_create 2255 + | User_license_read 2256 + | User_license_update 2257 + | User_license_delete 2258 + | User_onboarding_read 2259 + | User_onboarding_update 2260 + | User_onboarding_delete 2261 + | User_preference_read 2262 + | User_preference_update 2263 + | User_profile_image_create 2264 + | User_profile_image_read 2265 + | User_profile_image_update 2266 + | User_profile_image_delete 2267 + | Queue_read 2268 + | Queue_update 2269 + | Queue_job_create 2270 + | Queue_job_read 2271 + | Queue_job_update 2272 + | Queue_job_delete 2273 + | Workflow_create 2274 + | Workflow_read 2275 + | Workflow_update 2276 + | Workflow_delete 2277 + | Admin_user_create 2278 + | Admin_user_read 2279 + | Admin_user_update 2280 + | Admin_user_delete 2281 + | Admin_session_read 2282 + | Admin_auth_unlink_all 2283 + 2284 + let t_jsont : t Jsont.t = 2285 + Jsont.map Jsont.string ~kind:"t" 2286 + ~dec:(function 2287 + | "all" -> All 2288 + | "activity.create" -> Activity_create 2289 + | "activity.read" -> Activity_read 2290 + | "activity.update" -> Activity_update 2291 + | "activity.delete" -> Activity_delete 2292 + | "activity.statistics" -> Activity_statistics 2293 + | "apiKey.create" -> Api_key_create 2294 + | "apiKey.read" -> Api_key_read 2295 + | "apiKey.update" -> Api_key_update 2296 + | "apiKey.delete" -> Api_key_delete 2297 + | "asset.read" -> Asset_read 2298 + | "asset.update" -> Asset_update 2299 + | "asset.delete" -> Asset_delete 2300 + | "asset.statistics" -> Asset_statistics 2301 + | "asset.share" -> Asset_share 2302 + | "asset.view" -> Asset_view 2303 + | "asset.download" -> Asset_download 2304 + | "asset.upload" -> Asset_upload 2305 + | "asset.replace" -> Asset_replace 2306 + | "asset.copy" -> Asset_copy 2307 + | "asset.derive" -> Asset_derive 2308 + | "asset.edit.get" -> Asset_edit_get 2309 + | "asset.edit.create" -> Asset_edit_create 2310 + | "asset.edit.delete" -> Asset_edit_delete 2311 + | "album.create" -> Album_create 2312 + | "album.read" -> Album_read 2313 + | "album.update" -> Album_update 2314 + | "album.delete" -> Album_delete 2315 + | "album.statistics" -> Album_statistics 2316 + | "album.share" -> Album_share 2317 + | "album.download" -> Album_download 2318 + | "albumAsset.create" -> Album_asset_create 2319 + | "albumAsset.delete" -> Album_asset_delete 2320 + | "albumUser.create" -> Album_user_create 2321 + | "albumUser.update" -> Album_user_update 2322 + | "albumUser.delete" -> Album_user_delete 2323 + | "auth.changePassword" -> Auth_change_password 2324 + | "authDevice.delete" -> Auth_device_delete 2325 + | "archive.read" -> Archive_read 2326 + | "backup.list" -> Backup_list 2327 + | "backup.download" -> Backup_download 2328 + | "backup.upload" -> Backup_upload 2329 + | "backup.delete" -> Backup_delete 2330 + | "duplicate.read" -> Duplicate_read 2331 + | "duplicate.delete" -> Duplicate_delete 2332 + | "face.create" -> Face_create 2333 + | "face.read" -> Face_read 2334 + | "face.update" -> Face_update 2335 + | "face.delete" -> Face_delete 2336 + | "folder.read" -> Folder_read 2337 + | "job.create" -> Job_create 2338 + | "job.read" -> Job_read 2339 + | "library.create" -> Library_create 2340 + | "library.read" -> Library_read 2341 + | "library.update" -> Library_update 2342 + | "library.delete" -> Library_delete 2343 + | "library.statistics" -> Library_statistics 2344 + | "timeline.read" -> Timeline_read 2345 + | "timeline.download" -> Timeline_download 2346 + | "maintenance" -> Maintenance 2347 + | "map.read" -> Map_read 2348 + | "map.search" -> Map_search 2349 + | "memory.create" -> Memory_create 2350 + | "memory.read" -> Memory_read 2351 + | "memory.update" -> Memory_update 2352 + | "memory.delete" -> Memory_delete 2353 + | "memory.statistics" -> Memory_statistics 2354 + | "memoryAsset.create" -> Memory_asset_create 2355 + | "memoryAsset.delete" -> Memory_asset_delete 2356 + | "notification.create" -> Notification_create 2357 + | "notification.read" -> Notification_read 2358 + | "notification.update" -> Notification_update 2359 + | "notification.delete" -> Notification_delete 2360 + | "partner.create" -> Partner_create 2361 + | "partner.read" -> Partner_read 2362 + | "partner.update" -> Partner_update 2363 + | "partner.delete" -> Partner_delete 2364 + | "person.create" -> Person_create 2365 + | "person.read" -> Person_read 2366 + | "person.update" -> Person_update 2367 + | "person.delete" -> Person_delete 2368 + | "person.statistics" -> Person_statistics 2369 + | "person.merge" -> Person_merge 2370 + | "person.reassign" -> Person_reassign 2371 + | "pinCode.create" -> Pin_code_create 2372 + | "pinCode.update" -> Pin_code_update 2373 + | "pinCode.delete" -> Pin_code_delete 2374 + | "plugin.create" -> Plugin_create 2375 + | "plugin.read" -> Plugin_read 2376 + | "plugin.update" -> Plugin_update 2377 + | "plugin.delete" -> Plugin_delete 2378 + | "server.about" -> Server_about 2379 + | "server.apkLinks" -> Server_apk_links 2380 + | "server.storage" -> Server_storage 2381 + | "server.statistics" -> Server_statistics 2382 + | "server.versionCheck" -> Server_version_check 2383 + | "serverLicense.read" -> Server_license_read 2384 + | "serverLicense.update" -> Server_license_update 2385 + | "serverLicense.delete" -> Server_license_delete 2386 + | "session.create" -> Session_create 2387 + | "session.read" -> Session_read 2388 + | "session.update" -> Session_update 2389 + | "session.delete" -> Session_delete 2390 + | "session.lock" -> Session_lock 2391 + | "sharedLink.create" -> Shared_link_create 2392 + | "sharedLink.read" -> Shared_link_read 2393 + | "sharedLink.update" -> Shared_link_update 2394 + | "sharedLink.delete" -> Shared_link_delete 2395 + | "stack.create" -> Stack_create 2396 + | "stack.read" -> Stack_read 2397 + | "stack.update" -> Stack_update 2398 + | "stack.delete" -> Stack_delete 2399 + | "sync.stream" -> Sync_stream 2400 + | "syncCheckpoint.read" -> Sync_checkpoint_read 2401 + | "syncCheckpoint.update" -> Sync_checkpoint_update 2402 + | "syncCheckpoint.delete" -> Sync_checkpoint_delete 2403 + | "systemConfig.read" -> System_config_read 2404 + | "systemConfig.update" -> System_config_update 2405 + | "systemMetadata.read" -> System_metadata_read 2406 + | "systemMetadata.update" -> System_metadata_update 2407 + | "tag.create" -> Tag_create 2408 + | "tag.read" -> Tag_read 2409 + | "tag.update" -> Tag_update 2410 + | "tag.delete" -> Tag_delete 2411 + | "tag.asset" -> Tag_asset 2412 + | "user.read" -> User_read 2413 + | "user.update" -> User_update 2414 + | "userLicense.create" -> User_license_create 2415 + | "userLicense.read" -> User_license_read 2416 + | "userLicense.update" -> User_license_update 2417 + | "userLicense.delete" -> User_license_delete 2418 + | "userOnboarding.read" -> User_onboarding_read 2419 + | "userOnboarding.update" -> User_onboarding_update 2420 + | "userOnboarding.delete" -> User_onboarding_delete 2421 + | "userPreference.read" -> User_preference_read 2422 + | "userPreference.update" -> User_preference_update 2423 + | "userProfileImage.create" -> User_profile_image_create 2424 + | "userProfileImage.read" -> User_profile_image_read 2425 + | "userProfileImage.update" -> User_profile_image_update 2426 + | "userProfileImage.delete" -> User_profile_image_delete 2427 + | "queue.read" -> Queue_read 2428 + | "queue.update" -> Queue_update 2429 + | "queueJob.create" -> Queue_job_create 2430 + | "queueJob.read" -> Queue_job_read 2431 + | "queueJob.update" -> Queue_job_update 2432 + | "queueJob.delete" -> Queue_job_delete 2433 + | "workflow.create" -> Workflow_create 2434 + | "workflow.read" -> Workflow_read 2435 + | "workflow.update" -> Workflow_update 2436 + | "workflow.delete" -> Workflow_delete 2437 + | "adminUser.create" -> Admin_user_create 2438 + | "adminUser.read" -> Admin_user_read 2439 + | "adminUser.update" -> Admin_user_update 2440 + | "adminUser.delete" -> Admin_user_delete 2441 + | "adminSession.read" -> Admin_session_read 2442 + | "adminAuth.unlinkAll" -> Admin_auth_unlink_all 2443 + | s -> Jsont.Error.msgf Jsont.Meta.none "Unknown t: %s" s) 2444 + ~enc:(function 2445 + | All -> "all" 2446 + | Activity_create -> "activity.create" 2447 + | Activity_read -> "activity.read" 2448 + | Activity_update -> "activity.update" 2449 + | Activity_delete -> "activity.delete" 2450 + | Activity_statistics -> "activity.statistics" 2451 + | Api_key_create -> "apiKey.create" 2452 + | Api_key_read -> "apiKey.read" 2453 + | Api_key_update -> "apiKey.update" 2454 + | Api_key_delete -> "apiKey.delete" 2455 + | Asset_read -> "asset.read" 2456 + | Asset_update -> "asset.update" 2457 + | Asset_delete -> "asset.delete" 2458 + | Asset_statistics -> "asset.statistics" 2459 + | Asset_share -> "asset.share" 2460 + | Asset_view -> "asset.view" 2461 + | Asset_download -> "asset.download" 2462 + | Asset_upload -> "asset.upload" 2463 + | Asset_replace -> "asset.replace" 2464 + | Asset_copy -> "asset.copy" 2465 + | Asset_derive -> "asset.derive" 2466 + | Asset_edit_get -> "asset.edit.get" 2467 + | Asset_edit_create -> "asset.edit.create" 2468 + | Asset_edit_delete -> "asset.edit.delete" 2469 + | Album_create -> "album.create" 2470 + | Album_read -> "album.read" 2471 + | Album_update -> "album.update" 2472 + | Album_delete -> "album.delete" 2473 + | Album_statistics -> "album.statistics" 2474 + | Album_share -> "album.share" 2475 + | Album_download -> "album.download" 2476 + | Album_asset_create -> "albumAsset.create" 2477 + | Album_asset_delete -> "albumAsset.delete" 2478 + | Album_user_create -> "albumUser.create" 2479 + | Album_user_update -> "albumUser.update" 2480 + | Album_user_delete -> "albumUser.delete" 2481 + | Auth_change_password -> "auth.changePassword" 2482 + | Auth_device_delete -> "authDevice.delete" 2483 + | Archive_read -> "archive.read" 2484 + | Backup_list -> "backup.list" 2485 + | Backup_download -> "backup.download" 2486 + | Backup_upload -> "backup.upload" 2487 + | Backup_delete -> "backup.delete" 2488 + | Duplicate_read -> "duplicate.read" 2489 + | Duplicate_delete -> "duplicate.delete" 2490 + | Face_create -> "face.create" 2491 + | Face_read -> "face.read" 2492 + | Face_update -> "face.update" 2493 + | Face_delete -> "face.delete" 2494 + | Folder_read -> "folder.read" 2495 + | Job_create -> "job.create" 2496 + | Job_read -> "job.read" 2497 + | Library_create -> "library.create" 2498 + | Library_read -> "library.read" 2499 + | Library_update -> "library.update" 2500 + | Library_delete -> "library.delete" 2501 + | Library_statistics -> "library.statistics" 2502 + | Timeline_read -> "timeline.read" 2503 + | Timeline_download -> "timeline.download" 2504 + | Maintenance -> "maintenance" 2505 + | Map_read -> "map.read" 2506 + | Map_search -> "map.search" 2507 + | Memory_create -> "memory.create" 2508 + | Memory_read -> "memory.read" 2509 + | Memory_update -> "memory.update" 2510 + | Memory_delete -> "memory.delete" 2511 + | Memory_statistics -> "memory.statistics" 2512 + | Memory_asset_create -> "memoryAsset.create" 2513 + | Memory_asset_delete -> "memoryAsset.delete" 2514 + | Notification_create -> "notification.create" 2515 + | Notification_read -> "notification.read" 2516 + | Notification_update -> "notification.update" 2517 + | Notification_delete -> "notification.delete" 2518 + | Partner_create -> "partner.create" 2519 + | Partner_read -> "partner.read" 2520 + | Partner_update -> "partner.update" 2521 + | Partner_delete -> "partner.delete" 2522 + | Person_create -> "person.create" 2523 + | Person_read -> "person.read" 2524 + | Person_update -> "person.update" 2525 + | Person_delete -> "person.delete" 2526 + | Person_statistics -> "person.statistics" 2527 + | Person_merge -> "person.merge" 2528 + | Person_reassign -> "person.reassign" 2529 + | Pin_code_create -> "pinCode.create" 2530 + | Pin_code_update -> "pinCode.update" 2531 + | Pin_code_delete -> "pinCode.delete" 2532 + | Plugin_create -> "plugin.create" 2533 + | Plugin_read -> "plugin.read" 2534 + | Plugin_update -> "plugin.update" 2535 + | Plugin_delete -> "plugin.delete" 2536 + | Server_about -> "server.about" 2537 + | Server_apk_links -> "server.apkLinks" 2538 + | Server_storage -> "server.storage" 2539 + | Server_statistics -> "server.statistics" 2540 + | Server_version_check -> "server.versionCheck" 2541 + | Server_license_read -> "serverLicense.read" 2542 + | Server_license_update -> "serverLicense.update" 2543 + | Server_license_delete -> "serverLicense.delete" 2544 + | Session_create -> "session.create" 2545 + | Session_read -> "session.read" 2546 + | Session_update -> "session.update" 2547 + | Session_delete -> "session.delete" 2548 + | Session_lock -> "session.lock" 2549 + | Shared_link_create -> "sharedLink.create" 2550 + | Shared_link_read -> "sharedLink.read" 2551 + | Shared_link_update -> "sharedLink.update" 2552 + | Shared_link_delete -> "sharedLink.delete" 2553 + | Stack_create -> "stack.create" 2554 + | Stack_read -> "stack.read" 2555 + | Stack_update -> "stack.update" 2556 + | Stack_delete -> "stack.delete" 2557 + | Sync_stream -> "sync.stream" 2558 + | Sync_checkpoint_read -> "syncCheckpoint.read" 2559 + | Sync_checkpoint_update -> "syncCheckpoint.update" 2560 + | Sync_checkpoint_delete -> "syncCheckpoint.delete" 2561 + | System_config_read -> "systemConfig.read" 2562 + | System_config_update -> "systemConfig.update" 2563 + | System_metadata_read -> "systemMetadata.read" 2564 + | System_metadata_update -> "systemMetadata.update" 2565 + | Tag_create -> "tag.create" 2566 + | Tag_read -> "tag.read" 2567 + | Tag_update -> "tag.update" 2568 + | Tag_delete -> "tag.delete" 2569 + | Tag_asset -> "tag.asset" 2570 + | User_read -> "user.read" 2571 + | User_update -> "user.update" 2572 + | User_license_create -> "userLicense.create" 2573 + | User_license_read -> "userLicense.read" 2574 + | User_license_update -> "userLicense.update" 2575 + | User_license_delete -> "userLicense.delete" 2576 + | User_onboarding_read -> "userOnboarding.read" 2577 + | User_onboarding_update -> "userOnboarding.update" 2578 + | User_onboarding_delete -> "userOnboarding.delete" 2579 + | User_preference_read -> "userPreference.read" 2580 + | User_preference_update -> "userPreference.update" 2581 + | User_profile_image_create -> "userProfileImage.create" 2582 + | User_profile_image_read -> "userProfileImage.read" 2583 + | User_profile_image_update -> "userProfileImage.update" 2584 + | User_profile_image_delete -> "userProfileImage.delete" 2585 + | Queue_read -> "queue.read" 2586 + | Queue_update -> "queue.update" 2587 + | Queue_job_create -> "queueJob.create" 2588 + | Queue_job_read -> "queueJob.read" 2589 + | Queue_job_update -> "queueJob.update" 2590 + | Queue_job_delete -> "queueJob.delete" 2591 + | Workflow_create -> "workflow.create" 2592 + | Workflow_read -> "workflow.read" 2593 + | Workflow_update -> "workflow.update" 2594 + | Workflow_delete -> "workflow.delete" 2595 + | Admin_user_create -> "adminUser.create" 2596 + | Admin_user_read -> "adminUser.read" 2597 + | Admin_user_update -> "adminUser.update" 2598 + | Admin_user_delete -> "adminUser.delete" 2599 + | Admin_session_read -> "adminSession.read" 2600 + | Admin_auth_unlink_all -> "adminAuth.unlinkAll") 2601 + end 2602 + 2603 + module PersonCreateDto = struct 2604 + type t = { 2605 + birth_date : string option; (** Person date of birth. 2606 + Note: the mobile app cannot currently set the birth date to null. *) 2607 + color : string option; 2608 + is_favorite : bool option; 2609 + is_hidden : bool option; (** Person visibility *) 2610 + name : string option; (** Person name. *) 2611 + } 2612 + 2613 + let t_jsont : t Jsont.t = 2614 + Jsont.Object.map ~kind:"t" 2615 + (fun birth_date color is_favorite is_hidden name -> { birth_date; color; is_favorite; is_hidden; name }) 2616 + |> Jsont.Object.opt_mem "birthDate" Jsont.string ~enc:(fun r -> r.birth_date) 2617 + |> Jsont.Object.opt_mem "color" Jsont.string ~enc:(fun r -> r.color) 2618 + |> Jsont.Object.opt_mem "isFavorite" Jsont.bool ~enc:(fun r -> r.is_favorite) 2619 + |> Jsont.Object.opt_mem "isHidden" Jsont.bool ~enc:(fun r -> r.is_hidden) 2620 + |> Jsont.Object.opt_mem "name" Jsont.string ~enc:(fun r -> r.name) 2621 + |> Jsont.Object.skip_unknown 2622 + |> Jsont.Object.finish 2623 + end 2624 + 2625 + module PersonResponseDto = struct 2626 + type t = { 2627 + birth_date : string; 2628 + color : string option; 2629 + id : string; 2630 + is_favorite : bool option; 2631 + is_hidden : bool; 2632 + name : string; 2633 + thumbnail_path : string; 2634 + updated_at : Ptime.t option; 2635 + } 2636 + 2637 + let t_jsont : t Jsont.t = 2638 + Jsont.Object.map ~kind:"t" 2639 + (fun birth_date color id is_favorite is_hidden name thumbnail_path updated_at -> { birth_date; color; id; is_favorite; is_hidden; name; thumbnail_path; updated_at }) 2640 + |> Jsont.Object.mem "birthDate" Jsont.string ~enc:(fun r -> r.birth_date) 2641 + |> Jsont.Object.opt_mem "color" Jsont.string ~enc:(fun r -> r.color) 2642 + |> Jsont.Object.mem "id" Jsont.string ~enc:(fun r -> r.id) 2643 + |> Jsont.Object.opt_mem "isFavorite" Jsont.bool ~enc:(fun r -> r.is_favorite) 2644 + |> Jsont.Object.mem "isHidden" Jsont.bool ~enc:(fun r -> r.is_hidden) 2645 + |> Jsont.Object.mem "name" Jsont.string ~enc:(fun r -> r.name) 2646 + |> Jsont.Object.mem "thumbnailPath" Jsont.string ~enc:(fun r -> r.thumbnail_path) 2647 + |> Jsont.Object.opt_mem "updatedAt" Openapi.Runtime.ptime_jsont ~enc:(fun r -> r.updated_at) 2648 + |> Jsont.Object.skip_unknown 2649 + |> Jsont.Object.finish 2650 + end 2651 + 2652 + module PersonStatisticsResponseDto = struct 2653 + type t = { 2654 + assets : int; 2655 + } 2656 + 2657 + let t_jsont : t Jsont.t = 2658 + Jsont.Object.map ~kind:"t" 2659 + (fun assets -> { assets }) 2660 + |> Jsont.Object.mem "assets" Jsont.int ~enc:(fun r -> r.assets) 2661 + |> Jsont.Object.skip_unknown 2662 + |> Jsont.Object.finish 2663 + end 2664 + 2665 + module PersonUpdateDto = struct 2666 + type t = { 2667 + birth_date : string option; (** Person date of birth. 2668 + Note: the mobile app cannot currently set the birth date to null. *) 2669 + color : string option; 2670 + feature_face_asset_id : string option; (** Asset is used to get the feature face thumbnail. *) 2671 + is_favorite : bool option; 2672 + is_hidden : bool option; (** Person visibility *) 2673 + name : string option; (** Person name. *) 2674 + } 2675 + 2676 + let t_jsont : t Jsont.t = 2677 + Jsont.Object.map ~kind:"t" 2678 + (fun birth_date color feature_face_asset_id is_favorite is_hidden name -> { birth_date; color; feature_face_asset_id; is_favorite; is_hidden; name }) 2679 + |> Jsont.Object.opt_mem "birthDate" Jsont.string ~enc:(fun r -> r.birth_date) 2680 + |> Jsont.Object.opt_mem "color" Jsont.string ~enc:(fun r -> r.color) 2681 + |> Jsont.Object.opt_mem "featureFaceAssetId" Jsont.string ~enc:(fun r -> r.feature_face_asset_id) 2682 + |> Jsont.Object.opt_mem "isFavorite" Jsont.bool ~enc:(fun r -> r.is_favorite) 2683 + |> Jsont.Object.opt_mem "isHidden" Jsont.bool ~enc:(fun r -> r.is_hidden) 2684 + |> Jsont.Object.opt_mem "name" Jsont.string ~enc:(fun r -> r.name) 2685 + |> Jsont.Object.skip_unknown 2686 + |> Jsont.Object.finish 2687 + end 2688 + 2689 + module PinCodeChangeDto = struct 2690 + type t = { 2691 + new_pin_code : string; 2692 + password : string option; 2693 + pin_code : string option; 2694 + } 2695 + 2696 + let t_jsont : t Jsont.t = 2697 + Jsont.Object.map ~kind:"t" 2698 + (fun new_pin_code password pin_code -> { new_pin_code; password; pin_code }) 2699 + |> Jsont.Object.mem "newPinCode" Jsont.string ~enc:(fun r -> r.new_pin_code) 2700 + |> Jsont.Object.opt_mem "password" Jsont.string ~enc:(fun r -> r.password) 2701 + |> Jsont.Object.opt_mem "pinCode" Jsont.string ~enc:(fun r -> r.pin_code) 2702 + |> Jsont.Object.skip_unknown 2703 + |> Jsont.Object.finish 2704 + end 2705 + 2706 + module PinCodeResetDto = struct 2707 + type t = { 2708 + password : string option; 2709 + pin_code : string option; 2710 + } 2711 + 2712 + let t_jsont : t Jsont.t = 2713 + Jsont.Object.map ~kind:"t" 2714 + (fun password pin_code -> { password; pin_code }) 2715 + |> Jsont.Object.opt_mem "password" Jsont.string ~enc:(fun r -> r.password) 2716 + |> Jsont.Object.opt_mem "pinCode" Jsont.string ~enc:(fun r -> r.pin_code) 2717 + |> Jsont.Object.skip_unknown 2718 + |> Jsont.Object.finish 2719 + end 2720 + 2721 + module PinCodeSetupDto = struct 2722 + type t = { 2723 + pin_code : string; 2724 + } 2725 + 2726 + let t_jsont : t Jsont.t = 2727 + Jsont.Object.map ~kind:"t" 2728 + (fun pin_code -> { pin_code }) 2729 + |> Jsont.Object.mem "pinCode" Jsont.string ~enc:(fun r -> r.pin_code) 2730 + |> Jsont.Object.skip_unknown 2731 + |> Jsont.Object.finish 2732 + end 2733 + 2734 + module PlacesResponseDto = struct 2735 + type t = { 2736 + admin1name : string option; 2737 + admin2name : string option; 2738 + latitude : float; 2739 + longitude : float; 2740 + name : string; 2741 + } 2742 + 2743 + let t_jsont : t Jsont.t = 2744 + Jsont.Object.map ~kind:"t" 2745 + (fun admin1name admin2name latitude longitude name -> { admin1name; admin2name; latitude; longitude; name }) 2746 + |> Jsont.Object.opt_mem "admin1name" Jsont.string ~enc:(fun r -> r.admin1name) 2747 + |> Jsont.Object.opt_mem "admin2name" Jsont.string ~enc:(fun r -> r.admin2name) 2748 + |> Jsont.Object.mem "latitude" Jsont.number ~enc:(fun r -> r.latitude) 2749 + |> Jsont.Object.mem "longitude" Jsont.number ~enc:(fun r -> r.longitude) 2750 + |> Jsont.Object.mem "name" Jsont.string ~enc:(fun r -> r.name) 2751 + |> Jsont.Object.skip_unknown 2752 + |> Jsont.Object.finish 2753 + end 2754 + 2755 + module PluginContextType = struct 2756 + type t = 2757 + | Asset 2758 + | Album 2759 + | Person 2760 + 2761 + let t_jsont : t Jsont.t = 2762 + Jsont.map Jsont.string ~kind:"t" 2763 + ~dec:(function 2764 + | "asset" -> Asset 2765 + | "album" -> Album 2766 + | "person" -> Person 2767 + | s -> Jsont.Error.msgf Jsont.Meta.none "Unknown t: %s" s) 2768 + ~enc:(function 2769 + | Asset -> "asset" 2770 + | Album -> "album" 2771 + | Person -> "person") 2772 + end 2773 + 2774 + module PluginTriggerType = struct 2775 + type t = 2776 + | Asset_create 2777 + | Person_recognized 2778 + 2779 + let t_jsont : t Jsont.t = 2780 + Jsont.map Jsont.string ~kind:"t" 2781 + ~dec:(function 2782 + | "AssetCreate" -> Asset_create 2783 + | "PersonRecognized" -> Person_recognized 2784 + | s -> Jsont.Error.msgf Jsont.Meta.none "Unknown t: %s" s) 2785 + ~enc:(function 2786 + | Asset_create -> "AssetCreate" 2787 + | Person_recognized -> "PersonRecognized") 2788 + end 2789 + 2790 + module PurchaseResponse = struct 2791 + type t = { 2792 + hide_buy_button_until : string; 2793 + show_support_badge : bool; 2794 + } 2795 + 2796 + let t_jsont : t Jsont.t = 2797 + Jsont.Object.map ~kind:"t" 2798 + (fun hide_buy_button_until show_support_badge -> { hide_buy_button_until; show_support_badge }) 2799 + |> Jsont.Object.mem "hideBuyButtonUntil" Jsont.string ~enc:(fun r -> r.hide_buy_button_until) 2800 + |> Jsont.Object.mem "showSupportBadge" Jsont.bool ~enc:(fun r -> r.show_support_badge) 2801 + |> Jsont.Object.skip_unknown 2802 + |> Jsont.Object.finish 2803 + end 2804 + 2805 + module PurchaseUpdate = struct 2806 + type t = { 2807 + hide_buy_button_until : string option; 2808 + show_support_badge : bool option; 2809 + } 2810 + 2811 + let t_jsont : t Jsont.t = 2812 + Jsont.Object.map ~kind:"t" 2813 + (fun hide_buy_button_until show_support_badge -> { hide_buy_button_until; show_support_badge }) 2814 + |> Jsont.Object.opt_mem "hideBuyButtonUntil" Jsont.string ~enc:(fun r -> r.hide_buy_button_until) 2815 + |> Jsont.Object.opt_mem "showSupportBadge" Jsont.bool ~enc:(fun r -> r.show_support_badge) 2816 + |> Jsont.Object.skip_unknown 2817 + |> Jsont.Object.finish 2818 + end 2819 + 2820 + module QueueCommand = struct 2821 + type t = 2822 + | Start 2823 + | Pause 2824 + | Resume 2825 + | Empty 2826 + | Clear_failed 2827 + 2828 + let t_jsont : t Jsont.t = 2829 + Jsont.map Jsont.string ~kind:"t" 2830 + ~dec:(function 2831 + | "start" -> Start 2832 + | "pause" -> Pause 2833 + | "resume" -> Resume 2834 + | "empty" -> Empty 2835 + | "clear-failed" -> Clear_failed 2836 + | s -> Jsont.Error.msgf Jsont.Meta.none "Unknown t: %s" s) 2837 + ~enc:(function 2838 + | Start -> "start" 2839 + | Pause -> "pause" 2840 + | Resume -> "resume" 2841 + | Empty -> "empty" 2842 + | Clear_failed -> "clear-failed") 2843 + end 2844 + 2845 + module QueueDeleteDto = struct 2846 + type t = { 2847 + failed : bool option; (** If true, will also remove failed jobs from the queue. *) 2848 + } 2849 + 2850 + let t_jsont : t Jsont.t = 2851 + Jsont.Object.map ~kind:"t" 2852 + (fun failed -> { failed }) 2853 + |> Jsont.Object.opt_mem "failed" Jsont.bool ~enc:(fun r -> r.failed) 2854 + |> Jsont.Object.skip_unknown 2855 + |> Jsont.Object.finish 2856 + end 2857 + 2858 + module QueueJobStatus = struct 2859 + type t = 2860 + | Active 2861 + | Failed 2862 + | Completed 2863 + | Delayed 2864 + | Waiting 2865 + | Paused 2866 + 2867 + let t_jsont : t Jsont.t = 2868 + Jsont.map Jsont.string ~kind:"t" 2869 + ~dec:(function 2870 + | "active" -> Active 2871 + | "failed" -> Failed 2872 + | "completed" -> Completed 2873 + | "delayed" -> Delayed 2874 + | "waiting" -> Waiting 2875 + | "paused" -> Paused 2876 + | s -> Jsont.Error.msgf Jsont.Meta.none "Unknown t: %s" s) 2877 + ~enc:(function 2878 + | Active -> "active" 2879 + | Failed -> "failed" 2880 + | Completed -> "completed" 2881 + | Delayed -> "delayed" 2882 + | Waiting -> "waiting" 2883 + | Paused -> "paused") 2884 + end 2885 + 2886 + module QueueName = struct 2887 + type t = 2888 + | Thumbnail_generation 2889 + | Metadata_extraction 2890 + | Video_conversion 2891 + | Face_detection 2892 + | Facial_recognition 2893 + | Smart_search 2894 + | Duplicate_detection 2895 + | Background_task 2896 + | Storage_template_migration 2897 + | Migration 2898 + | Search 2899 + | Sidecar 2900 + | Library 2901 + | Notifications 2902 + | Backup_database 2903 + | Ocr 2904 + | Workflow 2905 + | Editor 2906 + 2907 + let t_jsont : t Jsont.t = 2908 + Jsont.map Jsont.string ~kind:"t" 2909 + ~dec:(function 2910 + | "thumbnailGeneration" -> Thumbnail_generation 2911 + | "metadataExtraction" -> Metadata_extraction 2912 + | "videoConversion" -> Video_conversion 2913 + | "faceDetection" -> Face_detection 2914 + | "facialRecognition" -> Facial_recognition 2915 + | "smartSearch" -> Smart_search 2916 + | "duplicateDetection" -> Duplicate_detection 2917 + | "backgroundTask" -> Background_task 2918 + | "storageTemplateMigration" -> Storage_template_migration 2919 + | "migration" -> Migration 2920 + | "search" -> Search 2921 + | "sidecar" -> Sidecar 2922 + | "library" -> Library 2923 + | "notifications" -> Notifications 2924 + | "backupDatabase" -> Backup_database 2925 + | "ocr" -> Ocr 2926 + | "workflow" -> Workflow 2927 + | "editor" -> Editor 2928 + | s -> Jsont.Error.msgf Jsont.Meta.none "Unknown t: %s" s) 2929 + ~enc:(function 2930 + | Thumbnail_generation -> "thumbnailGeneration" 2931 + | Metadata_extraction -> "metadataExtraction" 2932 + | Video_conversion -> "videoConversion" 2933 + | Face_detection -> "faceDetection" 2934 + | Facial_recognition -> "facialRecognition" 2935 + | Smart_search -> "smartSearch" 2936 + | Duplicate_detection -> "duplicateDetection" 2937 + | Background_task -> "backgroundTask" 2938 + | Storage_template_migration -> "storageTemplateMigration" 2939 + | Migration -> "migration" 2940 + | Search -> "search" 2941 + | Sidecar -> "sidecar" 2942 + | Library -> "library" 2943 + | Notifications -> "notifications" 2944 + | Backup_database -> "backupDatabase" 2945 + | Ocr -> "ocr" 2946 + | Workflow -> "workflow" 2947 + | Editor -> "editor") 2948 + end 2949 + 2950 + module QueueStatisticsDto = struct 2951 + type t = { 2952 + active : int; 2953 + completed : int; 2954 + delayed : int; 2955 + failed : int; 2956 + paused : int; 2957 + waiting : int; 2958 + } 2959 + 2960 + let t_jsont : t Jsont.t = 2961 + Jsont.Object.map ~kind:"t" 2962 + (fun active completed delayed failed paused waiting -> { active; completed; delayed; failed; paused; waiting }) 2963 + |> Jsont.Object.mem "active" Jsont.int ~enc:(fun r -> r.active) 2964 + |> Jsont.Object.mem "completed" Jsont.int ~enc:(fun r -> r.completed) 2965 + |> Jsont.Object.mem "delayed" Jsont.int ~enc:(fun r -> r.delayed) 2966 + |> Jsont.Object.mem "failed" Jsont.int ~enc:(fun r -> r.failed) 2967 + |> Jsont.Object.mem "paused" Jsont.int ~enc:(fun r -> r.paused) 2968 + |> Jsont.Object.mem "waiting" Jsont.int ~enc:(fun r -> r.waiting) 2969 + |> Jsont.Object.skip_unknown 2970 + |> Jsont.Object.finish 2971 + end 2972 + 2973 + module QueueStatusLegacyDto = struct 2974 + type t = { 2975 + is_active : bool; 2976 + is_paused : bool; 2977 + } 2978 + 2979 + let t_jsont : t Jsont.t = 2980 + Jsont.Object.map ~kind:"t" 2981 + (fun is_active is_paused -> { is_active; is_paused }) 2982 + |> Jsont.Object.mem "isActive" Jsont.bool ~enc:(fun r -> r.is_active) 2983 + |> Jsont.Object.mem "isPaused" Jsont.bool ~enc:(fun r -> r.is_paused) 2984 + |> Jsont.Object.skip_unknown 2985 + |> Jsont.Object.finish 2986 + end 2987 + 2988 + module QueueUpdateDto = struct 2989 + type t = { 2990 + is_paused : bool option; 2991 + } 2992 + 2993 + let t_jsont : t Jsont.t = 2994 + Jsont.Object.map ~kind:"t" 2995 + (fun is_paused -> { is_paused }) 2996 + |> Jsont.Object.opt_mem "isPaused" Jsont.bool ~enc:(fun r -> r.is_paused) 2997 + |> Jsont.Object.skip_unknown 2998 + |> Jsont.Object.finish 2999 + end 3000 + 3001 + module RatingsResponse = struct 3002 + type t = { 3003 + enabled : bool; 3004 + } 3005 + 3006 + let t_jsont : t Jsont.t = 3007 + Jsont.Object.map ~kind:"t" 3008 + (fun enabled -> { enabled }) 3009 + |> Jsont.Object.mem "enabled" Jsont.bool ~enc:(fun r -> r.enabled) 3010 + |> Jsont.Object.skip_unknown 3011 + |> Jsont.Object.finish 3012 + end 3013 + 3014 + module RatingsUpdate = struct 3015 + type t = { 3016 + enabled : bool option; 3017 + } 3018 + 3019 + let t_jsont : t Jsont.t = 3020 + Jsont.Object.map ~kind:"t" 3021 + (fun enabled -> { enabled }) 3022 + |> Jsont.Object.opt_mem "enabled" Jsont.bool ~enc:(fun r -> r.enabled) 3023 + |> Jsont.Object.skip_unknown 3024 + |> Jsont.Object.finish 3025 + end 3026 + 3027 + module ReactionLevel = struct 3028 + type t = 3029 + | Album 3030 + | Asset 3031 + 3032 + let t_jsont : t Jsont.t = 3033 + Jsont.map Jsont.string ~kind:"t" 3034 + ~dec:(function 3035 + | "album" -> Album 3036 + | "asset" -> Asset 3037 + | s -> Jsont.Error.msgf Jsont.Meta.none "Unknown t: %s" s) 3038 + ~enc:(function 3039 + | Album -> "album" 3040 + | Asset -> "asset") 3041 + end 3042 + 3043 + module ReactionType = struct 3044 + type t = 3045 + | Comment 3046 + | Like 3047 + 3048 + let t_jsont : t Jsont.t = 3049 + Jsont.map Jsont.string ~kind:"t" 3050 + ~dec:(function 3051 + | "comment" -> Comment 3052 + | "like" -> Like 3053 + | s -> Jsont.Error.msgf Jsont.Meta.none "Unknown t: %s" s) 3054 + ~enc:(function 3055 + | Comment -> "comment" 3056 + | Like -> "like") 3057 + end 3058 + 3059 + module ReverseGeocodingStateResponseDto = struct 3060 + type t = { 3061 + last_import_file_name : string; 3062 + last_update : string; 3063 + } 3064 + 3065 + let t_jsont : t Jsont.t = 3066 + Jsont.Object.map ~kind:"t" 3067 + (fun last_import_file_name last_update -> { last_import_file_name; last_update }) 3068 + |> Jsont.Object.mem "lastImportFileName" Jsont.string ~enc:(fun r -> r.last_import_file_name) 3069 + |> Jsont.Object.mem "lastUpdate" Jsont.string ~enc:(fun r -> r.last_update) 3070 + |> Jsont.Object.skip_unknown 3071 + |> Jsont.Object.finish 3072 + end 3073 + 3074 + module RotateParameters = struct 3075 + type t = { 3076 + angle : float; (** Rotation angle in degrees *) 3077 + } 3078 + 3079 + let t_jsont : t Jsont.t = 3080 + Jsont.Object.map ~kind:"t" 3081 + (fun angle -> { angle }) 3082 + |> Jsont.Object.mem "angle" Jsont.number ~enc:(fun r -> r.angle) 3083 + |> Jsont.Object.skip_unknown 3084 + |> Jsont.Object.finish 3085 + end 3086 + 3087 + module SearchFacetCountResponseDto = struct 3088 + type t = { 3089 + count : int; 3090 + value : string; 3091 + } 3092 + 3093 + let t_jsont : t Jsont.t = 3094 + Jsont.Object.map ~kind:"t" 3095 + (fun count value -> { count; value }) 3096 + |> Jsont.Object.mem "count" Jsont.int ~enc:(fun r -> r.count) 3097 + |> Jsont.Object.mem "value" Jsont.string ~enc:(fun r -> r.value) 3098 + |> Jsont.Object.skip_unknown 3099 + |> Jsont.Object.finish 3100 + end 3101 + 3102 + module SearchStatisticsResponseDto = struct 3103 + type t = { 3104 + total : int; 3105 + } 3106 + 3107 + let t_jsont : t Jsont.t = 3108 + Jsont.Object.map ~kind:"t" 3109 + (fun total -> { total }) 3110 + |> Jsont.Object.mem "total" Jsont.int ~enc:(fun r -> r.total) 3111 + |> Jsont.Object.skip_unknown 3112 + |> Jsont.Object.finish 3113 + end 3114 + 3115 + module SearchSuggestionType = struct 3116 + type t = 3117 + | Country 3118 + | State 3119 + | City 3120 + | Camera_make 3121 + | Camera_model 3122 + | Camera_lens_model 3123 + 3124 + let t_jsont : t Jsont.t = 3125 + Jsont.map Jsont.string ~kind:"t" 3126 + ~dec:(function 3127 + | "country" -> Country 3128 + | "state" -> State 3129 + | "city" -> City 3130 + | "camera-make" -> Camera_make 3131 + | "camera-model" -> Camera_model 3132 + | "camera-lens-model" -> Camera_lens_model 3133 + | s -> Jsont.Error.msgf Jsont.Meta.none "Unknown t: %s" s) 3134 + ~enc:(function 3135 + | Country -> "country" 3136 + | State -> "state" 3137 + | City -> "city" 3138 + | Camera_make -> "camera-make" 3139 + | Camera_model -> "camera-model" 3140 + | Camera_lens_model -> "camera-lens-model") 3141 + end 3142 + 3143 + module ServerAboutResponseDto = struct 3144 + type t = { 3145 + build : string option; 3146 + build_image : string option; 3147 + build_image_url : string option; 3148 + build_url : string option; 3149 + exiftool : string option; 3150 + ffmpeg : string option; 3151 + imagemagick : string option; 3152 + libvips : string option; 3153 + licensed : bool; 3154 + nodejs : string option; 3155 + repository : string option; 3156 + repository_url : string option; 3157 + source_commit : string option; 3158 + source_ref : string option; 3159 + source_url : string option; 3160 + third_party_bug_feature_url : string option; 3161 + third_party_documentation_url : string option; 3162 + third_party_source_url : string option; 3163 + third_party_support_url : string option; 3164 + version : string; 3165 + version_url : string; 3166 + } 3167 + 3168 + let t_jsont : t Jsont.t = 3169 + Jsont.Object.map ~kind:"t" 3170 + (fun build build_image build_image_url build_url exiftool ffmpeg imagemagick libvips licensed nodejs repository repository_url source_commit source_ref source_url third_party_bug_feature_url third_party_documentation_url third_party_source_url third_party_support_url version version_url -> { build; build_image; build_image_url; build_url; exiftool; ffmpeg; imagemagick; libvips; licensed; nodejs; repository; repository_url; source_commit; source_ref; source_url; third_party_bug_feature_url; third_party_documentation_url; third_party_source_url; third_party_support_url; version; version_url }) 3171 + |> Jsont.Object.opt_mem "build" Jsont.string ~enc:(fun r -> r.build) 3172 + |> Jsont.Object.opt_mem "buildImage" Jsont.string ~enc:(fun r -> r.build_image) 3173 + |> Jsont.Object.opt_mem "buildImageUrl" Jsont.string ~enc:(fun r -> r.build_image_url) 3174 + |> Jsont.Object.opt_mem "buildUrl" Jsont.string ~enc:(fun r -> r.build_url) 3175 + |> Jsont.Object.opt_mem "exiftool" Jsont.string ~enc:(fun r -> r.exiftool) 3176 + |> Jsont.Object.opt_mem "ffmpeg" Jsont.string ~enc:(fun r -> r.ffmpeg) 3177 + |> Jsont.Object.opt_mem "imagemagick" Jsont.string ~enc:(fun r -> r.imagemagick) 3178 + |> Jsont.Object.opt_mem "libvips" Jsont.string ~enc:(fun r -> r.libvips) 3179 + |> Jsont.Object.mem "licensed" Jsont.bool ~enc:(fun r -> r.licensed) 3180 + |> Jsont.Object.opt_mem "nodejs" Jsont.string ~enc:(fun r -> r.nodejs) 3181 + |> Jsont.Object.opt_mem "repository" Jsont.string ~enc:(fun r -> r.repository) 3182 + |> Jsont.Object.opt_mem "repositoryUrl" Jsont.string ~enc:(fun r -> r.repository_url) 3183 + |> Jsont.Object.opt_mem "sourceCommit" Jsont.string ~enc:(fun r -> r.source_commit) 3184 + |> Jsont.Object.opt_mem "sourceRef" Jsont.string ~enc:(fun r -> r.source_ref) 3185 + |> Jsont.Object.opt_mem "sourceUrl" Jsont.string ~enc:(fun r -> r.source_url) 3186 + |> Jsont.Object.opt_mem "thirdPartyBugFeatureUrl" Jsont.string ~enc:(fun r -> r.third_party_bug_feature_url) 3187 + |> Jsont.Object.opt_mem "thirdPartyDocumentationUrl" Jsont.string ~enc:(fun r -> r.third_party_documentation_url) 3188 + |> Jsont.Object.opt_mem "thirdPartySourceUrl" Jsont.string ~enc:(fun r -> r.third_party_source_url) 3189 + |> Jsont.Object.opt_mem "thirdPartySupportUrl" Jsont.string ~enc:(fun r -> r.third_party_support_url) 3190 + |> Jsont.Object.mem "version" Jsont.string ~enc:(fun r -> r.version) 3191 + |> Jsont.Object.mem "versionUrl" Jsont.string ~enc:(fun r -> r.version_url) 3192 + |> Jsont.Object.skip_unknown 3193 + |> Jsont.Object.finish 3194 + end 3195 + 3196 + module ServerApkLinksDto = struct 3197 + type t = { 3198 + arm64v8a : string; 3199 + armeabiv7a : string; 3200 + universal : string; 3201 + x86_64 : string; 3202 + } 3203 + 3204 + let t_jsont : t Jsont.t = 3205 + Jsont.Object.map ~kind:"t" 3206 + (fun arm64v8a armeabiv7a universal x86_64 -> { arm64v8a; armeabiv7a; universal; x86_64 }) 3207 + |> Jsont.Object.mem "arm64v8a" Jsont.string ~enc:(fun r -> r.arm64v8a) 3208 + |> Jsont.Object.mem "armeabiv7a" Jsont.string ~enc:(fun r -> r.armeabiv7a) 3209 + |> Jsont.Object.mem "universal" Jsont.string ~enc:(fun r -> r.universal) 3210 + |> Jsont.Object.mem "x86_64" Jsont.string ~enc:(fun r -> r.x86_64) 3211 + |> Jsont.Object.skip_unknown 3212 + |> Jsont.Object.finish 3213 + end 3214 + 3215 + module ServerConfigDto = struct 3216 + type t = { 3217 + external_domain : string; 3218 + is_initialized : bool; 3219 + is_onboarded : bool; 3220 + login_page_message : string; 3221 + maintenance_mode : bool; 3222 + map_dark_style_url : string; 3223 + map_light_style_url : string; 3224 + oauth_button_text : string; 3225 + public_users : bool; 3226 + trash_days : int; 3227 + user_delete_delay : int; 3228 + } 3229 + 3230 + let t_jsont : t Jsont.t = 3231 + Jsont.Object.map ~kind:"t" 3232 + (fun external_domain is_initialized is_onboarded login_page_message maintenance_mode map_dark_style_url map_light_style_url oauth_button_text public_users trash_days user_delete_delay -> { external_domain; is_initialized; is_onboarded; login_page_message; maintenance_mode; map_dark_style_url; map_light_style_url; oauth_button_text; public_users; trash_days; user_delete_delay }) 3233 + |> Jsont.Object.mem "externalDomain" Jsont.string ~enc:(fun r -> r.external_domain) 3234 + |> Jsont.Object.mem "isInitialized" Jsont.bool ~enc:(fun r -> r.is_initialized) 3235 + |> Jsont.Object.mem "isOnboarded" Jsont.bool ~enc:(fun r -> r.is_onboarded) 3236 + |> Jsont.Object.mem "loginPageMessage" Jsont.string ~enc:(fun r -> r.login_page_message) 3237 + |> Jsont.Object.mem "maintenanceMode" Jsont.bool ~enc:(fun r -> r.maintenance_mode) 3238 + |> Jsont.Object.mem "mapDarkStyleUrl" Jsont.string ~enc:(fun r -> r.map_dark_style_url) 3239 + |> Jsont.Object.mem "mapLightStyleUrl" Jsont.string ~enc:(fun r -> r.map_light_style_url) 3240 + |> Jsont.Object.mem "oauthButtonText" Jsont.string ~enc:(fun r -> r.oauth_button_text) 3241 + |> Jsont.Object.mem "publicUsers" Jsont.bool ~enc:(fun r -> r.public_users) 3242 + |> Jsont.Object.mem "trashDays" Jsont.int ~enc:(fun r -> r.trash_days) 3243 + |> Jsont.Object.mem "userDeleteDelay" Jsont.int ~enc:(fun r -> r.user_delete_delay) 3244 + |> Jsont.Object.skip_unknown 3245 + |> Jsont.Object.finish 3246 + end 3247 + 3248 + module ServerFeaturesDto = struct 3249 + type t = { 3250 + config_file : bool; 3251 + duplicate_detection : bool; 3252 + email : bool; 3253 + facial_recognition : bool; 3254 + import_faces : bool; 3255 + map : bool; 3256 + oauth : bool; 3257 + oauth_auto_launch : bool; 3258 + ocr : bool; 3259 + password_login : bool; 3260 + reverse_geocoding : bool; 3261 + search : bool; 3262 + sidecar : bool; 3263 + smart_search : bool; 3264 + trash : bool; 3265 + } 3266 + 3267 + let t_jsont : t Jsont.t = 3268 + Jsont.Object.map ~kind:"t" 3269 + (fun config_file duplicate_detection email facial_recognition import_faces map oauth oauth_auto_launch ocr password_login reverse_geocoding search sidecar smart_search trash -> { config_file; duplicate_detection; email; facial_recognition; import_faces; map; oauth; oauth_auto_launch; ocr; password_login; reverse_geocoding; search; sidecar; smart_search; trash }) 3270 + |> Jsont.Object.mem "configFile" Jsont.bool ~enc:(fun r -> r.config_file) 3271 + |> Jsont.Object.mem "duplicateDetection" Jsont.bool ~enc:(fun r -> r.duplicate_detection) 3272 + |> Jsont.Object.mem "email" Jsont.bool ~enc:(fun r -> r.email) 3273 + |> Jsont.Object.mem "facialRecognition" Jsont.bool ~enc:(fun r -> r.facial_recognition) 3274 + |> Jsont.Object.mem "importFaces" Jsont.bool ~enc:(fun r -> r.import_faces) 3275 + |> Jsont.Object.mem "map" Jsont.bool ~enc:(fun r -> r.map) 3276 + |> Jsont.Object.mem "oauth" Jsont.bool ~enc:(fun r -> r.oauth) 3277 + |> Jsont.Object.mem "oauthAutoLaunch" Jsont.bool ~enc:(fun r -> r.oauth_auto_launch) 3278 + |> Jsont.Object.mem "ocr" Jsont.bool ~enc:(fun r -> r.ocr) 3279 + |> Jsont.Object.mem "passwordLogin" Jsont.bool ~enc:(fun r -> r.password_login) 3280 + |> Jsont.Object.mem "reverseGeocoding" Jsont.bool ~enc:(fun r -> r.reverse_geocoding) 3281 + |> Jsont.Object.mem "search" Jsont.bool ~enc:(fun r -> r.search) 3282 + |> Jsont.Object.mem "sidecar" Jsont.bool ~enc:(fun r -> r.sidecar) 3283 + |> Jsont.Object.mem "smartSearch" Jsont.bool ~enc:(fun r -> r.smart_search) 3284 + |> Jsont.Object.mem "trash" Jsont.bool ~enc:(fun r -> r.trash) 3285 + |> Jsont.Object.skip_unknown 3286 + |> Jsont.Object.finish 3287 + end 3288 + 3289 + module ServerMediaTypesResponseDto = struct 3290 + type t = { 3291 + image : string list; 3292 + sidecar : string list; 3293 + video : string list; 3294 + } 3295 + 3296 + let t_jsont : t Jsont.t = 3297 + Jsont.Object.map ~kind:"t" 3298 + (fun image sidecar video -> { image; sidecar; video }) 3299 + |> Jsont.Object.mem "image" Jsont.(list Jsont.string) ~enc:(fun r -> r.image) 3300 + |> Jsont.Object.mem "sidecar" Jsont.(list Jsont.string) ~enc:(fun r -> r.sidecar) 3301 + |> Jsont.Object.mem "video" Jsont.(list Jsont.string) ~enc:(fun r -> r.video) 3302 + |> Jsont.Object.skip_unknown 3303 + |> Jsont.Object.finish 3304 + end 3305 + 3306 + module ServerPingResponse = struct 3307 + type t = { 3308 + res : string; 3309 + } 3310 + 3311 + let t_jsont : t Jsont.t = 3312 + Jsont.Object.map ~kind:"t" 3313 + (fun res -> { res }) 3314 + |> Jsont.Object.mem "res" Jsont.string ~enc:(fun r -> r.res) 3315 + |> Jsont.Object.skip_unknown 3316 + |> Jsont.Object.finish 3317 + end 3318 + 3319 + module ServerStorageResponseDto = struct 3320 + type t = { 3321 + disk_available : string; 3322 + disk_available_raw : int64; 3323 + disk_size : string; 3324 + disk_size_raw : int64; 3325 + disk_usage_percentage : float; 3326 + disk_use : string; 3327 + disk_use_raw : int64; 3328 + } 3329 + 3330 + let t_jsont : t Jsont.t = 3331 + Jsont.Object.map ~kind:"t" 3332 + (fun disk_available disk_available_raw disk_size disk_size_raw disk_usage_percentage disk_use disk_use_raw -> { disk_available; disk_available_raw; disk_size; disk_size_raw; disk_usage_percentage; disk_use; disk_use_raw }) 3333 + |> Jsont.Object.mem "diskAvailable" Jsont.string ~enc:(fun r -> r.disk_available) 3334 + |> Jsont.Object.mem "diskAvailableRaw" Jsont.int64 ~enc:(fun r -> r.disk_available_raw) 3335 + |> Jsont.Object.mem "diskSize" Jsont.string ~enc:(fun r -> r.disk_size) 3336 + |> Jsont.Object.mem "diskSizeRaw" Jsont.int64 ~enc:(fun r -> r.disk_size_raw) 3337 + |> Jsont.Object.mem "diskUsagePercentage" Jsont.number ~enc:(fun r -> r.disk_usage_percentage) 3338 + |> Jsont.Object.mem "diskUse" Jsont.string ~enc:(fun r -> r.disk_use) 3339 + |> Jsont.Object.mem "diskUseRaw" Jsont.int64 ~enc:(fun r -> r.disk_use_raw) 3340 + |> Jsont.Object.skip_unknown 3341 + |> Jsont.Object.finish 3342 + end 3343 + 3344 + module ServerThemeDto = struct 3345 + type t = { 3346 + custom_css : string; 3347 + } 3348 + 3349 + let t_jsont : t Jsont.t = 3350 + Jsont.Object.map ~kind:"t" 3351 + (fun custom_css -> { custom_css }) 3352 + |> Jsont.Object.mem "customCss" Jsont.string ~enc:(fun r -> r.custom_css) 3353 + |> Jsont.Object.skip_unknown 3354 + |> Jsont.Object.finish 3355 + end 3356 + 3357 + module ServerVersionHistoryResponseDto = struct 3358 + type t = { 3359 + created_at : Ptime.t; 3360 + id : string; 3361 + version : string; 3362 + } 3363 + 3364 + let t_jsont : t Jsont.t = 3365 + Jsont.Object.map ~kind:"t" 3366 + (fun created_at id version -> { created_at; id; version }) 3367 + |> Jsont.Object.mem "createdAt" Openapi.Runtime.ptime_jsont ~enc:(fun r -> r.created_at) 3368 + |> Jsont.Object.mem "id" Jsont.string ~enc:(fun r -> r.id) 3369 + |> Jsont.Object.mem "version" Jsont.string ~enc:(fun r -> r.version) 3370 + |> Jsont.Object.skip_unknown 3371 + |> Jsont.Object.finish 3372 + end 3373 + 3374 + module ServerVersionResponseDto = struct 3375 + type t = { 3376 + major : int; 3377 + minor : int; 3378 + patch : int; 3379 + } 3380 + 3381 + let t_jsont : t Jsont.t = 3382 + Jsont.Object.map ~kind:"t" 3383 + (fun major minor patch -> { major; minor; patch }) 3384 + |> Jsont.Object.mem "major" Jsont.int ~enc:(fun r -> r.major) 3385 + |> Jsont.Object.mem "minor" Jsont.int ~enc:(fun r -> r.minor) 3386 + |> Jsont.Object.mem "patch" Jsont.int ~enc:(fun r -> r.patch) 3387 + |> Jsont.Object.skip_unknown 3388 + |> Jsont.Object.finish 3389 + end 3390 + 3391 + module SessionCreateDto = struct 3392 + type t = { 3393 + device_os : string option; 3394 + device_type : string option; 3395 + duration : float option; (** session duration, in seconds *) 3396 + } 3397 + 3398 + let t_jsont : t Jsont.t = 3399 + Jsont.Object.map ~kind:"t" 3400 + (fun device_os device_type duration -> { device_os; device_type; duration }) 3401 + |> Jsont.Object.opt_mem "deviceOS" Jsont.string ~enc:(fun r -> r.device_os) 3402 + |> Jsont.Object.opt_mem "deviceType" Jsont.string ~enc:(fun r -> r.device_type) 3403 + |> Jsont.Object.opt_mem "duration" Jsont.number ~enc:(fun r -> r.duration) 3404 + |> Jsont.Object.skip_unknown 3405 + |> Jsont.Object.finish 3406 + end 3407 + 3408 + module SessionCreateResponseDto = struct 3409 + type t = { 3410 + app_version : string; 3411 + created_at : string; 3412 + current : bool; 3413 + device_os : string; 3414 + device_type : string; 3415 + expires_at : string option; 3416 + id : string; 3417 + is_pending_sync_reset : bool; 3418 + token : string; 3419 + updated_at : string; 3420 + } 3421 + 3422 + let t_jsont : t Jsont.t = 3423 + Jsont.Object.map ~kind:"t" 3424 + (fun app_version created_at current device_os device_type expires_at id is_pending_sync_reset token updated_at -> { app_version; created_at; current; device_os; device_type; expires_at; id; is_pending_sync_reset; token; updated_at }) 3425 + |> Jsont.Object.mem "appVersion" Jsont.string ~enc:(fun r -> r.app_version) 3426 + |> Jsont.Object.mem "createdAt" Jsont.string ~enc:(fun r -> r.created_at) 3427 + |> Jsont.Object.mem "current" Jsont.bool ~enc:(fun r -> r.current) 3428 + |> Jsont.Object.mem "deviceOS" Jsont.string ~enc:(fun r -> r.device_os) 3429 + |> Jsont.Object.mem "deviceType" Jsont.string ~enc:(fun r -> r.device_type) 3430 + |> Jsont.Object.opt_mem "expiresAt" Jsont.string ~enc:(fun r -> r.expires_at) 3431 + |> Jsont.Object.mem "id" Jsont.string ~enc:(fun r -> r.id) 3432 + |> Jsont.Object.mem "isPendingSyncReset" Jsont.bool ~enc:(fun r -> r.is_pending_sync_reset) 3433 + |> Jsont.Object.mem "token" Jsont.string ~enc:(fun r -> r.token) 3434 + |> Jsont.Object.mem "updatedAt" Jsont.string ~enc:(fun r -> r.updated_at) 3435 + |> Jsont.Object.skip_unknown 3436 + |> Jsont.Object.finish 3437 + end 3438 + 3439 + module SessionResponseDto = struct 3440 + type t = { 3441 + app_version : string; 3442 + created_at : string; 3443 + current : bool; 3444 + device_os : string; 3445 + device_type : string; 3446 + expires_at : string option; 3447 + id : string; 3448 + is_pending_sync_reset : bool; 3449 + updated_at : string; 3450 + } 3451 + 3452 + let t_jsont : t Jsont.t = 3453 + Jsont.Object.map ~kind:"t" 3454 + (fun app_version created_at current device_os device_type expires_at id is_pending_sync_reset updated_at -> { app_version; created_at; current; device_os; device_type; expires_at; id; is_pending_sync_reset; updated_at }) 3455 + |> Jsont.Object.mem "appVersion" Jsont.string ~enc:(fun r -> r.app_version) 3456 + |> Jsont.Object.mem "createdAt" Jsont.string ~enc:(fun r -> r.created_at) 3457 + |> Jsont.Object.mem "current" Jsont.bool ~enc:(fun r -> r.current) 3458 + |> Jsont.Object.mem "deviceOS" Jsont.string ~enc:(fun r -> r.device_os) 3459 + |> Jsont.Object.mem "deviceType" Jsont.string ~enc:(fun r -> r.device_type) 3460 + |> Jsont.Object.opt_mem "expiresAt" Jsont.string ~enc:(fun r -> r.expires_at) 3461 + |> Jsont.Object.mem "id" Jsont.string ~enc:(fun r -> r.id) 3462 + |> Jsont.Object.mem "isPendingSyncReset" Jsont.bool ~enc:(fun r -> r.is_pending_sync_reset) 3463 + |> Jsont.Object.mem "updatedAt" Jsont.string ~enc:(fun r -> r.updated_at) 3464 + |> Jsont.Object.skip_unknown 3465 + |> Jsont.Object.finish 3466 + end 3467 + 3468 + module SessionUnlockDto = struct 3469 + type t = { 3470 + password : string option; 3471 + pin_code : string option; 3472 + } 3473 + 3474 + let t_jsont : t Jsont.t = 3475 + Jsont.Object.map ~kind:"t" 3476 + (fun password pin_code -> { password; pin_code }) 3477 + |> Jsont.Object.opt_mem "password" Jsont.string ~enc:(fun r -> r.password) 3478 + |> Jsont.Object.opt_mem "pinCode" Jsont.string ~enc:(fun r -> r.pin_code) 3479 + |> Jsont.Object.skip_unknown 3480 + |> Jsont.Object.finish 3481 + end 3482 + 3483 + module SessionUpdateDto = struct 3484 + type t = { 3485 + is_pending_sync_reset : bool option; 3486 + } 3487 + 3488 + let t_jsont : t Jsont.t = 3489 + Jsont.Object.map ~kind:"t" 3490 + (fun is_pending_sync_reset -> { is_pending_sync_reset }) 3491 + |> Jsont.Object.opt_mem "isPendingSyncReset" Jsont.bool ~enc:(fun r -> r.is_pending_sync_reset) 3492 + |> Jsont.Object.skip_unknown 3493 + |> Jsont.Object.finish 3494 + end 3495 + 3496 + module SharedLinkEditDto = struct 3497 + type t = { 3498 + allow_download : bool option; 3499 + allow_upload : bool option; 3500 + change_expiry_time : bool option; (** Few clients cannot send null to set the expiryTime to never. 3501 + Setting this flag and not sending expiryAt is considered as null instead. 3502 + Clients that can send null values can ignore this. *) 3503 + description : string option; 3504 + expires_at : Ptime.t option; 3505 + password : string option; 3506 + show_metadata : bool option; 3507 + slug : string option; 3508 + } 3509 + 3510 + let t_jsont : t Jsont.t = 3511 + Jsont.Object.map ~kind:"t" 3512 + (fun allow_download allow_upload change_expiry_time description expires_at password show_metadata slug -> { allow_download; allow_upload; change_expiry_time; description; expires_at; password; show_metadata; slug }) 3513 + |> Jsont.Object.opt_mem "allowDownload" Jsont.bool ~enc:(fun r -> r.allow_download) 3514 + |> Jsont.Object.opt_mem "allowUpload" Jsont.bool ~enc:(fun r -> r.allow_upload) 3515 + |> Jsont.Object.opt_mem "changeExpiryTime" Jsont.bool ~enc:(fun r -> r.change_expiry_time) 3516 + |> Jsont.Object.opt_mem "description" Jsont.string ~enc:(fun r -> r.description) 3517 + |> Jsont.Object.opt_mem "expiresAt" Openapi.Runtime.ptime_jsont ~enc:(fun r -> r.expires_at) 3518 + |> Jsont.Object.opt_mem "password" Jsont.string ~enc:(fun r -> r.password) 3519 + |> Jsont.Object.opt_mem "showMetadata" Jsont.bool ~enc:(fun r -> r.show_metadata) 3520 + |> Jsont.Object.opt_mem "slug" Jsont.string ~enc:(fun r -> r.slug) 3521 + |> Jsont.Object.skip_unknown 3522 + |> Jsont.Object.finish 3523 + end 3524 + 3525 + module SharedLinkType = struct 3526 + type t = 3527 + | Album 3528 + | Individual 3529 + 3530 + let t_jsont : t Jsont.t = 3531 + Jsont.map Jsont.string ~kind:"t" 3532 + ~dec:(function 3533 + | "ALBUM" -> Album 3534 + | "INDIVIDUAL" -> Individual 3535 + | s -> Jsont.Error.msgf Jsont.Meta.none "Unknown t: %s" s) 3536 + ~enc:(function 3537 + | Album -> "ALBUM" 3538 + | Individual -> "INDIVIDUAL") 3539 + end 3540 + 3541 + module SharedLinksResponse = struct 3542 + type t = { 3543 + enabled : bool; 3544 + sidebar_web : bool; 3545 + } 3546 + 3547 + let t_jsont : t Jsont.t = 3548 + Jsont.Object.map ~kind:"t" 3549 + (fun enabled sidebar_web -> { enabled; sidebar_web }) 3550 + |> Jsont.Object.mem "enabled" Jsont.bool ~enc:(fun r -> r.enabled) 3551 + |> Jsont.Object.mem "sidebarWeb" Jsont.bool ~enc:(fun r -> r.sidebar_web) 3552 + |> Jsont.Object.skip_unknown 3553 + |> Jsont.Object.finish 3554 + end 3555 + 3556 + module SharedLinksUpdate = struct 3557 + type t = { 3558 + enabled : bool option; 3559 + sidebar_web : bool option; 3560 + } 3561 + 3562 + let t_jsont : t Jsont.t = 3563 + Jsont.Object.map ~kind:"t" 3564 + (fun enabled sidebar_web -> { enabled; sidebar_web }) 3565 + |> Jsont.Object.opt_mem "enabled" Jsont.bool ~enc:(fun r -> r.enabled) 3566 + |> Jsont.Object.opt_mem "sidebarWeb" Jsont.bool ~enc:(fun r -> r.sidebar_web) 3567 + |> Jsont.Object.skip_unknown 3568 + |> Jsont.Object.finish 3569 + end 3570 + 3571 + module SignUpDto = struct 3572 + type t = { 3573 + email : string; 3574 + name : string; 3575 + password : string; 3576 + } 3577 + 3578 + let t_jsont : t Jsont.t = 3579 + Jsont.Object.map ~kind:"t" 3580 + (fun email name password -> { email; name; password }) 3581 + |> Jsont.Object.mem "email" Jsont.string ~enc:(fun r -> r.email) 3582 + |> Jsont.Object.mem "name" Jsont.string ~enc:(fun r -> r.name) 3583 + |> Jsont.Object.mem "password" Jsont.string ~enc:(fun r -> r.password) 3584 + |> Jsont.Object.skip_unknown 3585 + |> Jsont.Object.finish 3586 + end 3587 + 3588 + module SourceType = struct 3589 + type t = 3590 + | Machine_learning 3591 + | Exif 3592 + | Manual 3593 + 3594 + let t_jsont : t Jsont.t = 3595 + Jsont.map Jsont.string ~kind:"t" 3596 + ~dec:(function 3597 + | "machine-learning" -> Machine_learning 3598 + | "exif" -> Exif 3599 + | "manual" -> Manual 3600 + | s -> Jsont.Error.msgf Jsont.Meta.none "Unknown t: %s" s) 3601 + ~enc:(function 3602 + | Machine_learning -> "machine-learning" 3603 + | Exif -> "exif" 3604 + | Manual -> "manual") 3605 + end 3606 + 3607 + module StackCreateDto = struct 3608 + type t = { 3609 + asset_ids : string list; (** first asset becomes the primary *) 3610 + } 3611 + 3612 + let t_jsont : t Jsont.t = 3613 + Jsont.Object.map ~kind:"t" 3614 + (fun asset_ids -> { asset_ids }) 3615 + |> Jsont.Object.mem "assetIds" Jsont.(list Jsont.string) ~enc:(fun r -> r.asset_ids) 3616 + |> Jsont.Object.skip_unknown 3617 + |> Jsont.Object.finish 3618 + end 3619 + 3620 + module StackUpdateDto = struct 3621 + type t = { 3622 + primary_asset_id : string option; 3623 + } 3624 + 3625 + let t_jsont : t Jsont.t = 3626 + Jsont.Object.map ~kind:"t" 3627 + (fun primary_asset_id -> { primary_asset_id }) 3628 + |> Jsont.Object.opt_mem "primaryAssetId" Jsont.string ~enc:(fun r -> r.primary_asset_id) 3629 + |> Jsont.Object.skip_unknown 3630 + |> Jsont.Object.finish 3631 + end 3632 + 3633 + module StorageFolder = struct 3634 + type t = 3635 + | Encoded_video 3636 + | Library 3637 + | Upload 3638 + | Profile 3639 + | Thumbs 3640 + | Backups 3641 + 3642 + let t_jsont : t Jsont.t = 3643 + Jsont.map Jsont.string ~kind:"t" 3644 + ~dec:(function 3645 + | "encoded-video" -> Encoded_video 3646 + | "library" -> Library 3647 + | "upload" -> Upload 3648 + | "profile" -> Profile 3649 + | "thumbs" -> Thumbs 3650 + | "backups" -> Backups 3651 + | s -> Jsont.Error.msgf Jsont.Meta.none "Unknown t: %s" s) 3652 + ~enc:(function 3653 + | Encoded_video -> "encoded-video" 3654 + | Library -> "library" 3655 + | Upload -> "upload" 3656 + | Profile -> "profile" 3657 + | Thumbs -> "thumbs" 3658 + | Backups -> "backups") 3659 + end 3660 + 3661 + module SyncAckSetDto = struct 3662 + type t = { 3663 + acks : string list; 3664 + } 3665 + 3666 + let t_jsont : t Jsont.t = 3667 + Jsont.Object.map ~kind:"t" 3668 + (fun acks -> { acks }) 3669 + |> Jsont.Object.mem "acks" Jsont.(list Jsont.string) ~enc:(fun r -> r.acks) 3670 + |> Jsont.Object.skip_unknown 3671 + |> Jsont.Object.finish 3672 + end 3673 + 3674 + module SyncAckV1 = struct 3675 + type t = Jsont.json 3676 + let t_jsont = Jsont.json 3677 + end 3678 + 3679 + module SyncAlbumDeleteV1 = struct 3680 + type t = { 3681 + album_id : string; 3682 + } 3683 + 3684 + let t_jsont : t Jsont.t = 3685 + Jsont.Object.map ~kind:"t" 3686 + (fun album_id -> { album_id }) 3687 + |> Jsont.Object.mem "albumId" Jsont.string ~enc:(fun r -> r.album_id) 3688 + |> Jsont.Object.skip_unknown 3689 + |> Jsont.Object.finish 3690 + end 3691 + 3692 + module SyncAlbumToAssetDeleteV1 = struct 3693 + type t = { 3694 + album_id : string; 3695 + asset_id : string; 3696 + } 3697 + 3698 + let t_jsont : t Jsont.t = 3699 + Jsont.Object.map ~kind:"t" 3700 + (fun album_id asset_id -> { album_id; asset_id }) 3701 + |> Jsont.Object.mem "albumId" Jsont.string ~enc:(fun r -> r.album_id) 3702 + |> Jsont.Object.mem "assetId" Jsont.string ~enc:(fun r -> r.asset_id) 3703 + |> Jsont.Object.skip_unknown 3704 + |> Jsont.Object.finish 3705 + end 3706 + 3707 + module SyncAlbumToAssetV1 = struct 3708 + type t = { 3709 + album_id : string; 3710 + asset_id : string; 3711 + } 3712 + 3713 + let t_jsont : t Jsont.t = 3714 + Jsont.Object.map ~kind:"t" 3715 + (fun album_id asset_id -> { album_id; asset_id }) 3716 + |> Jsont.Object.mem "albumId" Jsont.string ~enc:(fun r -> r.album_id) 3717 + |> Jsont.Object.mem "assetId" Jsont.string ~enc:(fun r -> r.asset_id) 3718 + |> Jsont.Object.skip_unknown 3719 + |> Jsont.Object.finish 3720 + end 3721 + 3722 + module SyncAlbumUserDeleteV1 = struct 3723 + type t = { 3724 + album_id : string; 3725 + user_id : string; 3726 + } 3727 + 3728 + let t_jsont : t Jsont.t = 3729 + Jsont.Object.map ~kind:"t" 3730 + (fun album_id user_id -> { album_id; user_id }) 3731 + |> Jsont.Object.mem "albumId" Jsont.string ~enc:(fun r -> r.album_id) 3732 + |> Jsont.Object.mem "userId" Jsont.string ~enc:(fun r -> r.user_id) 3733 + |> Jsont.Object.skip_unknown 3734 + |> Jsont.Object.finish 3735 + end 3736 + 3737 + module SyncAssetDeleteV1 = struct 3738 + type t = { 3739 + asset_id : string; 3740 + } 3741 + 3742 + let t_jsont : t Jsont.t = 3743 + Jsont.Object.map ~kind:"t" 3744 + (fun asset_id -> { asset_id }) 3745 + |> Jsont.Object.mem "assetId" Jsont.string ~enc:(fun r -> r.asset_id) 3746 + |> Jsont.Object.skip_unknown 3747 + |> Jsont.Object.finish 3748 + end 3749 + 3750 + module SyncAssetExifV1 = struct 3751 + type t = { 3752 + asset_id : string; 3753 + city : string; 3754 + country : string; 3755 + date_time_original : Ptime.t; 3756 + description : string; 3757 + exif_image_height : int; 3758 + exif_image_width : int; 3759 + exposure_time : string; 3760 + f_number : float; 3761 + file_size_in_byte : int; 3762 + focal_length : float; 3763 + fps : float; 3764 + iso : int; 3765 + latitude : float; 3766 + lens_model : string; 3767 + longitude : float; 3768 + make : string; 3769 + model : string; 3770 + modify_date : Ptime.t; 3771 + orientation : string; 3772 + profile_description : string; 3773 + projection_type : string; 3774 + rating : int; 3775 + state : string; 3776 + time_zone : string; 3777 + } 3778 + 3779 + let t_jsont : t Jsont.t = 3780 + Jsont.Object.map ~kind:"t" 3781 + (fun asset_id city country date_time_original description exif_image_height exif_image_width exposure_time f_number file_size_in_byte focal_length fps iso latitude lens_model longitude make model modify_date orientation profile_description projection_type rating state time_zone -> { asset_id; city; country; date_time_original; description; exif_image_height; exif_image_width; exposure_time; f_number; file_size_in_byte; focal_length; fps; iso; latitude; lens_model; longitude; make; model; modify_date; orientation; profile_description; projection_type; rating; state; time_zone }) 3782 + |> Jsont.Object.mem "assetId" Jsont.string ~enc:(fun r -> r.asset_id) 3783 + |> Jsont.Object.mem "city" Jsont.string ~enc:(fun r -> r.city) 3784 + |> Jsont.Object.mem "country" Jsont.string ~enc:(fun r -> r.country) 3785 + |> Jsont.Object.mem "dateTimeOriginal" Openapi.Runtime.ptime_jsont ~enc:(fun r -> r.date_time_original) 3786 + |> Jsont.Object.mem "description" Jsont.string ~enc:(fun r -> r.description) 3787 + |> Jsont.Object.mem "exifImageHeight" Jsont.int ~enc:(fun r -> r.exif_image_height) 3788 + |> Jsont.Object.mem "exifImageWidth" Jsont.int ~enc:(fun r -> r.exif_image_width) 3789 + |> Jsont.Object.mem "exposureTime" Jsont.string ~enc:(fun r -> r.exposure_time) 3790 + |> Jsont.Object.mem "fNumber" Jsont.number ~enc:(fun r -> r.f_number) 3791 + |> Jsont.Object.mem "fileSizeInByte" Jsont.int ~enc:(fun r -> r.file_size_in_byte) 3792 + |> Jsont.Object.mem "focalLength" Jsont.number ~enc:(fun r -> r.focal_length) 3793 + |> Jsont.Object.mem "fps" Jsont.number ~enc:(fun r -> r.fps) 3794 + |> Jsont.Object.mem "iso" Jsont.int ~enc:(fun r -> r.iso) 3795 + |> Jsont.Object.mem "latitude" Jsont.number ~enc:(fun r -> r.latitude) 3796 + |> Jsont.Object.mem "lensModel" Jsont.string ~enc:(fun r -> r.lens_model) 3797 + |> Jsont.Object.mem "longitude" Jsont.number ~enc:(fun r -> r.longitude) 3798 + |> Jsont.Object.mem "make" Jsont.string ~enc:(fun r -> r.make) 3799 + |> Jsont.Object.mem "model" Jsont.string ~enc:(fun r -> r.model) 3800 + |> Jsont.Object.mem "modifyDate" Openapi.Runtime.ptime_jsont ~enc:(fun r -> r.modify_date) 3801 + |> Jsont.Object.mem "orientation" Jsont.string ~enc:(fun r -> r.orientation) 3802 + |> Jsont.Object.mem "profileDescription" Jsont.string ~enc:(fun r -> r.profile_description) 3803 + |> Jsont.Object.mem "projectionType" Jsont.string ~enc:(fun r -> r.projection_type) 3804 + |> Jsont.Object.mem "rating" Jsont.int ~enc:(fun r -> r.rating) 3805 + |> Jsont.Object.mem "state" Jsont.string ~enc:(fun r -> r.state) 3806 + |> Jsont.Object.mem "timeZone" Jsont.string ~enc:(fun r -> r.time_zone) 3807 + |> Jsont.Object.skip_unknown 3808 + |> Jsont.Object.finish 3809 + end 3810 + 3811 + module SyncAssetFaceDeleteV1 = struct 3812 + type t = { 3813 + asset_face_id : string; 3814 + } 3815 + 3816 + let t_jsont : t Jsont.t = 3817 + Jsont.Object.map ~kind:"t" 3818 + (fun asset_face_id -> { asset_face_id }) 3819 + |> Jsont.Object.mem "assetFaceId" Jsont.string ~enc:(fun r -> r.asset_face_id) 3820 + |> Jsont.Object.skip_unknown 3821 + |> Jsont.Object.finish 3822 + end 3823 + 3824 + module SyncAssetFaceV1 = struct 3825 + type t = { 3826 + asset_id : string; 3827 + bounding_box_x1 : int; 3828 + bounding_box_x2 : int; 3829 + bounding_box_y1 : int; 3830 + bounding_box_y2 : int; 3831 + id : string; 3832 + image_height : int; 3833 + image_width : int; 3834 + person_id : string; 3835 + source_type : string; 3836 + } 3837 + 3838 + let t_jsont : t Jsont.t = 3839 + Jsont.Object.map ~kind:"t" 3840 + (fun asset_id bounding_box_x1 bounding_box_x2 bounding_box_y1 bounding_box_y2 id image_height image_width person_id source_type -> { asset_id; bounding_box_x1; bounding_box_x2; bounding_box_y1; bounding_box_y2; id; image_height; image_width; person_id; source_type }) 3841 + |> Jsont.Object.mem "assetId" Jsont.string ~enc:(fun r -> r.asset_id) 3842 + |> Jsont.Object.mem "boundingBoxX1" Jsont.int ~enc:(fun r -> r.bounding_box_x1) 3843 + |> Jsont.Object.mem "boundingBoxX2" Jsont.int ~enc:(fun r -> r.bounding_box_x2) 3844 + |> Jsont.Object.mem "boundingBoxY1" Jsont.int ~enc:(fun r -> r.bounding_box_y1) 3845 + |> Jsont.Object.mem "boundingBoxY2" Jsont.int ~enc:(fun r -> r.bounding_box_y2) 3846 + |> Jsont.Object.mem "id" Jsont.string ~enc:(fun r -> r.id) 3847 + |> Jsont.Object.mem "imageHeight" Jsont.int ~enc:(fun r -> r.image_height) 3848 + |> Jsont.Object.mem "imageWidth" Jsont.int ~enc:(fun r -> r.image_width) 3849 + |> Jsont.Object.mem "personId" Jsont.string ~enc:(fun r -> r.person_id) 3850 + |> Jsont.Object.mem "sourceType" Jsont.string ~enc:(fun r -> r.source_type) 3851 + |> Jsont.Object.skip_unknown 3852 + |> Jsont.Object.finish 3853 + end 3854 + 3855 + module SyncAssetMetadataDeleteV1 = struct 3856 + type t = { 3857 + asset_id : string; 3858 + key : string; 3859 + } 3860 + 3861 + let t_jsont : t Jsont.t = 3862 + Jsont.Object.map ~kind:"t" 3863 + (fun asset_id key -> { asset_id; key }) 3864 + |> Jsont.Object.mem "assetId" Jsont.string ~enc:(fun r -> r.asset_id) 3865 + |> Jsont.Object.mem "key" Jsont.string ~enc:(fun r -> r.key) 3866 + |> Jsont.Object.skip_unknown 3867 + |> Jsont.Object.finish 3868 + end 3869 + 3870 + module SyncAssetMetadataV1 = struct 3871 + type t = { 3872 + asset_id : string; 3873 + key : string; 3874 + value : Jsont.json; 3875 + } 3876 + 3877 + let t_jsont : t Jsont.t = 3878 + Jsont.Object.map ~kind:"t" 3879 + (fun asset_id key value -> { asset_id; key; value }) 3880 + |> Jsont.Object.mem "assetId" Jsont.string ~enc:(fun r -> r.asset_id) 3881 + |> Jsont.Object.mem "key" Jsont.string ~enc:(fun r -> r.key) 3882 + |> Jsont.Object.mem "value" Jsont.json ~enc:(fun r -> r.value) 3883 + |> Jsont.Object.skip_unknown 3884 + |> Jsont.Object.finish 3885 + end 3886 + 3887 + module SyncCompleteV1 = struct 3888 + type t = Jsont.json 3889 + let t_jsont = Jsont.json 3890 + end 3891 + 3892 + module SyncEntityType = struct 3893 + type t = 3894 + | Auth_user_v1 3895 + | User_v1 3896 + | User_delete_v1 3897 + | Asset_v1 3898 + | Asset_delete_v1 3899 + | Asset_exif_v1 3900 + | Asset_metadata_v1 3901 + | Asset_metadata_delete_v1 3902 + | Partner_v1 3903 + | Partner_delete_v1 3904 + | Partner_asset_v1 3905 + | Partner_asset_backfill_v1 3906 + | Partner_asset_delete_v1 3907 + | Partner_asset_exif_v1 3908 + | Partner_asset_exif_backfill_v1 3909 + | Partner_stack_backfill_v1 3910 + | Partner_stack_delete_v1 3911 + | Partner_stack_v1 3912 + | Album_v1 3913 + | Album_delete_v1 3914 + | Album_user_v1 3915 + | Album_user_backfill_v1 3916 + | Album_user_delete_v1 3917 + | Album_asset_create_v1 3918 + | Album_asset_update_v1 3919 + | Album_asset_backfill_v1 3920 + | Album_asset_exif_create_v1 3921 + | Album_asset_exif_update_v1 3922 + | Album_asset_exif_backfill_v1 3923 + | Album_to_asset_v1 3924 + | Album_to_asset_delete_v1 3925 + | Album_to_asset_backfill_v1 3926 + | Memory_v1 3927 + | Memory_delete_v1 3928 + | Memory_to_asset_v1 3929 + | Memory_to_asset_delete_v1 3930 + | Stack_v1 3931 + | Stack_delete_v1 3932 + | Person_v1 3933 + | Person_delete_v1 3934 + | Asset_face_v1 3935 + | Asset_face_delete_v1 3936 + | User_metadata_v1 3937 + | User_metadata_delete_v1 3938 + | Sync_ack_v1 3939 + | Sync_reset_v1 3940 + | Sync_complete_v1 3941 + 3942 + let t_jsont : t Jsont.t = 3943 + Jsont.map Jsont.string ~kind:"t" 3944 + ~dec:(function 3945 + | "AuthUserV1" -> Auth_user_v1 3946 + | "UserV1" -> User_v1 3947 + | "UserDeleteV1" -> User_delete_v1 3948 + | "AssetV1" -> Asset_v1 3949 + | "AssetDeleteV1" -> Asset_delete_v1 3950 + | "AssetExifV1" -> Asset_exif_v1 3951 + | "AssetMetadataV1" -> Asset_metadata_v1 3952 + | "AssetMetadataDeleteV1" -> Asset_metadata_delete_v1 3953 + | "PartnerV1" -> Partner_v1 3954 + | "PartnerDeleteV1" -> Partner_delete_v1 3955 + | "PartnerAssetV1" -> Partner_asset_v1 3956 + | "PartnerAssetBackfillV1" -> Partner_asset_backfill_v1 3957 + | "PartnerAssetDeleteV1" -> Partner_asset_delete_v1 3958 + | "PartnerAssetExifV1" -> Partner_asset_exif_v1 3959 + | "PartnerAssetExifBackfillV1" -> Partner_asset_exif_backfill_v1 3960 + | "PartnerStackBackfillV1" -> Partner_stack_backfill_v1 3961 + | "PartnerStackDeleteV1" -> Partner_stack_delete_v1 3962 + | "PartnerStackV1" -> Partner_stack_v1 3963 + | "AlbumV1" -> Album_v1 3964 + | "AlbumDeleteV1" -> Album_delete_v1 3965 + | "AlbumUserV1" -> Album_user_v1 3966 + | "AlbumUserBackfillV1" -> Album_user_backfill_v1 3967 + | "AlbumUserDeleteV1" -> Album_user_delete_v1 3968 + | "AlbumAssetCreateV1" -> Album_asset_create_v1 3969 + | "AlbumAssetUpdateV1" -> Album_asset_update_v1 3970 + | "AlbumAssetBackfillV1" -> Album_asset_backfill_v1 3971 + | "AlbumAssetExifCreateV1" -> Album_asset_exif_create_v1 3972 + | "AlbumAssetExifUpdateV1" -> Album_asset_exif_update_v1 3973 + | "AlbumAssetExifBackfillV1" -> Album_asset_exif_backfill_v1 3974 + | "AlbumToAssetV1" -> Album_to_asset_v1 3975 + | "AlbumToAssetDeleteV1" -> Album_to_asset_delete_v1 3976 + | "AlbumToAssetBackfillV1" -> Album_to_asset_backfill_v1 3977 + | "MemoryV1" -> Memory_v1 3978 + | "MemoryDeleteV1" -> Memory_delete_v1 3979 + | "MemoryToAssetV1" -> Memory_to_asset_v1 3980 + | "MemoryToAssetDeleteV1" -> Memory_to_asset_delete_v1 3981 + | "StackV1" -> Stack_v1 3982 + | "StackDeleteV1" -> Stack_delete_v1 3983 + | "PersonV1" -> Person_v1 3984 + | "PersonDeleteV1" -> Person_delete_v1 3985 + | "AssetFaceV1" -> Asset_face_v1 3986 + | "AssetFaceDeleteV1" -> Asset_face_delete_v1 3987 + | "UserMetadataV1" -> User_metadata_v1 3988 + | "UserMetadataDeleteV1" -> User_metadata_delete_v1 3989 + | "SyncAckV1" -> Sync_ack_v1 3990 + | "SyncResetV1" -> Sync_reset_v1 3991 + | "SyncCompleteV1" -> Sync_complete_v1 3992 + | s -> Jsont.Error.msgf Jsont.Meta.none "Unknown t: %s" s) 3993 + ~enc:(function 3994 + | Auth_user_v1 -> "AuthUserV1" 3995 + | User_v1 -> "UserV1" 3996 + | User_delete_v1 -> "UserDeleteV1" 3997 + | Asset_v1 -> "AssetV1" 3998 + | Asset_delete_v1 -> "AssetDeleteV1" 3999 + | Asset_exif_v1 -> "AssetExifV1" 4000 + | Asset_metadata_v1 -> "AssetMetadataV1" 4001 + | Asset_metadata_delete_v1 -> "AssetMetadataDeleteV1" 4002 + | Partner_v1 -> "PartnerV1" 4003 + | Partner_delete_v1 -> "PartnerDeleteV1" 4004 + | Partner_asset_v1 -> "PartnerAssetV1" 4005 + | Partner_asset_backfill_v1 -> "PartnerAssetBackfillV1" 4006 + | Partner_asset_delete_v1 -> "PartnerAssetDeleteV1" 4007 + | Partner_asset_exif_v1 -> "PartnerAssetExifV1" 4008 + | Partner_asset_exif_backfill_v1 -> "PartnerAssetExifBackfillV1" 4009 + | Partner_stack_backfill_v1 -> "PartnerStackBackfillV1" 4010 + | Partner_stack_delete_v1 -> "PartnerStackDeleteV1" 4011 + | Partner_stack_v1 -> "PartnerStackV1" 4012 + | Album_v1 -> "AlbumV1" 4013 + | Album_delete_v1 -> "AlbumDeleteV1" 4014 + | Album_user_v1 -> "AlbumUserV1" 4015 + | Album_user_backfill_v1 -> "AlbumUserBackfillV1" 4016 + | Album_user_delete_v1 -> "AlbumUserDeleteV1" 4017 + | Album_asset_create_v1 -> "AlbumAssetCreateV1" 4018 + | Album_asset_update_v1 -> "AlbumAssetUpdateV1" 4019 + | Album_asset_backfill_v1 -> "AlbumAssetBackfillV1" 4020 + | Album_asset_exif_create_v1 -> "AlbumAssetExifCreateV1" 4021 + | Album_asset_exif_update_v1 -> "AlbumAssetExifUpdateV1" 4022 + | Album_asset_exif_backfill_v1 -> "AlbumAssetExifBackfillV1" 4023 + | Album_to_asset_v1 -> "AlbumToAssetV1" 4024 + | Album_to_asset_delete_v1 -> "AlbumToAssetDeleteV1" 4025 + | Album_to_asset_backfill_v1 -> "AlbumToAssetBackfillV1" 4026 + | Memory_v1 -> "MemoryV1" 4027 + | Memory_delete_v1 -> "MemoryDeleteV1" 4028 + | Memory_to_asset_v1 -> "MemoryToAssetV1" 4029 + | Memory_to_asset_delete_v1 -> "MemoryToAssetDeleteV1" 4030 + | Stack_v1 -> "StackV1" 4031 + | Stack_delete_v1 -> "StackDeleteV1" 4032 + | Person_v1 -> "PersonV1" 4033 + | Person_delete_v1 -> "PersonDeleteV1" 4034 + | Asset_face_v1 -> "AssetFaceV1" 4035 + | Asset_face_delete_v1 -> "AssetFaceDeleteV1" 4036 + | User_metadata_v1 -> "UserMetadataV1" 4037 + | User_metadata_delete_v1 -> "UserMetadataDeleteV1" 4038 + | Sync_ack_v1 -> "SyncAckV1" 4039 + | Sync_reset_v1 -> "SyncResetV1" 4040 + | Sync_complete_v1 -> "SyncCompleteV1") 4041 + end 4042 + 4043 + module SyncMemoryAssetDeleteV1 = struct 4044 + type t = { 4045 + asset_id : string; 4046 + memory_id : string; 4047 + } 4048 + 4049 + let t_jsont : t Jsont.t = 4050 + Jsont.Object.map ~kind:"t" 4051 + (fun asset_id memory_id -> { asset_id; memory_id }) 4052 + |> Jsont.Object.mem "assetId" Jsont.string ~enc:(fun r -> r.asset_id) 4053 + |> Jsont.Object.mem "memoryId" Jsont.string ~enc:(fun r -> r.memory_id) 4054 + |> Jsont.Object.skip_unknown 4055 + |> Jsont.Object.finish 4056 + end 4057 + 4058 + module SyncMemoryAssetV1 = struct 4059 + type t = { 4060 + asset_id : string; 4061 + memory_id : string; 4062 + } 4063 + 4064 + let t_jsont : t Jsont.t = 4065 + Jsont.Object.map ~kind:"t" 4066 + (fun asset_id memory_id -> { asset_id; memory_id }) 4067 + |> Jsont.Object.mem "assetId" Jsont.string ~enc:(fun r -> r.asset_id) 4068 + |> Jsont.Object.mem "memoryId" Jsont.string ~enc:(fun r -> r.memory_id) 4069 + |> Jsont.Object.skip_unknown 4070 + |> Jsont.Object.finish 4071 + end 4072 + 4073 + module SyncMemoryDeleteV1 = struct 4074 + type t = { 4075 + memory_id : string; 4076 + } 4077 + 4078 + let t_jsont : t Jsont.t = 4079 + Jsont.Object.map ~kind:"t" 4080 + (fun memory_id -> { memory_id }) 4081 + |> Jsont.Object.mem "memoryId" Jsont.string ~enc:(fun r -> r.memory_id) 4082 + |> Jsont.Object.skip_unknown 4083 + |> Jsont.Object.finish 4084 + end 4085 + 4086 + module SyncPartnerDeleteV1 = struct 4087 + type t = { 4088 + shared_by_id : string; 4089 + shared_with_id : string; 4090 + } 4091 + 4092 + let t_jsont : t Jsont.t = 4093 + Jsont.Object.map ~kind:"t" 4094 + (fun shared_by_id shared_with_id -> { shared_by_id; shared_with_id }) 4095 + |> Jsont.Object.mem "sharedById" Jsont.string ~enc:(fun r -> r.shared_by_id) 4096 + |> Jsont.Object.mem "sharedWithId" Jsont.string ~enc:(fun r -> r.shared_with_id) 4097 + |> Jsont.Object.skip_unknown 4098 + |> Jsont.Object.finish 4099 + end 4100 + 4101 + module SyncPartnerV1 = struct 4102 + type t = { 4103 + in_timeline : bool; 4104 + shared_by_id : string; 4105 + shared_with_id : string; 4106 + } 4107 + 4108 + let t_jsont : t Jsont.t = 4109 + Jsont.Object.map ~kind:"t" 4110 + (fun in_timeline shared_by_id shared_with_id -> { in_timeline; shared_by_id; shared_with_id }) 4111 + |> Jsont.Object.mem "inTimeline" Jsont.bool ~enc:(fun r -> r.in_timeline) 4112 + |> Jsont.Object.mem "sharedById" Jsont.string ~enc:(fun r -> r.shared_by_id) 4113 + |> Jsont.Object.mem "sharedWithId" Jsont.string ~enc:(fun r -> r.shared_with_id) 4114 + |> Jsont.Object.skip_unknown 4115 + |> Jsont.Object.finish 4116 + end 4117 + 4118 + module SyncPersonDeleteV1 = struct 4119 + type t = { 4120 + person_id : string; 4121 + } 4122 + 4123 + let t_jsont : t Jsont.t = 4124 + Jsont.Object.map ~kind:"t" 4125 + (fun person_id -> { person_id }) 4126 + |> Jsont.Object.mem "personId" Jsont.string ~enc:(fun r -> r.person_id) 4127 + |> Jsont.Object.skip_unknown 4128 + |> Jsont.Object.finish 4129 + end 4130 + 4131 + module SyncPersonV1 = struct 4132 + type t = { 4133 + birth_date : Ptime.t; 4134 + color : string; 4135 + created_at : Ptime.t; 4136 + face_asset_id : string; 4137 + id : string; 4138 + is_favorite : bool; 4139 + is_hidden : bool; 4140 + name : string; 4141 + owner_id : string; 4142 + updated_at : Ptime.t; 4143 + } 4144 + 4145 + let t_jsont : t Jsont.t = 4146 + Jsont.Object.map ~kind:"t" 4147 + (fun birth_date color created_at face_asset_id id is_favorite is_hidden name owner_id updated_at -> { birth_date; color; created_at; face_asset_id; id; is_favorite; is_hidden; name; owner_id; updated_at }) 4148 + |> Jsont.Object.mem "birthDate" Openapi.Runtime.ptime_jsont ~enc:(fun r -> r.birth_date) 4149 + |> Jsont.Object.mem "color" Jsont.string ~enc:(fun r -> r.color) 4150 + |> Jsont.Object.mem "createdAt" Openapi.Runtime.ptime_jsont ~enc:(fun r -> r.created_at) 4151 + |> Jsont.Object.mem "faceAssetId" Jsont.string ~enc:(fun r -> r.face_asset_id) 4152 + |> Jsont.Object.mem "id" Jsont.string ~enc:(fun r -> r.id) 4153 + |> Jsont.Object.mem "isFavorite" Jsont.bool ~enc:(fun r -> r.is_favorite) 4154 + |> Jsont.Object.mem "isHidden" Jsont.bool ~enc:(fun r -> r.is_hidden) 4155 + |> Jsont.Object.mem "name" Jsont.string ~enc:(fun r -> r.name) 4156 + |> Jsont.Object.mem "ownerId" Jsont.string ~enc:(fun r -> r.owner_id) 4157 + |> Jsont.Object.mem "updatedAt" Openapi.Runtime.ptime_jsont ~enc:(fun r -> r.updated_at) 4158 + |> Jsont.Object.skip_unknown 4159 + |> Jsont.Object.finish 4160 + end 4161 + 4162 + module SyncRequestType = struct 4163 + type t = 4164 + | Albums_v1 4165 + | Album_users_v1 4166 + | Album_to_assets_v1 4167 + | Album_assets_v1 4168 + | Album_asset_exifs_v1 4169 + | Assets_v1 4170 + | Asset_exifs_v1 4171 + | Asset_metadata_v1 4172 + | Auth_users_v1 4173 + | Memories_v1 4174 + | Memory_to_assets_v1 4175 + | Partners_v1 4176 + | Partner_assets_v1 4177 + | Partner_asset_exifs_v1 4178 + | Partner_stacks_v1 4179 + | Stacks_v1 4180 + | Users_v1 4181 + | People_v1 4182 + | Asset_faces_v1 4183 + | User_metadata_v1 4184 + 4185 + let t_jsont : t Jsont.t = 4186 + Jsont.map Jsont.string ~kind:"t" 4187 + ~dec:(function 4188 + | "AlbumsV1" -> Albums_v1 4189 + | "AlbumUsersV1" -> Album_users_v1 4190 + | "AlbumToAssetsV1" -> Album_to_assets_v1 4191 + | "AlbumAssetsV1" -> Album_assets_v1 4192 + | "AlbumAssetExifsV1" -> Album_asset_exifs_v1 4193 + | "AssetsV1" -> Assets_v1 4194 + | "AssetExifsV1" -> Asset_exifs_v1 4195 + | "AssetMetadataV1" -> Asset_metadata_v1 4196 + | "AuthUsersV1" -> Auth_users_v1 4197 + | "MemoriesV1" -> Memories_v1 4198 + | "MemoryToAssetsV1" -> Memory_to_assets_v1 4199 + | "PartnersV1" -> Partners_v1 4200 + | "PartnerAssetsV1" -> Partner_assets_v1 4201 + | "PartnerAssetExifsV1" -> Partner_asset_exifs_v1 4202 + | "PartnerStacksV1" -> Partner_stacks_v1 4203 + | "StacksV1" -> Stacks_v1 4204 + | "UsersV1" -> Users_v1 4205 + | "PeopleV1" -> People_v1 4206 + | "AssetFacesV1" -> Asset_faces_v1 4207 + | "UserMetadataV1" -> User_metadata_v1 4208 + | s -> Jsont.Error.msgf Jsont.Meta.none "Unknown t: %s" s) 4209 + ~enc:(function 4210 + | Albums_v1 -> "AlbumsV1" 4211 + | Album_users_v1 -> "AlbumUsersV1" 4212 + | Album_to_assets_v1 -> "AlbumToAssetsV1" 4213 + | Album_assets_v1 -> "AlbumAssetsV1" 4214 + | Album_asset_exifs_v1 -> "AlbumAssetExifsV1" 4215 + | Assets_v1 -> "AssetsV1" 4216 + | Asset_exifs_v1 -> "AssetExifsV1" 4217 + | Asset_metadata_v1 -> "AssetMetadataV1" 4218 + | Auth_users_v1 -> "AuthUsersV1" 4219 + | Memories_v1 -> "MemoriesV1" 4220 + | Memory_to_assets_v1 -> "MemoryToAssetsV1" 4221 + | Partners_v1 -> "PartnersV1" 4222 + | Partner_assets_v1 -> "PartnerAssetsV1" 4223 + | Partner_asset_exifs_v1 -> "PartnerAssetExifsV1" 4224 + | Partner_stacks_v1 -> "PartnerStacksV1" 4225 + | Stacks_v1 -> "StacksV1" 4226 + | Users_v1 -> "UsersV1" 4227 + | People_v1 -> "PeopleV1" 4228 + | Asset_faces_v1 -> "AssetFacesV1" 4229 + | User_metadata_v1 -> "UserMetadataV1") 4230 + end 4231 + 4232 + module SyncResetV1 = struct 4233 + type t = Jsont.json 4234 + let t_jsont = Jsont.json 4235 + end 4236 + 4237 + module SyncStackDeleteV1 = struct 4238 + type t = { 4239 + stack_id : string; 4240 + } 4241 + 4242 + let t_jsont : t Jsont.t = 4243 + Jsont.Object.map ~kind:"t" 4244 + (fun stack_id -> { stack_id }) 4245 + |> Jsont.Object.mem "stackId" Jsont.string ~enc:(fun r -> r.stack_id) 4246 + |> Jsont.Object.skip_unknown 4247 + |> Jsont.Object.finish 4248 + end 4249 + 4250 + module SyncStackV1 = struct 4251 + type t = { 4252 + created_at : Ptime.t; 4253 + id : string; 4254 + owner_id : string; 4255 + primary_asset_id : string; 4256 + updated_at : Ptime.t; 4257 + } 4258 + 4259 + let t_jsont : t Jsont.t = 4260 + Jsont.Object.map ~kind:"t" 4261 + (fun created_at id owner_id primary_asset_id updated_at -> { created_at; id; owner_id; primary_asset_id; updated_at }) 4262 + |> Jsont.Object.mem "createdAt" Openapi.Runtime.ptime_jsont ~enc:(fun r -> r.created_at) 4263 + |> Jsont.Object.mem "id" Jsont.string ~enc:(fun r -> r.id) 4264 + |> Jsont.Object.mem "ownerId" Jsont.string ~enc:(fun r -> r.owner_id) 4265 + |> Jsont.Object.mem "primaryAssetId" Jsont.string ~enc:(fun r -> r.primary_asset_id) 4266 + |> Jsont.Object.mem "updatedAt" Openapi.Runtime.ptime_jsont ~enc:(fun r -> r.updated_at) 4267 + |> Jsont.Object.skip_unknown 4268 + |> Jsont.Object.finish 4269 + end 4270 + 4271 + module SyncUserDeleteV1 = struct 4272 + type t = { 4273 + user_id : string; 4274 + } 4275 + 4276 + let t_jsont : t Jsont.t = 4277 + Jsont.Object.map ~kind:"t" 4278 + (fun user_id -> { user_id }) 4279 + |> Jsont.Object.mem "userId" Jsont.string ~enc:(fun r -> r.user_id) 4280 + |> Jsont.Object.skip_unknown 4281 + |> Jsont.Object.finish 4282 + end 4283 + 4284 + module SystemConfigFacesDto = struct 4285 + type t = { 4286 + import : bool; 4287 + } 4288 + 4289 + let t_jsont : t Jsont.t = 4290 + Jsont.Object.map ~kind:"t" 4291 + (fun import -> { import }) 4292 + |> Jsont.Object.mem "import" Jsont.bool ~enc:(fun r -> r.import) 4293 + |> Jsont.Object.skip_unknown 4294 + |> Jsont.Object.finish 4295 + end 4296 + 4297 + module SystemConfigLibraryScanDto = struct 4298 + type t = { 4299 + cron_expression : string; 4300 + enabled : bool; 4301 + } 4302 + 4303 + let t_jsont : t Jsont.t = 4304 + Jsont.Object.map ~kind:"t" 4305 + (fun cron_expression enabled -> { cron_expression; enabled }) 4306 + |> Jsont.Object.mem "cronExpression" Jsont.string ~enc:(fun r -> r.cron_expression) 4307 + |> Jsont.Object.mem "enabled" Jsont.bool ~enc:(fun r -> r.enabled) 4308 + |> Jsont.Object.skip_unknown 4309 + |> Jsont.Object.finish 4310 + end 4311 + 4312 + module SystemConfigLibraryWatchDto = struct 4313 + type t = { 4314 + enabled : bool; 4315 + } 4316 + 4317 + let t_jsont : t Jsont.t = 4318 + Jsont.Object.map ~kind:"t" 4319 + (fun enabled -> { enabled }) 4320 + |> Jsont.Object.mem "enabled" Jsont.bool ~enc:(fun r -> r.enabled) 4321 + |> Jsont.Object.skip_unknown 4322 + |> Jsont.Object.finish 4323 + end 4324 + 4325 + module SystemConfigMapDto = struct 4326 + type t = { 4327 + dark_style : string; 4328 + enabled : bool; 4329 + light_style : string; 4330 + } 4331 + 4332 + let t_jsont : t Jsont.t = 4333 + Jsont.Object.map ~kind:"t" 4334 + (fun dark_style enabled light_style -> { dark_style; enabled; light_style }) 4335 + |> Jsont.Object.mem "darkStyle" Jsont.string ~enc:(fun r -> r.dark_style) 4336 + |> Jsont.Object.mem "enabled" Jsont.bool ~enc:(fun r -> r.enabled) 4337 + |> Jsont.Object.mem "lightStyle" Jsont.string ~enc:(fun r -> r.light_style) 4338 + |> Jsont.Object.skip_unknown 4339 + |> Jsont.Object.finish 4340 + end 4341 + 4342 + module SystemConfigNewVersionCheckDto = struct 4343 + type t = { 4344 + enabled : bool; 4345 + } 4346 + 4347 + let t_jsont : t Jsont.t = 4348 + Jsont.Object.map ~kind:"t" 4349 + (fun enabled -> { enabled }) 4350 + |> Jsont.Object.mem "enabled" Jsont.bool ~enc:(fun r -> r.enabled) 4351 + |> Jsont.Object.skip_unknown 4352 + |> Jsont.Object.finish 4353 + end 4354 + 4355 + module SystemConfigNightlyTasksDto = struct 4356 + type t = { 4357 + cluster_new_faces : bool; 4358 + database_cleanup : bool; 4359 + generate_memories : bool; 4360 + missing_thumbnails : bool; 4361 + start_time : string; 4362 + sync_quota_usage : bool; 4363 + } 4364 + 4365 + let t_jsont : t Jsont.t = 4366 + Jsont.Object.map ~kind:"t" 4367 + (fun cluster_new_faces database_cleanup generate_memories missing_thumbnails start_time sync_quota_usage -> { cluster_new_faces; database_cleanup; generate_memories; missing_thumbnails; start_time; sync_quota_usage }) 4368 + |> Jsont.Object.mem "clusterNewFaces" Jsont.bool ~enc:(fun r -> r.cluster_new_faces) 4369 + |> Jsont.Object.mem "databaseCleanup" Jsont.bool ~enc:(fun r -> r.database_cleanup) 4370 + |> Jsont.Object.mem "generateMemories" Jsont.bool ~enc:(fun r -> r.generate_memories) 4371 + |> Jsont.Object.mem "missingThumbnails" Jsont.bool ~enc:(fun r -> r.missing_thumbnails) 4372 + |> Jsont.Object.mem "startTime" Jsont.string ~enc:(fun r -> r.start_time) 4373 + |> Jsont.Object.mem "syncQuotaUsage" Jsont.bool ~enc:(fun r -> r.sync_quota_usage) 4374 + |> Jsont.Object.skip_unknown 4375 + |> Jsont.Object.finish 4376 + end 4377 + 4378 + module SystemConfigPasswordLoginDto = struct 4379 + type t = { 4380 + enabled : bool; 4381 + } 4382 + 4383 + let t_jsont : t Jsont.t = 4384 + Jsont.Object.map ~kind:"t" 4385 + (fun enabled -> { enabled }) 4386 + |> Jsont.Object.mem "enabled" Jsont.bool ~enc:(fun r -> r.enabled) 4387 + |> Jsont.Object.skip_unknown 4388 + |> Jsont.Object.finish 4389 + end 4390 + 4391 + module SystemConfigReverseGeocodingDto = struct 4392 + type t = { 4393 + enabled : bool; 4394 + } 4395 + 4396 + let t_jsont : t Jsont.t = 4397 + Jsont.Object.map ~kind:"t" 4398 + (fun enabled -> { enabled }) 4399 + |> Jsont.Object.mem "enabled" Jsont.bool ~enc:(fun r -> r.enabled) 4400 + |> Jsont.Object.skip_unknown 4401 + |> Jsont.Object.finish 4402 + end 4403 + 4404 + module SystemConfigServerDto = struct 4405 + type t = { 4406 + external_domain : string; 4407 + login_page_message : string; 4408 + public_users : bool; 4409 + } 4410 + 4411 + let t_jsont : t Jsont.t = 4412 + Jsont.Object.map ~kind:"t" 4413 + (fun external_domain login_page_message public_users -> { external_domain; login_page_message; public_users }) 4414 + |> Jsont.Object.mem "externalDomain" Jsont.string ~enc:(fun r -> r.external_domain) 4415 + |> Jsont.Object.mem "loginPageMessage" Jsont.string ~enc:(fun r -> r.login_page_message) 4416 + |> Jsont.Object.mem "publicUsers" Jsont.bool ~enc:(fun r -> r.public_users) 4417 + |> Jsont.Object.skip_unknown 4418 + |> Jsont.Object.finish 4419 + end 4420 + 4421 + module SystemConfigSmtpTransportDto = struct 4422 + type t = { 4423 + host : string; 4424 + ignore_cert : bool; 4425 + password : string; 4426 + port : float; 4427 + secure : bool; 4428 + username : string; 4429 + } 4430 + 4431 + let t_jsont : t Jsont.t = 4432 + Jsont.Object.map ~kind:"t" 4433 + (fun host ignore_cert password port secure username -> { host; ignore_cert; password; port; secure; username }) 4434 + |> Jsont.Object.mem "host" Jsont.string ~enc:(fun r -> r.host) 4435 + |> Jsont.Object.mem "ignoreCert" Jsont.bool ~enc:(fun r -> r.ignore_cert) 4436 + |> Jsont.Object.mem "password" Jsont.string ~enc:(fun r -> r.password) 4437 + |> Jsont.Object.mem "port" Jsont.number ~enc:(fun r -> r.port) 4438 + |> Jsont.Object.mem "secure" Jsont.bool ~enc:(fun r -> r.secure) 4439 + |> Jsont.Object.mem "username" Jsont.string ~enc:(fun r -> r.username) 4440 + |> Jsont.Object.skip_unknown 4441 + |> Jsont.Object.finish 4442 + end 4443 + 4444 + module SystemConfigStorageTemplateDto = struct 4445 + type t = { 4446 + enabled : bool; 4447 + hash_verification_enabled : bool; 4448 + template : string; 4449 + } 4450 + 4451 + let t_jsont : t Jsont.t = 4452 + Jsont.Object.map ~kind:"t" 4453 + (fun enabled hash_verification_enabled template -> { enabled; hash_verification_enabled; template }) 4454 + |> Jsont.Object.mem "enabled" Jsont.bool ~enc:(fun r -> r.enabled) 4455 + |> Jsont.Object.mem "hashVerificationEnabled" Jsont.bool ~enc:(fun r -> r.hash_verification_enabled) 4456 + |> Jsont.Object.mem "template" Jsont.string ~enc:(fun r -> r.template) 4457 + |> Jsont.Object.skip_unknown 4458 + |> Jsont.Object.finish 4459 + end 4460 + 4461 + module SystemConfigTemplateEmailsDto = struct 4462 + type t = { 4463 + album_invite_template : string; 4464 + album_update_template : string; 4465 + welcome_template : string; 4466 + } 4467 + 4468 + let t_jsont : t Jsont.t = 4469 + Jsont.Object.map ~kind:"t" 4470 + (fun album_invite_template album_update_template welcome_template -> { album_invite_template; album_update_template; welcome_template }) 4471 + |> Jsont.Object.mem "albumInviteTemplate" Jsont.string ~enc:(fun r -> r.album_invite_template) 4472 + |> Jsont.Object.mem "albumUpdateTemplate" Jsont.string ~enc:(fun r -> r.album_update_template) 4473 + |> Jsont.Object.mem "welcomeTemplate" Jsont.string ~enc:(fun r -> r.welcome_template) 4474 + |> Jsont.Object.skip_unknown 4475 + |> Jsont.Object.finish 4476 + end 4477 + 4478 + module SystemConfigTemplateStorageOptionDto = struct 4479 + type t = { 4480 + day_options : string list; 4481 + hour_options : string list; 4482 + minute_options : string list; 4483 + month_options : string list; 4484 + preset_options : string list; 4485 + second_options : string list; 4486 + week_options : string list; 4487 + year_options : string list; 4488 + } 4489 + 4490 + let t_jsont : t Jsont.t = 4491 + Jsont.Object.map ~kind:"t" 4492 + (fun day_options hour_options minute_options month_options preset_options second_options week_options year_options -> { day_options; hour_options; minute_options; month_options; preset_options; second_options; week_options; year_options }) 4493 + |> Jsont.Object.mem "dayOptions" Jsont.(list Jsont.string) ~enc:(fun r -> r.day_options) 4494 + |> Jsont.Object.mem "hourOptions" Jsont.(list Jsont.string) ~enc:(fun r -> r.hour_options) 4495 + |> Jsont.Object.mem "minuteOptions" Jsont.(list Jsont.string) ~enc:(fun r -> r.minute_options) 4496 + |> Jsont.Object.mem "monthOptions" Jsont.(list Jsont.string) ~enc:(fun r -> r.month_options) 4497 + |> Jsont.Object.mem "presetOptions" Jsont.(list Jsont.string) ~enc:(fun r -> r.preset_options) 4498 + |> Jsont.Object.mem "secondOptions" Jsont.(list Jsont.string) ~enc:(fun r -> r.second_options) 4499 + |> Jsont.Object.mem "weekOptions" Jsont.(list Jsont.string) ~enc:(fun r -> r.week_options) 4500 + |> Jsont.Object.mem "yearOptions" Jsont.(list Jsont.string) ~enc:(fun r -> r.year_options) 4501 + |> Jsont.Object.skip_unknown 4502 + |> Jsont.Object.finish 4503 + end 4504 + 4505 + module SystemConfigThemeDto = struct 4506 + type t = { 4507 + custom_css : string; 4508 + } 4509 + 4510 + let t_jsont : t Jsont.t = 4511 + Jsont.Object.map ~kind:"t" 4512 + (fun custom_css -> { custom_css }) 4513 + |> Jsont.Object.mem "customCss" Jsont.string ~enc:(fun r -> r.custom_css) 4514 + |> Jsont.Object.skip_unknown 4515 + |> Jsont.Object.finish 4516 + end 4517 + 4518 + module SystemConfigTrashDto = struct 4519 + type t = { 4520 + days : int; 4521 + enabled : bool; 4522 + } 4523 + 4524 + let t_jsont : t Jsont.t = 4525 + Jsont.Object.map ~kind:"t" 4526 + (fun days enabled -> { days; enabled }) 4527 + |> Jsont.Object.mem "days" Jsont.int ~enc:(fun r -> r.days) 4528 + |> Jsont.Object.mem "enabled" Jsont.bool ~enc:(fun r -> r.enabled) 4529 + |> Jsont.Object.skip_unknown 4530 + |> Jsont.Object.finish 4531 + end 4532 + 4533 + module SystemConfigUserDto = struct 4534 + type t = { 4535 + delete_delay : int; 4536 + } 4537 + 4538 + let t_jsont : t Jsont.t = 4539 + Jsont.Object.map ~kind:"t" 4540 + (fun delete_delay -> { delete_delay }) 4541 + |> Jsont.Object.mem "deleteDelay" Jsont.int ~enc:(fun r -> r.delete_delay) 4542 + |> Jsont.Object.skip_unknown 4543 + |> Jsont.Object.finish 4544 + end 4545 + 4546 + module TagBulkAssetsDto = struct 4547 + type t = { 4548 + asset_ids : string list; 4549 + tag_ids : string list; 4550 + } 4551 + 4552 + let t_jsont : t Jsont.t = 4553 + Jsont.Object.map ~kind:"t" 4554 + (fun asset_ids tag_ids -> { asset_ids; tag_ids }) 4555 + |> Jsont.Object.mem "assetIds" Jsont.(list Jsont.string) ~enc:(fun r -> r.asset_ids) 4556 + |> Jsont.Object.mem "tagIds" Jsont.(list Jsont.string) ~enc:(fun r -> r.tag_ids) 4557 + |> Jsont.Object.skip_unknown 4558 + |> Jsont.Object.finish 4559 + end 4560 + 4561 + module TagBulkAssetsResponseDto = struct 4562 + type t = { 4563 + count : int; 4564 + } 4565 + 4566 + let t_jsont : t Jsont.t = 4567 + Jsont.Object.map ~kind:"t" 4568 + (fun count -> { count }) 4569 + |> Jsont.Object.mem "count" Jsont.int ~enc:(fun r -> r.count) 4570 + |> Jsont.Object.skip_unknown 4571 + |> Jsont.Object.finish 4572 + end 4573 + 4574 + module TagCreateDto = struct 4575 + type t = { 4576 + color : string option; 4577 + name : string; 4578 + parent_id : string option; 4579 + } 4580 + 4581 + let t_jsont : t Jsont.t = 4582 + Jsont.Object.map ~kind:"t" 4583 + (fun color name parent_id -> { color; name; parent_id }) 4584 + |> Jsont.Object.opt_mem "color" Jsont.string ~enc:(fun r -> r.color) 4585 + |> Jsont.Object.mem "name" Jsont.string ~enc:(fun r -> r.name) 4586 + |> Jsont.Object.opt_mem "parentId" Jsont.string ~enc:(fun r -> r.parent_id) 4587 + |> Jsont.Object.skip_unknown 4588 + |> Jsont.Object.finish 4589 + end 4590 + 4591 + module TagResponseDto = struct 4592 + type t = { 4593 + color : string option; 4594 + created_at : Ptime.t; 4595 + id : string; 4596 + name : string; 4597 + parent_id : string option; 4598 + updated_at : Ptime.t; 4599 + value : string; 4600 + } 4601 + 4602 + let t_jsont : t Jsont.t = 4603 + Jsont.Object.map ~kind:"t" 4604 + (fun color created_at id name parent_id updated_at value -> { color; created_at; id; name; parent_id; updated_at; value }) 4605 + |> Jsont.Object.opt_mem "color" Jsont.string ~enc:(fun r -> r.color) 4606 + |> Jsont.Object.mem "createdAt" Openapi.Runtime.ptime_jsont ~enc:(fun r -> r.created_at) 4607 + |> Jsont.Object.mem "id" Jsont.string ~enc:(fun r -> r.id) 4608 + |> Jsont.Object.mem "name" Jsont.string ~enc:(fun r -> r.name) 4609 + |> Jsont.Object.opt_mem "parentId" Jsont.string ~enc:(fun r -> r.parent_id) 4610 + |> Jsont.Object.mem "updatedAt" Openapi.Runtime.ptime_jsont ~enc:(fun r -> r.updated_at) 4611 + |> Jsont.Object.mem "value" Jsont.string ~enc:(fun r -> r.value) 4612 + |> Jsont.Object.skip_unknown 4613 + |> Jsont.Object.finish 4614 + end 4615 + 4616 + module TagUpdateDto = struct 4617 + type t = { 4618 + color : string option; 4619 + } 4620 + 4621 + let t_jsont : t Jsont.t = 4622 + Jsont.Object.map ~kind:"t" 4623 + (fun color -> { color }) 4624 + |> Jsont.Object.opt_mem "color" Jsont.string ~enc:(fun r -> r.color) 4625 + |> Jsont.Object.skip_unknown 4626 + |> Jsont.Object.finish 4627 + end 4628 + 4629 + module TagUpsertDto = struct 4630 + type t = { 4631 + tags : string list; 4632 + } 4633 + 4634 + let t_jsont : t Jsont.t = 4635 + Jsont.Object.map ~kind:"t" 4636 + (fun tags -> { tags }) 4637 + |> Jsont.Object.mem "tags" Jsont.(list Jsont.string) ~enc:(fun r -> r.tags) 4638 + |> Jsont.Object.skip_unknown 4639 + |> Jsont.Object.finish 4640 + end 4641 + 4642 + module TagsResponse = struct 4643 + type t = { 4644 + enabled : bool; 4645 + sidebar_web : bool; 4646 + } 4647 + 4648 + let t_jsont : t Jsont.t = 4649 + Jsont.Object.map ~kind:"t" 4650 + (fun enabled sidebar_web -> { enabled; sidebar_web }) 4651 + |> Jsont.Object.mem "enabled" Jsont.bool ~enc:(fun r -> r.enabled) 4652 + |> Jsont.Object.mem "sidebarWeb" Jsont.bool ~enc:(fun r -> r.sidebar_web) 4653 + |> Jsont.Object.skip_unknown 4654 + |> Jsont.Object.finish 4655 + end 4656 + 4657 + module TagsUpdate = struct 4658 + type t = { 4659 + enabled : bool option; 4660 + sidebar_web : bool option; 4661 + } 4662 + 4663 + let t_jsont : t Jsont.t = 4664 + Jsont.Object.map ~kind:"t" 4665 + (fun enabled sidebar_web -> { enabled; sidebar_web }) 4666 + |> Jsont.Object.opt_mem "enabled" Jsont.bool ~enc:(fun r -> r.enabled) 4667 + |> Jsont.Object.opt_mem "sidebarWeb" Jsont.bool ~enc:(fun r -> r.sidebar_web) 4668 + |> Jsont.Object.skip_unknown 4669 + |> Jsont.Object.finish 4670 + end 4671 + 4672 + module TemplateDto = struct 4673 + type t = { 4674 + template : string; 4675 + } 4676 + 4677 + let t_jsont : t Jsont.t = 4678 + Jsont.Object.map ~kind:"t" 4679 + (fun template -> { template }) 4680 + |> Jsont.Object.mem "template" Jsont.string ~enc:(fun r -> r.template) 4681 + |> Jsont.Object.skip_unknown 4682 + |> Jsont.Object.finish 4683 + end 4684 + 4685 + module TemplateResponseDto = struct 4686 + type t = { 4687 + html : string; 4688 + name : string; 4689 + } 4690 + 4691 + let t_jsont : t Jsont.t = 4692 + Jsont.Object.map ~kind:"t" 4693 + (fun html name -> { html; name }) 4694 + |> Jsont.Object.mem "html" Jsont.string ~enc:(fun r -> r.html) 4695 + |> Jsont.Object.mem "name" Jsont.string ~enc:(fun r -> r.name) 4696 + |> Jsont.Object.skip_unknown 4697 + |> Jsont.Object.finish 4698 + end 4699 + 4700 + module TestEmailResponseDto = struct 4701 + type t = { 4702 + message_id : string; 4703 + } 4704 + 4705 + let t_jsont : t Jsont.t = 4706 + Jsont.Object.map ~kind:"t" 4707 + (fun message_id -> { message_id }) 4708 + |> Jsont.Object.mem "messageId" Jsont.string ~enc:(fun r -> r.message_id) 4709 + |> Jsont.Object.skip_unknown 4710 + |> Jsont.Object.finish 4711 + end 4712 + 4713 + module TimeBucketsResponseDto = struct 4714 + type t = { 4715 + count : int; (** Number of assets in this time bucket *) 4716 + time_bucket : string; (** Time bucket identifier in YYYY-MM-DD format representing the start of the time period *) 4717 + } 4718 + 4719 + let t_jsont : t Jsont.t = 4720 + Jsont.Object.map ~kind:"t" 4721 + (fun count time_bucket -> { count; time_bucket }) 4722 + |> Jsont.Object.mem "count" Jsont.int ~enc:(fun r -> r.count) 4723 + |> Jsont.Object.mem "timeBucket" Jsont.string ~enc:(fun r -> r.time_bucket) 4724 + |> Jsont.Object.skip_unknown 4725 + |> Jsont.Object.finish 4726 + end 4727 + 4728 + module ToneMapping = struct 4729 + type t = 4730 + | Hable 4731 + | Mobius 4732 + | Reinhard 4733 + | Disabled 4734 + 4735 + let t_jsont : t Jsont.t = 4736 + Jsont.map Jsont.string ~kind:"t" 4737 + ~dec:(function 4738 + | "hable" -> Hable 4739 + | "mobius" -> Mobius 4740 + | "reinhard" -> Reinhard 4741 + | "disabled" -> Disabled 4742 + | s -> Jsont.Error.msgf Jsont.Meta.none "Unknown t: %s" s) 4743 + ~enc:(function 4744 + | Hable -> "hable" 4745 + | Mobius -> "mobius" 4746 + | Reinhard -> "reinhard" 4747 + | Disabled -> "disabled") 4748 + end 4749 + 4750 + module TranscodeHwaccel = struct 4751 + type t = 4752 + | Nvenc 4753 + | Qsv 4754 + | Vaapi 4755 + | Rkmpp 4756 + | Disabled 4757 + 4758 + let t_jsont : t Jsont.t = 4759 + Jsont.map Jsont.string ~kind:"t" 4760 + ~dec:(function 4761 + | "nvenc" -> Nvenc 4762 + | "qsv" -> Qsv 4763 + | "vaapi" -> Vaapi 4764 + | "rkmpp" -> Rkmpp 4765 + | "disabled" -> Disabled 4766 + | s -> Jsont.Error.msgf Jsont.Meta.none "Unknown t: %s" s) 4767 + ~enc:(function 4768 + | Nvenc -> "nvenc" 4769 + | Qsv -> "qsv" 4770 + | Vaapi -> "vaapi" 4771 + | Rkmpp -> "rkmpp" 4772 + | Disabled -> "disabled") 4773 + end 4774 + 4775 + module TranscodePolicy = struct 4776 + type t = 4777 + | All 4778 + | Optimal 4779 + | Bitrate 4780 + | Required 4781 + | Disabled 4782 + 4783 + let t_jsont : t Jsont.t = 4784 + Jsont.map Jsont.string ~kind:"t" 4785 + ~dec:(function 4786 + | "all" -> All 4787 + | "optimal" -> Optimal 4788 + | "bitrate" -> Bitrate 4789 + | "required" -> Required 4790 + | "disabled" -> Disabled 4791 + | s -> Jsont.Error.msgf Jsont.Meta.none "Unknown t: %s" s) 4792 + ~enc:(function 4793 + | All -> "all" 4794 + | Optimal -> "optimal" 4795 + | Bitrate -> "bitrate" 4796 + | Required -> "required" 4797 + | Disabled -> "disabled") 4798 + end 4799 + 4800 + module TrashResponseDto = struct 4801 + type t = { 4802 + count : int; 4803 + } 4804 + 4805 + let t_jsont : t Jsont.t = 4806 + Jsont.Object.map ~kind:"t" 4807 + (fun count -> { count }) 4808 + |> Jsont.Object.mem "count" Jsont.int ~enc:(fun r -> r.count) 4809 + |> Jsont.Object.skip_unknown 4810 + |> Jsont.Object.finish 4811 + end 4812 + 4813 + module UpdateLibraryDto = struct 4814 + type t = { 4815 + exclusion_patterns : string list option; 4816 + import_paths : string list option; 4817 + name : string option; 4818 + } 4819 + 4820 + let t_jsont : t Jsont.t = 4821 + Jsont.Object.map ~kind:"t" 4822 + (fun exclusion_patterns import_paths name -> { exclusion_patterns; import_paths; name }) 4823 + |> Jsont.Object.opt_mem "exclusionPatterns" Jsont.(list Jsont.string) ~enc:(fun r -> r.exclusion_patterns) 4824 + |> Jsont.Object.opt_mem "importPaths" Jsont.(list Jsont.string) ~enc:(fun r -> r.import_paths) 4825 + |> Jsont.Object.opt_mem "name" Jsont.string ~enc:(fun r -> r.name) 4826 + |> Jsont.Object.skip_unknown 4827 + |> Jsont.Object.finish 4828 + end 4829 + 4830 + module UsageByUserDto = struct 4831 + type t = { 4832 + photos : int; 4833 + quota_size_in_bytes : int64; 4834 + usage : int64; 4835 + usage_photos : int64; 4836 + usage_videos : int64; 4837 + user_id : string; 4838 + user_name : string; 4839 + videos : int; 4840 + } 4841 + 4842 + let t_jsont : t Jsont.t = 4843 + Jsont.Object.map ~kind:"t" 4844 + (fun photos quota_size_in_bytes usage usage_photos usage_videos user_id user_name videos -> { photos; quota_size_in_bytes; usage; usage_photos; usage_videos; user_id; user_name; videos }) 4845 + |> Jsont.Object.mem "photos" Jsont.int ~enc:(fun r -> r.photos) 4846 + |> Jsont.Object.mem "quotaSizeInBytes" Jsont.int64 ~enc:(fun r -> r.quota_size_in_bytes) 4847 + |> Jsont.Object.mem "usage" Jsont.int64 ~enc:(fun r -> r.usage) 4848 + |> Jsont.Object.mem "usagePhotos" Jsont.int64 ~enc:(fun r -> r.usage_photos) 4849 + |> Jsont.Object.mem "usageVideos" Jsont.int64 ~enc:(fun r -> r.usage_videos) 4850 + |> Jsont.Object.mem "userId" Jsont.string ~enc:(fun r -> r.user_id) 4851 + |> Jsont.Object.mem "userName" Jsont.string ~enc:(fun r -> r.user_name) 4852 + |> Jsont.Object.mem "videos" Jsont.int ~enc:(fun r -> r.videos) 4853 + |> Jsont.Object.skip_unknown 4854 + |> Jsont.Object.finish 4855 + end 4856 + 4857 + module UserAdminDeleteDto = struct 4858 + type t = { 4859 + force : bool option; 4860 + } 4861 + 4862 + let t_jsont : t Jsont.t = 4863 + Jsont.Object.map ~kind:"t" 4864 + (fun force -> { force }) 4865 + |> Jsont.Object.opt_mem "force" Jsont.bool ~enc:(fun r -> r.force) 4866 + |> Jsont.Object.skip_unknown 4867 + |> Jsont.Object.finish 4868 + end 4869 + 4870 + module UserAvatarColor = struct 4871 + type t = 4872 + | Primary 4873 + | Pink 4874 + | Red 4875 + | Yellow 4876 + | Blue 4877 + | Green 4878 + | Purple 4879 + | Orange 4880 + | Gray 4881 + | Amber 4882 + 4883 + let t_jsont : t Jsont.t = 4884 + Jsont.map Jsont.string ~kind:"t" 4885 + ~dec:(function 4886 + | "primary" -> Primary 4887 + | "pink" -> Pink 4888 + | "red" -> Red 4889 + | "yellow" -> Yellow 4890 + | "blue" -> Blue 4891 + | "green" -> Green 4892 + | "purple" -> Purple 4893 + | "orange" -> Orange 4894 + | "gray" -> Gray 4895 + | "amber" -> Amber 4896 + | s -> Jsont.Error.msgf Jsont.Meta.none "Unknown t: %s" s) 4897 + ~enc:(function 4898 + | Primary -> "primary" 4899 + | Pink -> "pink" 4900 + | Red -> "red" 4901 + | Yellow -> "yellow" 4902 + | Blue -> "blue" 4903 + | Green -> "green" 4904 + | Purple -> "purple" 4905 + | Orange -> "orange" 4906 + | Gray -> "gray" 4907 + | Amber -> "amber") 4908 + end 4909 + 4910 + module UserLicense = struct 4911 + type t = { 4912 + activated_at : Ptime.t; 4913 + activation_key : string; 4914 + license_key : string; 4915 + } 4916 + 4917 + let t_jsont : t Jsont.t = 4918 + Jsont.Object.map ~kind:"t" 4919 + (fun activated_at activation_key license_key -> { activated_at; activation_key; license_key }) 4920 + |> Jsont.Object.mem "activatedAt" Openapi.Runtime.ptime_jsont ~enc:(fun r -> r.activated_at) 4921 + |> Jsont.Object.mem "activationKey" Jsont.string ~enc:(fun r -> r.activation_key) 4922 + |> Jsont.Object.mem "licenseKey" Jsont.string ~enc:(fun r -> r.license_key) 4923 + |> Jsont.Object.skip_unknown 4924 + |> Jsont.Object.finish 4925 + end 4926 + 4927 + module UserMetadataKey = struct 4928 + type t = 4929 + | Preferences 4930 + | License 4931 + | Onboarding 4932 + 4933 + let t_jsont : t Jsont.t = 4934 + Jsont.map Jsont.string ~kind:"t" 4935 + ~dec:(function 4936 + | "preferences" -> Preferences 4937 + | "license" -> License 4938 + | "onboarding" -> Onboarding 4939 + | s -> Jsont.Error.msgf Jsont.Meta.none "Unknown t: %s" s) 4940 + ~enc:(function 4941 + | Preferences -> "preferences" 4942 + | License -> "license" 4943 + | Onboarding -> "onboarding") 4944 + end 4945 + 4946 + module UserStatus = struct 4947 + type t = 4948 + | Active 4949 + | Removing 4950 + | Deleted 4951 + 4952 + let t_jsont : t Jsont.t = 4953 + Jsont.map Jsont.string ~kind:"t" 4954 + ~dec:(function 4955 + | "active" -> Active 4956 + | "removing" -> Removing 4957 + | "deleted" -> Deleted 4958 + | s -> Jsont.Error.msgf Jsont.Meta.none "Unknown t: %s" s) 4959 + ~enc:(function 4960 + | Active -> "active" 4961 + | Removing -> "removing" 4962 + | Deleted -> "deleted") 4963 + end 4964 + 4965 + module ValidateAccessTokenResponseDto = struct 4966 + type t = { 4967 + auth_status : bool; 4968 + } 4969 + 4970 + let t_jsont : t Jsont.t = 4971 + Jsont.Object.map ~kind:"t" 4972 + (fun auth_status -> { auth_status }) 4973 + |> Jsont.Object.mem "authStatus" Jsont.bool ~enc:(fun r -> r.auth_status) 4974 + |> Jsont.Object.skip_unknown 4975 + |> Jsont.Object.finish 4976 + end 4977 + 4978 + module ValidateLibraryDto = struct 4979 + type t = { 4980 + exclusion_patterns : string list option; 4981 + import_paths : string list option; 4982 + } 4983 + 4984 + let t_jsont : t Jsont.t = 4985 + Jsont.Object.map ~kind:"t" 4986 + (fun exclusion_patterns import_paths -> { exclusion_patterns; import_paths }) 4987 + |> Jsont.Object.opt_mem "exclusionPatterns" Jsont.(list Jsont.string) ~enc:(fun r -> r.exclusion_patterns) 4988 + |> Jsont.Object.opt_mem "importPaths" Jsont.(list Jsont.string) ~enc:(fun r -> r.import_paths) 4989 + |> Jsont.Object.skip_unknown 4990 + |> Jsont.Object.finish 4991 + end 4992 + 4993 + module ValidateLibraryImportPathResponseDto = struct 4994 + type t = { 4995 + import_path : string; 4996 + is_valid : bool; 4997 + message : string option; 4998 + } 4999 + 5000 + let t_jsont : t Jsont.t = 5001 + Jsont.Object.map ~kind:"t" 5002 + (fun import_path is_valid message -> { import_path; is_valid; message }) 5003 + |> Jsont.Object.mem "importPath" Jsont.string ~enc:(fun r -> r.import_path) 5004 + |> Jsont.Object.mem "isValid" Jsont.bool ~enc:(fun r -> r.is_valid) 5005 + |> Jsont.Object.opt_mem "message" Jsont.string ~enc:(fun r -> r.message) 5006 + |> Jsont.Object.skip_unknown 5007 + |> Jsont.Object.finish 5008 + end 5009 + 5010 + module VersionCheckStateResponseDto = struct 5011 + type t = { 5012 + checked_at : string; 5013 + release_version : string; 5014 + } 5015 + 5016 + let t_jsont : t Jsont.t = 5017 + Jsont.Object.map ~kind:"t" 5018 + (fun checked_at release_version -> { checked_at; release_version }) 5019 + |> Jsont.Object.mem "checkedAt" Jsont.string ~enc:(fun r -> r.checked_at) 5020 + |> Jsont.Object.mem "releaseVersion" Jsont.string ~enc:(fun r -> r.release_version) 5021 + |> Jsont.Object.skip_unknown 5022 + |> Jsont.Object.finish 5023 + end 5024 + 5025 + module VideoCodec = struct 5026 + type t = 5027 + | H264 5028 + | Hevc 5029 + | Vp9 5030 + | Av1 5031 + 5032 + let t_jsont : t Jsont.t = 5033 + Jsont.map Jsont.string ~kind:"t" 5034 + ~dec:(function 5035 + | "h264" -> H264 5036 + | "hevc" -> Hevc 5037 + | "vp9" -> Vp9 5038 + | "av1" -> Av1 5039 + | s -> Jsont.Error.msgf Jsont.Meta.none "Unknown t: %s" s) 5040 + ~enc:(function 5041 + | H264 -> "h264" 5042 + | Hevc -> "hevc" 5043 + | Vp9 -> "vp9" 5044 + | Av1 -> "av1") 5045 + end 5046 + 5047 + module VideoContainer = struct 5048 + type t = 5049 + | Mov 5050 + | Mp4 5051 + | Ogg 5052 + | Webm 5053 + 5054 + let t_jsont : t Jsont.t = 5055 + Jsont.map Jsont.string ~kind:"t" 5056 + ~dec:(function 5057 + | "mov" -> Mov 5058 + | "mp4" -> Mp4 5059 + | "ogg" -> Ogg 5060 + | "webm" -> Webm 5061 + | s -> Jsont.Error.msgf Jsont.Meta.none "Unknown t: %s" s) 5062 + ~enc:(function 5063 + | Mov -> "mov" 5064 + | Mp4 -> "mp4" 5065 + | Ogg -> "ogg" 5066 + | Webm -> "webm") 5067 + end 5068 + 5069 + module WorkflowActionItemDto = struct 5070 + type t = { 5071 + action_config : Jsont.json option; 5072 + plugin_action_id : string; 5073 + } 5074 + 5075 + let t_jsont : t Jsont.t = 5076 + Jsont.Object.map ~kind:"t" 5077 + (fun action_config plugin_action_id -> { action_config; plugin_action_id }) 5078 + |> Jsont.Object.opt_mem "actionConfig" Jsont.json ~enc:(fun r -> r.action_config) 5079 + |> Jsont.Object.mem "pluginActionId" Jsont.string ~enc:(fun r -> r.plugin_action_id) 5080 + |> Jsont.Object.skip_unknown 5081 + |> Jsont.Object.finish 5082 + end 5083 + 5084 + module WorkflowActionResponseDto = struct 5085 + type t = { 5086 + action_config : Jsont.json; 5087 + id : string; 5088 + order : float; 5089 + plugin_action_id : string; 5090 + workflow_id : string; 5091 + } 5092 + 5093 + let t_jsont : t Jsont.t = 5094 + Jsont.Object.map ~kind:"t" 5095 + (fun action_config id order plugin_action_id workflow_id -> { action_config; id; order; plugin_action_id; workflow_id }) 5096 + |> Jsont.Object.mem "actionConfig" Jsont.json ~enc:(fun r -> r.action_config) 5097 + |> Jsont.Object.mem "id" Jsont.string ~enc:(fun r -> r.id) 5098 + |> Jsont.Object.mem "order" Jsont.number ~enc:(fun r -> r.order) 5099 + |> Jsont.Object.mem "pluginActionId" Jsont.string ~enc:(fun r -> r.plugin_action_id) 5100 + |> Jsont.Object.mem "workflowId" Jsont.string ~enc:(fun r -> r.workflow_id) 5101 + |> Jsont.Object.skip_unknown 5102 + |> Jsont.Object.finish 5103 + end 5104 + 5105 + module WorkflowFilterItemDto = struct 5106 + type t = { 5107 + filter_config : Jsont.json option; 5108 + plugin_filter_id : string; 5109 + } 5110 + 5111 + let t_jsont : t Jsont.t = 5112 + Jsont.Object.map ~kind:"t" 5113 + (fun filter_config plugin_filter_id -> { filter_config; plugin_filter_id }) 5114 + |> Jsont.Object.opt_mem "filterConfig" Jsont.json ~enc:(fun r -> r.filter_config) 5115 + |> Jsont.Object.mem "pluginFilterId" Jsont.string ~enc:(fun r -> r.plugin_filter_id) 5116 + |> Jsont.Object.skip_unknown 5117 + |> Jsont.Object.finish 5118 + end 5119 + 5120 + module WorkflowFilterResponseDto = struct 5121 + type t = { 5122 + filter_config : Jsont.json; 5123 + id : string; 5124 + order : float; 5125 + plugin_filter_id : string; 5126 + workflow_id : string; 5127 + } 5128 + 5129 + let t_jsont : t Jsont.t = 5130 + Jsont.Object.map ~kind:"t" 5131 + (fun filter_config id order plugin_filter_id workflow_id -> { filter_config; id; order; plugin_filter_id; workflow_id }) 5132 + |> Jsont.Object.mem "filterConfig" Jsont.json ~enc:(fun r -> r.filter_config) 5133 + |> Jsont.Object.mem "id" Jsont.string ~enc:(fun r -> r.id) 5134 + |> Jsont.Object.mem "order" Jsont.number ~enc:(fun r -> r.order) 5135 + |> Jsont.Object.mem "pluginFilterId" Jsont.string ~enc:(fun r -> r.plugin_filter_id) 5136 + |> Jsont.Object.mem "workflowId" Jsont.string ~enc:(fun r -> r.workflow_id) 5137 + |> Jsont.Object.skip_unknown 5138 + |> Jsont.Object.finish 5139 + end 5140 + 5141 + module AlbumUserAddDto = struct 5142 + type t = { 5143 + role : Jsont.json option; 5144 + user_id : string; 5145 + } 5146 + 5147 + let t_jsont : t Jsont.t = 5148 + Jsont.Object.map ~kind:"t" 5149 + (fun role user_id -> { role; user_id }) 5150 + |> Jsont.Object.opt_mem "role" Jsont.json ~enc:(fun r -> r.role) 5151 + |> Jsont.Object.mem "userId" Jsont.string ~enc:(fun r -> r.user_id) 5152 + |> Jsont.Object.skip_unknown 5153 + |> Jsont.Object.finish 5154 + end 5155 + 5156 + module AlbumUserCreateDto = struct 5157 + type t = { 5158 + role : Jsont.json; 5159 + user_id : string; 5160 + } 5161 + 5162 + let t_jsont : t Jsont.t = 5163 + Jsont.Object.map ~kind:"t" 5164 + (fun role user_id -> { role; user_id }) 5165 + |> Jsont.Object.mem "role" Jsont.json ~enc:(fun r -> r.role) 5166 + |> Jsont.Object.mem "userId" Jsont.string ~enc:(fun r -> r.user_id) 5167 + |> Jsont.Object.skip_unknown 5168 + |> Jsont.Object.finish 5169 + end 5170 + 5171 + module SyncAlbumUserV1 = struct 5172 + type t = { 5173 + album_id : string; 5174 + role : Jsont.json; 5175 + user_id : string; 5176 + } 5177 + 5178 + let t_jsont : t Jsont.t = 5179 + Jsont.Object.map ~kind:"t" 5180 + (fun album_id role user_id -> { album_id; role; user_id }) 5181 + |> Jsont.Object.mem "albumId" Jsont.string ~enc:(fun r -> r.album_id) 5182 + |> Jsont.Object.mem "role" Jsont.json ~enc:(fun r -> r.role) 5183 + |> Jsont.Object.mem "userId" Jsont.string ~enc:(fun r -> r.user_id) 5184 + |> Jsont.Object.skip_unknown 5185 + |> Jsont.Object.finish 5186 + end 5187 + 5188 + module UpdateAlbumUserDto = struct 5189 + type t = { 5190 + role : Jsont.json; 5191 + } 5192 + 5193 + let t_jsont : t Jsont.t = 5194 + Jsont.Object.map ~kind:"t" 5195 + (fun role -> { role }) 5196 + |> Jsont.Object.mem "role" Jsont.json ~enc:(fun r -> r.role) 5197 + |> Jsont.Object.skip_unknown 5198 + |> Jsont.Object.finish 5199 + end 5200 + 5201 + module AssetBulkUploadCheckDto = struct 5202 + type t = { 5203 + assets : AssetBulkUploadCheckItem.t list; 5204 + } 5205 + 5206 + let t_jsont : t Jsont.t = 5207 + Jsont.Object.map ~kind:"t" 5208 + (fun assets -> { assets }) 5209 + |> Jsont.Object.mem "assets" Jsont.(list AssetBulkUploadCheckItem.t_jsont) ~enc:(fun r -> r.assets) 5210 + |> Jsont.Object.skip_unknown 5211 + |> Jsont.Object.finish 5212 + end 5213 + 5214 + module AssetBulkUploadCheckResponseDto = struct 5215 + type t = { 5216 + results : AssetBulkUploadCheckResult.t list; 5217 + } 5218 + 5219 + let t_jsont : t Jsont.t = 5220 + Jsont.Object.map ~kind:"t" 5221 + (fun results -> { results }) 5222 + |> Jsont.Object.mem "results" Jsont.(list AssetBulkUploadCheckResult.t_jsont) ~enc:(fun r -> r.results) 5223 + |> Jsont.Object.skip_unknown 5224 + |> Jsont.Object.finish 5225 + end 5226 + 5227 + module AssetFaceUpdateDto = struct 5228 + type t = { 5229 + data : AssetFaceUpdateItem.t list; 5230 + } 5231 + 5232 + let t_jsont : t Jsont.t = 5233 + Jsont.Object.map ~kind:"t" 5234 + (fun data -> { data }) 5235 + |> Jsont.Object.mem "data" Jsont.(list AssetFaceUpdateItem.t_jsont) ~enc:(fun r -> r.data) 5236 + |> Jsont.Object.skip_unknown 5237 + |> Jsont.Object.finish 5238 + end 5239 + 5240 + module AssetJobsDto = struct 5241 + type t = { 5242 + asset_ids : string list; 5243 + name : Jsont.json; 5244 + } 5245 + 5246 + let t_jsont : t Jsont.t = 5247 + Jsont.Object.map ~kind:"t" 5248 + (fun asset_ids name -> { asset_ids; name }) 5249 + |> Jsont.Object.mem "assetIds" Jsont.(list Jsont.string) ~enc:(fun r -> r.asset_ids) 5250 + |> Jsont.Object.mem "name" Jsont.json ~enc:(fun r -> r.name) 5251 + |> Jsont.Object.skip_unknown 5252 + |> Jsont.Object.finish 5253 + end 5254 + 5255 + module AssetMediaResponseDto = struct 5256 + type t = { 5257 + id : string; 5258 + status : Jsont.json; 5259 + } 5260 + 5261 + let t_jsont : t Jsont.t = 5262 + Jsont.Object.map ~kind:"t" 5263 + (fun id status -> { id; status }) 5264 + |> Jsont.Object.mem "id" Jsont.string ~enc:(fun r -> r.id) 5265 + |> Jsont.Object.mem "status" Jsont.json ~enc:(fun r -> r.status) 5266 + |> Jsont.Object.skip_unknown 5267 + |> Jsont.Object.finish 5268 + end 5269 + 5270 + module AssetMetadataBulkDeleteDto = struct 5271 + type t = { 5272 + items : AssetMetadataBulkDeleteItemDto.t list; 5273 + } 5274 + 5275 + let t_jsont : t Jsont.t = 5276 + Jsont.Object.map ~kind:"t" 5277 + (fun items -> { items }) 5278 + |> Jsont.Object.mem "items" Jsont.(list AssetMetadataBulkDeleteItemDto.t_jsont) ~enc:(fun r -> r.items) 5279 + |> Jsont.Object.skip_unknown 5280 + |> Jsont.Object.finish 5281 + end 5282 + 5283 + module AssetMetadataBulkUpsertDto = struct 5284 + type t = { 5285 + items : AssetMetadataBulkUpsertItemDto.t list; 5286 + } 5287 + 5288 + let t_jsont : t Jsont.t = 5289 + Jsont.Object.map ~kind:"t" 5290 + (fun items -> { items }) 5291 + |> Jsont.Object.mem "items" Jsont.(list AssetMetadataBulkUpsertItemDto.t_jsont) ~enc:(fun r -> r.items) 5292 + |> Jsont.Object.skip_unknown 5293 + |> Jsont.Object.finish 5294 + end 5295 + 5296 + module AssetMetadataUpsertDto = struct 5297 + type t = { 5298 + items : AssetMetadataUpsertItemDto.t list; 5299 + } 5300 + 5301 + let t_jsont : t Jsont.t = 5302 + Jsont.Object.map ~kind:"t" 5303 + (fun items -> { items }) 5304 + |> Jsont.Object.mem "items" Jsont.(list AssetMetadataUpsertItemDto.t_jsont) ~enc:(fun r -> r.items) 5305 + |> Jsont.Object.skip_unknown 5306 + |> Jsont.Object.finish 5307 + end 5308 + 5309 + module AlbumsResponse = struct 5310 + type t = { 5311 + default_asset_order : Jsont.json; 5312 + } 5313 + 5314 + let t_jsont : t Jsont.t = 5315 + Jsont.Object.map ~kind:"t" 5316 + (fun default_asset_order -> { default_asset_order }) 5317 + |> Jsont.Object.mem "defaultAssetOrder" Jsont.json ~enc:(fun r -> r.default_asset_order) 5318 + |> Jsont.Object.skip_unknown 5319 + |> Jsont.Object.finish 5320 + end 5321 + 5322 + module AlbumsUpdate = struct 5323 + type t = { 5324 + default_asset_order : Jsont.json option; 5325 + } 5326 + 5327 + let t_jsont : t Jsont.t = 5328 + Jsont.Object.map ~kind:"t" 5329 + (fun default_asset_order -> { default_asset_order }) 5330 + |> Jsont.Object.opt_mem "defaultAssetOrder" Jsont.json ~enc:(fun r -> r.default_asset_order) 5331 + |> Jsont.Object.skip_unknown 5332 + |> Jsont.Object.finish 5333 + end 5334 + 5335 + module SyncAlbumV1 = struct 5336 + type t = { 5337 + created_at : Ptime.t; 5338 + description : string; 5339 + id : string; 5340 + is_activity_enabled : bool; 5341 + name : string; 5342 + order : Jsont.json; 5343 + owner_id : string; 5344 + thumbnail_asset_id : string; 5345 + updated_at : Ptime.t; 5346 + } 5347 + 5348 + let t_jsont : t Jsont.t = 5349 + Jsont.Object.map ~kind:"t" 5350 + (fun created_at description id is_activity_enabled name order owner_id thumbnail_asset_id updated_at -> { created_at; description; id; is_activity_enabled; name; order; owner_id; thumbnail_asset_id; updated_at }) 5351 + |> Jsont.Object.mem "createdAt" Openapi.Runtime.ptime_jsont ~enc:(fun r -> r.created_at) 5352 + |> Jsont.Object.mem "description" Jsont.string ~enc:(fun r -> r.description) 5353 + |> Jsont.Object.mem "id" Jsont.string ~enc:(fun r -> r.id) 5354 + |> Jsont.Object.mem "isActivityEnabled" Jsont.bool ~enc:(fun r -> r.is_activity_enabled) 5355 + |> Jsont.Object.mem "name" Jsont.string ~enc:(fun r -> r.name) 5356 + |> Jsont.Object.mem "order" Jsont.json ~enc:(fun r -> r.order) 5357 + |> Jsont.Object.mem "ownerId" Jsont.string ~enc:(fun r -> r.owner_id) 5358 + |> Jsont.Object.mem "thumbnailAssetId" Jsont.string ~enc:(fun r -> r.thumbnail_asset_id) 5359 + |> Jsont.Object.mem "updatedAt" Openapi.Runtime.ptime_jsont ~enc:(fun r -> r.updated_at) 5360 + |> Jsont.Object.skip_unknown 5361 + |> Jsont.Object.finish 5362 + end 5363 + 5364 + module UpdateAlbumDto = struct 5365 + type t = { 5366 + album_name : string option; 5367 + album_thumbnail_asset_id : string option; 5368 + description : string option; 5369 + is_activity_enabled : bool option; 5370 + order : Jsont.json option; 5371 + } 5372 + 5373 + let t_jsont : t Jsont.t = 5374 + Jsont.Object.map ~kind:"t" 5375 + (fun album_name album_thumbnail_asset_id description is_activity_enabled order -> { album_name; album_thumbnail_asset_id; description; is_activity_enabled; order }) 5376 + |> Jsont.Object.opt_mem "albumName" Jsont.string ~enc:(fun r -> r.album_name) 5377 + |> Jsont.Object.opt_mem "albumThumbnailAssetId" Jsont.string ~enc:(fun r -> r.album_thumbnail_asset_id) 5378 + |> Jsont.Object.opt_mem "description" Jsont.string ~enc:(fun r -> r.description) 5379 + |> Jsont.Object.opt_mem "isActivityEnabled" Jsont.bool ~enc:(fun r -> r.is_activity_enabled) 5380 + |> Jsont.Object.opt_mem "order" Jsont.json ~enc:(fun r -> r.order) 5381 + |> Jsont.Object.skip_unknown 5382 + |> Jsont.Object.finish 5383 + end 5384 + 5385 + module AssetBulkUpdateDto = struct 5386 + type t = { 5387 + date_time_original : string option; 5388 + date_time_relative : float option; 5389 + description : string option; 5390 + duplicate_id : string option; 5391 + ids : string list; 5392 + is_favorite : bool option; 5393 + latitude : float option; 5394 + longitude : float option; 5395 + rating : float option; 5396 + time_zone : string option; 5397 + visibility : Jsont.json option; 5398 + } 5399 + 5400 + let t_jsont : t Jsont.t = 5401 + Jsont.Object.map ~kind:"t" 5402 + (fun date_time_original date_time_relative description duplicate_id ids is_favorite latitude longitude rating time_zone visibility -> { date_time_original; date_time_relative; description; duplicate_id; ids; is_favorite; latitude; longitude; rating; time_zone; visibility }) 5403 + |> Jsont.Object.opt_mem "dateTimeOriginal" Jsont.string ~enc:(fun r -> r.date_time_original) 5404 + |> Jsont.Object.opt_mem "dateTimeRelative" Jsont.number ~enc:(fun r -> r.date_time_relative) 5405 + |> Jsont.Object.opt_mem "description" Jsont.string ~enc:(fun r -> r.description) 5406 + |> Jsont.Object.opt_mem "duplicateId" Jsont.string ~enc:(fun r -> r.duplicate_id) 5407 + |> Jsont.Object.mem "ids" Jsont.(list Jsont.string) ~enc:(fun r -> r.ids) 5408 + |> Jsont.Object.opt_mem "isFavorite" Jsont.bool ~enc:(fun r -> r.is_favorite) 5409 + |> Jsont.Object.opt_mem "latitude" Jsont.number ~enc:(fun r -> r.latitude) 5410 + |> Jsont.Object.opt_mem "longitude" Jsont.number ~enc:(fun r -> r.longitude) 5411 + |> Jsont.Object.opt_mem "rating" Jsont.number ~enc:(fun r -> r.rating) 5412 + |> Jsont.Object.opt_mem "timeZone" Jsont.string ~enc:(fun r -> r.time_zone) 5413 + |> Jsont.Object.opt_mem "visibility" Jsont.json ~enc:(fun r -> r.visibility) 5414 + |> Jsont.Object.skip_unknown 5415 + |> Jsont.Object.finish 5416 + end 5417 + 5418 + module AssetMediaCreateDto = struct 5419 + type t = { 5420 + asset_data : string; 5421 + device_asset_id : string; 5422 + device_id : string; 5423 + duration : string option; 5424 + file_created_at : Ptime.t; 5425 + file_modified_at : Ptime.t; 5426 + filename : string option; 5427 + is_favorite : bool option; 5428 + live_photo_video_id : string option; 5429 + metadata : AssetMetadataUpsertItemDto.t list option; 5430 + sidecar_data : string option; 5431 + visibility : Jsont.json option; 5432 + } 5433 + 5434 + let t_jsont : t Jsont.t = 5435 + Jsont.Object.map ~kind:"t" 5436 + (fun asset_data device_asset_id device_id duration file_created_at file_modified_at filename is_favorite live_photo_video_id metadata sidecar_data visibility -> { asset_data; device_asset_id; device_id; duration; file_created_at; file_modified_at; filename; is_favorite; live_photo_video_id; metadata; sidecar_data; visibility }) 5437 + |> Jsont.Object.mem "assetData" Jsont.string ~enc:(fun r -> r.asset_data) 5438 + |> Jsont.Object.mem "deviceAssetId" Jsont.string ~enc:(fun r -> r.device_asset_id) 5439 + |> Jsont.Object.mem "deviceId" Jsont.string ~enc:(fun r -> r.device_id) 5440 + |> Jsont.Object.opt_mem "duration" Jsont.string ~enc:(fun r -> r.duration) 5441 + |> Jsont.Object.mem "fileCreatedAt" Openapi.Runtime.ptime_jsont ~enc:(fun r -> r.file_created_at) 5442 + |> Jsont.Object.mem "fileModifiedAt" Openapi.Runtime.ptime_jsont ~enc:(fun r -> r.file_modified_at) 5443 + |> Jsont.Object.opt_mem "filename" Jsont.string ~enc:(fun r -> r.filename) 5444 + |> Jsont.Object.opt_mem "isFavorite" Jsont.bool ~enc:(fun r -> r.is_favorite) 5445 + |> Jsont.Object.opt_mem "livePhotoVideoId" Jsont.string ~enc:(fun r -> r.live_photo_video_id) 5446 + |> Jsont.Object.opt_mem "metadata" Jsont.(list AssetMetadataUpsertItemDto.t_jsont) ~enc:(fun r -> r.metadata) 5447 + |> Jsont.Object.opt_mem "sidecarData" Jsont.string ~enc:(fun r -> r.sidecar_data) 5448 + |> Jsont.Object.opt_mem "visibility" Jsont.json ~enc:(fun r -> r.visibility) 5449 + |> Jsont.Object.skip_unknown 5450 + |> Jsont.Object.finish 5451 + end 5452 + 5453 + module MetadataSearchDto = struct 5454 + type t = { 5455 + album_ids : string list option; 5456 + checksum : string option; 5457 + city : string option; 5458 + country : string option; 5459 + created_after : Ptime.t option; 5460 + created_before : Ptime.t option; 5461 + description : string option; 5462 + device_asset_id : string option; 5463 + device_id : string option; 5464 + encoded_video_path : string option; 5465 + id : string option; 5466 + is_encoded : bool option; 5467 + is_favorite : bool option; 5468 + is_motion : bool option; 5469 + is_not_in_album : bool option; 5470 + is_offline : bool option; 5471 + lens_model : string option; 5472 + library_id : string option; 5473 + make : string option; 5474 + model : string option; 5475 + ocr : string option; 5476 + order : Jsont.json option; 5477 + original_file_name : string option; 5478 + original_path : string option; 5479 + page : float option; 5480 + person_ids : string list option; 5481 + preview_path : string option; 5482 + rating : float option; 5483 + size : float option; 5484 + state : string option; 5485 + tag_ids : string list option; 5486 + taken_after : Ptime.t option; 5487 + taken_before : Ptime.t option; 5488 + thumbnail_path : string option; 5489 + trashed_after : Ptime.t option; 5490 + trashed_before : Ptime.t option; 5491 + type_ : Jsont.json option; 5492 + updated_after : Ptime.t option; 5493 + updated_before : Ptime.t option; 5494 + visibility : Jsont.json option; 5495 + with_deleted : bool option; 5496 + with_exif : bool option; 5497 + with_people : bool option; 5498 + with_stacked : bool option; 5499 + } 5500 + 5501 + let t_jsont : t Jsont.t = 5502 + Jsont.Object.map ~kind:"t" 5503 + (fun album_ids checksum city country created_after created_before description device_asset_id device_id encoded_video_path id is_encoded is_favorite is_motion is_not_in_album is_offline lens_model library_id make model ocr order original_file_name original_path page person_ids preview_path rating size state tag_ids taken_after taken_before thumbnail_path trashed_after trashed_before type_ updated_after updated_before visibility with_deleted with_exif with_people with_stacked -> { album_ids; checksum; city; country; created_after; created_before; description; device_asset_id; device_id; encoded_video_path; id; is_encoded; is_favorite; is_motion; is_not_in_album; is_offline; lens_model; library_id; make; model; ocr; order; original_file_name; original_path; page; person_ids; preview_path; rating; size; state; tag_ids; taken_after; taken_before; thumbnail_path; trashed_after; trashed_before; type_; updated_after; updated_before; visibility; with_deleted; with_exif; with_people; with_stacked }) 5504 + |> Jsont.Object.opt_mem "albumIds" Jsont.(list Jsont.string) ~enc:(fun r -> r.album_ids) 5505 + |> Jsont.Object.opt_mem "checksum" Jsont.string ~enc:(fun r -> r.checksum) 5506 + |> Jsont.Object.opt_mem "city" Jsont.string ~enc:(fun r -> r.city) 5507 + |> Jsont.Object.opt_mem "country" Jsont.string ~enc:(fun r -> r.country) 5508 + |> Jsont.Object.opt_mem "createdAfter" Openapi.Runtime.ptime_jsont ~enc:(fun r -> r.created_after) 5509 + |> Jsont.Object.opt_mem "createdBefore" Openapi.Runtime.ptime_jsont ~enc:(fun r -> r.created_before) 5510 + |> Jsont.Object.opt_mem "description" Jsont.string ~enc:(fun r -> r.description) 5511 + |> Jsont.Object.opt_mem "deviceAssetId" Jsont.string ~enc:(fun r -> r.device_asset_id) 5512 + |> Jsont.Object.opt_mem "deviceId" Jsont.string ~enc:(fun r -> r.device_id) 5513 + |> Jsont.Object.opt_mem "encodedVideoPath" Jsont.string ~enc:(fun r -> r.encoded_video_path) 5514 + |> Jsont.Object.opt_mem "id" Jsont.string ~enc:(fun r -> r.id) 5515 + |> Jsont.Object.opt_mem "isEncoded" Jsont.bool ~enc:(fun r -> r.is_encoded) 5516 + |> Jsont.Object.opt_mem "isFavorite" Jsont.bool ~enc:(fun r -> r.is_favorite) 5517 + |> Jsont.Object.opt_mem "isMotion" Jsont.bool ~enc:(fun r -> r.is_motion) 5518 + |> Jsont.Object.opt_mem "isNotInAlbum" Jsont.bool ~enc:(fun r -> r.is_not_in_album) 5519 + |> Jsont.Object.opt_mem "isOffline" Jsont.bool ~enc:(fun r -> r.is_offline) 5520 + |> Jsont.Object.opt_mem "lensModel" Jsont.string ~enc:(fun r -> r.lens_model) 5521 + |> Jsont.Object.opt_mem "libraryId" Jsont.string ~enc:(fun r -> r.library_id) 5522 + |> Jsont.Object.opt_mem "make" Jsont.string ~enc:(fun r -> r.make) 5523 + |> Jsont.Object.opt_mem "model" Jsont.string ~enc:(fun r -> r.model) 5524 + |> Jsont.Object.opt_mem "ocr" Jsont.string ~enc:(fun r -> r.ocr) 5525 + |> Jsont.Object.opt_mem "order" Jsont.json ~enc:(fun r -> r.order) 5526 + |> Jsont.Object.opt_mem "originalFileName" Jsont.string ~enc:(fun r -> r.original_file_name) 5527 + |> Jsont.Object.opt_mem "originalPath" Jsont.string ~enc:(fun r -> r.original_path) 5528 + |> Jsont.Object.opt_mem "page" Jsont.number ~enc:(fun r -> r.page) 5529 + |> Jsont.Object.opt_mem "personIds" Jsont.(list Jsont.string) ~enc:(fun r -> r.person_ids) 5530 + |> Jsont.Object.opt_mem "previewPath" Jsont.string ~enc:(fun r -> r.preview_path) 5531 + |> Jsont.Object.opt_mem "rating" Jsont.number ~enc:(fun r -> r.rating) 5532 + |> Jsont.Object.opt_mem "size" Jsont.number ~enc:(fun r -> r.size) 5533 + |> Jsont.Object.opt_mem "state" Jsont.string ~enc:(fun r -> r.state) 5534 + |> Jsont.Object.opt_mem "tagIds" Jsont.(list Jsont.string) ~enc:(fun r -> r.tag_ids) 5535 + |> Jsont.Object.opt_mem "takenAfter" Openapi.Runtime.ptime_jsont ~enc:(fun r -> r.taken_after) 5536 + |> Jsont.Object.opt_mem "takenBefore" Openapi.Runtime.ptime_jsont ~enc:(fun r -> r.taken_before) 5537 + |> Jsont.Object.opt_mem "thumbnailPath" Jsont.string ~enc:(fun r -> r.thumbnail_path) 5538 + |> Jsont.Object.opt_mem "trashedAfter" Openapi.Runtime.ptime_jsont ~enc:(fun r -> r.trashed_after) 5539 + |> Jsont.Object.opt_mem "trashedBefore" Openapi.Runtime.ptime_jsont ~enc:(fun r -> r.trashed_before) 5540 + |> Jsont.Object.opt_mem "type" Jsont.json ~enc:(fun r -> r.type_) 5541 + |> Jsont.Object.opt_mem "updatedAfter" Openapi.Runtime.ptime_jsont ~enc:(fun r -> r.updated_after) 5542 + |> Jsont.Object.opt_mem "updatedBefore" Openapi.Runtime.ptime_jsont ~enc:(fun r -> r.updated_before) 5543 + |> Jsont.Object.opt_mem "visibility" Jsont.json ~enc:(fun r -> r.visibility) 5544 + |> Jsont.Object.opt_mem "withDeleted" Jsont.bool ~enc:(fun r -> r.with_deleted) 5545 + |> Jsont.Object.opt_mem "withExif" Jsont.bool ~enc:(fun r -> r.with_exif) 5546 + |> Jsont.Object.opt_mem "withPeople" Jsont.bool ~enc:(fun r -> r.with_people) 5547 + |> Jsont.Object.opt_mem "withStacked" Jsont.bool ~enc:(fun r -> r.with_stacked) 5548 + |> Jsont.Object.skip_unknown 5549 + |> Jsont.Object.finish 5550 + end 5551 + 5552 + module RandomSearchDto = struct 5553 + type t = { 5554 + album_ids : string list option; 5555 + city : string option; 5556 + country : string option; 5557 + created_after : Ptime.t option; 5558 + created_before : Ptime.t option; 5559 + device_id : string option; 5560 + is_encoded : bool option; 5561 + is_favorite : bool option; 5562 + is_motion : bool option; 5563 + is_not_in_album : bool option; 5564 + is_offline : bool option; 5565 + lens_model : string option; 5566 + library_id : string option; 5567 + make : string option; 5568 + model : string option; 5569 + ocr : string option; 5570 + person_ids : string list option; 5571 + rating : float option; 5572 + size : float option; 5573 + state : string option; 5574 + tag_ids : string list option; 5575 + taken_after : Ptime.t option; 5576 + taken_before : Ptime.t option; 5577 + trashed_after : Ptime.t option; 5578 + trashed_before : Ptime.t option; 5579 + type_ : Jsont.json option; 5580 + updated_after : Ptime.t option; 5581 + updated_before : Ptime.t option; 5582 + visibility : Jsont.json option; 5583 + with_deleted : bool option; 5584 + with_exif : bool option; 5585 + with_people : bool option; 5586 + with_stacked : bool option; 5587 + } 5588 + 5589 + let t_jsont : t Jsont.t = 5590 + Jsont.Object.map ~kind:"t" 5591 + (fun album_ids city country created_after created_before device_id is_encoded is_favorite is_motion is_not_in_album is_offline lens_model library_id make model ocr person_ids rating size state tag_ids taken_after taken_before trashed_after trashed_before type_ updated_after updated_before visibility with_deleted with_exif with_people with_stacked -> { album_ids; city; country; created_after; created_before; device_id; is_encoded; is_favorite; is_motion; is_not_in_album; is_offline; lens_model; library_id; make; model; ocr; person_ids; rating; size; state; tag_ids; taken_after; taken_before; trashed_after; trashed_before; type_; updated_after; updated_before; visibility; with_deleted; with_exif; with_people; with_stacked }) 5592 + |> Jsont.Object.opt_mem "albumIds" Jsont.(list Jsont.string) ~enc:(fun r -> r.album_ids) 5593 + |> Jsont.Object.opt_mem "city" Jsont.string ~enc:(fun r -> r.city) 5594 + |> Jsont.Object.opt_mem "country" Jsont.string ~enc:(fun r -> r.country) 5595 + |> Jsont.Object.opt_mem "createdAfter" Openapi.Runtime.ptime_jsont ~enc:(fun r -> r.created_after) 5596 + |> Jsont.Object.opt_mem "createdBefore" Openapi.Runtime.ptime_jsont ~enc:(fun r -> r.created_before) 5597 + |> Jsont.Object.opt_mem "deviceId" Jsont.string ~enc:(fun r -> r.device_id) 5598 + |> Jsont.Object.opt_mem "isEncoded" Jsont.bool ~enc:(fun r -> r.is_encoded) 5599 + |> Jsont.Object.opt_mem "isFavorite" Jsont.bool ~enc:(fun r -> r.is_favorite) 5600 + |> Jsont.Object.opt_mem "isMotion" Jsont.bool ~enc:(fun r -> r.is_motion) 5601 + |> Jsont.Object.opt_mem "isNotInAlbum" Jsont.bool ~enc:(fun r -> r.is_not_in_album) 5602 + |> Jsont.Object.opt_mem "isOffline" Jsont.bool ~enc:(fun r -> r.is_offline) 5603 + |> Jsont.Object.opt_mem "lensModel" Jsont.string ~enc:(fun r -> r.lens_model) 5604 + |> Jsont.Object.opt_mem "libraryId" Jsont.string ~enc:(fun r -> r.library_id) 5605 + |> Jsont.Object.opt_mem "make" Jsont.string ~enc:(fun r -> r.make) 5606 + |> Jsont.Object.opt_mem "model" Jsont.string ~enc:(fun r -> r.model) 5607 + |> Jsont.Object.opt_mem "ocr" Jsont.string ~enc:(fun r -> r.ocr) 5608 + |> Jsont.Object.opt_mem "personIds" Jsont.(list Jsont.string) ~enc:(fun r -> r.person_ids) 5609 + |> Jsont.Object.opt_mem "rating" Jsont.number ~enc:(fun r -> r.rating) 5610 + |> Jsont.Object.opt_mem "size" Jsont.number ~enc:(fun r -> r.size) 5611 + |> Jsont.Object.opt_mem "state" Jsont.string ~enc:(fun r -> r.state) 5612 + |> Jsont.Object.opt_mem "tagIds" Jsont.(list Jsont.string) ~enc:(fun r -> r.tag_ids) 5613 + |> Jsont.Object.opt_mem "takenAfter" Openapi.Runtime.ptime_jsont ~enc:(fun r -> r.taken_after) 5614 + |> Jsont.Object.opt_mem "takenBefore" Openapi.Runtime.ptime_jsont ~enc:(fun r -> r.taken_before) 5615 + |> Jsont.Object.opt_mem "trashedAfter" Openapi.Runtime.ptime_jsont ~enc:(fun r -> r.trashed_after) 5616 + |> Jsont.Object.opt_mem "trashedBefore" Openapi.Runtime.ptime_jsont ~enc:(fun r -> r.trashed_before) 5617 + |> Jsont.Object.opt_mem "type" Jsont.json ~enc:(fun r -> r.type_) 5618 + |> Jsont.Object.opt_mem "updatedAfter" Openapi.Runtime.ptime_jsont ~enc:(fun r -> r.updated_after) 5619 + |> Jsont.Object.opt_mem "updatedBefore" Openapi.Runtime.ptime_jsont ~enc:(fun r -> r.updated_before) 5620 + |> Jsont.Object.opt_mem "visibility" Jsont.json ~enc:(fun r -> r.visibility) 5621 + |> Jsont.Object.opt_mem "withDeleted" Jsont.bool ~enc:(fun r -> r.with_deleted) 5622 + |> Jsont.Object.opt_mem "withExif" Jsont.bool ~enc:(fun r -> r.with_exif) 5623 + |> Jsont.Object.opt_mem "withPeople" Jsont.bool ~enc:(fun r -> r.with_people) 5624 + |> Jsont.Object.opt_mem "withStacked" Jsont.bool ~enc:(fun r -> r.with_stacked) 5625 + |> Jsont.Object.skip_unknown 5626 + |> Jsont.Object.finish 5627 + end 5628 + 5629 + module SmartSearchDto = struct 5630 + type t = { 5631 + album_ids : string list option; 5632 + city : string option; 5633 + country : string option; 5634 + created_after : Ptime.t option; 5635 + created_before : Ptime.t option; 5636 + device_id : string option; 5637 + is_encoded : bool option; 5638 + is_favorite : bool option; 5639 + is_motion : bool option; 5640 + is_not_in_album : bool option; 5641 + is_offline : bool option; 5642 + language : string option; 5643 + lens_model : string option; 5644 + library_id : string option; 5645 + make : string option; 5646 + model : string option; 5647 + ocr : string option; 5648 + page : float option; 5649 + person_ids : string list option; 5650 + query : string option; 5651 + query_asset_id : string option; 5652 + rating : float option; 5653 + size : float option; 5654 + state : string option; 5655 + tag_ids : string list option; 5656 + taken_after : Ptime.t option; 5657 + taken_before : Ptime.t option; 5658 + trashed_after : Ptime.t option; 5659 + trashed_before : Ptime.t option; 5660 + type_ : Jsont.json option; 5661 + updated_after : Ptime.t option; 5662 + updated_before : Ptime.t option; 5663 + visibility : Jsont.json option; 5664 + with_deleted : bool option; 5665 + with_exif : bool option; 5666 + } 5667 + 5668 + let t_jsont : t Jsont.t = 5669 + Jsont.Object.map ~kind:"t" 5670 + (fun album_ids city country created_after created_before device_id is_encoded is_favorite is_motion is_not_in_album is_offline language lens_model library_id make model ocr page person_ids query query_asset_id rating size state tag_ids taken_after taken_before trashed_after trashed_before type_ updated_after updated_before visibility with_deleted with_exif -> { album_ids; city; country; created_after; created_before; device_id; is_encoded; is_favorite; is_motion; is_not_in_album; is_offline; language; lens_model; library_id; make; model; ocr; page; person_ids; query; query_asset_id; rating; size; state; tag_ids; taken_after; taken_before; trashed_after; trashed_before; type_; updated_after; updated_before; visibility; with_deleted; with_exif }) 5671 + |> Jsont.Object.opt_mem "albumIds" Jsont.(list Jsont.string) ~enc:(fun r -> r.album_ids) 5672 + |> Jsont.Object.opt_mem "city" Jsont.string ~enc:(fun r -> r.city) 5673 + |> Jsont.Object.opt_mem "country" Jsont.string ~enc:(fun r -> r.country) 5674 + |> Jsont.Object.opt_mem "createdAfter" Openapi.Runtime.ptime_jsont ~enc:(fun r -> r.created_after) 5675 + |> Jsont.Object.opt_mem "createdBefore" Openapi.Runtime.ptime_jsont ~enc:(fun r -> r.created_before) 5676 + |> Jsont.Object.opt_mem "deviceId" Jsont.string ~enc:(fun r -> r.device_id) 5677 + |> Jsont.Object.opt_mem "isEncoded" Jsont.bool ~enc:(fun r -> r.is_encoded) 5678 + |> Jsont.Object.opt_mem "isFavorite" Jsont.bool ~enc:(fun r -> r.is_favorite) 5679 + |> Jsont.Object.opt_mem "isMotion" Jsont.bool ~enc:(fun r -> r.is_motion) 5680 + |> Jsont.Object.opt_mem "isNotInAlbum" Jsont.bool ~enc:(fun r -> r.is_not_in_album) 5681 + |> Jsont.Object.opt_mem "isOffline" Jsont.bool ~enc:(fun r -> r.is_offline) 5682 + |> Jsont.Object.opt_mem "language" Jsont.string ~enc:(fun r -> r.language) 5683 + |> Jsont.Object.opt_mem "lensModel" Jsont.string ~enc:(fun r -> r.lens_model) 5684 + |> Jsont.Object.opt_mem "libraryId" Jsont.string ~enc:(fun r -> r.library_id) 5685 + |> Jsont.Object.opt_mem "make" Jsont.string ~enc:(fun r -> r.make) 5686 + |> Jsont.Object.opt_mem "model" Jsont.string ~enc:(fun r -> r.model) 5687 + |> Jsont.Object.opt_mem "ocr" Jsont.string ~enc:(fun r -> r.ocr) 5688 + |> Jsont.Object.opt_mem "page" Jsont.number ~enc:(fun r -> r.page) 5689 + |> Jsont.Object.opt_mem "personIds" Jsont.(list Jsont.string) ~enc:(fun r -> r.person_ids) 5690 + |> Jsont.Object.opt_mem "query" Jsont.string ~enc:(fun r -> r.query) 5691 + |> Jsont.Object.opt_mem "queryAssetId" Jsont.string ~enc:(fun r -> r.query_asset_id) 5692 + |> Jsont.Object.opt_mem "rating" Jsont.number ~enc:(fun r -> r.rating) 5693 + |> Jsont.Object.opt_mem "size" Jsont.number ~enc:(fun r -> r.size) 5694 + |> Jsont.Object.opt_mem "state" Jsont.string ~enc:(fun r -> r.state) 5695 + |> Jsont.Object.opt_mem "tagIds" Jsont.(list Jsont.string) ~enc:(fun r -> r.tag_ids) 5696 + |> Jsont.Object.opt_mem "takenAfter" Openapi.Runtime.ptime_jsont ~enc:(fun r -> r.taken_after) 5697 + |> Jsont.Object.opt_mem "takenBefore" Openapi.Runtime.ptime_jsont ~enc:(fun r -> r.taken_before) 5698 + |> Jsont.Object.opt_mem "trashedAfter" Openapi.Runtime.ptime_jsont ~enc:(fun r -> r.trashed_after) 5699 + |> Jsont.Object.opt_mem "trashedBefore" Openapi.Runtime.ptime_jsont ~enc:(fun r -> r.trashed_before) 5700 + |> Jsont.Object.opt_mem "type" Jsont.json ~enc:(fun r -> r.type_) 5701 + |> Jsont.Object.opt_mem "updatedAfter" Openapi.Runtime.ptime_jsont ~enc:(fun r -> r.updated_after) 5702 + |> Jsont.Object.opt_mem "updatedBefore" Openapi.Runtime.ptime_jsont ~enc:(fun r -> r.updated_before) 5703 + |> Jsont.Object.opt_mem "visibility" Jsont.json ~enc:(fun r -> r.visibility) 5704 + |> Jsont.Object.opt_mem "withDeleted" Jsont.bool ~enc:(fun r -> r.with_deleted) 5705 + |> Jsont.Object.opt_mem "withExif" Jsont.bool ~enc:(fun r -> r.with_exif) 5706 + |> Jsont.Object.skip_unknown 5707 + |> Jsont.Object.finish 5708 + end 5709 + 5710 + module StatisticsSearchDto = struct 5711 + type t = { 5712 + album_ids : string list option; 5713 + city : string option; 5714 + country : string option; 5715 + created_after : Ptime.t option; 5716 + created_before : Ptime.t option; 5717 + description : string option; 5718 + device_id : string option; 5719 + is_encoded : bool option; 5720 + is_favorite : bool option; 5721 + is_motion : bool option; 5722 + is_not_in_album : bool option; 5723 + is_offline : bool option; 5724 + lens_model : string option; 5725 + library_id : string option; 5726 + make : string option; 5727 + model : string option; 5728 + ocr : string option; 5729 + person_ids : string list option; 5730 + rating : float option; 5731 + state : string option; 5732 + tag_ids : string list option; 5733 + taken_after : Ptime.t option; 5734 + taken_before : Ptime.t option; 5735 + trashed_after : Ptime.t option; 5736 + trashed_before : Ptime.t option; 5737 + type_ : Jsont.json option; 5738 + updated_after : Ptime.t option; 5739 + updated_before : Ptime.t option; 5740 + visibility : Jsont.json option; 5741 + } 5742 + 5743 + let t_jsont : t Jsont.t = 5744 + Jsont.Object.map ~kind:"t" 5745 + (fun album_ids city country created_after created_before description device_id is_encoded is_favorite is_motion is_not_in_album is_offline lens_model library_id make model ocr person_ids rating state tag_ids taken_after taken_before trashed_after trashed_before type_ updated_after updated_before visibility -> { album_ids; city; country; created_after; created_before; description; device_id; is_encoded; is_favorite; is_motion; is_not_in_album; is_offline; lens_model; library_id; make; model; ocr; person_ids; rating; state; tag_ids; taken_after; taken_before; trashed_after; trashed_before; type_; updated_after; updated_before; visibility }) 5746 + |> Jsont.Object.opt_mem "albumIds" Jsont.(list Jsont.string) ~enc:(fun r -> r.album_ids) 5747 + |> Jsont.Object.opt_mem "city" Jsont.string ~enc:(fun r -> r.city) 5748 + |> Jsont.Object.opt_mem "country" Jsont.string ~enc:(fun r -> r.country) 5749 + |> Jsont.Object.opt_mem "createdAfter" Openapi.Runtime.ptime_jsont ~enc:(fun r -> r.created_after) 5750 + |> Jsont.Object.opt_mem "createdBefore" Openapi.Runtime.ptime_jsont ~enc:(fun r -> r.created_before) 5751 + |> Jsont.Object.opt_mem "description" Jsont.string ~enc:(fun r -> r.description) 5752 + |> Jsont.Object.opt_mem "deviceId" Jsont.string ~enc:(fun r -> r.device_id) 5753 + |> Jsont.Object.opt_mem "isEncoded" Jsont.bool ~enc:(fun r -> r.is_encoded) 5754 + |> Jsont.Object.opt_mem "isFavorite" Jsont.bool ~enc:(fun r -> r.is_favorite) 5755 + |> Jsont.Object.opt_mem "isMotion" Jsont.bool ~enc:(fun r -> r.is_motion) 5756 + |> Jsont.Object.opt_mem "isNotInAlbum" Jsont.bool ~enc:(fun r -> r.is_not_in_album) 5757 + |> Jsont.Object.opt_mem "isOffline" Jsont.bool ~enc:(fun r -> r.is_offline) 5758 + |> Jsont.Object.opt_mem "lensModel" Jsont.string ~enc:(fun r -> r.lens_model) 5759 + |> Jsont.Object.opt_mem "libraryId" Jsont.string ~enc:(fun r -> r.library_id) 5760 + |> Jsont.Object.opt_mem "make" Jsont.string ~enc:(fun r -> r.make) 5761 + |> Jsont.Object.opt_mem "model" Jsont.string ~enc:(fun r -> r.model) 5762 + |> Jsont.Object.opt_mem "ocr" Jsont.string ~enc:(fun r -> r.ocr) 5763 + |> Jsont.Object.opt_mem "personIds" Jsont.(list Jsont.string) ~enc:(fun r -> r.person_ids) 5764 + |> Jsont.Object.opt_mem "rating" Jsont.number ~enc:(fun r -> r.rating) 5765 + |> Jsont.Object.opt_mem "state" Jsont.string ~enc:(fun r -> r.state) 5766 + |> Jsont.Object.opt_mem "tagIds" Jsont.(list Jsont.string) ~enc:(fun r -> r.tag_ids) 5767 + |> Jsont.Object.opt_mem "takenAfter" Openapi.Runtime.ptime_jsont ~enc:(fun r -> r.taken_after) 5768 + |> Jsont.Object.opt_mem "takenBefore" Openapi.Runtime.ptime_jsont ~enc:(fun r -> r.taken_before) 5769 + |> Jsont.Object.opt_mem "trashedAfter" Openapi.Runtime.ptime_jsont ~enc:(fun r -> r.trashed_after) 5770 + |> Jsont.Object.opt_mem "trashedBefore" Openapi.Runtime.ptime_jsont ~enc:(fun r -> r.trashed_before) 5771 + |> Jsont.Object.opt_mem "type" Jsont.json ~enc:(fun r -> r.type_) 5772 + |> Jsont.Object.opt_mem "updatedAfter" Openapi.Runtime.ptime_jsont ~enc:(fun r -> r.updated_after) 5773 + |> Jsont.Object.opt_mem "updatedBefore" Openapi.Runtime.ptime_jsont ~enc:(fun r -> r.updated_before) 5774 + |> Jsont.Object.opt_mem "visibility" Jsont.json ~enc:(fun r -> r.visibility) 5775 + |> Jsont.Object.skip_unknown 5776 + |> Jsont.Object.finish 5777 + end 5778 + 5779 + module SyncAssetV1 = struct 5780 + type t = { 5781 + checksum : string; 5782 + deleted_at : Ptime.t; 5783 + duration : string; 5784 + file_created_at : Ptime.t; 5785 + file_modified_at : Ptime.t; 5786 + height : int; 5787 + id : string; 5788 + is_edited : bool; 5789 + is_favorite : bool; 5790 + library_id : string; 5791 + live_photo_video_id : string; 5792 + local_date_time : Ptime.t; 5793 + original_file_name : string; 5794 + owner_id : string; 5795 + stack_id : string; 5796 + thumbhash : string; 5797 + type_ : Jsont.json; 5798 + visibility : Jsont.json; 5799 + width : int; 5800 + } 5801 + 5802 + let t_jsont : t Jsont.t = 5803 + Jsont.Object.map ~kind:"t" 5804 + (fun checksum deleted_at duration file_created_at file_modified_at height id is_edited is_favorite library_id live_photo_video_id local_date_time original_file_name owner_id stack_id thumbhash type_ visibility width -> { checksum; deleted_at; duration; file_created_at; file_modified_at; height; id; is_edited; is_favorite; library_id; live_photo_video_id; local_date_time; original_file_name; owner_id; stack_id; thumbhash; type_; visibility; width }) 5805 + |> Jsont.Object.mem "checksum" Jsont.string ~enc:(fun r -> r.checksum) 5806 + |> Jsont.Object.mem "deletedAt" Openapi.Runtime.ptime_jsont ~enc:(fun r -> r.deleted_at) 5807 + |> Jsont.Object.mem "duration" Jsont.string ~enc:(fun r -> r.duration) 5808 + |> Jsont.Object.mem "fileCreatedAt" Openapi.Runtime.ptime_jsont ~enc:(fun r -> r.file_created_at) 5809 + |> Jsont.Object.mem "fileModifiedAt" Openapi.Runtime.ptime_jsont ~enc:(fun r -> r.file_modified_at) 5810 + |> Jsont.Object.mem "height" Jsont.int ~enc:(fun r -> r.height) 5811 + |> Jsont.Object.mem "id" Jsont.string ~enc:(fun r -> r.id) 5812 + |> Jsont.Object.mem "isEdited" Jsont.bool ~enc:(fun r -> r.is_edited) 5813 + |> Jsont.Object.mem "isFavorite" Jsont.bool ~enc:(fun r -> r.is_favorite) 5814 + |> Jsont.Object.mem "libraryId" Jsont.string ~enc:(fun r -> r.library_id) 5815 + |> Jsont.Object.mem "livePhotoVideoId" Jsont.string ~enc:(fun r -> r.live_photo_video_id) 5816 + |> Jsont.Object.mem "localDateTime" Openapi.Runtime.ptime_jsont ~enc:(fun r -> r.local_date_time) 5817 + |> Jsont.Object.mem "originalFileName" Jsont.string ~enc:(fun r -> r.original_file_name) 5818 + |> Jsont.Object.mem "ownerId" Jsont.string ~enc:(fun r -> r.owner_id) 5819 + |> Jsont.Object.mem "stackId" Jsont.string ~enc:(fun r -> r.stack_id) 5820 + |> Jsont.Object.mem "thumbhash" Jsont.string ~enc:(fun r -> r.thumbhash) 5821 + |> Jsont.Object.mem "type" Jsont.json ~enc:(fun r -> r.type_) 5822 + |> Jsont.Object.mem "visibility" Jsont.json ~enc:(fun r -> r.visibility) 5823 + |> Jsont.Object.mem "width" Jsont.int ~enc:(fun r -> r.width) 5824 + |> Jsont.Object.skip_unknown 5825 + |> Jsont.Object.finish 5826 + end 5827 + 5828 + module TimeBucketAssetResponseDto = struct 5829 + type t = { 5830 + city : string list; (** Array of city names extracted from EXIF GPS data *) 5831 + country : string list; (** Array of country names extracted from EXIF GPS data *) 5832 + duration : string list; (** Array of video durations in HH:MM:SS format (null for images) *) 5833 + file_created_at : string list; (** Array of file creation timestamps in UTC (ISO 8601 format, without timezone) *) 5834 + id : string list; (** Array of asset IDs in the time bucket *) 5835 + is_favorite : bool list; (** Array indicating whether each asset is favorited *) 5836 + is_image : bool list; (** Array indicating whether each asset is an image (false for videos) *) 5837 + is_trashed : bool list; (** Array indicating whether each asset is in the trash *) 5838 + latitude : float list option; (** Array of latitude coordinates extracted from EXIF GPS data *) 5839 + live_photo_video_id : string list; (** Array of live photo video asset IDs (null for non-live photos) *) 5840 + local_offset_hours : float list; (** Array of UTC offset hours at the time each photo was taken. Positive values are east of UTC, negative values are west of UTC. Values may be fractional (e.g., 5.5 for +05:30, -9.75 for -09:45). Applying this offset to 'fileCreatedAt' will give you the time the photo was taken from the photographer's perspective. *) 5841 + longitude : float list option; (** Array of longitude coordinates extracted from EXIF GPS data *) 5842 + owner_id : string list; (** Array of owner IDs for each asset *) 5843 + projection_type : string list; (** Array of projection types for 360° content (e.g., "EQUIRECTANGULAR", "CUBEFACE", "CYLINDRICAL") *) 5844 + ratio : float list; (** Array of aspect ratios (width/height) for each asset *) 5845 + stack : Jsont.json list option; (** Array of stack information as [stackId, assetCount] tuples (null for non-stacked assets) *) 5846 + thumbhash : string list; (** Array of BlurHash strings for generating asset previews (base64 encoded) *) 5847 + visibility : AssetVisibility.t list; (** Array of visibility statuses for each asset (e.g., ARCHIVE, TIMELINE, HIDDEN, LOCKED) *) 5848 + } 5849 + 5850 + let t_jsont : t Jsont.t = 5851 + Jsont.Object.map ~kind:"t" 5852 + (fun city country duration file_created_at id is_favorite is_image is_trashed latitude live_photo_video_id local_offset_hours longitude owner_id projection_type ratio stack thumbhash visibility -> { city; country; duration; file_created_at; id; is_favorite; is_image; is_trashed; latitude; live_photo_video_id; local_offset_hours; longitude; owner_id; projection_type; ratio; stack; thumbhash; visibility }) 5853 + |> Jsont.Object.mem "city" Jsont.(list Jsont.string) ~enc:(fun r -> r.city) 5854 + |> Jsont.Object.mem "country" Jsont.(list Jsont.string) ~enc:(fun r -> r.country) 5855 + |> Jsont.Object.mem "duration" Jsont.(list Jsont.string) ~enc:(fun r -> r.duration) 5856 + |> Jsont.Object.mem "fileCreatedAt" Jsont.(list Jsont.string) ~enc:(fun r -> r.file_created_at) 5857 + |> Jsont.Object.mem "id" Jsont.(list Jsont.string) ~enc:(fun r -> r.id) 5858 + |> Jsont.Object.mem "isFavorite" Jsont.(list Jsont.bool) ~enc:(fun r -> r.is_favorite) 5859 + |> Jsont.Object.mem "isImage" Jsont.(list Jsont.bool) ~enc:(fun r -> r.is_image) 5860 + |> Jsont.Object.mem "isTrashed" Jsont.(list Jsont.bool) ~enc:(fun r -> r.is_trashed) 5861 + |> Jsont.Object.opt_mem "latitude" Jsont.(list Jsont.number) ~enc:(fun r -> r.latitude) 5862 + |> Jsont.Object.mem "livePhotoVideoId" Jsont.(list Jsont.string) ~enc:(fun r -> r.live_photo_video_id) 5863 + |> Jsont.Object.mem "localOffsetHours" Jsont.(list Jsont.number) ~enc:(fun r -> r.local_offset_hours) 5864 + |> Jsont.Object.opt_mem "longitude" Jsont.(list Jsont.number) ~enc:(fun r -> r.longitude) 5865 + |> Jsont.Object.mem "ownerId" Jsont.(list Jsont.string) ~enc:(fun r -> r.owner_id) 5866 + |> Jsont.Object.mem "projectionType" Jsont.(list Jsont.string) ~enc:(fun r -> r.projection_type) 5867 + |> Jsont.Object.mem "ratio" Jsont.(list Jsont.number) ~enc:(fun r -> r.ratio) 5868 + |> Jsont.Object.opt_mem "stack" Jsont.(list Jsont.json) ~enc:(fun r -> r.stack) 5869 + |> Jsont.Object.mem "thumbhash" Jsont.(list Jsont.string) ~enc:(fun r -> r.thumbhash) 5870 + |> Jsont.Object.mem "visibility" Jsont.(list AssetVisibility.t_jsont) ~enc:(fun r -> r.visibility) 5871 + |> Jsont.Object.skip_unknown 5872 + |> Jsont.Object.finish 5873 + end 5874 + 5875 + module UpdateAssetDto = struct 5876 + type t = { 5877 + date_time_original : string option; 5878 + description : string option; 5879 + is_favorite : bool option; 5880 + latitude : float option; 5881 + live_photo_video_id : string option; 5882 + longitude : float option; 5883 + rating : float option; 5884 + visibility : Jsont.json option; 5885 + } 5886 + 5887 + let t_jsont : t Jsont.t = 5888 + Jsont.Object.map ~kind:"t" 5889 + (fun date_time_original description is_favorite latitude live_photo_video_id longitude rating visibility -> { date_time_original; description; is_favorite; latitude; live_photo_video_id; longitude; rating; visibility }) 5890 + |> Jsont.Object.opt_mem "dateTimeOriginal" Jsont.string ~enc:(fun r -> r.date_time_original) 5891 + |> Jsont.Object.opt_mem "description" Jsont.string ~enc:(fun r -> r.description) 5892 + |> Jsont.Object.opt_mem "isFavorite" Jsont.bool ~enc:(fun r -> r.is_favorite) 5893 + |> Jsont.Object.opt_mem "latitude" Jsont.number ~enc:(fun r -> r.latitude) 5894 + |> Jsont.Object.opt_mem "livePhotoVideoId" Jsont.string ~enc:(fun r -> r.live_photo_video_id) 5895 + |> Jsont.Object.opt_mem "longitude" Jsont.number ~enc:(fun r -> r.longitude) 5896 + |> Jsont.Object.opt_mem "rating" Jsont.number ~enc:(fun r -> r.rating) 5897 + |> Jsont.Object.opt_mem "visibility" Jsont.json ~enc:(fun r -> r.visibility) 5898 + |> Jsont.Object.skip_unknown 5899 + |> Jsont.Object.finish 5900 + end 5901 + 5902 + module AlbumsAddAssetsResponseDto = struct 5903 + type t = { 5904 + error : Jsont.json option; 5905 + success : bool; 5906 + } 5907 + 5908 + let t_jsont : t Jsont.t = 5909 + Jsont.Object.map ~kind:"t" 5910 + (fun error success -> { error; success }) 5911 + |> Jsont.Object.opt_mem "error" Jsont.json ~enc:(fun r -> r.error) 5912 + |> Jsont.Object.mem "success" Jsont.bool ~enc:(fun r -> r.success) 5913 + |> Jsont.Object.skip_unknown 5914 + |> Jsont.Object.finish 5915 + end 5916 + 5917 + module AssetEditActionCrop = struct 5918 + type t = { 5919 + action : Jsont.json; 5920 + parameters : CropParameters.t; 5921 + } 5922 + 5923 + let t_jsont : t Jsont.t = 5924 + Jsont.Object.map ~kind:"t" 5925 + (fun action parameters -> { action; parameters }) 5926 + |> Jsont.Object.mem "action" Jsont.json ~enc:(fun r -> r.action) 5927 + |> Jsont.Object.mem "parameters" CropParameters.t_jsont ~enc:(fun r -> r.parameters) 5928 + |> Jsont.Object.skip_unknown 5929 + |> Jsont.Object.finish 5930 + end 5931 + 5932 + module SystemConfigBackupsDto = struct 5933 + type t = { 5934 + database : DatabaseBackupConfig.t; 5935 + } 5936 + 5937 + let t_jsont : t Jsont.t = 5938 + Jsont.Object.map ~kind:"t" 5939 + (fun database -> { database }) 5940 + |> Jsont.Object.mem "database" DatabaseBackupConfig.t_jsont ~enc:(fun r -> r.database) 5941 + |> Jsont.Object.skip_unknown 5942 + |> Jsont.Object.finish 5943 + end 5944 + 5945 + module DatabaseBackupListResponseDto = struct 5946 + type t = { 5947 + backups : DatabaseBackupDto.t list; 5948 + } 5949 + 5950 + let t_jsont : t Jsont.t = 5951 + Jsont.Object.map ~kind:"t" 5952 + (fun backups -> { backups }) 5953 + |> Jsont.Object.mem "backups" Jsont.(list DatabaseBackupDto.t_jsont) ~enc:(fun r -> r.backups) 5954 + |> Jsont.Object.skip_unknown 5955 + |> Jsont.Object.finish 5956 + end 5957 + 5958 + module DownloadResponseDto = struct 5959 + type t = { 5960 + archives : DownloadArchiveInfo.t list; 5961 + total_size : int; 5962 + } 5963 + 5964 + let t_jsont : t Jsont.t = 5965 + Jsont.Object.map ~kind:"t" 5966 + (fun archives total_size -> { archives; total_size }) 5967 + |> Jsont.Object.mem "archives" Jsont.(list DownloadArchiveInfo.t_jsont) ~enc:(fun r -> r.archives) 5968 + |> Jsont.Object.mem "totalSize" Jsont.int ~enc:(fun r -> r.total_size) 5969 + |> Jsont.Object.skip_unknown 5970 + |> Jsont.Object.finish 5971 + end 5972 + 5973 + module SystemConfigGeneratedFullsizeImageDto = struct 5974 + type t = { 5975 + enabled : bool; 5976 + format : Jsont.json; 5977 + progressive : bool option; 5978 + quality : int; 5979 + } 5980 + 5981 + let t_jsont : t Jsont.t = 5982 + Jsont.Object.map ~kind:"t" 5983 + (fun enabled format progressive quality -> { enabled; format; progressive; quality }) 5984 + |> Jsont.Object.mem "enabled" Jsont.bool ~enc:(fun r -> r.enabled) 5985 + |> Jsont.Object.mem "format" Jsont.json ~enc:(fun r -> r.format) 5986 + |> Jsont.Object.opt_mem "progressive" Jsont.bool ~enc:(fun r -> r.progressive) 5987 + |> Jsont.Object.mem "quality" Jsont.int ~enc:(fun r -> r.quality) 5988 + |> Jsont.Object.skip_unknown 5989 + |> Jsont.Object.finish 5990 + end 5991 + 5992 + module SystemConfigGeneratedImageDto = struct 5993 + type t = { 5994 + format : Jsont.json; 5995 + progressive : bool option; 5996 + quality : int; 5997 + size : int; 5998 + } 5999 + 6000 + let t_jsont : t Jsont.t = 6001 + Jsont.Object.map ~kind:"t" 6002 + (fun format progressive quality size -> { format; progressive; quality; size }) 6003 + |> Jsont.Object.mem "format" Jsont.json ~enc:(fun r -> r.format) 6004 + |> Jsont.Object.opt_mem "progressive" Jsont.bool ~enc:(fun r -> r.progressive) 6005 + |> Jsont.Object.mem "quality" Jsont.int ~enc:(fun r -> r.quality) 6006 + |> Jsont.Object.mem "size" Jsont.int ~enc:(fun r -> r.size) 6007 + |> Jsont.Object.skip_unknown 6008 + |> Jsont.Object.finish 6009 + end 6010 + 6011 + module QueueJobResponseDto = struct 6012 + type t = { 6013 + data : Jsont.json; 6014 + id : string option; 6015 + name : Jsont.json; 6016 + timestamp : int; 6017 + } 6018 + 6019 + let t_jsont : t Jsont.t = 6020 + Jsont.Object.map ~kind:"t" 6021 + (fun data id name timestamp -> { data; id; name; timestamp }) 6022 + |> Jsont.Object.mem "data" Jsont.json ~enc:(fun r -> r.data) 6023 + |> Jsont.Object.opt_mem "id" Jsont.string ~enc:(fun r -> r.id) 6024 + |> Jsont.Object.mem "name" Jsont.json ~enc:(fun r -> r.name) 6025 + |> Jsont.Object.mem "timestamp" Jsont.int ~enc:(fun r -> r.timestamp) 6026 + |> Jsont.Object.skip_unknown 6027 + |> Jsont.Object.finish 6028 + end 6029 + 6030 + module SystemConfigJobDto = struct 6031 + type t = { 6032 + background_task : JobSettingsDto.t; 6033 + editor : JobSettingsDto.t; 6034 + face_detection : JobSettingsDto.t; 6035 + library : JobSettingsDto.t; 6036 + metadata_extraction : JobSettingsDto.t; 6037 + migration : JobSettingsDto.t; 6038 + notifications : JobSettingsDto.t; 6039 + ocr : JobSettingsDto.t; 6040 + search : JobSettingsDto.t; 6041 + sidecar : JobSettingsDto.t; 6042 + smart_search : JobSettingsDto.t; 6043 + thumbnail_generation : JobSettingsDto.t; 6044 + video_conversion : JobSettingsDto.t; 6045 + workflow : JobSettingsDto.t; 6046 + } 6047 + 6048 + let t_jsont : t Jsont.t = 6049 + Jsont.Object.map ~kind:"t" 6050 + (fun background_task editor face_detection library metadata_extraction migration notifications ocr search sidecar smart_search thumbnail_generation video_conversion workflow -> { background_task; editor; face_detection; library; metadata_extraction; migration; notifications; ocr; search; sidecar; smart_search; thumbnail_generation; video_conversion; workflow }) 6051 + |> Jsont.Object.mem "backgroundTask" JobSettingsDto.t_jsont ~enc:(fun r -> r.background_task) 6052 + |> Jsont.Object.mem "editor" JobSettingsDto.t_jsont ~enc:(fun r -> r.editor) 6053 + |> Jsont.Object.mem "faceDetection" JobSettingsDto.t_jsont ~enc:(fun r -> r.face_detection) 6054 + |> Jsont.Object.mem "library" JobSettingsDto.t_jsont ~enc:(fun r -> r.library) 6055 + |> Jsont.Object.mem "metadataExtraction" JobSettingsDto.t_jsont ~enc:(fun r -> r.metadata_extraction) 6056 + |> Jsont.Object.mem "migration" JobSettingsDto.t_jsont ~enc:(fun r -> r.migration) 6057 + |> Jsont.Object.mem "notifications" JobSettingsDto.t_jsont ~enc:(fun r -> r.notifications) 6058 + |> Jsont.Object.mem "ocr" JobSettingsDto.t_jsont ~enc:(fun r -> r.ocr) 6059 + |> Jsont.Object.mem "search" JobSettingsDto.t_jsont ~enc:(fun r -> r.search) 6060 + |> Jsont.Object.mem "sidecar" JobSettingsDto.t_jsont ~enc:(fun r -> r.sidecar) 6061 + |> Jsont.Object.mem "smartSearch" JobSettingsDto.t_jsont ~enc:(fun r -> r.smart_search) 6062 + |> Jsont.Object.mem "thumbnailGeneration" JobSettingsDto.t_jsont ~enc:(fun r -> r.thumbnail_generation) 6063 + |> Jsont.Object.mem "videoConversion" JobSettingsDto.t_jsont ~enc:(fun r -> r.video_conversion) 6064 + |> Jsont.Object.mem "workflow" JobSettingsDto.t_jsont ~enc:(fun r -> r.workflow) 6065 + |> Jsont.Object.skip_unknown 6066 + |> Jsont.Object.finish 6067 + end 6068 + 6069 + module SystemConfigLoggingDto = struct 6070 + type t = { 6071 + enabled : bool; 6072 + level : Jsont.json; 6073 + } 6074 + 6075 + let t_jsont : t Jsont.t = 6076 + Jsont.Object.map ~kind:"t" 6077 + (fun enabled level -> { enabled; level }) 6078 + |> Jsont.Object.mem "enabled" Jsont.bool ~enc:(fun r -> r.enabled) 6079 + |> Jsont.Object.mem "level" Jsont.json ~enc:(fun r -> r.level) 6080 + |> Jsont.Object.skip_unknown 6081 + |> Jsont.Object.finish 6082 + end 6083 + 6084 + module MaintenanceStatusResponseDto = struct 6085 + type t = { 6086 + action : Jsont.json; 6087 + active : bool; 6088 + error : string option; 6089 + progress : float option; 6090 + task : string option; 6091 + } 6092 + 6093 + let t_jsont : t Jsont.t = 6094 + Jsont.Object.map ~kind:"t" 6095 + (fun action active error progress task -> { action; active; error; progress; task }) 6096 + |> Jsont.Object.mem "action" Jsont.json ~enc:(fun r -> r.action) 6097 + |> Jsont.Object.mem "active" Jsont.bool ~enc:(fun r -> r.active) 6098 + |> Jsont.Object.opt_mem "error" Jsont.string ~enc:(fun r -> r.error) 6099 + |> Jsont.Object.opt_mem "progress" Jsont.number ~enc:(fun r -> r.progress) 6100 + |> Jsont.Object.opt_mem "task" Jsont.string ~enc:(fun r -> r.task) 6101 + |> Jsont.Object.skip_unknown 6102 + |> Jsont.Object.finish 6103 + end 6104 + 6105 + module SetMaintenanceModeDto = struct 6106 + type t = { 6107 + action : Jsont.json; 6108 + restore_backup_filename : string option; 6109 + } 6110 + 6111 + let t_jsont : t Jsont.t = 6112 + Jsont.Object.map ~kind:"t" 6113 + (fun action restore_backup_filename -> { action; restore_backup_filename }) 6114 + |> Jsont.Object.mem "action" Jsont.json ~enc:(fun r -> r.action) 6115 + |> Jsont.Object.opt_mem "restoreBackupFilename" Jsont.string ~enc:(fun r -> r.restore_backup_filename) 6116 + |> Jsont.Object.skip_unknown 6117 + |> Jsont.Object.finish 6118 + end 6119 + 6120 + module JobCreateDto = struct 6121 + type t = { 6122 + name : Jsont.json; 6123 + } 6124 + 6125 + let t_jsont : t Jsont.t = 6126 + Jsont.Object.map ~kind:"t" 6127 + (fun name -> { name }) 6128 + |> Jsont.Object.mem "name" Jsont.json ~enc:(fun r -> r.name) 6129 + |> Jsont.Object.skip_unknown 6130 + |> Jsont.Object.finish 6131 + end 6132 + 6133 + module SyncMemoryV1 = struct 6134 + type t = { 6135 + created_at : Ptime.t; 6136 + data : Jsont.json; 6137 + deleted_at : Ptime.t; 6138 + hide_at : Ptime.t; 6139 + id : string; 6140 + is_saved : bool; 6141 + memory_at : Ptime.t; 6142 + owner_id : string; 6143 + seen_at : Ptime.t; 6144 + show_at : Ptime.t; 6145 + type_ : Jsont.json; 6146 + updated_at : Ptime.t; 6147 + } 6148 + 6149 + let t_jsont : t Jsont.t = 6150 + Jsont.Object.map ~kind:"t" 6151 + (fun created_at data deleted_at hide_at id is_saved memory_at owner_id seen_at show_at type_ updated_at -> { created_at; data; deleted_at; hide_at; id; is_saved; memory_at; owner_id; seen_at; show_at; type_; updated_at }) 6152 + |> Jsont.Object.mem "createdAt" Openapi.Runtime.ptime_jsont ~enc:(fun r -> r.created_at) 6153 + |> Jsont.Object.mem "data" Jsont.json ~enc:(fun r -> r.data) 6154 + |> Jsont.Object.mem "deletedAt" Openapi.Runtime.ptime_jsont ~enc:(fun r -> r.deleted_at) 6155 + |> Jsont.Object.mem "hideAt" Openapi.Runtime.ptime_jsont ~enc:(fun r -> r.hide_at) 6156 + |> Jsont.Object.mem "id" Jsont.string ~enc:(fun r -> r.id) 6157 + |> Jsont.Object.mem "isSaved" Jsont.bool ~enc:(fun r -> r.is_saved) 6158 + |> Jsont.Object.mem "memoryAt" Openapi.Runtime.ptime_jsont ~enc:(fun r -> r.memory_at) 6159 + |> Jsont.Object.mem "ownerId" Jsont.string ~enc:(fun r -> r.owner_id) 6160 + |> Jsont.Object.mem "seenAt" Openapi.Runtime.ptime_jsont ~enc:(fun r -> r.seen_at) 6161 + |> Jsont.Object.mem "showAt" Openapi.Runtime.ptime_jsont ~enc:(fun r -> r.show_at) 6162 + |> Jsont.Object.mem "type" Jsont.json ~enc:(fun r -> r.type_) 6163 + |> Jsont.Object.mem "updatedAt" Openapi.Runtime.ptime_jsont ~enc:(fun r -> r.updated_at) 6164 + |> Jsont.Object.skip_unknown 6165 + |> Jsont.Object.finish 6166 + end 6167 + 6168 + module MirrorParameters = struct 6169 + type t = { 6170 + axis : Jsont.json; (** Axis to mirror along *) 6171 + } 6172 + 6173 + let t_jsont : t Jsont.t = 6174 + Jsont.Object.map ~kind:"t" 6175 + (fun axis -> { axis }) 6176 + |> Jsont.Object.mem "axis" Jsont.json ~enc:(fun r -> r.axis) 6177 + |> Jsont.Object.skip_unknown 6178 + |> Jsont.Object.finish 6179 + end 6180 + 6181 + module NotificationCreateDto = struct 6182 + type t = { 6183 + data : Jsont.json option; 6184 + description : string option; 6185 + level : Jsont.json option; 6186 + read_at : Ptime.t option; 6187 + title : string; 6188 + type_ : Jsont.json option; 6189 + user_id : string; 6190 + } 6191 + 6192 + let t_jsont : t Jsont.t = 6193 + Jsont.Object.map ~kind:"t" 6194 + (fun data description level read_at title type_ user_id -> { data; description; level; read_at; title; type_; user_id }) 6195 + |> Jsont.Object.opt_mem "data" Jsont.json ~enc:(fun r -> r.data) 6196 + |> Jsont.Object.opt_mem "description" Jsont.string ~enc:(fun r -> r.description) 6197 + |> Jsont.Object.opt_mem "level" Jsont.json ~enc:(fun r -> r.level) 6198 + |> Jsont.Object.opt_mem "readAt" Openapi.Runtime.ptime_jsont ~enc:(fun r -> r.read_at) 6199 + |> Jsont.Object.mem "title" Jsont.string ~enc:(fun r -> r.title) 6200 + |> Jsont.Object.opt_mem "type" Jsont.json ~enc:(fun r -> r.type_) 6201 + |> Jsont.Object.mem "userId" Jsont.string ~enc:(fun r -> r.user_id) 6202 + |> Jsont.Object.skip_unknown 6203 + |> Jsont.Object.finish 6204 + end 6205 + 6206 + module NotificationDto = struct 6207 + type t = { 6208 + created_at : Ptime.t; 6209 + data : Jsont.json option; 6210 + description : string option; 6211 + id : string; 6212 + level : Jsont.json; 6213 + read_at : Ptime.t option; 6214 + title : string; 6215 + type_ : Jsont.json; 6216 + } 6217 + 6218 + let t_jsont : t Jsont.t = 6219 + Jsont.Object.map ~kind:"t" 6220 + (fun created_at data description id level read_at title type_ -> { created_at; data; description; id; level; read_at; title; type_ }) 6221 + |> Jsont.Object.mem "createdAt" Openapi.Runtime.ptime_jsont ~enc:(fun r -> r.created_at) 6222 + |> Jsont.Object.opt_mem "data" Jsont.json ~enc:(fun r -> r.data) 6223 + |> Jsont.Object.opt_mem "description" Jsont.string ~enc:(fun r -> r.description) 6224 + |> Jsont.Object.mem "id" Jsont.string ~enc:(fun r -> r.id) 6225 + |> Jsont.Object.mem "level" Jsont.json ~enc:(fun r -> r.level) 6226 + |> Jsont.Object.opt_mem "readAt" Openapi.Runtime.ptime_jsont ~enc:(fun r -> r.read_at) 6227 + |> Jsont.Object.mem "title" Jsont.string ~enc:(fun r -> r.title) 6228 + |> Jsont.Object.mem "type" Jsont.json ~enc:(fun r -> r.type_) 6229 + |> Jsont.Object.skip_unknown 6230 + |> Jsont.Object.finish 6231 + end 6232 + 6233 + module SystemConfigOauthDto = struct 6234 + type t = { 6235 + auto_launch : bool; 6236 + auto_register : bool; 6237 + button_text : string; 6238 + client_id : string; 6239 + client_secret : string; 6240 + default_storage_quota : int64; 6241 + enabled : bool; 6242 + issuer_url : string; 6243 + mobile_override_enabled : bool; 6244 + mobile_redirect_uri : string; 6245 + profile_signing_algorithm : string; 6246 + role_claim : string; 6247 + scope : string; 6248 + signing_algorithm : string; 6249 + storage_label_claim : string; 6250 + storage_quota_claim : string; 6251 + timeout : int; 6252 + token_endpoint_auth_method : Jsont.json; 6253 + } 6254 + 6255 + let t_jsont : t Jsont.t = 6256 + Jsont.Object.map ~kind:"t" 6257 + (fun auto_launch auto_register button_text client_id client_secret default_storage_quota enabled issuer_url mobile_override_enabled mobile_redirect_uri profile_signing_algorithm role_claim scope signing_algorithm storage_label_claim storage_quota_claim timeout token_endpoint_auth_method -> { auto_launch; auto_register; button_text; client_id; client_secret; default_storage_quota; enabled; issuer_url; mobile_override_enabled; mobile_redirect_uri; profile_signing_algorithm; role_claim; scope; signing_algorithm; storage_label_claim; storage_quota_claim; timeout; token_endpoint_auth_method }) 6258 + |> Jsont.Object.mem "autoLaunch" Jsont.bool ~enc:(fun r -> r.auto_launch) 6259 + |> Jsont.Object.mem "autoRegister" Jsont.bool ~enc:(fun r -> r.auto_register) 6260 + |> Jsont.Object.mem "buttonText" Jsont.string ~enc:(fun r -> r.button_text) 6261 + |> Jsont.Object.mem "clientId" Jsont.string ~enc:(fun r -> r.client_id) 6262 + |> Jsont.Object.mem "clientSecret" Jsont.string ~enc:(fun r -> r.client_secret) 6263 + |> Jsont.Object.mem "defaultStorageQuota" Jsont.int64 ~enc:(fun r -> r.default_storage_quota) 6264 + |> Jsont.Object.mem "enabled" Jsont.bool ~enc:(fun r -> r.enabled) 6265 + |> Jsont.Object.mem "issuerUrl" Jsont.string ~enc:(fun r -> r.issuer_url) 6266 + |> Jsont.Object.mem "mobileOverrideEnabled" Jsont.bool ~enc:(fun r -> r.mobile_override_enabled) 6267 + |> Jsont.Object.mem "mobileRedirectUri" Jsont.string ~enc:(fun r -> r.mobile_redirect_uri) 6268 + |> Jsont.Object.mem "profileSigningAlgorithm" Jsont.string ~enc:(fun r -> r.profile_signing_algorithm) 6269 + |> Jsont.Object.mem "roleClaim" Jsont.string ~enc:(fun r -> r.role_claim) 6270 + |> Jsont.Object.mem "scope" Jsont.string ~enc:(fun r -> r.scope) 6271 + |> Jsont.Object.mem "signingAlgorithm" Jsont.string ~enc:(fun r -> r.signing_algorithm) 6272 + |> Jsont.Object.mem "storageLabelClaim" Jsont.string ~enc:(fun r -> r.storage_label_claim) 6273 + |> Jsont.Object.mem "storageQuotaClaim" Jsont.string ~enc:(fun r -> r.storage_quota_claim) 6274 + |> Jsont.Object.mem "timeout" Jsont.int ~enc:(fun r -> r.timeout) 6275 + |> Jsont.Object.mem "tokenEndpointAuthMethod" Jsont.json ~enc:(fun r -> r.token_endpoint_auth_method) 6276 + |> Jsont.Object.skip_unknown 6277 + |> Jsont.Object.finish 6278 + end 6279 + 6280 + module SystemConfigMachineLearningDto = struct 6281 + type t = { 6282 + availability_checks : MachineLearningAvailabilityChecksDto.t; 6283 + clip : Clipconfig.t; 6284 + duplicate_detection : DuplicateDetectionConfig.t; 6285 + enabled : bool; 6286 + facial_recognition : FacialRecognitionConfig.t; 6287 + ocr : OcrConfig.t; 6288 + urls : string list; 6289 + } 6290 + 6291 + let t_jsont : t Jsont.t = 6292 + Jsont.Object.map ~kind:"t" 6293 + (fun availability_checks clip duplicate_detection enabled facial_recognition ocr urls -> { availability_checks; clip; duplicate_detection; enabled; facial_recognition; ocr; urls }) 6294 + |> Jsont.Object.mem "availabilityChecks" MachineLearningAvailabilityChecksDto.t_jsont ~enc:(fun r -> r.availability_checks) 6295 + |> Jsont.Object.mem "clip" Clipconfig.t_jsont ~enc:(fun r -> r.clip) 6296 + |> Jsont.Object.mem "duplicateDetection" DuplicateDetectionConfig.t_jsont ~enc:(fun r -> r.duplicate_detection) 6297 + |> Jsont.Object.mem "enabled" Jsont.bool ~enc:(fun r -> r.enabled) 6298 + |> Jsont.Object.mem "facialRecognition" FacialRecognitionConfig.t_jsont ~enc:(fun r -> r.facial_recognition) 6299 + |> Jsont.Object.mem "ocr" OcrConfig.t_jsont ~enc:(fun r -> r.ocr) 6300 + |> Jsont.Object.mem "urls" Jsont.(list Jsont.string) ~enc:(fun r -> r.urls) 6301 + |> Jsont.Object.skip_unknown 6302 + |> Jsont.Object.finish 6303 + end 6304 + 6305 + module MemoryCreateDto = struct 6306 + type t = { 6307 + asset_ids : string list option; 6308 + data : OnThisDayDto.t; 6309 + is_saved : bool option; 6310 + memory_at : Ptime.t; 6311 + seen_at : Ptime.t option; 6312 + type_ : Jsont.json; 6313 + } 6314 + 6315 + let t_jsont : t Jsont.t = 6316 + Jsont.Object.map ~kind:"t" 6317 + (fun asset_ids data is_saved memory_at seen_at type_ -> { asset_ids; data; is_saved; memory_at; seen_at; type_ }) 6318 + |> Jsont.Object.opt_mem "assetIds" Jsont.(list Jsont.string) ~enc:(fun r -> r.asset_ids) 6319 + |> Jsont.Object.mem "data" OnThisDayDto.t_jsont ~enc:(fun r -> r.data) 6320 + |> Jsont.Object.opt_mem "isSaved" Jsont.bool ~enc:(fun r -> r.is_saved) 6321 + |> Jsont.Object.mem "memoryAt" Openapi.Runtime.ptime_jsont ~enc:(fun r -> r.memory_at) 6322 + |> Jsont.Object.opt_mem "seenAt" Openapi.Runtime.ptime_jsont ~enc:(fun r -> r.seen_at) 6323 + |> Jsont.Object.mem "type" Jsont.json ~enc:(fun r -> r.type_) 6324 + |> Jsont.Object.skip_unknown 6325 + |> Jsont.Object.finish 6326 + end 6327 + 6328 + module PeopleUpdateDto = struct 6329 + type t = { 6330 + people : PeopleUpdateItem.t list; 6331 + } 6332 + 6333 + let t_jsont : t Jsont.t = 6334 + Jsont.Object.map ~kind:"t" 6335 + (fun people -> { people }) 6336 + |> Jsont.Object.mem "people" Jsont.(list PeopleUpdateItem.t_jsont) ~enc:(fun r -> r.people) 6337 + |> Jsont.Object.skip_unknown 6338 + |> Jsont.Object.finish 6339 + end 6340 + 6341 + module ApikeyCreateDto = struct 6342 + type t = { 6343 + name : string option; 6344 + permissions : Permission.t list; 6345 + } 6346 + 6347 + let t_jsont : t Jsont.t = 6348 + Jsont.Object.map ~kind:"t" 6349 + (fun name permissions -> { name; permissions }) 6350 + |> Jsont.Object.opt_mem "name" Jsont.string ~enc:(fun r -> r.name) 6351 + |> Jsont.Object.mem "permissions" Jsont.(list Permission.t_jsont) ~enc:(fun r -> r.permissions) 6352 + |> Jsont.Object.skip_unknown 6353 + |> Jsont.Object.finish 6354 + end 6355 + 6356 + module ApikeyResponseDto = struct 6357 + type t = { 6358 + created_at : Ptime.t; 6359 + id : string; 6360 + name : string; 6361 + permissions : Permission.t list; 6362 + updated_at : Ptime.t; 6363 + } 6364 + 6365 + let t_jsont : t Jsont.t = 6366 + Jsont.Object.map ~kind:"t" 6367 + (fun created_at id name permissions updated_at -> { created_at; id; name; permissions; updated_at }) 6368 + |> Jsont.Object.mem "createdAt" Openapi.Runtime.ptime_jsont ~enc:(fun r -> r.created_at) 6369 + |> Jsont.Object.mem "id" Jsont.string ~enc:(fun r -> r.id) 6370 + |> Jsont.Object.mem "name" Jsont.string ~enc:(fun r -> r.name) 6371 + |> Jsont.Object.mem "permissions" Jsont.(list Permission.t_jsont) ~enc:(fun r -> r.permissions) 6372 + |> Jsont.Object.mem "updatedAt" Openapi.Runtime.ptime_jsont ~enc:(fun r -> r.updated_at) 6373 + |> Jsont.Object.skip_unknown 6374 + |> Jsont.Object.finish 6375 + end 6376 + 6377 + module ApikeyUpdateDto = struct 6378 + type t = { 6379 + name : string option; 6380 + permissions : Permission.t list option; 6381 + } 6382 + 6383 + let t_jsont : t Jsont.t = 6384 + Jsont.Object.map ~kind:"t" 6385 + (fun name permissions -> { name; permissions }) 6386 + |> Jsont.Object.opt_mem "name" Jsont.string ~enc:(fun r -> r.name) 6387 + |> Jsont.Object.opt_mem "permissions" Jsont.(list Permission.t_jsont) ~enc:(fun r -> r.permissions) 6388 + |> Jsont.Object.skip_unknown 6389 + |> Jsont.Object.finish 6390 + end 6391 + 6392 + module PeopleResponseDto = struct 6393 + type t = { 6394 + has_next_page : bool option; 6395 + hidden : int; 6396 + people : PersonResponseDto.t list; 6397 + total : int; 6398 + } 6399 + 6400 + let t_jsont : t Jsont.t = 6401 + Jsont.Object.map ~kind:"t" 6402 + (fun has_next_page hidden people total -> { has_next_page; hidden; people; total }) 6403 + |> Jsont.Object.opt_mem "hasNextPage" Jsont.bool ~enc:(fun r -> r.has_next_page) 6404 + |> Jsont.Object.mem "hidden" Jsont.int ~enc:(fun r -> r.hidden) 6405 + |> Jsont.Object.mem "people" Jsont.(list PersonResponseDto.t_jsont) ~enc:(fun r -> r.people) 6406 + |> Jsont.Object.mem "total" Jsont.int ~enc:(fun r -> r.total) 6407 + |> Jsont.Object.skip_unknown 6408 + |> Jsont.Object.finish 6409 + end 6410 + 6411 + module PluginActionResponseDto = struct 6412 + type t = { 6413 + description : string; 6414 + id : string; 6415 + method_name : string; 6416 + plugin_id : string; 6417 + schema : Jsont.json; 6418 + supported_contexts : PluginContextType.t list; 6419 + title : string; 6420 + } 6421 + 6422 + let t_jsont : t Jsont.t = 6423 + Jsont.Object.map ~kind:"t" 6424 + (fun description id method_name plugin_id schema supported_contexts title -> { description; id; method_name; plugin_id; schema; supported_contexts; title }) 6425 + |> Jsont.Object.mem "description" Jsont.string ~enc:(fun r -> r.description) 6426 + |> Jsont.Object.mem "id" Jsont.string ~enc:(fun r -> r.id) 6427 + |> Jsont.Object.mem "methodName" Jsont.string ~enc:(fun r -> r.method_name) 6428 + |> Jsont.Object.mem "pluginId" Jsont.string ~enc:(fun r -> r.plugin_id) 6429 + |> Jsont.Object.mem "schema" Jsont.json ~enc:(fun r -> r.schema) 6430 + |> Jsont.Object.mem "supportedContexts" Jsont.(list PluginContextType.t_jsont) ~enc:(fun r -> r.supported_contexts) 6431 + |> Jsont.Object.mem "title" Jsont.string ~enc:(fun r -> r.title) 6432 + |> Jsont.Object.skip_unknown 6433 + |> Jsont.Object.finish 6434 + end 6435 + 6436 + module PluginFilterResponseDto = struct 6437 + type t = { 6438 + description : string; 6439 + id : string; 6440 + method_name : string; 6441 + plugin_id : string; 6442 + schema : Jsont.json; 6443 + supported_contexts : PluginContextType.t list; 6444 + title : string; 6445 + } 6446 + 6447 + let t_jsont : t Jsont.t = 6448 + Jsont.Object.map ~kind:"t" 6449 + (fun description id method_name plugin_id schema supported_contexts title -> { description; id; method_name; plugin_id; schema; supported_contexts; title }) 6450 + |> Jsont.Object.mem "description" Jsont.string ~enc:(fun r -> r.description) 6451 + |> Jsont.Object.mem "id" Jsont.string ~enc:(fun r -> r.id) 6452 + |> Jsont.Object.mem "methodName" Jsont.string ~enc:(fun r -> r.method_name) 6453 + |> Jsont.Object.mem "pluginId" Jsont.string ~enc:(fun r -> r.plugin_id) 6454 + |> Jsont.Object.mem "schema" Jsont.json ~enc:(fun r -> r.schema) 6455 + |> Jsont.Object.mem "supportedContexts" Jsont.(list PluginContextType.t_jsont) ~enc:(fun r -> r.supported_contexts) 6456 + |> Jsont.Object.mem "title" Jsont.string ~enc:(fun r -> r.title) 6457 + |> Jsont.Object.skip_unknown 6458 + |> Jsont.Object.finish 6459 + end 6460 + 6461 + module PluginTriggerResponseDto = struct 6462 + type t = { 6463 + context_type : Jsont.json; 6464 + type_ : Jsont.json; 6465 + } 6466 + 6467 + let t_jsont : t Jsont.t = 6468 + Jsont.Object.map ~kind:"t" 6469 + (fun context_type type_ -> { context_type; type_ }) 6470 + |> Jsont.Object.mem "contextType" Jsont.json ~enc:(fun r -> r.context_type) 6471 + |> Jsont.Object.mem "type" Jsont.json ~enc:(fun r -> r.type_) 6472 + |> Jsont.Object.skip_unknown 6473 + |> Jsont.Object.finish 6474 + end 6475 + 6476 + module QueueCommandDto = struct 6477 + type t = { 6478 + command : Jsont.json; 6479 + force : bool option; 6480 + } 6481 + 6482 + let t_jsont : t Jsont.t = 6483 + Jsont.Object.map ~kind:"t" 6484 + (fun command force -> { command; force }) 6485 + |> Jsont.Object.mem "command" Jsont.json ~enc:(fun r -> r.command) 6486 + |> Jsont.Object.opt_mem "force" Jsont.bool ~enc:(fun r -> r.force) 6487 + |> Jsont.Object.skip_unknown 6488 + |> Jsont.Object.finish 6489 + end 6490 + 6491 + module QueueResponseDto = struct 6492 + type t = { 6493 + is_paused : bool; 6494 + name : Jsont.json; 6495 + statistics : QueueStatisticsDto.t; 6496 + } 6497 + 6498 + let t_jsont : t Jsont.t = 6499 + Jsont.Object.map ~kind:"t" 6500 + (fun is_paused name statistics -> { is_paused; name; statistics }) 6501 + |> Jsont.Object.mem "isPaused" Jsont.bool ~enc:(fun r -> r.is_paused) 6502 + |> Jsont.Object.mem "name" Jsont.json ~enc:(fun r -> r.name) 6503 + |> Jsont.Object.mem "statistics" QueueStatisticsDto.t_jsont ~enc:(fun r -> r.statistics) 6504 + |> Jsont.Object.skip_unknown 6505 + |> Jsont.Object.finish 6506 + end 6507 + 6508 + module QueueResponseLegacyDto = struct 6509 + type t = { 6510 + job_counts : QueueStatisticsDto.t; 6511 + queue_status : QueueStatusLegacyDto.t; 6512 + } 6513 + 6514 + let t_jsont : t Jsont.t = 6515 + Jsont.Object.map ~kind:"t" 6516 + (fun job_counts queue_status -> { job_counts; queue_status }) 6517 + |> Jsont.Object.mem "jobCounts" QueueStatisticsDto.t_jsont ~enc:(fun r -> r.job_counts) 6518 + |> Jsont.Object.mem "queueStatus" QueueStatusLegacyDto.t_jsont ~enc:(fun r -> r.queue_status) 6519 + |> Jsont.Object.skip_unknown 6520 + |> Jsont.Object.finish 6521 + end 6522 + 6523 + module ActivityCreateDto = struct 6524 + type t = { 6525 + album_id : string; 6526 + asset_id : string option; 6527 + comment : string option; 6528 + type_ : Jsont.json; 6529 + } 6530 + 6531 + let t_jsont : t Jsont.t = 6532 + Jsont.Object.map ~kind:"t" 6533 + (fun album_id asset_id comment type_ -> { album_id; asset_id; comment; type_ }) 6534 + |> Jsont.Object.mem "albumId" Jsont.string ~enc:(fun r -> r.album_id) 6535 + |> Jsont.Object.opt_mem "assetId" Jsont.string ~enc:(fun r -> r.asset_id) 6536 + |> Jsont.Object.opt_mem "comment" Jsont.string ~enc:(fun r -> r.comment) 6537 + |> Jsont.Object.mem "type" Jsont.json ~enc:(fun r -> r.type_) 6538 + |> Jsont.Object.skip_unknown 6539 + |> Jsont.Object.finish 6540 + end 6541 + 6542 + module AssetEditActionRotate = struct 6543 + type t = { 6544 + action : Jsont.json; 6545 + parameters : RotateParameters.t; 6546 + } 6547 + 6548 + let t_jsont : t Jsont.t = 6549 + Jsont.Object.map ~kind:"t" 6550 + (fun action parameters -> { action; parameters }) 6551 + |> Jsont.Object.mem "action" Jsont.json ~enc:(fun r -> r.action) 6552 + |> Jsont.Object.mem "parameters" RotateParameters.t_jsont ~enc:(fun r -> r.parameters) 6553 + |> Jsont.Object.skip_unknown 6554 + |> Jsont.Object.finish 6555 + end 6556 + 6557 + module SearchFacetResponseDto = struct 6558 + type t = { 6559 + counts : SearchFacetCountResponseDto.t list; 6560 + field_name : string; 6561 + } 6562 + 6563 + let t_jsont : t Jsont.t = 6564 + Jsont.Object.map ~kind:"t" 6565 + (fun counts field_name -> { counts; field_name }) 6566 + |> Jsont.Object.mem "counts" Jsont.(list SearchFacetCountResponseDto.t_jsont) ~enc:(fun r -> r.counts) 6567 + |> Jsont.Object.mem "fieldName" Jsont.string ~enc:(fun r -> r.field_name) 6568 + |> Jsont.Object.skip_unknown 6569 + |> Jsont.Object.finish 6570 + end 6571 + 6572 + module SharedLinkCreateDto = struct 6573 + type t = { 6574 + album_id : string option; 6575 + allow_download : bool option; 6576 + allow_upload : bool option; 6577 + asset_ids : string list option; 6578 + description : string option; 6579 + expires_at : Ptime.t option; 6580 + password : string option; 6581 + show_metadata : bool option; 6582 + slug : string option; 6583 + type_ : Jsont.json; 6584 + } 6585 + 6586 + let t_jsont : t Jsont.t = 6587 + Jsont.Object.map ~kind:"t" 6588 + (fun album_id allow_download allow_upload asset_ids description expires_at password show_metadata slug type_ -> { album_id; allow_download; allow_upload; asset_ids; description; expires_at; password; show_metadata; slug; type_ }) 6589 + |> Jsont.Object.opt_mem "albumId" Jsont.string ~enc:(fun r -> r.album_id) 6590 + |> Jsont.Object.opt_mem "allowDownload" Jsont.bool ~enc:(fun r -> r.allow_download) 6591 + |> Jsont.Object.opt_mem "allowUpload" Jsont.bool ~enc:(fun r -> r.allow_upload) 6592 + |> Jsont.Object.opt_mem "assetIds" Jsont.(list Jsont.string) ~enc:(fun r -> r.asset_ids) 6593 + |> Jsont.Object.opt_mem "description" Jsont.string ~enc:(fun r -> r.description) 6594 + |> Jsont.Object.opt_mem "expiresAt" Openapi.Runtime.ptime_jsont ~enc:(fun r -> r.expires_at) 6595 + |> Jsont.Object.opt_mem "password" Jsont.string ~enc:(fun r -> r.password) 6596 + |> Jsont.Object.opt_mem "showMetadata" Jsont.bool ~enc:(fun r -> r.show_metadata) 6597 + |> Jsont.Object.opt_mem "slug" Jsont.string ~enc:(fun r -> r.slug) 6598 + |> Jsont.Object.mem "type" Jsont.json ~enc:(fun r -> r.type_) 6599 + |> Jsont.Object.skip_unknown 6600 + |> Jsont.Object.finish 6601 + end 6602 + 6603 + module AssetFaceResponseDto = struct 6604 + type t = { 6605 + bounding_box_x1 : int; 6606 + bounding_box_x2 : int; 6607 + bounding_box_y1 : int; 6608 + bounding_box_y2 : int; 6609 + id : string; 6610 + image_height : int; 6611 + image_width : int; 6612 + person : Jsont.json option; 6613 + source_type : Jsont.json option; 6614 + } 6615 + 6616 + let t_jsont : t Jsont.t = 6617 + Jsont.Object.map ~kind:"t" 6618 + (fun bounding_box_x1 bounding_box_x2 bounding_box_y1 bounding_box_y2 id image_height image_width person source_type -> { bounding_box_x1; bounding_box_x2; bounding_box_y1; bounding_box_y2; id; image_height; image_width; person; source_type }) 6619 + |> Jsont.Object.mem "boundingBoxX1" Jsont.int ~enc:(fun r -> r.bounding_box_x1) 6620 + |> Jsont.Object.mem "boundingBoxX2" Jsont.int ~enc:(fun r -> r.bounding_box_x2) 6621 + |> Jsont.Object.mem "boundingBoxY1" Jsont.int ~enc:(fun r -> r.bounding_box_y1) 6622 + |> Jsont.Object.mem "boundingBoxY2" Jsont.int ~enc:(fun r -> r.bounding_box_y2) 6623 + |> Jsont.Object.mem "id" Jsont.string ~enc:(fun r -> r.id) 6624 + |> Jsont.Object.mem "imageHeight" Jsont.int ~enc:(fun r -> r.image_height) 6625 + |> Jsont.Object.mem "imageWidth" Jsont.int ~enc:(fun r -> r.image_width) 6626 + |> Jsont.Object.mem "person" (Jsont.option Jsont.json) 6627 + ~dec_absent:None ~enc_omit:Option.is_none ~enc:(fun r -> r.person) 6628 + |> Jsont.Object.opt_mem "sourceType" Jsont.json ~enc:(fun r -> r.source_type) 6629 + |> Jsont.Object.skip_unknown 6630 + |> Jsont.Object.finish 6631 + end 6632 + 6633 + module AssetFaceWithoutPersonResponseDto = struct 6634 + type t = { 6635 + bounding_box_x1 : int; 6636 + bounding_box_x2 : int; 6637 + bounding_box_y1 : int; 6638 + bounding_box_y2 : int; 6639 + id : string; 6640 + image_height : int; 6641 + image_width : int; 6642 + source_type : Jsont.json option; 6643 + } 6644 + 6645 + let t_jsont : t Jsont.t = 6646 + Jsont.Object.map ~kind:"t" 6647 + (fun bounding_box_x1 bounding_box_x2 bounding_box_y1 bounding_box_y2 id image_height image_width source_type -> { bounding_box_x1; bounding_box_x2; bounding_box_y1; bounding_box_y2; id; image_height; image_width; source_type }) 6648 + |> Jsont.Object.mem "boundingBoxX1" Jsont.int ~enc:(fun r -> r.bounding_box_x1) 6649 + |> Jsont.Object.mem "boundingBoxX2" Jsont.int ~enc:(fun r -> r.bounding_box_x2) 6650 + |> Jsont.Object.mem "boundingBoxY1" Jsont.int ~enc:(fun r -> r.bounding_box_y1) 6651 + |> Jsont.Object.mem "boundingBoxY2" Jsont.int ~enc:(fun r -> r.bounding_box_y2) 6652 + |> Jsont.Object.mem "id" Jsont.string ~enc:(fun r -> r.id) 6653 + |> Jsont.Object.mem "imageHeight" Jsont.int ~enc:(fun r -> r.image_height) 6654 + |> Jsont.Object.mem "imageWidth" Jsont.int ~enc:(fun r -> r.image_width) 6655 + |> Jsont.Object.opt_mem "sourceType" Jsont.json ~enc:(fun r -> r.source_type) 6656 + |> Jsont.Object.skip_unknown 6657 + |> Jsont.Object.finish 6658 + end 6659 + 6660 + module MaintenanceDetectInstallStorageFolderDto = struct 6661 + type t = { 6662 + files : float; 6663 + folder : Jsont.json; 6664 + readable : bool; 6665 + writable : bool; 6666 + } 6667 + 6668 + let t_jsont : t Jsont.t = 6669 + Jsont.Object.map ~kind:"t" 6670 + (fun files folder readable writable -> { files; folder; readable; writable }) 6671 + |> Jsont.Object.mem "files" Jsont.number ~enc:(fun r -> r.files) 6672 + |> Jsont.Object.mem "folder" Jsont.json ~enc:(fun r -> r.folder) 6673 + |> Jsont.Object.mem "readable" Jsont.bool ~enc:(fun r -> r.readable) 6674 + |> Jsont.Object.mem "writable" Jsont.bool ~enc:(fun r -> r.writable) 6675 + |> Jsont.Object.skip_unknown 6676 + |> Jsont.Object.finish 6677 + end 6678 + 6679 + module SyncAckDeleteDto = struct 6680 + type t = { 6681 + types : SyncEntityType.t list option; 6682 + } 6683 + 6684 + let t_jsont : t Jsont.t = 6685 + Jsont.Object.map ~kind:"t" 6686 + (fun types -> { types }) 6687 + |> Jsont.Object.opt_mem "types" Jsont.(list SyncEntityType.t_jsont) ~enc:(fun r -> r.types) 6688 + |> Jsont.Object.skip_unknown 6689 + |> Jsont.Object.finish 6690 + end 6691 + 6692 + module SyncAckDto = struct 6693 + type t = { 6694 + ack : string; 6695 + type_ : Jsont.json; 6696 + } 6697 + 6698 + let t_jsont : t Jsont.t = 6699 + Jsont.Object.map ~kind:"t" 6700 + (fun ack type_ -> { ack; type_ }) 6701 + |> Jsont.Object.mem "ack" Jsont.string ~enc:(fun r -> r.ack) 6702 + |> Jsont.Object.mem "type" Jsont.json ~enc:(fun r -> r.type_) 6703 + |> Jsont.Object.skip_unknown 6704 + |> Jsont.Object.finish 6705 + end 6706 + 6707 + module SyncStreamDto = struct 6708 + type t = { 6709 + reset : bool option; 6710 + types : SyncRequestType.t list; 6711 + } 6712 + 6713 + let t_jsont : t Jsont.t = 6714 + Jsont.Object.map ~kind:"t" 6715 + (fun reset types -> { reset; types }) 6716 + |> Jsont.Object.opt_mem "reset" Jsont.bool ~enc:(fun r -> r.reset) 6717 + |> Jsont.Object.mem "types" Jsont.(list SyncRequestType.t_jsont) ~enc:(fun r -> r.types) 6718 + |> Jsont.Object.skip_unknown 6719 + |> Jsont.Object.finish 6720 + end 6721 + 6722 + module SystemConfigMetadataDto = struct 6723 + type t = { 6724 + faces : SystemConfigFacesDto.t; 6725 + } 6726 + 6727 + let t_jsont : t Jsont.t = 6728 + Jsont.Object.map ~kind:"t" 6729 + (fun faces -> { faces }) 6730 + |> Jsont.Object.mem "faces" SystemConfigFacesDto.t_jsont ~enc:(fun r -> r.faces) 6731 + |> Jsont.Object.skip_unknown 6732 + |> Jsont.Object.finish 6733 + end 6734 + 6735 + module SystemConfigLibraryDto = struct 6736 + type t = { 6737 + scan : SystemConfigLibraryScanDto.t; 6738 + watch : SystemConfigLibraryWatchDto.t; 6739 + } 6740 + 6741 + let t_jsont : t Jsont.t = 6742 + Jsont.Object.map ~kind:"t" 6743 + (fun scan watch -> { scan; watch }) 6744 + |> Jsont.Object.mem "scan" SystemConfigLibraryScanDto.t_jsont ~enc:(fun r -> r.scan) 6745 + |> Jsont.Object.mem "watch" SystemConfigLibraryWatchDto.t_jsont ~enc:(fun r -> r.watch) 6746 + |> Jsont.Object.skip_unknown 6747 + |> Jsont.Object.finish 6748 + end 6749 + 6750 + module SystemConfigSmtpDto = struct 6751 + type t = { 6752 + enabled : bool; 6753 + from : string; 6754 + reply_to : string; 6755 + transport : SystemConfigSmtpTransportDto.t; 6756 + } 6757 + 6758 + let t_jsont : t Jsont.t = 6759 + Jsont.Object.map ~kind:"t" 6760 + (fun enabled from reply_to transport -> { enabled; from; reply_to; transport }) 6761 + |> Jsont.Object.mem "enabled" Jsont.bool ~enc:(fun r -> r.enabled) 6762 + |> Jsont.Object.mem "from" Jsont.string ~enc:(fun r -> r.from) 6763 + |> Jsont.Object.mem "replyTo" Jsont.string ~enc:(fun r -> r.reply_to) 6764 + |> Jsont.Object.mem "transport" SystemConfigSmtpTransportDto.t_jsont ~enc:(fun r -> r.transport) 6765 + |> Jsont.Object.skip_unknown 6766 + |> Jsont.Object.finish 6767 + end 6768 + 6769 + module SystemConfigTemplatesDto = struct 6770 + type t = { 6771 + email : SystemConfigTemplateEmailsDto.t; 6772 + } 6773 + 6774 + let t_jsont : t Jsont.t = 6775 + Jsont.Object.map ~kind:"t" 6776 + (fun email -> { email }) 6777 + |> Jsont.Object.mem "email" SystemConfigTemplateEmailsDto.t_jsont ~enc:(fun r -> r.email) 6778 + |> Jsont.Object.skip_unknown 6779 + |> Jsont.Object.finish 6780 + end 6781 + 6782 + module ServerStatsResponseDto = struct 6783 + type t = { 6784 + photos : int; 6785 + usage : int64; 6786 + usage_by_user : UsageByUserDto.t list; 6787 + usage_photos : int64; 6788 + usage_videos : int64; 6789 + videos : int; 6790 + } 6791 + 6792 + let t_jsont : t Jsont.t = 6793 + Jsont.Object.map ~kind:"t" 6794 + (fun photos usage usage_by_user usage_photos usage_videos videos -> { photos; usage; usage_by_user; usage_photos; usage_videos; videos }) 6795 + |> Jsont.Object.mem "photos" Jsont.int ~enc:(fun r -> r.photos) 6796 + |> Jsont.Object.mem "usage" Jsont.int64 ~enc:(fun r -> r.usage) 6797 + |> Jsont.Object.mem "usageByUser" Jsont.(list UsageByUserDto.t_jsont) ~enc:(fun r -> r.usage_by_user) 6798 + |> Jsont.Object.mem "usagePhotos" Jsont.int64 ~enc:(fun r -> r.usage_photos) 6799 + |> Jsont.Object.mem "usageVideos" Jsont.int64 ~enc:(fun r -> r.usage_videos) 6800 + |> Jsont.Object.mem "videos" Jsont.int ~enc:(fun r -> r.videos) 6801 + |> Jsont.Object.skip_unknown 6802 + |> Jsont.Object.finish 6803 + end 6804 + 6805 + module AvatarUpdate = struct 6806 + type t = { 6807 + color : Jsont.json option; 6808 + } 6809 + 6810 + let t_jsont : t Jsont.t = 6811 + Jsont.Object.map ~kind:"t" 6812 + (fun color -> { color }) 6813 + |> Jsont.Object.opt_mem "color" Jsont.json ~enc:(fun r -> r.color) 6814 + |> Jsont.Object.skip_unknown 6815 + |> Jsont.Object.finish 6816 + end 6817 + 6818 + module PartnerResponseDto = struct 6819 + type t = { 6820 + avatar_color : Jsont.json; 6821 + email : string; 6822 + id : string; 6823 + in_timeline : bool option; 6824 + name : string; 6825 + profile_changed_at : Ptime.t; 6826 + profile_image_path : string; 6827 + } 6828 + 6829 + let t_jsont : t Jsont.t = 6830 + Jsont.Object.map ~kind:"t" 6831 + (fun avatar_color email id in_timeline name profile_changed_at profile_image_path -> { avatar_color; email; id; in_timeline; name; profile_changed_at; profile_image_path }) 6832 + |> Jsont.Object.mem "avatarColor" Jsont.json ~enc:(fun r -> r.avatar_color) 6833 + |> Jsont.Object.mem "email" Jsont.string ~enc:(fun r -> r.email) 6834 + |> Jsont.Object.mem "id" Jsont.string ~enc:(fun r -> r.id) 6835 + |> Jsont.Object.opt_mem "inTimeline" Jsont.bool ~enc:(fun r -> r.in_timeline) 6836 + |> Jsont.Object.mem "name" Jsont.string ~enc:(fun r -> r.name) 6837 + |> Jsont.Object.mem "profileChangedAt" Openapi.Runtime.ptime_jsont ~enc:(fun r -> r.profile_changed_at) 6838 + |> Jsont.Object.mem "profileImagePath" Jsont.string ~enc:(fun r -> r.profile_image_path) 6839 + |> Jsont.Object.skip_unknown 6840 + |> Jsont.Object.finish 6841 + end 6842 + 6843 + module SyncAuthUserV1 = struct 6844 + type t = { 6845 + avatar_color : Jsont.json option; 6846 + deleted_at : Ptime.t; 6847 + email : string; 6848 + has_profile_image : bool; 6849 + id : string; 6850 + is_admin : bool; 6851 + name : string; 6852 + oauth_id : string; 6853 + pin_code : string; 6854 + profile_changed_at : Ptime.t; 6855 + quota_size_in_bytes : int; 6856 + quota_usage_in_bytes : int; 6857 + storage_label : string; 6858 + } 6859 + 6860 + let t_jsont : t Jsont.t = 6861 + Jsont.Object.map ~kind:"t" 6862 + (fun avatar_color deleted_at email has_profile_image id is_admin name oauth_id pin_code profile_changed_at quota_size_in_bytes quota_usage_in_bytes storage_label -> { avatar_color; deleted_at; email; has_profile_image; id; is_admin; name; oauth_id; pin_code; profile_changed_at; quota_size_in_bytes; quota_usage_in_bytes; storage_label }) 6863 + |> Jsont.Object.mem "avatarColor" (Jsont.option Jsont.json) 6864 + ~dec_absent:None ~enc_omit:Option.is_none ~enc:(fun r -> r.avatar_color) 6865 + |> Jsont.Object.mem "deletedAt" Openapi.Runtime.ptime_jsont ~enc:(fun r -> r.deleted_at) 6866 + |> Jsont.Object.mem "email" Jsont.string ~enc:(fun r -> r.email) 6867 + |> Jsont.Object.mem "hasProfileImage" Jsont.bool ~enc:(fun r -> r.has_profile_image) 6868 + |> Jsont.Object.mem "id" Jsont.string ~enc:(fun r -> r.id) 6869 + |> Jsont.Object.mem "isAdmin" Jsont.bool ~enc:(fun r -> r.is_admin) 6870 + |> Jsont.Object.mem "name" Jsont.string ~enc:(fun r -> r.name) 6871 + |> Jsont.Object.mem "oauthId" Jsont.string ~enc:(fun r -> r.oauth_id) 6872 + |> Jsont.Object.mem "pinCode" Jsont.string ~enc:(fun r -> r.pin_code) 6873 + |> Jsont.Object.mem "profileChangedAt" Openapi.Runtime.ptime_jsont ~enc:(fun r -> r.profile_changed_at) 6874 + |> Jsont.Object.mem "quotaSizeInBytes" Jsont.int ~enc:(fun r -> r.quota_size_in_bytes) 6875 + |> Jsont.Object.mem "quotaUsageInBytes" Jsont.int ~enc:(fun r -> r.quota_usage_in_bytes) 6876 + |> Jsont.Object.mem "storageLabel" Jsont.string ~enc:(fun r -> r.storage_label) 6877 + |> Jsont.Object.skip_unknown 6878 + |> Jsont.Object.finish 6879 + end 6880 + 6881 + module SyncUserV1 = struct 6882 + type t = { 6883 + avatar_color : Jsont.json option; 6884 + deleted_at : Ptime.t; 6885 + email : string; 6886 + has_profile_image : bool; 6887 + id : string; 6888 + name : string; 6889 + profile_changed_at : Ptime.t; 6890 + } 6891 + 6892 + let t_jsont : t Jsont.t = 6893 + Jsont.Object.map ~kind:"t" 6894 + (fun avatar_color deleted_at email has_profile_image id name profile_changed_at -> { avatar_color; deleted_at; email; has_profile_image; id; name; profile_changed_at }) 6895 + |> Jsont.Object.mem "avatarColor" (Jsont.option Jsont.json) 6896 + ~dec_absent:None ~enc_omit:Option.is_none ~enc:(fun r -> r.avatar_color) 6897 + |> Jsont.Object.mem "deletedAt" Openapi.Runtime.ptime_jsont ~enc:(fun r -> r.deleted_at) 6898 + |> Jsont.Object.mem "email" Jsont.string ~enc:(fun r -> r.email) 6899 + |> Jsont.Object.mem "hasProfileImage" Jsont.bool ~enc:(fun r -> r.has_profile_image) 6900 + |> Jsont.Object.mem "id" Jsont.string ~enc:(fun r -> r.id) 6901 + |> Jsont.Object.mem "name" Jsont.string ~enc:(fun r -> r.name) 6902 + |> Jsont.Object.mem "profileChangedAt" Openapi.Runtime.ptime_jsont ~enc:(fun r -> r.profile_changed_at) 6903 + |> Jsont.Object.skip_unknown 6904 + |> Jsont.Object.finish 6905 + end 6906 + 6907 + module UserAdminCreateDto = struct 6908 + type t = { 6909 + avatar_color : Jsont.json option; 6910 + email : string; 6911 + is_admin : bool option; 6912 + name : string; 6913 + notify : bool option; 6914 + password : string; 6915 + quota_size_in_bytes : int64 option; 6916 + should_change_password : bool option; 6917 + storage_label : string option; 6918 + } 6919 + 6920 + let t_jsont : t Jsont.t = 6921 + Jsont.Object.map ~kind:"t" 6922 + (fun avatar_color email is_admin name notify password quota_size_in_bytes should_change_password storage_label -> { avatar_color; email; is_admin; name; notify; password; quota_size_in_bytes; should_change_password; storage_label }) 6923 + |> Jsont.Object.opt_mem "avatarColor" Jsont.json ~enc:(fun r -> r.avatar_color) 6924 + |> Jsont.Object.mem "email" Jsont.string ~enc:(fun r -> r.email) 6925 + |> Jsont.Object.opt_mem "isAdmin" Jsont.bool ~enc:(fun r -> r.is_admin) 6926 + |> Jsont.Object.mem "name" Jsont.string ~enc:(fun r -> r.name) 6927 + |> Jsont.Object.opt_mem "notify" Jsont.bool ~enc:(fun r -> r.notify) 6928 + |> Jsont.Object.mem "password" Jsont.string ~enc:(fun r -> r.password) 6929 + |> Jsont.Object.opt_mem "quotaSizeInBytes" Jsont.int64 ~enc:(fun r -> r.quota_size_in_bytes) 6930 + |> Jsont.Object.opt_mem "shouldChangePassword" Jsont.bool ~enc:(fun r -> r.should_change_password) 6931 + |> Jsont.Object.opt_mem "storageLabel" Jsont.string ~enc:(fun r -> r.storage_label) 6932 + |> Jsont.Object.skip_unknown 6933 + |> Jsont.Object.finish 6934 + end 6935 + 6936 + module UserAdminUpdateDto = struct 6937 + type t = { 6938 + avatar_color : Jsont.json option; 6939 + email : string option; 6940 + is_admin : bool option; 6941 + name : string option; 6942 + password : string option; 6943 + pin_code : string option; 6944 + quota_size_in_bytes : int64 option; 6945 + should_change_password : bool option; 6946 + storage_label : string option; 6947 + } 6948 + 6949 + let t_jsont : t Jsont.t = 6950 + Jsont.Object.map ~kind:"t" 6951 + (fun avatar_color email is_admin name password pin_code quota_size_in_bytes should_change_password storage_label -> { avatar_color; email; is_admin; name; password; pin_code; quota_size_in_bytes; should_change_password; storage_label }) 6952 + |> Jsont.Object.opt_mem "avatarColor" Jsont.json ~enc:(fun r -> r.avatar_color) 6953 + |> Jsont.Object.opt_mem "email" Jsont.string ~enc:(fun r -> r.email) 6954 + |> Jsont.Object.opt_mem "isAdmin" Jsont.bool ~enc:(fun r -> r.is_admin) 6955 + |> Jsont.Object.opt_mem "name" Jsont.string ~enc:(fun r -> r.name) 6956 + |> Jsont.Object.opt_mem "password" Jsont.string ~enc:(fun r -> r.password) 6957 + |> Jsont.Object.opt_mem "pinCode" Jsont.string ~enc:(fun r -> r.pin_code) 6958 + |> Jsont.Object.opt_mem "quotaSizeInBytes" Jsont.int64 ~enc:(fun r -> r.quota_size_in_bytes) 6959 + |> Jsont.Object.opt_mem "shouldChangePassword" Jsont.bool ~enc:(fun r -> r.should_change_password) 6960 + |> Jsont.Object.opt_mem "storageLabel" Jsont.string ~enc:(fun r -> r.storage_label) 6961 + |> Jsont.Object.skip_unknown 6962 + |> Jsont.Object.finish 6963 + end 6964 + 6965 + module UserResponseDto = struct 6966 + type t = { 6967 + avatar_color : Jsont.json; 6968 + email : string; 6969 + id : string; 6970 + name : string; 6971 + profile_changed_at : Ptime.t; 6972 + profile_image_path : string; 6973 + } 6974 + 6975 + let t_jsont : t Jsont.t = 6976 + Jsont.Object.map ~kind:"t" 6977 + (fun avatar_color email id name profile_changed_at profile_image_path -> { avatar_color; email; id; name; profile_changed_at; profile_image_path }) 6978 + |> Jsont.Object.mem "avatarColor" Jsont.json ~enc:(fun r -> r.avatar_color) 6979 + |> Jsont.Object.mem "email" Jsont.string ~enc:(fun r -> r.email) 6980 + |> Jsont.Object.mem "id" Jsont.string ~enc:(fun r -> r.id) 6981 + |> Jsont.Object.mem "name" Jsont.string ~enc:(fun r -> r.name) 6982 + |> Jsont.Object.mem "profileChangedAt" Openapi.Runtime.ptime_jsont ~enc:(fun r -> r.profile_changed_at) 6983 + |> Jsont.Object.mem "profileImagePath" Jsont.string ~enc:(fun r -> r.profile_image_path) 6984 + |> Jsont.Object.skip_unknown 6985 + |> Jsont.Object.finish 6986 + end 6987 + 6988 + module UserUpdateMeDto = struct 6989 + type t = { 6990 + avatar_color : Jsont.json option; 6991 + email : string option; 6992 + name : string option; 6993 + password : string option; 6994 + } 6995 + 6996 + let t_jsont : t Jsont.t = 6997 + Jsont.Object.map ~kind:"t" 6998 + (fun avatar_color email name password -> { avatar_color; email; name; password }) 6999 + |> Jsont.Object.opt_mem "avatarColor" Jsont.json ~enc:(fun r -> r.avatar_color) 7000 + |> Jsont.Object.opt_mem "email" Jsont.string ~enc:(fun r -> r.email) 7001 + |> Jsont.Object.opt_mem "name" Jsont.string ~enc:(fun r -> r.name) 7002 + |> Jsont.Object.opt_mem "password" Jsont.string ~enc:(fun r -> r.password) 7003 + |> Jsont.Object.skip_unknown 7004 + |> Jsont.Object.finish 7005 + end 7006 + 7007 + module SyncUserMetadataDeleteV1 = struct 7008 + type t = { 7009 + key : Jsont.json; 7010 + user_id : string; 7011 + } 7012 + 7013 + let t_jsont : t Jsont.t = 7014 + Jsont.Object.map ~kind:"t" 7015 + (fun key user_id -> { key; user_id }) 7016 + |> Jsont.Object.mem "key" Jsont.json ~enc:(fun r -> r.key) 7017 + |> Jsont.Object.mem "userId" Jsont.string ~enc:(fun r -> r.user_id) 7018 + |> Jsont.Object.skip_unknown 7019 + |> Jsont.Object.finish 7020 + end 7021 + 7022 + module SyncUserMetadataV1 = struct 7023 + type t = { 7024 + key : Jsont.json; 7025 + user_id : string; 7026 + value : Jsont.json; 7027 + } 7028 + 7029 + let t_jsont : t Jsont.t = 7030 + Jsont.Object.map ~kind:"t" 7031 + (fun key user_id value -> { key; user_id; value }) 7032 + |> Jsont.Object.mem "key" Jsont.json ~enc:(fun r -> r.key) 7033 + |> Jsont.Object.mem "userId" Jsont.string ~enc:(fun r -> r.user_id) 7034 + |> Jsont.Object.mem "value" Jsont.json ~enc:(fun r -> r.value) 7035 + |> Jsont.Object.skip_unknown 7036 + |> Jsont.Object.finish 7037 + end 7038 + 7039 + module UserAdminResponseDto = struct 7040 + type t = { 7041 + avatar_color : Jsont.json; 7042 + created_at : Ptime.t; 7043 + deleted_at : Ptime.t; 7044 + email : string; 7045 + id : string; 7046 + is_admin : bool; 7047 + license : Jsont.json option; 7048 + name : string; 7049 + oauth_id : string; 7050 + profile_changed_at : Ptime.t; 7051 + profile_image_path : string; 7052 + quota_size_in_bytes : int64; 7053 + quota_usage_in_bytes : int64; 7054 + should_change_password : bool; 7055 + status : Jsont.json; 7056 + storage_label : string; 7057 + updated_at : Ptime.t; 7058 + } 7059 + 7060 + let t_jsont : t Jsont.t = 7061 + Jsont.Object.map ~kind:"t" 7062 + (fun avatar_color created_at deleted_at email id is_admin license name oauth_id profile_changed_at profile_image_path quota_size_in_bytes quota_usage_in_bytes should_change_password status storage_label updated_at -> { avatar_color; created_at; deleted_at; email; id; is_admin; license; name; oauth_id; profile_changed_at; profile_image_path; quota_size_in_bytes; quota_usage_in_bytes; should_change_password; status; storage_label; updated_at }) 7063 + |> Jsont.Object.mem "avatarColor" Jsont.json ~enc:(fun r -> r.avatar_color) 7064 + |> Jsont.Object.mem "createdAt" Openapi.Runtime.ptime_jsont ~enc:(fun r -> r.created_at) 7065 + |> Jsont.Object.mem "deletedAt" Openapi.Runtime.ptime_jsont ~enc:(fun r -> r.deleted_at) 7066 + |> Jsont.Object.mem "email" Jsont.string ~enc:(fun r -> r.email) 7067 + |> Jsont.Object.mem "id" Jsont.string ~enc:(fun r -> r.id) 7068 + |> Jsont.Object.mem "isAdmin" Jsont.bool ~enc:(fun r -> r.is_admin) 7069 + |> Jsont.Object.mem "license" (Jsont.option Jsont.json) 7070 + ~dec_absent:None ~enc_omit:Option.is_none ~enc:(fun r -> r.license) 7071 + |> Jsont.Object.mem "name" Jsont.string ~enc:(fun r -> r.name) 7072 + |> Jsont.Object.mem "oauthId" Jsont.string ~enc:(fun r -> r.oauth_id) 7073 + |> Jsont.Object.mem "profileChangedAt" Openapi.Runtime.ptime_jsont ~enc:(fun r -> r.profile_changed_at) 7074 + |> Jsont.Object.mem "profileImagePath" Jsont.string ~enc:(fun r -> r.profile_image_path) 7075 + |> Jsont.Object.mem "quotaSizeInBytes" Jsont.int64 ~enc:(fun r -> r.quota_size_in_bytes) 7076 + |> Jsont.Object.mem "quotaUsageInBytes" Jsont.int64 ~enc:(fun r -> r.quota_usage_in_bytes) 7077 + |> Jsont.Object.mem "shouldChangePassword" Jsont.bool ~enc:(fun r -> r.should_change_password) 7078 + |> Jsont.Object.mem "status" Jsont.json ~enc:(fun r -> r.status) 7079 + |> Jsont.Object.mem "storageLabel" Jsont.string ~enc:(fun r -> r.storage_label) 7080 + |> Jsont.Object.mem "updatedAt" Openapi.Runtime.ptime_jsont ~enc:(fun r -> r.updated_at) 7081 + |> Jsont.Object.skip_unknown 7082 + |> Jsont.Object.finish 7083 + end 7084 + 7085 + module ValidateLibraryResponseDto = struct 7086 + type t = { 7087 + import_paths : ValidateLibraryImportPathResponseDto.t list option; 7088 + } 7089 + 7090 + let t_jsont : t Jsont.t = 7091 + Jsont.Object.map ~kind:"t" 7092 + (fun import_paths -> { import_paths }) 7093 + |> Jsont.Object.opt_mem "importPaths" Jsont.(list ValidateLibraryImportPathResponseDto.t_jsont) ~enc:(fun r -> r.import_paths) 7094 + |> Jsont.Object.skip_unknown 7095 + |> Jsont.Object.finish 7096 + end 7097 + 7098 + module SystemConfigFfmpegDto = struct 7099 + type t = { 7100 + accel : Jsont.json; 7101 + accel_decode : bool; 7102 + accepted_audio_codecs : AudioCodec.t list; 7103 + accepted_containers : VideoContainer.t list; 7104 + accepted_video_codecs : VideoCodec.t list; 7105 + bframes : int; 7106 + cq_mode : Jsont.json; 7107 + crf : int; 7108 + gop_size : int; 7109 + max_bitrate : string; 7110 + preferred_hw_device : string; 7111 + preset : string; 7112 + refs : int; 7113 + target_audio_codec : Jsont.json; 7114 + target_resolution : string; 7115 + target_video_codec : Jsont.json; 7116 + temporal_aq : bool; 7117 + threads : int; 7118 + tonemap : Jsont.json; 7119 + transcode : Jsont.json; 7120 + two_pass : bool; 7121 + } 7122 + 7123 + let t_jsont : t Jsont.t = 7124 + Jsont.Object.map ~kind:"t" 7125 + (fun accel accel_decode accepted_audio_codecs accepted_containers accepted_video_codecs bframes cq_mode crf gop_size max_bitrate preferred_hw_device preset refs target_audio_codec target_resolution target_video_codec temporal_aq threads tonemap transcode two_pass -> { accel; accel_decode; accepted_audio_codecs; accepted_containers; accepted_video_codecs; bframes; cq_mode; crf; gop_size; max_bitrate; preferred_hw_device; preset; refs; target_audio_codec; target_resolution; target_video_codec; temporal_aq; threads; tonemap; transcode; two_pass }) 7126 + |> Jsont.Object.mem "accel" Jsont.json ~enc:(fun r -> r.accel) 7127 + |> Jsont.Object.mem "accelDecode" Jsont.bool ~enc:(fun r -> r.accel_decode) 7128 + |> Jsont.Object.mem "acceptedAudioCodecs" Jsont.(list AudioCodec.t_jsont) ~enc:(fun r -> r.accepted_audio_codecs) 7129 + |> Jsont.Object.mem "acceptedContainers" Jsont.(list VideoContainer.t_jsont) ~enc:(fun r -> r.accepted_containers) 7130 + |> Jsont.Object.mem "acceptedVideoCodecs" Jsont.(list VideoCodec.t_jsont) ~enc:(fun r -> r.accepted_video_codecs) 7131 + |> Jsont.Object.mem "bframes" Jsont.int ~enc:(fun r -> r.bframes) 7132 + |> Jsont.Object.mem "cqMode" Jsont.json ~enc:(fun r -> r.cq_mode) 7133 + |> Jsont.Object.mem "crf" Jsont.int ~enc:(fun r -> r.crf) 7134 + |> Jsont.Object.mem "gopSize" Jsont.int ~enc:(fun r -> r.gop_size) 7135 + |> Jsont.Object.mem "maxBitrate" Jsont.string ~enc:(fun r -> r.max_bitrate) 7136 + |> Jsont.Object.mem "preferredHwDevice" Jsont.string ~enc:(fun r -> r.preferred_hw_device) 7137 + |> Jsont.Object.mem "preset" Jsont.string ~enc:(fun r -> r.preset) 7138 + |> Jsont.Object.mem "refs" Jsont.int ~enc:(fun r -> r.refs) 7139 + |> Jsont.Object.mem "targetAudioCodec" Jsont.json ~enc:(fun r -> r.target_audio_codec) 7140 + |> Jsont.Object.mem "targetResolution" Jsont.string ~enc:(fun r -> r.target_resolution) 7141 + |> Jsont.Object.mem "targetVideoCodec" Jsont.json ~enc:(fun r -> r.target_video_codec) 7142 + |> Jsont.Object.mem "temporalAQ" Jsont.bool ~enc:(fun r -> r.temporal_aq) 7143 + |> Jsont.Object.mem "threads" Jsont.int ~enc:(fun r -> r.threads) 7144 + |> Jsont.Object.mem "tonemap" Jsont.json ~enc:(fun r -> r.tonemap) 7145 + |> Jsont.Object.mem "transcode" Jsont.json ~enc:(fun r -> r.transcode) 7146 + |> Jsont.Object.mem "twoPass" Jsont.bool ~enc:(fun r -> r.two_pass) 7147 + |> Jsont.Object.skip_unknown 7148 + |> Jsont.Object.finish 7149 + end 7150 + 7151 + module WorkflowCreateDto = struct 7152 + type t = { 7153 + actions : WorkflowActionItemDto.t list; 7154 + description : string option; 7155 + enabled : bool option; 7156 + filters : WorkflowFilterItemDto.t list; 7157 + name : string; 7158 + trigger_type : Jsont.json; 7159 + } 7160 + 7161 + let t_jsont : t Jsont.t = 7162 + Jsont.Object.map ~kind:"t" 7163 + (fun actions description enabled filters name trigger_type -> { actions; description; enabled; filters; name; trigger_type }) 7164 + |> Jsont.Object.mem "actions" Jsont.(list WorkflowActionItemDto.t_jsont) ~enc:(fun r -> r.actions) 7165 + |> Jsont.Object.opt_mem "description" Jsont.string ~enc:(fun r -> r.description) 7166 + |> Jsont.Object.opt_mem "enabled" Jsont.bool ~enc:(fun r -> r.enabled) 7167 + |> Jsont.Object.mem "filters" Jsont.(list WorkflowFilterItemDto.t_jsont) ~enc:(fun r -> r.filters) 7168 + |> Jsont.Object.mem "name" Jsont.string ~enc:(fun r -> r.name) 7169 + |> Jsont.Object.mem "triggerType" Jsont.json ~enc:(fun r -> r.trigger_type) 7170 + |> Jsont.Object.skip_unknown 7171 + |> Jsont.Object.finish 7172 + end 7173 + 7174 + module WorkflowUpdateDto = struct 7175 + type t = { 7176 + actions : WorkflowActionItemDto.t list option; 7177 + description : string option; 7178 + enabled : bool option; 7179 + filters : WorkflowFilterItemDto.t list option; 7180 + name : string option; 7181 + trigger_type : Jsont.json option; 7182 + } 7183 + 7184 + let t_jsont : t Jsont.t = 7185 + Jsont.Object.map ~kind:"t" 7186 + (fun actions description enabled filters name trigger_type -> { actions; description; enabled; filters; name; trigger_type }) 7187 + |> Jsont.Object.opt_mem "actions" Jsont.(list WorkflowActionItemDto.t_jsont) ~enc:(fun r -> r.actions) 7188 + |> Jsont.Object.opt_mem "description" Jsont.string ~enc:(fun r -> r.description) 7189 + |> Jsont.Object.opt_mem "enabled" Jsont.bool ~enc:(fun r -> r.enabled) 7190 + |> Jsont.Object.opt_mem "filters" Jsont.(list WorkflowFilterItemDto.t_jsont) ~enc:(fun r -> r.filters) 7191 + |> Jsont.Object.opt_mem "name" Jsont.string ~enc:(fun r -> r.name) 7192 + |> Jsont.Object.opt_mem "triggerType" Jsont.json ~enc:(fun r -> r.trigger_type) 7193 + |> Jsont.Object.skip_unknown 7194 + |> Jsont.Object.finish 7195 + end 7196 + 7197 + module WorkflowResponseDto = struct 7198 + type t = { 7199 + actions : WorkflowActionResponseDto.t list; 7200 + created_at : string; 7201 + description : string; 7202 + enabled : bool; 7203 + filters : WorkflowFilterResponseDto.t list; 7204 + id : string; 7205 + name : string; 7206 + owner_id : string; 7207 + trigger_type : Jsont.json; 7208 + } 7209 + 7210 + let t_jsont : t Jsont.t = 7211 + Jsont.Object.map ~kind:"t" 7212 + (fun actions created_at description enabled filters id name owner_id trigger_type -> { actions; created_at; description; enabled; filters; id; name; owner_id; trigger_type }) 7213 + |> Jsont.Object.mem "actions" Jsont.(list WorkflowActionResponseDto.t_jsont) ~enc:(fun r -> r.actions) 7214 + |> Jsont.Object.mem "createdAt" Jsont.string ~enc:(fun r -> r.created_at) 7215 + |> Jsont.Object.mem "description" Jsont.string ~enc:(fun r -> r.description) 7216 + |> Jsont.Object.mem "enabled" Jsont.bool ~enc:(fun r -> r.enabled) 7217 + |> Jsont.Object.mem "filters" Jsont.(list WorkflowFilterResponseDto.t_jsont) ~enc:(fun r -> r.filters) 7218 + |> Jsont.Object.mem "id" Jsont.string ~enc:(fun r -> r.id) 7219 + |> Jsont.Object.mem "name" Jsont.string ~enc:(fun r -> r.name) 7220 + |> Jsont.Object.mem "ownerId" Jsont.string ~enc:(fun r -> r.owner_id) 7221 + |> Jsont.Object.mem "triggerType" Jsont.json ~enc:(fun r -> r.trigger_type) 7222 + |> Jsont.Object.skip_unknown 7223 + |> Jsont.Object.finish 7224 + end 7225 + 7226 + module AddUsersDto = struct 7227 + type t = { 7228 + album_users : AlbumUserAddDto.t list; 7229 + } 7230 + 7231 + let t_jsont : t Jsont.t = 7232 + Jsont.Object.map ~kind:"t" 7233 + (fun album_users -> { album_users }) 7234 + |> Jsont.Object.mem "albumUsers" Jsont.(list AlbumUserAddDto.t_jsont) ~enc:(fun r -> r.album_users) 7235 + |> Jsont.Object.skip_unknown 7236 + |> Jsont.Object.finish 7237 + end 7238 + 7239 + module CreateAlbumDto = struct 7240 + type t = { 7241 + album_name : string; 7242 + album_users : AlbumUserCreateDto.t list option; 7243 + asset_ids : string list option; 7244 + description : string option; 7245 + } 7246 + 7247 + let t_jsont : t Jsont.t = 7248 + Jsont.Object.map ~kind:"t" 7249 + (fun album_name album_users asset_ids description -> { album_name; album_users; asset_ids; description }) 7250 + |> Jsont.Object.mem "albumName" Jsont.string ~enc:(fun r -> r.album_name) 7251 + |> Jsont.Object.opt_mem "albumUsers" Jsont.(list AlbumUserCreateDto.t_jsont) ~enc:(fun r -> r.album_users) 7252 + |> Jsont.Object.opt_mem "assetIds" Jsont.(list Jsont.string) ~enc:(fun r -> r.asset_ids) 7253 + |> Jsont.Object.opt_mem "description" Jsont.string ~enc:(fun r -> r.description) 7254 + |> Jsont.Object.skip_unknown 7255 + |> Jsont.Object.finish 7256 + end 7257 + 7258 + module UserPreferencesResponseDto = struct 7259 + type t = { 7260 + albums : AlbumsResponse.t; 7261 + cast : CastResponse.t; 7262 + download : DownloadResponse.t; 7263 + email_notifications : EmailNotificationsResponse.t; 7264 + folders : FoldersResponse.t; 7265 + memories : MemoriesResponse.t; 7266 + people : PeopleResponse.t; 7267 + purchase : PurchaseResponse.t; 7268 + ratings : RatingsResponse.t; 7269 + shared_links : SharedLinksResponse.t; 7270 + tags : TagsResponse.t; 7271 + } 7272 + 7273 + let t_jsont : t Jsont.t = 7274 + Jsont.Object.map ~kind:"t" 7275 + (fun albums cast download email_notifications folders memories people purchase ratings shared_links tags -> { albums; cast; download; email_notifications; folders; memories; people; purchase; ratings; shared_links; tags }) 7276 + |> Jsont.Object.mem "albums" AlbumsResponse.t_jsont ~enc:(fun r -> r.albums) 7277 + |> Jsont.Object.mem "cast" CastResponse.t_jsont ~enc:(fun r -> r.cast) 7278 + |> Jsont.Object.mem "download" DownloadResponse.t_jsont ~enc:(fun r -> r.download) 7279 + |> Jsont.Object.mem "emailNotifications" EmailNotificationsResponse.t_jsont ~enc:(fun r -> r.email_notifications) 7280 + |> Jsont.Object.mem "folders" FoldersResponse.t_jsont ~enc:(fun r -> r.folders) 7281 + |> Jsont.Object.mem "memories" MemoriesResponse.t_jsont ~enc:(fun r -> r.memories) 7282 + |> Jsont.Object.mem "people" PeopleResponse.t_jsont ~enc:(fun r -> r.people) 7283 + |> Jsont.Object.mem "purchase" PurchaseResponse.t_jsont ~enc:(fun r -> r.purchase) 7284 + |> Jsont.Object.mem "ratings" RatingsResponse.t_jsont ~enc:(fun r -> r.ratings) 7285 + |> Jsont.Object.mem "sharedLinks" SharedLinksResponse.t_jsont ~enc:(fun r -> r.shared_links) 7286 + |> Jsont.Object.mem "tags" TagsResponse.t_jsont ~enc:(fun r -> r.tags) 7287 + |> Jsont.Object.skip_unknown 7288 + |> Jsont.Object.finish 7289 + end 7290 + 7291 + module SystemConfigImageDto = struct 7292 + type t = { 7293 + colorspace : Jsont.json; 7294 + extract_embedded : bool; 7295 + fullsize : SystemConfigGeneratedFullsizeImageDto.t; 7296 + preview : SystemConfigGeneratedImageDto.t; 7297 + thumbnail : SystemConfigGeneratedImageDto.t; 7298 + } 7299 + 7300 + let t_jsont : t Jsont.t = 7301 + Jsont.Object.map ~kind:"t" 7302 + (fun colorspace extract_embedded fullsize preview thumbnail -> { colorspace; extract_embedded; fullsize; preview; thumbnail }) 7303 + |> Jsont.Object.mem "colorspace" Jsont.json ~enc:(fun r -> r.colorspace) 7304 + |> Jsont.Object.mem "extractEmbedded" Jsont.bool ~enc:(fun r -> r.extract_embedded) 7305 + |> Jsont.Object.mem "fullsize" SystemConfigGeneratedFullsizeImageDto.t_jsont ~enc:(fun r -> r.fullsize) 7306 + |> Jsont.Object.mem "preview" SystemConfigGeneratedImageDto.t_jsont ~enc:(fun r -> r.preview) 7307 + |> Jsont.Object.mem "thumbnail" SystemConfigGeneratedImageDto.t_jsont ~enc:(fun r -> r.thumbnail) 7308 + |> Jsont.Object.skip_unknown 7309 + |> Jsont.Object.finish 7310 + end 7311 + 7312 + module AssetEditActionMirror = struct 7313 + type t = { 7314 + action : Jsont.json; 7315 + parameters : MirrorParameters.t; 7316 + } 7317 + 7318 + let t_jsont : t Jsont.t = 7319 + Jsont.Object.map ~kind:"t" 7320 + (fun action parameters -> { action; parameters }) 7321 + |> Jsont.Object.mem "action" Jsont.json ~enc:(fun r -> r.action) 7322 + |> Jsont.Object.mem "parameters" MirrorParameters.t_jsont ~enc:(fun r -> r.parameters) 7323 + |> Jsont.Object.skip_unknown 7324 + |> Jsont.Object.finish 7325 + end 7326 + 7327 + module ApikeyCreateResponseDto = struct 7328 + type t = { 7329 + api_key : ApikeyResponseDto.t; 7330 + secret : string; 7331 + } 7332 + 7333 + let t_jsont : t Jsont.t = 7334 + Jsont.Object.map ~kind:"t" 7335 + (fun api_key secret -> { api_key; secret }) 7336 + |> Jsont.Object.mem "apiKey" ApikeyResponseDto.t_jsont ~enc:(fun r -> r.api_key) 7337 + |> Jsont.Object.mem "secret" Jsont.string ~enc:(fun r -> r.secret) 7338 + |> Jsont.Object.skip_unknown 7339 + |> Jsont.Object.finish 7340 + end 7341 + 7342 + module PluginResponseDto = struct 7343 + type t = { 7344 + actions : PluginActionResponseDto.t list; 7345 + author : string; 7346 + created_at : string; 7347 + description : string; 7348 + filters : PluginFilterResponseDto.t list; 7349 + id : string; 7350 + name : string; 7351 + title : string; 7352 + updated_at : string; 7353 + version : string; 7354 + } 7355 + 7356 + let t_jsont : t Jsont.t = 7357 + Jsont.Object.map ~kind:"t" 7358 + (fun actions author created_at description filters id name title updated_at version -> { actions; author; created_at; description; filters; id; name; title; updated_at; version }) 7359 + |> Jsont.Object.mem "actions" Jsont.(list PluginActionResponseDto.t_jsont) ~enc:(fun r -> r.actions) 7360 + |> Jsont.Object.mem "author" Jsont.string ~enc:(fun r -> r.author) 7361 + |> Jsont.Object.mem "createdAt" Jsont.string ~enc:(fun r -> r.created_at) 7362 + |> Jsont.Object.mem "description" Jsont.string ~enc:(fun r -> r.description) 7363 + |> Jsont.Object.mem "filters" Jsont.(list PluginFilterResponseDto.t_jsont) ~enc:(fun r -> r.filters) 7364 + |> Jsont.Object.mem "id" Jsont.string ~enc:(fun r -> r.id) 7365 + |> Jsont.Object.mem "name" Jsont.string ~enc:(fun r -> r.name) 7366 + |> Jsont.Object.mem "title" Jsont.string ~enc:(fun r -> r.title) 7367 + |> Jsont.Object.mem "updatedAt" Jsont.string ~enc:(fun r -> r.updated_at) 7368 + |> Jsont.Object.mem "version" Jsont.string ~enc:(fun r -> r.version) 7369 + |> Jsont.Object.skip_unknown 7370 + |> Jsont.Object.finish 7371 + end 7372 + 7373 + module QueuesResponseLegacyDto = struct 7374 + type t = { 7375 + background_task : QueueResponseLegacyDto.t; 7376 + backup_database : QueueResponseLegacyDto.t; 7377 + duplicate_detection : QueueResponseLegacyDto.t; 7378 + editor : QueueResponseLegacyDto.t; 7379 + face_detection : QueueResponseLegacyDto.t; 7380 + facial_recognition : QueueResponseLegacyDto.t; 7381 + library : QueueResponseLegacyDto.t; 7382 + metadata_extraction : QueueResponseLegacyDto.t; 7383 + migration : QueueResponseLegacyDto.t; 7384 + notifications : QueueResponseLegacyDto.t; 7385 + ocr : QueueResponseLegacyDto.t; 7386 + search : QueueResponseLegacyDto.t; 7387 + sidecar : QueueResponseLegacyDto.t; 7388 + smart_search : QueueResponseLegacyDto.t; 7389 + storage_template_migration : QueueResponseLegacyDto.t; 7390 + thumbnail_generation : QueueResponseLegacyDto.t; 7391 + video_conversion : QueueResponseLegacyDto.t; 7392 + workflow : QueueResponseLegacyDto.t; 7393 + } 7394 + 7395 + let t_jsont : t Jsont.t = 7396 + Jsont.Object.map ~kind:"t" 7397 + (fun background_task backup_database duplicate_detection editor face_detection facial_recognition library metadata_extraction migration notifications ocr search sidecar smart_search storage_template_migration thumbnail_generation video_conversion workflow -> { background_task; backup_database; duplicate_detection; editor; face_detection; facial_recognition; library; metadata_extraction; migration; notifications; ocr; search; sidecar; smart_search; storage_template_migration; thumbnail_generation; video_conversion; workflow }) 7398 + |> Jsont.Object.mem "backgroundTask" QueueResponseLegacyDto.t_jsont ~enc:(fun r -> r.background_task) 7399 + |> Jsont.Object.mem "backupDatabase" QueueResponseLegacyDto.t_jsont ~enc:(fun r -> r.backup_database) 7400 + |> Jsont.Object.mem "duplicateDetection" QueueResponseLegacyDto.t_jsont ~enc:(fun r -> r.duplicate_detection) 7401 + |> Jsont.Object.mem "editor" QueueResponseLegacyDto.t_jsont ~enc:(fun r -> r.editor) 7402 + |> Jsont.Object.mem "faceDetection" QueueResponseLegacyDto.t_jsont ~enc:(fun r -> r.face_detection) 7403 + |> Jsont.Object.mem "facialRecognition" QueueResponseLegacyDto.t_jsont ~enc:(fun r -> r.facial_recognition) 7404 + |> Jsont.Object.mem "library" QueueResponseLegacyDto.t_jsont ~enc:(fun r -> r.library) 7405 + |> Jsont.Object.mem "metadataExtraction" QueueResponseLegacyDto.t_jsont ~enc:(fun r -> r.metadata_extraction) 7406 + |> Jsont.Object.mem "migration" QueueResponseLegacyDto.t_jsont ~enc:(fun r -> r.migration) 7407 + |> Jsont.Object.mem "notifications" QueueResponseLegacyDto.t_jsont ~enc:(fun r -> r.notifications) 7408 + |> Jsont.Object.mem "ocr" QueueResponseLegacyDto.t_jsont ~enc:(fun r -> r.ocr) 7409 + |> Jsont.Object.mem "search" QueueResponseLegacyDto.t_jsont ~enc:(fun r -> r.search) 7410 + |> Jsont.Object.mem "sidecar" QueueResponseLegacyDto.t_jsont ~enc:(fun r -> r.sidecar) 7411 + |> Jsont.Object.mem "smartSearch" QueueResponseLegacyDto.t_jsont ~enc:(fun r -> r.smart_search) 7412 + |> Jsont.Object.mem "storageTemplateMigration" QueueResponseLegacyDto.t_jsont ~enc:(fun r -> r.storage_template_migration) 7413 + |> Jsont.Object.mem "thumbnailGeneration" QueueResponseLegacyDto.t_jsont ~enc:(fun r -> r.thumbnail_generation) 7414 + |> Jsont.Object.mem "videoConversion" QueueResponseLegacyDto.t_jsont ~enc:(fun r -> r.video_conversion) 7415 + |> Jsont.Object.mem "workflow" QueueResponseLegacyDto.t_jsont ~enc:(fun r -> r.workflow) 7416 + |> Jsont.Object.skip_unknown 7417 + |> Jsont.Object.finish 7418 + end 7419 + 7420 + module PersonWithFacesResponseDto = struct 7421 + type t = { 7422 + birth_date : string; 7423 + color : string option; 7424 + faces : AssetFaceWithoutPersonResponseDto.t list; 7425 + id : string; 7426 + is_favorite : bool option; 7427 + is_hidden : bool; 7428 + name : string; 7429 + thumbnail_path : string; 7430 + updated_at : Ptime.t option; 7431 + } 7432 + 7433 + let t_jsont : t Jsont.t = 7434 + Jsont.Object.map ~kind:"t" 7435 + (fun birth_date color faces id is_favorite is_hidden name thumbnail_path updated_at -> { birth_date; color; faces; id; is_favorite; is_hidden; name; thumbnail_path; updated_at }) 7436 + |> Jsont.Object.mem "birthDate" Jsont.string ~enc:(fun r -> r.birth_date) 7437 + |> Jsont.Object.opt_mem "color" Jsont.string ~enc:(fun r -> r.color) 7438 + |> Jsont.Object.mem "faces" Jsont.(list AssetFaceWithoutPersonResponseDto.t_jsont) ~enc:(fun r -> r.faces) 7439 + |> Jsont.Object.mem "id" Jsont.string ~enc:(fun r -> r.id) 7440 + |> Jsont.Object.opt_mem "isFavorite" Jsont.bool ~enc:(fun r -> r.is_favorite) 7441 + |> Jsont.Object.mem "isHidden" Jsont.bool ~enc:(fun r -> r.is_hidden) 7442 + |> Jsont.Object.mem "name" Jsont.string ~enc:(fun r -> r.name) 7443 + |> Jsont.Object.mem "thumbnailPath" Jsont.string ~enc:(fun r -> r.thumbnail_path) 7444 + |> Jsont.Object.opt_mem "updatedAt" Openapi.Runtime.ptime_jsont ~enc:(fun r -> r.updated_at) 7445 + |> Jsont.Object.skip_unknown 7446 + |> Jsont.Object.finish 7447 + end 7448 + 7449 + module MaintenanceDetectInstallResponseDto = struct 7450 + type t = { 7451 + storage : MaintenanceDetectInstallStorageFolderDto.t list; 7452 + } 7453 + 7454 + let t_jsont : t Jsont.t = 7455 + Jsont.Object.map ~kind:"t" 7456 + (fun storage -> { storage }) 7457 + |> Jsont.Object.mem "storage" Jsont.(list MaintenanceDetectInstallStorageFolderDto.t_jsont) ~enc:(fun r -> r.storage) 7458 + |> Jsont.Object.skip_unknown 7459 + |> Jsont.Object.finish 7460 + end 7461 + 7462 + module SystemConfigNotificationsDto = struct 7463 + type t = { 7464 + smtp : SystemConfigSmtpDto.t; 7465 + } 7466 + 7467 + let t_jsont : t Jsont.t = 7468 + Jsont.Object.map ~kind:"t" 7469 + (fun smtp -> { smtp }) 7470 + |> Jsont.Object.mem "smtp" SystemConfigSmtpDto.t_jsont ~enc:(fun r -> r.smtp) 7471 + |> Jsont.Object.skip_unknown 7472 + |> Jsont.Object.finish 7473 + end 7474 + 7475 + module UserPreferencesUpdateDto = struct 7476 + type t = { 7477 + albums : AlbumsUpdate.t option; 7478 + avatar : AvatarUpdate.t option; 7479 + cast : CastUpdate.t option; 7480 + download : DownloadUpdate.t option; 7481 + email_notifications : EmailNotificationsUpdate.t option; 7482 + folders : FoldersUpdate.t option; 7483 + memories : MemoriesUpdate.t option; 7484 + people : PeopleUpdate.t option; 7485 + purchase : PurchaseUpdate.t option; 7486 + ratings : RatingsUpdate.t option; 7487 + shared_links : SharedLinksUpdate.t option; 7488 + tags : TagsUpdate.t option; 7489 + } 7490 + 7491 + let t_jsont : t Jsont.t = 7492 + Jsont.Object.map ~kind:"t" 7493 + (fun albums avatar cast download email_notifications folders memories people purchase ratings shared_links tags -> { albums; avatar; cast; download; email_notifications; folders; memories; people; purchase; ratings; shared_links; tags }) 7494 + |> Jsont.Object.opt_mem "albums" AlbumsUpdate.t_jsont ~enc:(fun r -> r.albums) 7495 + |> Jsont.Object.opt_mem "avatar" AvatarUpdate.t_jsont ~enc:(fun r -> r.avatar) 7496 + |> Jsont.Object.opt_mem "cast" CastUpdate.t_jsont ~enc:(fun r -> r.cast) 7497 + |> Jsont.Object.opt_mem "download" DownloadUpdate.t_jsont ~enc:(fun r -> r.download) 7498 + |> Jsont.Object.opt_mem "emailNotifications" EmailNotificationsUpdate.t_jsont ~enc:(fun r -> r.email_notifications) 7499 + |> Jsont.Object.opt_mem "folders" FoldersUpdate.t_jsont ~enc:(fun r -> r.folders) 7500 + |> Jsont.Object.opt_mem "memories" MemoriesUpdate.t_jsont ~enc:(fun r -> r.memories) 7501 + |> Jsont.Object.opt_mem "people" PeopleUpdate.t_jsont ~enc:(fun r -> r.people) 7502 + |> Jsont.Object.opt_mem "purchase" PurchaseUpdate.t_jsont ~enc:(fun r -> r.purchase) 7503 + |> Jsont.Object.opt_mem "ratings" RatingsUpdate.t_jsont ~enc:(fun r -> r.ratings) 7504 + |> Jsont.Object.opt_mem "sharedLinks" SharedLinksUpdate.t_jsont ~enc:(fun r -> r.shared_links) 7505 + |> Jsont.Object.opt_mem "tags" TagsUpdate.t_jsont ~enc:(fun r -> r.tags) 7506 + |> Jsont.Object.skip_unknown 7507 + |> Jsont.Object.finish 7508 + end 7509 + 7510 + module ActivityResponseDto = struct 7511 + type t = { 7512 + asset_id : string; 7513 + comment : string option; 7514 + created_at : Ptime.t; 7515 + id : string; 7516 + type_ : Jsont.json; 7517 + user : UserResponseDto.t; 7518 + } 7519 + 7520 + let t_jsont : t Jsont.t = 7521 + Jsont.Object.map ~kind:"t" 7522 + (fun asset_id comment created_at id type_ user -> { asset_id; comment; created_at; id; type_; user }) 7523 + |> Jsont.Object.mem "assetId" Jsont.string ~enc:(fun r -> r.asset_id) 7524 + |> Jsont.Object.opt_mem "comment" Jsont.string ~enc:(fun r -> r.comment) 7525 + |> Jsont.Object.mem "createdAt" Openapi.Runtime.ptime_jsont ~enc:(fun r -> r.created_at) 7526 + |> Jsont.Object.mem "id" Jsont.string ~enc:(fun r -> r.id) 7527 + |> Jsont.Object.mem "type" Jsont.json ~enc:(fun r -> r.type_) 7528 + |> Jsont.Object.mem "user" UserResponseDto.t_jsont ~enc:(fun r -> r.user) 7529 + |> Jsont.Object.skip_unknown 7530 + |> Jsont.Object.finish 7531 + end 7532 + 7533 + module AlbumUserResponseDto = struct 7534 + type t = { 7535 + role : Jsont.json; 7536 + user : UserResponseDto.t; 7537 + } 7538 + 7539 + let t_jsont : t Jsont.t = 7540 + Jsont.Object.map ~kind:"t" 7541 + (fun role user -> { role; user }) 7542 + |> Jsont.Object.mem "role" Jsont.json ~enc:(fun r -> r.role) 7543 + |> Jsont.Object.mem "user" UserResponseDto.t_jsont ~enc:(fun r -> r.user) 7544 + |> Jsont.Object.skip_unknown 7545 + |> Jsont.Object.finish 7546 + end 7547 + 7548 + module AssetEditActionListDto = struct 7549 + type t = { 7550 + edits : Jsont.json list; (** list of edits *) 7551 + } 7552 + 7553 + let t_jsont : t Jsont.t = 7554 + Jsont.Object.map ~kind:"t" 7555 + (fun edits -> { edits }) 7556 + |> Jsont.Object.mem "edits" Jsont.(list Jsont.json) ~enc:(fun r -> r.edits) 7557 + |> Jsont.Object.skip_unknown 7558 + |> Jsont.Object.finish 7559 + end 7560 + 7561 + module AssetEditsDto = struct 7562 + type t = { 7563 + asset_id : string; 7564 + edits : Jsont.json list; (** list of edits *) 7565 + } 7566 + 7567 + let t_jsont : t Jsont.t = 7568 + Jsont.Object.map ~kind:"t" 7569 + (fun asset_id edits -> { asset_id; edits }) 7570 + |> Jsont.Object.mem "assetId" Jsont.string ~enc:(fun r -> r.asset_id) 7571 + |> Jsont.Object.mem "edits" Jsont.(list Jsont.json) ~enc:(fun r -> r.edits) 7572 + |> Jsont.Object.skip_unknown 7573 + |> Jsont.Object.finish 7574 + end 7575 + 7576 + module AssetResponseDto = struct 7577 + type t = { 7578 + checksum : string; (** base64 encoded sha1 hash *) 7579 + created_at : Ptime.t; (** The UTC timestamp when the asset was originally uploaded to Immich. *) 7580 + device_asset_id : string; 7581 + device_id : string; 7582 + duplicate_id : string option; 7583 + duration : string; 7584 + exif_info : ExifResponseDto.t option; 7585 + file_created_at : Ptime.t; (** The actual UTC timestamp when the file was created/captured, preserving timezone information. This is the authoritative timestamp for chronological sorting within timeline groups. Combined with timezone data, this can be used to determine the exact moment the photo was taken. *) 7586 + file_modified_at : Ptime.t; (** The UTC timestamp when the file was last modified on the filesystem. This reflects the last time the physical file was changed, which may be different from when the photo was originally taken. *) 7587 + has_metadata : bool; 7588 + height : float; 7589 + id : string; 7590 + is_archived : bool; 7591 + is_edited : bool; 7592 + is_favorite : bool; 7593 + is_offline : bool; 7594 + is_trashed : bool; 7595 + library_id : string option; 7596 + live_photo_video_id : string option; 7597 + local_date_time : Ptime.t; (** The local date and time when the photo/video was taken, derived from EXIF metadata. This represents the photographer's local time regardless of timezone, stored as a timezone-agnostic timestamp. Used for timeline grouping by "local" days and months. *) 7598 + original_file_name : string; 7599 + original_mime_type : string option; 7600 + original_path : string; 7601 + owner : UserResponseDto.t option; 7602 + owner_id : string; 7603 + people : PersonWithFacesResponseDto.t list option; 7604 + resized : bool option; 7605 + stack : Jsont.json option; 7606 + tags : TagResponseDto.t list option; 7607 + thumbhash : string; 7608 + type_ : Jsont.json; 7609 + unassigned_faces : AssetFaceWithoutPersonResponseDto.t list option; 7610 + updated_at : Ptime.t; (** The UTC timestamp when the asset record was last updated in the database. This is automatically maintained by the database and reflects when any field in the asset was last modified. *) 7611 + visibility : Jsont.json; 7612 + width : float; 7613 + } 7614 + 7615 + let t_jsont : t Jsont.t = 7616 + Jsont.Object.map ~kind:"t" 7617 + (fun checksum created_at device_asset_id device_id duplicate_id duration exif_info file_created_at file_modified_at has_metadata height id is_archived is_edited is_favorite is_offline is_trashed library_id live_photo_video_id local_date_time original_file_name original_mime_type original_path owner owner_id people resized stack tags thumbhash type_ unassigned_faces updated_at visibility width -> { checksum; created_at; device_asset_id; device_id; duplicate_id; duration; exif_info; file_created_at; file_modified_at; has_metadata; height; id; is_archived; is_edited; is_favorite; is_offline; is_trashed; library_id; live_photo_video_id; local_date_time; original_file_name; original_mime_type; original_path; owner; owner_id; people; resized; stack; tags; thumbhash; type_; unassigned_faces; updated_at; visibility; width }) 7618 + |> Jsont.Object.mem "checksum" Jsont.string ~enc:(fun r -> r.checksum) 7619 + |> Jsont.Object.mem "createdAt" Openapi.Runtime.ptime_jsont ~enc:(fun r -> r.created_at) 7620 + |> Jsont.Object.mem "deviceAssetId" Jsont.string ~enc:(fun r -> r.device_asset_id) 7621 + |> Jsont.Object.mem "deviceId" Jsont.string ~enc:(fun r -> r.device_id) 7622 + |> Jsont.Object.opt_mem "duplicateId" Jsont.string ~enc:(fun r -> r.duplicate_id) 7623 + |> Jsont.Object.mem "duration" Jsont.string ~enc:(fun r -> r.duration) 7624 + |> Jsont.Object.opt_mem "exifInfo" ExifResponseDto.t_jsont ~enc:(fun r -> r.exif_info) 7625 + |> Jsont.Object.mem "fileCreatedAt" Openapi.Runtime.ptime_jsont ~enc:(fun r -> r.file_created_at) 7626 + |> Jsont.Object.mem "fileModifiedAt" Openapi.Runtime.ptime_jsont ~enc:(fun r -> r.file_modified_at) 7627 + |> Jsont.Object.mem "hasMetadata" Jsont.bool ~enc:(fun r -> r.has_metadata) 7628 + |> Jsont.Object.mem "height" Jsont.number ~enc:(fun r -> r.height) 7629 + |> Jsont.Object.mem "id" Jsont.string ~enc:(fun r -> r.id) 7630 + |> Jsont.Object.mem "isArchived" Jsont.bool ~enc:(fun r -> r.is_archived) 7631 + |> Jsont.Object.mem "isEdited" Jsont.bool ~enc:(fun r -> r.is_edited) 7632 + |> Jsont.Object.mem "isFavorite" Jsont.bool ~enc:(fun r -> r.is_favorite) 7633 + |> Jsont.Object.mem "isOffline" Jsont.bool ~enc:(fun r -> r.is_offline) 7634 + |> Jsont.Object.mem "isTrashed" Jsont.bool ~enc:(fun r -> r.is_trashed) 7635 + |> Jsont.Object.opt_mem "libraryId" Jsont.string ~enc:(fun r -> r.library_id) 7636 + |> Jsont.Object.opt_mem "livePhotoVideoId" Jsont.string ~enc:(fun r -> r.live_photo_video_id) 7637 + |> Jsont.Object.mem "localDateTime" Openapi.Runtime.ptime_jsont ~enc:(fun r -> r.local_date_time) 7638 + |> Jsont.Object.mem "originalFileName" Jsont.string ~enc:(fun r -> r.original_file_name) 7639 + |> Jsont.Object.opt_mem "originalMimeType" Jsont.string ~enc:(fun r -> r.original_mime_type) 7640 + |> Jsont.Object.mem "originalPath" Jsont.string ~enc:(fun r -> r.original_path) 7641 + |> Jsont.Object.opt_mem "owner" UserResponseDto.t_jsont ~enc:(fun r -> r.owner) 7642 + |> Jsont.Object.mem "ownerId" Jsont.string ~enc:(fun r -> r.owner_id) 7643 + |> Jsont.Object.opt_mem "people" Jsont.(list PersonWithFacesResponseDto.t_jsont) ~enc:(fun r -> r.people) 7644 + |> Jsont.Object.opt_mem "resized" Jsont.bool ~enc:(fun r -> r.resized) 7645 + |> Jsont.Object.opt_mem "stack" Jsont.json ~enc:(fun r -> r.stack) 7646 + |> Jsont.Object.opt_mem "tags" Jsont.(list TagResponseDto.t_jsont) ~enc:(fun r -> r.tags) 7647 + |> Jsont.Object.mem "thumbhash" Jsont.string ~enc:(fun r -> r.thumbhash) 7648 + |> Jsont.Object.mem "type" Jsont.json ~enc:(fun r -> r.type_) 7649 + |> Jsont.Object.opt_mem "unassignedFaces" Jsont.(list AssetFaceWithoutPersonResponseDto.t_jsont) ~enc:(fun r -> r.unassigned_faces) 7650 + |> Jsont.Object.mem "updatedAt" Openapi.Runtime.ptime_jsont ~enc:(fun r -> r.updated_at) 7651 + |> Jsont.Object.mem "visibility" Jsont.json ~enc:(fun r -> r.visibility) 7652 + |> Jsont.Object.mem "width" Jsont.number ~enc:(fun r -> r.width) 7653 + |> Jsont.Object.skip_unknown 7654 + |> Jsont.Object.finish 7655 + end 7656 + 7657 + module SystemConfigDto = struct 7658 + type t = { 7659 + backup : SystemConfigBackupsDto.t; 7660 + ffmpeg : SystemConfigFfmpegDto.t; 7661 + image : SystemConfigImageDto.t; 7662 + job : SystemConfigJobDto.t; 7663 + library : SystemConfigLibraryDto.t; 7664 + logging : SystemConfigLoggingDto.t; 7665 + machine_learning : SystemConfigMachineLearningDto.t; 7666 + map : SystemConfigMapDto.t; 7667 + metadata : SystemConfigMetadataDto.t; 7668 + new_version_check : SystemConfigNewVersionCheckDto.t; 7669 + nightly_tasks : SystemConfigNightlyTasksDto.t; 7670 + notifications : SystemConfigNotificationsDto.t; 7671 + oauth : SystemConfigOauthDto.t; 7672 + password_login : SystemConfigPasswordLoginDto.t; 7673 + reverse_geocoding : SystemConfigReverseGeocodingDto.t; 7674 + server : SystemConfigServerDto.t; 7675 + storage_template : SystemConfigStorageTemplateDto.t; 7676 + templates : SystemConfigTemplatesDto.t; 7677 + theme : SystemConfigThemeDto.t; 7678 + trash : SystemConfigTrashDto.t; 7679 + user : SystemConfigUserDto.t; 7680 + } 7681 + 7682 + let t_jsont : t Jsont.t = 7683 + Jsont.Object.map ~kind:"t" 7684 + (fun backup ffmpeg image job library logging machine_learning map metadata new_version_check nightly_tasks notifications oauth password_login reverse_geocoding server storage_template templates theme trash user -> { backup; ffmpeg; image; job; library; logging; machine_learning; map; metadata; new_version_check; nightly_tasks; notifications; oauth; password_login; reverse_geocoding; server; storage_template; templates; theme; trash; user }) 7685 + |> Jsont.Object.mem "backup" SystemConfigBackupsDto.t_jsont ~enc:(fun r -> r.backup) 7686 + |> Jsont.Object.mem "ffmpeg" SystemConfigFfmpegDto.t_jsont ~enc:(fun r -> r.ffmpeg) 7687 + |> Jsont.Object.mem "image" SystemConfigImageDto.t_jsont ~enc:(fun r -> r.image) 7688 + |> Jsont.Object.mem "job" SystemConfigJobDto.t_jsont ~enc:(fun r -> r.job) 7689 + |> Jsont.Object.mem "library" SystemConfigLibraryDto.t_jsont ~enc:(fun r -> r.library) 7690 + |> Jsont.Object.mem "logging" SystemConfigLoggingDto.t_jsont ~enc:(fun r -> r.logging) 7691 + |> Jsont.Object.mem "machineLearning" SystemConfigMachineLearningDto.t_jsont ~enc:(fun r -> r.machine_learning) 7692 + |> Jsont.Object.mem "map" SystemConfigMapDto.t_jsont ~enc:(fun r -> r.map) 7693 + |> Jsont.Object.mem "metadata" SystemConfigMetadataDto.t_jsont ~enc:(fun r -> r.metadata) 7694 + |> Jsont.Object.mem "newVersionCheck" SystemConfigNewVersionCheckDto.t_jsont ~enc:(fun r -> r.new_version_check) 7695 + |> Jsont.Object.mem "nightlyTasks" SystemConfigNightlyTasksDto.t_jsont ~enc:(fun r -> r.nightly_tasks) 7696 + |> Jsont.Object.mem "notifications" SystemConfigNotificationsDto.t_jsont ~enc:(fun r -> r.notifications) 7697 + |> Jsont.Object.mem "oauth" SystemConfigOauthDto.t_jsont ~enc:(fun r -> r.oauth) 7698 + |> Jsont.Object.mem "passwordLogin" SystemConfigPasswordLoginDto.t_jsont ~enc:(fun r -> r.password_login) 7699 + |> Jsont.Object.mem "reverseGeocoding" SystemConfigReverseGeocodingDto.t_jsont ~enc:(fun r -> r.reverse_geocoding) 7700 + |> Jsont.Object.mem "server" SystemConfigServerDto.t_jsont ~enc:(fun r -> r.server) 7701 + |> Jsont.Object.mem "storageTemplate" SystemConfigStorageTemplateDto.t_jsont ~enc:(fun r -> r.storage_template) 7702 + |> Jsont.Object.mem "templates" SystemConfigTemplatesDto.t_jsont ~enc:(fun r -> r.templates) 7703 + |> Jsont.Object.mem "theme" SystemConfigThemeDto.t_jsont ~enc:(fun r -> r.theme) 7704 + |> Jsont.Object.mem "trash" SystemConfigTrashDto.t_jsont ~enc:(fun r -> r.trash) 7705 + |> Jsont.Object.mem "user" SystemConfigUserDto.t_jsont ~enc:(fun r -> r.user) 7706 + |> Jsont.Object.skip_unknown 7707 + |> Jsont.Object.finish 7708 + end 7709 + 7710 + module AlbumResponseDto = struct 7711 + type t = { 7712 + album_name : string; 7713 + album_thumbnail_asset_id : string; 7714 + album_users : AlbumUserResponseDto.t list; 7715 + asset_count : int; 7716 + assets : AssetResponseDto.t list; 7717 + contributor_counts : ContributorCountResponseDto.t list option; 7718 + created_at : Ptime.t; 7719 + description : string; 7720 + end_date : Ptime.t option; 7721 + has_shared_link : bool; 7722 + id : string; 7723 + is_activity_enabled : bool; 7724 + last_modified_asset_timestamp : Ptime.t option; 7725 + order : Jsont.json option; 7726 + owner : UserResponseDto.t; 7727 + owner_id : string; 7728 + shared : bool; 7729 + start_date : Ptime.t option; 7730 + updated_at : Ptime.t; 7731 + } 7732 + 7733 + let t_jsont : t Jsont.t = 7734 + Jsont.Object.map ~kind:"t" 7735 + (fun album_name album_thumbnail_asset_id album_users asset_count assets contributor_counts created_at description end_date has_shared_link id is_activity_enabled last_modified_asset_timestamp order owner owner_id shared start_date updated_at -> { album_name; album_thumbnail_asset_id; album_users; asset_count; assets; contributor_counts; created_at; description; end_date; has_shared_link; id; is_activity_enabled; last_modified_asset_timestamp; order; owner; owner_id; shared; start_date; updated_at }) 7736 + |> Jsont.Object.mem "albumName" Jsont.string ~enc:(fun r -> r.album_name) 7737 + |> Jsont.Object.mem "albumThumbnailAssetId" Jsont.string ~enc:(fun r -> r.album_thumbnail_asset_id) 7738 + |> Jsont.Object.mem "albumUsers" Jsont.(list AlbumUserResponseDto.t_jsont) ~enc:(fun r -> r.album_users) 7739 + |> Jsont.Object.mem "assetCount" Jsont.int ~enc:(fun r -> r.asset_count) 7740 + |> Jsont.Object.mem "assets" Jsont.(list AssetResponseDto.t_jsont) ~enc:(fun r -> r.assets) 7741 + |> Jsont.Object.opt_mem "contributorCounts" Jsont.(list ContributorCountResponseDto.t_jsont) ~enc:(fun r -> r.contributor_counts) 7742 + |> Jsont.Object.mem "createdAt" Openapi.Runtime.ptime_jsont ~enc:(fun r -> r.created_at) 7743 + |> Jsont.Object.mem "description" Jsont.string ~enc:(fun r -> r.description) 7744 + |> Jsont.Object.opt_mem "endDate" Openapi.Runtime.ptime_jsont ~enc:(fun r -> r.end_date) 7745 + |> Jsont.Object.mem "hasSharedLink" Jsont.bool ~enc:(fun r -> r.has_shared_link) 7746 + |> Jsont.Object.mem "id" Jsont.string ~enc:(fun r -> r.id) 7747 + |> Jsont.Object.mem "isActivityEnabled" Jsont.bool ~enc:(fun r -> r.is_activity_enabled) 7748 + |> Jsont.Object.opt_mem "lastModifiedAssetTimestamp" Openapi.Runtime.ptime_jsont ~enc:(fun r -> r.last_modified_asset_timestamp) 7749 + |> Jsont.Object.opt_mem "order" Jsont.json ~enc:(fun r -> r.order) 7750 + |> Jsont.Object.mem "owner" UserResponseDto.t_jsont ~enc:(fun r -> r.owner) 7751 + |> Jsont.Object.mem "ownerId" Jsont.string ~enc:(fun r -> r.owner_id) 7752 + |> Jsont.Object.mem "shared" Jsont.bool ~enc:(fun r -> r.shared) 7753 + |> Jsont.Object.opt_mem "startDate" Openapi.Runtime.ptime_jsont ~enc:(fun r -> r.start_date) 7754 + |> Jsont.Object.mem "updatedAt" Openapi.Runtime.ptime_jsont ~enc:(fun r -> r.updated_at) 7755 + |> Jsont.Object.skip_unknown 7756 + |> Jsont.Object.finish 7757 + end 7758 + 7759 + module AssetDeltaSyncResponseDto = struct 7760 + type t = { 7761 + deleted : string list; 7762 + needs_full_sync : bool; 7763 + upserted : AssetResponseDto.t list; 7764 + } 7765 + 7766 + let t_jsont : t Jsont.t = 7767 + Jsont.Object.map ~kind:"t" 7768 + (fun deleted needs_full_sync upserted -> { deleted; needs_full_sync; upserted }) 7769 + |> Jsont.Object.mem "deleted" Jsont.(list Jsont.string) ~enc:(fun r -> r.deleted) 7770 + |> Jsont.Object.mem "needsFullSync" Jsont.bool ~enc:(fun r -> r.needs_full_sync) 7771 + |> Jsont.Object.mem "upserted" Jsont.(list AssetResponseDto.t_jsont) ~enc:(fun r -> r.upserted) 7772 + |> Jsont.Object.skip_unknown 7773 + |> Jsont.Object.finish 7774 + end 7775 + 7776 + module DuplicateResponseDto = struct 7777 + type t = { 7778 + assets : AssetResponseDto.t list; 7779 + duplicate_id : string; 7780 + } 7781 + 7782 + let t_jsont : t Jsont.t = 7783 + Jsont.Object.map ~kind:"t" 7784 + (fun assets duplicate_id -> { assets; duplicate_id }) 7785 + |> Jsont.Object.mem "assets" Jsont.(list AssetResponseDto.t_jsont) ~enc:(fun r -> r.assets) 7786 + |> Jsont.Object.mem "duplicateId" Jsont.string ~enc:(fun r -> r.duplicate_id) 7787 + |> Jsont.Object.skip_unknown 7788 + |> Jsont.Object.finish 7789 + end 7790 + 7791 + module MemoryResponseDto = struct 7792 + type t = { 7793 + assets : AssetResponseDto.t list; 7794 + created_at : Ptime.t; 7795 + data : OnThisDayDto.t; 7796 + deleted_at : Ptime.t option; 7797 + hide_at : Ptime.t option; 7798 + id : string; 7799 + is_saved : bool; 7800 + memory_at : Ptime.t; 7801 + owner_id : string; 7802 + seen_at : Ptime.t option; 7803 + show_at : Ptime.t option; 7804 + type_ : Jsont.json; 7805 + updated_at : Ptime.t; 7806 + } 7807 + 7808 + let t_jsont : t Jsont.t = 7809 + Jsont.Object.map ~kind:"t" 7810 + (fun assets created_at data deleted_at hide_at id is_saved memory_at owner_id seen_at show_at type_ updated_at -> { assets; created_at; data; deleted_at; hide_at; id; is_saved; memory_at; owner_id; seen_at; show_at; type_; updated_at }) 7811 + |> Jsont.Object.mem "assets" Jsont.(list AssetResponseDto.t_jsont) ~enc:(fun r -> r.assets) 7812 + |> Jsont.Object.mem "createdAt" Openapi.Runtime.ptime_jsont ~enc:(fun r -> r.created_at) 7813 + |> Jsont.Object.mem "data" OnThisDayDto.t_jsont ~enc:(fun r -> r.data) 7814 + |> Jsont.Object.opt_mem "deletedAt" Openapi.Runtime.ptime_jsont ~enc:(fun r -> r.deleted_at) 7815 + |> Jsont.Object.opt_mem "hideAt" Openapi.Runtime.ptime_jsont ~enc:(fun r -> r.hide_at) 7816 + |> Jsont.Object.mem "id" Jsont.string ~enc:(fun r -> r.id) 7817 + |> Jsont.Object.mem "isSaved" Jsont.bool ~enc:(fun r -> r.is_saved) 7818 + |> Jsont.Object.mem "memoryAt" Openapi.Runtime.ptime_jsont ~enc:(fun r -> r.memory_at) 7819 + |> Jsont.Object.mem "ownerId" Jsont.string ~enc:(fun r -> r.owner_id) 7820 + |> Jsont.Object.opt_mem "seenAt" Openapi.Runtime.ptime_jsont ~enc:(fun r -> r.seen_at) 7821 + |> Jsont.Object.opt_mem "showAt" Openapi.Runtime.ptime_jsont ~enc:(fun r -> r.show_at) 7822 + |> Jsont.Object.mem "type" Jsont.json ~enc:(fun r -> r.type_) 7823 + |> Jsont.Object.mem "updatedAt" Openapi.Runtime.ptime_jsont ~enc:(fun r -> r.updated_at) 7824 + |> Jsont.Object.skip_unknown 7825 + |> Jsont.Object.finish 7826 + end 7827 + 7828 + module SearchAssetResponseDto = struct 7829 + type t = { 7830 + count : int; 7831 + facets : SearchFacetResponseDto.t list; 7832 + items : AssetResponseDto.t list; 7833 + next_page : string; 7834 + total : int; 7835 + } 7836 + 7837 + let t_jsont : t Jsont.t = 7838 + Jsont.Object.map ~kind:"t" 7839 + (fun count facets items next_page total -> { count; facets; items; next_page; total }) 7840 + |> Jsont.Object.mem "count" Jsont.int ~enc:(fun r -> r.count) 7841 + |> Jsont.Object.mem "facets" Jsont.(list SearchFacetResponseDto.t_jsont) ~enc:(fun r -> r.facets) 7842 + |> Jsont.Object.mem "items" Jsont.(list AssetResponseDto.t_jsont) ~enc:(fun r -> r.items) 7843 + |> Jsont.Object.mem "nextPage" Jsont.string ~enc:(fun r -> r.next_page) 7844 + |> Jsont.Object.mem "total" Jsont.int ~enc:(fun r -> r.total) 7845 + |> Jsont.Object.skip_unknown 7846 + |> Jsont.Object.finish 7847 + end 7848 + 7849 + module SearchExploreItem = struct 7850 + type t = { 7851 + data : AssetResponseDto.t; 7852 + value : string; 7853 + } 7854 + 7855 + let t_jsont : t Jsont.t = 7856 + Jsont.Object.map ~kind:"t" 7857 + (fun data value -> { data; value }) 7858 + |> Jsont.Object.mem "data" AssetResponseDto.t_jsont ~enc:(fun r -> r.data) 7859 + |> Jsont.Object.mem "value" Jsont.string ~enc:(fun r -> r.value) 7860 + |> Jsont.Object.skip_unknown 7861 + |> Jsont.Object.finish 7862 + end 7863 + 7864 + module StackResponseDto = struct 7865 + type t = { 7866 + assets : AssetResponseDto.t list; 7867 + id : string; 7868 + primary_asset_id : string; 7869 + } 7870 + 7871 + let t_jsont : t Jsont.t = 7872 + Jsont.Object.map ~kind:"t" 7873 + (fun assets id primary_asset_id -> { assets; id; primary_asset_id }) 7874 + |> Jsont.Object.mem "assets" Jsont.(list AssetResponseDto.t_jsont) ~enc:(fun r -> r.assets) 7875 + |> Jsont.Object.mem "id" Jsont.string ~enc:(fun r -> r.id) 7876 + |> Jsont.Object.mem "primaryAssetId" Jsont.string ~enc:(fun r -> r.primary_asset_id) 7877 + |> Jsont.Object.skip_unknown 7878 + |> Jsont.Object.finish 7879 + end 7880 + 7881 + module SearchAlbumResponseDto = struct 7882 + type t = { 7883 + count : int; 7884 + facets : SearchFacetResponseDto.t list; 7885 + items : AlbumResponseDto.t list; 7886 + total : int; 7887 + } 7888 + 7889 + let t_jsont : t Jsont.t = 7890 + Jsont.Object.map ~kind:"t" 7891 + (fun count facets items total -> { count; facets; items; total }) 7892 + |> Jsont.Object.mem "count" Jsont.int ~enc:(fun r -> r.count) 7893 + |> Jsont.Object.mem "facets" Jsont.(list SearchFacetResponseDto.t_jsont) ~enc:(fun r -> r.facets) 7894 + |> Jsont.Object.mem "items" Jsont.(list AlbumResponseDto.t_jsont) ~enc:(fun r -> r.items) 7895 + |> Jsont.Object.mem "total" Jsont.int ~enc:(fun r -> r.total) 7896 + |> Jsont.Object.skip_unknown 7897 + |> Jsont.Object.finish 7898 + end 7899 + 7900 + module SharedLinkResponseDto = struct 7901 + type t = { 7902 + album : AlbumResponseDto.t option; 7903 + allow_download : bool; 7904 + allow_upload : bool; 7905 + assets : AssetResponseDto.t list; 7906 + created_at : Ptime.t; 7907 + description : string; 7908 + expires_at : Ptime.t; 7909 + id : string; 7910 + key : string; 7911 + password : string; 7912 + show_metadata : bool; 7913 + slug : string; 7914 + token : string option; 7915 + type_ : Jsont.json; 7916 + user_id : string; 7917 + } 7918 + 7919 + let t_jsont : t Jsont.t = 7920 + Jsont.Object.map ~kind:"t" 7921 + (fun album allow_download allow_upload assets created_at description expires_at id key password show_metadata slug token type_ user_id -> { album; allow_download; allow_upload; assets; created_at; description; expires_at; id; key; password; show_metadata; slug; token; type_; user_id }) 7922 + |> Jsont.Object.opt_mem "album" AlbumResponseDto.t_jsont ~enc:(fun r -> r.album) 7923 + |> Jsont.Object.mem "allowDownload" Jsont.bool ~enc:(fun r -> r.allow_download) 7924 + |> Jsont.Object.mem "allowUpload" Jsont.bool ~enc:(fun r -> r.allow_upload) 7925 + |> Jsont.Object.mem "assets" Jsont.(list AssetResponseDto.t_jsont) ~enc:(fun r -> r.assets) 7926 + |> Jsont.Object.mem "createdAt" Openapi.Runtime.ptime_jsont ~enc:(fun r -> r.created_at) 7927 + |> Jsont.Object.mem "description" Jsont.string ~enc:(fun r -> r.description) 7928 + |> Jsont.Object.mem "expiresAt" Openapi.Runtime.ptime_jsont ~enc:(fun r -> r.expires_at) 7929 + |> Jsont.Object.mem "id" Jsont.string ~enc:(fun r -> r.id) 7930 + |> Jsont.Object.mem "key" Jsont.string ~enc:(fun r -> r.key) 7931 + |> Jsont.Object.mem "password" Jsont.string ~enc:(fun r -> r.password) 7932 + |> Jsont.Object.mem "showMetadata" Jsont.bool ~enc:(fun r -> r.show_metadata) 7933 + |> Jsont.Object.mem "slug" Jsont.string ~enc:(fun r -> r.slug) 7934 + |> Jsont.Object.opt_mem "token" Jsont.string ~enc:(fun r -> r.token) 7935 + |> Jsont.Object.mem "type" Jsont.json ~enc:(fun r -> r.type_) 7936 + |> Jsont.Object.mem "userId" Jsont.string ~enc:(fun r -> r.user_id) 7937 + |> Jsont.Object.skip_unknown 7938 + |> Jsont.Object.finish 7939 + end 7940 + 7941 + module SearchExploreResponseDto = struct 7942 + type t = { 7943 + field_name : string; 7944 + items : SearchExploreItem.t list; 7945 + } 7946 + 7947 + let t_jsont : t Jsont.t = 7948 + Jsont.Object.map ~kind:"t" 7949 + (fun field_name items -> { field_name; items }) 7950 + |> Jsont.Object.mem "fieldName" Jsont.string ~enc:(fun r -> r.field_name) 7951 + |> Jsont.Object.mem "items" Jsont.(list SearchExploreItem.t_jsont) ~enc:(fun r -> r.items) 7952 + |> Jsont.Object.skip_unknown 7953 + |> Jsont.Object.finish 7954 + end 7955 + 7956 + module SearchResponseDto = struct 7957 + type t = { 7958 + albums : SearchAlbumResponseDto.t; 7959 + assets : SearchAssetResponseDto.t; 7960 + } 7961 + 7962 + let t_jsont : t Jsont.t = 7963 + Jsont.Object.map ~kind:"t" 7964 + (fun albums assets -> { albums; assets }) 7965 + |> Jsont.Object.mem "albums" SearchAlbumResponseDto.t_jsont ~enc:(fun r -> r.albums) 7966 + |> Jsont.Object.mem "assets" SearchAssetResponseDto.t_jsont ~enc:(fun r -> r.assets) 7967 + |> Jsont.Object.skip_unknown 7968 + |> Jsont.Object.finish 7969 + end
+4275
ocaml-immich/types.mli
··· 1 + (** Immich API 2 + 3 + @version 2.4.1 *) 4 + 5 + module ActivityStatisticsResponseDto : sig 6 + type t = { 7 + comments : int; 8 + likes : int; 9 + } 10 + 11 + val t_jsont : t Jsont.t 12 + end 13 + 14 + module AdminOnboardingUpdateDto : sig 15 + type t = { 16 + is_onboarded : bool; 17 + } 18 + 19 + val t_jsont : t Jsont.t 20 + end 21 + 22 + module AlbumStatisticsResponseDto : sig 23 + type t = { 24 + not_shared : int; 25 + owned : int; 26 + shared : int; 27 + } 28 + 29 + val t_jsont : t Jsont.t 30 + end 31 + 32 + module AlbumUserRole : sig 33 + type t = 34 + | Editor 35 + | Viewer 36 + 37 + val t_jsont : t Jsont.t 38 + end 39 + 40 + module AlbumsAddAssetsDto : sig 41 + type t = { 42 + album_ids : string list; 43 + asset_ids : string list; 44 + } 45 + 46 + val t_jsont : t Jsont.t 47 + end 48 + 49 + module AssetBulkDeleteDto : sig 50 + type t = { 51 + force : bool option; 52 + ids : string list; 53 + } 54 + 55 + val t_jsont : t Jsont.t 56 + end 57 + 58 + module AssetBulkUploadCheckItem : sig 59 + type t = { 60 + checksum : string; (** base64 or hex encoded sha1 hash *) 61 + id : string; 62 + } 63 + 64 + val t_jsont : t Jsont.t 65 + end 66 + 67 + module AssetBulkUploadCheckResult : sig 68 + type t = { 69 + action : string; 70 + asset_id : string option; 71 + id : string; 72 + is_trashed : bool option; 73 + reason : string option; 74 + } 75 + 76 + val t_jsont : t Jsont.t 77 + end 78 + 79 + module AssetCopyDto : sig 80 + type t = { 81 + albums : bool option; 82 + favorite : bool option; 83 + shared_links : bool option; 84 + sidecar : bool option; 85 + source_id : string; 86 + stack : bool option; 87 + target_id : string; 88 + } 89 + 90 + val t_jsont : t Jsont.t 91 + end 92 + 93 + module AssetDeltaSyncDto : sig 94 + type t = { 95 + updated_after : Ptime.t; 96 + user_ids : string list; 97 + } 98 + 99 + val t_jsont : t Jsont.t 100 + end 101 + 102 + module AssetEditAction : sig 103 + type t = 104 + | Crop 105 + | Rotate 106 + | Mirror 107 + 108 + val t_jsont : t Jsont.t 109 + end 110 + 111 + module AssetFaceCreateDto : sig 112 + type t = { 113 + asset_id : string; 114 + height : int; 115 + image_height : int; 116 + image_width : int; 117 + person_id : string; 118 + width : int; 119 + x : int; 120 + y : int; 121 + } 122 + 123 + val t_jsont : t Jsont.t 124 + end 125 + 126 + module AssetFaceDeleteDto : sig 127 + type t = { 128 + force : bool; 129 + } 130 + 131 + val t_jsont : t Jsont.t 132 + end 133 + 134 + module AssetFaceUpdateItem : sig 135 + type t = { 136 + asset_id : string; 137 + person_id : string; 138 + } 139 + 140 + val t_jsont : t Jsont.t 141 + end 142 + 143 + module AssetFullSyncDto : sig 144 + type t = { 145 + last_id : string option; 146 + limit : int; 147 + updated_until : Ptime.t; 148 + user_id : string option; 149 + } 150 + 151 + val t_jsont : t Jsont.t 152 + end 153 + 154 + module AssetIdsDto : sig 155 + type t = { 156 + asset_ids : string list; 157 + } 158 + 159 + val t_jsont : t Jsont.t 160 + end 161 + 162 + module AssetIdsResponseDto : sig 163 + type t = { 164 + asset_id : string; 165 + error : string option; 166 + success : bool; 167 + } 168 + 169 + val t_jsont : t Jsont.t 170 + end 171 + 172 + module AssetJobName : sig 173 + type t = 174 + | Refresh_faces 175 + | Refresh_metadata 176 + | Regenerate_thumbnail 177 + | Transcode_video 178 + 179 + val t_jsont : t Jsont.t 180 + end 181 + 182 + module AssetMediaReplaceDto : sig 183 + type t = { 184 + asset_data : string; 185 + device_asset_id : string; 186 + device_id : string; 187 + duration : string option; 188 + file_created_at : Ptime.t; 189 + file_modified_at : Ptime.t; 190 + filename : string option; 191 + } 192 + 193 + val t_jsont : t Jsont.t 194 + end 195 + 196 + module AssetMediaSize : sig 197 + type t = 198 + | Original 199 + | Fullsize 200 + | Preview 201 + | Thumbnail 202 + 203 + val t_jsont : t Jsont.t 204 + end 205 + 206 + module AssetMediaStatus : sig 207 + type t = 208 + | Created 209 + | Replaced 210 + | Duplicate 211 + 212 + val t_jsont : t Jsont.t 213 + end 214 + 215 + module AssetMetadataBulkDeleteItemDto : sig 216 + type t = { 217 + asset_id : string; 218 + key : string; 219 + } 220 + 221 + val t_jsont : t Jsont.t 222 + end 223 + 224 + module AssetMetadataBulkResponseDto : sig 225 + type t = { 226 + asset_id : string; 227 + key : string; 228 + updated_at : Ptime.t; 229 + value : Jsont.json; 230 + } 231 + 232 + val t_jsont : t Jsont.t 233 + end 234 + 235 + module AssetMetadataBulkUpsertItemDto : sig 236 + type t = { 237 + asset_id : string; 238 + key : string; 239 + value : Jsont.json; 240 + } 241 + 242 + val t_jsont : t Jsont.t 243 + end 244 + 245 + module AssetMetadataResponseDto : sig 246 + type t = { 247 + key : string; 248 + updated_at : Ptime.t; 249 + value : Jsont.json; 250 + } 251 + 252 + val t_jsont : t Jsont.t 253 + end 254 + 255 + module AssetMetadataUpsertItemDto : sig 256 + type t = { 257 + key : string; 258 + value : Jsont.json; 259 + } 260 + 261 + val t_jsont : t Jsont.t 262 + end 263 + 264 + module AssetOcrResponseDto : sig 265 + type t = { 266 + asset_id : string; 267 + box_score : float; (** Confidence score for text detection box *) 268 + id : string; 269 + text : string; (** Recognized text *) 270 + text_score : float; (** Confidence score for text recognition *) 271 + x1 : float; (** Normalized x coordinate of box corner 1 (0-1) *) 272 + x2 : float; (** Normalized x coordinate of box corner 2 (0-1) *) 273 + x3 : float; (** Normalized x coordinate of box corner 3 (0-1) *) 274 + x4 : float; (** Normalized x coordinate of box corner 4 (0-1) *) 275 + y1 : float; (** Normalized y coordinate of box corner 1 (0-1) *) 276 + y2 : float; (** Normalized y coordinate of box corner 2 (0-1) *) 277 + y3 : float; (** Normalized y coordinate of box corner 3 (0-1) *) 278 + y4 : float; (** Normalized y coordinate of box corner 4 (0-1) *) 279 + } 280 + 281 + val t_jsont : t Jsont.t 282 + end 283 + 284 + module AssetOrder : sig 285 + type t = 286 + | Asc 287 + | Desc 288 + 289 + val t_jsont : t Jsont.t 290 + end 291 + 292 + module AssetStackResponseDto : sig 293 + type t = { 294 + asset_count : int; 295 + id : string; 296 + primary_asset_id : string; 297 + } 298 + 299 + val t_jsont : t Jsont.t 300 + end 301 + 302 + module AssetStatsResponseDto : sig 303 + type t = { 304 + images : int; 305 + total : int; 306 + videos : int; 307 + } 308 + 309 + val t_jsont : t Jsont.t 310 + end 311 + 312 + module AssetTypeEnum : sig 313 + type t = 314 + | Image 315 + | Video 316 + | Audio 317 + | Other 318 + 319 + val t_jsont : t Jsont.t 320 + end 321 + 322 + module AssetVisibility : sig 323 + type t = 324 + | Archive 325 + | Timeline 326 + | Hidden 327 + | Locked 328 + 329 + val t_jsont : t Jsont.t 330 + end 331 + 332 + module AudioCodec : sig 333 + type t = 334 + | Mp3 335 + | Aac 336 + | Libopus 337 + | Pcm_s16le 338 + 339 + val t_jsont : t Jsont.t 340 + end 341 + 342 + module AuthStatusResponseDto : sig 343 + type t = { 344 + expires_at : string option; 345 + is_elevated : bool; 346 + password : bool; 347 + pin_code : bool; 348 + pin_expires_at : string option; 349 + } 350 + 351 + val t_jsont : t Jsont.t 352 + end 353 + 354 + module BulkIdErrorReason : sig 355 + type t = 356 + | Duplicate 357 + | No_permission 358 + | Not_found 359 + | Unknown 360 + 361 + val t_jsont : t Jsont.t 362 + end 363 + 364 + module BulkIdResponseDto : sig 365 + type t = { 366 + error : string option; 367 + id : string; 368 + success : bool; 369 + } 370 + 371 + val t_jsont : t Jsont.t 372 + end 373 + 374 + module BulkIdsDto : sig 375 + type t = { 376 + ids : string list; 377 + } 378 + 379 + val t_jsont : t Jsont.t 380 + end 381 + 382 + module Clipconfig : sig 383 + type t = { 384 + enabled : bool; 385 + model_name : string; 386 + } 387 + 388 + val t_jsont : t Jsont.t 389 + end 390 + 391 + module Cqmode : sig 392 + type t = 393 + | Auto 394 + | Cqp 395 + | Icq 396 + 397 + val t_jsont : t Jsont.t 398 + end 399 + 400 + module CastResponse : sig 401 + type t = { 402 + g_cast_enabled : bool; 403 + } 404 + 405 + val t_jsont : t Jsont.t 406 + end 407 + 408 + module CastUpdate : sig 409 + type t = { 410 + g_cast_enabled : bool option; 411 + } 412 + 413 + val t_jsont : t Jsont.t 414 + end 415 + 416 + module ChangePasswordDto : sig 417 + type t = { 418 + invalidate_sessions : bool option; 419 + new_password : string; 420 + password : string; 421 + } 422 + 423 + val t_jsont : t Jsont.t 424 + end 425 + 426 + module CheckExistingAssetsDto : sig 427 + type t = { 428 + device_asset_ids : string list; 429 + device_id : string; 430 + } 431 + 432 + val t_jsont : t Jsont.t 433 + end 434 + 435 + module CheckExistingAssetsResponseDto : sig 436 + type t = { 437 + existing_ids : string list; 438 + } 439 + 440 + val t_jsont : t Jsont.t 441 + end 442 + 443 + module Colorspace : sig 444 + type t = 445 + | Srgb 446 + | P3 447 + 448 + val t_jsont : t Jsont.t 449 + end 450 + 451 + module ContributorCountResponseDto : sig 452 + type t = { 453 + asset_count : int; 454 + user_id : string; 455 + } 456 + 457 + val t_jsont : t Jsont.t 458 + end 459 + 460 + module CreateLibraryDto : sig 461 + type t = { 462 + exclusion_patterns : string list option; 463 + import_paths : string list option; 464 + name : string option; 465 + owner_id : string; 466 + } 467 + 468 + val t_jsont : t Jsont.t 469 + end 470 + 471 + module CreateProfileImageDto : sig 472 + type t = { 473 + file : string; 474 + } 475 + 476 + val t_jsont : t Jsont.t 477 + end 478 + 479 + module CreateProfileImageResponseDto : sig 480 + type t = { 481 + profile_changed_at : Ptime.t; 482 + profile_image_path : string; 483 + user_id : string; 484 + } 485 + 486 + val t_jsont : t Jsont.t 487 + end 488 + 489 + module CropParameters : sig 490 + type t = { 491 + height : float; (** Height of the crop *) 492 + width : float; (** Width of the crop *) 493 + x : float; (** Top-Left X coordinate of crop *) 494 + y : float; (** Top-Left Y coordinate of crop *) 495 + } 496 + 497 + val t_jsont : t Jsont.t 498 + end 499 + 500 + module DatabaseBackupConfig : sig 501 + type t = { 502 + cron_expression : string; 503 + enabled : bool; 504 + keep_last_amount : float; 505 + } 506 + 507 + val t_jsont : t Jsont.t 508 + end 509 + 510 + module DatabaseBackupDeleteDto : sig 511 + type t = { 512 + backups : string list; 513 + } 514 + 515 + val t_jsont : t Jsont.t 516 + end 517 + 518 + module DatabaseBackupDto : sig 519 + type t = { 520 + filename : string; 521 + filesize : float; 522 + } 523 + 524 + val t_jsont : t Jsont.t 525 + end 526 + 527 + module DatabaseBackupUploadDto : sig 528 + type t = { 529 + file : string option; 530 + } 531 + 532 + val t_jsont : t Jsont.t 533 + end 534 + 535 + module DownloadArchiveInfo : sig 536 + type t = { 537 + asset_ids : string list; 538 + size : int; 539 + } 540 + 541 + val t_jsont : t Jsont.t 542 + end 543 + 544 + module DownloadInfoDto : sig 545 + type t = { 546 + album_id : string option; 547 + archive_size : int option; 548 + asset_ids : string list option; 549 + user_id : string option; 550 + } 551 + 552 + val t_jsont : t Jsont.t 553 + end 554 + 555 + module DownloadResponse : sig 556 + type t = { 557 + archive_size : int; 558 + include_embedded_videos : bool; 559 + } 560 + 561 + val t_jsont : t Jsont.t 562 + end 563 + 564 + module DownloadUpdate : sig 565 + type t = { 566 + archive_size : int option; 567 + include_embedded_videos : bool option; 568 + } 569 + 570 + val t_jsont : t Jsont.t 571 + end 572 + 573 + module DuplicateDetectionConfig : sig 574 + type t = { 575 + enabled : bool; 576 + max_distance : float; 577 + } 578 + 579 + val t_jsont : t Jsont.t 580 + end 581 + 582 + module EmailNotificationsResponse : sig 583 + type t = { 584 + album_invite : bool; 585 + album_update : bool; 586 + enabled : bool; 587 + } 588 + 589 + val t_jsont : t Jsont.t 590 + end 591 + 592 + module EmailNotificationsUpdate : sig 593 + type t = { 594 + album_invite : bool option; 595 + album_update : bool option; 596 + enabled : bool option; 597 + } 598 + 599 + val t_jsont : t Jsont.t 600 + end 601 + 602 + module ExifResponseDto : sig 603 + type t = { 604 + city : string option; 605 + country : string option; 606 + date_time_original : Ptime.t option; 607 + description : string option; 608 + exif_image_height : float option; 609 + exif_image_width : float option; 610 + exposure_time : string option; 611 + f_number : float option; 612 + file_size_in_byte : int64 option; 613 + focal_length : float option; 614 + iso : float option; 615 + latitude : float option; 616 + lens_model : string option; 617 + longitude : float option; 618 + make : string option; 619 + model : string option; 620 + modify_date : Ptime.t option; 621 + orientation : string option; 622 + projection_type : string option; 623 + rating : float option; 624 + state : string option; 625 + time_zone : string option; 626 + } 627 + 628 + val t_jsont : t Jsont.t 629 + end 630 + 631 + module FaceDto : sig 632 + type t = { 633 + id : string; 634 + } 635 + 636 + val t_jsont : t Jsont.t 637 + end 638 + 639 + module FacialRecognitionConfig : sig 640 + type t = { 641 + enabled : bool; 642 + max_distance : float; 643 + min_faces : int; 644 + min_score : float; 645 + model_name : string; 646 + } 647 + 648 + val t_jsont : t Jsont.t 649 + end 650 + 651 + module FoldersResponse : sig 652 + type t = { 653 + enabled : bool; 654 + sidebar_web : bool; 655 + } 656 + 657 + val t_jsont : t Jsont.t 658 + end 659 + 660 + module FoldersUpdate : sig 661 + type t = { 662 + enabled : bool option; 663 + sidebar_web : bool option; 664 + } 665 + 666 + val t_jsont : t Jsont.t 667 + end 668 + 669 + module ImageFormat : sig 670 + type t = 671 + | Jpeg 672 + | Webp 673 + 674 + val t_jsont : t Jsont.t 675 + end 676 + 677 + module JobName : sig 678 + type t = 679 + | Asset_delete 680 + | Asset_delete_check 681 + | Asset_detect_faces_queue_all 682 + | Asset_detect_faces 683 + | Asset_detect_duplicates_queue_all 684 + | Asset_detect_duplicates 685 + | Asset_edit_thumbnail_generation 686 + | Asset_encode_video_queue_all 687 + | Asset_encode_video 688 + | Asset_empty_trash 689 + | Asset_extract_metadata_queue_all 690 + | Asset_extract_metadata 691 + | Asset_file_migration 692 + | Asset_generate_thumbnails_queue_all 693 + | Asset_generate_thumbnails 694 + | Audit_log_cleanup 695 + | Audit_table_cleanup 696 + | Database_backup 697 + | Facial_recognition_queue_all 698 + | Facial_recognition 699 + | File_delete 700 + | File_migration_queue_all 701 + | Library_delete_check 702 + | Library_delete 703 + | Library_remove_asset 704 + | Library_scan_assets_queue_all 705 + | Library_sync_assets 706 + | Library_sync_files_queue_all 707 + | Library_sync_files 708 + | Library_scan_queue_all 709 + | Memory_cleanup 710 + | Memory_generate 711 + | Notifications_cleanup 712 + | Notify_user_signup 713 + | Notify_album_invite 714 + | Notify_album_update 715 + | User_delete 716 + | User_delete_check 717 + | User_sync_usage 718 + | Person_cleanup 719 + | Person_file_migration 720 + | Person_generate_thumbnail 721 + | Session_cleanup 722 + | Send_mail 723 + | Sidecar_queue_all 724 + | Sidecar_check 725 + | Sidecar_write 726 + | Smart_search_queue_all 727 + | Smart_search 728 + | Storage_template_migration 729 + | Storage_template_migration_single 730 + | Tag_cleanup 731 + | Version_check 732 + | Ocr_queue_all 733 + | Ocr 734 + | Workflow_run 735 + 736 + val t_jsont : t Jsont.t 737 + end 738 + 739 + module JobSettingsDto : sig 740 + type t = { 741 + concurrency : int; 742 + } 743 + 744 + val t_jsont : t Jsont.t 745 + end 746 + 747 + module LibraryResponseDto : sig 748 + type t = { 749 + asset_count : int; 750 + created_at : Ptime.t; 751 + exclusion_patterns : string list; 752 + id : string; 753 + import_paths : string list; 754 + name : string; 755 + owner_id : string; 756 + refreshed_at : Ptime.t; 757 + updated_at : Ptime.t; 758 + } 759 + 760 + val t_jsont : t Jsont.t 761 + end 762 + 763 + module LibraryStatsResponseDto : sig 764 + type t = { 765 + photos : int; 766 + total : int; 767 + usage : int64; 768 + videos : int; 769 + } 770 + 771 + val t_jsont : t Jsont.t 772 + end 773 + 774 + module LicenseKeyDto : sig 775 + type t = { 776 + activation_key : string; 777 + license_key : string; 778 + } 779 + 780 + val t_jsont : t Jsont.t 781 + end 782 + 783 + module LicenseResponseDto : sig 784 + type t = { 785 + activated_at : Ptime.t; 786 + activation_key : string; 787 + license_key : string; 788 + } 789 + 790 + val t_jsont : t Jsont.t 791 + end 792 + 793 + module LogLevel : sig 794 + type t = 795 + | Verbose 796 + | Debug 797 + | Log 798 + | Warn 799 + | Error 800 + | Fatal 801 + 802 + val t_jsont : t Jsont.t 803 + end 804 + 805 + module LoginCredentialDto : sig 806 + type t = { 807 + email : string; 808 + password : string; 809 + } 810 + 811 + val t_jsont : t Jsont.t 812 + end 813 + 814 + module LoginResponseDto : sig 815 + type t = { 816 + access_token : string; 817 + is_admin : bool; 818 + is_onboarded : bool; 819 + name : string; 820 + profile_image_path : string; 821 + should_change_password : bool; 822 + user_email : string; 823 + user_id : string; 824 + } 825 + 826 + val t_jsont : t Jsont.t 827 + end 828 + 829 + module LogoutResponseDto : sig 830 + type t = { 831 + redirect_uri : string; 832 + successful : bool; 833 + } 834 + 835 + val t_jsont : t Jsont.t 836 + end 837 + 838 + module MachineLearningAvailabilityChecksDto : sig 839 + type t = { 840 + enabled : bool; 841 + interval : float; 842 + timeout : float; 843 + } 844 + 845 + val t_jsont : t Jsont.t 846 + end 847 + 848 + module MaintenanceAction : sig 849 + type t = 850 + | Start 851 + | End_ 852 + | Select_database_restore 853 + | Restore_database 854 + 855 + val t_jsont : t Jsont.t 856 + end 857 + 858 + module MaintenanceAuthDto : sig 859 + type t = { 860 + username : string; 861 + } 862 + 863 + val t_jsont : t Jsont.t 864 + end 865 + 866 + module MaintenanceLoginDto : sig 867 + type t = { 868 + token : string option; 869 + } 870 + 871 + val t_jsont : t Jsont.t 872 + end 873 + 874 + module ManualJobName : sig 875 + type t = 876 + | Person_cleanup 877 + | Tag_cleanup 878 + | User_cleanup 879 + | Memory_cleanup 880 + | Memory_create 881 + | Backup_database 882 + 883 + val t_jsont : t Jsont.t 884 + end 885 + 886 + module MapMarkerResponseDto : sig 887 + type t = { 888 + city : string; 889 + country : string; 890 + id : string; 891 + lat : float; 892 + lon : float; 893 + state : string; 894 + } 895 + 896 + val t_jsont : t Jsont.t 897 + end 898 + 899 + module MapReverseGeocodeResponseDto : sig 900 + type t = { 901 + city : string; 902 + country : string; 903 + state : string; 904 + } 905 + 906 + val t_jsont : t Jsont.t 907 + end 908 + 909 + module MemoriesResponse : sig 910 + type t = { 911 + duration : int; 912 + enabled : bool; 913 + } 914 + 915 + val t_jsont : t Jsont.t 916 + end 917 + 918 + module MemoriesUpdate : sig 919 + type t = { 920 + duration : int option; 921 + enabled : bool option; 922 + } 923 + 924 + val t_jsont : t Jsont.t 925 + end 926 + 927 + module MemorySearchOrder : sig 928 + type t = 929 + | Asc 930 + | Desc 931 + | Random 932 + 933 + val t_jsont : t Jsont.t 934 + end 935 + 936 + module MemoryStatisticsResponseDto : sig 937 + type t = { 938 + total : int; 939 + } 940 + 941 + val t_jsont : t Jsont.t 942 + end 943 + 944 + module MemoryType : sig 945 + type t = 946 + | On_this_day 947 + 948 + val t_jsont : t Jsont.t 949 + end 950 + 951 + module MemoryUpdateDto : sig 952 + type t = { 953 + is_saved : bool option; 954 + memory_at : Ptime.t option; 955 + seen_at : Ptime.t option; 956 + } 957 + 958 + val t_jsont : t Jsont.t 959 + end 960 + 961 + module MergePersonDto : sig 962 + type t = { 963 + ids : string list; 964 + } 965 + 966 + val t_jsont : t Jsont.t 967 + end 968 + 969 + module MirrorAxis : sig 970 + (** Axis to mirror along *) 971 + type t = 972 + | Horizontal 973 + | Vertical 974 + 975 + val t_jsont : t Jsont.t 976 + end 977 + 978 + module NotificationDeleteAllDto : sig 979 + type t = { 980 + ids : string list; 981 + } 982 + 983 + val t_jsont : t Jsont.t 984 + end 985 + 986 + module NotificationLevel : sig 987 + type t = 988 + | Success 989 + | Error 990 + | Warning 991 + | Info 992 + 993 + val t_jsont : t Jsont.t 994 + end 995 + 996 + module NotificationType : sig 997 + type t = 998 + | Job_failed 999 + | Backup_failed 1000 + | System_message 1001 + | Album_invite 1002 + | Album_update 1003 + | Custom 1004 + 1005 + val t_jsont : t Jsont.t 1006 + end 1007 + 1008 + module NotificationUpdateAllDto : sig 1009 + type t = { 1010 + ids : string list; 1011 + read_at : Ptime.t option; 1012 + } 1013 + 1014 + val t_jsont : t Jsont.t 1015 + end 1016 + 1017 + module NotificationUpdateDto : sig 1018 + type t = { 1019 + read_at : Ptime.t option; 1020 + } 1021 + 1022 + val t_jsont : t Jsont.t 1023 + end 1024 + 1025 + module OauthAuthorizeResponseDto : sig 1026 + type t = { 1027 + url : string; 1028 + } 1029 + 1030 + val t_jsont : t Jsont.t 1031 + end 1032 + 1033 + module OauthCallbackDto : sig 1034 + type t = { 1035 + code_verifier : string option; 1036 + state : string option; 1037 + url : string; 1038 + } 1039 + 1040 + val t_jsont : t Jsont.t 1041 + end 1042 + 1043 + module OauthConfigDto : sig 1044 + type t = { 1045 + code_challenge : string option; 1046 + redirect_uri : string; 1047 + state : string option; 1048 + } 1049 + 1050 + val t_jsont : t Jsont.t 1051 + end 1052 + 1053 + module OauthTokenEndpointAuthMethod : sig 1054 + type t = 1055 + | Client_secret_post 1056 + | Client_secret_basic 1057 + 1058 + val t_jsont : t Jsont.t 1059 + end 1060 + 1061 + module OcrConfig : sig 1062 + type t = { 1063 + enabled : bool; 1064 + max_resolution : int; 1065 + min_detection_score : float; 1066 + min_recognition_score : float; 1067 + model_name : string; 1068 + } 1069 + 1070 + val t_jsont : t Jsont.t 1071 + end 1072 + 1073 + module OnThisDayDto : sig 1074 + type t = { 1075 + year : float; 1076 + } 1077 + 1078 + val t_jsont : t Jsont.t 1079 + end 1080 + 1081 + module OnboardingDto : sig 1082 + type t = { 1083 + is_onboarded : bool; 1084 + } 1085 + 1086 + val t_jsont : t Jsont.t 1087 + end 1088 + 1089 + module OnboardingResponseDto : sig 1090 + type t = { 1091 + is_onboarded : bool; 1092 + } 1093 + 1094 + val t_jsont : t Jsont.t 1095 + end 1096 + 1097 + module PartnerCreateDto : sig 1098 + type t = { 1099 + shared_with_id : string; 1100 + } 1101 + 1102 + val t_jsont : t Jsont.t 1103 + end 1104 + 1105 + module PartnerDirection : sig 1106 + type t = 1107 + | Shared_by 1108 + | Shared_with 1109 + 1110 + val t_jsont : t Jsont.t 1111 + end 1112 + 1113 + module PartnerUpdateDto : sig 1114 + type t = { 1115 + in_timeline : bool; 1116 + } 1117 + 1118 + val t_jsont : t Jsont.t 1119 + end 1120 + 1121 + module PeopleResponse : sig 1122 + type t = { 1123 + enabled : bool; 1124 + sidebar_web : bool; 1125 + } 1126 + 1127 + val t_jsont : t Jsont.t 1128 + end 1129 + 1130 + module PeopleUpdate : sig 1131 + type t = { 1132 + enabled : bool option; 1133 + sidebar_web : bool option; 1134 + } 1135 + 1136 + val t_jsont : t Jsont.t 1137 + end 1138 + 1139 + module PeopleUpdateItem : sig 1140 + type t = { 1141 + birth_date : string option; (** Person date of birth. 1142 + Note: the mobile app cannot currently set the birth date to null. *) 1143 + color : string option; 1144 + feature_face_asset_id : string option; (** Asset is used to get the feature face thumbnail. *) 1145 + id : string; (** Person id. *) 1146 + is_favorite : bool option; 1147 + is_hidden : bool option; (** Person visibility *) 1148 + name : string option; (** Person name. *) 1149 + } 1150 + 1151 + val t_jsont : t Jsont.t 1152 + end 1153 + 1154 + module Permission : sig 1155 + type t = 1156 + | All 1157 + | Activity_create 1158 + | Activity_read 1159 + | Activity_update 1160 + | Activity_delete 1161 + | Activity_statistics 1162 + | Api_key_create 1163 + | Api_key_read 1164 + | Api_key_update 1165 + | Api_key_delete 1166 + | Asset_read 1167 + | Asset_update 1168 + | Asset_delete 1169 + | Asset_statistics 1170 + | Asset_share 1171 + | Asset_view 1172 + | Asset_download 1173 + | Asset_upload 1174 + | Asset_replace 1175 + | Asset_copy 1176 + | Asset_derive 1177 + | Asset_edit_get 1178 + | Asset_edit_create 1179 + | Asset_edit_delete 1180 + | Album_create 1181 + | Album_read 1182 + | Album_update 1183 + | Album_delete 1184 + | Album_statistics 1185 + | Album_share 1186 + | Album_download 1187 + | Album_asset_create 1188 + | Album_asset_delete 1189 + | Album_user_create 1190 + | Album_user_update 1191 + | Album_user_delete 1192 + | Auth_change_password 1193 + | Auth_device_delete 1194 + | Archive_read 1195 + | Backup_list 1196 + | Backup_download 1197 + | Backup_upload 1198 + | Backup_delete 1199 + | Duplicate_read 1200 + | Duplicate_delete 1201 + | Face_create 1202 + | Face_read 1203 + | Face_update 1204 + | Face_delete 1205 + | Folder_read 1206 + | Job_create 1207 + | Job_read 1208 + | Library_create 1209 + | Library_read 1210 + | Library_update 1211 + | Library_delete 1212 + | Library_statistics 1213 + | Timeline_read 1214 + | Timeline_download 1215 + | Maintenance 1216 + | Map_read 1217 + | Map_search 1218 + | Memory_create 1219 + | Memory_read 1220 + | Memory_update 1221 + | Memory_delete 1222 + | Memory_statistics 1223 + | Memory_asset_create 1224 + | Memory_asset_delete 1225 + | Notification_create 1226 + | Notification_read 1227 + | Notification_update 1228 + | Notification_delete 1229 + | Partner_create 1230 + | Partner_read 1231 + | Partner_update 1232 + | Partner_delete 1233 + | Person_create 1234 + | Person_read 1235 + | Person_update 1236 + | Person_delete 1237 + | Person_statistics 1238 + | Person_merge 1239 + | Person_reassign 1240 + | Pin_code_create 1241 + | Pin_code_update 1242 + | Pin_code_delete 1243 + | Plugin_create 1244 + | Plugin_read 1245 + | Plugin_update 1246 + | Plugin_delete 1247 + | Server_about 1248 + | Server_apk_links 1249 + | Server_storage 1250 + | Server_statistics 1251 + | Server_version_check 1252 + | Server_license_read 1253 + | Server_license_update 1254 + | Server_license_delete 1255 + | Session_create 1256 + | Session_read 1257 + | Session_update 1258 + | Session_delete 1259 + | Session_lock 1260 + | Shared_link_create 1261 + | Shared_link_read 1262 + | Shared_link_update 1263 + | Shared_link_delete 1264 + | Stack_create 1265 + | Stack_read 1266 + | Stack_update 1267 + | Stack_delete 1268 + | Sync_stream 1269 + | Sync_checkpoint_read 1270 + | Sync_checkpoint_update 1271 + | Sync_checkpoint_delete 1272 + | System_config_read 1273 + | System_config_update 1274 + | System_metadata_read 1275 + | System_metadata_update 1276 + | Tag_create 1277 + | Tag_read 1278 + | Tag_update 1279 + | Tag_delete 1280 + | Tag_asset 1281 + | User_read 1282 + | User_update 1283 + | User_license_create 1284 + | User_license_read 1285 + | User_license_update 1286 + | User_license_delete 1287 + | User_onboarding_read 1288 + | User_onboarding_update 1289 + | User_onboarding_delete 1290 + | User_preference_read 1291 + | User_preference_update 1292 + | User_profile_image_create 1293 + | User_profile_image_read 1294 + | User_profile_image_update 1295 + | User_profile_image_delete 1296 + | Queue_read 1297 + | Queue_update 1298 + | Queue_job_create 1299 + | Queue_job_read 1300 + | Queue_job_update 1301 + | Queue_job_delete 1302 + | Workflow_create 1303 + | Workflow_read 1304 + | Workflow_update 1305 + | Workflow_delete 1306 + | Admin_user_create 1307 + | Admin_user_read 1308 + | Admin_user_update 1309 + | Admin_user_delete 1310 + | Admin_session_read 1311 + | Admin_auth_unlink_all 1312 + 1313 + val t_jsont : t Jsont.t 1314 + end 1315 + 1316 + module PersonCreateDto : sig 1317 + type t = { 1318 + birth_date : string option; (** Person date of birth. 1319 + Note: the mobile app cannot currently set the birth date to null. *) 1320 + color : string option; 1321 + is_favorite : bool option; 1322 + is_hidden : bool option; (** Person visibility *) 1323 + name : string option; (** Person name. *) 1324 + } 1325 + 1326 + val t_jsont : t Jsont.t 1327 + end 1328 + 1329 + module PersonResponseDto : sig 1330 + type t = { 1331 + birth_date : string; 1332 + color : string option; 1333 + id : string; 1334 + is_favorite : bool option; 1335 + is_hidden : bool; 1336 + name : string; 1337 + thumbnail_path : string; 1338 + updated_at : Ptime.t option; 1339 + } 1340 + 1341 + val t_jsont : t Jsont.t 1342 + end 1343 + 1344 + module PersonStatisticsResponseDto : sig 1345 + type t = { 1346 + assets : int; 1347 + } 1348 + 1349 + val t_jsont : t Jsont.t 1350 + end 1351 + 1352 + module PersonUpdateDto : sig 1353 + type t = { 1354 + birth_date : string option; (** Person date of birth. 1355 + Note: the mobile app cannot currently set the birth date to null. *) 1356 + color : string option; 1357 + feature_face_asset_id : string option; (** Asset is used to get the feature face thumbnail. *) 1358 + is_favorite : bool option; 1359 + is_hidden : bool option; (** Person visibility *) 1360 + name : string option; (** Person name. *) 1361 + } 1362 + 1363 + val t_jsont : t Jsont.t 1364 + end 1365 + 1366 + module PinCodeChangeDto : sig 1367 + type t = { 1368 + new_pin_code : string; 1369 + password : string option; 1370 + pin_code : string option; 1371 + } 1372 + 1373 + val t_jsont : t Jsont.t 1374 + end 1375 + 1376 + module PinCodeResetDto : sig 1377 + type t = { 1378 + password : string option; 1379 + pin_code : string option; 1380 + } 1381 + 1382 + val t_jsont : t Jsont.t 1383 + end 1384 + 1385 + module PinCodeSetupDto : sig 1386 + type t = { 1387 + pin_code : string; 1388 + } 1389 + 1390 + val t_jsont : t Jsont.t 1391 + end 1392 + 1393 + module PlacesResponseDto : sig 1394 + type t = { 1395 + admin1name : string option; 1396 + admin2name : string option; 1397 + latitude : float; 1398 + longitude : float; 1399 + name : string; 1400 + } 1401 + 1402 + val t_jsont : t Jsont.t 1403 + end 1404 + 1405 + module PluginContextType : sig 1406 + type t = 1407 + | Asset 1408 + | Album 1409 + | Person 1410 + 1411 + val t_jsont : t Jsont.t 1412 + end 1413 + 1414 + module PluginTriggerType : sig 1415 + type t = 1416 + | Asset_create 1417 + | Person_recognized 1418 + 1419 + val t_jsont : t Jsont.t 1420 + end 1421 + 1422 + module PurchaseResponse : sig 1423 + type t = { 1424 + hide_buy_button_until : string; 1425 + show_support_badge : bool; 1426 + } 1427 + 1428 + val t_jsont : t Jsont.t 1429 + end 1430 + 1431 + module PurchaseUpdate : sig 1432 + type t = { 1433 + hide_buy_button_until : string option; 1434 + show_support_badge : bool option; 1435 + } 1436 + 1437 + val t_jsont : t Jsont.t 1438 + end 1439 + 1440 + module QueueCommand : sig 1441 + type t = 1442 + | Start 1443 + | Pause 1444 + | Resume 1445 + | Empty 1446 + | Clear_failed 1447 + 1448 + val t_jsont : t Jsont.t 1449 + end 1450 + 1451 + module QueueDeleteDto : sig 1452 + type t = { 1453 + failed : bool option; (** If true, will also remove failed jobs from the queue. *) 1454 + } 1455 + 1456 + val t_jsont : t Jsont.t 1457 + end 1458 + 1459 + module QueueJobStatus : sig 1460 + type t = 1461 + | Active 1462 + | Failed 1463 + | Completed 1464 + | Delayed 1465 + | Waiting 1466 + | Paused 1467 + 1468 + val t_jsont : t Jsont.t 1469 + end 1470 + 1471 + module QueueName : sig 1472 + type t = 1473 + | Thumbnail_generation 1474 + | Metadata_extraction 1475 + | Video_conversion 1476 + | Face_detection 1477 + | Facial_recognition 1478 + | Smart_search 1479 + | Duplicate_detection 1480 + | Background_task 1481 + | Storage_template_migration 1482 + | Migration 1483 + | Search 1484 + | Sidecar 1485 + | Library 1486 + | Notifications 1487 + | Backup_database 1488 + | Ocr 1489 + | Workflow 1490 + | Editor 1491 + 1492 + val t_jsont : t Jsont.t 1493 + end 1494 + 1495 + module QueueStatisticsDto : sig 1496 + type t = { 1497 + active : int; 1498 + completed : int; 1499 + delayed : int; 1500 + failed : int; 1501 + paused : int; 1502 + waiting : int; 1503 + } 1504 + 1505 + val t_jsont : t Jsont.t 1506 + end 1507 + 1508 + module QueueStatusLegacyDto : sig 1509 + type t = { 1510 + is_active : bool; 1511 + is_paused : bool; 1512 + } 1513 + 1514 + val t_jsont : t Jsont.t 1515 + end 1516 + 1517 + module QueueUpdateDto : sig 1518 + type t = { 1519 + is_paused : bool option; 1520 + } 1521 + 1522 + val t_jsont : t Jsont.t 1523 + end 1524 + 1525 + module RatingsResponse : sig 1526 + type t = { 1527 + enabled : bool; 1528 + } 1529 + 1530 + val t_jsont : t Jsont.t 1531 + end 1532 + 1533 + module RatingsUpdate : sig 1534 + type t = { 1535 + enabled : bool option; 1536 + } 1537 + 1538 + val t_jsont : t Jsont.t 1539 + end 1540 + 1541 + module ReactionLevel : sig 1542 + type t = 1543 + | Album 1544 + | Asset 1545 + 1546 + val t_jsont : t Jsont.t 1547 + end 1548 + 1549 + module ReactionType : sig 1550 + type t = 1551 + | Comment 1552 + | Like 1553 + 1554 + val t_jsont : t Jsont.t 1555 + end 1556 + 1557 + module ReverseGeocodingStateResponseDto : sig 1558 + type t = { 1559 + last_import_file_name : string; 1560 + last_update : string; 1561 + } 1562 + 1563 + val t_jsont : t Jsont.t 1564 + end 1565 + 1566 + module RotateParameters : sig 1567 + type t = { 1568 + angle : float; (** Rotation angle in degrees *) 1569 + } 1570 + 1571 + val t_jsont : t Jsont.t 1572 + end 1573 + 1574 + module SearchFacetCountResponseDto : sig 1575 + type t = { 1576 + count : int; 1577 + value : string; 1578 + } 1579 + 1580 + val t_jsont : t Jsont.t 1581 + end 1582 + 1583 + module SearchStatisticsResponseDto : sig 1584 + type t = { 1585 + total : int; 1586 + } 1587 + 1588 + val t_jsont : t Jsont.t 1589 + end 1590 + 1591 + module SearchSuggestionType : sig 1592 + type t = 1593 + | Country 1594 + | State 1595 + | City 1596 + | Camera_make 1597 + | Camera_model 1598 + | Camera_lens_model 1599 + 1600 + val t_jsont : t Jsont.t 1601 + end 1602 + 1603 + module ServerAboutResponseDto : sig 1604 + type t = { 1605 + build : string option; 1606 + build_image : string option; 1607 + build_image_url : string option; 1608 + build_url : string option; 1609 + exiftool : string option; 1610 + ffmpeg : string option; 1611 + imagemagick : string option; 1612 + libvips : string option; 1613 + licensed : bool; 1614 + nodejs : string option; 1615 + repository : string option; 1616 + repository_url : string option; 1617 + source_commit : string option; 1618 + source_ref : string option; 1619 + source_url : string option; 1620 + third_party_bug_feature_url : string option; 1621 + third_party_documentation_url : string option; 1622 + third_party_source_url : string option; 1623 + third_party_support_url : string option; 1624 + version : string; 1625 + version_url : string; 1626 + } 1627 + 1628 + val t_jsont : t Jsont.t 1629 + end 1630 + 1631 + module ServerApkLinksDto : sig 1632 + type t = { 1633 + arm64v8a : string; 1634 + armeabiv7a : string; 1635 + universal : string; 1636 + x86_64 : string; 1637 + } 1638 + 1639 + val t_jsont : t Jsont.t 1640 + end 1641 + 1642 + module ServerConfigDto : sig 1643 + type t = { 1644 + external_domain : string; 1645 + is_initialized : bool; 1646 + is_onboarded : bool; 1647 + login_page_message : string; 1648 + maintenance_mode : bool; 1649 + map_dark_style_url : string; 1650 + map_light_style_url : string; 1651 + oauth_button_text : string; 1652 + public_users : bool; 1653 + trash_days : int; 1654 + user_delete_delay : int; 1655 + } 1656 + 1657 + val t_jsont : t Jsont.t 1658 + end 1659 + 1660 + module ServerFeaturesDto : sig 1661 + type t = { 1662 + config_file : bool; 1663 + duplicate_detection : bool; 1664 + email : bool; 1665 + facial_recognition : bool; 1666 + import_faces : bool; 1667 + map : bool; 1668 + oauth : bool; 1669 + oauth_auto_launch : bool; 1670 + ocr : bool; 1671 + password_login : bool; 1672 + reverse_geocoding : bool; 1673 + search : bool; 1674 + sidecar : bool; 1675 + smart_search : bool; 1676 + trash : bool; 1677 + } 1678 + 1679 + val t_jsont : t Jsont.t 1680 + end 1681 + 1682 + module ServerMediaTypesResponseDto : sig 1683 + type t = { 1684 + image : string list; 1685 + sidecar : string list; 1686 + video : string list; 1687 + } 1688 + 1689 + val t_jsont : t Jsont.t 1690 + end 1691 + 1692 + module ServerPingResponse : sig 1693 + type t = { 1694 + res : string; 1695 + } 1696 + 1697 + val t_jsont : t Jsont.t 1698 + end 1699 + 1700 + module ServerStorageResponseDto : sig 1701 + type t = { 1702 + disk_available : string; 1703 + disk_available_raw : int64; 1704 + disk_size : string; 1705 + disk_size_raw : int64; 1706 + disk_usage_percentage : float; 1707 + disk_use : string; 1708 + disk_use_raw : int64; 1709 + } 1710 + 1711 + val t_jsont : t Jsont.t 1712 + end 1713 + 1714 + module ServerThemeDto : sig 1715 + type t = { 1716 + custom_css : string; 1717 + } 1718 + 1719 + val t_jsont : t Jsont.t 1720 + end 1721 + 1722 + module ServerVersionHistoryResponseDto : sig 1723 + type t = { 1724 + created_at : Ptime.t; 1725 + id : string; 1726 + version : string; 1727 + } 1728 + 1729 + val t_jsont : t Jsont.t 1730 + end 1731 + 1732 + module ServerVersionResponseDto : sig 1733 + type t = { 1734 + major : int; 1735 + minor : int; 1736 + patch : int; 1737 + } 1738 + 1739 + val t_jsont : t Jsont.t 1740 + end 1741 + 1742 + module SessionCreateDto : sig 1743 + type t = { 1744 + device_os : string option; 1745 + device_type : string option; 1746 + duration : float option; (** session duration, in seconds *) 1747 + } 1748 + 1749 + val t_jsont : t Jsont.t 1750 + end 1751 + 1752 + module SessionCreateResponseDto : sig 1753 + type t = { 1754 + app_version : string; 1755 + created_at : string; 1756 + current : bool; 1757 + device_os : string; 1758 + device_type : string; 1759 + expires_at : string option; 1760 + id : string; 1761 + is_pending_sync_reset : bool; 1762 + token : string; 1763 + updated_at : string; 1764 + } 1765 + 1766 + val t_jsont : t Jsont.t 1767 + end 1768 + 1769 + module SessionResponseDto : sig 1770 + type t = { 1771 + app_version : string; 1772 + created_at : string; 1773 + current : bool; 1774 + device_os : string; 1775 + device_type : string; 1776 + expires_at : string option; 1777 + id : string; 1778 + is_pending_sync_reset : bool; 1779 + updated_at : string; 1780 + } 1781 + 1782 + val t_jsont : t Jsont.t 1783 + end 1784 + 1785 + module SessionUnlockDto : sig 1786 + type t = { 1787 + password : string option; 1788 + pin_code : string option; 1789 + } 1790 + 1791 + val t_jsont : t Jsont.t 1792 + end 1793 + 1794 + module SessionUpdateDto : sig 1795 + type t = { 1796 + is_pending_sync_reset : bool option; 1797 + } 1798 + 1799 + val t_jsont : t Jsont.t 1800 + end 1801 + 1802 + module SharedLinkEditDto : sig 1803 + type t = { 1804 + allow_download : bool option; 1805 + allow_upload : bool option; 1806 + change_expiry_time : bool option; (** Few clients cannot send null to set the expiryTime to never. 1807 + Setting this flag and not sending expiryAt is considered as null instead. 1808 + Clients that can send null values can ignore this. *) 1809 + description : string option; 1810 + expires_at : Ptime.t option; 1811 + password : string option; 1812 + show_metadata : bool option; 1813 + slug : string option; 1814 + } 1815 + 1816 + val t_jsont : t Jsont.t 1817 + end 1818 + 1819 + module SharedLinkType : sig 1820 + type t = 1821 + | Album 1822 + | Individual 1823 + 1824 + val t_jsont : t Jsont.t 1825 + end 1826 + 1827 + module SharedLinksResponse : sig 1828 + type t = { 1829 + enabled : bool; 1830 + sidebar_web : bool; 1831 + } 1832 + 1833 + val t_jsont : t Jsont.t 1834 + end 1835 + 1836 + module SharedLinksUpdate : sig 1837 + type t = { 1838 + enabled : bool option; 1839 + sidebar_web : bool option; 1840 + } 1841 + 1842 + val t_jsont : t Jsont.t 1843 + end 1844 + 1845 + module SignUpDto : sig 1846 + type t = { 1847 + email : string; 1848 + name : string; 1849 + password : string; 1850 + } 1851 + 1852 + val t_jsont : t Jsont.t 1853 + end 1854 + 1855 + module SourceType : sig 1856 + type t = 1857 + | Machine_learning 1858 + | Exif 1859 + | Manual 1860 + 1861 + val t_jsont : t Jsont.t 1862 + end 1863 + 1864 + module StackCreateDto : sig 1865 + type t = { 1866 + asset_ids : string list; (** first asset becomes the primary *) 1867 + } 1868 + 1869 + val t_jsont : t Jsont.t 1870 + end 1871 + 1872 + module StackUpdateDto : sig 1873 + type t = { 1874 + primary_asset_id : string option; 1875 + } 1876 + 1877 + val t_jsont : t Jsont.t 1878 + end 1879 + 1880 + module StorageFolder : sig 1881 + type t = 1882 + | Encoded_video 1883 + | Library 1884 + | Upload 1885 + | Profile 1886 + | Thumbs 1887 + | Backups 1888 + 1889 + val t_jsont : t Jsont.t 1890 + end 1891 + 1892 + module SyncAckSetDto : sig 1893 + type t = { 1894 + acks : string list; 1895 + } 1896 + 1897 + val t_jsont : t Jsont.t 1898 + end 1899 + 1900 + module SyncAckV1 : sig 1901 + type t = Jsont.json 1902 + val t_jsont : t Jsont.t 1903 + end 1904 + 1905 + module SyncAlbumDeleteV1 : sig 1906 + type t = { 1907 + album_id : string; 1908 + } 1909 + 1910 + val t_jsont : t Jsont.t 1911 + end 1912 + 1913 + module SyncAlbumToAssetDeleteV1 : sig 1914 + type t = { 1915 + album_id : string; 1916 + asset_id : string; 1917 + } 1918 + 1919 + val t_jsont : t Jsont.t 1920 + end 1921 + 1922 + module SyncAlbumToAssetV1 : sig 1923 + type t = { 1924 + album_id : string; 1925 + asset_id : string; 1926 + } 1927 + 1928 + val t_jsont : t Jsont.t 1929 + end 1930 + 1931 + module SyncAlbumUserDeleteV1 : sig 1932 + type t = { 1933 + album_id : string; 1934 + user_id : string; 1935 + } 1936 + 1937 + val t_jsont : t Jsont.t 1938 + end 1939 + 1940 + module SyncAssetDeleteV1 : sig 1941 + type t = { 1942 + asset_id : string; 1943 + } 1944 + 1945 + val t_jsont : t Jsont.t 1946 + end 1947 + 1948 + module SyncAssetExifV1 : sig 1949 + type t = { 1950 + asset_id : string; 1951 + city : string; 1952 + country : string; 1953 + date_time_original : Ptime.t; 1954 + description : string; 1955 + exif_image_height : int; 1956 + exif_image_width : int; 1957 + exposure_time : string; 1958 + f_number : float; 1959 + file_size_in_byte : int; 1960 + focal_length : float; 1961 + fps : float; 1962 + iso : int; 1963 + latitude : float; 1964 + lens_model : string; 1965 + longitude : float; 1966 + make : string; 1967 + model : string; 1968 + modify_date : Ptime.t; 1969 + orientation : string; 1970 + profile_description : string; 1971 + projection_type : string; 1972 + rating : int; 1973 + state : string; 1974 + time_zone : string; 1975 + } 1976 + 1977 + val t_jsont : t Jsont.t 1978 + end 1979 + 1980 + module SyncAssetFaceDeleteV1 : sig 1981 + type t = { 1982 + asset_face_id : string; 1983 + } 1984 + 1985 + val t_jsont : t Jsont.t 1986 + end 1987 + 1988 + module SyncAssetFaceV1 : sig 1989 + type t = { 1990 + asset_id : string; 1991 + bounding_box_x1 : int; 1992 + bounding_box_x2 : int; 1993 + bounding_box_y1 : int; 1994 + bounding_box_y2 : int; 1995 + id : string; 1996 + image_height : int; 1997 + image_width : int; 1998 + person_id : string; 1999 + source_type : string; 2000 + } 2001 + 2002 + val t_jsont : t Jsont.t 2003 + end 2004 + 2005 + module SyncAssetMetadataDeleteV1 : sig 2006 + type t = { 2007 + asset_id : string; 2008 + key : string; 2009 + } 2010 + 2011 + val t_jsont : t Jsont.t 2012 + end 2013 + 2014 + module SyncAssetMetadataV1 : sig 2015 + type t = { 2016 + asset_id : string; 2017 + key : string; 2018 + value : Jsont.json; 2019 + } 2020 + 2021 + val t_jsont : t Jsont.t 2022 + end 2023 + 2024 + module SyncCompleteV1 : sig 2025 + type t = Jsont.json 2026 + val t_jsont : t Jsont.t 2027 + end 2028 + 2029 + module SyncEntityType : sig 2030 + type t = 2031 + | Auth_user_v1 2032 + | User_v1 2033 + | User_delete_v1 2034 + | Asset_v1 2035 + | Asset_delete_v1 2036 + | Asset_exif_v1 2037 + | Asset_metadata_v1 2038 + | Asset_metadata_delete_v1 2039 + | Partner_v1 2040 + | Partner_delete_v1 2041 + | Partner_asset_v1 2042 + | Partner_asset_backfill_v1 2043 + | Partner_asset_delete_v1 2044 + | Partner_asset_exif_v1 2045 + | Partner_asset_exif_backfill_v1 2046 + | Partner_stack_backfill_v1 2047 + | Partner_stack_delete_v1 2048 + | Partner_stack_v1 2049 + | Album_v1 2050 + | Album_delete_v1 2051 + | Album_user_v1 2052 + | Album_user_backfill_v1 2053 + | Album_user_delete_v1 2054 + | Album_asset_create_v1 2055 + | Album_asset_update_v1 2056 + | Album_asset_backfill_v1 2057 + | Album_asset_exif_create_v1 2058 + | Album_asset_exif_update_v1 2059 + | Album_asset_exif_backfill_v1 2060 + | Album_to_asset_v1 2061 + | Album_to_asset_delete_v1 2062 + | Album_to_asset_backfill_v1 2063 + | Memory_v1 2064 + | Memory_delete_v1 2065 + | Memory_to_asset_v1 2066 + | Memory_to_asset_delete_v1 2067 + | Stack_v1 2068 + | Stack_delete_v1 2069 + | Person_v1 2070 + | Person_delete_v1 2071 + | Asset_face_v1 2072 + | Asset_face_delete_v1 2073 + | User_metadata_v1 2074 + | User_metadata_delete_v1 2075 + | Sync_ack_v1 2076 + | Sync_reset_v1 2077 + | Sync_complete_v1 2078 + 2079 + val t_jsont : t Jsont.t 2080 + end 2081 + 2082 + module SyncMemoryAssetDeleteV1 : sig 2083 + type t = { 2084 + asset_id : string; 2085 + memory_id : string; 2086 + } 2087 + 2088 + val t_jsont : t Jsont.t 2089 + end 2090 + 2091 + module SyncMemoryAssetV1 : sig 2092 + type t = { 2093 + asset_id : string; 2094 + memory_id : string; 2095 + } 2096 + 2097 + val t_jsont : t Jsont.t 2098 + end 2099 + 2100 + module SyncMemoryDeleteV1 : sig 2101 + type t = { 2102 + memory_id : string; 2103 + } 2104 + 2105 + val t_jsont : t Jsont.t 2106 + end 2107 + 2108 + module SyncPartnerDeleteV1 : sig 2109 + type t = { 2110 + shared_by_id : string; 2111 + shared_with_id : string; 2112 + } 2113 + 2114 + val t_jsont : t Jsont.t 2115 + end 2116 + 2117 + module SyncPartnerV1 : sig 2118 + type t = { 2119 + in_timeline : bool; 2120 + shared_by_id : string; 2121 + shared_with_id : string; 2122 + } 2123 + 2124 + val t_jsont : t Jsont.t 2125 + end 2126 + 2127 + module SyncPersonDeleteV1 : sig 2128 + type t = { 2129 + person_id : string; 2130 + } 2131 + 2132 + val t_jsont : t Jsont.t 2133 + end 2134 + 2135 + module SyncPersonV1 : sig 2136 + type t = { 2137 + birth_date : Ptime.t; 2138 + color : string; 2139 + created_at : Ptime.t; 2140 + face_asset_id : string; 2141 + id : string; 2142 + is_favorite : bool; 2143 + is_hidden : bool; 2144 + name : string; 2145 + owner_id : string; 2146 + updated_at : Ptime.t; 2147 + } 2148 + 2149 + val t_jsont : t Jsont.t 2150 + end 2151 + 2152 + module SyncRequestType : sig 2153 + type t = 2154 + | Albums_v1 2155 + | Album_users_v1 2156 + | Album_to_assets_v1 2157 + | Album_assets_v1 2158 + | Album_asset_exifs_v1 2159 + | Assets_v1 2160 + | Asset_exifs_v1 2161 + | Asset_metadata_v1 2162 + | Auth_users_v1 2163 + | Memories_v1 2164 + | Memory_to_assets_v1 2165 + | Partners_v1 2166 + | Partner_assets_v1 2167 + | Partner_asset_exifs_v1 2168 + | Partner_stacks_v1 2169 + | Stacks_v1 2170 + | Users_v1 2171 + | People_v1 2172 + | Asset_faces_v1 2173 + | User_metadata_v1 2174 + 2175 + val t_jsont : t Jsont.t 2176 + end 2177 + 2178 + module SyncResetV1 : sig 2179 + type t = Jsont.json 2180 + val t_jsont : t Jsont.t 2181 + end 2182 + 2183 + module SyncStackDeleteV1 : sig 2184 + type t = { 2185 + stack_id : string; 2186 + } 2187 + 2188 + val t_jsont : t Jsont.t 2189 + end 2190 + 2191 + module SyncStackV1 : sig 2192 + type t = { 2193 + created_at : Ptime.t; 2194 + id : string; 2195 + owner_id : string; 2196 + primary_asset_id : string; 2197 + updated_at : Ptime.t; 2198 + } 2199 + 2200 + val t_jsont : t Jsont.t 2201 + end 2202 + 2203 + module SyncUserDeleteV1 : sig 2204 + type t = { 2205 + user_id : string; 2206 + } 2207 + 2208 + val t_jsont : t Jsont.t 2209 + end 2210 + 2211 + module SystemConfigFacesDto : sig 2212 + type t = { 2213 + import : bool; 2214 + } 2215 + 2216 + val t_jsont : t Jsont.t 2217 + end 2218 + 2219 + module SystemConfigLibraryScanDto : sig 2220 + type t = { 2221 + cron_expression : string; 2222 + enabled : bool; 2223 + } 2224 + 2225 + val t_jsont : t Jsont.t 2226 + end 2227 + 2228 + module SystemConfigLibraryWatchDto : sig 2229 + type t = { 2230 + enabled : bool; 2231 + } 2232 + 2233 + val t_jsont : t Jsont.t 2234 + end 2235 + 2236 + module SystemConfigMapDto : sig 2237 + type t = { 2238 + dark_style : string; 2239 + enabled : bool; 2240 + light_style : string; 2241 + } 2242 + 2243 + val t_jsont : t Jsont.t 2244 + end 2245 + 2246 + module SystemConfigNewVersionCheckDto : sig 2247 + type t = { 2248 + enabled : bool; 2249 + } 2250 + 2251 + val t_jsont : t Jsont.t 2252 + end 2253 + 2254 + module SystemConfigNightlyTasksDto : sig 2255 + type t = { 2256 + cluster_new_faces : bool; 2257 + database_cleanup : bool; 2258 + generate_memories : bool; 2259 + missing_thumbnails : bool; 2260 + start_time : string; 2261 + sync_quota_usage : bool; 2262 + } 2263 + 2264 + val t_jsont : t Jsont.t 2265 + end 2266 + 2267 + module SystemConfigPasswordLoginDto : sig 2268 + type t = { 2269 + enabled : bool; 2270 + } 2271 + 2272 + val t_jsont : t Jsont.t 2273 + end 2274 + 2275 + module SystemConfigReverseGeocodingDto : sig 2276 + type t = { 2277 + enabled : bool; 2278 + } 2279 + 2280 + val t_jsont : t Jsont.t 2281 + end 2282 + 2283 + module SystemConfigServerDto : sig 2284 + type t = { 2285 + external_domain : string; 2286 + login_page_message : string; 2287 + public_users : bool; 2288 + } 2289 + 2290 + val t_jsont : t Jsont.t 2291 + end 2292 + 2293 + module SystemConfigSmtpTransportDto : sig 2294 + type t = { 2295 + host : string; 2296 + ignore_cert : bool; 2297 + password : string; 2298 + port : float; 2299 + secure : bool; 2300 + username : string; 2301 + } 2302 + 2303 + val t_jsont : t Jsont.t 2304 + end 2305 + 2306 + module SystemConfigStorageTemplateDto : sig 2307 + type t = { 2308 + enabled : bool; 2309 + hash_verification_enabled : bool; 2310 + template : string; 2311 + } 2312 + 2313 + val t_jsont : t Jsont.t 2314 + end 2315 + 2316 + module SystemConfigTemplateEmailsDto : sig 2317 + type t = { 2318 + album_invite_template : string; 2319 + album_update_template : string; 2320 + welcome_template : string; 2321 + } 2322 + 2323 + val t_jsont : t Jsont.t 2324 + end 2325 + 2326 + module SystemConfigTemplateStorageOptionDto : sig 2327 + type t = { 2328 + day_options : string list; 2329 + hour_options : string list; 2330 + minute_options : string list; 2331 + month_options : string list; 2332 + preset_options : string list; 2333 + second_options : string list; 2334 + week_options : string list; 2335 + year_options : string list; 2336 + } 2337 + 2338 + val t_jsont : t Jsont.t 2339 + end 2340 + 2341 + module SystemConfigThemeDto : sig 2342 + type t = { 2343 + custom_css : string; 2344 + } 2345 + 2346 + val t_jsont : t Jsont.t 2347 + end 2348 + 2349 + module SystemConfigTrashDto : sig 2350 + type t = { 2351 + days : int; 2352 + enabled : bool; 2353 + } 2354 + 2355 + val t_jsont : t Jsont.t 2356 + end 2357 + 2358 + module SystemConfigUserDto : sig 2359 + type t = { 2360 + delete_delay : int; 2361 + } 2362 + 2363 + val t_jsont : t Jsont.t 2364 + end 2365 + 2366 + module TagBulkAssetsDto : sig 2367 + type t = { 2368 + asset_ids : string list; 2369 + tag_ids : string list; 2370 + } 2371 + 2372 + val t_jsont : t Jsont.t 2373 + end 2374 + 2375 + module TagBulkAssetsResponseDto : sig 2376 + type t = { 2377 + count : int; 2378 + } 2379 + 2380 + val t_jsont : t Jsont.t 2381 + end 2382 + 2383 + module TagCreateDto : sig 2384 + type t = { 2385 + color : string option; 2386 + name : string; 2387 + parent_id : string option; 2388 + } 2389 + 2390 + val t_jsont : t Jsont.t 2391 + end 2392 + 2393 + module TagResponseDto : sig 2394 + type t = { 2395 + color : string option; 2396 + created_at : Ptime.t; 2397 + id : string; 2398 + name : string; 2399 + parent_id : string option; 2400 + updated_at : Ptime.t; 2401 + value : string; 2402 + } 2403 + 2404 + val t_jsont : t Jsont.t 2405 + end 2406 + 2407 + module TagUpdateDto : sig 2408 + type t = { 2409 + color : string option; 2410 + } 2411 + 2412 + val t_jsont : t Jsont.t 2413 + end 2414 + 2415 + module TagUpsertDto : sig 2416 + type t = { 2417 + tags : string list; 2418 + } 2419 + 2420 + val t_jsont : t Jsont.t 2421 + end 2422 + 2423 + module TagsResponse : sig 2424 + type t = { 2425 + enabled : bool; 2426 + sidebar_web : bool; 2427 + } 2428 + 2429 + val t_jsont : t Jsont.t 2430 + end 2431 + 2432 + module TagsUpdate : sig 2433 + type t = { 2434 + enabled : bool option; 2435 + sidebar_web : bool option; 2436 + } 2437 + 2438 + val t_jsont : t Jsont.t 2439 + end 2440 + 2441 + module TemplateDto : sig 2442 + type t = { 2443 + template : string; 2444 + } 2445 + 2446 + val t_jsont : t Jsont.t 2447 + end 2448 + 2449 + module TemplateResponseDto : sig 2450 + type t = { 2451 + html : string; 2452 + name : string; 2453 + } 2454 + 2455 + val t_jsont : t Jsont.t 2456 + end 2457 + 2458 + module TestEmailResponseDto : sig 2459 + type t = { 2460 + message_id : string; 2461 + } 2462 + 2463 + val t_jsont : t Jsont.t 2464 + end 2465 + 2466 + module TimeBucketsResponseDto : sig 2467 + type t = { 2468 + count : int; (** Number of assets in this time bucket *) 2469 + time_bucket : string; (** Time bucket identifier in YYYY-MM-DD format representing the start of the time period *) 2470 + } 2471 + 2472 + val t_jsont : t Jsont.t 2473 + end 2474 + 2475 + module ToneMapping : sig 2476 + type t = 2477 + | Hable 2478 + | Mobius 2479 + | Reinhard 2480 + | Disabled 2481 + 2482 + val t_jsont : t Jsont.t 2483 + end 2484 + 2485 + module TranscodeHwaccel : sig 2486 + type t = 2487 + | Nvenc 2488 + | Qsv 2489 + | Vaapi 2490 + | Rkmpp 2491 + | Disabled 2492 + 2493 + val t_jsont : t Jsont.t 2494 + end 2495 + 2496 + module TranscodePolicy : sig 2497 + type t = 2498 + | All 2499 + | Optimal 2500 + | Bitrate 2501 + | Required 2502 + | Disabled 2503 + 2504 + val t_jsont : t Jsont.t 2505 + end 2506 + 2507 + module TrashResponseDto : sig 2508 + type t = { 2509 + count : int; 2510 + } 2511 + 2512 + val t_jsont : t Jsont.t 2513 + end 2514 + 2515 + module UpdateLibraryDto : sig 2516 + type t = { 2517 + exclusion_patterns : string list option; 2518 + import_paths : string list option; 2519 + name : string option; 2520 + } 2521 + 2522 + val t_jsont : t Jsont.t 2523 + end 2524 + 2525 + module UsageByUserDto : sig 2526 + type t = { 2527 + photos : int; 2528 + quota_size_in_bytes : int64; 2529 + usage : int64; 2530 + usage_photos : int64; 2531 + usage_videos : int64; 2532 + user_id : string; 2533 + user_name : string; 2534 + videos : int; 2535 + } 2536 + 2537 + val t_jsont : t Jsont.t 2538 + end 2539 + 2540 + module UserAdminDeleteDto : sig 2541 + type t = { 2542 + force : bool option; 2543 + } 2544 + 2545 + val t_jsont : t Jsont.t 2546 + end 2547 + 2548 + module UserAvatarColor : sig 2549 + type t = 2550 + | Primary 2551 + | Pink 2552 + | Red 2553 + | Yellow 2554 + | Blue 2555 + | Green 2556 + | Purple 2557 + | Orange 2558 + | Gray 2559 + | Amber 2560 + 2561 + val t_jsont : t Jsont.t 2562 + end 2563 + 2564 + module UserLicense : sig 2565 + type t = { 2566 + activated_at : Ptime.t; 2567 + activation_key : string; 2568 + license_key : string; 2569 + } 2570 + 2571 + val t_jsont : t Jsont.t 2572 + end 2573 + 2574 + module UserMetadataKey : sig 2575 + type t = 2576 + | Preferences 2577 + | License 2578 + | Onboarding 2579 + 2580 + val t_jsont : t Jsont.t 2581 + end 2582 + 2583 + module UserStatus : sig 2584 + type t = 2585 + | Active 2586 + | Removing 2587 + | Deleted 2588 + 2589 + val t_jsont : t Jsont.t 2590 + end 2591 + 2592 + module ValidateAccessTokenResponseDto : sig 2593 + type t = { 2594 + auth_status : bool; 2595 + } 2596 + 2597 + val t_jsont : t Jsont.t 2598 + end 2599 + 2600 + module ValidateLibraryDto : sig 2601 + type t = { 2602 + exclusion_patterns : string list option; 2603 + import_paths : string list option; 2604 + } 2605 + 2606 + val t_jsont : t Jsont.t 2607 + end 2608 + 2609 + module ValidateLibraryImportPathResponseDto : sig 2610 + type t = { 2611 + import_path : string; 2612 + is_valid : bool; 2613 + message : string option; 2614 + } 2615 + 2616 + val t_jsont : t Jsont.t 2617 + end 2618 + 2619 + module VersionCheckStateResponseDto : sig 2620 + type t = { 2621 + checked_at : string; 2622 + release_version : string; 2623 + } 2624 + 2625 + val t_jsont : t Jsont.t 2626 + end 2627 + 2628 + module VideoCodec : sig 2629 + type t = 2630 + | H264 2631 + | Hevc 2632 + | Vp9 2633 + | Av1 2634 + 2635 + val t_jsont : t Jsont.t 2636 + end 2637 + 2638 + module VideoContainer : sig 2639 + type t = 2640 + | Mov 2641 + | Mp4 2642 + | Ogg 2643 + | Webm 2644 + 2645 + val t_jsont : t Jsont.t 2646 + end 2647 + 2648 + module WorkflowActionItemDto : sig 2649 + type t = { 2650 + action_config : Jsont.json option; 2651 + plugin_action_id : string; 2652 + } 2653 + 2654 + val t_jsont : t Jsont.t 2655 + end 2656 + 2657 + module WorkflowActionResponseDto : sig 2658 + type t = { 2659 + action_config : Jsont.json; 2660 + id : string; 2661 + order : float; 2662 + plugin_action_id : string; 2663 + workflow_id : string; 2664 + } 2665 + 2666 + val t_jsont : t Jsont.t 2667 + end 2668 + 2669 + module WorkflowFilterItemDto : sig 2670 + type t = { 2671 + filter_config : Jsont.json option; 2672 + plugin_filter_id : string; 2673 + } 2674 + 2675 + val t_jsont : t Jsont.t 2676 + end 2677 + 2678 + module WorkflowFilterResponseDto : sig 2679 + type t = { 2680 + filter_config : Jsont.json; 2681 + id : string; 2682 + order : float; 2683 + plugin_filter_id : string; 2684 + workflow_id : string; 2685 + } 2686 + 2687 + val t_jsont : t Jsont.t 2688 + end 2689 + 2690 + module AlbumUserAddDto : sig 2691 + type t = { 2692 + role : Jsont.json option; 2693 + user_id : string; 2694 + } 2695 + 2696 + val t_jsont : t Jsont.t 2697 + end 2698 + 2699 + module AlbumUserCreateDto : sig 2700 + type t = { 2701 + role : Jsont.json; 2702 + user_id : string; 2703 + } 2704 + 2705 + val t_jsont : t Jsont.t 2706 + end 2707 + 2708 + module SyncAlbumUserV1 : sig 2709 + type t = { 2710 + album_id : string; 2711 + role : Jsont.json; 2712 + user_id : string; 2713 + } 2714 + 2715 + val t_jsont : t Jsont.t 2716 + end 2717 + 2718 + module UpdateAlbumUserDto : sig 2719 + type t = { 2720 + role : Jsont.json; 2721 + } 2722 + 2723 + val t_jsont : t Jsont.t 2724 + end 2725 + 2726 + module AssetBulkUploadCheckDto : sig 2727 + type t = { 2728 + assets : AssetBulkUploadCheckItem.t list; 2729 + } 2730 + 2731 + val t_jsont : t Jsont.t 2732 + end 2733 + 2734 + module AssetBulkUploadCheckResponseDto : sig 2735 + type t = { 2736 + results : AssetBulkUploadCheckResult.t list; 2737 + } 2738 + 2739 + val t_jsont : t Jsont.t 2740 + end 2741 + 2742 + module AssetFaceUpdateDto : sig 2743 + type t = { 2744 + data : AssetFaceUpdateItem.t list; 2745 + } 2746 + 2747 + val t_jsont : t Jsont.t 2748 + end 2749 + 2750 + module AssetJobsDto : sig 2751 + type t = { 2752 + asset_ids : string list; 2753 + name : Jsont.json; 2754 + } 2755 + 2756 + val t_jsont : t Jsont.t 2757 + end 2758 + 2759 + module AssetMediaResponseDto : sig 2760 + type t = { 2761 + id : string; 2762 + status : Jsont.json; 2763 + } 2764 + 2765 + val t_jsont : t Jsont.t 2766 + end 2767 + 2768 + module AssetMetadataBulkDeleteDto : sig 2769 + type t = { 2770 + items : AssetMetadataBulkDeleteItemDto.t list; 2771 + } 2772 + 2773 + val t_jsont : t Jsont.t 2774 + end 2775 + 2776 + module AssetMetadataBulkUpsertDto : sig 2777 + type t = { 2778 + items : AssetMetadataBulkUpsertItemDto.t list; 2779 + } 2780 + 2781 + val t_jsont : t Jsont.t 2782 + end 2783 + 2784 + module AssetMetadataUpsertDto : sig 2785 + type t = { 2786 + items : AssetMetadataUpsertItemDto.t list; 2787 + } 2788 + 2789 + val t_jsont : t Jsont.t 2790 + end 2791 + 2792 + module AlbumsResponse : sig 2793 + type t = { 2794 + default_asset_order : Jsont.json; 2795 + } 2796 + 2797 + val t_jsont : t Jsont.t 2798 + end 2799 + 2800 + module AlbumsUpdate : sig 2801 + type t = { 2802 + default_asset_order : Jsont.json option; 2803 + } 2804 + 2805 + val t_jsont : t Jsont.t 2806 + end 2807 + 2808 + module SyncAlbumV1 : sig 2809 + type t = { 2810 + created_at : Ptime.t; 2811 + description : string; 2812 + id : string; 2813 + is_activity_enabled : bool; 2814 + name : string; 2815 + order : Jsont.json; 2816 + owner_id : string; 2817 + thumbnail_asset_id : string; 2818 + updated_at : Ptime.t; 2819 + } 2820 + 2821 + val t_jsont : t Jsont.t 2822 + end 2823 + 2824 + module UpdateAlbumDto : sig 2825 + type t = { 2826 + album_name : string option; 2827 + album_thumbnail_asset_id : string option; 2828 + description : string option; 2829 + is_activity_enabled : bool option; 2830 + order : Jsont.json option; 2831 + } 2832 + 2833 + val t_jsont : t Jsont.t 2834 + end 2835 + 2836 + module AssetBulkUpdateDto : sig 2837 + type t = { 2838 + date_time_original : string option; 2839 + date_time_relative : float option; 2840 + description : string option; 2841 + duplicate_id : string option; 2842 + ids : string list; 2843 + is_favorite : bool option; 2844 + latitude : float option; 2845 + longitude : float option; 2846 + rating : float option; 2847 + time_zone : string option; 2848 + visibility : Jsont.json option; 2849 + } 2850 + 2851 + val t_jsont : t Jsont.t 2852 + end 2853 + 2854 + module AssetMediaCreateDto : sig 2855 + type t = { 2856 + asset_data : string; 2857 + device_asset_id : string; 2858 + device_id : string; 2859 + duration : string option; 2860 + file_created_at : Ptime.t; 2861 + file_modified_at : Ptime.t; 2862 + filename : string option; 2863 + is_favorite : bool option; 2864 + live_photo_video_id : string option; 2865 + metadata : AssetMetadataUpsertItemDto.t list option; 2866 + sidecar_data : string option; 2867 + visibility : Jsont.json option; 2868 + } 2869 + 2870 + val t_jsont : t Jsont.t 2871 + end 2872 + 2873 + module MetadataSearchDto : sig 2874 + type t = { 2875 + album_ids : string list option; 2876 + checksum : string option; 2877 + city : string option; 2878 + country : string option; 2879 + created_after : Ptime.t option; 2880 + created_before : Ptime.t option; 2881 + description : string option; 2882 + device_asset_id : string option; 2883 + device_id : string option; 2884 + encoded_video_path : string option; 2885 + id : string option; 2886 + is_encoded : bool option; 2887 + is_favorite : bool option; 2888 + is_motion : bool option; 2889 + is_not_in_album : bool option; 2890 + is_offline : bool option; 2891 + lens_model : string option; 2892 + library_id : string option; 2893 + make : string option; 2894 + model : string option; 2895 + ocr : string option; 2896 + order : Jsont.json option; 2897 + original_file_name : string option; 2898 + original_path : string option; 2899 + page : float option; 2900 + person_ids : string list option; 2901 + preview_path : string option; 2902 + rating : float option; 2903 + size : float option; 2904 + state : string option; 2905 + tag_ids : string list option; 2906 + taken_after : Ptime.t option; 2907 + taken_before : Ptime.t option; 2908 + thumbnail_path : string option; 2909 + trashed_after : Ptime.t option; 2910 + trashed_before : Ptime.t option; 2911 + type_ : Jsont.json option; 2912 + updated_after : Ptime.t option; 2913 + updated_before : Ptime.t option; 2914 + visibility : Jsont.json option; 2915 + with_deleted : bool option; 2916 + with_exif : bool option; 2917 + with_people : bool option; 2918 + with_stacked : bool option; 2919 + } 2920 + 2921 + val t_jsont : t Jsont.t 2922 + end 2923 + 2924 + module RandomSearchDto : sig 2925 + type t = { 2926 + album_ids : string list option; 2927 + city : string option; 2928 + country : string option; 2929 + created_after : Ptime.t option; 2930 + created_before : Ptime.t option; 2931 + device_id : string option; 2932 + is_encoded : bool option; 2933 + is_favorite : bool option; 2934 + is_motion : bool option; 2935 + is_not_in_album : bool option; 2936 + is_offline : bool option; 2937 + lens_model : string option; 2938 + library_id : string option; 2939 + make : string option; 2940 + model : string option; 2941 + ocr : string option; 2942 + person_ids : string list option; 2943 + rating : float option; 2944 + size : float option; 2945 + state : string option; 2946 + tag_ids : string list option; 2947 + taken_after : Ptime.t option; 2948 + taken_before : Ptime.t option; 2949 + trashed_after : Ptime.t option; 2950 + trashed_before : Ptime.t option; 2951 + type_ : Jsont.json option; 2952 + updated_after : Ptime.t option; 2953 + updated_before : Ptime.t option; 2954 + visibility : Jsont.json option; 2955 + with_deleted : bool option; 2956 + with_exif : bool option; 2957 + with_people : bool option; 2958 + with_stacked : bool option; 2959 + } 2960 + 2961 + val t_jsont : t Jsont.t 2962 + end 2963 + 2964 + module SmartSearchDto : sig 2965 + type t = { 2966 + album_ids : string list option; 2967 + city : string option; 2968 + country : string option; 2969 + created_after : Ptime.t option; 2970 + created_before : Ptime.t option; 2971 + device_id : string option; 2972 + is_encoded : bool option; 2973 + is_favorite : bool option; 2974 + is_motion : bool option; 2975 + is_not_in_album : bool option; 2976 + is_offline : bool option; 2977 + language : string option; 2978 + lens_model : string option; 2979 + library_id : string option; 2980 + make : string option; 2981 + model : string option; 2982 + ocr : string option; 2983 + page : float option; 2984 + person_ids : string list option; 2985 + query : string option; 2986 + query_asset_id : string option; 2987 + rating : float option; 2988 + size : float option; 2989 + state : string option; 2990 + tag_ids : string list option; 2991 + taken_after : Ptime.t option; 2992 + taken_before : Ptime.t option; 2993 + trashed_after : Ptime.t option; 2994 + trashed_before : Ptime.t option; 2995 + type_ : Jsont.json option; 2996 + updated_after : Ptime.t option; 2997 + updated_before : Ptime.t option; 2998 + visibility : Jsont.json option; 2999 + with_deleted : bool option; 3000 + with_exif : bool option; 3001 + } 3002 + 3003 + val t_jsont : t Jsont.t 3004 + end 3005 + 3006 + module StatisticsSearchDto : sig 3007 + type t = { 3008 + album_ids : string list option; 3009 + city : string option; 3010 + country : string option; 3011 + created_after : Ptime.t option; 3012 + created_before : Ptime.t option; 3013 + description : string option; 3014 + device_id : string option; 3015 + is_encoded : bool option; 3016 + is_favorite : bool option; 3017 + is_motion : bool option; 3018 + is_not_in_album : bool option; 3019 + is_offline : bool option; 3020 + lens_model : string option; 3021 + library_id : string option; 3022 + make : string option; 3023 + model : string option; 3024 + ocr : string option; 3025 + person_ids : string list option; 3026 + rating : float option; 3027 + state : string option; 3028 + tag_ids : string list option; 3029 + taken_after : Ptime.t option; 3030 + taken_before : Ptime.t option; 3031 + trashed_after : Ptime.t option; 3032 + trashed_before : Ptime.t option; 3033 + type_ : Jsont.json option; 3034 + updated_after : Ptime.t option; 3035 + updated_before : Ptime.t option; 3036 + visibility : Jsont.json option; 3037 + } 3038 + 3039 + val t_jsont : t Jsont.t 3040 + end 3041 + 3042 + module SyncAssetV1 : sig 3043 + type t = { 3044 + checksum : string; 3045 + deleted_at : Ptime.t; 3046 + duration : string; 3047 + file_created_at : Ptime.t; 3048 + file_modified_at : Ptime.t; 3049 + height : int; 3050 + id : string; 3051 + is_edited : bool; 3052 + is_favorite : bool; 3053 + library_id : string; 3054 + live_photo_video_id : string; 3055 + local_date_time : Ptime.t; 3056 + original_file_name : string; 3057 + owner_id : string; 3058 + stack_id : string; 3059 + thumbhash : string; 3060 + type_ : Jsont.json; 3061 + visibility : Jsont.json; 3062 + width : int; 3063 + } 3064 + 3065 + val t_jsont : t Jsont.t 3066 + end 3067 + 3068 + module TimeBucketAssetResponseDto : sig 3069 + type t = { 3070 + city : string list; (** Array of city names extracted from EXIF GPS data *) 3071 + country : string list; (** Array of country names extracted from EXIF GPS data *) 3072 + duration : string list; (** Array of video durations in HH:MM:SS format (null for images) *) 3073 + file_created_at : string list; (** Array of file creation timestamps in UTC (ISO 8601 format, without timezone) *) 3074 + id : string list; (** Array of asset IDs in the time bucket *) 3075 + is_favorite : bool list; (** Array indicating whether each asset is favorited *) 3076 + is_image : bool list; (** Array indicating whether each asset is an image (false for videos) *) 3077 + is_trashed : bool list; (** Array indicating whether each asset is in the trash *) 3078 + latitude : float list option; (** Array of latitude coordinates extracted from EXIF GPS data *) 3079 + live_photo_video_id : string list; (** Array of live photo video asset IDs (null for non-live photos) *) 3080 + local_offset_hours : float list; (** Array of UTC offset hours at the time each photo was taken. Positive values are east of UTC, negative values are west of UTC. Values may be fractional (e.g., 5.5 for +05:30, -9.75 for -09:45). Applying this offset to 'fileCreatedAt' will give you the time the photo was taken from the photographer's perspective. *) 3081 + longitude : float list option; (** Array of longitude coordinates extracted from EXIF GPS data *) 3082 + owner_id : string list; (** Array of owner IDs for each asset *) 3083 + projection_type : string list; (** Array of projection types for 360° content (e.g., "EQUIRECTANGULAR", "CUBEFACE", "CYLINDRICAL") *) 3084 + ratio : float list; (** Array of aspect ratios (width/height) for each asset *) 3085 + stack : Jsont.json list option; (** Array of stack information as [stackId, assetCount] tuples (null for non-stacked assets) *) 3086 + thumbhash : string list; (** Array of BlurHash strings for generating asset previews (base64 encoded) *) 3087 + visibility : AssetVisibility.t list; (** Array of visibility statuses for each asset (e.g., ARCHIVE, TIMELINE, HIDDEN, LOCKED) *) 3088 + } 3089 + 3090 + val t_jsont : t Jsont.t 3091 + end 3092 + 3093 + module UpdateAssetDto : sig 3094 + type t = { 3095 + date_time_original : string option; 3096 + description : string option; 3097 + is_favorite : bool option; 3098 + latitude : float option; 3099 + live_photo_video_id : string option; 3100 + longitude : float option; 3101 + rating : float option; 3102 + visibility : Jsont.json option; 3103 + } 3104 + 3105 + val t_jsont : t Jsont.t 3106 + end 3107 + 3108 + module AlbumsAddAssetsResponseDto : sig 3109 + type t = { 3110 + error : Jsont.json option; 3111 + success : bool; 3112 + } 3113 + 3114 + val t_jsont : t Jsont.t 3115 + end 3116 + 3117 + module AssetEditActionCrop : sig 3118 + type t = { 3119 + action : Jsont.json; 3120 + parameters : CropParameters.t; 3121 + } 3122 + 3123 + val t_jsont : t Jsont.t 3124 + end 3125 + 3126 + module SystemConfigBackupsDto : sig 3127 + type t = { 3128 + database : DatabaseBackupConfig.t; 3129 + } 3130 + 3131 + val t_jsont : t Jsont.t 3132 + end 3133 + 3134 + module DatabaseBackupListResponseDto : sig 3135 + type t = { 3136 + backups : DatabaseBackupDto.t list; 3137 + } 3138 + 3139 + val t_jsont : t Jsont.t 3140 + end 3141 + 3142 + module DownloadResponseDto : sig 3143 + type t = { 3144 + archives : DownloadArchiveInfo.t list; 3145 + total_size : int; 3146 + } 3147 + 3148 + val t_jsont : t Jsont.t 3149 + end 3150 + 3151 + module SystemConfigGeneratedFullsizeImageDto : sig 3152 + type t = { 3153 + enabled : bool; 3154 + format : Jsont.json; 3155 + progressive : bool option; 3156 + quality : int; 3157 + } 3158 + 3159 + val t_jsont : t Jsont.t 3160 + end 3161 + 3162 + module SystemConfigGeneratedImageDto : sig 3163 + type t = { 3164 + format : Jsont.json; 3165 + progressive : bool option; 3166 + quality : int; 3167 + size : int; 3168 + } 3169 + 3170 + val t_jsont : t Jsont.t 3171 + end 3172 + 3173 + module QueueJobResponseDto : sig 3174 + type t = { 3175 + data : Jsont.json; 3176 + id : string option; 3177 + name : Jsont.json; 3178 + timestamp : int; 3179 + } 3180 + 3181 + val t_jsont : t Jsont.t 3182 + end 3183 + 3184 + module SystemConfigJobDto : sig 3185 + type t = { 3186 + background_task : JobSettingsDto.t; 3187 + editor : JobSettingsDto.t; 3188 + face_detection : JobSettingsDto.t; 3189 + library : JobSettingsDto.t; 3190 + metadata_extraction : JobSettingsDto.t; 3191 + migration : JobSettingsDto.t; 3192 + notifications : JobSettingsDto.t; 3193 + ocr : JobSettingsDto.t; 3194 + search : JobSettingsDto.t; 3195 + sidecar : JobSettingsDto.t; 3196 + smart_search : JobSettingsDto.t; 3197 + thumbnail_generation : JobSettingsDto.t; 3198 + video_conversion : JobSettingsDto.t; 3199 + workflow : JobSettingsDto.t; 3200 + } 3201 + 3202 + val t_jsont : t Jsont.t 3203 + end 3204 + 3205 + module SystemConfigLoggingDto : sig 3206 + type t = { 3207 + enabled : bool; 3208 + level : Jsont.json; 3209 + } 3210 + 3211 + val t_jsont : t Jsont.t 3212 + end 3213 + 3214 + module MaintenanceStatusResponseDto : sig 3215 + type t = { 3216 + action : Jsont.json; 3217 + active : bool; 3218 + error : string option; 3219 + progress : float option; 3220 + task : string option; 3221 + } 3222 + 3223 + val t_jsont : t Jsont.t 3224 + end 3225 + 3226 + module SetMaintenanceModeDto : sig 3227 + type t = { 3228 + action : Jsont.json; 3229 + restore_backup_filename : string option; 3230 + } 3231 + 3232 + val t_jsont : t Jsont.t 3233 + end 3234 + 3235 + module JobCreateDto : sig 3236 + type t = { 3237 + name : Jsont.json; 3238 + } 3239 + 3240 + val t_jsont : t Jsont.t 3241 + end 3242 + 3243 + module SyncMemoryV1 : sig 3244 + type t = { 3245 + created_at : Ptime.t; 3246 + data : Jsont.json; 3247 + deleted_at : Ptime.t; 3248 + hide_at : Ptime.t; 3249 + id : string; 3250 + is_saved : bool; 3251 + memory_at : Ptime.t; 3252 + owner_id : string; 3253 + seen_at : Ptime.t; 3254 + show_at : Ptime.t; 3255 + type_ : Jsont.json; 3256 + updated_at : Ptime.t; 3257 + } 3258 + 3259 + val t_jsont : t Jsont.t 3260 + end 3261 + 3262 + module MirrorParameters : sig 3263 + type t = { 3264 + axis : Jsont.json; (** Axis to mirror along *) 3265 + } 3266 + 3267 + val t_jsont : t Jsont.t 3268 + end 3269 + 3270 + module NotificationCreateDto : sig 3271 + type t = { 3272 + data : Jsont.json option; 3273 + description : string option; 3274 + level : Jsont.json option; 3275 + read_at : Ptime.t option; 3276 + title : string; 3277 + type_ : Jsont.json option; 3278 + user_id : string; 3279 + } 3280 + 3281 + val t_jsont : t Jsont.t 3282 + end 3283 + 3284 + module NotificationDto : sig 3285 + type t = { 3286 + created_at : Ptime.t; 3287 + data : Jsont.json option; 3288 + description : string option; 3289 + id : string; 3290 + level : Jsont.json; 3291 + read_at : Ptime.t option; 3292 + title : string; 3293 + type_ : Jsont.json; 3294 + } 3295 + 3296 + val t_jsont : t Jsont.t 3297 + end 3298 + 3299 + module SystemConfigOauthDto : sig 3300 + type t = { 3301 + auto_launch : bool; 3302 + auto_register : bool; 3303 + button_text : string; 3304 + client_id : string; 3305 + client_secret : string; 3306 + default_storage_quota : int64; 3307 + enabled : bool; 3308 + issuer_url : string; 3309 + mobile_override_enabled : bool; 3310 + mobile_redirect_uri : string; 3311 + profile_signing_algorithm : string; 3312 + role_claim : string; 3313 + scope : string; 3314 + signing_algorithm : string; 3315 + storage_label_claim : string; 3316 + storage_quota_claim : string; 3317 + timeout : int; 3318 + token_endpoint_auth_method : Jsont.json; 3319 + } 3320 + 3321 + val t_jsont : t Jsont.t 3322 + end 3323 + 3324 + module SystemConfigMachineLearningDto : sig 3325 + type t = { 3326 + availability_checks : MachineLearningAvailabilityChecksDto.t; 3327 + clip : Clipconfig.t; 3328 + duplicate_detection : DuplicateDetectionConfig.t; 3329 + enabled : bool; 3330 + facial_recognition : FacialRecognitionConfig.t; 3331 + ocr : OcrConfig.t; 3332 + urls : string list; 3333 + } 3334 + 3335 + val t_jsont : t Jsont.t 3336 + end 3337 + 3338 + module MemoryCreateDto : sig 3339 + type t = { 3340 + asset_ids : string list option; 3341 + data : OnThisDayDto.t; 3342 + is_saved : bool option; 3343 + memory_at : Ptime.t; 3344 + seen_at : Ptime.t option; 3345 + type_ : Jsont.json; 3346 + } 3347 + 3348 + val t_jsont : t Jsont.t 3349 + end 3350 + 3351 + module PeopleUpdateDto : sig 3352 + type t = { 3353 + people : PeopleUpdateItem.t list; 3354 + } 3355 + 3356 + val t_jsont : t Jsont.t 3357 + end 3358 + 3359 + module ApikeyCreateDto : sig 3360 + type t = { 3361 + name : string option; 3362 + permissions : Permission.t list; 3363 + } 3364 + 3365 + val t_jsont : t Jsont.t 3366 + end 3367 + 3368 + module ApikeyResponseDto : sig 3369 + type t = { 3370 + created_at : Ptime.t; 3371 + id : string; 3372 + name : string; 3373 + permissions : Permission.t list; 3374 + updated_at : Ptime.t; 3375 + } 3376 + 3377 + val t_jsont : t Jsont.t 3378 + end 3379 + 3380 + module ApikeyUpdateDto : sig 3381 + type t = { 3382 + name : string option; 3383 + permissions : Permission.t list option; 3384 + } 3385 + 3386 + val t_jsont : t Jsont.t 3387 + end 3388 + 3389 + module PeopleResponseDto : sig 3390 + type t = { 3391 + has_next_page : bool option; 3392 + hidden : int; 3393 + people : PersonResponseDto.t list; 3394 + total : int; 3395 + } 3396 + 3397 + val t_jsont : t Jsont.t 3398 + end 3399 + 3400 + module PluginActionResponseDto : sig 3401 + type t = { 3402 + description : string; 3403 + id : string; 3404 + method_name : string; 3405 + plugin_id : string; 3406 + schema : Jsont.json; 3407 + supported_contexts : PluginContextType.t list; 3408 + title : string; 3409 + } 3410 + 3411 + val t_jsont : t Jsont.t 3412 + end 3413 + 3414 + module PluginFilterResponseDto : sig 3415 + type t = { 3416 + description : string; 3417 + id : string; 3418 + method_name : string; 3419 + plugin_id : string; 3420 + schema : Jsont.json; 3421 + supported_contexts : PluginContextType.t list; 3422 + title : string; 3423 + } 3424 + 3425 + val t_jsont : t Jsont.t 3426 + end 3427 + 3428 + module PluginTriggerResponseDto : sig 3429 + type t = { 3430 + context_type : Jsont.json; 3431 + type_ : Jsont.json; 3432 + } 3433 + 3434 + val t_jsont : t Jsont.t 3435 + end 3436 + 3437 + module QueueCommandDto : sig 3438 + type t = { 3439 + command : Jsont.json; 3440 + force : bool option; 3441 + } 3442 + 3443 + val t_jsont : t Jsont.t 3444 + end 3445 + 3446 + module QueueResponseDto : sig 3447 + type t = { 3448 + is_paused : bool; 3449 + name : Jsont.json; 3450 + statistics : QueueStatisticsDto.t; 3451 + } 3452 + 3453 + val t_jsont : t Jsont.t 3454 + end 3455 + 3456 + module QueueResponseLegacyDto : sig 3457 + type t = { 3458 + job_counts : QueueStatisticsDto.t; 3459 + queue_status : QueueStatusLegacyDto.t; 3460 + } 3461 + 3462 + val t_jsont : t Jsont.t 3463 + end 3464 + 3465 + module ActivityCreateDto : sig 3466 + type t = { 3467 + album_id : string; 3468 + asset_id : string option; 3469 + comment : string option; 3470 + type_ : Jsont.json; 3471 + } 3472 + 3473 + val t_jsont : t Jsont.t 3474 + end 3475 + 3476 + module AssetEditActionRotate : sig 3477 + type t = { 3478 + action : Jsont.json; 3479 + parameters : RotateParameters.t; 3480 + } 3481 + 3482 + val t_jsont : t Jsont.t 3483 + end 3484 + 3485 + module SearchFacetResponseDto : sig 3486 + type t = { 3487 + counts : SearchFacetCountResponseDto.t list; 3488 + field_name : string; 3489 + } 3490 + 3491 + val t_jsont : t Jsont.t 3492 + end 3493 + 3494 + module SharedLinkCreateDto : sig 3495 + type t = { 3496 + album_id : string option; 3497 + allow_download : bool option; 3498 + allow_upload : bool option; 3499 + asset_ids : string list option; 3500 + description : string option; 3501 + expires_at : Ptime.t option; 3502 + password : string option; 3503 + show_metadata : bool option; 3504 + slug : string option; 3505 + type_ : Jsont.json; 3506 + } 3507 + 3508 + val t_jsont : t Jsont.t 3509 + end 3510 + 3511 + module AssetFaceResponseDto : sig 3512 + type t = { 3513 + bounding_box_x1 : int; 3514 + bounding_box_x2 : int; 3515 + bounding_box_y1 : int; 3516 + bounding_box_y2 : int; 3517 + id : string; 3518 + image_height : int; 3519 + image_width : int; 3520 + person : Jsont.json option; 3521 + source_type : Jsont.json option; 3522 + } 3523 + 3524 + val t_jsont : t Jsont.t 3525 + end 3526 + 3527 + module AssetFaceWithoutPersonResponseDto : sig 3528 + type t = { 3529 + bounding_box_x1 : int; 3530 + bounding_box_x2 : int; 3531 + bounding_box_y1 : int; 3532 + bounding_box_y2 : int; 3533 + id : string; 3534 + image_height : int; 3535 + image_width : int; 3536 + source_type : Jsont.json option; 3537 + } 3538 + 3539 + val t_jsont : t Jsont.t 3540 + end 3541 + 3542 + module MaintenanceDetectInstallStorageFolderDto : sig 3543 + type t = { 3544 + files : float; 3545 + folder : Jsont.json; 3546 + readable : bool; 3547 + writable : bool; 3548 + } 3549 + 3550 + val t_jsont : t Jsont.t 3551 + end 3552 + 3553 + module SyncAckDeleteDto : sig 3554 + type t = { 3555 + types : SyncEntityType.t list option; 3556 + } 3557 + 3558 + val t_jsont : t Jsont.t 3559 + end 3560 + 3561 + module SyncAckDto : sig 3562 + type t = { 3563 + ack : string; 3564 + type_ : Jsont.json; 3565 + } 3566 + 3567 + val t_jsont : t Jsont.t 3568 + end 3569 + 3570 + module SyncStreamDto : sig 3571 + type t = { 3572 + reset : bool option; 3573 + types : SyncRequestType.t list; 3574 + } 3575 + 3576 + val t_jsont : t Jsont.t 3577 + end 3578 + 3579 + module SystemConfigMetadataDto : sig 3580 + type t = { 3581 + faces : SystemConfigFacesDto.t; 3582 + } 3583 + 3584 + val t_jsont : t Jsont.t 3585 + end 3586 + 3587 + module SystemConfigLibraryDto : sig 3588 + type t = { 3589 + scan : SystemConfigLibraryScanDto.t; 3590 + watch : SystemConfigLibraryWatchDto.t; 3591 + } 3592 + 3593 + val t_jsont : t Jsont.t 3594 + end 3595 + 3596 + module SystemConfigSmtpDto : sig 3597 + type t = { 3598 + enabled : bool; 3599 + from : string; 3600 + reply_to : string; 3601 + transport : SystemConfigSmtpTransportDto.t; 3602 + } 3603 + 3604 + val t_jsont : t Jsont.t 3605 + end 3606 + 3607 + module SystemConfigTemplatesDto : sig 3608 + type t = { 3609 + email : SystemConfigTemplateEmailsDto.t; 3610 + } 3611 + 3612 + val t_jsont : t Jsont.t 3613 + end 3614 + 3615 + module ServerStatsResponseDto : sig 3616 + type t = { 3617 + photos : int; 3618 + usage : int64; 3619 + usage_by_user : UsageByUserDto.t list; 3620 + usage_photos : int64; 3621 + usage_videos : int64; 3622 + videos : int; 3623 + } 3624 + 3625 + val t_jsont : t Jsont.t 3626 + end 3627 + 3628 + module AvatarUpdate : sig 3629 + type t = { 3630 + color : Jsont.json option; 3631 + } 3632 + 3633 + val t_jsont : t Jsont.t 3634 + end 3635 + 3636 + module PartnerResponseDto : sig 3637 + type t = { 3638 + avatar_color : Jsont.json; 3639 + email : string; 3640 + id : string; 3641 + in_timeline : bool option; 3642 + name : string; 3643 + profile_changed_at : Ptime.t; 3644 + profile_image_path : string; 3645 + } 3646 + 3647 + val t_jsont : t Jsont.t 3648 + end 3649 + 3650 + module SyncAuthUserV1 : sig 3651 + type t = { 3652 + avatar_color : Jsont.json option; 3653 + deleted_at : Ptime.t; 3654 + email : string; 3655 + has_profile_image : bool; 3656 + id : string; 3657 + is_admin : bool; 3658 + name : string; 3659 + oauth_id : string; 3660 + pin_code : string; 3661 + profile_changed_at : Ptime.t; 3662 + quota_size_in_bytes : int; 3663 + quota_usage_in_bytes : int; 3664 + storage_label : string; 3665 + } 3666 + 3667 + val t_jsont : t Jsont.t 3668 + end 3669 + 3670 + module SyncUserV1 : sig 3671 + type t = { 3672 + avatar_color : Jsont.json option; 3673 + deleted_at : Ptime.t; 3674 + email : string; 3675 + has_profile_image : bool; 3676 + id : string; 3677 + name : string; 3678 + profile_changed_at : Ptime.t; 3679 + } 3680 + 3681 + val t_jsont : t Jsont.t 3682 + end 3683 + 3684 + module UserAdminCreateDto : sig 3685 + type t = { 3686 + avatar_color : Jsont.json option; 3687 + email : string; 3688 + is_admin : bool option; 3689 + name : string; 3690 + notify : bool option; 3691 + password : string; 3692 + quota_size_in_bytes : int64 option; 3693 + should_change_password : bool option; 3694 + storage_label : string option; 3695 + } 3696 + 3697 + val t_jsont : t Jsont.t 3698 + end 3699 + 3700 + module UserAdminUpdateDto : sig 3701 + type t = { 3702 + avatar_color : Jsont.json option; 3703 + email : string option; 3704 + is_admin : bool option; 3705 + name : string option; 3706 + password : string option; 3707 + pin_code : string option; 3708 + quota_size_in_bytes : int64 option; 3709 + should_change_password : bool option; 3710 + storage_label : string option; 3711 + } 3712 + 3713 + val t_jsont : t Jsont.t 3714 + end 3715 + 3716 + module UserResponseDto : sig 3717 + type t = { 3718 + avatar_color : Jsont.json; 3719 + email : string; 3720 + id : string; 3721 + name : string; 3722 + profile_changed_at : Ptime.t; 3723 + profile_image_path : string; 3724 + } 3725 + 3726 + val t_jsont : t Jsont.t 3727 + end 3728 + 3729 + module UserUpdateMeDto : sig 3730 + type t = { 3731 + avatar_color : Jsont.json option; 3732 + email : string option; 3733 + name : string option; 3734 + password : string option; 3735 + } 3736 + 3737 + val t_jsont : t Jsont.t 3738 + end 3739 + 3740 + module SyncUserMetadataDeleteV1 : sig 3741 + type t = { 3742 + key : Jsont.json; 3743 + user_id : string; 3744 + } 3745 + 3746 + val t_jsont : t Jsont.t 3747 + end 3748 + 3749 + module SyncUserMetadataV1 : sig 3750 + type t = { 3751 + key : Jsont.json; 3752 + user_id : string; 3753 + value : Jsont.json; 3754 + } 3755 + 3756 + val t_jsont : t Jsont.t 3757 + end 3758 + 3759 + module UserAdminResponseDto : sig 3760 + type t = { 3761 + avatar_color : Jsont.json; 3762 + created_at : Ptime.t; 3763 + deleted_at : Ptime.t; 3764 + email : string; 3765 + id : string; 3766 + is_admin : bool; 3767 + license : Jsont.json option; 3768 + name : string; 3769 + oauth_id : string; 3770 + profile_changed_at : Ptime.t; 3771 + profile_image_path : string; 3772 + quota_size_in_bytes : int64; 3773 + quota_usage_in_bytes : int64; 3774 + should_change_password : bool; 3775 + status : Jsont.json; 3776 + storage_label : string; 3777 + updated_at : Ptime.t; 3778 + } 3779 + 3780 + val t_jsont : t Jsont.t 3781 + end 3782 + 3783 + module ValidateLibraryResponseDto : sig 3784 + type t = { 3785 + import_paths : ValidateLibraryImportPathResponseDto.t list option; 3786 + } 3787 + 3788 + val t_jsont : t Jsont.t 3789 + end 3790 + 3791 + module SystemConfigFfmpegDto : sig 3792 + type t = { 3793 + accel : Jsont.json; 3794 + accel_decode : bool; 3795 + accepted_audio_codecs : AudioCodec.t list; 3796 + accepted_containers : VideoContainer.t list; 3797 + accepted_video_codecs : VideoCodec.t list; 3798 + bframes : int; 3799 + cq_mode : Jsont.json; 3800 + crf : int; 3801 + gop_size : int; 3802 + max_bitrate : string; 3803 + preferred_hw_device : string; 3804 + preset : string; 3805 + refs : int; 3806 + target_audio_codec : Jsont.json; 3807 + target_resolution : string; 3808 + target_video_codec : Jsont.json; 3809 + temporal_aq : bool; 3810 + threads : int; 3811 + tonemap : Jsont.json; 3812 + transcode : Jsont.json; 3813 + two_pass : bool; 3814 + } 3815 + 3816 + val t_jsont : t Jsont.t 3817 + end 3818 + 3819 + module WorkflowCreateDto : sig 3820 + type t = { 3821 + actions : WorkflowActionItemDto.t list; 3822 + description : string option; 3823 + enabled : bool option; 3824 + filters : WorkflowFilterItemDto.t list; 3825 + name : string; 3826 + trigger_type : Jsont.json; 3827 + } 3828 + 3829 + val t_jsont : t Jsont.t 3830 + end 3831 + 3832 + module WorkflowUpdateDto : sig 3833 + type t = { 3834 + actions : WorkflowActionItemDto.t list option; 3835 + description : string option; 3836 + enabled : bool option; 3837 + filters : WorkflowFilterItemDto.t list option; 3838 + name : string option; 3839 + trigger_type : Jsont.json option; 3840 + } 3841 + 3842 + val t_jsont : t Jsont.t 3843 + end 3844 + 3845 + module WorkflowResponseDto : sig 3846 + type t = { 3847 + actions : WorkflowActionResponseDto.t list; 3848 + created_at : string; 3849 + description : string; 3850 + enabled : bool; 3851 + filters : WorkflowFilterResponseDto.t list; 3852 + id : string; 3853 + name : string; 3854 + owner_id : string; 3855 + trigger_type : Jsont.json; 3856 + } 3857 + 3858 + val t_jsont : t Jsont.t 3859 + end 3860 + 3861 + module AddUsersDto : sig 3862 + type t = { 3863 + album_users : AlbumUserAddDto.t list; 3864 + } 3865 + 3866 + val t_jsont : t Jsont.t 3867 + end 3868 + 3869 + module CreateAlbumDto : sig 3870 + type t = { 3871 + album_name : string; 3872 + album_users : AlbumUserCreateDto.t list option; 3873 + asset_ids : string list option; 3874 + description : string option; 3875 + } 3876 + 3877 + val t_jsont : t Jsont.t 3878 + end 3879 + 3880 + module UserPreferencesResponseDto : sig 3881 + type t = { 3882 + albums : AlbumsResponse.t; 3883 + cast : CastResponse.t; 3884 + download : DownloadResponse.t; 3885 + email_notifications : EmailNotificationsResponse.t; 3886 + folders : FoldersResponse.t; 3887 + memories : MemoriesResponse.t; 3888 + people : PeopleResponse.t; 3889 + purchase : PurchaseResponse.t; 3890 + ratings : RatingsResponse.t; 3891 + shared_links : SharedLinksResponse.t; 3892 + tags : TagsResponse.t; 3893 + } 3894 + 3895 + val t_jsont : t Jsont.t 3896 + end 3897 + 3898 + module SystemConfigImageDto : sig 3899 + type t = { 3900 + colorspace : Jsont.json; 3901 + extract_embedded : bool; 3902 + fullsize : SystemConfigGeneratedFullsizeImageDto.t; 3903 + preview : SystemConfigGeneratedImageDto.t; 3904 + thumbnail : SystemConfigGeneratedImageDto.t; 3905 + } 3906 + 3907 + val t_jsont : t Jsont.t 3908 + end 3909 + 3910 + module AssetEditActionMirror : sig 3911 + type t = { 3912 + action : Jsont.json; 3913 + parameters : MirrorParameters.t; 3914 + } 3915 + 3916 + val t_jsont : t Jsont.t 3917 + end 3918 + 3919 + module ApikeyCreateResponseDto : sig 3920 + type t = { 3921 + api_key : ApikeyResponseDto.t; 3922 + secret : string; 3923 + } 3924 + 3925 + val t_jsont : t Jsont.t 3926 + end 3927 + 3928 + module PluginResponseDto : sig 3929 + type t = { 3930 + actions : PluginActionResponseDto.t list; 3931 + author : string; 3932 + created_at : string; 3933 + description : string; 3934 + filters : PluginFilterResponseDto.t list; 3935 + id : string; 3936 + name : string; 3937 + title : string; 3938 + updated_at : string; 3939 + version : string; 3940 + } 3941 + 3942 + val t_jsont : t Jsont.t 3943 + end 3944 + 3945 + module QueuesResponseLegacyDto : sig 3946 + type t = { 3947 + background_task : QueueResponseLegacyDto.t; 3948 + backup_database : QueueResponseLegacyDto.t; 3949 + duplicate_detection : QueueResponseLegacyDto.t; 3950 + editor : QueueResponseLegacyDto.t; 3951 + face_detection : QueueResponseLegacyDto.t; 3952 + facial_recognition : QueueResponseLegacyDto.t; 3953 + library : QueueResponseLegacyDto.t; 3954 + metadata_extraction : QueueResponseLegacyDto.t; 3955 + migration : QueueResponseLegacyDto.t; 3956 + notifications : QueueResponseLegacyDto.t; 3957 + ocr : QueueResponseLegacyDto.t; 3958 + search : QueueResponseLegacyDto.t; 3959 + sidecar : QueueResponseLegacyDto.t; 3960 + smart_search : QueueResponseLegacyDto.t; 3961 + storage_template_migration : QueueResponseLegacyDto.t; 3962 + thumbnail_generation : QueueResponseLegacyDto.t; 3963 + video_conversion : QueueResponseLegacyDto.t; 3964 + workflow : QueueResponseLegacyDto.t; 3965 + } 3966 + 3967 + val t_jsont : t Jsont.t 3968 + end 3969 + 3970 + module PersonWithFacesResponseDto : sig 3971 + type t = { 3972 + birth_date : string; 3973 + color : string option; 3974 + faces : AssetFaceWithoutPersonResponseDto.t list; 3975 + id : string; 3976 + is_favorite : bool option; 3977 + is_hidden : bool; 3978 + name : string; 3979 + thumbnail_path : string; 3980 + updated_at : Ptime.t option; 3981 + } 3982 + 3983 + val t_jsont : t Jsont.t 3984 + end 3985 + 3986 + module MaintenanceDetectInstallResponseDto : sig 3987 + type t = { 3988 + storage : MaintenanceDetectInstallStorageFolderDto.t list; 3989 + } 3990 + 3991 + val t_jsont : t Jsont.t 3992 + end 3993 + 3994 + module SystemConfigNotificationsDto : sig 3995 + type t = { 3996 + smtp : SystemConfigSmtpDto.t; 3997 + } 3998 + 3999 + val t_jsont : t Jsont.t 4000 + end 4001 + 4002 + module UserPreferencesUpdateDto : sig 4003 + type t = { 4004 + albums : AlbumsUpdate.t option; 4005 + avatar : AvatarUpdate.t option; 4006 + cast : CastUpdate.t option; 4007 + download : DownloadUpdate.t option; 4008 + email_notifications : EmailNotificationsUpdate.t option; 4009 + folders : FoldersUpdate.t option; 4010 + memories : MemoriesUpdate.t option; 4011 + people : PeopleUpdate.t option; 4012 + purchase : PurchaseUpdate.t option; 4013 + ratings : RatingsUpdate.t option; 4014 + shared_links : SharedLinksUpdate.t option; 4015 + tags : TagsUpdate.t option; 4016 + } 4017 + 4018 + val t_jsont : t Jsont.t 4019 + end 4020 + 4021 + module ActivityResponseDto : sig 4022 + type t = { 4023 + asset_id : string; 4024 + comment : string option; 4025 + created_at : Ptime.t; 4026 + id : string; 4027 + type_ : Jsont.json; 4028 + user : UserResponseDto.t; 4029 + } 4030 + 4031 + val t_jsont : t Jsont.t 4032 + end 4033 + 4034 + module AlbumUserResponseDto : sig 4035 + type t = { 4036 + role : Jsont.json; 4037 + user : UserResponseDto.t; 4038 + } 4039 + 4040 + val t_jsont : t Jsont.t 4041 + end 4042 + 4043 + module AssetEditActionListDto : sig 4044 + type t = { 4045 + edits : Jsont.json list; (** list of edits *) 4046 + } 4047 + 4048 + val t_jsont : t Jsont.t 4049 + end 4050 + 4051 + module AssetEditsDto : sig 4052 + type t = { 4053 + asset_id : string; 4054 + edits : Jsont.json list; (** list of edits *) 4055 + } 4056 + 4057 + val t_jsont : t Jsont.t 4058 + end 4059 + 4060 + module AssetResponseDto : sig 4061 + type t = { 4062 + checksum : string; (** base64 encoded sha1 hash *) 4063 + created_at : Ptime.t; (** The UTC timestamp when the asset was originally uploaded to Immich. *) 4064 + device_asset_id : string; 4065 + device_id : string; 4066 + duplicate_id : string option; 4067 + duration : string; 4068 + exif_info : ExifResponseDto.t option; 4069 + file_created_at : Ptime.t; (** The actual UTC timestamp when the file was created/captured, preserving timezone information. This is the authoritative timestamp for chronological sorting within timeline groups. Combined with timezone data, this can be used to determine the exact moment the photo was taken. *) 4070 + file_modified_at : Ptime.t; (** The UTC timestamp when the file was last modified on the filesystem. This reflects the last time the physical file was changed, which may be different from when the photo was originally taken. *) 4071 + has_metadata : bool; 4072 + height : float; 4073 + id : string; 4074 + is_archived : bool; 4075 + is_edited : bool; 4076 + is_favorite : bool; 4077 + is_offline : bool; 4078 + is_trashed : bool; 4079 + library_id : string option; 4080 + live_photo_video_id : string option; 4081 + local_date_time : Ptime.t; (** The local date and time when the photo/video was taken, derived from EXIF metadata. This represents the photographer's local time regardless of timezone, stored as a timezone-agnostic timestamp. Used for timeline grouping by "local" days and months. *) 4082 + original_file_name : string; 4083 + original_mime_type : string option; 4084 + original_path : string; 4085 + owner : UserResponseDto.t option; 4086 + owner_id : string; 4087 + people : PersonWithFacesResponseDto.t list option; 4088 + resized : bool option; 4089 + stack : Jsont.json option; 4090 + tags : TagResponseDto.t list option; 4091 + thumbhash : string; 4092 + type_ : Jsont.json; 4093 + unassigned_faces : AssetFaceWithoutPersonResponseDto.t list option; 4094 + updated_at : Ptime.t; (** The UTC timestamp when the asset record was last updated in the database. This is automatically maintained by the database and reflects when any field in the asset was last modified. *) 4095 + visibility : Jsont.json; 4096 + width : float; 4097 + } 4098 + 4099 + val t_jsont : t Jsont.t 4100 + end 4101 + 4102 + module SystemConfigDto : sig 4103 + type t = { 4104 + backup : SystemConfigBackupsDto.t; 4105 + ffmpeg : SystemConfigFfmpegDto.t; 4106 + image : SystemConfigImageDto.t; 4107 + job : SystemConfigJobDto.t; 4108 + library : SystemConfigLibraryDto.t; 4109 + logging : SystemConfigLoggingDto.t; 4110 + machine_learning : SystemConfigMachineLearningDto.t; 4111 + map : SystemConfigMapDto.t; 4112 + metadata : SystemConfigMetadataDto.t; 4113 + new_version_check : SystemConfigNewVersionCheckDto.t; 4114 + nightly_tasks : SystemConfigNightlyTasksDto.t; 4115 + notifications : SystemConfigNotificationsDto.t; 4116 + oauth : SystemConfigOauthDto.t; 4117 + password_login : SystemConfigPasswordLoginDto.t; 4118 + reverse_geocoding : SystemConfigReverseGeocodingDto.t; 4119 + server : SystemConfigServerDto.t; 4120 + storage_template : SystemConfigStorageTemplateDto.t; 4121 + templates : SystemConfigTemplatesDto.t; 4122 + theme : SystemConfigThemeDto.t; 4123 + trash : SystemConfigTrashDto.t; 4124 + user : SystemConfigUserDto.t; 4125 + } 4126 + 4127 + val t_jsont : t Jsont.t 4128 + end 4129 + 4130 + module AlbumResponseDto : sig 4131 + type t = { 4132 + album_name : string; 4133 + album_thumbnail_asset_id : string; 4134 + album_users : AlbumUserResponseDto.t list; 4135 + asset_count : int; 4136 + assets : AssetResponseDto.t list; 4137 + contributor_counts : ContributorCountResponseDto.t list option; 4138 + created_at : Ptime.t; 4139 + description : string; 4140 + end_date : Ptime.t option; 4141 + has_shared_link : bool; 4142 + id : string; 4143 + is_activity_enabled : bool; 4144 + last_modified_asset_timestamp : Ptime.t option; 4145 + order : Jsont.json option; 4146 + owner : UserResponseDto.t; 4147 + owner_id : string; 4148 + shared : bool; 4149 + start_date : Ptime.t option; 4150 + updated_at : Ptime.t; 4151 + } 4152 + 4153 + val t_jsont : t Jsont.t 4154 + end 4155 + 4156 + module AssetDeltaSyncResponseDto : sig 4157 + type t = { 4158 + deleted : string list; 4159 + needs_full_sync : bool; 4160 + upserted : AssetResponseDto.t list; 4161 + } 4162 + 4163 + val t_jsont : t Jsont.t 4164 + end 4165 + 4166 + module DuplicateResponseDto : sig 4167 + type t = { 4168 + assets : AssetResponseDto.t list; 4169 + duplicate_id : string; 4170 + } 4171 + 4172 + val t_jsont : t Jsont.t 4173 + end 4174 + 4175 + module MemoryResponseDto : sig 4176 + type t = { 4177 + assets : AssetResponseDto.t list; 4178 + created_at : Ptime.t; 4179 + data : OnThisDayDto.t; 4180 + deleted_at : Ptime.t option; 4181 + hide_at : Ptime.t option; 4182 + id : string; 4183 + is_saved : bool; 4184 + memory_at : Ptime.t; 4185 + owner_id : string; 4186 + seen_at : Ptime.t option; 4187 + show_at : Ptime.t option; 4188 + type_ : Jsont.json; 4189 + updated_at : Ptime.t; 4190 + } 4191 + 4192 + val t_jsont : t Jsont.t 4193 + end 4194 + 4195 + module SearchAssetResponseDto : sig 4196 + type t = { 4197 + count : int; 4198 + facets : SearchFacetResponseDto.t list; 4199 + items : AssetResponseDto.t list; 4200 + next_page : string; 4201 + total : int; 4202 + } 4203 + 4204 + val t_jsont : t Jsont.t 4205 + end 4206 + 4207 + module SearchExploreItem : sig 4208 + type t = { 4209 + data : AssetResponseDto.t; 4210 + value : string; 4211 + } 4212 + 4213 + val t_jsont : t Jsont.t 4214 + end 4215 + 4216 + module StackResponseDto : sig 4217 + type t = { 4218 + assets : AssetResponseDto.t list; 4219 + id : string; 4220 + primary_asset_id : string; 4221 + } 4222 + 4223 + val t_jsont : t Jsont.t 4224 + end 4225 + 4226 + module SearchAlbumResponseDto : sig 4227 + type t = { 4228 + count : int; 4229 + facets : SearchFacetResponseDto.t list; 4230 + items : AlbumResponseDto.t list; 4231 + total : int; 4232 + } 4233 + 4234 + val t_jsont : t Jsont.t 4235 + end 4236 + 4237 + module SharedLinkResponseDto : sig 4238 + type t = { 4239 + album : AlbumResponseDto.t option; 4240 + allow_download : bool; 4241 + allow_upload : bool; 4242 + assets : AssetResponseDto.t list; 4243 + created_at : Ptime.t; 4244 + description : string; 4245 + expires_at : Ptime.t; 4246 + id : string; 4247 + key : string; 4248 + password : string; 4249 + show_metadata : bool; 4250 + slug : string; 4251 + token : string option; 4252 + type_ : Jsont.json; 4253 + user_id : string; 4254 + } 4255 + 4256 + val t_jsont : t Jsont.t 4257 + end 4258 + 4259 + module SearchExploreResponseDto : sig 4260 + type t = { 4261 + field_name : string; 4262 + items : SearchExploreItem.t list; 4263 + } 4264 + 4265 + val t_jsont : t Jsont.t 4266 + end 4267 + 4268 + module SearchResponseDto : sig 4269 + type t = { 4270 + albums : SearchAlbumResponseDto.t; 4271 + assets : SearchAssetResponseDto.t; 4272 + } 4273 + 4274 + val t_jsont : t Jsont.t 4275 + end