mirror of
https://github.com/immich-app/immich.git
synced 2026-05-18 03:10:24 +03:00
Merge branch 'main' into feat/search-filter-album/web
This commit is contained in:
Generated
+15
-1
@@ -34,6 +34,7 @@ part 'api/api_keys_api.dart';
|
||||
part 'api/activities_api.dart';
|
||||
part 'api/albums_api.dart';
|
||||
part 'api/assets_api.dart';
|
||||
part 'api/auth_admin_api.dart';
|
||||
part 'api/authentication_api.dart';
|
||||
part 'api/deprecated_api.dart';
|
||||
part 'api/download_api.dart';
|
||||
@@ -78,6 +79,8 @@ part 'model/album_user_add_dto.dart';
|
||||
part 'model/album_user_create_dto.dart';
|
||||
part 'model/album_user_response_dto.dart';
|
||||
part 'model/album_user_role.dart';
|
||||
part 'model/albums_add_assets_dto.dart';
|
||||
part 'model/albums_add_assets_response_dto.dart';
|
||||
part 'model/albums_response.dart';
|
||||
part 'model/albums_update.dart';
|
||||
part 'model/all_job_status_response_dto.dart';
|
||||
@@ -103,6 +106,10 @@ part 'model/asset_jobs_dto.dart';
|
||||
part 'model/asset_media_response_dto.dart';
|
||||
part 'model/asset_media_size.dart';
|
||||
part 'model/asset_media_status.dart';
|
||||
part 'model/asset_metadata_key.dart';
|
||||
part 'model/asset_metadata_response_dto.dart';
|
||||
part 'model/asset_metadata_upsert_dto.dart';
|
||||
part 'model/asset_metadata_upsert_item_dto.dart';
|
||||
part 'model/asset_order.dart';
|
||||
part 'model/asset_response_dto.dart';
|
||||
part 'model/asset_stack_response_dto.dart';
|
||||
@@ -112,6 +119,7 @@ part 'model/asset_visibility.dart';
|
||||
part 'model/audio_codec.dart';
|
||||
part 'model/auth_status_response_dto.dart';
|
||||
part 'model/avatar_update.dart';
|
||||
part 'model/bulk_id_error_reason.dart';
|
||||
part 'model/bulk_id_response_dto.dart';
|
||||
part 'model/bulk_ids_dto.dart';
|
||||
part 'model/clip_config.dart';
|
||||
@@ -156,6 +164,7 @@ part 'model/log_level.dart';
|
||||
part 'model/login_credential_dto.dart';
|
||||
part 'model/login_response_dto.dart';
|
||||
part 'model/logout_response_dto.dart';
|
||||
part 'model/machine_learning_availability_checks_dto.dart';
|
||||
part 'model/manual_job_name.dart';
|
||||
part 'model/map_marker_response_dto.dart';
|
||||
part 'model/map_reverse_geocode_response_dto.dart';
|
||||
@@ -182,8 +191,10 @@ part 'model/o_auth_token_endpoint_auth_method.dart';
|
||||
part 'model/on_this_day_dto.dart';
|
||||
part 'model/onboarding_dto.dart';
|
||||
part 'model/onboarding_response_dto.dart';
|
||||
part 'model/partner_create_dto.dart';
|
||||
part 'model/partner_direction.dart';
|
||||
part 'model/partner_response_dto.dart';
|
||||
part 'model/partner_update_dto.dart';
|
||||
part 'model/people_response.dart';
|
||||
part 'model/people_response_dto.dart';
|
||||
part 'model/people_update.dart';
|
||||
@@ -259,7 +270,10 @@ part 'model/sync_asset_delete_v1.dart';
|
||||
part 'model/sync_asset_exif_v1.dart';
|
||||
part 'model/sync_asset_face_delete_v1.dart';
|
||||
part 'model/sync_asset_face_v1.dart';
|
||||
part 'model/sync_asset_metadata_delete_v1.dart';
|
||||
part 'model/sync_asset_metadata_v1.dart';
|
||||
part 'model/sync_asset_v1.dart';
|
||||
part 'model/sync_auth_user_v1.dart';
|
||||
part 'model/sync_entity_type.dart';
|
||||
part 'model/sync_memory_asset_delete_v1.dart';
|
||||
part 'model/sync_memory_asset_v1.dart';
|
||||
@@ -329,7 +343,6 @@ part 'model/update_album_dto.dart';
|
||||
part 'model/update_album_user_dto.dart';
|
||||
part 'model/update_asset_dto.dart';
|
||||
part 'model/update_library_dto.dart';
|
||||
part 'model/update_partner_dto.dart';
|
||||
part 'model/usage_by_user_dto.dart';
|
||||
part 'model/user_admin_create_dto.dart';
|
||||
part 'model/user_admin_delete_dto.dart';
|
||||
@@ -337,6 +350,7 @@ part 'model/user_admin_response_dto.dart';
|
||||
part 'model/user_admin_update_dto.dart';
|
||||
part 'model/user_avatar_color.dart';
|
||||
part 'model/user_license.dart';
|
||||
part 'model/user_metadata_key.dart';
|
||||
part 'model/user_preferences_response_dto.dart';
|
||||
part 'model/user_preferences_update_dto.dart';
|
||||
part 'model/user_response_dto.dart';
|
||||
|
||||
+24
-4
@@ -16,7 +16,10 @@ class ActivitiesApi {
|
||||
|
||||
final ApiClient apiClient;
|
||||
|
||||
/// Performs an HTTP 'POST /activities' operation and returns the [Response].
|
||||
/// This endpoint requires the `activity.create` permission.
|
||||
///
|
||||
/// Note: This method returns the HTTP [Response].
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [ActivityCreateDto] activityCreateDto (required):
|
||||
@@ -45,6 +48,8 @@ class ActivitiesApi {
|
||||
);
|
||||
}
|
||||
|
||||
/// This endpoint requires the `activity.create` permission.
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [ActivityCreateDto] activityCreateDto (required):
|
||||
@@ -63,7 +68,10 @@ class ActivitiesApi {
|
||||
return null;
|
||||
}
|
||||
|
||||
/// Performs an HTTP 'DELETE /activities/{id}' operation and returns the [Response].
|
||||
/// This endpoint requires the `activity.delete` permission.
|
||||
///
|
||||
/// Note: This method returns the HTTP [Response].
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [String] id (required):
|
||||
@@ -93,6 +101,8 @@ class ActivitiesApi {
|
||||
);
|
||||
}
|
||||
|
||||
/// This endpoint requires the `activity.delete` permission.
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [String] id (required):
|
||||
@@ -103,7 +113,10 @@ class ActivitiesApi {
|
||||
}
|
||||
}
|
||||
|
||||
/// Performs an HTTP 'GET /activities' operation and returns the [Response].
|
||||
/// This endpoint requires the `activity.read` permission.
|
||||
///
|
||||
/// Note: This method returns the HTTP [Response].
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [String] albumId (required):
|
||||
@@ -154,6 +167,8 @@ class ActivitiesApi {
|
||||
);
|
||||
}
|
||||
|
||||
/// This endpoint requires the `activity.read` permission.
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [String] albumId (required):
|
||||
@@ -183,7 +198,10 @@ class ActivitiesApi {
|
||||
return null;
|
||||
}
|
||||
|
||||
/// Performs an HTTP 'GET /activities/statistics' operation and returns the [Response].
|
||||
/// This endpoint requires the `activity.statistics` permission.
|
||||
///
|
||||
/// Note: This method returns the HTTP [Response].
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [String] albumId (required):
|
||||
@@ -219,6 +237,8 @@ class ActivitiesApi {
|
||||
);
|
||||
}
|
||||
|
||||
/// This endpoint requires the `activity.statistics` permission.
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [String] albumId (required):
|
||||
|
||||
Generated
+69
-5
@@ -16,7 +16,10 @@ class APIKeysApi {
|
||||
|
||||
final ApiClient apiClient;
|
||||
|
||||
/// Performs an HTTP 'POST /api-keys' operation and returns the [Response].
|
||||
/// This endpoint requires the `apiKey.create` permission.
|
||||
///
|
||||
/// Note: This method returns the HTTP [Response].
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [APIKeyCreateDto] aPIKeyCreateDto (required):
|
||||
@@ -45,6 +48,8 @@ class APIKeysApi {
|
||||
);
|
||||
}
|
||||
|
||||
/// This endpoint requires the `apiKey.create` permission.
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [APIKeyCreateDto] aPIKeyCreateDto (required):
|
||||
@@ -63,7 +68,10 @@ class APIKeysApi {
|
||||
return null;
|
||||
}
|
||||
|
||||
/// Performs an HTTP 'DELETE /api-keys/{id}' operation and returns the [Response].
|
||||
/// This endpoint requires the `apiKey.delete` permission.
|
||||
///
|
||||
/// Note: This method returns the HTTP [Response].
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [String] id (required):
|
||||
@@ -93,6 +101,8 @@ class APIKeysApi {
|
||||
);
|
||||
}
|
||||
|
||||
/// This endpoint requires the `apiKey.delete` permission.
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [String] id (required):
|
||||
@@ -103,7 +113,10 @@ class APIKeysApi {
|
||||
}
|
||||
}
|
||||
|
||||
/// Performs an HTTP 'GET /api-keys/{id}' operation and returns the [Response].
|
||||
/// This endpoint requires the `apiKey.read` permission.
|
||||
///
|
||||
/// Note: This method returns the HTTP [Response].
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [String] id (required):
|
||||
@@ -133,6 +146,8 @@ class APIKeysApi {
|
||||
);
|
||||
}
|
||||
|
||||
/// This endpoint requires the `apiKey.read` permission.
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [String] id (required):
|
||||
@@ -151,7 +166,9 @@ class APIKeysApi {
|
||||
return null;
|
||||
}
|
||||
|
||||
/// Performs an HTTP 'GET /api-keys' operation and returns the [Response].
|
||||
/// This endpoint requires the `apiKey.read` permission.
|
||||
///
|
||||
/// Note: This method returns the HTTP [Response].
|
||||
Future<Response> getApiKeysWithHttpInfo() async {
|
||||
// ignore: prefer_const_declarations
|
||||
final apiPath = r'/api-keys';
|
||||
@@ -177,6 +194,7 @@ class APIKeysApi {
|
||||
);
|
||||
}
|
||||
|
||||
/// This endpoint requires the `apiKey.read` permission.
|
||||
Future<List<APIKeyResponseDto>?> getApiKeys() async {
|
||||
final response = await getApiKeysWithHttpInfo();
|
||||
if (response.statusCode >= HttpStatus.badRequest) {
|
||||
@@ -195,7 +213,51 @@ class APIKeysApi {
|
||||
return null;
|
||||
}
|
||||
|
||||
/// Performs an HTTP 'PUT /api-keys/{id}' operation and returns the [Response].
|
||||
/// Performs an HTTP 'GET /api-keys/me' operation and returns the [Response].
|
||||
Future<Response> getMyApiKeyWithHttpInfo() async {
|
||||
// ignore: prefer_const_declarations
|
||||
final apiPath = r'/api-keys/me';
|
||||
|
||||
// ignore: prefer_final_locals
|
||||
Object? postBody;
|
||||
|
||||
final queryParams = <QueryParam>[];
|
||||
final headerParams = <String, String>{};
|
||||
final formParams = <String, String>{};
|
||||
|
||||
const contentTypes = <String>[];
|
||||
|
||||
|
||||
return apiClient.invokeAPI(
|
||||
apiPath,
|
||||
'GET',
|
||||
queryParams,
|
||||
postBody,
|
||||
headerParams,
|
||||
formParams,
|
||||
contentTypes.isEmpty ? null : contentTypes.first,
|
||||
);
|
||||
}
|
||||
|
||||
Future<APIKeyResponseDto?> getMyApiKey() async {
|
||||
final response = await getMyApiKeyWithHttpInfo();
|
||||
if (response.statusCode >= HttpStatus.badRequest) {
|
||||
throw ApiException(response.statusCode, await _decodeBodyBytes(response));
|
||||
}
|
||||
// When a remote server returns no body with a status of 204, we shall not decode it.
|
||||
// At the time of writing this, `dart:convert` will throw an "Unexpected end of input"
|
||||
// FormatException when trying to decode an empty string.
|
||||
if (response.body.isNotEmpty && response.statusCode != HttpStatus.noContent) {
|
||||
return await apiClient.deserializeAsync(await _decodeBodyBytes(response), 'APIKeyResponseDto',) as APIKeyResponseDto;
|
||||
|
||||
}
|
||||
return null;
|
||||
}
|
||||
|
||||
/// This endpoint requires the `apiKey.update` permission.
|
||||
///
|
||||
/// Note: This method returns the HTTP [Response].
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [String] id (required):
|
||||
@@ -227,6 +289,8 @@ class APIKeysApi {
|
||||
);
|
||||
}
|
||||
|
||||
/// This endpoint requires the `apiKey.update` permission.
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [String] id (required):
|
||||
|
||||
Generated
+354
-35
@@ -18,7 +18,7 @@ class AssetsApi {
|
||||
|
||||
/// checkBulkUpload
|
||||
///
|
||||
/// Checks if assets exist by checksums
|
||||
/// Checks if assets exist by checksums. This endpoint requires the `asset.upload` permission.
|
||||
///
|
||||
/// Note: This method returns the HTTP [Response].
|
||||
///
|
||||
@@ -52,7 +52,7 @@ class AssetsApi {
|
||||
|
||||
/// checkBulkUpload
|
||||
///
|
||||
/// Checks if assets exist by checksums
|
||||
/// Checks if assets exist by checksums. This endpoint requires the `asset.upload` permission.
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
@@ -128,7 +128,60 @@ class AssetsApi {
|
||||
return null;
|
||||
}
|
||||
|
||||
/// Performs an HTTP 'DELETE /assets' operation and returns the [Response].
|
||||
/// This endpoint requires the `asset.update` permission.
|
||||
///
|
||||
/// Note: This method returns the HTTP [Response].
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [String] id (required):
|
||||
///
|
||||
/// * [AssetMetadataKey] key (required):
|
||||
Future<Response> deleteAssetMetadataWithHttpInfo(String id, AssetMetadataKey key,) async {
|
||||
// ignore: prefer_const_declarations
|
||||
final apiPath = r'/assets/{id}/metadata/{key}'
|
||||
.replaceAll('{id}', id)
|
||||
.replaceAll('{key}', key.toString());
|
||||
|
||||
// ignore: prefer_final_locals
|
||||
Object? postBody;
|
||||
|
||||
final queryParams = <QueryParam>[];
|
||||
final headerParams = <String, String>{};
|
||||
final formParams = <String, String>{};
|
||||
|
||||
const contentTypes = <String>[];
|
||||
|
||||
|
||||
return apiClient.invokeAPI(
|
||||
apiPath,
|
||||
'DELETE',
|
||||
queryParams,
|
||||
postBody,
|
||||
headerParams,
|
||||
formParams,
|
||||
contentTypes.isEmpty ? null : contentTypes.first,
|
||||
);
|
||||
}
|
||||
|
||||
/// This endpoint requires the `asset.update` permission.
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [String] id (required):
|
||||
///
|
||||
/// * [AssetMetadataKey] key (required):
|
||||
Future<void> deleteAssetMetadata(String id, AssetMetadataKey key,) async {
|
||||
final response = await deleteAssetMetadataWithHttpInfo(id, key,);
|
||||
if (response.statusCode >= HttpStatus.badRequest) {
|
||||
throw ApiException(response.statusCode, await _decodeBodyBytes(response));
|
||||
}
|
||||
}
|
||||
|
||||
/// This endpoint requires the `asset.delete` permission.
|
||||
///
|
||||
/// Note: This method returns the HTTP [Response].
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [AssetBulkDeleteDto] assetBulkDeleteDto (required):
|
||||
@@ -157,6 +210,8 @@ class AssetsApi {
|
||||
);
|
||||
}
|
||||
|
||||
/// This endpoint requires the `asset.delete` permission.
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [AssetBulkDeleteDto] assetBulkDeleteDto (required):
|
||||
@@ -167,13 +222,18 @@ class AssetsApi {
|
||||
}
|
||||
}
|
||||
|
||||
/// Performs an HTTP 'GET /assets/{id}/original' operation and returns the [Response].
|
||||
/// This endpoint requires the `asset.download` permission.
|
||||
///
|
||||
/// Note: This method returns the HTTP [Response].
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [String] id (required):
|
||||
///
|
||||
/// * [String] key:
|
||||
Future<Response> downloadAssetWithHttpInfo(String id, { String? key, }) async {
|
||||
///
|
||||
/// * [String] slug:
|
||||
Future<Response> downloadAssetWithHttpInfo(String id, { String? key, String? slug, }) async {
|
||||
// ignore: prefer_const_declarations
|
||||
final apiPath = r'/assets/{id}/original'
|
||||
.replaceAll('{id}', id);
|
||||
@@ -188,6 +248,9 @@ class AssetsApi {
|
||||
if (key != null) {
|
||||
queryParams.addAll(_queryParams('', 'key', key));
|
||||
}
|
||||
if (slug != null) {
|
||||
queryParams.addAll(_queryParams('', 'slug', slug));
|
||||
}
|
||||
|
||||
const contentTypes = <String>[];
|
||||
|
||||
@@ -203,13 +266,17 @@ class AssetsApi {
|
||||
);
|
||||
}
|
||||
|
||||
/// This endpoint requires the `asset.download` permission.
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [String] id (required):
|
||||
///
|
||||
/// * [String] key:
|
||||
Future<MultipartFile?> downloadAsset(String id, { String? key, }) async {
|
||||
final response = await downloadAssetWithHttpInfo(id, key: key, );
|
||||
///
|
||||
/// * [String] slug:
|
||||
Future<MultipartFile?> downloadAsset(String id, { String? key, String? slug, }) async {
|
||||
final response = await downloadAssetWithHttpInfo(id, key: key, slug: slug, );
|
||||
if (response.statusCode >= HttpStatus.badRequest) {
|
||||
throw ApiException(response.statusCode, await _decodeBodyBytes(response));
|
||||
}
|
||||
@@ -283,13 +350,18 @@ class AssetsApi {
|
||||
return null;
|
||||
}
|
||||
|
||||
/// Performs an HTTP 'GET /assets/{id}' operation and returns the [Response].
|
||||
/// This endpoint requires the `asset.read` permission.
|
||||
///
|
||||
/// Note: This method returns the HTTP [Response].
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [String] id (required):
|
||||
///
|
||||
/// * [String] key:
|
||||
Future<Response> getAssetInfoWithHttpInfo(String id, { String? key, }) async {
|
||||
///
|
||||
/// * [String] slug:
|
||||
Future<Response> getAssetInfoWithHttpInfo(String id, { String? key, String? slug, }) async {
|
||||
// ignore: prefer_const_declarations
|
||||
final apiPath = r'/assets/{id}'
|
||||
.replaceAll('{id}', id);
|
||||
@@ -304,6 +376,9 @@ class AssetsApi {
|
||||
if (key != null) {
|
||||
queryParams.addAll(_queryParams('', 'key', key));
|
||||
}
|
||||
if (slug != null) {
|
||||
queryParams.addAll(_queryParams('', 'slug', slug));
|
||||
}
|
||||
|
||||
const contentTypes = <String>[];
|
||||
|
||||
@@ -319,13 +394,17 @@ class AssetsApi {
|
||||
);
|
||||
}
|
||||
|
||||
/// This endpoint requires the `asset.read` permission.
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [String] id (required):
|
||||
///
|
||||
/// * [String] key:
|
||||
Future<AssetResponseDto?> getAssetInfo(String id, { String? key, }) async {
|
||||
final response = await getAssetInfoWithHttpInfo(id, key: key, );
|
||||
///
|
||||
/// * [String] slug:
|
||||
Future<AssetResponseDto?> getAssetInfo(String id, { String? key, String? slug, }) async {
|
||||
final response = await getAssetInfoWithHttpInfo(id, key: key, slug: slug, );
|
||||
if (response.statusCode >= HttpStatus.badRequest) {
|
||||
throw ApiException(response.statusCode, await _decodeBodyBytes(response));
|
||||
}
|
||||
@@ -339,7 +418,124 @@ class AssetsApi {
|
||||
return null;
|
||||
}
|
||||
|
||||
/// Performs an HTTP 'GET /assets/statistics' operation and returns the [Response].
|
||||
/// This endpoint requires the `asset.read` permission.
|
||||
///
|
||||
/// Note: This method returns the HTTP [Response].
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [String] id (required):
|
||||
Future<Response> getAssetMetadataWithHttpInfo(String id,) async {
|
||||
// ignore: prefer_const_declarations
|
||||
final apiPath = r'/assets/{id}/metadata'
|
||||
.replaceAll('{id}', id);
|
||||
|
||||
// ignore: prefer_final_locals
|
||||
Object? postBody;
|
||||
|
||||
final queryParams = <QueryParam>[];
|
||||
final headerParams = <String, String>{};
|
||||
final formParams = <String, String>{};
|
||||
|
||||
const contentTypes = <String>[];
|
||||
|
||||
|
||||
return apiClient.invokeAPI(
|
||||
apiPath,
|
||||
'GET',
|
||||
queryParams,
|
||||
postBody,
|
||||
headerParams,
|
||||
formParams,
|
||||
contentTypes.isEmpty ? null : contentTypes.first,
|
||||
);
|
||||
}
|
||||
|
||||
/// This endpoint requires the `asset.read` permission.
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [String] id (required):
|
||||
Future<List<AssetMetadataResponseDto>?> getAssetMetadata(String id,) async {
|
||||
final response = await getAssetMetadataWithHttpInfo(id,);
|
||||
if (response.statusCode >= HttpStatus.badRequest) {
|
||||
throw ApiException(response.statusCode, await _decodeBodyBytes(response));
|
||||
}
|
||||
// When a remote server returns no body with a status of 204, we shall not decode it.
|
||||
// At the time of writing this, `dart:convert` will throw an "Unexpected end of input"
|
||||
// FormatException when trying to decode an empty string.
|
||||
if (response.body.isNotEmpty && response.statusCode != HttpStatus.noContent) {
|
||||
final responseBody = await _decodeBodyBytes(response);
|
||||
return (await apiClient.deserializeAsync(responseBody, 'List<AssetMetadataResponseDto>') as List)
|
||||
.cast<AssetMetadataResponseDto>()
|
||||
.toList(growable: false);
|
||||
|
||||
}
|
||||
return null;
|
||||
}
|
||||
|
||||
/// This endpoint requires the `asset.read` permission.
|
||||
///
|
||||
/// Note: This method returns the HTTP [Response].
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [String] id (required):
|
||||
///
|
||||
/// * [AssetMetadataKey] key (required):
|
||||
Future<Response> getAssetMetadataByKeyWithHttpInfo(String id, AssetMetadataKey key,) async {
|
||||
// ignore: prefer_const_declarations
|
||||
final apiPath = r'/assets/{id}/metadata/{key}'
|
||||
.replaceAll('{id}', id)
|
||||
.replaceAll('{key}', key.toString());
|
||||
|
||||
// ignore: prefer_final_locals
|
||||
Object? postBody;
|
||||
|
||||
final queryParams = <QueryParam>[];
|
||||
final headerParams = <String, String>{};
|
||||
final formParams = <String, String>{};
|
||||
|
||||
const contentTypes = <String>[];
|
||||
|
||||
|
||||
return apiClient.invokeAPI(
|
||||
apiPath,
|
||||
'GET',
|
||||
queryParams,
|
||||
postBody,
|
||||
headerParams,
|
||||
formParams,
|
||||
contentTypes.isEmpty ? null : contentTypes.first,
|
||||
);
|
||||
}
|
||||
|
||||
/// This endpoint requires the `asset.read` permission.
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [String] id (required):
|
||||
///
|
||||
/// * [AssetMetadataKey] key (required):
|
||||
Future<AssetMetadataResponseDto?> getAssetMetadataByKey(String id, AssetMetadataKey key,) async {
|
||||
final response = await getAssetMetadataByKeyWithHttpInfo(id, key,);
|
||||
if (response.statusCode >= HttpStatus.badRequest) {
|
||||
throw ApiException(response.statusCode, await _decodeBodyBytes(response));
|
||||
}
|
||||
// When a remote server returns no body with a status of 204, we shall not decode it.
|
||||
// At the time of writing this, `dart:convert` will throw an "Unexpected end of input"
|
||||
// FormatException when trying to decode an empty string.
|
||||
if (response.body.isNotEmpty && response.statusCode != HttpStatus.noContent) {
|
||||
return await apiClient.deserializeAsync(await _decodeBodyBytes(response), 'AssetMetadataResponseDto',) as AssetMetadataResponseDto;
|
||||
|
||||
}
|
||||
return null;
|
||||
}
|
||||
|
||||
/// This endpoint requires the `asset.statistics` permission.
|
||||
///
|
||||
/// Note: This method returns the HTTP [Response].
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [bool] isFavorite:
|
||||
@@ -382,6 +578,8 @@ class AssetsApi {
|
||||
);
|
||||
}
|
||||
|
||||
/// This endpoint requires the `asset.statistics` permission.
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [bool] isFavorite:
|
||||
@@ -404,7 +602,7 @@ class AssetsApi {
|
||||
return null;
|
||||
}
|
||||
|
||||
/// This property was deprecated in v1.116.0
|
||||
/// This property was deprecated in v1.116.0. This endpoint requires the `asset.read` permission.
|
||||
///
|
||||
/// Note: This method returns the HTTP [Response].
|
||||
///
|
||||
@@ -440,7 +638,7 @@ class AssetsApi {
|
||||
);
|
||||
}
|
||||
|
||||
/// This property was deprecated in v1.116.0
|
||||
/// This property was deprecated in v1.116.0. This endpoint requires the `asset.read` permission.
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
@@ -463,13 +661,18 @@ class AssetsApi {
|
||||
return null;
|
||||
}
|
||||
|
||||
/// Performs an HTTP 'GET /assets/{id}/video/playback' operation and returns the [Response].
|
||||
/// This endpoint requires the `asset.view` permission.
|
||||
///
|
||||
/// Note: This method returns the HTTP [Response].
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [String] id (required):
|
||||
///
|
||||
/// * [String] key:
|
||||
Future<Response> playAssetVideoWithHttpInfo(String id, { String? key, }) async {
|
||||
///
|
||||
/// * [String] slug:
|
||||
Future<Response> playAssetVideoWithHttpInfo(String id, { String? key, String? slug, }) async {
|
||||
// ignore: prefer_const_declarations
|
||||
final apiPath = r'/assets/{id}/video/playback'
|
||||
.replaceAll('{id}', id);
|
||||
@@ -484,6 +687,9 @@ class AssetsApi {
|
||||
if (key != null) {
|
||||
queryParams.addAll(_queryParams('', 'key', key));
|
||||
}
|
||||
if (slug != null) {
|
||||
queryParams.addAll(_queryParams('', 'slug', slug));
|
||||
}
|
||||
|
||||
const contentTypes = <String>[];
|
||||
|
||||
@@ -499,13 +705,17 @@ class AssetsApi {
|
||||
);
|
||||
}
|
||||
|
||||
/// This endpoint requires the `asset.view` permission.
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [String] id (required):
|
||||
///
|
||||
/// * [String] key:
|
||||
Future<MultipartFile?> playAssetVideo(String id, { String? key, }) async {
|
||||
final response = await playAssetVideoWithHttpInfo(id, key: key, );
|
||||
///
|
||||
/// * [String] slug:
|
||||
Future<MultipartFile?> playAssetVideo(String id, { String? key, String? slug, }) async {
|
||||
final response = await playAssetVideoWithHttpInfo(id, key: key, slug: slug, );
|
||||
if (response.statusCode >= HttpStatus.badRequest) {
|
||||
throw ApiException(response.statusCode, await _decodeBodyBytes(response));
|
||||
}
|
||||
@@ -519,10 +729,10 @@ class AssetsApi {
|
||||
return null;
|
||||
}
|
||||
|
||||
/// replaceAsset
|
||||
///
|
||||
/// Replace the asset with new file, without changing its id
|
||||
///
|
||||
/// This property was deprecated in v1.142.0. Replace the asset with new file, without changing its id. This endpoint requires the `asset.replace` permission.
|
||||
///
|
||||
/// Note: This method returns the HTTP [Response].
|
||||
///
|
||||
/// Parameters:
|
||||
@@ -541,10 +751,12 @@ class AssetsApi {
|
||||
///
|
||||
/// * [String] key:
|
||||
///
|
||||
/// * [String] slug:
|
||||
///
|
||||
/// * [String] duration:
|
||||
///
|
||||
/// * [String] filename:
|
||||
Future<Response> replaceAssetWithHttpInfo(String id, MultipartFile assetData, String deviceAssetId, String deviceId, DateTime fileCreatedAt, DateTime fileModifiedAt, { String? key, String? duration, String? filename, }) async {
|
||||
Future<Response> replaceAssetWithHttpInfo(String id, MultipartFile assetData, String deviceAssetId, String deviceId, DateTime fileCreatedAt, DateTime fileModifiedAt, { String? key, String? slug, String? duration, String? filename, }) async {
|
||||
// ignore: prefer_const_declarations
|
||||
final apiPath = r'/assets/{id}/original'
|
||||
.replaceAll('{id}', id);
|
||||
@@ -559,6 +771,9 @@ class AssetsApi {
|
||||
if (key != null) {
|
||||
queryParams.addAll(_queryParams('', 'key', key));
|
||||
}
|
||||
if (slug != null) {
|
||||
queryParams.addAll(_queryParams('', 'slug', slug));
|
||||
}
|
||||
|
||||
const contentTypes = <String>['multipart/form-data'];
|
||||
|
||||
@@ -608,10 +823,10 @@ class AssetsApi {
|
||||
);
|
||||
}
|
||||
|
||||
/// replaceAsset
|
||||
///
|
||||
/// Replace the asset with new file, without changing its id
|
||||
///
|
||||
/// This property was deprecated in v1.142.0. Replace the asset with new file, without changing its id. This endpoint requires the `asset.replace` permission.
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [String] id (required):
|
||||
@@ -628,11 +843,13 @@ class AssetsApi {
|
||||
///
|
||||
/// * [String] key:
|
||||
///
|
||||
/// * [String] slug:
|
||||
///
|
||||
/// * [String] duration:
|
||||
///
|
||||
/// * [String] filename:
|
||||
Future<AssetMediaResponseDto?> replaceAsset(String id, MultipartFile assetData, String deviceAssetId, String deviceId, DateTime fileCreatedAt, DateTime fileModifiedAt, { String? key, String? duration, String? filename, }) async {
|
||||
final response = await replaceAssetWithHttpInfo(id, assetData, deviceAssetId, deviceId, fileCreatedAt, fileModifiedAt, key: key, duration: duration, filename: filename, );
|
||||
Future<AssetMediaResponseDto?> replaceAsset(String id, MultipartFile assetData, String deviceAssetId, String deviceId, DateTime fileCreatedAt, DateTime fileModifiedAt, { String? key, String? slug, String? duration, String? filename, }) async {
|
||||
final response = await replaceAssetWithHttpInfo(id, assetData, deviceAssetId, deviceId, fileCreatedAt, fileModifiedAt, key: key, slug: slug, duration: duration, filename: filename, );
|
||||
if (response.statusCode >= HttpStatus.badRequest) {
|
||||
throw ApiException(response.statusCode, await _decodeBodyBytes(response));
|
||||
}
|
||||
@@ -685,7 +902,10 @@ class AssetsApi {
|
||||
}
|
||||
}
|
||||
|
||||
/// Performs an HTTP 'PUT /assets/{id}' operation and returns the [Response].
|
||||
/// This endpoint requires the `asset.update` permission.
|
||||
///
|
||||
/// Note: This method returns the HTTP [Response].
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [String] id (required):
|
||||
@@ -717,6 +937,8 @@ class AssetsApi {
|
||||
);
|
||||
}
|
||||
|
||||
/// This endpoint requires the `asset.update` permission.
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [String] id (required):
|
||||
@@ -737,7 +959,70 @@ class AssetsApi {
|
||||
return null;
|
||||
}
|
||||
|
||||
/// Performs an HTTP 'PUT /assets' operation and returns the [Response].
|
||||
/// This endpoint requires the `asset.update` permission.
|
||||
///
|
||||
/// Note: This method returns the HTTP [Response].
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [String] id (required):
|
||||
///
|
||||
/// * [AssetMetadataUpsertDto] assetMetadataUpsertDto (required):
|
||||
Future<Response> updateAssetMetadataWithHttpInfo(String id, AssetMetadataUpsertDto assetMetadataUpsertDto,) async {
|
||||
// ignore: prefer_const_declarations
|
||||
final apiPath = r'/assets/{id}/metadata'
|
||||
.replaceAll('{id}', id);
|
||||
|
||||
// ignore: prefer_final_locals
|
||||
Object? postBody = assetMetadataUpsertDto;
|
||||
|
||||
final queryParams = <QueryParam>[];
|
||||
final headerParams = <String, String>{};
|
||||
final formParams = <String, String>{};
|
||||
|
||||
const contentTypes = <String>['application/json'];
|
||||
|
||||
|
||||
return apiClient.invokeAPI(
|
||||
apiPath,
|
||||
'PUT',
|
||||
queryParams,
|
||||
postBody,
|
||||
headerParams,
|
||||
formParams,
|
||||
contentTypes.isEmpty ? null : contentTypes.first,
|
||||
);
|
||||
}
|
||||
|
||||
/// This endpoint requires the `asset.update` permission.
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [String] id (required):
|
||||
///
|
||||
/// * [AssetMetadataUpsertDto] assetMetadataUpsertDto (required):
|
||||
Future<List<AssetMetadataResponseDto>?> updateAssetMetadata(String id, AssetMetadataUpsertDto assetMetadataUpsertDto,) async {
|
||||
final response = await updateAssetMetadataWithHttpInfo(id, assetMetadataUpsertDto,);
|
||||
if (response.statusCode >= HttpStatus.badRequest) {
|
||||
throw ApiException(response.statusCode, await _decodeBodyBytes(response));
|
||||
}
|
||||
// When a remote server returns no body with a status of 204, we shall not decode it.
|
||||
// At the time of writing this, `dart:convert` will throw an "Unexpected end of input"
|
||||
// FormatException when trying to decode an empty string.
|
||||
if (response.body.isNotEmpty && response.statusCode != HttpStatus.noContent) {
|
||||
final responseBody = await _decodeBodyBytes(response);
|
||||
return (await apiClient.deserializeAsync(responseBody, 'List<AssetMetadataResponseDto>') as List)
|
||||
.cast<AssetMetadataResponseDto>()
|
||||
.toList(growable: false);
|
||||
|
||||
}
|
||||
return null;
|
||||
}
|
||||
|
||||
/// This endpoint requires the `asset.update` permission.
|
||||
///
|
||||
/// Note: This method returns the HTTP [Response].
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [AssetBulkUpdateDto] assetBulkUpdateDto (required):
|
||||
@@ -766,6 +1051,8 @@ class AssetsApi {
|
||||
);
|
||||
}
|
||||
|
||||
/// This endpoint requires the `asset.update` permission.
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [AssetBulkUpdateDto] assetBulkUpdateDto (required):
|
||||
@@ -776,7 +1063,10 @@ class AssetsApi {
|
||||
}
|
||||
}
|
||||
|
||||
/// Performs an HTTP 'POST /assets' operation and returns the [Response].
|
||||
/// This endpoint requires the `asset.upload` permission.
|
||||
///
|
||||
/// Note: This method returns the HTTP [Response].
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [MultipartFile] assetData (required):
|
||||
@@ -789,8 +1079,12 @@ class AssetsApi {
|
||||
///
|
||||
/// * [DateTime] fileModifiedAt (required):
|
||||
///
|
||||
/// * [List<AssetMetadataUpsertItemDto>] metadata (required):
|
||||
///
|
||||
/// * [String] key:
|
||||
///
|
||||
/// * [String] slug:
|
||||
///
|
||||
/// * [String] xImmichChecksum:
|
||||
/// sha1 checksum that can be used for duplicate detection before the file is uploaded
|
||||
///
|
||||
@@ -805,7 +1099,7 @@ class AssetsApi {
|
||||
/// * [MultipartFile] sidecarData:
|
||||
///
|
||||
/// * [AssetVisibility] visibility:
|
||||
Future<Response> uploadAssetWithHttpInfo(MultipartFile assetData, String deviceAssetId, String deviceId, DateTime fileCreatedAt, DateTime fileModifiedAt, { String? key, String? xImmichChecksum, String? duration, String? filename, bool? isFavorite, String? livePhotoVideoId, MultipartFile? sidecarData, AssetVisibility? visibility, }) async {
|
||||
Future<Response> uploadAssetWithHttpInfo(MultipartFile assetData, String deviceAssetId, String deviceId, DateTime fileCreatedAt, DateTime fileModifiedAt, List<AssetMetadataUpsertItemDto> metadata, { String? key, String? slug, String? xImmichChecksum, String? duration, String? filename, bool? isFavorite, String? livePhotoVideoId, MultipartFile? sidecarData, AssetVisibility? visibility, }) async {
|
||||
// ignore: prefer_const_declarations
|
||||
final apiPath = r'/assets';
|
||||
|
||||
@@ -819,6 +1113,9 @@ class AssetsApi {
|
||||
if (key != null) {
|
||||
queryParams.addAll(_queryParams('', 'key', key));
|
||||
}
|
||||
if (slug != null) {
|
||||
queryParams.addAll(_queryParams('', 'slug', slug));
|
||||
}
|
||||
|
||||
if (xImmichChecksum != null) {
|
||||
headerParams[r'x-immich-checksum'] = parameterToString(xImmichChecksum);
|
||||
@@ -865,6 +1162,10 @@ class AssetsApi {
|
||||
hasFields = true;
|
||||
mp.fields[r'livePhotoVideoId'] = parameterToString(livePhotoVideoId);
|
||||
}
|
||||
if (metadata != null) {
|
||||
hasFields = true;
|
||||
mp.fields[r'metadata'] = parameterToString(metadata);
|
||||
}
|
||||
if (sidecarData != null) {
|
||||
hasFields = true;
|
||||
mp.fields[r'sidecarData'] = sidecarData.field;
|
||||
@@ -889,6 +1190,8 @@ class AssetsApi {
|
||||
);
|
||||
}
|
||||
|
||||
/// This endpoint requires the `asset.upload` permission.
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [MultipartFile] assetData (required):
|
||||
@@ -901,8 +1204,12 @@ class AssetsApi {
|
||||
///
|
||||
/// * [DateTime] fileModifiedAt (required):
|
||||
///
|
||||
/// * [List<AssetMetadataUpsertItemDto>] metadata (required):
|
||||
///
|
||||
/// * [String] key:
|
||||
///
|
||||
/// * [String] slug:
|
||||
///
|
||||
/// * [String] xImmichChecksum:
|
||||
/// sha1 checksum that can be used for duplicate detection before the file is uploaded
|
||||
///
|
||||
@@ -917,8 +1224,8 @@ class AssetsApi {
|
||||
/// * [MultipartFile] sidecarData:
|
||||
///
|
||||
/// * [AssetVisibility] visibility:
|
||||
Future<AssetMediaResponseDto?> uploadAsset(MultipartFile assetData, String deviceAssetId, String deviceId, DateTime fileCreatedAt, DateTime fileModifiedAt, { String? key, String? xImmichChecksum, String? duration, String? filename, bool? isFavorite, String? livePhotoVideoId, MultipartFile? sidecarData, AssetVisibility? visibility, }) async {
|
||||
final response = await uploadAssetWithHttpInfo(assetData, deviceAssetId, deviceId, fileCreatedAt, fileModifiedAt, key: key, xImmichChecksum: xImmichChecksum, duration: duration, filename: filename, isFavorite: isFavorite, livePhotoVideoId: livePhotoVideoId, sidecarData: sidecarData, visibility: visibility, );
|
||||
Future<AssetMediaResponseDto?> uploadAsset(MultipartFile assetData, String deviceAssetId, String deviceId, DateTime fileCreatedAt, DateTime fileModifiedAt, List<AssetMetadataUpsertItemDto> metadata, { String? key, String? slug, String? xImmichChecksum, String? duration, String? filename, bool? isFavorite, String? livePhotoVideoId, MultipartFile? sidecarData, AssetVisibility? visibility, }) async {
|
||||
final response = await uploadAssetWithHttpInfo(assetData, deviceAssetId, deviceId, fileCreatedAt, fileModifiedAt, metadata, key: key, slug: slug, xImmichChecksum: xImmichChecksum, duration: duration, filename: filename, isFavorite: isFavorite, livePhotoVideoId: livePhotoVideoId, sidecarData: sidecarData, visibility: visibility, );
|
||||
if (response.statusCode >= HttpStatus.badRequest) {
|
||||
throw ApiException(response.statusCode, await _decodeBodyBytes(response));
|
||||
}
|
||||
@@ -932,7 +1239,10 @@ class AssetsApi {
|
||||
return null;
|
||||
}
|
||||
|
||||
/// Performs an HTTP 'GET /assets/{id}/thumbnail' operation and returns the [Response].
|
||||
/// This endpoint requires the `asset.view` permission.
|
||||
///
|
||||
/// Note: This method returns the HTTP [Response].
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [String] id (required):
|
||||
@@ -940,7 +1250,9 @@ class AssetsApi {
|
||||
/// * [String] key:
|
||||
///
|
||||
/// * [AssetMediaSize] size:
|
||||
Future<Response> viewAssetWithHttpInfo(String id, { String? key, AssetMediaSize? size, }) async {
|
||||
///
|
||||
/// * [String] slug:
|
||||
Future<Response> viewAssetWithHttpInfo(String id, { String? key, AssetMediaSize? size, String? slug, }) async {
|
||||
// ignore: prefer_const_declarations
|
||||
final apiPath = r'/assets/{id}/thumbnail'
|
||||
.replaceAll('{id}', id);
|
||||
@@ -958,6 +1270,9 @@ class AssetsApi {
|
||||
if (size != null) {
|
||||
queryParams.addAll(_queryParams('', 'size', size));
|
||||
}
|
||||
if (slug != null) {
|
||||
queryParams.addAll(_queryParams('', 'slug', slug));
|
||||
}
|
||||
|
||||
const contentTypes = <String>[];
|
||||
|
||||
@@ -973,6 +1288,8 @@ class AssetsApi {
|
||||
);
|
||||
}
|
||||
|
||||
/// This endpoint requires the `asset.view` permission.
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [String] id (required):
|
||||
@@ -980,8 +1297,10 @@ class AssetsApi {
|
||||
/// * [String] key:
|
||||
///
|
||||
/// * [AssetMediaSize] size:
|
||||
Future<MultipartFile?> viewAsset(String id, { String? key, AssetMediaSize? size, }) async {
|
||||
final response = await viewAssetWithHttpInfo(id, key: key, size: size, );
|
||||
///
|
||||
/// * [String] slug:
|
||||
Future<MultipartFile?> viewAsset(String id, { String? key, AssetMediaSize? size, String? slug, }) async {
|
||||
final response = await viewAssetWithHttpInfo(id, key: key, size: size, slug: slug, );
|
||||
if (response.statusCode >= HttpStatus.badRequest) {
|
||||
throw ApiException(response.statusCode, await _decodeBodyBytes(response));
|
||||
}
|
||||
|
||||
+54
@@ -0,0 +1,54 @@
|
||||
//
|
||||
// AUTO-GENERATED FILE, DO NOT MODIFY!
|
||||
//
|
||||
// @dart=2.18
|
||||
|
||||
// ignore_for_file: unused_element, unused_import
|
||||
// ignore_for_file: always_put_required_named_parameters_first
|
||||
// ignore_for_file: constant_identifier_names
|
||||
// ignore_for_file: lines_longer_than_80_chars
|
||||
|
||||
part of openapi.api;
|
||||
|
||||
|
||||
class AuthAdminApi {
|
||||
AuthAdminApi([ApiClient? apiClient]) : apiClient = apiClient ?? defaultApiClient;
|
||||
|
||||
final ApiClient apiClient;
|
||||
|
||||
/// This endpoint is an admin-only route, and requires the `adminAuth.unlinkAll` permission.
|
||||
///
|
||||
/// Note: This method returns the HTTP [Response].
|
||||
Future<Response> unlinkAllOAuthAccountsAdminWithHttpInfo() async {
|
||||
// ignore: prefer_const_declarations
|
||||
final apiPath = r'/admin/auth/unlink-all';
|
||||
|
||||
// ignore: prefer_final_locals
|
||||
Object? postBody;
|
||||
|
||||
final queryParams = <QueryParam>[];
|
||||
final headerParams = <String, String>{};
|
||||
final formParams = <String, String>{};
|
||||
|
||||
const contentTypes = <String>[];
|
||||
|
||||
|
||||
return apiClient.invokeAPI(
|
||||
apiPath,
|
||||
'POST',
|
||||
queryParams,
|
||||
postBody,
|
||||
headerParams,
|
||||
formParams,
|
||||
contentTypes.isEmpty ? null : contentTypes.first,
|
||||
);
|
||||
}
|
||||
|
||||
/// This endpoint is an admin-only route, and requires the `adminAuth.unlinkAll` permission.
|
||||
Future<void> unlinkAllOAuthAccountsAdmin() async {
|
||||
final response = await unlinkAllOAuthAccountsAdminWithHttpInfo();
|
||||
if (response.statusCode >= HttpStatus.badRequest) {
|
||||
throw ApiException(response.statusCode, await _decodeBodyBytes(response));
|
||||
}
|
||||
}
|
||||
}
|
||||
+24
-4
@@ -16,7 +16,10 @@ class AuthenticationApi {
|
||||
|
||||
final ApiClient apiClient;
|
||||
|
||||
/// Performs an HTTP 'POST /auth/change-password' operation and returns the [Response].
|
||||
/// This endpoint requires the `auth.changePassword` permission.
|
||||
///
|
||||
/// Note: This method returns the HTTP [Response].
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [ChangePasswordDto] changePasswordDto (required):
|
||||
@@ -45,6 +48,8 @@ class AuthenticationApi {
|
||||
);
|
||||
}
|
||||
|
||||
/// This endpoint requires the `auth.changePassword` permission.
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [ChangePasswordDto] changePasswordDto (required):
|
||||
@@ -63,7 +68,10 @@ class AuthenticationApi {
|
||||
return null;
|
||||
}
|
||||
|
||||
/// Performs an HTTP 'PUT /auth/pin-code' operation and returns the [Response].
|
||||
/// This endpoint requires the `pinCode.update` permission.
|
||||
///
|
||||
/// Note: This method returns the HTTP [Response].
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [PinCodeChangeDto] pinCodeChangeDto (required):
|
||||
@@ -92,6 +100,8 @@ class AuthenticationApi {
|
||||
);
|
||||
}
|
||||
|
||||
/// This endpoint requires the `pinCode.update` permission.
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [PinCodeChangeDto] pinCodeChangeDto (required):
|
||||
@@ -264,7 +274,10 @@ class AuthenticationApi {
|
||||
return null;
|
||||
}
|
||||
|
||||
/// Performs an HTTP 'DELETE /auth/pin-code' operation and returns the [Response].
|
||||
/// This endpoint requires the `pinCode.delete` permission.
|
||||
///
|
||||
/// Note: This method returns the HTTP [Response].
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [PinCodeResetDto] pinCodeResetDto (required):
|
||||
@@ -293,6 +306,8 @@ class AuthenticationApi {
|
||||
);
|
||||
}
|
||||
|
||||
/// This endpoint requires the `pinCode.delete` permission.
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [PinCodeResetDto] pinCodeResetDto (required):
|
||||
@@ -303,7 +318,10 @@ class AuthenticationApi {
|
||||
}
|
||||
}
|
||||
|
||||
/// Performs an HTTP 'POST /auth/pin-code' operation and returns the [Response].
|
||||
/// This endpoint requires the `pinCode.create` permission.
|
||||
///
|
||||
/// Note: This method returns the HTTP [Response].
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [PinCodeSetupDto] pinCodeSetupDto (required):
|
||||
@@ -332,6 +350,8 @@ class AuthenticationApi {
|
||||
);
|
||||
}
|
||||
|
||||
/// This endpoint requires the `pinCode.create` permission.
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [PinCodeSetupDto] pinCodeSetupDto (required):
|
||||
|
||||
+189
-2
@@ -16,7 +16,60 @@ class DeprecatedApi {
|
||||
|
||||
final ApiClient apiClient;
|
||||
|
||||
/// This property was deprecated in v1.116.0
|
||||
/// This property was deprecated in v1.141.0. This endpoint requires the `partner.create` permission.
|
||||
///
|
||||
/// Note: This method returns the HTTP [Response].
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [String] id (required):
|
||||
Future<Response> createPartnerDeprecatedWithHttpInfo(String id,) async {
|
||||
// ignore: prefer_const_declarations
|
||||
final apiPath = r'/partners/{id}'
|
||||
.replaceAll('{id}', id);
|
||||
|
||||
// ignore: prefer_final_locals
|
||||
Object? postBody;
|
||||
|
||||
final queryParams = <QueryParam>[];
|
||||
final headerParams = <String, String>{};
|
||||
final formParams = <String, String>{};
|
||||
|
||||
const contentTypes = <String>[];
|
||||
|
||||
|
||||
return apiClient.invokeAPI(
|
||||
apiPath,
|
||||
'POST',
|
||||
queryParams,
|
||||
postBody,
|
||||
headerParams,
|
||||
formParams,
|
||||
contentTypes.isEmpty ? null : contentTypes.first,
|
||||
);
|
||||
}
|
||||
|
||||
/// This property was deprecated in v1.141.0. This endpoint requires the `partner.create` permission.
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [String] id (required):
|
||||
Future<PartnerResponseDto?> createPartnerDeprecated(String id,) async {
|
||||
final response = await createPartnerDeprecatedWithHttpInfo(id,);
|
||||
if (response.statusCode >= HttpStatus.badRequest) {
|
||||
throw ApiException(response.statusCode, await _decodeBodyBytes(response));
|
||||
}
|
||||
// When a remote server returns no body with a status of 204, we shall not decode it.
|
||||
// At the time of writing this, `dart:convert` will throw an "Unexpected end of input"
|
||||
// FormatException when trying to decode an empty string.
|
||||
if (response.body.isNotEmpty && response.statusCode != HttpStatus.noContent) {
|
||||
return await apiClient.deserializeAsync(await _decodeBodyBytes(response), 'PartnerResponseDto',) as PartnerResponseDto;
|
||||
|
||||
}
|
||||
return null;
|
||||
}
|
||||
|
||||
/// This property was deprecated in v1.116.0. This endpoint requires the `asset.read` permission.
|
||||
///
|
||||
/// Note: This method returns the HTTP [Response].
|
||||
///
|
||||
@@ -52,7 +105,7 @@ class DeprecatedApi {
|
||||
);
|
||||
}
|
||||
|
||||
/// This property was deprecated in v1.116.0
|
||||
/// This property was deprecated in v1.116.0. This endpoint requires the `asset.read` permission.
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
@@ -74,4 +127,138 @@ class DeprecatedApi {
|
||||
}
|
||||
return null;
|
||||
}
|
||||
|
||||
/// Replace the asset with new file, without changing its id
|
||||
///
|
||||
/// This property was deprecated in v1.142.0. Replace the asset with new file, without changing its id. This endpoint requires the `asset.replace` permission.
|
||||
///
|
||||
/// Note: This method returns the HTTP [Response].
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [String] id (required):
|
||||
///
|
||||
/// * [MultipartFile] assetData (required):
|
||||
///
|
||||
/// * [String] deviceAssetId (required):
|
||||
///
|
||||
/// * [String] deviceId (required):
|
||||
///
|
||||
/// * [DateTime] fileCreatedAt (required):
|
||||
///
|
||||
/// * [DateTime] fileModifiedAt (required):
|
||||
///
|
||||
/// * [String] key:
|
||||
///
|
||||
/// * [String] slug:
|
||||
///
|
||||
/// * [String] duration:
|
||||
///
|
||||
/// * [String] filename:
|
||||
Future<Response> replaceAssetWithHttpInfo(String id, MultipartFile assetData, String deviceAssetId, String deviceId, DateTime fileCreatedAt, DateTime fileModifiedAt, { String? key, String? slug, String? duration, String? filename, }) async {
|
||||
// ignore: prefer_const_declarations
|
||||
final apiPath = r'/assets/{id}/original'
|
||||
.replaceAll('{id}', id);
|
||||
|
||||
// ignore: prefer_final_locals
|
||||
Object? postBody;
|
||||
|
||||
final queryParams = <QueryParam>[];
|
||||
final headerParams = <String, String>{};
|
||||
final formParams = <String, String>{};
|
||||
|
||||
if (key != null) {
|
||||
queryParams.addAll(_queryParams('', 'key', key));
|
||||
}
|
||||
if (slug != null) {
|
||||
queryParams.addAll(_queryParams('', 'slug', slug));
|
||||
}
|
||||
|
||||
const contentTypes = <String>['multipart/form-data'];
|
||||
|
||||
bool hasFields = false;
|
||||
final mp = MultipartRequest('PUT', Uri.parse(apiPath));
|
||||
if (assetData != null) {
|
||||
hasFields = true;
|
||||
mp.fields[r'assetData'] = assetData.field;
|
||||
mp.files.add(assetData);
|
||||
}
|
||||
if (deviceAssetId != null) {
|
||||
hasFields = true;
|
||||
mp.fields[r'deviceAssetId'] = parameterToString(deviceAssetId);
|
||||
}
|
||||
if (deviceId != null) {
|
||||
hasFields = true;
|
||||
mp.fields[r'deviceId'] = parameterToString(deviceId);
|
||||
}
|
||||
if (duration != null) {
|
||||
hasFields = true;
|
||||
mp.fields[r'duration'] = parameterToString(duration);
|
||||
}
|
||||
if (fileCreatedAt != null) {
|
||||
hasFields = true;
|
||||
mp.fields[r'fileCreatedAt'] = parameterToString(fileCreatedAt);
|
||||
}
|
||||
if (fileModifiedAt != null) {
|
||||
hasFields = true;
|
||||
mp.fields[r'fileModifiedAt'] = parameterToString(fileModifiedAt);
|
||||
}
|
||||
if (filename != null) {
|
||||
hasFields = true;
|
||||
mp.fields[r'filename'] = parameterToString(filename);
|
||||
}
|
||||
if (hasFields) {
|
||||
postBody = mp;
|
||||
}
|
||||
|
||||
return apiClient.invokeAPI(
|
||||
apiPath,
|
||||
'PUT',
|
||||
queryParams,
|
||||
postBody,
|
||||
headerParams,
|
||||
formParams,
|
||||
contentTypes.isEmpty ? null : contentTypes.first,
|
||||
);
|
||||
}
|
||||
|
||||
/// Replace the asset with new file, without changing its id
|
||||
///
|
||||
/// This property was deprecated in v1.142.0. Replace the asset with new file, without changing its id. This endpoint requires the `asset.replace` permission.
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [String] id (required):
|
||||
///
|
||||
/// * [MultipartFile] assetData (required):
|
||||
///
|
||||
/// * [String] deviceAssetId (required):
|
||||
///
|
||||
/// * [String] deviceId (required):
|
||||
///
|
||||
/// * [DateTime] fileCreatedAt (required):
|
||||
///
|
||||
/// * [DateTime] fileModifiedAt (required):
|
||||
///
|
||||
/// * [String] key:
|
||||
///
|
||||
/// * [String] slug:
|
||||
///
|
||||
/// * [String] duration:
|
||||
///
|
||||
/// * [String] filename:
|
||||
Future<AssetMediaResponseDto?> replaceAsset(String id, MultipartFile assetData, String deviceAssetId, String deviceId, DateTime fileCreatedAt, DateTime fileModifiedAt, { String? key, String? slug, String? duration, String? filename, }) async {
|
||||
final response = await replaceAssetWithHttpInfo(id, assetData, deviceAssetId, deviceId, fileCreatedAt, fileModifiedAt, key: key, slug: slug, duration: duration, filename: filename, );
|
||||
if (response.statusCode >= HttpStatus.badRequest) {
|
||||
throw ApiException(response.statusCode, await _decodeBodyBytes(response));
|
||||
}
|
||||
// When a remote server returns no body with a status of 204, we shall not decode it.
|
||||
// At the time of writing this, `dart:convert` will throw an "Unexpected end of input"
|
||||
// FormatException when trying to decode an empty string.
|
||||
if (response.body.isNotEmpty && response.statusCode != HttpStatus.noContent) {
|
||||
return await apiClient.deserializeAsync(await _decodeBodyBytes(response), 'AssetMediaResponseDto',) as AssetMediaResponseDto;
|
||||
|
||||
}
|
||||
return null;
|
||||
}
|
||||
}
|
||||
|
||||
Generated
+32
-8
@@ -16,13 +16,18 @@ class DownloadApi {
|
||||
|
||||
final ApiClient apiClient;
|
||||
|
||||
/// Performs an HTTP 'POST /download/archive' operation and returns the [Response].
|
||||
/// This endpoint requires the `asset.download` permission.
|
||||
///
|
||||
/// Note: This method returns the HTTP [Response].
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [AssetIdsDto] assetIdsDto (required):
|
||||
///
|
||||
/// * [String] key:
|
||||
Future<Response> downloadArchiveWithHttpInfo(AssetIdsDto assetIdsDto, { String? key, }) async {
|
||||
///
|
||||
/// * [String] slug:
|
||||
Future<Response> downloadArchiveWithHttpInfo(AssetIdsDto assetIdsDto, { String? key, String? slug, }) async {
|
||||
// ignore: prefer_const_declarations
|
||||
final apiPath = r'/download/archive';
|
||||
|
||||
@@ -36,6 +41,9 @@ class DownloadApi {
|
||||
if (key != null) {
|
||||
queryParams.addAll(_queryParams('', 'key', key));
|
||||
}
|
||||
if (slug != null) {
|
||||
queryParams.addAll(_queryParams('', 'slug', slug));
|
||||
}
|
||||
|
||||
const contentTypes = <String>['application/json'];
|
||||
|
||||
@@ -51,13 +59,17 @@ class DownloadApi {
|
||||
);
|
||||
}
|
||||
|
||||
/// This endpoint requires the `asset.download` permission.
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [AssetIdsDto] assetIdsDto (required):
|
||||
///
|
||||
/// * [String] key:
|
||||
Future<MultipartFile?> downloadArchive(AssetIdsDto assetIdsDto, { String? key, }) async {
|
||||
final response = await downloadArchiveWithHttpInfo(assetIdsDto, key: key, );
|
||||
///
|
||||
/// * [String] slug:
|
||||
Future<MultipartFile?> downloadArchive(AssetIdsDto assetIdsDto, { String? key, String? slug, }) async {
|
||||
final response = await downloadArchiveWithHttpInfo(assetIdsDto, key: key, slug: slug, );
|
||||
if (response.statusCode >= HttpStatus.badRequest) {
|
||||
throw ApiException(response.statusCode, await _decodeBodyBytes(response));
|
||||
}
|
||||
@@ -71,13 +83,18 @@ class DownloadApi {
|
||||
return null;
|
||||
}
|
||||
|
||||
/// Performs an HTTP 'POST /download/info' operation and returns the [Response].
|
||||
/// This endpoint requires the `asset.download` permission.
|
||||
///
|
||||
/// Note: This method returns the HTTP [Response].
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [DownloadInfoDto] downloadInfoDto (required):
|
||||
///
|
||||
/// * [String] key:
|
||||
Future<Response> getDownloadInfoWithHttpInfo(DownloadInfoDto downloadInfoDto, { String? key, }) async {
|
||||
///
|
||||
/// * [String] slug:
|
||||
Future<Response> getDownloadInfoWithHttpInfo(DownloadInfoDto downloadInfoDto, { String? key, String? slug, }) async {
|
||||
// ignore: prefer_const_declarations
|
||||
final apiPath = r'/download/info';
|
||||
|
||||
@@ -91,6 +108,9 @@ class DownloadApi {
|
||||
if (key != null) {
|
||||
queryParams.addAll(_queryParams('', 'key', key));
|
||||
}
|
||||
if (slug != null) {
|
||||
queryParams.addAll(_queryParams('', 'slug', slug));
|
||||
}
|
||||
|
||||
const contentTypes = <String>['application/json'];
|
||||
|
||||
@@ -106,13 +126,17 @@ class DownloadApi {
|
||||
);
|
||||
}
|
||||
|
||||
/// This endpoint requires the `asset.download` permission.
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [DownloadInfoDto] downloadInfoDto (required):
|
||||
///
|
||||
/// * [String] key:
|
||||
Future<DownloadResponseDto?> getDownloadInfo(DownloadInfoDto downloadInfoDto, { String? key, }) async {
|
||||
final response = await getDownloadInfoWithHttpInfo(downloadInfoDto, key: key, );
|
||||
///
|
||||
/// * [String] slug:
|
||||
Future<DownloadResponseDto?> getDownloadInfo(DownloadInfoDto downloadInfoDto, { String? key, String? slug, }) async {
|
||||
final response = await getDownloadInfoWithHttpInfo(downloadInfoDto, key: key, slug: slug, );
|
||||
if (response.statusCode >= HttpStatus.badRequest) {
|
||||
throw ApiException(response.statusCode, await _decodeBodyBytes(response));
|
||||
}
|
||||
|
||||
+16
-3
@@ -16,7 +16,10 @@ class DuplicatesApi {
|
||||
|
||||
final ApiClient apiClient;
|
||||
|
||||
/// Performs an HTTP 'DELETE /duplicates/{id}' operation and returns the [Response].
|
||||
/// This endpoint requires the `duplicate.delete` permission.
|
||||
///
|
||||
/// Note: This method returns the HTTP [Response].
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [String] id (required):
|
||||
@@ -46,6 +49,8 @@ class DuplicatesApi {
|
||||
);
|
||||
}
|
||||
|
||||
/// This endpoint requires the `duplicate.delete` permission.
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [String] id (required):
|
||||
@@ -56,7 +61,10 @@ class DuplicatesApi {
|
||||
}
|
||||
}
|
||||
|
||||
/// Performs an HTTP 'DELETE /duplicates' operation and returns the [Response].
|
||||
/// This endpoint requires the `duplicate.delete` permission.
|
||||
///
|
||||
/// Note: This method returns the HTTP [Response].
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [BulkIdsDto] bulkIdsDto (required):
|
||||
@@ -85,6 +93,8 @@ class DuplicatesApi {
|
||||
);
|
||||
}
|
||||
|
||||
/// This endpoint requires the `duplicate.delete` permission.
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [BulkIdsDto] bulkIdsDto (required):
|
||||
@@ -95,7 +105,9 @@ class DuplicatesApi {
|
||||
}
|
||||
}
|
||||
|
||||
/// Performs an HTTP 'GET /duplicates' operation and returns the [Response].
|
||||
/// This endpoint requires the `duplicate.read` permission.
|
||||
///
|
||||
/// Note: This method returns the HTTP [Response].
|
||||
Future<Response> getAssetDuplicatesWithHttpInfo() async {
|
||||
// ignore: prefer_const_declarations
|
||||
final apiPath = r'/duplicates';
|
||||
@@ -121,6 +133,7 @@ class DuplicatesApi {
|
||||
);
|
||||
}
|
||||
|
||||
/// This endpoint requires the `duplicate.read` permission.
|
||||
Future<List<DuplicateResponseDto>?> getAssetDuplicates() async {
|
||||
final response = await getAssetDuplicatesWithHttpInfo();
|
||||
if (response.statusCode >= HttpStatus.badRequest) {
|
||||
|
||||
Generated
+24
-4
@@ -16,7 +16,10 @@ class FacesApi {
|
||||
|
||||
final ApiClient apiClient;
|
||||
|
||||
/// Performs an HTTP 'POST /faces' operation and returns the [Response].
|
||||
/// This endpoint requires the `face.create` permission.
|
||||
///
|
||||
/// Note: This method returns the HTTP [Response].
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [AssetFaceCreateDto] assetFaceCreateDto (required):
|
||||
@@ -45,6 +48,8 @@ class FacesApi {
|
||||
);
|
||||
}
|
||||
|
||||
/// This endpoint requires the `face.create` permission.
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [AssetFaceCreateDto] assetFaceCreateDto (required):
|
||||
@@ -55,7 +60,10 @@ class FacesApi {
|
||||
}
|
||||
}
|
||||
|
||||
/// Performs an HTTP 'DELETE /faces/{id}' operation and returns the [Response].
|
||||
/// This endpoint requires the `face.delete` permission.
|
||||
///
|
||||
/// Note: This method returns the HTTP [Response].
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [String] id (required):
|
||||
@@ -87,6 +95,8 @@ class FacesApi {
|
||||
);
|
||||
}
|
||||
|
||||
/// This endpoint requires the `face.delete` permission.
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [String] id (required):
|
||||
@@ -99,7 +109,10 @@ class FacesApi {
|
||||
}
|
||||
}
|
||||
|
||||
/// Performs an HTTP 'GET /faces' operation and returns the [Response].
|
||||
/// This endpoint requires the `face.read` permission.
|
||||
///
|
||||
/// Note: This method returns the HTTP [Response].
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [String] id (required):
|
||||
@@ -130,6 +143,8 @@ class FacesApi {
|
||||
);
|
||||
}
|
||||
|
||||
/// This endpoint requires the `face.read` permission.
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [String] id (required):
|
||||
@@ -151,7 +166,10 @@ class FacesApi {
|
||||
return null;
|
||||
}
|
||||
|
||||
/// Performs an HTTP 'PUT /faces/{id}' operation and returns the [Response].
|
||||
/// This endpoint requires the `face.update` permission.
|
||||
///
|
||||
/// Note: This method returns the HTTP [Response].
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [String] id (required):
|
||||
@@ -183,6 +201,8 @@ class FacesApi {
|
||||
);
|
||||
}
|
||||
|
||||
/// This endpoint requires the `face.update` permission.
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [String] id (required):
|
||||
|
||||
Generated
+16
-3
@@ -16,7 +16,10 @@ class JobsApi {
|
||||
|
||||
final ApiClient apiClient;
|
||||
|
||||
/// Performs an HTTP 'POST /jobs' operation and returns the [Response].
|
||||
/// This endpoint is an admin-only route, and requires the `job.create` permission.
|
||||
///
|
||||
/// Note: This method returns the HTTP [Response].
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [JobCreateDto] jobCreateDto (required):
|
||||
@@ -45,6 +48,8 @@ class JobsApi {
|
||||
);
|
||||
}
|
||||
|
||||
/// This endpoint is an admin-only route, and requires the `job.create` permission.
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [JobCreateDto] jobCreateDto (required):
|
||||
@@ -55,7 +60,9 @@ class JobsApi {
|
||||
}
|
||||
}
|
||||
|
||||
/// Performs an HTTP 'GET /jobs' operation and returns the [Response].
|
||||
/// This endpoint is an admin-only route, and requires the `job.read` permission.
|
||||
///
|
||||
/// Note: This method returns the HTTP [Response].
|
||||
Future<Response> getAllJobsStatusWithHttpInfo() async {
|
||||
// ignore: prefer_const_declarations
|
||||
final apiPath = r'/jobs';
|
||||
@@ -81,6 +88,7 @@ class JobsApi {
|
||||
);
|
||||
}
|
||||
|
||||
/// This endpoint is an admin-only route, and requires the `job.read` permission.
|
||||
Future<AllJobStatusResponseDto?> getAllJobsStatus() async {
|
||||
final response = await getAllJobsStatusWithHttpInfo();
|
||||
if (response.statusCode >= HttpStatus.badRequest) {
|
||||
@@ -96,7 +104,10 @@ class JobsApi {
|
||||
return null;
|
||||
}
|
||||
|
||||
/// Performs an HTTP 'PUT /jobs/{id}' operation and returns the [Response].
|
||||
/// This endpoint is an admin-only route, and requires the `job.create` permission.
|
||||
///
|
||||
/// Note: This method returns the HTTP [Response].
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [JobName] id (required):
|
||||
@@ -128,6 +139,8 @@ class JobsApi {
|
||||
);
|
||||
}
|
||||
|
||||
/// This endpoint is an admin-only route, and requires the `job.create` permission.
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [JobName] id (required):
|
||||
|
||||
+40
-7
@@ -16,7 +16,10 @@ class LibrariesApi {
|
||||
|
||||
final ApiClient apiClient;
|
||||
|
||||
/// Performs an HTTP 'POST /libraries' operation and returns the [Response].
|
||||
/// This endpoint is an admin-only route, and requires the `library.create` permission.
|
||||
///
|
||||
/// Note: This method returns the HTTP [Response].
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [CreateLibraryDto] createLibraryDto (required):
|
||||
@@ -45,6 +48,8 @@ class LibrariesApi {
|
||||
);
|
||||
}
|
||||
|
||||
/// This endpoint is an admin-only route, and requires the `library.create` permission.
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [CreateLibraryDto] createLibraryDto (required):
|
||||
@@ -63,7 +68,10 @@ class LibrariesApi {
|
||||
return null;
|
||||
}
|
||||
|
||||
/// Performs an HTTP 'DELETE /libraries/{id}' operation and returns the [Response].
|
||||
/// This endpoint is an admin-only route, and requires the `library.delete` permission.
|
||||
///
|
||||
/// Note: This method returns the HTTP [Response].
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [String] id (required):
|
||||
@@ -93,6 +101,8 @@ class LibrariesApi {
|
||||
);
|
||||
}
|
||||
|
||||
/// This endpoint is an admin-only route, and requires the `library.delete` permission.
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [String] id (required):
|
||||
@@ -103,7 +113,9 @@ class LibrariesApi {
|
||||
}
|
||||
}
|
||||
|
||||
/// Performs an HTTP 'GET /libraries' operation and returns the [Response].
|
||||
/// This endpoint is an admin-only route, and requires the `library.read` permission.
|
||||
///
|
||||
/// Note: This method returns the HTTP [Response].
|
||||
Future<Response> getAllLibrariesWithHttpInfo() async {
|
||||
// ignore: prefer_const_declarations
|
||||
final apiPath = r'/libraries';
|
||||
@@ -129,6 +141,7 @@ class LibrariesApi {
|
||||
);
|
||||
}
|
||||
|
||||
/// This endpoint is an admin-only route, and requires the `library.read` permission.
|
||||
Future<List<LibraryResponseDto>?> getAllLibraries() async {
|
||||
final response = await getAllLibrariesWithHttpInfo();
|
||||
if (response.statusCode >= HttpStatus.badRequest) {
|
||||
@@ -147,7 +160,10 @@ class LibrariesApi {
|
||||
return null;
|
||||
}
|
||||
|
||||
/// Performs an HTTP 'GET /libraries/{id}' operation and returns the [Response].
|
||||
/// This endpoint is an admin-only route, and requires the `library.read` permission.
|
||||
///
|
||||
/// Note: This method returns the HTTP [Response].
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [String] id (required):
|
||||
@@ -177,6 +193,8 @@ class LibrariesApi {
|
||||
);
|
||||
}
|
||||
|
||||
/// This endpoint is an admin-only route, and requires the `library.read` permission.
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [String] id (required):
|
||||
@@ -195,7 +213,10 @@ class LibrariesApi {
|
||||
return null;
|
||||
}
|
||||
|
||||
/// Performs an HTTP 'GET /libraries/{id}/statistics' operation and returns the [Response].
|
||||
/// This endpoint is an admin-only route, and requires the `library.statistics` permission.
|
||||
///
|
||||
/// Note: This method returns the HTTP [Response].
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [String] id (required):
|
||||
@@ -225,6 +246,8 @@ class LibrariesApi {
|
||||
);
|
||||
}
|
||||
|
||||
/// This endpoint is an admin-only route, and requires the `library.statistics` permission.
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [String] id (required):
|
||||
@@ -243,7 +266,10 @@ class LibrariesApi {
|
||||
return null;
|
||||
}
|
||||
|
||||
/// Performs an HTTP 'POST /libraries/{id}/scan' operation and returns the [Response].
|
||||
/// This endpoint is an admin-only route, and requires the `library.update` permission.
|
||||
///
|
||||
/// Note: This method returns the HTTP [Response].
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [String] id (required):
|
||||
@@ -273,6 +299,8 @@ class LibrariesApi {
|
||||
);
|
||||
}
|
||||
|
||||
/// This endpoint is an admin-only route, and requires the `library.update` permission.
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [String] id (required):
|
||||
@@ -283,7 +311,10 @@ class LibrariesApi {
|
||||
}
|
||||
}
|
||||
|
||||
/// Performs an HTTP 'PUT /libraries/{id}' operation and returns the [Response].
|
||||
/// This endpoint is an admin-only route, and requires the `library.update` permission.
|
||||
///
|
||||
/// Note: This method returns the HTTP [Response].
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [String] id (required):
|
||||
@@ -315,6 +346,8 @@ class LibrariesApi {
|
||||
);
|
||||
}
|
||||
|
||||
/// This endpoint is an admin-only route, and requires the `library.update` permission.
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [String] id (required):
|
||||
|
||||
Generated
+17
-17
@@ -19,18 +19,18 @@ class MapApi {
|
||||
/// Performs an HTTP 'GET /map/markers' operation and returns the [Response].
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [DateTime] fileCreatedAfter:
|
||||
///
|
||||
/// * [DateTime] fileCreatedBefore:
|
||||
///
|
||||
/// * [bool] isArchived:
|
||||
///
|
||||
/// * [bool] isFavorite:
|
||||
///
|
||||
/// * [DateTime] fileCreatedAfter:
|
||||
///
|
||||
/// * [DateTime] fileCreatedBefore:
|
||||
///
|
||||
/// * [bool] withPartners:
|
||||
///
|
||||
/// * [bool] withSharedAlbums:
|
||||
Future<Response> getMapMarkersWithHttpInfo({ DateTime? fileCreatedAfter, DateTime? fileCreatedBefore, bool? isArchived, bool? isFavorite, bool? withPartners, bool? withSharedAlbums, }) async {
|
||||
Future<Response> getMapMarkersWithHttpInfo({ bool? isArchived, bool? isFavorite, DateTime? fileCreatedAfter, DateTime? fileCreatedBefore, bool? withPartners, bool? withSharedAlbums, }) async {
|
||||
// ignore: prefer_const_declarations
|
||||
final apiPath = r'/map/markers';
|
||||
|
||||
@@ -41,18 +41,18 @@ class MapApi {
|
||||
final headerParams = <String, String>{};
|
||||
final formParams = <String, String>{};
|
||||
|
||||
if (fileCreatedAfter != null) {
|
||||
queryParams.addAll(_queryParams('', 'fileCreatedAfter', fileCreatedAfter));
|
||||
}
|
||||
if (fileCreatedBefore != null) {
|
||||
queryParams.addAll(_queryParams('', 'fileCreatedBefore', fileCreatedBefore));
|
||||
}
|
||||
if (isArchived != null) {
|
||||
queryParams.addAll(_queryParams('', 'isArchived', isArchived));
|
||||
}
|
||||
if (isFavorite != null) {
|
||||
queryParams.addAll(_queryParams('', 'isFavorite', isFavorite));
|
||||
}
|
||||
if (fileCreatedAfter != null) {
|
||||
queryParams.addAll(_queryParams('', 'fileCreatedAfter', fileCreatedAfter));
|
||||
}
|
||||
if (fileCreatedBefore != null) {
|
||||
queryParams.addAll(_queryParams('', 'fileCreatedBefore', fileCreatedBefore));
|
||||
}
|
||||
if (withPartners != null) {
|
||||
queryParams.addAll(_queryParams('', 'withPartners', withPartners));
|
||||
}
|
||||
@@ -76,19 +76,19 @@ class MapApi {
|
||||
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [DateTime] fileCreatedAfter:
|
||||
///
|
||||
/// * [DateTime] fileCreatedBefore:
|
||||
///
|
||||
/// * [bool] isArchived:
|
||||
///
|
||||
/// * [bool] isFavorite:
|
||||
///
|
||||
/// * [DateTime] fileCreatedAfter:
|
||||
///
|
||||
/// * [DateTime] fileCreatedBefore:
|
||||
///
|
||||
/// * [bool] withPartners:
|
||||
///
|
||||
/// * [bool] withSharedAlbums:
|
||||
Future<List<MapMarkerResponseDto>?> getMapMarkers({ DateTime? fileCreatedAfter, DateTime? fileCreatedBefore, bool? isArchived, bool? isFavorite, bool? withPartners, bool? withSharedAlbums, }) async {
|
||||
final response = await getMapMarkersWithHttpInfo( fileCreatedAfter: fileCreatedAfter, fileCreatedBefore: fileCreatedBefore, isArchived: isArchived, isFavorite: isFavorite, withPartners: withPartners, withSharedAlbums: withSharedAlbums, );
|
||||
Future<List<MapMarkerResponseDto>?> getMapMarkers({ bool? isArchived, bool? isFavorite, DateTime? fileCreatedAfter, DateTime? fileCreatedBefore, bool? withPartners, bool? withSharedAlbums, }) async {
|
||||
final response = await getMapMarkersWithHttpInfo( isArchived: isArchived, isFavorite: isFavorite, fileCreatedAfter: fileCreatedAfter, fileCreatedBefore: fileCreatedBefore, withPartners: withPartners, withSharedAlbums: withSharedAlbums, );
|
||||
if (response.statusCode >= HttpStatus.badRequest) {
|
||||
throw ApiException(response.statusCode, await _decodeBodyBytes(response));
|
||||
}
|
||||
|
||||
Generated
+48
-8
@@ -16,7 +16,10 @@ class MemoriesApi {
|
||||
|
||||
final ApiClient apiClient;
|
||||
|
||||
/// Performs an HTTP 'PUT /memories/{id}/assets' operation and returns the [Response].
|
||||
/// This endpoint requires the `memoryAsset.create` permission.
|
||||
///
|
||||
/// Note: This method returns the HTTP [Response].
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [String] id (required):
|
||||
@@ -48,6 +51,8 @@ class MemoriesApi {
|
||||
);
|
||||
}
|
||||
|
||||
/// This endpoint requires the `memoryAsset.create` permission.
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [String] id (required):
|
||||
@@ -71,7 +76,10 @@ class MemoriesApi {
|
||||
return null;
|
||||
}
|
||||
|
||||
/// Performs an HTTP 'POST /memories' operation and returns the [Response].
|
||||
/// This endpoint requires the `memory.create` permission.
|
||||
///
|
||||
/// Note: This method returns the HTTP [Response].
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [MemoryCreateDto] memoryCreateDto (required):
|
||||
@@ -100,6 +108,8 @@ class MemoriesApi {
|
||||
);
|
||||
}
|
||||
|
||||
/// This endpoint requires the `memory.create` permission.
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [MemoryCreateDto] memoryCreateDto (required):
|
||||
@@ -118,7 +128,10 @@ class MemoriesApi {
|
||||
return null;
|
||||
}
|
||||
|
||||
/// Performs an HTTP 'DELETE /memories/{id}' operation and returns the [Response].
|
||||
/// This endpoint requires the `memory.delete` permission.
|
||||
///
|
||||
/// Note: This method returns the HTTP [Response].
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [String] id (required):
|
||||
@@ -148,6 +161,8 @@ class MemoriesApi {
|
||||
);
|
||||
}
|
||||
|
||||
/// This endpoint requires the `memory.delete` permission.
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [String] id (required):
|
||||
@@ -158,7 +173,10 @@ class MemoriesApi {
|
||||
}
|
||||
}
|
||||
|
||||
/// Performs an HTTP 'GET /memories/{id}' operation and returns the [Response].
|
||||
/// This endpoint requires the `memory.read` permission.
|
||||
///
|
||||
/// Note: This method returns the HTTP [Response].
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [String] id (required):
|
||||
@@ -188,6 +206,8 @@ class MemoriesApi {
|
||||
);
|
||||
}
|
||||
|
||||
/// This endpoint requires the `memory.read` permission.
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [String] id (required):
|
||||
@@ -206,7 +226,10 @@ class MemoriesApi {
|
||||
return null;
|
||||
}
|
||||
|
||||
/// Performs an HTTP 'GET /memories/statistics' operation and returns the [Response].
|
||||
/// This endpoint requires the `memory.statistics` permission.
|
||||
///
|
||||
/// Note: This method returns the HTTP [Response].
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [DateTime] for_:
|
||||
@@ -254,6 +277,8 @@ class MemoriesApi {
|
||||
);
|
||||
}
|
||||
|
||||
/// This endpoint requires the `memory.statistics` permission.
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [DateTime] for_:
|
||||
@@ -278,7 +303,10 @@ class MemoriesApi {
|
||||
return null;
|
||||
}
|
||||
|
||||
/// Performs an HTTP 'DELETE /memories/{id}/assets' operation and returns the [Response].
|
||||
/// This endpoint requires the `memoryAsset.delete` permission.
|
||||
///
|
||||
/// Note: This method returns the HTTP [Response].
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [String] id (required):
|
||||
@@ -310,6 +338,8 @@ class MemoriesApi {
|
||||
);
|
||||
}
|
||||
|
||||
/// This endpoint requires the `memoryAsset.delete` permission.
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [String] id (required):
|
||||
@@ -333,7 +363,10 @@ class MemoriesApi {
|
||||
return null;
|
||||
}
|
||||
|
||||
/// Performs an HTTP 'GET /memories' operation and returns the [Response].
|
||||
/// This endpoint requires the `memory.read` permission.
|
||||
///
|
||||
/// Note: This method returns the HTTP [Response].
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [DateTime] for_:
|
||||
@@ -381,6 +414,8 @@ class MemoriesApi {
|
||||
);
|
||||
}
|
||||
|
||||
/// This endpoint requires the `memory.read` permission.
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [DateTime] for_:
|
||||
@@ -408,7 +443,10 @@ class MemoriesApi {
|
||||
return null;
|
||||
}
|
||||
|
||||
/// Performs an HTTP 'PUT /memories/{id}' operation and returns the [Response].
|
||||
/// This endpoint requires the `memory.update` permission.
|
||||
///
|
||||
/// Note: This method returns the HTTP [Response].
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [String] id (required):
|
||||
@@ -440,6 +478,8 @@ class MemoriesApi {
|
||||
);
|
||||
}
|
||||
|
||||
/// This endpoint requires the `memory.update` permission.
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [String] id (required):
|
||||
|
||||
+36
-6
@@ -16,7 +16,10 @@ class NotificationsApi {
|
||||
|
||||
final ApiClient apiClient;
|
||||
|
||||
/// Performs an HTTP 'DELETE /notifications/{id}' operation and returns the [Response].
|
||||
/// This endpoint requires the `notification.delete` permission.
|
||||
///
|
||||
/// Note: This method returns the HTTP [Response].
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [String] id (required):
|
||||
@@ -46,6 +49,8 @@ class NotificationsApi {
|
||||
);
|
||||
}
|
||||
|
||||
/// This endpoint requires the `notification.delete` permission.
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [String] id (required):
|
||||
@@ -56,7 +61,10 @@ class NotificationsApi {
|
||||
}
|
||||
}
|
||||
|
||||
/// Performs an HTTP 'DELETE /notifications' operation and returns the [Response].
|
||||
/// This endpoint requires the `notification.delete` permission.
|
||||
///
|
||||
/// Note: This method returns the HTTP [Response].
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [NotificationDeleteAllDto] notificationDeleteAllDto (required):
|
||||
@@ -85,6 +93,8 @@ class NotificationsApi {
|
||||
);
|
||||
}
|
||||
|
||||
/// This endpoint requires the `notification.delete` permission.
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [NotificationDeleteAllDto] notificationDeleteAllDto (required):
|
||||
@@ -95,7 +105,10 @@ class NotificationsApi {
|
||||
}
|
||||
}
|
||||
|
||||
/// Performs an HTTP 'GET /notifications/{id}' operation and returns the [Response].
|
||||
/// This endpoint requires the `notification.read` permission.
|
||||
///
|
||||
/// Note: This method returns the HTTP [Response].
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [String] id (required):
|
||||
@@ -125,6 +138,8 @@ class NotificationsApi {
|
||||
);
|
||||
}
|
||||
|
||||
/// This endpoint requires the `notification.read` permission.
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [String] id (required):
|
||||
@@ -143,7 +158,10 @@ class NotificationsApi {
|
||||
return null;
|
||||
}
|
||||
|
||||
/// Performs an HTTP 'GET /notifications' operation and returns the [Response].
|
||||
/// This endpoint requires the `notification.read` permission.
|
||||
///
|
||||
/// Note: This method returns the HTTP [Response].
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [String] id:
|
||||
@@ -191,6 +209,8 @@ class NotificationsApi {
|
||||
);
|
||||
}
|
||||
|
||||
/// This endpoint requires the `notification.read` permission.
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [String] id:
|
||||
@@ -218,7 +238,10 @@ class NotificationsApi {
|
||||
return null;
|
||||
}
|
||||
|
||||
/// Performs an HTTP 'PUT /notifications/{id}' operation and returns the [Response].
|
||||
/// This endpoint requires the `notification.update` permission.
|
||||
///
|
||||
/// Note: This method returns the HTTP [Response].
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [String] id (required):
|
||||
@@ -250,6 +273,8 @@ class NotificationsApi {
|
||||
);
|
||||
}
|
||||
|
||||
/// This endpoint requires the `notification.update` permission.
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [String] id (required):
|
||||
@@ -270,7 +295,10 @@ class NotificationsApi {
|
||||
return null;
|
||||
}
|
||||
|
||||
/// Performs an HTTP 'PUT /notifications' operation and returns the [Response].
|
||||
/// This endpoint requires the `notification.update` permission.
|
||||
///
|
||||
/// Note: This method returns the HTTP [Response].
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [NotificationUpdateAllDto] notificationUpdateAllDto (required):
|
||||
@@ -299,6 +327,8 @@ class NotificationsApi {
|
||||
);
|
||||
}
|
||||
|
||||
/// This endpoint requires the `notification.update` permission.
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [NotificationUpdateAllDto] notificationUpdateAllDto (required):
|
||||
|
||||
Generated
+85
-13
@@ -16,11 +16,66 @@ class PartnersApi {
|
||||
|
||||
final ApiClient apiClient;
|
||||
|
||||
/// Performs an HTTP 'POST /partners/{id}' operation and returns the [Response].
|
||||
/// This endpoint requires the `partner.create` permission.
|
||||
///
|
||||
/// Note: This method returns the HTTP [Response].
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [PartnerCreateDto] partnerCreateDto (required):
|
||||
Future<Response> createPartnerWithHttpInfo(PartnerCreateDto partnerCreateDto,) async {
|
||||
// ignore: prefer_const_declarations
|
||||
final apiPath = r'/partners';
|
||||
|
||||
// ignore: prefer_final_locals
|
||||
Object? postBody = partnerCreateDto;
|
||||
|
||||
final queryParams = <QueryParam>[];
|
||||
final headerParams = <String, String>{};
|
||||
final formParams = <String, String>{};
|
||||
|
||||
const contentTypes = <String>['application/json'];
|
||||
|
||||
|
||||
return apiClient.invokeAPI(
|
||||
apiPath,
|
||||
'POST',
|
||||
queryParams,
|
||||
postBody,
|
||||
headerParams,
|
||||
formParams,
|
||||
contentTypes.isEmpty ? null : contentTypes.first,
|
||||
);
|
||||
}
|
||||
|
||||
/// This endpoint requires the `partner.create` permission.
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [PartnerCreateDto] partnerCreateDto (required):
|
||||
Future<PartnerResponseDto?> createPartner(PartnerCreateDto partnerCreateDto,) async {
|
||||
final response = await createPartnerWithHttpInfo(partnerCreateDto,);
|
||||
if (response.statusCode >= HttpStatus.badRequest) {
|
||||
throw ApiException(response.statusCode, await _decodeBodyBytes(response));
|
||||
}
|
||||
// When a remote server returns no body with a status of 204, we shall not decode it.
|
||||
// At the time of writing this, `dart:convert` will throw an "Unexpected end of input"
|
||||
// FormatException when trying to decode an empty string.
|
||||
if (response.body.isNotEmpty && response.statusCode != HttpStatus.noContent) {
|
||||
return await apiClient.deserializeAsync(await _decodeBodyBytes(response), 'PartnerResponseDto',) as PartnerResponseDto;
|
||||
|
||||
}
|
||||
return null;
|
||||
}
|
||||
|
||||
/// This property was deprecated in v1.141.0. This endpoint requires the `partner.create` permission.
|
||||
///
|
||||
/// Note: This method returns the HTTP [Response].
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [String] id (required):
|
||||
Future<Response> createPartnerWithHttpInfo(String id,) async {
|
||||
Future<Response> createPartnerDeprecatedWithHttpInfo(String id,) async {
|
||||
// ignore: prefer_const_declarations
|
||||
final apiPath = r'/partners/{id}'
|
||||
.replaceAll('{id}', id);
|
||||
@@ -46,11 +101,13 @@ class PartnersApi {
|
||||
);
|
||||
}
|
||||
|
||||
/// This property was deprecated in v1.141.0. This endpoint requires the `partner.create` permission.
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [String] id (required):
|
||||
Future<PartnerResponseDto?> createPartner(String id,) async {
|
||||
final response = await createPartnerWithHttpInfo(id,);
|
||||
Future<PartnerResponseDto?> createPartnerDeprecated(String id,) async {
|
||||
final response = await createPartnerDeprecatedWithHttpInfo(id,);
|
||||
if (response.statusCode >= HttpStatus.badRequest) {
|
||||
throw ApiException(response.statusCode, await _decodeBodyBytes(response));
|
||||
}
|
||||
@@ -64,7 +121,10 @@ class PartnersApi {
|
||||
return null;
|
||||
}
|
||||
|
||||
/// Performs an HTTP 'GET /partners' operation and returns the [Response].
|
||||
/// This endpoint requires the `partner.read` permission.
|
||||
///
|
||||
/// Note: This method returns the HTTP [Response].
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [PartnerDirection] direction (required):
|
||||
@@ -95,6 +155,8 @@ class PartnersApi {
|
||||
);
|
||||
}
|
||||
|
||||
/// This endpoint requires the `partner.read` permission.
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [PartnerDirection] direction (required):
|
||||
@@ -116,7 +178,10 @@ class PartnersApi {
|
||||
return null;
|
||||
}
|
||||
|
||||
/// Performs an HTTP 'DELETE /partners/{id}' operation and returns the [Response].
|
||||
/// This endpoint requires the `partner.delete` permission.
|
||||
///
|
||||
/// Note: This method returns the HTTP [Response].
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [String] id (required):
|
||||
@@ -146,6 +211,8 @@ class PartnersApi {
|
||||
);
|
||||
}
|
||||
|
||||
/// This endpoint requires the `partner.delete` permission.
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [String] id (required):
|
||||
@@ -156,19 +223,22 @@ class PartnersApi {
|
||||
}
|
||||
}
|
||||
|
||||
/// Performs an HTTP 'PUT /partners/{id}' operation and returns the [Response].
|
||||
/// This endpoint requires the `partner.update` permission.
|
||||
///
|
||||
/// Note: This method returns the HTTP [Response].
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [String] id (required):
|
||||
///
|
||||
/// * [UpdatePartnerDto] updatePartnerDto (required):
|
||||
Future<Response> updatePartnerWithHttpInfo(String id, UpdatePartnerDto updatePartnerDto,) async {
|
||||
/// * [PartnerUpdateDto] partnerUpdateDto (required):
|
||||
Future<Response> updatePartnerWithHttpInfo(String id, PartnerUpdateDto partnerUpdateDto,) async {
|
||||
// ignore: prefer_const_declarations
|
||||
final apiPath = r'/partners/{id}'
|
||||
.replaceAll('{id}', id);
|
||||
|
||||
// ignore: prefer_final_locals
|
||||
Object? postBody = updatePartnerDto;
|
||||
Object? postBody = partnerUpdateDto;
|
||||
|
||||
final queryParams = <QueryParam>[];
|
||||
final headerParams = <String, String>{};
|
||||
@@ -188,13 +258,15 @@ class PartnersApi {
|
||||
);
|
||||
}
|
||||
|
||||
/// This endpoint requires the `partner.update` permission.
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [String] id (required):
|
||||
///
|
||||
/// * [UpdatePartnerDto] updatePartnerDto (required):
|
||||
Future<PartnerResponseDto?> updatePartner(String id, UpdatePartnerDto updatePartnerDto,) async {
|
||||
final response = await updatePartnerWithHttpInfo(id, updatePartnerDto,);
|
||||
/// * [PartnerUpdateDto] partnerUpdateDto (required):
|
||||
Future<PartnerResponseDto?> updatePartner(String id, PartnerUpdateDto partnerUpdateDto,) async {
|
||||
final response = await updatePartnerWithHttpInfo(id, partnerUpdateDto,);
|
||||
if (response.statusCode >= HttpStatus.badRequest) {
|
||||
throw ApiException(response.statusCode, await _decodeBodyBytes(response));
|
||||
}
|
||||
|
||||
Generated
+66
-11
@@ -16,7 +16,10 @@ class PeopleApi {
|
||||
|
||||
final ApiClient apiClient;
|
||||
|
||||
/// Performs an HTTP 'POST /people' operation and returns the [Response].
|
||||
/// This endpoint requires the `person.create` permission.
|
||||
///
|
||||
/// Note: This method returns the HTTP [Response].
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [PersonCreateDto] personCreateDto (required):
|
||||
@@ -45,6 +48,8 @@ class PeopleApi {
|
||||
);
|
||||
}
|
||||
|
||||
/// This endpoint requires the `person.create` permission.
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [PersonCreateDto] personCreateDto (required):
|
||||
@@ -63,7 +68,10 @@ class PeopleApi {
|
||||
return null;
|
||||
}
|
||||
|
||||
/// Performs an HTTP 'DELETE /people' operation and returns the [Response].
|
||||
/// This endpoint requires the `person.delete` permission.
|
||||
///
|
||||
/// Note: This method returns the HTTP [Response].
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [BulkIdsDto] bulkIdsDto (required):
|
||||
@@ -92,6 +100,8 @@ class PeopleApi {
|
||||
);
|
||||
}
|
||||
|
||||
/// This endpoint requires the `person.delete` permission.
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [BulkIdsDto] bulkIdsDto (required):
|
||||
@@ -102,7 +112,10 @@ class PeopleApi {
|
||||
}
|
||||
}
|
||||
|
||||
/// Performs an HTTP 'DELETE /people/{id}' operation and returns the [Response].
|
||||
/// This endpoint requires the `person.delete` permission.
|
||||
///
|
||||
/// Note: This method returns the HTTP [Response].
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [String] id (required):
|
||||
@@ -132,6 +145,8 @@ class PeopleApi {
|
||||
);
|
||||
}
|
||||
|
||||
/// This endpoint requires the `person.delete` permission.
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [String] id (required):
|
||||
@@ -142,7 +157,10 @@ class PeopleApi {
|
||||
}
|
||||
}
|
||||
|
||||
/// Performs an HTTP 'GET /people' operation and returns the [Response].
|
||||
/// This endpoint requires the `person.read` permission.
|
||||
///
|
||||
/// Note: This method returns the HTTP [Response].
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [String] closestAssetId:
|
||||
@@ -197,6 +215,8 @@ class PeopleApi {
|
||||
);
|
||||
}
|
||||
|
||||
/// This endpoint requires the `person.read` permission.
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [String] closestAssetId:
|
||||
@@ -225,7 +245,10 @@ class PeopleApi {
|
||||
return null;
|
||||
}
|
||||
|
||||
/// Performs an HTTP 'GET /people/{id}' operation and returns the [Response].
|
||||
/// This endpoint requires the `person.read` permission.
|
||||
///
|
||||
/// Note: This method returns the HTTP [Response].
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [String] id (required):
|
||||
@@ -255,6 +278,8 @@ class PeopleApi {
|
||||
);
|
||||
}
|
||||
|
||||
/// This endpoint requires the `person.read` permission.
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [String] id (required):
|
||||
@@ -273,7 +298,10 @@ class PeopleApi {
|
||||
return null;
|
||||
}
|
||||
|
||||
/// Performs an HTTP 'GET /people/{id}/statistics' operation and returns the [Response].
|
||||
/// This endpoint requires the `person.statistics` permission.
|
||||
///
|
||||
/// Note: This method returns the HTTP [Response].
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [String] id (required):
|
||||
@@ -303,6 +331,8 @@ class PeopleApi {
|
||||
);
|
||||
}
|
||||
|
||||
/// This endpoint requires the `person.statistics` permission.
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [String] id (required):
|
||||
@@ -321,7 +351,10 @@ class PeopleApi {
|
||||
return null;
|
||||
}
|
||||
|
||||
/// Performs an HTTP 'GET /people/{id}/thumbnail' operation and returns the [Response].
|
||||
/// This endpoint requires the `person.read` permission.
|
||||
///
|
||||
/// Note: This method returns the HTTP [Response].
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [String] id (required):
|
||||
@@ -351,6 +384,8 @@ class PeopleApi {
|
||||
);
|
||||
}
|
||||
|
||||
/// This endpoint requires the `person.read` permission.
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [String] id (required):
|
||||
@@ -369,7 +404,10 @@ class PeopleApi {
|
||||
return null;
|
||||
}
|
||||
|
||||
/// Performs an HTTP 'POST /people/{id}/merge' operation and returns the [Response].
|
||||
/// This endpoint requires the `person.merge` permission.
|
||||
///
|
||||
/// Note: This method returns the HTTP [Response].
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [String] id (required):
|
||||
@@ -401,6 +439,8 @@ class PeopleApi {
|
||||
);
|
||||
}
|
||||
|
||||
/// This endpoint requires the `person.merge` permission.
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [String] id (required):
|
||||
@@ -424,7 +464,10 @@ class PeopleApi {
|
||||
return null;
|
||||
}
|
||||
|
||||
/// Performs an HTTP 'PUT /people/{id}/reassign' operation and returns the [Response].
|
||||
/// This endpoint requires the `person.reassign` permission.
|
||||
///
|
||||
/// Note: This method returns the HTTP [Response].
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [String] id (required):
|
||||
@@ -456,6 +499,8 @@ class PeopleApi {
|
||||
);
|
||||
}
|
||||
|
||||
/// This endpoint requires the `person.reassign` permission.
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [String] id (required):
|
||||
@@ -479,7 +524,10 @@ class PeopleApi {
|
||||
return null;
|
||||
}
|
||||
|
||||
/// Performs an HTTP 'PUT /people' operation and returns the [Response].
|
||||
/// This endpoint requires the `person.update` permission.
|
||||
///
|
||||
/// Note: This method returns the HTTP [Response].
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [PeopleUpdateDto] peopleUpdateDto (required):
|
||||
@@ -508,6 +556,8 @@ class PeopleApi {
|
||||
);
|
||||
}
|
||||
|
||||
/// This endpoint requires the `person.update` permission.
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [PeopleUpdateDto] peopleUpdateDto (required):
|
||||
@@ -529,7 +579,10 @@ class PeopleApi {
|
||||
return null;
|
||||
}
|
||||
|
||||
/// Performs an HTTP 'PUT /people/{id}' operation and returns the [Response].
|
||||
/// This endpoint requires the `person.update` permission.
|
||||
///
|
||||
/// Note: This method returns the HTTP [Response].
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [String] id (required):
|
||||
@@ -561,6 +614,8 @@ class PeopleApi {
|
||||
);
|
||||
}
|
||||
|
||||
/// This endpoint requires the `person.update` permission.
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [String] id (required):
|
||||
|
||||
Generated
+319
-9
@@ -16,7 +16,9 @@ class SearchApi {
|
||||
|
||||
final ApiClient apiClient;
|
||||
|
||||
/// Performs an HTTP 'GET /search/cities' operation and returns the [Response].
|
||||
/// This endpoint requires the `asset.read` permission.
|
||||
///
|
||||
/// Note: This method returns the HTTP [Response].
|
||||
Future<Response> getAssetsByCityWithHttpInfo() async {
|
||||
// ignore: prefer_const_declarations
|
||||
final apiPath = r'/search/cities';
|
||||
@@ -42,6 +44,7 @@ class SearchApi {
|
||||
);
|
||||
}
|
||||
|
||||
/// This endpoint requires the `asset.read` permission.
|
||||
Future<List<AssetResponseDto>?> getAssetsByCity() async {
|
||||
final response = await getAssetsByCityWithHttpInfo();
|
||||
if (response.statusCode >= HttpStatus.badRequest) {
|
||||
@@ -60,7 +63,9 @@ class SearchApi {
|
||||
return null;
|
||||
}
|
||||
|
||||
/// Performs an HTTP 'GET /search/explore' operation and returns the [Response].
|
||||
/// This endpoint requires the `asset.read` permission.
|
||||
///
|
||||
/// Note: This method returns the HTTP [Response].
|
||||
Future<Response> getExploreDataWithHttpInfo() async {
|
||||
// ignore: prefer_const_declarations
|
||||
final apiPath = r'/search/explore';
|
||||
@@ -86,6 +91,7 @@ class SearchApi {
|
||||
);
|
||||
}
|
||||
|
||||
/// This endpoint requires the `asset.read` permission.
|
||||
Future<List<SearchExploreResponseDto>?> getExploreData() async {
|
||||
final response = await getExploreDataWithHttpInfo();
|
||||
if (response.statusCode >= HttpStatus.badRequest) {
|
||||
@@ -104,7 +110,10 @@ class SearchApi {
|
||||
return null;
|
||||
}
|
||||
|
||||
/// Performs an HTTP 'GET /search/suggestions' operation and returns the [Response].
|
||||
/// This endpoint requires the `asset.read` permission.
|
||||
///
|
||||
/// Note: This method returns the HTTP [Response].
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [SearchSuggestionType] type (required):
|
||||
@@ -161,6 +170,8 @@ class SearchApi {
|
||||
);
|
||||
}
|
||||
|
||||
/// This endpoint requires the `asset.read` permission.
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [SearchSuggestionType] type (required):
|
||||
@@ -193,7 +204,10 @@ class SearchApi {
|
||||
return null;
|
||||
}
|
||||
|
||||
/// Performs an HTTP 'POST /search/statistics' operation and returns the [Response].
|
||||
/// This endpoint requires the `asset.statistics` permission.
|
||||
///
|
||||
/// Note: This method returns the HTTP [Response].
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [StatisticsSearchDto] statisticsSearchDto (required):
|
||||
@@ -222,6 +236,8 @@ class SearchApi {
|
||||
);
|
||||
}
|
||||
|
||||
/// This endpoint requires the `asset.statistics` permission.
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [StatisticsSearchDto] statisticsSearchDto (required):
|
||||
@@ -240,7 +256,10 @@ class SearchApi {
|
||||
return null;
|
||||
}
|
||||
|
||||
/// Performs an HTTP 'POST /search/metadata' operation and returns the [Response].
|
||||
/// This endpoint requires the `asset.read` permission.
|
||||
///
|
||||
/// Note: This method returns the HTTP [Response].
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [MetadataSearchDto] metadataSearchDto (required):
|
||||
@@ -269,6 +288,8 @@ class SearchApi {
|
||||
);
|
||||
}
|
||||
|
||||
/// This endpoint requires the `asset.read` permission.
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [MetadataSearchDto] metadataSearchDto (required):
|
||||
@@ -287,7 +308,279 @@ class SearchApi {
|
||||
return null;
|
||||
}
|
||||
|
||||
/// Performs an HTTP 'GET /search/person' operation and returns the [Response].
|
||||
/// This endpoint requires the `asset.read` permission.
|
||||
///
|
||||
/// Note: This method returns the HTTP [Response].
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [List<String>] albumIds:
|
||||
///
|
||||
/// * [String] city:
|
||||
///
|
||||
/// * [String] country:
|
||||
///
|
||||
/// * [DateTime] createdAfter:
|
||||
///
|
||||
/// * [DateTime] createdBefore:
|
||||
///
|
||||
/// * [String] deviceId:
|
||||
///
|
||||
/// * [bool] isEncoded:
|
||||
///
|
||||
/// * [bool] isFavorite:
|
||||
///
|
||||
/// * [bool] isMotion:
|
||||
///
|
||||
/// * [bool] isNotInAlbum:
|
||||
///
|
||||
/// * [bool] isOffline:
|
||||
///
|
||||
/// * [String] lensModel:
|
||||
///
|
||||
/// * [String] libraryId:
|
||||
///
|
||||
/// * [String] make:
|
||||
///
|
||||
/// * [int] minFileSize:
|
||||
///
|
||||
/// * [String] model:
|
||||
///
|
||||
/// * [List<String>] personIds:
|
||||
///
|
||||
/// * [num] rating:
|
||||
///
|
||||
/// * [num] size:
|
||||
///
|
||||
/// * [String] state:
|
||||
///
|
||||
/// * [List<String>] tagIds:
|
||||
///
|
||||
/// * [DateTime] takenAfter:
|
||||
///
|
||||
/// * [DateTime] takenBefore:
|
||||
///
|
||||
/// * [DateTime] trashedAfter:
|
||||
///
|
||||
/// * [DateTime] trashedBefore:
|
||||
///
|
||||
/// * [AssetTypeEnum] type:
|
||||
///
|
||||
/// * [DateTime] updatedAfter:
|
||||
///
|
||||
/// * [DateTime] updatedBefore:
|
||||
///
|
||||
/// * [AssetVisibility] visibility:
|
||||
///
|
||||
/// * [bool] withDeleted:
|
||||
///
|
||||
/// * [bool] withExif:
|
||||
Future<Response> searchLargeAssetsWithHttpInfo({ List<String>? albumIds, String? city, String? country, DateTime? createdAfter, DateTime? createdBefore, String? deviceId, bool? isEncoded, bool? isFavorite, bool? isMotion, bool? isNotInAlbum, bool? isOffline, String? lensModel, String? libraryId, String? make, int? minFileSize, String? model, List<String>? personIds, num? rating, num? size, String? state, List<String>? tagIds, DateTime? takenAfter, DateTime? takenBefore, DateTime? trashedAfter, DateTime? trashedBefore, AssetTypeEnum? type, DateTime? updatedAfter, DateTime? updatedBefore, AssetVisibility? visibility, bool? withDeleted, bool? withExif, }) async {
|
||||
// ignore: prefer_const_declarations
|
||||
final apiPath = r'/search/large-assets';
|
||||
|
||||
// ignore: prefer_final_locals
|
||||
Object? postBody;
|
||||
|
||||
final queryParams = <QueryParam>[];
|
||||
final headerParams = <String, String>{};
|
||||
final formParams = <String, String>{};
|
||||
|
||||
if (albumIds != null) {
|
||||
queryParams.addAll(_queryParams('multi', 'albumIds', albumIds));
|
||||
}
|
||||
if (city != null) {
|
||||
queryParams.addAll(_queryParams('', 'city', city));
|
||||
}
|
||||
if (country != null) {
|
||||
queryParams.addAll(_queryParams('', 'country', country));
|
||||
}
|
||||
if (createdAfter != null) {
|
||||
queryParams.addAll(_queryParams('', 'createdAfter', createdAfter));
|
||||
}
|
||||
if (createdBefore != null) {
|
||||
queryParams.addAll(_queryParams('', 'createdBefore', createdBefore));
|
||||
}
|
||||
if (deviceId != null) {
|
||||
queryParams.addAll(_queryParams('', 'deviceId', deviceId));
|
||||
}
|
||||
if (isEncoded != null) {
|
||||
queryParams.addAll(_queryParams('', 'isEncoded', isEncoded));
|
||||
}
|
||||
if (isFavorite != null) {
|
||||
queryParams.addAll(_queryParams('', 'isFavorite', isFavorite));
|
||||
}
|
||||
if (isMotion != null) {
|
||||
queryParams.addAll(_queryParams('', 'isMotion', isMotion));
|
||||
}
|
||||
if (isNotInAlbum != null) {
|
||||
queryParams.addAll(_queryParams('', 'isNotInAlbum', isNotInAlbum));
|
||||
}
|
||||
if (isOffline != null) {
|
||||
queryParams.addAll(_queryParams('', 'isOffline', isOffline));
|
||||
}
|
||||
if (lensModel != null) {
|
||||
queryParams.addAll(_queryParams('', 'lensModel', lensModel));
|
||||
}
|
||||
if (libraryId != null) {
|
||||
queryParams.addAll(_queryParams('', 'libraryId', libraryId));
|
||||
}
|
||||
if (make != null) {
|
||||
queryParams.addAll(_queryParams('', 'make', make));
|
||||
}
|
||||
if (minFileSize != null) {
|
||||
queryParams.addAll(_queryParams('', 'minFileSize', minFileSize));
|
||||
}
|
||||
if (model != null) {
|
||||
queryParams.addAll(_queryParams('', 'model', model));
|
||||
}
|
||||
if (personIds != null) {
|
||||
queryParams.addAll(_queryParams('multi', 'personIds', personIds));
|
||||
}
|
||||
if (rating != null) {
|
||||
queryParams.addAll(_queryParams('', 'rating', rating));
|
||||
}
|
||||
if (size != null) {
|
||||
queryParams.addAll(_queryParams('', 'size', size));
|
||||
}
|
||||
if (state != null) {
|
||||
queryParams.addAll(_queryParams('', 'state', state));
|
||||
}
|
||||
if (tagIds != null) {
|
||||
queryParams.addAll(_queryParams('multi', 'tagIds', tagIds));
|
||||
}
|
||||
if (takenAfter != null) {
|
||||
queryParams.addAll(_queryParams('', 'takenAfter', takenAfter));
|
||||
}
|
||||
if (takenBefore != null) {
|
||||
queryParams.addAll(_queryParams('', 'takenBefore', takenBefore));
|
||||
}
|
||||
if (trashedAfter != null) {
|
||||
queryParams.addAll(_queryParams('', 'trashedAfter', trashedAfter));
|
||||
}
|
||||
if (trashedBefore != null) {
|
||||
queryParams.addAll(_queryParams('', 'trashedBefore', trashedBefore));
|
||||
}
|
||||
if (type != null) {
|
||||
queryParams.addAll(_queryParams('', 'type', type));
|
||||
}
|
||||
if (updatedAfter != null) {
|
||||
queryParams.addAll(_queryParams('', 'updatedAfter', updatedAfter));
|
||||
}
|
||||
if (updatedBefore != null) {
|
||||
queryParams.addAll(_queryParams('', 'updatedBefore', updatedBefore));
|
||||
}
|
||||
if (visibility != null) {
|
||||
queryParams.addAll(_queryParams('', 'visibility', visibility));
|
||||
}
|
||||
if (withDeleted != null) {
|
||||
queryParams.addAll(_queryParams('', 'withDeleted', withDeleted));
|
||||
}
|
||||
if (withExif != null) {
|
||||
queryParams.addAll(_queryParams('', 'withExif', withExif));
|
||||
}
|
||||
|
||||
const contentTypes = <String>[];
|
||||
|
||||
|
||||
return apiClient.invokeAPI(
|
||||
apiPath,
|
||||
'POST',
|
||||
queryParams,
|
||||
postBody,
|
||||
headerParams,
|
||||
formParams,
|
||||
contentTypes.isEmpty ? null : contentTypes.first,
|
||||
);
|
||||
}
|
||||
|
||||
/// This endpoint requires the `asset.read` permission.
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [List<String>] albumIds:
|
||||
///
|
||||
/// * [String] city:
|
||||
///
|
||||
/// * [String] country:
|
||||
///
|
||||
/// * [DateTime] createdAfter:
|
||||
///
|
||||
/// * [DateTime] createdBefore:
|
||||
///
|
||||
/// * [String] deviceId:
|
||||
///
|
||||
/// * [bool] isEncoded:
|
||||
///
|
||||
/// * [bool] isFavorite:
|
||||
///
|
||||
/// * [bool] isMotion:
|
||||
///
|
||||
/// * [bool] isNotInAlbum:
|
||||
///
|
||||
/// * [bool] isOffline:
|
||||
///
|
||||
/// * [String] lensModel:
|
||||
///
|
||||
/// * [String] libraryId:
|
||||
///
|
||||
/// * [String] make:
|
||||
///
|
||||
/// * [int] minFileSize:
|
||||
///
|
||||
/// * [String] model:
|
||||
///
|
||||
/// * [List<String>] personIds:
|
||||
///
|
||||
/// * [num] rating:
|
||||
///
|
||||
/// * [num] size:
|
||||
///
|
||||
/// * [String] state:
|
||||
///
|
||||
/// * [List<String>] tagIds:
|
||||
///
|
||||
/// * [DateTime] takenAfter:
|
||||
///
|
||||
/// * [DateTime] takenBefore:
|
||||
///
|
||||
/// * [DateTime] trashedAfter:
|
||||
///
|
||||
/// * [DateTime] trashedBefore:
|
||||
///
|
||||
/// * [AssetTypeEnum] type:
|
||||
///
|
||||
/// * [DateTime] updatedAfter:
|
||||
///
|
||||
/// * [DateTime] updatedBefore:
|
||||
///
|
||||
/// * [AssetVisibility] visibility:
|
||||
///
|
||||
/// * [bool] withDeleted:
|
||||
///
|
||||
/// * [bool] withExif:
|
||||
Future<List<AssetResponseDto>?> searchLargeAssets({ List<String>? albumIds, String? city, String? country, DateTime? createdAfter, DateTime? createdBefore, String? deviceId, bool? isEncoded, bool? isFavorite, bool? isMotion, bool? isNotInAlbum, bool? isOffline, String? lensModel, String? libraryId, String? make, int? minFileSize, String? model, List<String>? personIds, num? rating, num? size, String? state, List<String>? tagIds, DateTime? takenAfter, DateTime? takenBefore, DateTime? trashedAfter, DateTime? trashedBefore, AssetTypeEnum? type, DateTime? updatedAfter, DateTime? updatedBefore, AssetVisibility? visibility, bool? withDeleted, bool? withExif, }) async {
|
||||
final response = await searchLargeAssetsWithHttpInfo( albumIds: albumIds, city: city, country: country, createdAfter: createdAfter, createdBefore: createdBefore, deviceId: deviceId, isEncoded: isEncoded, isFavorite: isFavorite, isMotion: isMotion, isNotInAlbum: isNotInAlbum, isOffline: isOffline, lensModel: lensModel, libraryId: libraryId, make: make, minFileSize: minFileSize, model: model, personIds: personIds, rating: rating, size: size, state: state, tagIds: tagIds, takenAfter: takenAfter, takenBefore: takenBefore, trashedAfter: trashedAfter, trashedBefore: trashedBefore, type: type, updatedAfter: updatedAfter, updatedBefore: updatedBefore, visibility: visibility, withDeleted: withDeleted, withExif: withExif, );
|
||||
if (response.statusCode >= HttpStatus.badRequest) {
|
||||
throw ApiException(response.statusCode, await _decodeBodyBytes(response));
|
||||
}
|
||||
// When a remote server returns no body with a status of 204, we shall not decode it.
|
||||
// At the time of writing this, `dart:convert` will throw an "Unexpected end of input"
|
||||
// FormatException when trying to decode an empty string.
|
||||
if (response.body.isNotEmpty && response.statusCode != HttpStatus.noContent) {
|
||||
final responseBody = await _decodeBodyBytes(response);
|
||||
return (await apiClient.deserializeAsync(responseBody, 'List<AssetResponseDto>') as List)
|
||||
.cast<AssetResponseDto>()
|
||||
.toList(growable: false);
|
||||
|
||||
}
|
||||
return null;
|
||||
}
|
||||
|
||||
/// This endpoint requires the `person.read` permission.
|
||||
///
|
||||
/// Note: This method returns the HTTP [Response].
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [String] name (required):
|
||||
@@ -323,6 +616,8 @@ class SearchApi {
|
||||
);
|
||||
}
|
||||
|
||||
/// This endpoint requires the `person.read` permission.
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [String] name (required):
|
||||
@@ -346,7 +641,10 @@ class SearchApi {
|
||||
return null;
|
||||
}
|
||||
|
||||
/// Performs an HTTP 'GET /search/places' operation and returns the [Response].
|
||||
/// This endpoint requires the `asset.read` permission.
|
||||
///
|
||||
/// Note: This method returns the HTTP [Response].
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [String] name (required):
|
||||
@@ -377,6 +675,8 @@ class SearchApi {
|
||||
);
|
||||
}
|
||||
|
||||
/// This endpoint requires the `asset.read` permission.
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [String] name (required):
|
||||
@@ -398,7 +698,10 @@ class SearchApi {
|
||||
return null;
|
||||
}
|
||||
|
||||
/// Performs an HTTP 'POST /search/random' operation and returns the [Response].
|
||||
/// This endpoint requires the `asset.read` permission.
|
||||
///
|
||||
/// Note: This method returns the HTTP [Response].
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [RandomSearchDto] randomSearchDto (required):
|
||||
@@ -427,6 +730,8 @@ class SearchApi {
|
||||
);
|
||||
}
|
||||
|
||||
/// This endpoint requires the `asset.read` permission.
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [RandomSearchDto] randomSearchDto (required):
|
||||
@@ -448,7 +753,10 @@ class SearchApi {
|
||||
return null;
|
||||
}
|
||||
|
||||
/// Performs an HTTP 'POST /search/smart' operation and returns the [Response].
|
||||
/// This endpoint requires the `asset.read` permission.
|
||||
///
|
||||
/// Note: This method returns the HTTP [Response].
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [SmartSearchDto] smartSearchDto (required):
|
||||
@@ -477,6 +785,8 @@ class SearchApi {
|
||||
);
|
||||
}
|
||||
|
||||
/// This endpoint requires the `asset.read` permission.
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [SmartSearchDto] smartSearchDto (required):
|
||||
|
||||
Generated
+34
-8
@@ -16,7 +16,9 @@ class ServerApi {
|
||||
|
||||
final ApiClient apiClient;
|
||||
|
||||
/// Performs an HTTP 'DELETE /server/license' operation and returns the [Response].
|
||||
/// This endpoint is an admin-only route, and requires the `serverLicense.delete` permission.
|
||||
///
|
||||
/// Note: This method returns the HTTP [Response].
|
||||
Future<Response> deleteServerLicenseWithHttpInfo() async {
|
||||
// ignore: prefer_const_declarations
|
||||
final apiPath = r'/server/license';
|
||||
@@ -42,6 +44,7 @@ class ServerApi {
|
||||
);
|
||||
}
|
||||
|
||||
/// This endpoint is an admin-only route, and requires the `serverLicense.delete` permission.
|
||||
Future<void> deleteServerLicense() async {
|
||||
final response = await deleteServerLicenseWithHttpInfo();
|
||||
if (response.statusCode >= HttpStatus.badRequest) {
|
||||
@@ -49,7 +52,9 @@ class ServerApi {
|
||||
}
|
||||
}
|
||||
|
||||
/// Performs an HTTP 'GET /server/about' operation and returns the [Response].
|
||||
/// This endpoint requires the `server.about` permission.
|
||||
///
|
||||
/// Note: This method returns the HTTP [Response].
|
||||
Future<Response> getAboutInfoWithHttpInfo() async {
|
||||
// ignore: prefer_const_declarations
|
||||
final apiPath = r'/server/about';
|
||||
@@ -75,6 +80,7 @@ class ServerApi {
|
||||
);
|
||||
}
|
||||
|
||||
/// This endpoint requires the `server.about` permission.
|
||||
Future<ServerAboutResponseDto?> getAboutInfo() async {
|
||||
final response = await getAboutInfoWithHttpInfo();
|
||||
if (response.statusCode >= HttpStatus.badRequest) {
|
||||
@@ -90,7 +96,9 @@ class ServerApi {
|
||||
return null;
|
||||
}
|
||||
|
||||
/// Performs an HTTP 'GET /server/apk-links' operation and returns the [Response].
|
||||
/// This endpoint requires the `server.apkLinks` permission.
|
||||
///
|
||||
/// Note: This method returns the HTTP [Response].
|
||||
Future<Response> getApkLinksWithHttpInfo() async {
|
||||
// ignore: prefer_const_declarations
|
||||
final apiPath = r'/server/apk-links';
|
||||
@@ -116,6 +124,7 @@ class ServerApi {
|
||||
);
|
||||
}
|
||||
|
||||
/// This endpoint requires the `server.apkLinks` permission.
|
||||
Future<ServerApkLinksDto?> getApkLinks() async {
|
||||
final response = await getApkLinksWithHttpInfo();
|
||||
if (response.statusCode >= HttpStatus.badRequest) {
|
||||
@@ -213,7 +222,9 @@ class ServerApi {
|
||||
return null;
|
||||
}
|
||||
|
||||
/// Performs an HTTP 'GET /server/license' operation and returns the [Response].
|
||||
/// This endpoint is an admin-only route, and requires the `serverLicense.read` permission.
|
||||
///
|
||||
/// Note: This method returns the HTTP [Response].
|
||||
Future<Response> getServerLicenseWithHttpInfo() async {
|
||||
// ignore: prefer_const_declarations
|
||||
final apiPath = r'/server/license';
|
||||
@@ -239,6 +250,7 @@ class ServerApi {
|
||||
);
|
||||
}
|
||||
|
||||
/// This endpoint is an admin-only route, and requires the `serverLicense.read` permission.
|
||||
Future<LicenseResponseDto?> getServerLicense() async {
|
||||
final response = await getServerLicenseWithHttpInfo();
|
||||
if (response.statusCode >= HttpStatus.badRequest) {
|
||||
@@ -254,7 +266,9 @@ class ServerApi {
|
||||
return null;
|
||||
}
|
||||
|
||||
/// Performs an HTTP 'GET /server/statistics' operation and returns the [Response].
|
||||
/// This endpoint is an admin-only route, and requires the `server.statistics` permission.
|
||||
///
|
||||
/// Note: This method returns the HTTP [Response].
|
||||
Future<Response> getServerStatisticsWithHttpInfo() async {
|
||||
// ignore: prefer_const_declarations
|
||||
final apiPath = r'/server/statistics';
|
||||
@@ -280,6 +294,7 @@ class ServerApi {
|
||||
);
|
||||
}
|
||||
|
||||
/// This endpoint is an admin-only route, and requires the `server.statistics` permission.
|
||||
Future<ServerStatsResponseDto?> getServerStatistics() async {
|
||||
final response = await getServerStatisticsWithHttpInfo();
|
||||
if (response.statusCode >= HttpStatus.badRequest) {
|
||||
@@ -336,7 +351,9 @@ class ServerApi {
|
||||
return null;
|
||||
}
|
||||
|
||||
/// Performs an HTTP 'GET /server/storage' operation and returns the [Response].
|
||||
/// This endpoint requires the `server.storage` permission.
|
||||
///
|
||||
/// Note: This method returns the HTTP [Response].
|
||||
Future<Response> getStorageWithHttpInfo() async {
|
||||
// ignore: prefer_const_declarations
|
||||
final apiPath = r'/server/storage';
|
||||
@@ -362,6 +379,7 @@ class ServerApi {
|
||||
);
|
||||
}
|
||||
|
||||
/// This endpoint requires the `server.storage` permission.
|
||||
Future<ServerStorageResponseDto?> getStorage() async {
|
||||
final response = await getStorageWithHttpInfo();
|
||||
if (response.statusCode >= HttpStatus.badRequest) {
|
||||
@@ -459,7 +477,9 @@ class ServerApi {
|
||||
return null;
|
||||
}
|
||||
|
||||
/// Performs an HTTP 'GET /server/version-check' operation and returns the [Response].
|
||||
/// This endpoint requires the `server.versionCheck` permission.
|
||||
///
|
||||
/// Note: This method returns the HTTP [Response].
|
||||
Future<Response> getVersionCheckWithHttpInfo() async {
|
||||
// ignore: prefer_const_declarations
|
||||
final apiPath = r'/server/version-check';
|
||||
@@ -485,6 +505,7 @@ class ServerApi {
|
||||
);
|
||||
}
|
||||
|
||||
/// This endpoint requires the `server.versionCheck` permission.
|
||||
Future<VersionCheckStateResponseDto?> getVersionCheck() async {
|
||||
final response = await getVersionCheckWithHttpInfo();
|
||||
if (response.statusCode >= HttpStatus.badRequest) {
|
||||
@@ -585,7 +606,10 @@ class ServerApi {
|
||||
return null;
|
||||
}
|
||||
|
||||
/// Performs an HTTP 'PUT /server/license' operation and returns the [Response].
|
||||
/// This endpoint is an admin-only route, and requires the `serverLicense.update` permission.
|
||||
///
|
||||
/// Note: This method returns the HTTP [Response].
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [LicenseKeyDto] licenseKeyDto (required):
|
||||
@@ -614,6 +638,8 @@ class ServerApi {
|
||||
);
|
||||
}
|
||||
|
||||
/// This endpoint is an admin-only route, and requires the `serverLicense.update` permission.
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [LicenseKeyDto] licenseKeyDto (required):
|
||||
|
||||
Generated
+32
-6
@@ -16,7 +16,10 @@ class SessionsApi {
|
||||
|
||||
final ApiClient apiClient;
|
||||
|
||||
/// Performs an HTTP 'POST /sessions' operation and returns the [Response].
|
||||
/// This endpoint requires the `session.create` permission.
|
||||
///
|
||||
/// Note: This method returns the HTTP [Response].
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [SessionCreateDto] sessionCreateDto (required):
|
||||
@@ -45,6 +48,8 @@ class SessionsApi {
|
||||
);
|
||||
}
|
||||
|
||||
/// This endpoint requires the `session.create` permission.
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [SessionCreateDto] sessionCreateDto (required):
|
||||
@@ -63,7 +68,9 @@ class SessionsApi {
|
||||
return null;
|
||||
}
|
||||
|
||||
/// Performs an HTTP 'DELETE /sessions' operation and returns the [Response].
|
||||
/// This endpoint requires the `session.delete` permission.
|
||||
///
|
||||
/// Note: This method returns the HTTP [Response].
|
||||
Future<Response> deleteAllSessionsWithHttpInfo() async {
|
||||
// ignore: prefer_const_declarations
|
||||
final apiPath = r'/sessions';
|
||||
@@ -89,6 +96,7 @@ class SessionsApi {
|
||||
);
|
||||
}
|
||||
|
||||
/// This endpoint requires the `session.delete` permission.
|
||||
Future<void> deleteAllSessions() async {
|
||||
final response = await deleteAllSessionsWithHttpInfo();
|
||||
if (response.statusCode >= HttpStatus.badRequest) {
|
||||
@@ -96,7 +104,10 @@ class SessionsApi {
|
||||
}
|
||||
}
|
||||
|
||||
/// Performs an HTTP 'DELETE /sessions/{id}' operation and returns the [Response].
|
||||
/// This endpoint requires the `session.delete` permission.
|
||||
///
|
||||
/// Note: This method returns the HTTP [Response].
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [String] id (required):
|
||||
@@ -126,6 +137,8 @@ class SessionsApi {
|
||||
);
|
||||
}
|
||||
|
||||
/// This endpoint requires the `session.delete` permission.
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [String] id (required):
|
||||
@@ -136,7 +149,9 @@ class SessionsApi {
|
||||
}
|
||||
}
|
||||
|
||||
/// Performs an HTTP 'GET /sessions' operation and returns the [Response].
|
||||
/// This endpoint requires the `session.read` permission.
|
||||
///
|
||||
/// Note: This method returns the HTTP [Response].
|
||||
Future<Response> getSessionsWithHttpInfo() async {
|
||||
// ignore: prefer_const_declarations
|
||||
final apiPath = r'/sessions';
|
||||
@@ -162,6 +177,7 @@ class SessionsApi {
|
||||
);
|
||||
}
|
||||
|
||||
/// This endpoint requires the `session.read` permission.
|
||||
Future<List<SessionResponseDto>?> getSessions() async {
|
||||
final response = await getSessionsWithHttpInfo();
|
||||
if (response.statusCode >= HttpStatus.badRequest) {
|
||||
@@ -180,7 +196,10 @@ class SessionsApi {
|
||||
return null;
|
||||
}
|
||||
|
||||
/// Performs an HTTP 'POST /sessions/{id}/lock' operation and returns the [Response].
|
||||
/// This endpoint requires the `session.lock` permission.
|
||||
///
|
||||
/// Note: This method returns the HTTP [Response].
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [String] id (required):
|
||||
@@ -210,6 +229,8 @@ class SessionsApi {
|
||||
);
|
||||
}
|
||||
|
||||
/// This endpoint requires the `session.lock` permission.
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [String] id (required):
|
||||
@@ -220,7 +241,10 @@ class SessionsApi {
|
||||
}
|
||||
}
|
||||
|
||||
/// Performs an HTTP 'PUT /sessions/{id}' operation and returns the [Response].
|
||||
/// This endpoint requires the `session.update` permission.
|
||||
///
|
||||
/// Note: This method returns the HTTP [Response].
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [String] id (required):
|
||||
@@ -252,6 +276,8 @@ class SessionsApi {
|
||||
);
|
||||
}
|
||||
|
||||
/// This endpoint requires the `session.update` permission.
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [String] id (required):
|
||||
|
||||
+67
-21
@@ -24,7 +24,9 @@ class SharedLinksApi {
|
||||
/// * [AssetIdsDto] assetIdsDto (required):
|
||||
///
|
||||
/// * [String] key:
|
||||
Future<Response> addSharedLinkAssetsWithHttpInfo(String id, AssetIdsDto assetIdsDto, { String? key, }) async {
|
||||
///
|
||||
/// * [String] slug:
|
||||
Future<Response> addSharedLinkAssetsWithHttpInfo(String id, AssetIdsDto assetIdsDto, { String? key, String? slug, }) async {
|
||||
// ignore: prefer_const_declarations
|
||||
final apiPath = r'/shared-links/{id}/assets'
|
||||
.replaceAll('{id}', id);
|
||||
@@ -39,6 +41,9 @@ class SharedLinksApi {
|
||||
if (key != null) {
|
||||
queryParams.addAll(_queryParams('', 'key', key));
|
||||
}
|
||||
if (slug != null) {
|
||||
queryParams.addAll(_queryParams('', 'slug', slug));
|
||||
}
|
||||
|
||||
const contentTypes = <String>['application/json'];
|
||||
|
||||
@@ -61,8 +66,10 @@ class SharedLinksApi {
|
||||
/// * [AssetIdsDto] assetIdsDto (required):
|
||||
///
|
||||
/// * [String] key:
|
||||
Future<List<AssetIdsResponseDto>?> addSharedLinkAssets(String id, AssetIdsDto assetIdsDto, { String? key, }) async {
|
||||
final response = await addSharedLinkAssetsWithHttpInfo(id, assetIdsDto, key: key, );
|
||||
///
|
||||
/// * [String] slug:
|
||||
Future<List<AssetIdsResponseDto>?> addSharedLinkAssets(String id, AssetIdsDto assetIdsDto, { String? key, String? slug, }) async {
|
||||
final response = await addSharedLinkAssetsWithHttpInfo(id, assetIdsDto, key: key, slug: slug, );
|
||||
if (response.statusCode >= HttpStatus.badRequest) {
|
||||
throw ApiException(response.statusCode, await _decodeBodyBytes(response));
|
||||
}
|
||||
@@ -79,7 +86,10 @@ class SharedLinksApi {
|
||||
return null;
|
||||
}
|
||||
|
||||
/// Performs an HTTP 'POST /shared-links' operation and returns the [Response].
|
||||
/// This endpoint requires the `sharedLink.create` permission.
|
||||
///
|
||||
/// Note: This method returns the HTTP [Response].
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [SharedLinkCreateDto] sharedLinkCreateDto (required):
|
||||
@@ -108,6 +118,8 @@ class SharedLinksApi {
|
||||
);
|
||||
}
|
||||
|
||||
/// This endpoint requires the `sharedLink.create` permission.
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [SharedLinkCreateDto] sharedLinkCreateDto (required):
|
||||
@@ -126,7 +138,10 @@ class SharedLinksApi {
|
||||
return null;
|
||||
}
|
||||
|
||||
/// Performs an HTTP 'GET /shared-links' operation and returns the [Response].
|
||||
/// This endpoint requires the `sharedLink.read` permission.
|
||||
///
|
||||
/// Note: This method returns the HTTP [Response].
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [String] albumId:
|
||||
@@ -159,6 +174,8 @@ class SharedLinksApi {
|
||||
);
|
||||
}
|
||||
|
||||
/// This endpoint requires the `sharedLink.read` permission.
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [String] albumId:
|
||||
@@ -183,12 +200,14 @@ class SharedLinksApi {
|
||||
/// Performs an HTTP 'GET /shared-links/me' operation and returns the [Response].
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [String] key:
|
||||
///
|
||||
/// * [String] password:
|
||||
///
|
||||
/// * [String] token:
|
||||
Future<Response> getMySharedLinkWithHttpInfo({ String? key, String? password, String? token, }) async {
|
||||
///
|
||||
/// * [String] key:
|
||||
///
|
||||
/// * [String] slug:
|
||||
Future<Response> getMySharedLinkWithHttpInfo({ String? password, String? token, String? key, String? slug, }) async {
|
||||
// ignore: prefer_const_declarations
|
||||
final apiPath = r'/shared-links/me';
|
||||
|
||||
@@ -199,15 +218,18 @@ class SharedLinksApi {
|
||||
final headerParams = <String, String>{};
|
||||
final formParams = <String, String>{};
|
||||
|
||||
if (key != null) {
|
||||
queryParams.addAll(_queryParams('', 'key', key));
|
||||
}
|
||||
if (password != null) {
|
||||
queryParams.addAll(_queryParams('', 'password', password));
|
||||
}
|
||||
if (token != null) {
|
||||
queryParams.addAll(_queryParams('', 'token', token));
|
||||
}
|
||||
if (key != null) {
|
||||
queryParams.addAll(_queryParams('', 'key', key));
|
||||
}
|
||||
if (slug != null) {
|
||||
queryParams.addAll(_queryParams('', 'slug', slug));
|
||||
}
|
||||
|
||||
const contentTypes = <String>[];
|
||||
|
||||
@@ -225,13 +247,15 @@ class SharedLinksApi {
|
||||
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [String] key:
|
||||
///
|
||||
/// * [String] password:
|
||||
///
|
||||
/// * [String] token:
|
||||
Future<SharedLinkResponseDto?> getMySharedLink({ String? key, String? password, String? token, }) async {
|
||||
final response = await getMySharedLinkWithHttpInfo( key: key, password: password, token: token, );
|
||||
///
|
||||
/// * [String] key:
|
||||
///
|
||||
/// * [String] slug:
|
||||
Future<SharedLinkResponseDto?> getMySharedLink({ String? password, String? token, String? key, String? slug, }) async {
|
||||
final response = await getMySharedLinkWithHttpInfo( password: password, token: token, key: key, slug: slug, );
|
||||
if (response.statusCode >= HttpStatus.badRequest) {
|
||||
throw ApiException(response.statusCode, await _decodeBodyBytes(response));
|
||||
}
|
||||
@@ -245,7 +269,10 @@ class SharedLinksApi {
|
||||
return null;
|
||||
}
|
||||
|
||||
/// Performs an HTTP 'GET /shared-links/{id}' operation and returns the [Response].
|
||||
/// This endpoint requires the `sharedLink.read` permission.
|
||||
///
|
||||
/// Note: This method returns the HTTP [Response].
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [String] id (required):
|
||||
@@ -275,6 +302,8 @@ class SharedLinksApi {
|
||||
);
|
||||
}
|
||||
|
||||
/// This endpoint requires the `sharedLink.read` permission.
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [String] id (required):
|
||||
@@ -293,7 +322,10 @@ class SharedLinksApi {
|
||||
return null;
|
||||
}
|
||||
|
||||
/// Performs an HTTP 'DELETE /shared-links/{id}' operation and returns the [Response].
|
||||
/// This endpoint requires the `sharedLink.delete` permission.
|
||||
///
|
||||
/// Note: This method returns the HTTP [Response].
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [String] id (required):
|
||||
@@ -323,6 +355,8 @@ class SharedLinksApi {
|
||||
);
|
||||
}
|
||||
|
||||
/// This endpoint requires the `sharedLink.delete` permission.
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [String] id (required):
|
||||
@@ -341,7 +375,9 @@ class SharedLinksApi {
|
||||
/// * [AssetIdsDto] assetIdsDto (required):
|
||||
///
|
||||
/// * [String] key:
|
||||
Future<Response> removeSharedLinkAssetsWithHttpInfo(String id, AssetIdsDto assetIdsDto, { String? key, }) async {
|
||||
///
|
||||
/// * [String] slug:
|
||||
Future<Response> removeSharedLinkAssetsWithHttpInfo(String id, AssetIdsDto assetIdsDto, { String? key, String? slug, }) async {
|
||||
// ignore: prefer_const_declarations
|
||||
final apiPath = r'/shared-links/{id}/assets'
|
||||
.replaceAll('{id}', id);
|
||||
@@ -356,6 +392,9 @@ class SharedLinksApi {
|
||||
if (key != null) {
|
||||
queryParams.addAll(_queryParams('', 'key', key));
|
||||
}
|
||||
if (slug != null) {
|
||||
queryParams.addAll(_queryParams('', 'slug', slug));
|
||||
}
|
||||
|
||||
const contentTypes = <String>['application/json'];
|
||||
|
||||
@@ -378,8 +417,10 @@ class SharedLinksApi {
|
||||
/// * [AssetIdsDto] assetIdsDto (required):
|
||||
///
|
||||
/// * [String] key:
|
||||
Future<List<AssetIdsResponseDto>?> removeSharedLinkAssets(String id, AssetIdsDto assetIdsDto, { String? key, }) async {
|
||||
final response = await removeSharedLinkAssetsWithHttpInfo(id, assetIdsDto, key: key, );
|
||||
///
|
||||
/// * [String] slug:
|
||||
Future<List<AssetIdsResponseDto>?> removeSharedLinkAssets(String id, AssetIdsDto assetIdsDto, { String? key, String? slug, }) async {
|
||||
final response = await removeSharedLinkAssetsWithHttpInfo(id, assetIdsDto, key: key, slug: slug, );
|
||||
if (response.statusCode >= HttpStatus.badRequest) {
|
||||
throw ApiException(response.statusCode, await _decodeBodyBytes(response));
|
||||
}
|
||||
@@ -396,7 +437,10 @@ class SharedLinksApi {
|
||||
return null;
|
||||
}
|
||||
|
||||
/// Performs an HTTP 'PATCH /shared-links/{id}' operation and returns the [Response].
|
||||
/// This endpoint requires the `sharedLink.update` permission.
|
||||
///
|
||||
/// Note: This method returns the HTTP [Response].
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [String] id (required):
|
||||
@@ -428,6 +472,8 @@ class SharedLinksApi {
|
||||
);
|
||||
}
|
||||
|
||||
/// This endpoint requires the `sharedLink.update` permission.
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [String] id (required):
|
||||
|
||||
Generated
+86
-6
@@ -16,7 +16,10 @@ class StacksApi {
|
||||
|
||||
final ApiClient apiClient;
|
||||
|
||||
/// Performs an HTTP 'POST /stacks' operation and returns the [Response].
|
||||
/// This endpoint requires the `stack.create` permission.
|
||||
///
|
||||
/// Note: This method returns the HTTP [Response].
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [StackCreateDto] stackCreateDto (required):
|
||||
@@ -45,6 +48,8 @@ class StacksApi {
|
||||
);
|
||||
}
|
||||
|
||||
/// This endpoint requires the `stack.create` permission.
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [StackCreateDto] stackCreateDto (required):
|
||||
@@ -63,7 +68,10 @@ class StacksApi {
|
||||
return null;
|
||||
}
|
||||
|
||||
/// Performs an HTTP 'DELETE /stacks/{id}' operation and returns the [Response].
|
||||
/// This endpoint requires the `stack.delete` permission.
|
||||
///
|
||||
/// Note: This method returns the HTTP [Response].
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [String] id (required):
|
||||
@@ -93,6 +101,8 @@ class StacksApi {
|
||||
);
|
||||
}
|
||||
|
||||
/// This endpoint requires the `stack.delete` permission.
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [String] id (required):
|
||||
@@ -103,7 +113,10 @@ class StacksApi {
|
||||
}
|
||||
}
|
||||
|
||||
/// Performs an HTTP 'DELETE /stacks' operation and returns the [Response].
|
||||
/// This endpoint requires the `stack.delete` permission.
|
||||
///
|
||||
/// Note: This method returns the HTTP [Response].
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [BulkIdsDto] bulkIdsDto (required):
|
||||
@@ -132,6 +145,8 @@ class StacksApi {
|
||||
);
|
||||
}
|
||||
|
||||
/// This endpoint requires the `stack.delete` permission.
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [BulkIdsDto] bulkIdsDto (required):
|
||||
@@ -142,7 +157,10 @@ class StacksApi {
|
||||
}
|
||||
}
|
||||
|
||||
/// Performs an HTTP 'GET /stacks/{id}' operation and returns the [Response].
|
||||
/// This endpoint requires the `stack.read` permission.
|
||||
///
|
||||
/// Note: This method returns the HTTP [Response].
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [String] id (required):
|
||||
@@ -172,6 +190,8 @@ class StacksApi {
|
||||
);
|
||||
}
|
||||
|
||||
/// This endpoint requires the `stack.read` permission.
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [String] id (required):
|
||||
@@ -190,7 +210,60 @@ class StacksApi {
|
||||
return null;
|
||||
}
|
||||
|
||||
/// Performs an HTTP 'GET /stacks' operation and returns the [Response].
|
||||
/// This endpoint requires the `stack.update` permission.
|
||||
///
|
||||
/// Note: This method returns the HTTP [Response].
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [String] assetId (required):
|
||||
///
|
||||
/// * [String] id (required):
|
||||
Future<Response> removeAssetFromStackWithHttpInfo(String assetId, String id,) async {
|
||||
// ignore: prefer_const_declarations
|
||||
final apiPath = r'/stacks/{id}/assets/{assetId}'
|
||||
.replaceAll('{assetId}', assetId)
|
||||
.replaceAll('{id}', id);
|
||||
|
||||
// ignore: prefer_final_locals
|
||||
Object? postBody;
|
||||
|
||||
final queryParams = <QueryParam>[];
|
||||
final headerParams = <String, String>{};
|
||||
final formParams = <String, String>{};
|
||||
|
||||
const contentTypes = <String>[];
|
||||
|
||||
|
||||
return apiClient.invokeAPI(
|
||||
apiPath,
|
||||
'DELETE',
|
||||
queryParams,
|
||||
postBody,
|
||||
headerParams,
|
||||
formParams,
|
||||
contentTypes.isEmpty ? null : contentTypes.first,
|
||||
);
|
||||
}
|
||||
|
||||
/// This endpoint requires the `stack.update` permission.
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [String] assetId (required):
|
||||
///
|
||||
/// * [String] id (required):
|
||||
Future<void> removeAssetFromStack(String assetId, String id,) async {
|
||||
final response = await removeAssetFromStackWithHttpInfo(assetId, id,);
|
||||
if (response.statusCode >= HttpStatus.badRequest) {
|
||||
throw ApiException(response.statusCode, await _decodeBodyBytes(response));
|
||||
}
|
||||
}
|
||||
|
||||
/// This endpoint requires the `stack.read` permission.
|
||||
///
|
||||
/// Note: This method returns the HTTP [Response].
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [String] primaryAssetId:
|
||||
@@ -223,6 +296,8 @@ class StacksApi {
|
||||
);
|
||||
}
|
||||
|
||||
/// This endpoint requires the `stack.read` permission.
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [String] primaryAssetId:
|
||||
@@ -244,7 +319,10 @@ class StacksApi {
|
||||
return null;
|
||||
}
|
||||
|
||||
/// Performs an HTTP 'PUT /stacks/{id}' operation and returns the [Response].
|
||||
/// This endpoint requires the `stack.update` permission.
|
||||
///
|
||||
/// Note: This method returns the HTTP [Response].
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [String] id (required):
|
||||
@@ -276,6 +354,8 @@ class StacksApi {
|
||||
);
|
||||
}
|
||||
|
||||
/// This endpoint requires the `stack.update` permission.
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [String] id (required):
|
||||
|
||||
Generated
+22
-4
@@ -16,7 +16,10 @@ class SyncApi {
|
||||
|
||||
final ApiClient apiClient;
|
||||
|
||||
/// Performs an HTTP 'DELETE /sync/ack' operation and returns the [Response].
|
||||
/// This endpoint requires the `syncCheckpoint.delete` permission.
|
||||
///
|
||||
/// Note: This method returns the HTTP [Response].
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [SyncAckDeleteDto] syncAckDeleteDto (required):
|
||||
@@ -45,6 +48,8 @@ class SyncApi {
|
||||
);
|
||||
}
|
||||
|
||||
/// This endpoint requires the `syncCheckpoint.delete` permission.
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [SyncAckDeleteDto] syncAckDeleteDto (required):
|
||||
@@ -152,7 +157,9 @@ class SyncApi {
|
||||
return null;
|
||||
}
|
||||
|
||||
/// Performs an HTTP 'GET /sync/ack' operation and returns the [Response].
|
||||
/// This endpoint requires the `syncCheckpoint.read` permission.
|
||||
///
|
||||
/// Note: This method returns the HTTP [Response].
|
||||
Future<Response> getSyncAckWithHttpInfo() async {
|
||||
// ignore: prefer_const_declarations
|
||||
final apiPath = r'/sync/ack';
|
||||
@@ -178,6 +185,7 @@ class SyncApi {
|
||||
);
|
||||
}
|
||||
|
||||
/// This endpoint requires the `syncCheckpoint.read` permission.
|
||||
Future<List<SyncAckDto>?> getSyncAck() async {
|
||||
final response = await getSyncAckWithHttpInfo();
|
||||
if (response.statusCode >= HttpStatus.badRequest) {
|
||||
@@ -196,7 +204,10 @@ class SyncApi {
|
||||
return null;
|
||||
}
|
||||
|
||||
/// Performs an HTTP 'POST /sync/stream' operation and returns the [Response].
|
||||
/// This endpoint requires the `sync.stream` permission.
|
||||
///
|
||||
/// Note: This method returns the HTTP [Response].
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [SyncStreamDto] syncStreamDto (required):
|
||||
@@ -225,6 +236,8 @@ class SyncApi {
|
||||
);
|
||||
}
|
||||
|
||||
/// This endpoint requires the `sync.stream` permission.
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [SyncStreamDto] syncStreamDto (required):
|
||||
@@ -235,7 +248,10 @@ class SyncApi {
|
||||
}
|
||||
}
|
||||
|
||||
/// Performs an HTTP 'POST /sync/ack' operation and returns the [Response].
|
||||
/// This endpoint requires the `syncCheckpoint.update` permission.
|
||||
///
|
||||
/// Note: This method returns the HTTP [Response].
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [SyncAckSetDto] syncAckSetDto (required):
|
||||
@@ -264,6 +280,8 @@ class SyncApi {
|
||||
);
|
||||
}
|
||||
|
||||
/// This endpoint requires the `syncCheckpoint.update` permission.
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [SyncAckSetDto] syncAckSetDto (required):
|
||||
|
||||
+18
-4
@@ -16,7 +16,9 @@ class SystemConfigApi {
|
||||
|
||||
final ApiClient apiClient;
|
||||
|
||||
/// Performs an HTTP 'GET /system-config' operation and returns the [Response].
|
||||
/// This endpoint is an admin-only route, and requires the `systemConfig.read` permission.
|
||||
///
|
||||
/// Note: This method returns the HTTP [Response].
|
||||
Future<Response> getConfigWithHttpInfo() async {
|
||||
// ignore: prefer_const_declarations
|
||||
final apiPath = r'/system-config';
|
||||
@@ -42,6 +44,7 @@ class SystemConfigApi {
|
||||
);
|
||||
}
|
||||
|
||||
/// This endpoint is an admin-only route, and requires the `systemConfig.read` permission.
|
||||
Future<SystemConfigDto?> getConfig() async {
|
||||
final response = await getConfigWithHttpInfo();
|
||||
if (response.statusCode >= HttpStatus.badRequest) {
|
||||
@@ -57,7 +60,9 @@ class SystemConfigApi {
|
||||
return null;
|
||||
}
|
||||
|
||||
/// Performs an HTTP 'GET /system-config/defaults' operation and returns the [Response].
|
||||
/// This endpoint is an admin-only route, and requires the `systemConfig.read` permission.
|
||||
///
|
||||
/// Note: This method returns the HTTP [Response].
|
||||
Future<Response> getConfigDefaultsWithHttpInfo() async {
|
||||
// ignore: prefer_const_declarations
|
||||
final apiPath = r'/system-config/defaults';
|
||||
@@ -83,6 +88,7 @@ class SystemConfigApi {
|
||||
);
|
||||
}
|
||||
|
||||
/// This endpoint is an admin-only route, and requires the `systemConfig.read` permission.
|
||||
Future<SystemConfigDto?> getConfigDefaults() async {
|
||||
final response = await getConfigDefaultsWithHttpInfo();
|
||||
if (response.statusCode >= HttpStatus.badRequest) {
|
||||
@@ -98,7 +104,9 @@ class SystemConfigApi {
|
||||
return null;
|
||||
}
|
||||
|
||||
/// Performs an HTTP 'GET /system-config/storage-template-options' operation and returns the [Response].
|
||||
/// This endpoint is an admin-only route, and requires the `systemConfig.read` permission.
|
||||
///
|
||||
/// Note: This method returns the HTTP [Response].
|
||||
Future<Response> getStorageTemplateOptionsWithHttpInfo() async {
|
||||
// ignore: prefer_const_declarations
|
||||
final apiPath = r'/system-config/storage-template-options';
|
||||
@@ -124,6 +132,7 @@ class SystemConfigApi {
|
||||
);
|
||||
}
|
||||
|
||||
/// This endpoint is an admin-only route, and requires the `systemConfig.read` permission.
|
||||
Future<SystemConfigTemplateStorageOptionDto?> getStorageTemplateOptions() async {
|
||||
final response = await getStorageTemplateOptionsWithHttpInfo();
|
||||
if (response.statusCode >= HttpStatus.badRequest) {
|
||||
@@ -139,7 +148,10 @@ class SystemConfigApi {
|
||||
return null;
|
||||
}
|
||||
|
||||
/// Performs an HTTP 'PUT /system-config' operation and returns the [Response].
|
||||
/// This endpoint is an admin-only route, and requires the `systemConfig.update` permission.
|
||||
///
|
||||
/// Note: This method returns the HTTP [Response].
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [SystemConfigDto] systemConfigDto (required):
|
||||
@@ -168,6 +180,8 @@ class SystemConfigApi {
|
||||
);
|
||||
}
|
||||
|
||||
/// This endpoint is an admin-only route, and requires the `systemConfig.update` permission.
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [SystemConfigDto] systemConfigDto (required):
|
||||
|
||||
+18
-4
@@ -16,7 +16,9 @@ class SystemMetadataApi {
|
||||
|
||||
final ApiClient apiClient;
|
||||
|
||||
/// Performs an HTTP 'GET /system-metadata/admin-onboarding' operation and returns the [Response].
|
||||
/// This endpoint is an admin-only route, and requires the `systemMetadata.read` permission.
|
||||
///
|
||||
/// Note: This method returns the HTTP [Response].
|
||||
Future<Response> getAdminOnboardingWithHttpInfo() async {
|
||||
// ignore: prefer_const_declarations
|
||||
final apiPath = r'/system-metadata/admin-onboarding';
|
||||
@@ -42,6 +44,7 @@ class SystemMetadataApi {
|
||||
);
|
||||
}
|
||||
|
||||
/// This endpoint is an admin-only route, and requires the `systemMetadata.read` permission.
|
||||
Future<AdminOnboardingUpdateDto?> getAdminOnboarding() async {
|
||||
final response = await getAdminOnboardingWithHttpInfo();
|
||||
if (response.statusCode >= HttpStatus.badRequest) {
|
||||
@@ -57,7 +60,9 @@ class SystemMetadataApi {
|
||||
return null;
|
||||
}
|
||||
|
||||
/// Performs an HTTP 'GET /system-metadata/reverse-geocoding-state' operation and returns the [Response].
|
||||
/// This endpoint is an admin-only route, and requires the `systemMetadata.read` permission.
|
||||
///
|
||||
/// Note: This method returns the HTTP [Response].
|
||||
Future<Response> getReverseGeocodingStateWithHttpInfo() async {
|
||||
// ignore: prefer_const_declarations
|
||||
final apiPath = r'/system-metadata/reverse-geocoding-state';
|
||||
@@ -83,6 +88,7 @@ class SystemMetadataApi {
|
||||
);
|
||||
}
|
||||
|
||||
/// This endpoint is an admin-only route, and requires the `systemMetadata.read` permission.
|
||||
Future<ReverseGeocodingStateResponseDto?> getReverseGeocodingState() async {
|
||||
final response = await getReverseGeocodingStateWithHttpInfo();
|
||||
if (response.statusCode >= HttpStatus.badRequest) {
|
||||
@@ -98,7 +104,9 @@ class SystemMetadataApi {
|
||||
return null;
|
||||
}
|
||||
|
||||
/// Performs an HTTP 'GET /system-metadata/version-check-state' operation and returns the [Response].
|
||||
/// This endpoint is an admin-only route, and requires the `systemMetadata.read` permission.
|
||||
///
|
||||
/// Note: This method returns the HTTP [Response].
|
||||
Future<Response> getVersionCheckStateWithHttpInfo() async {
|
||||
// ignore: prefer_const_declarations
|
||||
final apiPath = r'/system-metadata/version-check-state';
|
||||
@@ -124,6 +132,7 @@ class SystemMetadataApi {
|
||||
);
|
||||
}
|
||||
|
||||
/// This endpoint is an admin-only route, and requires the `systemMetadata.read` permission.
|
||||
Future<VersionCheckStateResponseDto?> getVersionCheckState() async {
|
||||
final response = await getVersionCheckStateWithHttpInfo();
|
||||
if (response.statusCode >= HttpStatus.badRequest) {
|
||||
@@ -139,7 +148,10 @@ class SystemMetadataApi {
|
||||
return null;
|
||||
}
|
||||
|
||||
/// Performs an HTTP 'POST /system-metadata/admin-onboarding' operation and returns the [Response].
|
||||
/// This endpoint is an admin-only route, and requires the `systemMetadata.update` permission.
|
||||
///
|
||||
/// Note: This method returns the HTTP [Response].
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [AdminOnboardingUpdateDto] adminOnboardingUpdateDto (required):
|
||||
@@ -168,6 +180,8 @@ class SystemMetadataApi {
|
||||
);
|
||||
}
|
||||
|
||||
/// This endpoint is an admin-only route, and requires the `systemMetadata.update` permission.
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [AdminOnboardingUpdateDto] adminOnboardingUpdateDto (required):
|
||||
|
||||
Generated
+52
-9
@@ -16,7 +16,10 @@ class TagsApi {
|
||||
|
||||
final ApiClient apiClient;
|
||||
|
||||
/// Performs an HTTP 'PUT /tags/assets' operation and returns the [Response].
|
||||
/// This endpoint requires the `tag.asset` permission.
|
||||
///
|
||||
/// Note: This method returns the HTTP [Response].
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [TagBulkAssetsDto] tagBulkAssetsDto (required):
|
||||
@@ -45,6 +48,8 @@ class TagsApi {
|
||||
);
|
||||
}
|
||||
|
||||
/// This endpoint requires the `tag.asset` permission.
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [TagBulkAssetsDto] tagBulkAssetsDto (required):
|
||||
@@ -63,7 +68,10 @@ class TagsApi {
|
||||
return null;
|
||||
}
|
||||
|
||||
/// Performs an HTTP 'POST /tags' operation and returns the [Response].
|
||||
/// This endpoint requires the `tag.create` permission.
|
||||
///
|
||||
/// Note: This method returns the HTTP [Response].
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [TagCreateDto] tagCreateDto (required):
|
||||
@@ -92,6 +100,8 @@ class TagsApi {
|
||||
);
|
||||
}
|
||||
|
||||
/// This endpoint requires the `tag.create` permission.
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [TagCreateDto] tagCreateDto (required):
|
||||
@@ -110,7 +120,10 @@ class TagsApi {
|
||||
return null;
|
||||
}
|
||||
|
||||
/// Performs an HTTP 'DELETE /tags/{id}' operation and returns the [Response].
|
||||
/// This endpoint requires the `tag.delete` permission.
|
||||
///
|
||||
/// Note: This method returns the HTTP [Response].
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [String] id (required):
|
||||
@@ -140,6 +153,8 @@ class TagsApi {
|
||||
);
|
||||
}
|
||||
|
||||
/// This endpoint requires the `tag.delete` permission.
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [String] id (required):
|
||||
@@ -150,7 +165,9 @@ class TagsApi {
|
||||
}
|
||||
}
|
||||
|
||||
/// Performs an HTTP 'GET /tags' operation and returns the [Response].
|
||||
/// This endpoint requires the `tag.read` permission.
|
||||
///
|
||||
/// Note: This method returns the HTTP [Response].
|
||||
Future<Response> getAllTagsWithHttpInfo() async {
|
||||
// ignore: prefer_const_declarations
|
||||
final apiPath = r'/tags';
|
||||
@@ -176,6 +193,7 @@ class TagsApi {
|
||||
);
|
||||
}
|
||||
|
||||
/// This endpoint requires the `tag.read` permission.
|
||||
Future<List<TagResponseDto>?> getAllTags() async {
|
||||
final response = await getAllTagsWithHttpInfo();
|
||||
if (response.statusCode >= HttpStatus.badRequest) {
|
||||
@@ -194,7 +212,10 @@ class TagsApi {
|
||||
return null;
|
||||
}
|
||||
|
||||
/// Performs an HTTP 'GET /tags/{id}' operation and returns the [Response].
|
||||
/// This endpoint requires the `tag.read` permission.
|
||||
///
|
||||
/// Note: This method returns the HTTP [Response].
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [String] id (required):
|
||||
@@ -224,6 +245,8 @@ class TagsApi {
|
||||
);
|
||||
}
|
||||
|
||||
/// This endpoint requires the `tag.read` permission.
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [String] id (required):
|
||||
@@ -242,7 +265,10 @@ class TagsApi {
|
||||
return null;
|
||||
}
|
||||
|
||||
/// Performs an HTTP 'PUT /tags/{id}/assets' operation and returns the [Response].
|
||||
/// This endpoint requires the `tag.asset` permission.
|
||||
///
|
||||
/// Note: This method returns the HTTP [Response].
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [String] id (required):
|
||||
@@ -274,6 +300,8 @@ class TagsApi {
|
||||
);
|
||||
}
|
||||
|
||||
/// This endpoint requires the `tag.asset` permission.
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [String] id (required):
|
||||
@@ -297,7 +325,10 @@ class TagsApi {
|
||||
return null;
|
||||
}
|
||||
|
||||
/// Performs an HTTP 'DELETE /tags/{id}/assets' operation and returns the [Response].
|
||||
/// This endpoint requires the `tag.asset` permission.
|
||||
///
|
||||
/// Note: This method returns the HTTP [Response].
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [String] id (required):
|
||||
@@ -329,6 +360,8 @@ class TagsApi {
|
||||
);
|
||||
}
|
||||
|
||||
/// This endpoint requires the `tag.asset` permission.
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [String] id (required):
|
||||
@@ -352,7 +385,10 @@ class TagsApi {
|
||||
return null;
|
||||
}
|
||||
|
||||
/// Performs an HTTP 'PUT /tags/{id}' operation and returns the [Response].
|
||||
/// This endpoint requires the `tag.update` permission.
|
||||
///
|
||||
/// Note: This method returns the HTTP [Response].
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [String] id (required):
|
||||
@@ -384,6 +420,8 @@ class TagsApi {
|
||||
);
|
||||
}
|
||||
|
||||
/// This endpoint requires the `tag.update` permission.
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [String] id (required):
|
||||
@@ -404,7 +442,10 @@ class TagsApi {
|
||||
return null;
|
||||
}
|
||||
|
||||
/// Performs an HTTP 'PUT /tags' operation and returns the [Response].
|
||||
/// This endpoint requires the `tag.create` permission.
|
||||
///
|
||||
/// Note: This method returns the HTTP [Response].
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [TagUpsertDto] tagUpsertDto (required):
|
||||
@@ -433,6 +474,8 @@ class TagsApi {
|
||||
);
|
||||
}
|
||||
|
||||
/// This endpoint requires the `tag.create` permission.
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [TagUpsertDto] tagUpsertDto (required):
|
||||
|
||||
Generated
+50
-8
@@ -16,7 +16,10 @@ class TimelineApi {
|
||||
|
||||
final ApiClient apiClient;
|
||||
|
||||
/// Performs an HTTP 'GET /timeline/bucket' operation and returns the [Response].
|
||||
/// This endpoint requires the `asset.read` permission.
|
||||
///
|
||||
/// Note: This method returns the HTTP [Response].
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [String] timeBucket (required):
|
||||
@@ -39,6 +42,8 @@ class TimelineApi {
|
||||
/// * [String] personId:
|
||||
/// Filter assets containing a specific person (face recognition)
|
||||
///
|
||||
/// * [String] slug:
|
||||
///
|
||||
/// * [String] tagId:
|
||||
/// Filter assets with a specific tag
|
||||
///
|
||||
@@ -48,12 +53,15 @@ class TimelineApi {
|
||||
/// * [AssetVisibility] visibility:
|
||||
/// Filter by asset visibility status (ARCHIVE, TIMELINE, HIDDEN, LOCKED)
|
||||
///
|
||||
/// * [bool] withCoordinates:
|
||||
/// Include location data in the response
|
||||
///
|
||||
/// * [bool] withPartners:
|
||||
/// Include assets shared by partners
|
||||
///
|
||||
/// * [bool] withStacked:
|
||||
/// Include stacked assets in the response. When true, only primary assets from stacks are returned.
|
||||
Future<Response> getTimeBucketWithHttpInfo(String timeBucket, { String? albumId, bool? isFavorite, bool? isTrashed, String? key, AssetOrder? order, String? personId, String? tagId, String? userId, AssetVisibility? visibility, bool? withPartners, bool? withStacked, }) async {
|
||||
Future<Response> getTimeBucketWithHttpInfo(String timeBucket, { String? albumId, bool? isFavorite, bool? isTrashed, String? key, AssetOrder? order, String? personId, String? slug, String? tagId, String? userId, AssetVisibility? visibility, bool? withCoordinates, bool? withPartners, bool? withStacked, }) async {
|
||||
// ignore: prefer_const_declarations
|
||||
final apiPath = r'/timeline/bucket';
|
||||
|
||||
@@ -82,6 +90,9 @@ class TimelineApi {
|
||||
if (personId != null) {
|
||||
queryParams.addAll(_queryParams('', 'personId', personId));
|
||||
}
|
||||
if (slug != null) {
|
||||
queryParams.addAll(_queryParams('', 'slug', slug));
|
||||
}
|
||||
if (tagId != null) {
|
||||
queryParams.addAll(_queryParams('', 'tagId', tagId));
|
||||
}
|
||||
@@ -92,6 +103,9 @@ class TimelineApi {
|
||||
if (visibility != null) {
|
||||
queryParams.addAll(_queryParams('', 'visibility', visibility));
|
||||
}
|
||||
if (withCoordinates != null) {
|
||||
queryParams.addAll(_queryParams('', 'withCoordinates', withCoordinates));
|
||||
}
|
||||
if (withPartners != null) {
|
||||
queryParams.addAll(_queryParams('', 'withPartners', withPartners));
|
||||
}
|
||||
@@ -113,6 +127,8 @@ class TimelineApi {
|
||||
);
|
||||
}
|
||||
|
||||
/// This endpoint requires the `asset.read` permission.
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [String] timeBucket (required):
|
||||
@@ -135,6 +151,8 @@ class TimelineApi {
|
||||
/// * [String] personId:
|
||||
/// Filter assets containing a specific person (face recognition)
|
||||
///
|
||||
/// * [String] slug:
|
||||
///
|
||||
/// * [String] tagId:
|
||||
/// Filter assets with a specific tag
|
||||
///
|
||||
@@ -144,13 +162,16 @@ class TimelineApi {
|
||||
/// * [AssetVisibility] visibility:
|
||||
/// Filter by asset visibility status (ARCHIVE, TIMELINE, HIDDEN, LOCKED)
|
||||
///
|
||||
/// * [bool] withCoordinates:
|
||||
/// Include location data in the response
|
||||
///
|
||||
/// * [bool] withPartners:
|
||||
/// Include assets shared by partners
|
||||
///
|
||||
/// * [bool] withStacked:
|
||||
/// Include stacked assets in the response. When true, only primary assets from stacks are returned.
|
||||
Future<TimeBucketAssetResponseDto?> getTimeBucket(String timeBucket, { String? albumId, bool? isFavorite, bool? isTrashed, String? key, AssetOrder? order, String? personId, String? tagId, String? userId, AssetVisibility? visibility, bool? withPartners, bool? withStacked, }) async {
|
||||
final response = await getTimeBucketWithHttpInfo(timeBucket, albumId: albumId, isFavorite: isFavorite, isTrashed: isTrashed, key: key, order: order, personId: personId, tagId: tagId, userId: userId, visibility: visibility, withPartners: withPartners, withStacked: withStacked, );
|
||||
Future<TimeBucketAssetResponseDto?> getTimeBucket(String timeBucket, { String? albumId, bool? isFavorite, bool? isTrashed, String? key, AssetOrder? order, String? personId, String? slug, String? tagId, String? userId, AssetVisibility? visibility, bool? withCoordinates, bool? withPartners, bool? withStacked, }) async {
|
||||
final response = await getTimeBucketWithHttpInfo(timeBucket, albumId: albumId, isFavorite: isFavorite, isTrashed: isTrashed, key: key, order: order, personId: personId, slug: slug, tagId: tagId, userId: userId, visibility: visibility, withCoordinates: withCoordinates, withPartners: withPartners, withStacked: withStacked, );
|
||||
if (response.statusCode >= HttpStatus.badRequest) {
|
||||
throw ApiException(response.statusCode, await _decodeBodyBytes(response));
|
||||
}
|
||||
@@ -164,7 +185,10 @@ class TimelineApi {
|
||||
return null;
|
||||
}
|
||||
|
||||
/// Performs an HTTP 'GET /timeline/buckets' operation and returns the [Response].
|
||||
/// This endpoint requires the `asset.read` permission.
|
||||
///
|
||||
/// Note: This method returns the HTTP [Response].
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [String] albumId:
|
||||
@@ -184,6 +208,8 @@ class TimelineApi {
|
||||
/// * [String] personId:
|
||||
/// Filter assets containing a specific person (face recognition)
|
||||
///
|
||||
/// * [String] slug:
|
||||
///
|
||||
/// * [String] tagId:
|
||||
/// Filter assets with a specific tag
|
||||
///
|
||||
@@ -193,12 +219,15 @@ class TimelineApi {
|
||||
/// * [AssetVisibility] visibility:
|
||||
/// Filter by asset visibility status (ARCHIVE, TIMELINE, HIDDEN, LOCKED)
|
||||
///
|
||||
/// * [bool] withCoordinates:
|
||||
/// Include location data in the response
|
||||
///
|
||||
/// * [bool] withPartners:
|
||||
/// Include assets shared by partners
|
||||
///
|
||||
/// * [bool] withStacked:
|
||||
/// Include stacked assets in the response. When true, only primary assets from stacks are returned.
|
||||
Future<Response> getTimeBucketsWithHttpInfo({ String? albumId, bool? isFavorite, bool? isTrashed, String? key, AssetOrder? order, String? personId, String? tagId, String? userId, AssetVisibility? visibility, bool? withPartners, bool? withStacked, }) async {
|
||||
Future<Response> getTimeBucketsWithHttpInfo({ String? albumId, bool? isFavorite, bool? isTrashed, String? key, AssetOrder? order, String? personId, String? slug, String? tagId, String? userId, AssetVisibility? visibility, bool? withCoordinates, bool? withPartners, bool? withStacked, }) async {
|
||||
// ignore: prefer_const_declarations
|
||||
final apiPath = r'/timeline/buckets';
|
||||
|
||||
@@ -227,6 +256,9 @@ class TimelineApi {
|
||||
if (personId != null) {
|
||||
queryParams.addAll(_queryParams('', 'personId', personId));
|
||||
}
|
||||
if (slug != null) {
|
||||
queryParams.addAll(_queryParams('', 'slug', slug));
|
||||
}
|
||||
if (tagId != null) {
|
||||
queryParams.addAll(_queryParams('', 'tagId', tagId));
|
||||
}
|
||||
@@ -236,6 +268,9 @@ class TimelineApi {
|
||||
if (visibility != null) {
|
||||
queryParams.addAll(_queryParams('', 'visibility', visibility));
|
||||
}
|
||||
if (withCoordinates != null) {
|
||||
queryParams.addAll(_queryParams('', 'withCoordinates', withCoordinates));
|
||||
}
|
||||
if (withPartners != null) {
|
||||
queryParams.addAll(_queryParams('', 'withPartners', withPartners));
|
||||
}
|
||||
@@ -257,6 +292,8 @@ class TimelineApi {
|
||||
);
|
||||
}
|
||||
|
||||
/// This endpoint requires the `asset.read` permission.
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [String] albumId:
|
||||
@@ -276,6 +313,8 @@ class TimelineApi {
|
||||
/// * [String] personId:
|
||||
/// Filter assets containing a specific person (face recognition)
|
||||
///
|
||||
/// * [String] slug:
|
||||
///
|
||||
/// * [String] tagId:
|
||||
/// Filter assets with a specific tag
|
||||
///
|
||||
@@ -285,13 +324,16 @@ class TimelineApi {
|
||||
/// * [AssetVisibility] visibility:
|
||||
/// Filter by asset visibility status (ARCHIVE, TIMELINE, HIDDEN, LOCKED)
|
||||
///
|
||||
/// * [bool] withCoordinates:
|
||||
/// Include location data in the response
|
||||
///
|
||||
/// * [bool] withPartners:
|
||||
/// Include assets shared by partners
|
||||
///
|
||||
/// * [bool] withStacked:
|
||||
/// Include stacked assets in the response. When true, only primary assets from stacks are returned.
|
||||
Future<List<TimeBucketsResponseDto>?> getTimeBuckets({ String? albumId, bool? isFavorite, bool? isTrashed, String? key, AssetOrder? order, String? personId, String? tagId, String? userId, AssetVisibility? visibility, bool? withPartners, bool? withStacked, }) async {
|
||||
final response = await getTimeBucketsWithHttpInfo( albumId: albumId, isFavorite: isFavorite, isTrashed: isTrashed, key: key, order: order, personId: personId, tagId: tagId, userId: userId, visibility: visibility, withPartners: withPartners, withStacked: withStacked, );
|
||||
Future<List<TimeBucketsResponseDto>?> getTimeBuckets({ String? albumId, bool? isFavorite, bool? isTrashed, String? key, AssetOrder? order, String? personId, String? slug, String? tagId, String? userId, AssetVisibility? visibility, bool? withCoordinates, bool? withPartners, bool? withStacked, }) async {
|
||||
final response = await getTimeBucketsWithHttpInfo( albumId: albumId, isFavorite: isFavorite, isTrashed: isTrashed, key: key, order: order, personId: personId, slug: slug, tagId: tagId, userId: userId, visibility: visibility, withCoordinates: withCoordinates, withPartners: withPartners, withStacked: withStacked, );
|
||||
if (response.statusCode >= HttpStatus.badRequest) {
|
||||
throw ApiException(response.statusCode, await _decodeBodyBytes(response));
|
||||
}
|
||||
|
||||
Generated
+14
-3
@@ -16,7 +16,9 @@ class TrashApi {
|
||||
|
||||
final ApiClient apiClient;
|
||||
|
||||
/// Performs an HTTP 'POST /trash/empty' operation and returns the [Response].
|
||||
/// This endpoint requires the `asset.delete` permission.
|
||||
///
|
||||
/// Note: This method returns the HTTP [Response].
|
||||
Future<Response> emptyTrashWithHttpInfo() async {
|
||||
// ignore: prefer_const_declarations
|
||||
final apiPath = r'/trash/empty';
|
||||
@@ -42,6 +44,7 @@ class TrashApi {
|
||||
);
|
||||
}
|
||||
|
||||
/// This endpoint requires the `asset.delete` permission.
|
||||
Future<TrashResponseDto?> emptyTrash() async {
|
||||
final response = await emptyTrashWithHttpInfo();
|
||||
if (response.statusCode >= HttpStatus.badRequest) {
|
||||
@@ -57,7 +60,10 @@ class TrashApi {
|
||||
return null;
|
||||
}
|
||||
|
||||
/// Performs an HTTP 'POST /trash/restore/assets' operation and returns the [Response].
|
||||
/// This endpoint requires the `asset.delete` permission.
|
||||
///
|
||||
/// Note: This method returns the HTTP [Response].
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [BulkIdsDto] bulkIdsDto (required):
|
||||
@@ -86,6 +92,8 @@ class TrashApi {
|
||||
);
|
||||
}
|
||||
|
||||
/// This endpoint requires the `asset.delete` permission.
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [BulkIdsDto] bulkIdsDto (required):
|
||||
@@ -104,7 +112,9 @@ class TrashApi {
|
||||
return null;
|
||||
}
|
||||
|
||||
/// Performs an HTTP 'POST /trash/restore' operation and returns the [Response].
|
||||
/// This endpoint requires the `asset.delete` permission.
|
||||
///
|
||||
/// Note: This method returns the HTTP [Response].
|
||||
Future<Response> restoreTrashWithHttpInfo() async {
|
||||
// ignore: prefer_const_declarations
|
||||
final apiPath = r'/trash/restore';
|
||||
@@ -130,6 +140,7 @@ class TrashApi {
|
||||
);
|
||||
}
|
||||
|
||||
/// This endpoint requires the `asset.delete` permission.
|
||||
Future<TrashResponseDto?> restoreTrash() async {
|
||||
final response = await restoreTrashWithHttpInfo();
|
||||
if (response.statusCode >= HttpStatus.badRequest) {
|
||||
|
||||
+54
-9
@@ -16,7 +16,10 @@ class UsersAdminApi {
|
||||
|
||||
final ApiClient apiClient;
|
||||
|
||||
/// Performs an HTTP 'POST /admin/users' operation and returns the [Response].
|
||||
/// This endpoint is an admin-only route, and requires the `adminUser.create` permission.
|
||||
///
|
||||
/// Note: This method returns the HTTP [Response].
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [UserAdminCreateDto] userAdminCreateDto (required):
|
||||
@@ -45,6 +48,8 @@ class UsersAdminApi {
|
||||
);
|
||||
}
|
||||
|
||||
/// This endpoint is an admin-only route, and requires the `adminUser.create` permission.
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [UserAdminCreateDto] userAdminCreateDto (required):
|
||||
@@ -63,7 +68,10 @@ class UsersAdminApi {
|
||||
return null;
|
||||
}
|
||||
|
||||
/// Performs an HTTP 'DELETE /admin/users/{id}' operation and returns the [Response].
|
||||
/// This endpoint is an admin-only route, and requires the `adminUser.delete` permission.
|
||||
///
|
||||
/// Note: This method returns the HTTP [Response].
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [String] id (required):
|
||||
@@ -95,6 +103,8 @@ class UsersAdminApi {
|
||||
);
|
||||
}
|
||||
|
||||
/// This endpoint is an admin-only route, and requires the `adminUser.delete` permission.
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [String] id (required):
|
||||
@@ -115,7 +125,10 @@ class UsersAdminApi {
|
||||
return null;
|
||||
}
|
||||
|
||||
/// Performs an HTTP 'GET /admin/users/{id}' operation and returns the [Response].
|
||||
/// This endpoint is an admin-only route, and requires the `adminUser.read` permission.
|
||||
///
|
||||
/// Note: This method returns the HTTP [Response].
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [String] id (required):
|
||||
@@ -145,6 +158,8 @@ class UsersAdminApi {
|
||||
);
|
||||
}
|
||||
|
||||
/// This endpoint is an admin-only route, and requires the `adminUser.read` permission.
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [String] id (required):
|
||||
@@ -163,7 +178,10 @@ class UsersAdminApi {
|
||||
return null;
|
||||
}
|
||||
|
||||
/// Performs an HTTP 'GET /admin/users/{id}/preferences' operation and returns the [Response].
|
||||
/// This endpoint is an admin-only route, and requires the `adminUser.read` permission.
|
||||
///
|
||||
/// Note: This method returns the HTTP [Response].
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [String] id (required):
|
||||
@@ -193,6 +211,8 @@ class UsersAdminApi {
|
||||
);
|
||||
}
|
||||
|
||||
/// This endpoint is an admin-only route, and requires the `adminUser.read` permission.
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [String] id (required):
|
||||
@@ -211,7 +231,10 @@ class UsersAdminApi {
|
||||
return null;
|
||||
}
|
||||
|
||||
/// Performs an HTTP 'GET /admin/users/{id}/statistics' operation and returns the [Response].
|
||||
/// This endpoint is an admin-only route, and requires the `adminUser.read` permission.
|
||||
///
|
||||
/// Note: This method returns the HTTP [Response].
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [String] id (required):
|
||||
@@ -257,6 +280,8 @@ class UsersAdminApi {
|
||||
);
|
||||
}
|
||||
|
||||
/// This endpoint is an admin-only route, and requires the `adminUser.read` permission.
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [String] id (required):
|
||||
@@ -281,7 +306,10 @@ class UsersAdminApi {
|
||||
return null;
|
||||
}
|
||||
|
||||
/// Performs an HTTP 'POST /admin/users/{id}/restore' operation and returns the [Response].
|
||||
/// This endpoint is an admin-only route, and requires the `adminUser.delete` permission.
|
||||
///
|
||||
/// Note: This method returns the HTTP [Response].
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [String] id (required):
|
||||
@@ -311,6 +339,8 @@ class UsersAdminApi {
|
||||
);
|
||||
}
|
||||
|
||||
/// This endpoint is an admin-only route, and requires the `adminUser.delete` permission.
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [String] id (required):
|
||||
@@ -329,7 +359,10 @@ class UsersAdminApi {
|
||||
return null;
|
||||
}
|
||||
|
||||
/// Performs an HTTP 'GET /admin/users' operation and returns the [Response].
|
||||
/// This endpoint is an admin-only route, and requires the `adminUser.read` permission.
|
||||
///
|
||||
/// Note: This method returns the HTTP [Response].
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [String] id:
|
||||
@@ -367,6 +400,8 @@ class UsersAdminApi {
|
||||
);
|
||||
}
|
||||
|
||||
/// This endpoint is an admin-only route, and requires the `adminUser.read` permission.
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [String] id:
|
||||
@@ -390,7 +425,10 @@ class UsersAdminApi {
|
||||
return null;
|
||||
}
|
||||
|
||||
/// Performs an HTTP 'PUT /admin/users/{id}' operation and returns the [Response].
|
||||
/// This endpoint is an admin-only route, and requires the `adminUser.update` permission.
|
||||
///
|
||||
/// Note: This method returns the HTTP [Response].
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [String] id (required):
|
||||
@@ -422,6 +460,8 @@ class UsersAdminApi {
|
||||
);
|
||||
}
|
||||
|
||||
/// This endpoint is an admin-only route, and requires the `adminUser.update` permission.
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [String] id (required):
|
||||
@@ -442,7 +482,10 @@ class UsersAdminApi {
|
||||
return null;
|
||||
}
|
||||
|
||||
/// Performs an HTTP 'PUT /admin/users/{id}/preferences' operation and returns the [Response].
|
||||
/// This endpoint is an admin-only route, and requires the `adminUser.update` permission.
|
||||
///
|
||||
/// Note: This method returns the HTTP [Response].
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [String] id (required):
|
||||
@@ -474,6 +517,8 @@ class UsersAdminApi {
|
||||
);
|
||||
}
|
||||
|
||||
/// This endpoint is an admin-only route, and requires the `adminUser.update` permission.
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [String] id (required):
|
||||
|
||||
Generated
+74
-15
@@ -16,7 +16,10 @@ class UsersApi {
|
||||
|
||||
final ApiClient apiClient;
|
||||
|
||||
/// Performs an HTTP 'POST /users/profile-image' operation and returns the [Response].
|
||||
/// This endpoint requires the `userProfileImage.update` permission.
|
||||
///
|
||||
/// Note: This method returns the HTTP [Response].
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [MultipartFile] file (required):
|
||||
@@ -55,6 +58,8 @@ class UsersApi {
|
||||
);
|
||||
}
|
||||
|
||||
/// This endpoint requires the `userProfileImage.update` permission.
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [MultipartFile] file (required):
|
||||
@@ -73,7 +78,9 @@ class UsersApi {
|
||||
return null;
|
||||
}
|
||||
|
||||
/// Performs an HTTP 'DELETE /users/profile-image' operation and returns the [Response].
|
||||
/// This endpoint requires the `userProfileImage.delete` permission.
|
||||
///
|
||||
/// Note: This method returns the HTTP [Response].
|
||||
Future<Response> deleteProfileImageWithHttpInfo() async {
|
||||
// ignore: prefer_const_declarations
|
||||
final apiPath = r'/users/profile-image';
|
||||
@@ -99,6 +106,7 @@ class UsersApi {
|
||||
);
|
||||
}
|
||||
|
||||
/// This endpoint requires the `userProfileImage.delete` permission.
|
||||
Future<void> deleteProfileImage() async {
|
||||
final response = await deleteProfileImageWithHttpInfo();
|
||||
if (response.statusCode >= HttpStatus.badRequest) {
|
||||
@@ -106,7 +114,9 @@ class UsersApi {
|
||||
}
|
||||
}
|
||||
|
||||
/// Performs an HTTP 'DELETE /users/me/license' operation and returns the [Response].
|
||||
/// This endpoint requires the `userLicense.delete` permission.
|
||||
///
|
||||
/// Note: This method returns the HTTP [Response].
|
||||
Future<Response> deleteUserLicenseWithHttpInfo() async {
|
||||
// ignore: prefer_const_declarations
|
||||
final apiPath = r'/users/me/license';
|
||||
@@ -132,6 +142,7 @@ class UsersApi {
|
||||
);
|
||||
}
|
||||
|
||||
/// This endpoint requires the `userLicense.delete` permission.
|
||||
Future<void> deleteUserLicense() async {
|
||||
final response = await deleteUserLicenseWithHttpInfo();
|
||||
if (response.statusCode >= HttpStatus.badRequest) {
|
||||
@@ -139,7 +150,9 @@ class UsersApi {
|
||||
}
|
||||
}
|
||||
|
||||
/// Performs an HTTP 'DELETE /users/me/onboarding' operation and returns the [Response].
|
||||
/// This endpoint requires the `userOnboarding.delete` permission.
|
||||
///
|
||||
/// Note: This method returns the HTTP [Response].
|
||||
Future<Response> deleteUserOnboardingWithHttpInfo() async {
|
||||
// ignore: prefer_const_declarations
|
||||
final apiPath = r'/users/me/onboarding';
|
||||
@@ -165,6 +178,7 @@ class UsersApi {
|
||||
);
|
||||
}
|
||||
|
||||
/// This endpoint requires the `userOnboarding.delete` permission.
|
||||
Future<void> deleteUserOnboarding() async {
|
||||
final response = await deleteUserOnboardingWithHttpInfo();
|
||||
if (response.statusCode >= HttpStatus.badRequest) {
|
||||
@@ -172,7 +186,9 @@ class UsersApi {
|
||||
}
|
||||
}
|
||||
|
||||
/// Performs an HTTP 'GET /users/me/preferences' operation and returns the [Response].
|
||||
/// This endpoint requires the `userPreference.read` permission.
|
||||
///
|
||||
/// Note: This method returns the HTTP [Response].
|
||||
Future<Response> getMyPreferencesWithHttpInfo() async {
|
||||
// ignore: prefer_const_declarations
|
||||
final apiPath = r'/users/me/preferences';
|
||||
@@ -198,6 +214,7 @@ class UsersApi {
|
||||
);
|
||||
}
|
||||
|
||||
/// This endpoint requires the `userPreference.read` permission.
|
||||
Future<UserPreferencesResponseDto?> getMyPreferences() async {
|
||||
final response = await getMyPreferencesWithHttpInfo();
|
||||
if (response.statusCode >= HttpStatus.badRequest) {
|
||||
@@ -213,7 +230,9 @@ class UsersApi {
|
||||
return null;
|
||||
}
|
||||
|
||||
/// Performs an HTTP 'GET /users/me' operation and returns the [Response].
|
||||
/// This endpoint requires the `user.read` permission.
|
||||
///
|
||||
/// Note: This method returns the HTTP [Response].
|
||||
Future<Response> getMyUserWithHttpInfo() async {
|
||||
// ignore: prefer_const_declarations
|
||||
final apiPath = r'/users/me';
|
||||
@@ -239,6 +258,7 @@ class UsersApi {
|
||||
);
|
||||
}
|
||||
|
||||
/// This endpoint requires the `user.read` permission.
|
||||
Future<UserAdminResponseDto?> getMyUser() async {
|
||||
final response = await getMyUserWithHttpInfo();
|
||||
if (response.statusCode >= HttpStatus.badRequest) {
|
||||
@@ -254,7 +274,10 @@ class UsersApi {
|
||||
return null;
|
||||
}
|
||||
|
||||
/// Performs an HTTP 'GET /users/{id}/profile-image' operation and returns the [Response].
|
||||
/// This endpoint requires the `userProfileImage.read` permission.
|
||||
///
|
||||
/// Note: This method returns the HTTP [Response].
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [String] id (required):
|
||||
@@ -284,6 +307,8 @@ class UsersApi {
|
||||
);
|
||||
}
|
||||
|
||||
/// This endpoint requires the `userProfileImage.read` permission.
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [String] id (required):
|
||||
@@ -302,7 +327,10 @@ class UsersApi {
|
||||
return null;
|
||||
}
|
||||
|
||||
/// Performs an HTTP 'GET /users/{id}' operation and returns the [Response].
|
||||
/// This endpoint requires the `user.read` permission.
|
||||
///
|
||||
/// Note: This method returns the HTTP [Response].
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [String] id (required):
|
||||
@@ -332,6 +360,8 @@ class UsersApi {
|
||||
);
|
||||
}
|
||||
|
||||
/// This endpoint requires the `user.read` permission.
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [String] id (required):
|
||||
@@ -350,7 +380,9 @@ class UsersApi {
|
||||
return null;
|
||||
}
|
||||
|
||||
/// Performs an HTTP 'GET /users/me/license' operation and returns the [Response].
|
||||
/// This endpoint requires the `userLicense.read` permission.
|
||||
///
|
||||
/// Note: This method returns the HTTP [Response].
|
||||
Future<Response> getUserLicenseWithHttpInfo() async {
|
||||
// ignore: prefer_const_declarations
|
||||
final apiPath = r'/users/me/license';
|
||||
@@ -376,6 +408,7 @@ class UsersApi {
|
||||
);
|
||||
}
|
||||
|
||||
/// This endpoint requires the `userLicense.read` permission.
|
||||
Future<LicenseResponseDto?> getUserLicense() async {
|
||||
final response = await getUserLicenseWithHttpInfo();
|
||||
if (response.statusCode >= HttpStatus.badRequest) {
|
||||
@@ -391,7 +424,9 @@ class UsersApi {
|
||||
return null;
|
||||
}
|
||||
|
||||
/// Performs an HTTP 'GET /users/me/onboarding' operation and returns the [Response].
|
||||
/// This endpoint requires the `userOnboarding.read` permission.
|
||||
///
|
||||
/// Note: This method returns the HTTP [Response].
|
||||
Future<Response> getUserOnboardingWithHttpInfo() async {
|
||||
// ignore: prefer_const_declarations
|
||||
final apiPath = r'/users/me/onboarding';
|
||||
@@ -417,6 +452,7 @@ class UsersApi {
|
||||
);
|
||||
}
|
||||
|
||||
/// This endpoint requires the `userOnboarding.read` permission.
|
||||
Future<OnboardingResponseDto?> getUserOnboarding() async {
|
||||
final response = await getUserOnboardingWithHttpInfo();
|
||||
if (response.statusCode >= HttpStatus.badRequest) {
|
||||
@@ -432,7 +468,9 @@ class UsersApi {
|
||||
return null;
|
||||
}
|
||||
|
||||
/// Performs an HTTP 'GET /users' operation and returns the [Response].
|
||||
/// This endpoint requires the `user.read` permission.
|
||||
///
|
||||
/// Note: This method returns the HTTP [Response].
|
||||
Future<Response> searchUsersWithHttpInfo() async {
|
||||
// ignore: prefer_const_declarations
|
||||
final apiPath = r'/users';
|
||||
@@ -458,6 +496,7 @@ class UsersApi {
|
||||
);
|
||||
}
|
||||
|
||||
/// This endpoint requires the `user.read` permission.
|
||||
Future<List<UserResponseDto>?> searchUsers() async {
|
||||
final response = await searchUsersWithHttpInfo();
|
||||
if (response.statusCode >= HttpStatus.badRequest) {
|
||||
@@ -476,7 +515,10 @@ class UsersApi {
|
||||
return null;
|
||||
}
|
||||
|
||||
/// Performs an HTTP 'PUT /users/me/license' operation and returns the [Response].
|
||||
/// This endpoint requires the `userLicense.update` permission.
|
||||
///
|
||||
/// Note: This method returns the HTTP [Response].
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [LicenseKeyDto] licenseKeyDto (required):
|
||||
@@ -505,6 +547,8 @@ class UsersApi {
|
||||
);
|
||||
}
|
||||
|
||||
/// This endpoint requires the `userLicense.update` permission.
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [LicenseKeyDto] licenseKeyDto (required):
|
||||
@@ -523,7 +567,10 @@ class UsersApi {
|
||||
return null;
|
||||
}
|
||||
|
||||
/// Performs an HTTP 'PUT /users/me/onboarding' operation and returns the [Response].
|
||||
/// This endpoint requires the `userOnboarding.update` permission.
|
||||
///
|
||||
/// Note: This method returns the HTTP [Response].
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [OnboardingDto] onboardingDto (required):
|
||||
@@ -552,6 +599,8 @@ class UsersApi {
|
||||
);
|
||||
}
|
||||
|
||||
/// This endpoint requires the `userOnboarding.update` permission.
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [OnboardingDto] onboardingDto (required):
|
||||
@@ -570,7 +619,10 @@ class UsersApi {
|
||||
return null;
|
||||
}
|
||||
|
||||
/// Performs an HTTP 'PUT /users/me/preferences' operation and returns the [Response].
|
||||
/// This endpoint requires the `userPreference.update` permission.
|
||||
///
|
||||
/// Note: This method returns the HTTP [Response].
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [UserPreferencesUpdateDto] userPreferencesUpdateDto (required):
|
||||
@@ -599,6 +651,8 @@ class UsersApi {
|
||||
);
|
||||
}
|
||||
|
||||
/// This endpoint requires the `userPreference.update` permission.
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [UserPreferencesUpdateDto] userPreferencesUpdateDto (required):
|
||||
@@ -617,7 +671,10 @@ class UsersApi {
|
||||
return null;
|
||||
}
|
||||
|
||||
/// Performs an HTTP 'PUT /users/me' operation and returns the [Response].
|
||||
/// This endpoint requires the `user.update` permission.
|
||||
///
|
||||
/// Note: This method returns the HTTP [Response].
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [UserUpdateMeDto] userUpdateMeDto (required):
|
||||
@@ -646,6 +703,8 @@ class UsersApi {
|
||||
);
|
||||
}
|
||||
|
||||
/// This endpoint requires the `user.update` permission.
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [UserUpdateMeDto] userUpdateMeDto (required):
|
||||
|
||||
Generated
+28
-2
@@ -212,6 +212,10 @@ class ApiClient {
|
||||
return AlbumUserResponseDto.fromJson(value);
|
||||
case 'AlbumUserRole':
|
||||
return AlbumUserRoleTypeTransformer().decode(value);
|
||||
case 'AlbumsAddAssetsDto':
|
||||
return AlbumsAddAssetsDto.fromJson(value);
|
||||
case 'AlbumsAddAssetsResponseDto':
|
||||
return AlbumsAddAssetsResponseDto.fromJson(value);
|
||||
case 'AlbumsResponse':
|
||||
return AlbumsResponse.fromJson(value);
|
||||
case 'AlbumsUpdate':
|
||||
@@ -262,6 +266,14 @@ class ApiClient {
|
||||
return AssetMediaSizeTypeTransformer().decode(value);
|
||||
case 'AssetMediaStatus':
|
||||
return AssetMediaStatusTypeTransformer().decode(value);
|
||||
case 'AssetMetadataKey':
|
||||
return AssetMetadataKeyTypeTransformer().decode(value);
|
||||
case 'AssetMetadataResponseDto':
|
||||
return AssetMetadataResponseDto.fromJson(value);
|
||||
case 'AssetMetadataUpsertDto':
|
||||
return AssetMetadataUpsertDto.fromJson(value);
|
||||
case 'AssetMetadataUpsertItemDto':
|
||||
return AssetMetadataUpsertItemDto.fromJson(value);
|
||||
case 'AssetOrder':
|
||||
return AssetOrderTypeTransformer().decode(value);
|
||||
case 'AssetResponseDto':
|
||||
@@ -280,6 +292,8 @@ class ApiClient {
|
||||
return AuthStatusResponseDto.fromJson(value);
|
||||
case 'AvatarUpdate':
|
||||
return AvatarUpdate.fromJson(value);
|
||||
case 'BulkIdErrorReason':
|
||||
return BulkIdErrorReasonTypeTransformer().decode(value);
|
||||
case 'BulkIdResponseDto':
|
||||
return BulkIdResponseDto.fromJson(value);
|
||||
case 'BulkIdsDto':
|
||||
@@ -368,6 +382,8 @@ class ApiClient {
|
||||
return LoginResponseDto.fromJson(value);
|
||||
case 'LogoutResponseDto':
|
||||
return LogoutResponseDto.fromJson(value);
|
||||
case 'MachineLearningAvailabilityChecksDto':
|
||||
return MachineLearningAvailabilityChecksDto.fromJson(value);
|
||||
case 'ManualJobName':
|
||||
return ManualJobNameTypeTransformer().decode(value);
|
||||
case 'MapMarkerResponseDto':
|
||||
@@ -420,10 +436,14 @@ class ApiClient {
|
||||
return OnboardingDto.fromJson(value);
|
||||
case 'OnboardingResponseDto':
|
||||
return OnboardingResponseDto.fromJson(value);
|
||||
case 'PartnerCreateDto':
|
||||
return PartnerCreateDto.fromJson(value);
|
||||
case 'PartnerDirection':
|
||||
return PartnerDirectionTypeTransformer().decode(value);
|
||||
case 'PartnerResponseDto':
|
||||
return PartnerResponseDto.fromJson(value);
|
||||
case 'PartnerUpdateDto':
|
||||
return PartnerUpdateDto.fromJson(value);
|
||||
case 'PeopleResponse':
|
||||
return PeopleResponse.fromJson(value);
|
||||
case 'PeopleResponseDto':
|
||||
@@ -574,8 +594,14 @@ class ApiClient {
|
||||
return SyncAssetFaceDeleteV1.fromJson(value);
|
||||
case 'SyncAssetFaceV1':
|
||||
return SyncAssetFaceV1.fromJson(value);
|
||||
case 'SyncAssetMetadataDeleteV1':
|
||||
return SyncAssetMetadataDeleteV1.fromJson(value);
|
||||
case 'SyncAssetMetadataV1':
|
||||
return SyncAssetMetadataV1.fromJson(value);
|
||||
case 'SyncAssetV1':
|
||||
return SyncAssetV1.fromJson(value);
|
||||
case 'SyncAuthUserV1':
|
||||
return SyncAuthUserV1.fromJson(value);
|
||||
case 'SyncEntityType':
|
||||
return SyncEntityTypeTypeTransformer().decode(value);
|
||||
case 'SyncMemoryAssetDeleteV1':
|
||||
@@ -714,8 +740,6 @@ class ApiClient {
|
||||
return UpdateAssetDto.fromJson(value);
|
||||
case 'UpdateLibraryDto':
|
||||
return UpdateLibraryDto.fromJson(value);
|
||||
case 'UpdatePartnerDto':
|
||||
return UpdatePartnerDto.fromJson(value);
|
||||
case 'UsageByUserDto':
|
||||
return UsageByUserDto.fromJson(value);
|
||||
case 'UserAdminCreateDto':
|
||||
@@ -730,6 +754,8 @@ class ApiClient {
|
||||
return UserAvatarColorTypeTransformer().decode(value);
|
||||
case 'UserLicense':
|
||||
return UserLicense.fromJson(value);
|
||||
case 'UserMetadataKey':
|
||||
return UserMetadataKeyTypeTransformer().decode(value);
|
||||
case 'UserPreferencesResponseDto':
|
||||
return UserPreferencesResponseDto.fromJson(value);
|
||||
case 'UserPreferencesUpdateDto':
|
||||
|
||||
Generated
+9
@@ -67,6 +67,9 @@ String parameterToString(dynamic value) {
|
||||
if (value is AssetMediaStatus) {
|
||||
return AssetMediaStatusTypeTransformer().encode(value).toString();
|
||||
}
|
||||
if (value is AssetMetadataKey) {
|
||||
return AssetMetadataKeyTypeTransformer().encode(value).toString();
|
||||
}
|
||||
if (value is AssetOrder) {
|
||||
return AssetOrderTypeTransformer().encode(value).toString();
|
||||
}
|
||||
@@ -79,6 +82,9 @@ String parameterToString(dynamic value) {
|
||||
if (value is AudioCodec) {
|
||||
return AudioCodecTypeTransformer().encode(value).toString();
|
||||
}
|
||||
if (value is BulkIdErrorReason) {
|
||||
return BulkIdErrorReasonTypeTransformer().encode(value).toString();
|
||||
}
|
||||
if (value is CQMode) {
|
||||
return CQModeTypeTransformer().encode(value).toString();
|
||||
}
|
||||
@@ -151,6 +157,9 @@ String parameterToString(dynamic value) {
|
||||
if (value is UserAvatarColor) {
|
||||
return UserAvatarColorTypeTransformer().encode(value).toString();
|
||||
}
|
||||
if (value is UserMetadataKey) {
|
||||
return UserMetadataKeyTypeTransformer().encode(value).toString();
|
||||
}
|
||||
if (value is UserStatus) {
|
||||
return UserStatusTypeTransformer().encode(value).toString();
|
||||
}
|
||||
|
||||
+111
@@ -0,0 +1,111 @@
|
||||
//
|
||||
// AUTO-GENERATED FILE, DO NOT MODIFY!
|
||||
//
|
||||
// @dart=2.18
|
||||
|
||||
// ignore_for_file: unused_element, unused_import
|
||||
// ignore_for_file: always_put_required_named_parameters_first
|
||||
// ignore_for_file: constant_identifier_names
|
||||
// ignore_for_file: lines_longer_than_80_chars
|
||||
|
||||
part of openapi.api;
|
||||
|
||||
class AlbumsAddAssetsDto {
|
||||
/// Returns a new [AlbumsAddAssetsDto] instance.
|
||||
AlbumsAddAssetsDto({
|
||||
this.albumIds = const [],
|
||||
this.assetIds = const [],
|
||||
});
|
||||
|
||||
List<String> albumIds;
|
||||
|
||||
List<String> assetIds;
|
||||
|
||||
@override
|
||||
bool operator ==(Object other) => identical(this, other) || other is AlbumsAddAssetsDto &&
|
||||
_deepEquality.equals(other.albumIds, albumIds) &&
|
||||
_deepEquality.equals(other.assetIds, assetIds);
|
||||
|
||||
@override
|
||||
int get hashCode =>
|
||||
// ignore: unnecessary_parenthesis
|
||||
(albumIds.hashCode) +
|
||||
(assetIds.hashCode);
|
||||
|
||||
@override
|
||||
String toString() => 'AlbumsAddAssetsDto[albumIds=$albumIds, assetIds=$assetIds]';
|
||||
|
||||
Map<String, dynamic> toJson() {
|
||||
final json = <String, dynamic>{};
|
||||
json[r'albumIds'] = this.albumIds;
|
||||
json[r'assetIds'] = this.assetIds;
|
||||
return json;
|
||||
}
|
||||
|
||||
/// Returns a new [AlbumsAddAssetsDto] instance and imports its values from
|
||||
/// [value] if it's a [Map], null otherwise.
|
||||
// ignore: prefer_constructors_over_static_methods
|
||||
static AlbumsAddAssetsDto? fromJson(dynamic value) {
|
||||
upgradeDto(value, "AlbumsAddAssetsDto");
|
||||
if (value is Map) {
|
||||
final json = value.cast<String, dynamic>();
|
||||
|
||||
return AlbumsAddAssetsDto(
|
||||
albumIds: json[r'albumIds'] is Iterable
|
||||
? (json[r'albumIds'] as Iterable).cast<String>().toList(growable: false)
|
||||
: const [],
|
||||
assetIds: json[r'assetIds'] is Iterable
|
||||
? (json[r'assetIds'] as Iterable).cast<String>().toList(growable: false)
|
||||
: const [],
|
||||
);
|
||||
}
|
||||
return null;
|
||||
}
|
||||
|
||||
static List<AlbumsAddAssetsDto> listFromJson(dynamic json, {bool growable = false,}) {
|
||||
final result = <AlbumsAddAssetsDto>[];
|
||||
if (json is List && json.isNotEmpty) {
|
||||
for (final row in json) {
|
||||
final value = AlbumsAddAssetsDto.fromJson(row);
|
||||
if (value != null) {
|
||||
result.add(value);
|
||||
}
|
||||
}
|
||||
}
|
||||
return result.toList(growable: growable);
|
||||
}
|
||||
|
||||
static Map<String, AlbumsAddAssetsDto> mapFromJson(dynamic json) {
|
||||
final map = <String, AlbumsAddAssetsDto>{};
|
||||
if (json is Map && json.isNotEmpty) {
|
||||
json = json.cast<String, dynamic>(); // ignore: parameter_assignments
|
||||
for (final entry in json.entries) {
|
||||
final value = AlbumsAddAssetsDto.fromJson(entry.value);
|
||||
if (value != null) {
|
||||
map[entry.key] = value;
|
||||
}
|
||||
}
|
||||
}
|
||||
return map;
|
||||
}
|
||||
|
||||
// maps a json object with a list of AlbumsAddAssetsDto-objects as value to a dart map
|
||||
static Map<String, List<AlbumsAddAssetsDto>> mapListFromJson(dynamic json, {bool growable = false,}) {
|
||||
final map = <String, List<AlbumsAddAssetsDto>>{};
|
||||
if (json is Map && json.isNotEmpty) {
|
||||
// ignore: parameter_assignments
|
||||
json = json.cast<String, dynamic>();
|
||||
for (final entry in json.entries) {
|
||||
map[entry.key] = AlbumsAddAssetsDto.listFromJson(entry.value, growable: growable,);
|
||||
}
|
||||
}
|
||||
return map;
|
||||
}
|
||||
|
||||
/// The list of required keys that must be present in a JSON.
|
||||
static const requiredKeys = <String>{
|
||||
'albumIds',
|
||||
'assetIds',
|
||||
};
|
||||
}
|
||||
|
||||
@@ -0,0 +1,116 @@
|
||||
//
|
||||
// AUTO-GENERATED FILE, DO NOT MODIFY!
|
||||
//
|
||||
// @dart=2.18
|
||||
|
||||
// ignore_for_file: unused_element, unused_import
|
||||
// ignore_for_file: always_put_required_named_parameters_first
|
||||
// ignore_for_file: constant_identifier_names
|
||||
// ignore_for_file: lines_longer_than_80_chars
|
||||
|
||||
part of openapi.api;
|
||||
|
||||
class AlbumsAddAssetsResponseDto {
|
||||
/// Returns a new [AlbumsAddAssetsResponseDto] instance.
|
||||
AlbumsAddAssetsResponseDto({
|
||||
this.error,
|
||||
required this.success,
|
||||
});
|
||||
|
||||
///
|
||||
/// Please note: This property should have been non-nullable! Since the specification file
|
||||
/// does not include a default value (using the "default:" property), however, the generated
|
||||
/// source code must fall back to having a nullable type.
|
||||
/// Consider adding a "default:" property in the specification file to hide this note.
|
||||
///
|
||||
BulkIdErrorReason? error;
|
||||
|
||||
bool success;
|
||||
|
||||
@override
|
||||
bool operator ==(Object other) => identical(this, other) || other is AlbumsAddAssetsResponseDto &&
|
||||
other.error == error &&
|
||||
other.success == success;
|
||||
|
||||
@override
|
||||
int get hashCode =>
|
||||
// ignore: unnecessary_parenthesis
|
||||
(error == null ? 0 : error!.hashCode) +
|
||||
(success.hashCode);
|
||||
|
||||
@override
|
||||
String toString() => 'AlbumsAddAssetsResponseDto[error=$error, success=$success]';
|
||||
|
||||
Map<String, dynamic> toJson() {
|
||||
final json = <String, dynamic>{};
|
||||
if (this.error != null) {
|
||||
json[r'error'] = this.error;
|
||||
} else {
|
||||
// json[r'error'] = null;
|
||||
}
|
||||
json[r'success'] = this.success;
|
||||
return json;
|
||||
}
|
||||
|
||||
/// Returns a new [AlbumsAddAssetsResponseDto] instance and imports its values from
|
||||
/// [value] if it's a [Map], null otherwise.
|
||||
// ignore: prefer_constructors_over_static_methods
|
||||
static AlbumsAddAssetsResponseDto? fromJson(dynamic value) {
|
||||
upgradeDto(value, "AlbumsAddAssetsResponseDto");
|
||||
if (value is Map) {
|
||||
final json = value.cast<String, dynamic>();
|
||||
|
||||
return AlbumsAddAssetsResponseDto(
|
||||
error: BulkIdErrorReason.fromJson(json[r'error']),
|
||||
success: mapValueOfType<bool>(json, r'success')!,
|
||||
);
|
||||
}
|
||||
return null;
|
||||
}
|
||||
|
||||
static List<AlbumsAddAssetsResponseDto> listFromJson(dynamic json, {bool growable = false,}) {
|
||||
final result = <AlbumsAddAssetsResponseDto>[];
|
||||
if (json is List && json.isNotEmpty) {
|
||||
for (final row in json) {
|
||||
final value = AlbumsAddAssetsResponseDto.fromJson(row);
|
||||
if (value != null) {
|
||||
result.add(value);
|
||||
}
|
||||
}
|
||||
}
|
||||
return result.toList(growable: growable);
|
||||
}
|
||||
|
||||
static Map<String, AlbumsAddAssetsResponseDto> mapFromJson(dynamic json) {
|
||||
final map = <String, AlbumsAddAssetsResponseDto>{};
|
||||
if (json is Map && json.isNotEmpty) {
|
||||
json = json.cast<String, dynamic>(); // ignore: parameter_assignments
|
||||
for (final entry in json.entries) {
|
||||
final value = AlbumsAddAssetsResponseDto.fromJson(entry.value);
|
||||
if (value != null) {
|
||||
map[entry.key] = value;
|
||||
}
|
||||
}
|
||||
}
|
||||
return map;
|
||||
}
|
||||
|
||||
// maps a json object with a list of AlbumsAddAssetsResponseDto-objects as value to a dart map
|
||||
static Map<String, List<AlbumsAddAssetsResponseDto>> mapListFromJson(dynamic json, {bool growable = false,}) {
|
||||
final map = <String, List<AlbumsAddAssetsResponseDto>>{};
|
||||
if (json is Map && json.isNotEmpty) {
|
||||
// ignore: parameter_assignments
|
||||
json = json.cast<String, dynamic>();
|
||||
for (final entry in json.entries) {
|
||||
map[entry.key] = AlbumsAddAssetsResponseDto.listFromJson(entry.value, growable: growable,);
|
||||
}
|
||||
}
|
||||
return map;
|
||||
}
|
||||
|
||||
/// The list of required keys that must be present in a JSON.
|
||||
static const requiredKeys = <String>{
|
||||
'success',
|
||||
};
|
||||
}
|
||||
|
||||
+35
-1
@@ -14,6 +14,7 @@ class AssetBulkUpdateDto {
|
||||
/// Returns a new [AssetBulkUpdateDto] instance.
|
||||
AssetBulkUpdateDto({
|
||||
this.dateTimeOriginal,
|
||||
this.dateTimeRelative,
|
||||
this.description,
|
||||
this.duplicateId,
|
||||
this.ids = const [],
|
||||
@@ -21,6 +22,7 @@ class AssetBulkUpdateDto {
|
||||
this.latitude,
|
||||
this.longitude,
|
||||
this.rating,
|
||||
this.timeZone,
|
||||
this.visibility,
|
||||
});
|
||||
|
||||
@@ -32,6 +34,14 @@ class AssetBulkUpdateDto {
|
||||
///
|
||||
String? dateTimeOriginal;
|
||||
|
||||
///
|
||||
/// Please note: This property should have been non-nullable! Since the specification file
|
||||
/// does not include a default value (using the "default:" property), however, the generated
|
||||
/// source code must fall back to having a nullable type.
|
||||
/// Consider adding a "default:" property in the specification file to hide this note.
|
||||
///
|
||||
num? dateTimeRelative;
|
||||
|
||||
///
|
||||
/// Please note: This property should have been non-nullable! Since the specification file
|
||||
/// does not include a default value (using the "default:" property), however, the generated
|
||||
@@ -78,6 +88,14 @@ class AssetBulkUpdateDto {
|
||||
///
|
||||
num? rating;
|
||||
|
||||
///
|
||||
/// Please note: This property should have been non-nullable! Since the specification file
|
||||
/// does not include a default value (using the "default:" property), however, the generated
|
||||
/// source code must fall back to having a nullable type.
|
||||
/// Consider adding a "default:" property in the specification file to hide this note.
|
||||
///
|
||||
String? timeZone;
|
||||
|
||||
///
|
||||
/// Please note: This property should have been non-nullable! Since the specification file
|
||||
/// does not include a default value (using the "default:" property), however, the generated
|
||||
@@ -89,6 +107,7 @@ class AssetBulkUpdateDto {
|
||||
@override
|
||||
bool operator ==(Object other) => identical(this, other) || other is AssetBulkUpdateDto &&
|
||||
other.dateTimeOriginal == dateTimeOriginal &&
|
||||
other.dateTimeRelative == dateTimeRelative &&
|
||||
other.description == description &&
|
||||
other.duplicateId == duplicateId &&
|
||||
_deepEquality.equals(other.ids, ids) &&
|
||||
@@ -96,12 +115,14 @@ class AssetBulkUpdateDto {
|
||||
other.latitude == latitude &&
|
||||
other.longitude == longitude &&
|
||||
other.rating == rating &&
|
||||
other.timeZone == timeZone &&
|
||||
other.visibility == visibility;
|
||||
|
||||
@override
|
||||
int get hashCode =>
|
||||
// ignore: unnecessary_parenthesis
|
||||
(dateTimeOriginal == null ? 0 : dateTimeOriginal!.hashCode) +
|
||||
(dateTimeRelative == null ? 0 : dateTimeRelative!.hashCode) +
|
||||
(description == null ? 0 : description!.hashCode) +
|
||||
(duplicateId == null ? 0 : duplicateId!.hashCode) +
|
||||
(ids.hashCode) +
|
||||
@@ -109,10 +130,11 @@ class AssetBulkUpdateDto {
|
||||
(latitude == null ? 0 : latitude!.hashCode) +
|
||||
(longitude == null ? 0 : longitude!.hashCode) +
|
||||
(rating == null ? 0 : rating!.hashCode) +
|
||||
(timeZone == null ? 0 : timeZone!.hashCode) +
|
||||
(visibility == null ? 0 : visibility!.hashCode);
|
||||
|
||||
@override
|
||||
String toString() => 'AssetBulkUpdateDto[dateTimeOriginal=$dateTimeOriginal, description=$description, duplicateId=$duplicateId, ids=$ids, isFavorite=$isFavorite, latitude=$latitude, longitude=$longitude, rating=$rating, visibility=$visibility]';
|
||||
String toString() => 'AssetBulkUpdateDto[dateTimeOriginal=$dateTimeOriginal, dateTimeRelative=$dateTimeRelative, description=$description, duplicateId=$duplicateId, ids=$ids, isFavorite=$isFavorite, latitude=$latitude, longitude=$longitude, rating=$rating, timeZone=$timeZone, visibility=$visibility]';
|
||||
|
||||
Map<String, dynamic> toJson() {
|
||||
final json = <String, dynamic>{};
|
||||
@@ -121,6 +143,11 @@ class AssetBulkUpdateDto {
|
||||
} else {
|
||||
// json[r'dateTimeOriginal'] = null;
|
||||
}
|
||||
if (this.dateTimeRelative != null) {
|
||||
json[r'dateTimeRelative'] = this.dateTimeRelative;
|
||||
} else {
|
||||
// json[r'dateTimeRelative'] = null;
|
||||
}
|
||||
if (this.description != null) {
|
||||
json[r'description'] = this.description;
|
||||
} else {
|
||||
@@ -152,6 +179,11 @@ class AssetBulkUpdateDto {
|
||||
} else {
|
||||
// json[r'rating'] = null;
|
||||
}
|
||||
if (this.timeZone != null) {
|
||||
json[r'timeZone'] = this.timeZone;
|
||||
} else {
|
||||
// json[r'timeZone'] = null;
|
||||
}
|
||||
if (this.visibility != null) {
|
||||
json[r'visibility'] = this.visibility;
|
||||
} else {
|
||||
@@ -170,6 +202,7 @@ class AssetBulkUpdateDto {
|
||||
|
||||
return AssetBulkUpdateDto(
|
||||
dateTimeOriginal: mapValueOfType<String>(json, r'dateTimeOriginal'),
|
||||
dateTimeRelative: num.parse('${json[r'dateTimeRelative']}'),
|
||||
description: mapValueOfType<String>(json, r'description'),
|
||||
duplicateId: mapValueOfType<String>(json, r'duplicateId'),
|
||||
ids: json[r'ids'] is Iterable
|
||||
@@ -179,6 +212,7 @@ class AssetBulkUpdateDto {
|
||||
latitude: num.parse('${json[r'latitude']}'),
|
||||
longitude: num.parse('${json[r'longitude']}'),
|
||||
rating: num.parse('${json[r'rating']}'),
|
||||
timeZone: mapValueOfType<String>(json, r'timeZone'),
|
||||
visibility: AssetVisibility.fromJson(json[r'visibility']),
|
||||
);
|
||||
}
|
||||
|
||||
+82
@@ -0,0 +1,82 @@
|
||||
//
|
||||
// AUTO-GENERATED FILE, DO NOT MODIFY!
|
||||
//
|
||||
// @dart=2.18
|
||||
|
||||
// ignore_for_file: unused_element, unused_import
|
||||
// ignore_for_file: always_put_required_named_parameters_first
|
||||
// ignore_for_file: constant_identifier_names
|
||||
// ignore_for_file: lines_longer_than_80_chars
|
||||
|
||||
part of openapi.api;
|
||||
|
||||
|
||||
class AssetMetadataKey {
|
||||
/// Instantiate a new enum with the provided [value].
|
||||
const AssetMetadataKey._(this.value);
|
||||
|
||||
/// The underlying value of this enum member.
|
||||
final String value;
|
||||
|
||||
@override
|
||||
String toString() => value;
|
||||
|
||||
String toJson() => value;
|
||||
|
||||
static const mobileApp = AssetMetadataKey._(r'mobile-app');
|
||||
|
||||
/// List of all possible values in this [enum][AssetMetadataKey].
|
||||
static const values = <AssetMetadataKey>[
|
||||
mobileApp,
|
||||
];
|
||||
|
||||
static AssetMetadataKey? fromJson(dynamic value) => AssetMetadataKeyTypeTransformer().decode(value);
|
||||
|
||||
static List<AssetMetadataKey> listFromJson(dynamic json, {bool growable = false,}) {
|
||||
final result = <AssetMetadataKey>[];
|
||||
if (json is List && json.isNotEmpty) {
|
||||
for (final row in json) {
|
||||
final value = AssetMetadataKey.fromJson(row);
|
||||
if (value != null) {
|
||||
result.add(value);
|
||||
}
|
||||
}
|
||||
}
|
||||
return result.toList(growable: growable);
|
||||
}
|
||||
}
|
||||
|
||||
/// Transformation class that can [encode] an instance of [AssetMetadataKey] to String,
|
||||
/// and [decode] dynamic data back to [AssetMetadataKey].
|
||||
class AssetMetadataKeyTypeTransformer {
|
||||
factory AssetMetadataKeyTypeTransformer() => _instance ??= const AssetMetadataKeyTypeTransformer._();
|
||||
|
||||
const AssetMetadataKeyTypeTransformer._();
|
||||
|
||||
String encode(AssetMetadataKey data) => data.value;
|
||||
|
||||
/// Decodes a [dynamic value][data] to a AssetMetadataKey.
|
||||
///
|
||||
/// If [allowNull] is true and the [dynamic value][data] cannot be decoded successfully,
|
||||
/// then null is returned. However, if [allowNull] is false and the [dynamic value][data]
|
||||
/// cannot be decoded successfully, then an [UnimplementedError] is thrown.
|
||||
///
|
||||
/// The [allowNull] is very handy when an API changes and a new enum value is added or removed,
|
||||
/// and users are still using an old app with the old code.
|
||||
AssetMetadataKey? decode(dynamic data, {bool allowNull = true}) {
|
||||
if (data != null) {
|
||||
switch (data) {
|
||||
case r'mobile-app': return AssetMetadataKey.mobileApp;
|
||||
default:
|
||||
if (!allowNull) {
|
||||
throw ArgumentError('Unknown enum value to decode: $data');
|
||||
}
|
||||
}
|
||||
}
|
||||
return null;
|
||||
}
|
||||
|
||||
/// Singleton [AssetMetadataKeyTypeTransformer] instance.
|
||||
static AssetMetadataKeyTypeTransformer? _instance;
|
||||
}
|
||||
|
||||
@@ -0,0 +1,115 @@
|
||||
//
|
||||
// AUTO-GENERATED FILE, DO NOT MODIFY!
|
||||
//
|
||||
// @dart=2.18
|
||||
|
||||
// ignore_for_file: unused_element, unused_import
|
||||
// ignore_for_file: always_put_required_named_parameters_first
|
||||
// ignore_for_file: constant_identifier_names
|
||||
// ignore_for_file: lines_longer_than_80_chars
|
||||
|
||||
part of openapi.api;
|
||||
|
||||
class AssetMetadataResponseDto {
|
||||
/// Returns a new [AssetMetadataResponseDto] instance.
|
||||
AssetMetadataResponseDto({
|
||||
required this.key,
|
||||
required this.updatedAt,
|
||||
required this.value,
|
||||
});
|
||||
|
||||
AssetMetadataKey key;
|
||||
|
||||
DateTime updatedAt;
|
||||
|
||||
Object value;
|
||||
|
||||
@override
|
||||
bool operator ==(Object other) => identical(this, other) || other is AssetMetadataResponseDto &&
|
||||
other.key == key &&
|
||||
other.updatedAt == updatedAt &&
|
||||
other.value == value;
|
||||
|
||||
@override
|
||||
int get hashCode =>
|
||||
// ignore: unnecessary_parenthesis
|
||||
(key.hashCode) +
|
||||
(updatedAt.hashCode) +
|
||||
(value.hashCode);
|
||||
|
||||
@override
|
||||
String toString() => 'AssetMetadataResponseDto[key=$key, updatedAt=$updatedAt, value=$value]';
|
||||
|
||||
Map<String, dynamic> toJson() {
|
||||
final json = <String, dynamic>{};
|
||||
json[r'key'] = this.key;
|
||||
json[r'updatedAt'] = this.updatedAt.toUtc().toIso8601String();
|
||||
json[r'value'] = this.value;
|
||||
return json;
|
||||
}
|
||||
|
||||
/// Returns a new [AssetMetadataResponseDto] instance and imports its values from
|
||||
/// [value] if it's a [Map], null otherwise.
|
||||
// ignore: prefer_constructors_over_static_methods
|
||||
static AssetMetadataResponseDto? fromJson(dynamic value) {
|
||||
upgradeDto(value, "AssetMetadataResponseDto");
|
||||
if (value is Map) {
|
||||
final json = value.cast<String, dynamic>();
|
||||
|
||||
return AssetMetadataResponseDto(
|
||||
key: AssetMetadataKey.fromJson(json[r'key'])!,
|
||||
updatedAt: mapDateTime(json, r'updatedAt', r'')!,
|
||||
value: mapValueOfType<Object>(json, r'value')!,
|
||||
);
|
||||
}
|
||||
return null;
|
||||
}
|
||||
|
||||
static List<AssetMetadataResponseDto> listFromJson(dynamic json, {bool growable = false,}) {
|
||||
final result = <AssetMetadataResponseDto>[];
|
||||
if (json is List && json.isNotEmpty) {
|
||||
for (final row in json) {
|
||||
final value = AssetMetadataResponseDto.fromJson(row);
|
||||
if (value != null) {
|
||||
result.add(value);
|
||||
}
|
||||
}
|
||||
}
|
||||
return result.toList(growable: growable);
|
||||
}
|
||||
|
||||
static Map<String, AssetMetadataResponseDto> mapFromJson(dynamic json) {
|
||||
final map = <String, AssetMetadataResponseDto>{};
|
||||
if (json is Map && json.isNotEmpty) {
|
||||
json = json.cast<String, dynamic>(); // ignore: parameter_assignments
|
||||
for (final entry in json.entries) {
|
||||
final value = AssetMetadataResponseDto.fromJson(entry.value);
|
||||
if (value != null) {
|
||||
map[entry.key] = value;
|
||||
}
|
||||
}
|
||||
}
|
||||
return map;
|
||||
}
|
||||
|
||||
// maps a json object with a list of AssetMetadataResponseDto-objects as value to a dart map
|
||||
static Map<String, List<AssetMetadataResponseDto>> mapListFromJson(dynamic json, {bool growable = false,}) {
|
||||
final map = <String, List<AssetMetadataResponseDto>>{};
|
||||
if (json is Map && json.isNotEmpty) {
|
||||
// ignore: parameter_assignments
|
||||
json = json.cast<String, dynamic>();
|
||||
for (final entry in json.entries) {
|
||||
map[entry.key] = AssetMetadataResponseDto.listFromJson(entry.value, growable: growable,);
|
||||
}
|
||||
}
|
||||
return map;
|
||||
}
|
||||
|
||||
/// The list of required keys that must be present in a JSON.
|
||||
static const requiredKeys = <String>{
|
||||
'key',
|
||||
'updatedAt',
|
||||
'value',
|
||||
};
|
||||
}
|
||||
|
||||
@@ -0,0 +1,99 @@
|
||||
//
|
||||
// AUTO-GENERATED FILE, DO NOT MODIFY!
|
||||
//
|
||||
// @dart=2.18
|
||||
|
||||
// ignore_for_file: unused_element, unused_import
|
||||
// ignore_for_file: always_put_required_named_parameters_first
|
||||
// ignore_for_file: constant_identifier_names
|
||||
// ignore_for_file: lines_longer_than_80_chars
|
||||
|
||||
part of openapi.api;
|
||||
|
||||
class AssetMetadataUpsertDto {
|
||||
/// Returns a new [AssetMetadataUpsertDto] instance.
|
||||
AssetMetadataUpsertDto({
|
||||
this.items = const [],
|
||||
});
|
||||
|
||||
List<AssetMetadataUpsertItemDto> items;
|
||||
|
||||
@override
|
||||
bool operator ==(Object other) => identical(this, other) || other is AssetMetadataUpsertDto &&
|
||||
_deepEquality.equals(other.items, items);
|
||||
|
||||
@override
|
||||
int get hashCode =>
|
||||
// ignore: unnecessary_parenthesis
|
||||
(items.hashCode);
|
||||
|
||||
@override
|
||||
String toString() => 'AssetMetadataUpsertDto[items=$items]';
|
||||
|
||||
Map<String, dynamic> toJson() {
|
||||
final json = <String, dynamic>{};
|
||||
json[r'items'] = this.items;
|
||||
return json;
|
||||
}
|
||||
|
||||
/// Returns a new [AssetMetadataUpsertDto] instance and imports its values from
|
||||
/// [value] if it's a [Map], null otherwise.
|
||||
// ignore: prefer_constructors_over_static_methods
|
||||
static AssetMetadataUpsertDto? fromJson(dynamic value) {
|
||||
upgradeDto(value, "AssetMetadataUpsertDto");
|
||||
if (value is Map) {
|
||||
final json = value.cast<String, dynamic>();
|
||||
|
||||
return AssetMetadataUpsertDto(
|
||||
items: AssetMetadataUpsertItemDto.listFromJson(json[r'items']),
|
||||
);
|
||||
}
|
||||
return null;
|
||||
}
|
||||
|
||||
static List<AssetMetadataUpsertDto> listFromJson(dynamic json, {bool growable = false,}) {
|
||||
final result = <AssetMetadataUpsertDto>[];
|
||||
if (json is List && json.isNotEmpty) {
|
||||
for (final row in json) {
|
||||
final value = AssetMetadataUpsertDto.fromJson(row);
|
||||
if (value != null) {
|
||||
result.add(value);
|
||||
}
|
||||
}
|
||||
}
|
||||
return result.toList(growable: growable);
|
||||
}
|
||||
|
||||
static Map<String, AssetMetadataUpsertDto> mapFromJson(dynamic json) {
|
||||
final map = <String, AssetMetadataUpsertDto>{};
|
||||
if (json is Map && json.isNotEmpty) {
|
||||
json = json.cast<String, dynamic>(); // ignore: parameter_assignments
|
||||
for (final entry in json.entries) {
|
||||
final value = AssetMetadataUpsertDto.fromJson(entry.value);
|
||||
if (value != null) {
|
||||
map[entry.key] = value;
|
||||
}
|
||||
}
|
||||
}
|
||||
return map;
|
||||
}
|
||||
|
||||
// maps a json object with a list of AssetMetadataUpsertDto-objects as value to a dart map
|
||||
static Map<String, List<AssetMetadataUpsertDto>> mapListFromJson(dynamic json, {bool growable = false,}) {
|
||||
final map = <String, List<AssetMetadataUpsertDto>>{};
|
||||
if (json is Map && json.isNotEmpty) {
|
||||
// ignore: parameter_assignments
|
||||
json = json.cast<String, dynamic>();
|
||||
for (final entry in json.entries) {
|
||||
map[entry.key] = AssetMetadataUpsertDto.listFromJson(entry.value, growable: growable,);
|
||||
}
|
||||
}
|
||||
return map;
|
||||
}
|
||||
|
||||
/// The list of required keys that must be present in a JSON.
|
||||
static const requiredKeys = <String>{
|
||||
'items',
|
||||
};
|
||||
}
|
||||
|
||||
@@ -0,0 +1,107 @@
|
||||
//
|
||||
// AUTO-GENERATED FILE, DO NOT MODIFY!
|
||||
//
|
||||
// @dart=2.18
|
||||
|
||||
// ignore_for_file: unused_element, unused_import
|
||||
// ignore_for_file: always_put_required_named_parameters_first
|
||||
// ignore_for_file: constant_identifier_names
|
||||
// ignore_for_file: lines_longer_than_80_chars
|
||||
|
||||
part of openapi.api;
|
||||
|
||||
class AssetMetadataUpsertItemDto {
|
||||
/// Returns a new [AssetMetadataUpsertItemDto] instance.
|
||||
AssetMetadataUpsertItemDto({
|
||||
required this.key,
|
||||
required this.value,
|
||||
});
|
||||
|
||||
AssetMetadataKey key;
|
||||
|
||||
Object value;
|
||||
|
||||
@override
|
||||
bool operator ==(Object other) => identical(this, other) || other is AssetMetadataUpsertItemDto &&
|
||||
other.key == key &&
|
||||
other.value == value;
|
||||
|
||||
@override
|
||||
int get hashCode =>
|
||||
// ignore: unnecessary_parenthesis
|
||||
(key.hashCode) +
|
||||
(value.hashCode);
|
||||
|
||||
@override
|
||||
String toString() => 'AssetMetadataUpsertItemDto[key=$key, value=$value]';
|
||||
|
||||
Map<String, dynamic> toJson() {
|
||||
final json = <String, dynamic>{};
|
||||
json[r'key'] = this.key;
|
||||
json[r'value'] = this.value;
|
||||
return json;
|
||||
}
|
||||
|
||||
/// Returns a new [AssetMetadataUpsertItemDto] instance and imports its values from
|
||||
/// [value] if it's a [Map], null otherwise.
|
||||
// ignore: prefer_constructors_over_static_methods
|
||||
static AssetMetadataUpsertItemDto? fromJson(dynamic value) {
|
||||
upgradeDto(value, "AssetMetadataUpsertItemDto");
|
||||
if (value is Map) {
|
||||
final json = value.cast<String, dynamic>();
|
||||
|
||||
return AssetMetadataUpsertItemDto(
|
||||
key: AssetMetadataKey.fromJson(json[r'key'])!,
|
||||
value: mapValueOfType<Object>(json, r'value')!,
|
||||
);
|
||||
}
|
||||
return null;
|
||||
}
|
||||
|
||||
static List<AssetMetadataUpsertItemDto> listFromJson(dynamic json, {bool growable = false,}) {
|
||||
final result = <AssetMetadataUpsertItemDto>[];
|
||||
if (json is List && json.isNotEmpty) {
|
||||
for (final row in json) {
|
||||
final value = AssetMetadataUpsertItemDto.fromJson(row);
|
||||
if (value != null) {
|
||||
result.add(value);
|
||||
}
|
||||
}
|
||||
}
|
||||
return result.toList(growable: growable);
|
||||
}
|
||||
|
||||
static Map<String, AssetMetadataUpsertItemDto> mapFromJson(dynamic json) {
|
||||
final map = <String, AssetMetadataUpsertItemDto>{};
|
||||
if (json is Map && json.isNotEmpty) {
|
||||
json = json.cast<String, dynamic>(); // ignore: parameter_assignments
|
||||
for (final entry in json.entries) {
|
||||
final value = AssetMetadataUpsertItemDto.fromJson(entry.value);
|
||||
if (value != null) {
|
||||
map[entry.key] = value;
|
||||
}
|
||||
}
|
||||
}
|
||||
return map;
|
||||
}
|
||||
|
||||
// maps a json object with a list of AssetMetadataUpsertItemDto-objects as value to a dart map
|
||||
static Map<String, List<AssetMetadataUpsertItemDto>> mapListFromJson(dynamic json, {bool growable = false,}) {
|
||||
final map = <String, List<AssetMetadataUpsertItemDto>>{};
|
||||
if (json is Map && json.isNotEmpty) {
|
||||
// ignore: parameter_assignments
|
||||
json = json.cast<String, dynamic>();
|
||||
for (final entry in json.entries) {
|
||||
map[entry.key] = AssetMetadataUpsertItemDto.listFromJson(entry.value, growable: growable,);
|
||||
}
|
||||
}
|
||||
return map;
|
||||
}
|
||||
|
||||
/// The list of required keys that must be present in a JSON.
|
||||
static const requiredKeys = <String>{
|
||||
'key',
|
||||
'value',
|
||||
};
|
||||
}
|
||||
|
||||
+10
-1
@@ -14,6 +14,7 @@ class AssetResponseDto {
|
||||
/// Returns a new [AssetResponseDto] instance.
|
||||
AssetResponseDto({
|
||||
required this.checksum,
|
||||
required this.createdAt,
|
||||
required this.deviceAssetId,
|
||||
required this.deviceId,
|
||||
this.duplicateId,
|
||||
@@ -49,6 +50,9 @@ class AssetResponseDto {
|
||||
/// base64 encoded sha1 hash
|
||||
String checksum;
|
||||
|
||||
/// The UTC timestamp when the asset was originally uploaded to Immich.
|
||||
DateTime createdAt;
|
||||
|
||||
String deviceAssetId;
|
||||
|
||||
String deviceId;
|
||||
@@ -142,6 +146,7 @@ class AssetResponseDto {
|
||||
@override
|
||||
bool operator ==(Object other) => identical(this, other) || other is AssetResponseDto &&
|
||||
other.checksum == checksum &&
|
||||
other.createdAt == createdAt &&
|
||||
other.deviceAssetId == deviceAssetId &&
|
||||
other.deviceId == deviceId &&
|
||||
other.duplicateId == duplicateId &&
|
||||
@@ -177,6 +182,7 @@ class AssetResponseDto {
|
||||
int get hashCode =>
|
||||
// ignore: unnecessary_parenthesis
|
||||
(checksum.hashCode) +
|
||||
(createdAt.hashCode) +
|
||||
(deviceAssetId.hashCode) +
|
||||
(deviceId.hashCode) +
|
||||
(duplicateId == null ? 0 : duplicateId!.hashCode) +
|
||||
@@ -209,11 +215,12 @@ class AssetResponseDto {
|
||||
(visibility.hashCode);
|
||||
|
||||
@override
|
||||
String toString() => 'AssetResponseDto[checksum=$checksum, deviceAssetId=$deviceAssetId, deviceId=$deviceId, duplicateId=$duplicateId, duration=$duration, exifInfo=$exifInfo, fileCreatedAt=$fileCreatedAt, fileModifiedAt=$fileModifiedAt, hasMetadata=$hasMetadata, id=$id, isArchived=$isArchived, isFavorite=$isFavorite, isOffline=$isOffline, isTrashed=$isTrashed, libraryId=$libraryId, livePhotoVideoId=$livePhotoVideoId, localDateTime=$localDateTime, originalFileName=$originalFileName, originalMimeType=$originalMimeType, originalPath=$originalPath, owner=$owner, ownerId=$ownerId, people=$people, resized=$resized, stack=$stack, tags=$tags, thumbhash=$thumbhash, type=$type, unassignedFaces=$unassignedFaces, updatedAt=$updatedAt, visibility=$visibility]';
|
||||
String toString() => 'AssetResponseDto[checksum=$checksum, createdAt=$createdAt, deviceAssetId=$deviceAssetId, deviceId=$deviceId, duplicateId=$duplicateId, duration=$duration, exifInfo=$exifInfo, fileCreatedAt=$fileCreatedAt, fileModifiedAt=$fileModifiedAt, hasMetadata=$hasMetadata, id=$id, isArchived=$isArchived, isFavorite=$isFavorite, isOffline=$isOffline, isTrashed=$isTrashed, libraryId=$libraryId, livePhotoVideoId=$livePhotoVideoId, localDateTime=$localDateTime, originalFileName=$originalFileName, originalMimeType=$originalMimeType, originalPath=$originalPath, owner=$owner, ownerId=$ownerId, people=$people, resized=$resized, stack=$stack, tags=$tags, thumbhash=$thumbhash, type=$type, unassignedFaces=$unassignedFaces, updatedAt=$updatedAt, visibility=$visibility]';
|
||||
|
||||
Map<String, dynamic> toJson() {
|
||||
final json = <String, dynamic>{};
|
||||
json[r'checksum'] = this.checksum;
|
||||
json[r'createdAt'] = this.createdAt.toUtc().toIso8601String();
|
||||
json[r'deviceAssetId'] = this.deviceAssetId;
|
||||
json[r'deviceId'] = this.deviceId;
|
||||
if (this.duplicateId != null) {
|
||||
@@ -293,6 +300,7 @@ class AssetResponseDto {
|
||||
|
||||
return AssetResponseDto(
|
||||
checksum: mapValueOfType<String>(json, r'checksum')!,
|
||||
createdAt: mapDateTime(json, r'createdAt', r'')!,
|
||||
deviceAssetId: mapValueOfType<String>(json, r'deviceAssetId')!,
|
||||
deviceId: mapValueOfType<String>(json, r'deviceId')!,
|
||||
duplicateId: mapValueOfType<String>(json, r'duplicateId'),
|
||||
@@ -371,6 +379,7 @@ class AssetResponseDto {
|
||||
/// The list of required keys that must be present in a JSON.
|
||||
static const requiredKeys = <String>{
|
||||
'checksum',
|
||||
'createdAt',
|
||||
'deviceAssetId',
|
||||
'deviceId',
|
||||
'duration',
|
||||
|
||||
+91
@@ -0,0 +1,91 @@
|
||||
//
|
||||
// AUTO-GENERATED FILE, DO NOT MODIFY!
|
||||
//
|
||||
// @dart=2.18
|
||||
|
||||
// ignore_for_file: unused_element, unused_import
|
||||
// ignore_for_file: always_put_required_named_parameters_first
|
||||
// ignore_for_file: constant_identifier_names
|
||||
// ignore_for_file: lines_longer_than_80_chars
|
||||
|
||||
part of openapi.api;
|
||||
|
||||
|
||||
class BulkIdErrorReason {
|
||||
/// Instantiate a new enum with the provided [value].
|
||||
const BulkIdErrorReason._(this.value);
|
||||
|
||||
/// The underlying value of this enum member.
|
||||
final String value;
|
||||
|
||||
@override
|
||||
String toString() => value;
|
||||
|
||||
String toJson() => value;
|
||||
|
||||
static const duplicate = BulkIdErrorReason._(r'duplicate');
|
||||
static const noPermission = BulkIdErrorReason._(r'no_permission');
|
||||
static const notFound = BulkIdErrorReason._(r'not_found');
|
||||
static const unknown = BulkIdErrorReason._(r'unknown');
|
||||
|
||||
/// List of all possible values in this [enum][BulkIdErrorReason].
|
||||
static const values = <BulkIdErrorReason>[
|
||||
duplicate,
|
||||
noPermission,
|
||||
notFound,
|
||||
unknown,
|
||||
];
|
||||
|
||||
static BulkIdErrorReason? fromJson(dynamic value) => BulkIdErrorReasonTypeTransformer().decode(value);
|
||||
|
||||
static List<BulkIdErrorReason> listFromJson(dynamic json, {bool growable = false,}) {
|
||||
final result = <BulkIdErrorReason>[];
|
||||
if (json is List && json.isNotEmpty) {
|
||||
for (final row in json) {
|
||||
final value = BulkIdErrorReason.fromJson(row);
|
||||
if (value != null) {
|
||||
result.add(value);
|
||||
}
|
||||
}
|
||||
}
|
||||
return result.toList(growable: growable);
|
||||
}
|
||||
}
|
||||
|
||||
/// Transformation class that can [encode] an instance of [BulkIdErrorReason] to String,
|
||||
/// and [decode] dynamic data back to [BulkIdErrorReason].
|
||||
class BulkIdErrorReasonTypeTransformer {
|
||||
factory BulkIdErrorReasonTypeTransformer() => _instance ??= const BulkIdErrorReasonTypeTransformer._();
|
||||
|
||||
const BulkIdErrorReasonTypeTransformer._();
|
||||
|
||||
String encode(BulkIdErrorReason data) => data.value;
|
||||
|
||||
/// Decodes a [dynamic value][data] to a BulkIdErrorReason.
|
||||
///
|
||||
/// If [allowNull] is true and the [dynamic value][data] cannot be decoded successfully,
|
||||
/// then null is returned. However, if [allowNull] is false and the [dynamic value][data]
|
||||
/// cannot be decoded successfully, then an [UnimplementedError] is thrown.
|
||||
///
|
||||
/// The [allowNull] is very handy when an API changes and a new enum value is added or removed,
|
||||
/// and users are still using an old app with the old code.
|
||||
BulkIdErrorReason? decode(dynamic data, {bool allowNull = true}) {
|
||||
if (data != null) {
|
||||
switch (data) {
|
||||
case r'duplicate': return BulkIdErrorReason.duplicate;
|
||||
case r'no_permission': return BulkIdErrorReason.noPermission;
|
||||
case r'not_found': return BulkIdErrorReason.notFound;
|
||||
case r'unknown': return BulkIdErrorReason.unknown;
|
||||
default:
|
||||
if (!allowNull) {
|
||||
throw ArgumentError('Unknown enum value to decode: $data');
|
||||
}
|
||||
}
|
||||
}
|
||||
return null;
|
||||
}
|
||||
|
||||
/// Singleton [BulkIdErrorReasonTypeTransformer] instance.
|
||||
static BulkIdErrorReasonTypeTransformer? _instance;
|
||||
}
|
||||
|
||||
@@ -0,0 +1,115 @@
|
||||
//
|
||||
// AUTO-GENERATED FILE, DO NOT MODIFY!
|
||||
//
|
||||
// @dart=2.18
|
||||
|
||||
// ignore_for_file: unused_element, unused_import
|
||||
// ignore_for_file: always_put_required_named_parameters_first
|
||||
// ignore_for_file: constant_identifier_names
|
||||
// ignore_for_file: lines_longer_than_80_chars
|
||||
|
||||
part of openapi.api;
|
||||
|
||||
class MachineLearningAvailabilityChecksDto {
|
||||
/// Returns a new [MachineLearningAvailabilityChecksDto] instance.
|
||||
MachineLearningAvailabilityChecksDto({
|
||||
required this.enabled,
|
||||
required this.interval,
|
||||
required this.timeout,
|
||||
});
|
||||
|
||||
bool enabled;
|
||||
|
||||
num interval;
|
||||
|
||||
num timeout;
|
||||
|
||||
@override
|
||||
bool operator ==(Object other) => identical(this, other) || other is MachineLearningAvailabilityChecksDto &&
|
||||
other.enabled == enabled &&
|
||||
other.interval == interval &&
|
||||
other.timeout == timeout;
|
||||
|
||||
@override
|
||||
int get hashCode =>
|
||||
// ignore: unnecessary_parenthesis
|
||||
(enabled.hashCode) +
|
||||
(interval.hashCode) +
|
||||
(timeout.hashCode);
|
||||
|
||||
@override
|
||||
String toString() => 'MachineLearningAvailabilityChecksDto[enabled=$enabled, interval=$interval, timeout=$timeout]';
|
||||
|
||||
Map<String, dynamic> toJson() {
|
||||
final json = <String, dynamic>{};
|
||||
json[r'enabled'] = this.enabled;
|
||||
json[r'interval'] = this.interval;
|
||||
json[r'timeout'] = this.timeout;
|
||||
return json;
|
||||
}
|
||||
|
||||
/// Returns a new [MachineLearningAvailabilityChecksDto] instance and imports its values from
|
||||
/// [value] if it's a [Map], null otherwise.
|
||||
// ignore: prefer_constructors_over_static_methods
|
||||
static MachineLearningAvailabilityChecksDto? fromJson(dynamic value) {
|
||||
upgradeDto(value, "MachineLearningAvailabilityChecksDto");
|
||||
if (value is Map) {
|
||||
final json = value.cast<String, dynamic>();
|
||||
|
||||
return MachineLearningAvailabilityChecksDto(
|
||||
enabled: mapValueOfType<bool>(json, r'enabled')!,
|
||||
interval: num.parse('${json[r'interval']}'),
|
||||
timeout: num.parse('${json[r'timeout']}'),
|
||||
);
|
||||
}
|
||||
return null;
|
||||
}
|
||||
|
||||
static List<MachineLearningAvailabilityChecksDto> listFromJson(dynamic json, {bool growable = false,}) {
|
||||
final result = <MachineLearningAvailabilityChecksDto>[];
|
||||
if (json is List && json.isNotEmpty) {
|
||||
for (final row in json) {
|
||||
final value = MachineLearningAvailabilityChecksDto.fromJson(row);
|
||||
if (value != null) {
|
||||
result.add(value);
|
||||
}
|
||||
}
|
||||
}
|
||||
return result.toList(growable: growable);
|
||||
}
|
||||
|
||||
static Map<String, MachineLearningAvailabilityChecksDto> mapFromJson(dynamic json) {
|
||||
final map = <String, MachineLearningAvailabilityChecksDto>{};
|
||||
if (json is Map && json.isNotEmpty) {
|
||||
json = json.cast<String, dynamic>(); // ignore: parameter_assignments
|
||||
for (final entry in json.entries) {
|
||||
final value = MachineLearningAvailabilityChecksDto.fromJson(entry.value);
|
||||
if (value != null) {
|
||||
map[entry.key] = value;
|
||||
}
|
||||
}
|
||||
}
|
||||
return map;
|
||||
}
|
||||
|
||||
// maps a json object with a list of MachineLearningAvailabilityChecksDto-objects as value to a dart map
|
||||
static Map<String, List<MachineLearningAvailabilityChecksDto>> mapListFromJson(dynamic json, {bool growable = false,}) {
|
||||
final map = <String, List<MachineLearningAvailabilityChecksDto>>{};
|
||||
if (json is Map && json.isNotEmpty) {
|
||||
// ignore: parameter_assignments
|
||||
json = json.cast<String, dynamic>();
|
||||
for (final entry in json.entries) {
|
||||
map[entry.key] = MachineLearningAvailabilityChecksDto.listFromJson(entry.value, growable: growable,);
|
||||
}
|
||||
}
|
||||
return map;
|
||||
}
|
||||
|
||||
/// The list of required keys that must be present in a JSON.
|
||||
static const requiredKeys = <String>{
|
||||
'enabled',
|
||||
'interval',
|
||||
'timeout',
|
||||
};
|
||||
}
|
||||
|
||||
+99
@@ -0,0 +1,99 @@
|
||||
//
|
||||
// AUTO-GENERATED FILE, DO NOT MODIFY!
|
||||
//
|
||||
// @dart=2.18
|
||||
|
||||
// ignore_for_file: unused_element, unused_import
|
||||
// ignore_for_file: always_put_required_named_parameters_first
|
||||
// ignore_for_file: constant_identifier_names
|
||||
// ignore_for_file: lines_longer_than_80_chars
|
||||
|
||||
part of openapi.api;
|
||||
|
||||
class PartnerCreateDto {
|
||||
/// Returns a new [PartnerCreateDto] instance.
|
||||
PartnerCreateDto({
|
||||
required this.sharedWithId,
|
||||
});
|
||||
|
||||
String sharedWithId;
|
||||
|
||||
@override
|
||||
bool operator ==(Object other) => identical(this, other) || other is PartnerCreateDto &&
|
||||
other.sharedWithId == sharedWithId;
|
||||
|
||||
@override
|
||||
int get hashCode =>
|
||||
// ignore: unnecessary_parenthesis
|
||||
(sharedWithId.hashCode);
|
||||
|
||||
@override
|
||||
String toString() => 'PartnerCreateDto[sharedWithId=$sharedWithId]';
|
||||
|
||||
Map<String, dynamic> toJson() {
|
||||
final json = <String, dynamic>{};
|
||||
json[r'sharedWithId'] = this.sharedWithId;
|
||||
return json;
|
||||
}
|
||||
|
||||
/// Returns a new [PartnerCreateDto] instance and imports its values from
|
||||
/// [value] if it's a [Map], null otherwise.
|
||||
// ignore: prefer_constructors_over_static_methods
|
||||
static PartnerCreateDto? fromJson(dynamic value) {
|
||||
upgradeDto(value, "PartnerCreateDto");
|
||||
if (value is Map) {
|
||||
final json = value.cast<String, dynamic>();
|
||||
|
||||
return PartnerCreateDto(
|
||||
sharedWithId: mapValueOfType<String>(json, r'sharedWithId')!,
|
||||
);
|
||||
}
|
||||
return null;
|
||||
}
|
||||
|
||||
static List<PartnerCreateDto> listFromJson(dynamic json, {bool growable = false,}) {
|
||||
final result = <PartnerCreateDto>[];
|
||||
if (json is List && json.isNotEmpty) {
|
||||
for (final row in json) {
|
||||
final value = PartnerCreateDto.fromJson(row);
|
||||
if (value != null) {
|
||||
result.add(value);
|
||||
}
|
||||
}
|
||||
}
|
||||
return result.toList(growable: growable);
|
||||
}
|
||||
|
||||
static Map<String, PartnerCreateDto> mapFromJson(dynamic json) {
|
||||
final map = <String, PartnerCreateDto>{};
|
||||
if (json is Map && json.isNotEmpty) {
|
||||
json = json.cast<String, dynamic>(); // ignore: parameter_assignments
|
||||
for (final entry in json.entries) {
|
||||
final value = PartnerCreateDto.fromJson(entry.value);
|
||||
if (value != null) {
|
||||
map[entry.key] = value;
|
||||
}
|
||||
}
|
||||
}
|
||||
return map;
|
||||
}
|
||||
|
||||
// maps a json object with a list of PartnerCreateDto-objects as value to a dart map
|
||||
static Map<String, List<PartnerCreateDto>> mapListFromJson(dynamic json, {bool growable = false,}) {
|
||||
final map = <String, List<PartnerCreateDto>>{};
|
||||
if (json is Map && json.isNotEmpty) {
|
||||
// ignore: parameter_assignments
|
||||
json = json.cast<String, dynamic>();
|
||||
for (final entry in json.entries) {
|
||||
map[entry.key] = PartnerCreateDto.listFromJson(entry.value, growable: growable,);
|
||||
}
|
||||
}
|
||||
return map;
|
||||
}
|
||||
|
||||
/// The list of required keys that must be present in a JSON.
|
||||
static const requiredKeys = <String>{
|
||||
'sharedWithId',
|
||||
};
|
||||
}
|
||||
|
||||
Generated
+19
-19
@@ -10,16 +10,16 @@
|
||||
|
||||
part of openapi.api;
|
||||
|
||||
class UpdatePartnerDto {
|
||||
/// Returns a new [UpdatePartnerDto] instance.
|
||||
UpdatePartnerDto({
|
||||
class PartnerUpdateDto {
|
||||
/// Returns a new [PartnerUpdateDto] instance.
|
||||
PartnerUpdateDto({
|
||||
required this.inTimeline,
|
||||
});
|
||||
|
||||
bool inTimeline;
|
||||
|
||||
@override
|
||||
bool operator ==(Object other) => identical(this, other) || other is UpdatePartnerDto &&
|
||||
bool operator ==(Object other) => identical(this, other) || other is PartnerUpdateDto &&
|
||||
other.inTimeline == inTimeline;
|
||||
|
||||
@override
|
||||
@@ -28,7 +28,7 @@ class UpdatePartnerDto {
|
||||
(inTimeline.hashCode);
|
||||
|
||||
@override
|
||||
String toString() => 'UpdatePartnerDto[inTimeline=$inTimeline]';
|
||||
String toString() => 'PartnerUpdateDto[inTimeline=$inTimeline]';
|
||||
|
||||
Map<String, dynamic> toJson() {
|
||||
final json = <String, dynamic>{};
|
||||
@@ -36,26 +36,26 @@ class UpdatePartnerDto {
|
||||
return json;
|
||||
}
|
||||
|
||||
/// Returns a new [UpdatePartnerDto] instance and imports its values from
|
||||
/// Returns a new [PartnerUpdateDto] instance and imports its values from
|
||||
/// [value] if it's a [Map], null otherwise.
|
||||
// ignore: prefer_constructors_over_static_methods
|
||||
static UpdatePartnerDto? fromJson(dynamic value) {
|
||||
upgradeDto(value, "UpdatePartnerDto");
|
||||
static PartnerUpdateDto? fromJson(dynamic value) {
|
||||
upgradeDto(value, "PartnerUpdateDto");
|
||||
if (value is Map) {
|
||||
final json = value.cast<String, dynamic>();
|
||||
|
||||
return UpdatePartnerDto(
|
||||
return PartnerUpdateDto(
|
||||
inTimeline: mapValueOfType<bool>(json, r'inTimeline')!,
|
||||
);
|
||||
}
|
||||
return null;
|
||||
}
|
||||
|
||||
static List<UpdatePartnerDto> listFromJson(dynamic json, {bool growable = false,}) {
|
||||
final result = <UpdatePartnerDto>[];
|
||||
static List<PartnerUpdateDto> listFromJson(dynamic json, {bool growable = false,}) {
|
||||
final result = <PartnerUpdateDto>[];
|
||||
if (json is List && json.isNotEmpty) {
|
||||
for (final row in json) {
|
||||
final value = UpdatePartnerDto.fromJson(row);
|
||||
final value = PartnerUpdateDto.fromJson(row);
|
||||
if (value != null) {
|
||||
result.add(value);
|
||||
}
|
||||
@@ -64,12 +64,12 @@ class UpdatePartnerDto {
|
||||
return result.toList(growable: growable);
|
||||
}
|
||||
|
||||
static Map<String, UpdatePartnerDto> mapFromJson(dynamic json) {
|
||||
final map = <String, UpdatePartnerDto>{};
|
||||
static Map<String, PartnerUpdateDto> mapFromJson(dynamic json) {
|
||||
final map = <String, PartnerUpdateDto>{};
|
||||
if (json is Map && json.isNotEmpty) {
|
||||
json = json.cast<String, dynamic>(); // ignore: parameter_assignments
|
||||
for (final entry in json.entries) {
|
||||
final value = UpdatePartnerDto.fromJson(entry.value);
|
||||
final value = PartnerUpdateDto.fromJson(entry.value);
|
||||
if (value != null) {
|
||||
map[entry.key] = value;
|
||||
}
|
||||
@@ -78,14 +78,14 @@ class UpdatePartnerDto {
|
||||
return map;
|
||||
}
|
||||
|
||||
// maps a json object with a list of UpdatePartnerDto-objects as value to a dart map
|
||||
static Map<String, List<UpdatePartnerDto>> mapListFromJson(dynamic json, {bool growable = false,}) {
|
||||
final map = <String, List<UpdatePartnerDto>>{};
|
||||
// maps a json object with a list of PartnerUpdateDto-objects as value to a dart map
|
||||
static Map<String, List<PartnerUpdateDto>> mapListFromJson(dynamic json, {bool growable = false,}) {
|
||||
final map = <String, List<PartnerUpdateDto>>{};
|
||||
if (json is Map && json.isNotEmpty) {
|
||||
// ignore: parameter_assignments
|
||||
json = json.cast<String, dynamic>();
|
||||
for (final entry in json.entries) {
|
||||
map[entry.key] = UpdatePartnerDto.listFromJson(entry.value, growable: growable,);
|
||||
map[entry.key] = PartnerUpdateDto.listFromJson(entry.value, growable: growable,);
|
||||
}
|
||||
}
|
||||
return map;
|
||||
Generated
+150
-18
@@ -36,25 +36,35 @@ class Permission {
|
||||
static const assetPeriodRead = Permission._(r'asset.read');
|
||||
static const assetPeriodUpdate = Permission._(r'asset.update');
|
||||
static const assetPeriodDelete = Permission._(r'asset.delete');
|
||||
static const assetPeriodStatistics = Permission._(r'asset.statistics');
|
||||
static const assetPeriodShare = Permission._(r'asset.share');
|
||||
static const assetPeriodView = Permission._(r'asset.view');
|
||||
static const assetPeriodDownload = Permission._(r'asset.download');
|
||||
static const assetPeriodUpload = Permission._(r'asset.upload');
|
||||
static const assetPeriodReplace = Permission._(r'asset.replace');
|
||||
static const albumPeriodCreate = Permission._(r'album.create');
|
||||
static const albumPeriodRead = Permission._(r'album.read');
|
||||
static const albumPeriodUpdate = Permission._(r'album.update');
|
||||
static const albumPeriodDelete = Permission._(r'album.delete');
|
||||
static const albumPeriodStatistics = Permission._(r'album.statistics');
|
||||
static const albumPeriodAddAsset = Permission._(r'album.addAsset');
|
||||
static const albumPeriodRemoveAsset = Permission._(r'album.removeAsset');
|
||||
static const albumPeriodShare = Permission._(r'album.share');
|
||||
static const albumPeriodDownload = Permission._(r'album.download');
|
||||
static const albumAssetPeriodCreate = Permission._(r'albumAsset.create');
|
||||
static const albumAssetPeriodDelete = Permission._(r'albumAsset.delete');
|
||||
static const albumUserPeriodCreate = Permission._(r'albumUser.create');
|
||||
static const albumUserPeriodUpdate = Permission._(r'albumUser.update');
|
||||
static const albumUserPeriodDelete = Permission._(r'albumUser.delete');
|
||||
static const authPeriodChangePassword = Permission._(r'auth.changePassword');
|
||||
static const authDevicePeriodDelete = Permission._(r'authDevice.delete');
|
||||
static const archivePeriodRead = Permission._(r'archive.read');
|
||||
static const duplicatePeriodRead = Permission._(r'duplicate.read');
|
||||
static const duplicatePeriodDelete = Permission._(r'duplicate.delete');
|
||||
static const facePeriodCreate = Permission._(r'face.create');
|
||||
static const facePeriodRead = Permission._(r'face.read');
|
||||
static const facePeriodUpdate = Permission._(r'face.update');
|
||||
static const facePeriodDelete = Permission._(r'face.delete');
|
||||
static const jobPeriodCreate = Permission._(r'job.create');
|
||||
static const jobPeriodRead = Permission._(r'job.read');
|
||||
static const libraryPeriodCreate = Permission._(r'library.create');
|
||||
static const libraryPeriodRead = Permission._(r'library.read');
|
||||
static const libraryPeriodUpdate = Permission._(r'library.update');
|
||||
@@ -66,6 +76,9 @@ class Permission {
|
||||
static const memoryPeriodRead = Permission._(r'memory.read');
|
||||
static const memoryPeriodUpdate = Permission._(r'memory.update');
|
||||
static const memoryPeriodDelete = Permission._(r'memory.delete');
|
||||
static const memoryPeriodStatistics = Permission._(r'memory.statistics');
|
||||
static const memoryAssetPeriodCreate = Permission._(r'memoryAsset.create');
|
||||
static const memoryAssetPeriodDelete = Permission._(r'memoryAsset.delete');
|
||||
static const notificationPeriodCreate = Permission._(r'notification.create');
|
||||
static const notificationPeriodRead = Permission._(r'notification.read');
|
||||
static const notificationPeriodUpdate = Permission._(r'notification.update');
|
||||
@@ -81,6 +94,17 @@ class Permission {
|
||||
static const personPeriodStatistics = Permission._(r'person.statistics');
|
||||
static const personPeriodMerge = Permission._(r'person.merge');
|
||||
static const personPeriodReassign = Permission._(r'person.reassign');
|
||||
static const pinCodePeriodCreate = Permission._(r'pinCode.create');
|
||||
static const pinCodePeriodUpdate = Permission._(r'pinCode.update');
|
||||
static const pinCodePeriodDelete = Permission._(r'pinCode.delete');
|
||||
static const serverPeriodAbout = Permission._(r'server.about');
|
||||
static const serverPeriodApkLinks = Permission._(r'server.apkLinks');
|
||||
static const serverPeriodStorage = Permission._(r'server.storage');
|
||||
static const serverPeriodStatistics = Permission._(r'server.statistics');
|
||||
static const serverPeriodVersionCheck = Permission._(r'server.versionCheck');
|
||||
static const serverLicensePeriodRead = Permission._(r'serverLicense.read');
|
||||
static const serverLicensePeriodUpdate = Permission._(r'serverLicense.update');
|
||||
static const serverLicensePeriodDelete = Permission._(r'serverLicense.delete');
|
||||
static const sessionPeriodCreate = Permission._(r'session.create');
|
||||
static const sessionPeriodRead = Permission._(r'session.read');
|
||||
static const sessionPeriodUpdate = Permission._(r'session.update');
|
||||
@@ -94,6 +118,10 @@ class Permission {
|
||||
static const stackPeriodRead = Permission._(r'stack.read');
|
||||
static const stackPeriodUpdate = Permission._(r'stack.update');
|
||||
static const stackPeriodDelete = Permission._(r'stack.delete');
|
||||
static const syncPeriodStream = Permission._(r'sync.stream');
|
||||
static const syncCheckpointPeriodRead = Permission._(r'syncCheckpoint.read');
|
||||
static const syncCheckpointPeriodUpdate = Permission._(r'syncCheckpoint.update');
|
||||
static const syncCheckpointPeriodDelete = Permission._(r'syncCheckpoint.delete');
|
||||
static const systemConfigPeriodRead = Permission._(r'systemConfig.read');
|
||||
static const systemConfigPeriodUpdate = Permission._(r'systemConfig.update');
|
||||
static const systemMetadataPeriodRead = Permission._(r'systemMetadata.read');
|
||||
@@ -103,10 +131,26 @@ class Permission {
|
||||
static const tagPeriodUpdate = Permission._(r'tag.update');
|
||||
static const tagPeriodDelete = Permission._(r'tag.delete');
|
||||
static const tagPeriodAsset = Permission._(r'tag.asset');
|
||||
static const adminPeriodUserPeriodCreate = Permission._(r'admin.user.create');
|
||||
static const adminPeriodUserPeriodRead = Permission._(r'admin.user.read');
|
||||
static const adminPeriodUserPeriodUpdate = Permission._(r'admin.user.update');
|
||||
static const adminPeriodUserPeriodDelete = Permission._(r'admin.user.delete');
|
||||
static const userPeriodRead = Permission._(r'user.read');
|
||||
static const userPeriodUpdate = Permission._(r'user.update');
|
||||
static const userLicensePeriodCreate = Permission._(r'userLicense.create');
|
||||
static const userLicensePeriodRead = Permission._(r'userLicense.read');
|
||||
static const userLicensePeriodUpdate = Permission._(r'userLicense.update');
|
||||
static const userLicensePeriodDelete = Permission._(r'userLicense.delete');
|
||||
static const userOnboardingPeriodRead = Permission._(r'userOnboarding.read');
|
||||
static const userOnboardingPeriodUpdate = Permission._(r'userOnboarding.update');
|
||||
static const userOnboardingPeriodDelete = Permission._(r'userOnboarding.delete');
|
||||
static const userPreferencePeriodRead = Permission._(r'userPreference.read');
|
||||
static const userPreferencePeriodUpdate = Permission._(r'userPreference.update');
|
||||
static const userProfileImagePeriodCreate = Permission._(r'userProfileImage.create');
|
||||
static const userProfileImagePeriodRead = Permission._(r'userProfileImage.read');
|
||||
static const userProfileImagePeriodUpdate = Permission._(r'userProfileImage.update');
|
||||
static const userProfileImagePeriodDelete = Permission._(r'userProfileImage.delete');
|
||||
static const adminUserPeriodCreate = Permission._(r'adminUser.create');
|
||||
static const adminUserPeriodRead = Permission._(r'adminUser.read');
|
||||
static const adminUserPeriodUpdate = Permission._(r'adminUser.update');
|
||||
static const adminUserPeriodDelete = Permission._(r'adminUser.delete');
|
||||
static const adminAuthPeriodUnlinkAll = Permission._(r'adminAuth.unlinkAll');
|
||||
|
||||
/// List of all possible values in this [enum][Permission].
|
||||
static const values = <Permission>[
|
||||
@@ -123,25 +167,35 @@ class Permission {
|
||||
assetPeriodRead,
|
||||
assetPeriodUpdate,
|
||||
assetPeriodDelete,
|
||||
assetPeriodStatistics,
|
||||
assetPeriodShare,
|
||||
assetPeriodView,
|
||||
assetPeriodDownload,
|
||||
assetPeriodUpload,
|
||||
assetPeriodReplace,
|
||||
albumPeriodCreate,
|
||||
albumPeriodRead,
|
||||
albumPeriodUpdate,
|
||||
albumPeriodDelete,
|
||||
albumPeriodStatistics,
|
||||
albumPeriodAddAsset,
|
||||
albumPeriodRemoveAsset,
|
||||
albumPeriodShare,
|
||||
albumPeriodDownload,
|
||||
albumAssetPeriodCreate,
|
||||
albumAssetPeriodDelete,
|
||||
albumUserPeriodCreate,
|
||||
albumUserPeriodUpdate,
|
||||
albumUserPeriodDelete,
|
||||
authPeriodChangePassword,
|
||||
authDevicePeriodDelete,
|
||||
archivePeriodRead,
|
||||
duplicatePeriodRead,
|
||||
duplicatePeriodDelete,
|
||||
facePeriodCreate,
|
||||
facePeriodRead,
|
||||
facePeriodUpdate,
|
||||
facePeriodDelete,
|
||||
jobPeriodCreate,
|
||||
jobPeriodRead,
|
||||
libraryPeriodCreate,
|
||||
libraryPeriodRead,
|
||||
libraryPeriodUpdate,
|
||||
@@ -153,6 +207,9 @@ class Permission {
|
||||
memoryPeriodRead,
|
||||
memoryPeriodUpdate,
|
||||
memoryPeriodDelete,
|
||||
memoryPeriodStatistics,
|
||||
memoryAssetPeriodCreate,
|
||||
memoryAssetPeriodDelete,
|
||||
notificationPeriodCreate,
|
||||
notificationPeriodRead,
|
||||
notificationPeriodUpdate,
|
||||
@@ -168,6 +225,17 @@ class Permission {
|
||||
personPeriodStatistics,
|
||||
personPeriodMerge,
|
||||
personPeriodReassign,
|
||||
pinCodePeriodCreate,
|
||||
pinCodePeriodUpdate,
|
||||
pinCodePeriodDelete,
|
||||
serverPeriodAbout,
|
||||
serverPeriodApkLinks,
|
||||
serverPeriodStorage,
|
||||
serverPeriodStatistics,
|
||||
serverPeriodVersionCheck,
|
||||
serverLicensePeriodRead,
|
||||
serverLicensePeriodUpdate,
|
||||
serverLicensePeriodDelete,
|
||||
sessionPeriodCreate,
|
||||
sessionPeriodRead,
|
||||
sessionPeriodUpdate,
|
||||
@@ -181,6 +249,10 @@ class Permission {
|
||||
stackPeriodRead,
|
||||
stackPeriodUpdate,
|
||||
stackPeriodDelete,
|
||||
syncPeriodStream,
|
||||
syncCheckpointPeriodRead,
|
||||
syncCheckpointPeriodUpdate,
|
||||
syncCheckpointPeriodDelete,
|
||||
systemConfigPeriodRead,
|
||||
systemConfigPeriodUpdate,
|
||||
systemMetadataPeriodRead,
|
||||
@@ -190,10 +262,26 @@ class Permission {
|
||||
tagPeriodUpdate,
|
||||
tagPeriodDelete,
|
||||
tagPeriodAsset,
|
||||
adminPeriodUserPeriodCreate,
|
||||
adminPeriodUserPeriodRead,
|
||||
adminPeriodUserPeriodUpdate,
|
||||
adminPeriodUserPeriodDelete,
|
||||
userPeriodRead,
|
||||
userPeriodUpdate,
|
||||
userLicensePeriodCreate,
|
||||
userLicensePeriodRead,
|
||||
userLicensePeriodUpdate,
|
||||
userLicensePeriodDelete,
|
||||
userOnboardingPeriodRead,
|
||||
userOnboardingPeriodUpdate,
|
||||
userOnboardingPeriodDelete,
|
||||
userPreferencePeriodRead,
|
||||
userPreferencePeriodUpdate,
|
||||
userProfileImagePeriodCreate,
|
||||
userProfileImagePeriodRead,
|
||||
userProfileImagePeriodUpdate,
|
||||
userProfileImagePeriodDelete,
|
||||
adminUserPeriodCreate,
|
||||
adminUserPeriodRead,
|
||||
adminUserPeriodUpdate,
|
||||
adminUserPeriodDelete,
|
||||
adminAuthPeriodUnlinkAll,
|
||||
];
|
||||
|
||||
static Permission? fromJson(dynamic value) => PermissionTypeTransformer().decode(value);
|
||||
@@ -245,25 +333,35 @@ class PermissionTypeTransformer {
|
||||
case r'asset.read': return Permission.assetPeriodRead;
|
||||
case r'asset.update': return Permission.assetPeriodUpdate;
|
||||
case r'asset.delete': return Permission.assetPeriodDelete;
|
||||
case r'asset.statistics': return Permission.assetPeriodStatistics;
|
||||
case r'asset.share': return Permission.assetPeriodShare;
|
||||
case r'asset.view': return Permission.assetPeriodView;
|
||||
case r'asset.download': return Permission.assetPeriodDownload;
|
||||
case r'asset.upload': return Permission.assetPeriodUpload;
|
||||
case r'asset.replace': return Permission.assetPeriodReplace;
|
||||
case r'album.create': return Permission.albumPeriodCreate;
|
||||
case r'album.read': return Permission.albumPeriodRead;
|
||||
case r'album.update': return Permission.albumPeriodUpdate;
|
||||
case r'album.delete': return Permission.albumPeriodDelete;
|
||||
case r'album.statistics': return Permission.albumPeriodStatistics;
|
||||
case r'album.addAsset': return Permission.albumPeriodAddAsset;
|
||||
case r'album.removeAsset': return Permission.albumPeriodRemoveAsset;
|
||||
case r'album.share': return Permission.albumPeriodShare;
|
||||
case r'album.download': return Permission.albumPeriodDownload;
|
||||
case r'albumAsset.create': return Permission.albumAssetPeriodCreate;
|
||||
case r'albumAsset.delete': return Permission.albumAssetPeriodDelete;
|
||||
case r'albumUser.create': return Permission.albumUserPeriodCreate;
|
||||
case r'albumUser.update': return Permission.albumUserPeriodUpdate;
|
||||
case r'albumUser.delete': return Permission.albumUserPeriodDelete;
|
||||
case r'auth.changePassword': return Permission.authPeriodChangePassword;
|
||||
case r'authDevice.delete': return Permission.authDevicePeriodDelete;
|
||||
case r'archive.read': return Permission.archivePeriodRead;
|
||||
case r'duplicate.read': return Permission.duplicatePeriodRead;
|
||||
case r'duplicate.delete': return Permission.duplicatePeriodDelete;
|
||||
case r'face.create': return Permission.facePeriodCreate;
|
||||
case r'face.read': return Permission.facePeriodRead;
|
||||
case r'face.update': return Permission.facePeriodUpdate;
|
||||
case r'face.delete': return Permission.facePeriodDelete;
|
||||
case r'job.create': return Permission.jobPeriodCreate;
|
||||
case r'job.read': return Permission.jobPeriodRead;
|
||||
case r'library.create': return Permission.libraryPeriodCreate;
|
||||
case r'library.read': return Permission.libraryPeriodRead;
|
||||
case r'library.update': return Permission.libraryPeriodUpdate;
|
||||
@@ -275,6 +373,9 @@ class PermissionTypeTransformer {
|
||||
case r'memory.read': return Permission.memoryPeriodRead;
|
||||
case r'memory.update': return Permission.memoryPeriodUpdate;
|
||||
case r'memory.delete': return Permission.memoryPeriodDelete;
|
||||
case r'memory.statistics': return Permission.memoryPeriodStatistics;
|
||||
case r'memoryAsset.create': return Permission.memoryAssetPeriodCreate;
|
||||
case r'memoryAsset.delete': return Permission.memoryAssetPeriodDelete;
|
||||
case r'notification.create': return Permission.notificationPeriodCreate;
|
||||
case r'notification.read': return Permission.notificationPeriodRead;
|
||||
case r'notification.update': return Permission.notificationPeriodUpdate;
|
||||
@@ -290,6 +391,17 @@ class PermissionTypeTransformer {
|
||||
case r'person.statistics': return Permission.personPeriodStatistics;
|
||||
case r'person.merge': return Permission.personPeriodMerge;
|
||||
case r'person.reassign': return Permission.personPeriodReassign;
|
||||
case r'pinCode.create': return Permission.pinCodePeriodCreate;
|
||||
case r'pinCode.update': return Permission.pinCodePeriodUpdate;
|
||||
case r'pinCode.delete': return Permission.pinCodePeriodDelete;
|
||||
case r'server.about': return Permission.serverPeriodAbout;
|
||||
case r'server.apkLinks': return Permission.serverPeriodApkLinks;
|
||||
case r'server.storage': return Permission.serverPeriodStorage;
|
||||
case r'server.statistics': return Permission.serverPeriodStatistics;
|
||||
case r'server.versionCheck': return Permission.serverPeriodVersionCheck;
|
||||
case r'serverLicense.read': return Permission.serverLicensePeriodRead;
|
||||
case r'serverLicense.update': return Permission.serverLicensePeriodUpdate;
|
||||
case r'serverLicense.delete': return Permission.serverLicensePeriodDelete;
|
||||
case r'session.create': return Permission.sessionPeriodCreate;
|
||||
case r'session.read': return Permission.sessionPeriodRead;
|
||||
case r'session.update': return Permission.sessionPeriodUpdate;
|
||||
@@ -303,6 +415,10 @@ class PermissionTypeTransformer {
|
||||
case r'stack.read': return Permission.stackPeriodRead;
|
||||
case r'stack.update': return Permission.stackPeriodUpdate;
|
||||
case r'stack.delete': return Permission.stackPeriodDelete;
|
||||
case r'sync.stream': return Permission.syncPeriodStream;
|
||||
case r'syncCheckpoint.read': return Permission.syncCheckpointPeriodRead;
|
||||
case r'syncCheckpoint.update': return Permission.syncCheckpointPeriodUpdate;
|
||||
case r'syncCheckpoint.delete': return Permission.syncCheckpointPeriodDelete;
|
||||
case r'systemConfig.read': return Permission.systemConfigPeriodRead;
|
||||
case r'systemConfig.update': return Permission.systemConfigPeriodUpdate;
|
||||
case r'systemMetadata.read': return Permission.systemMetadataPeriodRead;
|
||||
@@ -312,10 +428,26 @@ class PermissionTypeTransformer {
|
||||
case r'tag.update': return Permission.tagPeriodUpdate;
|
||||
case r'tag.delete': return Permission.tagPeriodDelete;
|
||||
case r'tag.asset': return Permission.tagPeriodAsset;
|
||||
case r'admin.user.create': return Permission.adminPeriodUserPeriodCreate;
|
||||
case r'admin.user.read': return Permission.adminPeriodUserPeriodRead;
|
||||
case r'admin.user.update': return Permission.adminPeriodUserPeriodUpdate;
|
||||
case r'admin.user.delete': return Permission.adminPeriodUserPeriodDelete;
|
||||
case r'user.read': return Permission.userPeriodRead;
|
||||
case r'user.update': return Permission.userPeriodUpdate;
|
||||
case r'userLicense.create': return Permission.userLicensePeriodCreate;
|
||||
case r'userLicense.read': return Permission.userLicensePeriodRead;
|
||||
case r'userLicense.update': return Permission.userLicensePeriodUpdate;
|
||||
case r'userLicense.delete': return Permission.userLicensePeriodDelete;
|
||||
case r'userOnboarding.read': return Permission.userOnboardingPeriodRead;
|
||||
case r'userOnboarding.update': return Permission.userOnboardingPeriodUpdate;
|
||||
case r'userOnboarding.delete': return Permission.userOnboardingPeriodDelete;
|
||||
case r'userPreference.read': return Permission.userPreferencePeriodRead;
|
||||
case r'userPreference.update': return Permission.userPreferencePeriodUpdate;
|
||||
case r'userProfileImage.create': return Permission.userProfileImagePeriodCreate;
|
||||
case r'userProfileImage.read': return Permission.userProfileImagePeriodRead;
|
||||
case r'userProfileImage.update': return Permission.userProfileImagePeriodUpdate;
|
||||
case r'userProfileImage.delete': return Permission.userProfileImagePeriodDelete;
|
||||
case r'adminUser.create': return Permission.adminUserPeriodCreate;
|
||||
case r'adminUser.read': return Permission.adminUserPeriodRead;
|
||||
case r'adminUser.update': return Permission.adminUserPeriodUpdate;
|
||||
case r'adminUser.delete': return Permission.adminUserPeriodDelete;
|
||||
case r'adminAuth.unlinkAll': return Permission.adminAuthPeriodUnlinkAll;
|
||||
default:
|
||||
if (!allowNull) {
|
||||
throw ArgumentError('Unknown enum value to decode: $data');
|
||||
|
||||
+12
-13
@@ -21,6 +21,7 @@ class SharedLinkCreateDto {
|
||||
this.expiresAt,
|
||||
this.password,
|
||||
this.showMetadata = true,
|
||||
this.slug,
|
||||
required this.type,
|
||||
});
|
||||
|
||||
@@ -44,26 +45,16 @@ class SharedLinkCreateDto {
|
||||
|
||||
List<String> assetIds;
|
||||
|
||||
///
|
||||
/// Please note: This property should have been non-nullable! Since the specification file
|
||||
/// does not include a default value (using the "default:" property), however, the generated
|
||||
/// source code must fall back to having a nullable type.
|
||||
/// Consider adding a "default:" property in the specification file to hide this note.
|
||||
///
|
||||
String? description;
|
||||
|
||||
DateTime? expiresAt;
|
||||
|
||||
///
|
||||
/// Please note: This property should have been non-nullable! Since the specification file
|
||||
/// does not include a default value (using the "default:" property), however, the generated
|
||||
/// source code must fall back to having a nullable type.
|
||||
/// Consider adding a "default:" property in the specification file to hide this note.
|
||||
///
|
||||
String? password;
|
||||
|
||||
bool showMetadata;
|
||||
|
||||
String? slug;
|
||||
|
||||
SharedLinkType type;
|
||||
|
||||
@override
|
||||
@@ -76,6 +67,7 @@ class SharedLinkCreateDto {
|
||||
other.expiresAt == expiresAt &&
|
||||
other.password == password &&
|
||||
other.showMetadata == showMetadata &&
|
||||
other.slug == slug &&
|
||||
other.type == type;
|
||||
|
||||
@override
|
||||
@@ -89,10 +81,11 @@ class SharedLinkCreateDto {
|
||||
(expiresAt == null ? 0 : expiresAt!.hashCode) +
|
||||
(password == null ? 0 : password!.hashCode) +
|
||||
(showMetadata.hashCode) +
|
||||
(slug == null ? 0 : slug!.hashCode) +
|
||||
(type.hashCode);
|
||||
|
||||
@override
|
||||
String toString() => 'SharedLinkCreateDto[albumId=$albumId, allowDownload=$allowDownload, allowUpload=$allowUpload, assetIds=$assetIds, description=$description, expiresAt=$expiresAt, password=$password, showMetadata=$showMetadata, type=$type]';
|
||||
String toString() => 'SharedLinkCreateDto[albumId=$albumId, allowDownload=$allowDownload, allowUpload=$allowUpload, assetIds=$assetIds, description=$description, expiresAt=$expiresAt, password=$password, showMetadata=$showMetadata, slug=$slug, type=$type]';
|
||||
|
||||
Map<String, dynamic> toJson() {
|
||||
final json = <String, dynamic>{};
|
||||
@@ -124,6 +117,11 @@ class SharedLinkCreateDto {
|
||||
// json[r'password'] = null;
|
||||
}
|
||||
json[r'showMetadata'] = this.showMetadata;
|
||||
if (this.slug != null) {
|
||||
json[r'slug'] = this.slug;
|
||||
} else {
|
||||
// json[r'slug'] = null;
|
||||
}
|
||||
json[r'type'] = this.type;
|
||||
return json;
|
||||
}
|
||||
@@ -147,6 +145,7 @@ class SharedLinkCreateDto {
|
||||
expiresAt: mapDateTime(json, r'expiresAt', r''),
|
||||
password: mapValueOfType<String>(json, r'password'),
|
||||
showMetadata: mapValueOfType<bool>(json, r'showMetadata') ?? true,
|
||||
slug: mapValueOfType<String>(json, r'slug'),
|
||||
type: SharedLinkType.fromJson(json[r'type'])!,
|
||||
);
|
||||
}
|
||||
|
||||
+14
-15
@@ -20,6 +20,7 @@ class SharedLinkEditDto {
|
||||
this.expiresAt,
|
||||
this.password,
|
||||
this.showMetadata,
|
||||
this.slug,
|
||||
});
|
||||
|
||||
///
|
||||
@@ -47,22 +48,10 @@ class SharedLinkEditDto {
|
||||
///
|
||||
bool? changeExpiryTime;
|
||||
|
||||
///
|
||||
/// Please note: This property should have been non-nullable! Since the specification file
|
||||
/// does not include a default value (using the "default:" property), however, the generated
|
||||
/// source code must fall back to having a nullable type.
|
||||
/// Consider adding a "default:" property in the specification file to hide this note.
|
||||
///
|
||||
String? description;
|
||||
|
||||
DateTime? expiresAt;
|
||||
|
||||
///
|
||||
/// Please note: This property should have been non-nullable! Since the specification file
|
||||
/// does not include a default value (using the "default:" property), however, the generated
|
||||
/// source code must fall back to having a nullable type.
|
||||
/// Consider adding a "default:" property in the specification file to hide this note.
|
||||
///
|
||||
String? password;
|
||||
|
||||
///
|
||||
@@ -73,6 +62,8 @@ class SharedLinkEditDto {
|
||||
///
|
||||
bool? showMetadata;
|
||||
|
||||
String? slug;
|
||||
|
||||
@override
|
||||
bool operator ==(Object other) => identical(this, other) || other is SharedLinkEditDto &&
|
||||
other.allowDownload == allowDownload &&
|
||||
@@ -81,7 +72,8 @@ class SharedLinkEditDto {
|
||||
other.description == description &&
|
||||
other.expiresAt == expiresAt &&
|
||||
other.password == password &&
|
||||
other.showMetadata == showMetadata;
|
||||
other.showMetadata == showMetadata &&
|
||||
other.slug == slug;
|
||||
|
||||
@override
|
||||
int get hashCode =>
|
||||
@@ -92,10 +84,11 @@ class SharedLinkEditDto {
|
||||
(description == null ? 0 : description!.hashCode) +
|
||||
(expiresAt == null ? 0 : expiresAt!.hashCode) +
|
||||
(password == null ? 0 : password!.hashCode) +
|
||||
(showMetadata == null ? 0 : showMetadata!.hashCode);
|
||||
(showMetadata == null ? 0 : showMetadata!.hashCode) +
|
||||
(slug == null ? 0 : slug!.hashCode);
|
||||
|
||||
@override
|
||||
String toString() => 'SharedLinkEditDto[allowDownload=$allowDownload, allowUpload=$allowUpload, changeExpiryTime=$changeExpiryTime, description=$description, expiresAt=$expiresAt, password=$password, showMetadata=$showMetadata]';
|
||||
String toString() => 'SharedLinkEditDto[allowDownload=$allowDownload, allowUpload=$allowUpload, changeExpiryTime=$changeExpiryTime, description=$description, expiresAt=$expiresAt, password=$password, showMetadata=$showMetadata, slug=$slug]';
|
||||
|
||||
Map<String, dynamic> toJson() {
|
||||
final json = <String, dynamic>{};
|
||||
@@ -134,6 +127,11 @@ class SharedLinkEditDto {
|
||||
} else {
|
||||
// json[r'showMetadata'] = null;
|
||||
}
|
||||
if (this.slug != null) {
|
||||
json[r'slug'] = this.slug;
|
||||
} else {
|
||||
// json[r'slug'] = null;
|
||||
}
|
||||
return json;
|
||||
}
|
||||
|
||||
@@ -153,6 +151,7 @@ class SharedLinkEditDto {
|
||||
expiresAt: mapDateTime(json, r'expiresAt', r''),
|
||||
password: mapValueOfType<String>(json, r'password'),
|
||||
showMetadata: mapValueOfType<bool>(json, r'showMetadata'),
|
||||
slug: mapValueOfType<String>(json, r'slug'),
|
||||
);
|
||||
}
|
||||
return null;
|
||||
|
||||
+13
-1
@@ -24,6 +24,7 @@ class SharedLinkResponseDto {
|
||||
required this.key,
|
||||
required this.password,
|
||||
required this.showMetadata,
|
||||
required this.slug,
|
||||
this.token,
|
||||
required this.type,
|
||||
required this.userId,
|
||||
@@ -57,6 +58,8 @@ class SharedLinkResponseDto {
|
||||
|
||||
bool showMetadata;
|
||||
|
||||
String? slug;
|
||||
|
||||
String? token;
|
||||
|
||||
SharedLinkType type;
|
||||
@@ -76,6 +79,7 @@ class SharedLinkResponseDto {
|
||||
other.key == key &&
|
||||
other.password == password &&
|
||||
other.showMetadata == showMetadata &&
|
||||
other.slug == slug &&
|
||||
other.token == token &&
|
||||
other.type == type &&
|
||||
other.userId == userId;
|
||||
@@ -94,12 +98,13 @@ class SharedLinkResponseDto {
|
||||
(key.hashCode) +
|
||||
(password == null ? 0 : password!.hashCode) +
|
||||
(showMetadata.hashCode) +
|
||||
(slug == null ? 0 : slug!.hashCode) +
|
||||
(token == null ? 0 : token!.hashCode) +
|
||||
(type.hashCode) +
|
||||
(userId.hashCode);
|
||||
|
||||
@override
|
||||
String toString() => 'SharedLinkResponseDto[album=$album, allowDownload=$allowDownload, allowUpload=$allowUpload, assets=$assets, createdAt=$createdAt, description=$description, expiresAt=$expiresAt, id=$id, key=$key, password=$password, showMetadata=$showMetadata, token=$token, type=$type, userId=$userId]';
|
||||
String toString() => 'SharedLinkResponseDto[album=$album, allowDownload=$allowDownload, allowUpload=$allowUpload, assets=$assets, createdAt=$createdAt, description=$description, expiresAt=$expiresAt, id=$id, key=$key, password=$password, showMetadata=$showMetadata, slug=$slug, token=$token, type=$type, userId=$userId]';
|
||||
|
||||
Map<String, dynamic> toJson() {
|
||||
final json = <String, dynamic>{};
|
||||
@@ -130,6 +135,11 @@ class SharedLinkResponseDto {
|
||||
// json[r'password'] = null;
|
||||
}
|
||||
json[r'showMetadata'] = this.showMetadata;
|
||||
if (this.slug != null) {
|
||||
json[r'slug'] = this.slug;
|
||||
} else {
|
||||
// json[r'slug'] = null;
|
||||
}
|
||||
if (this.token != null) {
|
||||
json[r'token'] = this.token;
|
||||
} else {
|
||||
@@ -160,6 +170,7 @@ class SharedLinkResponseDto {
|
||||
key: mapValueOfType<String>(json, r'key')!,
|
||||
password: mapValueOfType<String>(json, r'password'),
|
||||
showMetadata: mapValueOfType<bool>(json, r'showMetadata')!,
|
||||
slug: mapValueOfType<String>(json, r'slug'),
|
||||
token: mapValueOfType<String>(json, r'token'),
|
||||
type: SharedLinkType.fromJson(json[r'type'])!,
|
||||
userId: mapValueOfType<String>(json, r'userId')!,
|
||||
@@ -220,6 +231,7 @@ class SharedLinkResponseDto {
|
||||
'key',
|
||||
'password',
|
||||
'showMetadata',
|
||||
'slug',
|
||||
'type',
|
||||
'userId',
|
||||
};
|
||||
|
||||
+32
-6
@@ -31,7 +31,8 @@ class SmartSearchDto {
|
||||
this.model,
|
||||
this.page,
|
||||
this.personIds = const [],
|
||||
required this.query,
|
||||
this.query,
|
||||
this.queryAssetId,
|
||||
this.rating,
|
||||
this.size,
|
||||
this.state,
|
||||
@@ -151,7 +152,21 @@ class SmartSearchDto {
|
||||
|
||||
List<String> personIds;
|
||||
|
||||
String query;
|
||||
///
|
||||
/// Please note: This property should have been non-nullable! Since the specification file
|
||||
/// does not include a default value (using the "default:" property), however, the generated
|
||||
/// source code must fall back to having a nullable type.
|
||||
/// Consider adding a "default:" property in the specification file to hide this note.
|
||||
///
|
||||
String? query;
|
||||
|
||||
///
|
||||
/// Please note: This property should have been non-nullable! Since the specification file
|
||||
/// does not include a default value (using the "default:" property), however, the generated
|
||||
/// source code must fall back to having a nullable type.
|
||||
/// Consider adding a "default:" property in the specification file to hide this note.
|
||||
///
|
||||
String? queryAssetId;
|
||||
|
||||
/// Minimum value: -1
|
||||
/// Maximum value: 5
|
||||
@@ -278,6 +293,7 @@ class SmartSearchDto {
|
||||
other.page == page &&
|
||||
_deepEquality.equals(other.personIds, personIds) &&
|
||||
other.query == query &&
|
||||
other.queryAssetId == queryAssetId &&
|
||||
other.rating == rating &&
|
||||
other.size == size &&
|
||||
other.state == state &&
|
||||
@@ -314,7 +330,8 @@ class SmartSearchDto {
|
||||
(model == null ? 0 : model!.hashCode) +
|
||||
(page == null ? 0 : page!.hashCode) +
|
||||
(personIds.hashCode) +
|
||||
(query.hashCode) +
|
||||
(query == null ? 0 : query!.hashCode) +
|
||||
(queryAssetId == null ? 0 : queryAssetId!.hashCode) +
|
||||
(rating == null ? 0 : rating!.hashCode) +
|
||||
(size == null ? 0 : size!.hashCode) +
|
||||
(state == null ? 0 : state!.hashCode) +
|
||||
@@ -331,7 +348,7 @@ class SmartSearchDto {
|
||||
(withExif == null ? 0 : withExif!.hashCode);
|
||||
|
||||
@override
|
||||
String toString() => 'SmartSearchDto[albumIds=$albumIds, city=$city, country=$country, createdAfter=$createdAfter, createdBefore=$createdBefore, deviceId=$deviceId, isEncoded=$isEncoded, isFavorite=$isFavorite, isMotion=$isMotion, isNotInAlbum=$isNotInAlbum, isOffline=$isOffline, language=$language, lensModel=$lensModel, libraryId=$libraryId, make=$make, model=$model, page=$page, personIds=$personIds, query=$query, rating=$rating, size=$size, state=$state, tagIds=$tagIds, takenAfter=$takenAfter, takenBefore=$takenBefore, trashedAfter=$trashedAfter, trashedBefore=$trashedBefore, type=$type, updatedAfter=$updatedAfter, updatedBefore=$updatedBefore, visibility=$visibility, withDeleted=$withDeleted, withExif=$withExif]';
|
||||
String toString() => 'SmartSearchDto[albumIds=$albumIds, city=$city, country=$country, createdAfter=$createdAfter, createdBefore=$createdBefore, deviceId=$deviceId, isEncoded=$isEncoded, isFavorite=$isFavorite, isMotion=$isMotion, isNotInAlbum=$isNotInAlbum, isOffline=$isOffline, language=$language, lensModel=$lensModel, libraryId=$libraryId, make=$make, model=$model, page=$page, personIds=$personIds, query=$query, queryAssetId=$queryAssetId, rating=$rating, size=$size, state=$state, tagIds=$tagIds, takenAfter=$takenAfter, takenBefore=$takenBefore, trashedAfter=$trashedAfter, trashedBefore=$trashedBefore, type=$type, updatedAfter=$updatedAfter, updatedBefore=$updatedBefore, visibility=$visibility, withDeleted=$withDeleted, withExif=$withExif]';
|
||||
|
||||
Map<String, dynamic> toJson() {
|
||||
final json = <String, dynamic>{};
|
||||
@@ -417,7 +434,16 @@ class SmartSearchDto {
|
||||
// json[r'page'] = null;
|
||||
}
|
||||
json[r'personIds'] = this.personIds;
|
||||
if (this.query != null) {
|
||||
json[r'query'] = this.query;
|
||||
} else {
|
||||
// json[r'query'] = null;
|
||||
}
|
||||
if (this.queryAssetId != null) {
|
||||
json[r'queryAssetId'] = this.queryAssetId;
|
||||
} else {
|
||||
// json[r'queryAssetId'] = null;
|
||||
}
|
||||
if (this.rating != null) {
|
||||
json[r'rating'] = this.rating;
|
||||
} else {
|
||||
@@ -522,7 +548,8 @@ class SmartSearchDto {
|
||||
personIds: json[r'personIds'] is Iterable
|
||||
? (json[r'personIds'] as Iterable).cast<String>().toList(growable: false)
|
||||
: const [],
|
||||
query: mapValueOfType<String>(json, r'query')!,
|
||||
query: mapValueOfType<String>(json, r'query'),
|
||||
queryAssetId: mapValueOfType<String>(json, r'queryAssetId'),
|
||||
rating: num.parse('${json[r'rating']}'),
|
||||
size: num.parse('${json[r'size']}'),
|
||||
state: mapValueOfType<String>(json, r'state'),
|
||||
@@ -586,7 +613,6 @@ class SmartSearchDto {
|
||||
|
||||
/// The list of required keys that must be present in a JSON.
|
||||
static const requiredKeys = <String>{
|
||||
'query',
|
||||
};
|
||||
}
|
||||
|
||||
|
||||
+12
-12
@@ -27,19 +27,19 @@ class SyncAssetFaceV1 {
|
||||
|
||||
String assetId;
|
||||
|
||||
num boundingBoxX1;
|
||||
int boundingBoxX1;
|
||||
|
||||
num boundingBoxX2;
|
||||
int boundingBoxX2;
|
||||
|
||||
num boundingBoxY1;
|
||||
int boundingBoxY1;
|
||||
|
||||
num boundingBoxY2;
|
||||
int boundingBoxY2;
|
||||
|
||||
String id;
|
||||
|
||||
num imageHeight;
|
||||
int imageHeight;
|
||||
|
||||
num imageWidth;
|
||||
int imageWidth;
|
||||
|
||||
String? personId;
|
||||
|
||||
@@ -104,13 +104,13 @@ class SyncAssetFaceV1 {
|
||||
|
||||
return SyncAssetFaceV1(
|
||||
assetId: mapValueOfType<String>(json, r'assetId')!,
|
||||
boundingBoxX1: num.parse('${json[r'boundingBoxX1']}'),
|
||||
boundingBoxX2: num.parse('${json[r'boundingBoxX2']}'),
|
||||
boundingBoxY1: num.parse('${json[r'boundingBoxY1']}'),
|
||||
boundingBoxY2: num.parse('${json[r'boundingBoxY2']}'),
|
||||
boundingBoxX1: mapValueOfType<int>(json, r'boundingBoxX1')!,
|
||||
boundingBoxX2: mapValueOfType<int>(json, r'boundingBoxX2')!,
|
||||
boundingBoxY1: mapValueOfType<int>(json, r'boundingBoxY1')!,
|
||||
boundingBoxY2: mapValueOfType<int>(json, r'boundingBoxY2')!,
|
||||
id: mapValueOfType<String>(json, r'id')!,
|
||||
imageHeight: num.parse('${json[r'imageHeight']}'),
|
||||
imageWidth: num.parse('${json[r'imageWidth']}'),
|
||||
imageHeight: mapValueOfType<int>(json, r'imageHeight')!,
|
||||
imageWidth: mapValueOfType<int>(json, r'imageWidth')!,
|
||||
personId: mapValueOfType<String>(json, r'personId'),
|
||||
sourceType: mapValueOfType<String>(json, r'sourceType')!,
|
||||
);
|
||||
|
||||
@@ -0,0 +1,107 @@
|
||||
//
|
||||
// AUTO-GENERATED FILE, DO NOT MODIFY!
|
||||
//
|
||||
// @dart=2.18
|
||||
|
||||
// ignore_for_file: unused_element, unused_import
|
||||
// ignore_for_file: always_put_required_named_parameters_first
|
||||
// ignore_for_file: constant_identifier_names
|
||||
// ignore_for_file: lines_longer_than_80_chars
|
||||
|
||||
part of openapi.api;
|
||||
|
||||
class SyncAssetMetadataDeleteV1 {
|
||||
/// Returns a new [SyncAssetMetadataDeleteV1] instance.
|
||||
SyncAssetMetadataDeleteV1({
|
||||
required this.assetId,
|
||||
required this.key,
|
||||
});
|
||||
|
||||
String assetId;
|
||||
|
||||
AssetMetadataKey key;
|
||||
|
||||
@override
|
||||
bool operator ==(Object other) => identical(this, other) || other is SyncAssetMetadataDeleteV1 &&
|
||||
other.assetId == assetId &&
|
||||
other.key == key;
|
||||
|
||||
@override
|
||||
int get hashCode =>
|
||||
// ignore: unnecessary_parenthesis
|
||||
(assetId.hashCode) +
|
||||
(key.hashCode);
|
||||
|
||||
@override
|
||||
String toString() => 'SyncAssetMetadataDeleteV1[assetId=$assetId, key=$key]';
|
||||
|
||||
Map<String, dynamic> toJson() {
|
||||
final json = <String, dynamic>{};
|
||||
json[r'assetId'] = this.assetId;
|
||||
json[r'key'] = this.key;
|
||||
return json;
|
||||
}
|
||||
|
||||
/// Returns a new [SyncAssetMetadataDeleteV1] instance and imports its values from
|
||||
/// [value] if it's a [Map], null otherwise.
|
||||
// ignore: prefer_constructors_over_static_methods
|
||||
static SyncAssetMetadataDeleteV1? fromJson(dynamic value) {
|
||||
upgradeDto(value, "SyncAssetMetadataDeleteV1");
|
||||
if (value is Map) {
|
||||
final json = value.cast<String, dynamic>();
|
||||
|
||||
return SyncAssetMetadataDeleteV1(
|
||||
assetId: mapValueOfType<String>(json, r'assetId')!,
|
||||
key: AssetMetadataKey.fromJson(json[r'key'])!,
|
||||
);
|
||||
}
|
||||
return null;
|
||||
}
|
||||
|
||||
static List<SyncAssetMetadataDeleteV1> listFromJson(dynamic json, {bool growable = false,}) {
|
||||
final result = <SyncAssetMetadataDeleteV1>[];
|
||||
if (json is List && json.isNotEmpty) {
|
||||
for (final row in json) {
|
||||
final value = SyncAssetMetadataDeleteV1.fromJson(row);
|
||||
if (value != null) {
|
||||
result.add(value);
|
||||
}
|
||||
}
|
||||
}
|
||||
return result.toList(growable: growable);
|
||||
}
|
||||
|
||||
static Map<String, SyncAssetMetadataDeleteV1> mapFromJson(dynamic json) {
|
||||
final map = <String, SyncAssetMetadataDeleteV1>{};
|
||||
if (json is Map && json.isNotEmpty) {
|
||||
json = json.cast<String, dynamic>(); // ignore: parameter_assignments
|
||||
for (final entry in json.entries) {
|
||||
final value = SyncAssetMetadataDeleteV1.fromJson(entry.value);
|
||||
if (value != null) {
|
||||
map[entry.key] = value;
|
||||
}
|
||||
}
|
||||
}
|
||||
return map;
|
||||
}
|
||||
|
||||
// maps a json object with a list of SyncAssetMetadataDeleteV1-objects as value to a dart map
|
||||
static Map<String, List<SyncAssetMetadataDeleteV1>> mapListFromJson(dynamic json, {bool growable = false,}) {
|
||||
final map = <String, List<SyncAssetMetadataDeleteV1>>{};
|
||||
if (json is Map && json.isNotEmpty) {
|
||||
// ignore: parameter_assignments
|
||||
json = json.cast<String, dynamic>();
|
||||
for (final entry in json.entries) {
|
||||
map[entry.key] = SyncAssetMetadataDeleteV1.listFromJson(entry.value, growable: growable,);
|
||||
}
|
||||
}
|
||||
return map;
|
||||
}
|
||||
|
||||
/// The list of required keys that must be present in a JSON.
|
||||
static const requiredKeys = <String>{
|
||||
'assetId',
|
||||
'key',
|
||||
};
|
||||
}
|
||||
|
||||
+115
@@ -0,0 +1,115 @@
|
||||
//
|
||||
// AUTO-GENERATED FILE, DO NOT MODIFY!
|
||||
//
|
||||
// @dart=2.18
|
||||
|
||||
// ignore_for_file: unused_element, unused_import
|
||||
// ignore_for_file: always_put_required_named_parameters_first
|
||||
// ignore_for_file: constant_identifier_names
|
||||
// ignore_for_file: lines_longer_than_80_chars
|
||||
|
||||
part of openapi.api;
|
||||
|
||||
class SyncAssetMetadataV1 {
|
||||
/// Returns a new [SyncAssetMetadataV1] instance.
|
||||
SyncAssetMetadataV1({
|
||||
required this.assetId,
|
||||
required this.key,
|
||||
required this.value,
|
||||
});
|
||||
|
||||
String assetId;
|
||||
|
||||
AssetMetadataKey key;
|
||||
|
||||
Object value;
|
||||
|
||||
@override
|
||||
bool operator ==(Object other) => identical(this, other) || other is SyncAssetMetadataV1 &&
|
||||
other.assetId == assetId &&
|
||||
other.key == key &&
|
||||
other.value == value;
|
||||
|
||||
@override
|
||||
int get hashCode =>
|
||||
// ignore: unnecessary_parenthesis
|
||||
(assetId.hashCode) +
|
||||
(key.hashCode) +
|
||||
(value.hashCode);
|
||||
|
||||
@override
|
||||
String toString() => 'SyncAssetMetadataV1[assetId=$assetId, key=$key, value=$value]';
|
||||
|
||||
Map<String, dynamic> toJson() {
|
||||
final json = <String, dynamic>{};
|
||||
json[r'assetId'] = this.assetId;
|
||||
json[r'key'] = this.key;
|
||||
json[r'value'] = this.value;
|
||||
return json;
|
||||
}
|
||||
|
||||
/// Returns a new [SyncAssetMetadataV1] instance and imports its values from
|
||||
/// [value] if it's a [Map], null otherwise.
|
||||
// ignore: prefer_constructors_over_static_methods
|
||||
static SyncAssetMetadataV1? fromJson(dynamic value) {
|
||||
upgradeDto(value, "SyncAssetMetadataV1");
|
||||
if (value is Map) {
|
||||
final json = value.cast<String, dynamic>();
|
||||
|
||||
return SyncAssetMetadataV1(
|
||||
assetId: mapValueOfType<String>(json, r'assetId')!,
|
||||
key: AssetMetadataKey.fromJson(json[r'key'])!,
|
||||
value: mapValueOfType<Object>(json, r'value')!,
|
||||
);
|
||||
}
|
||||
return null;
|
||||
}
|
||||
|
||||
static List<SyncAssetMetadataV1> listFromJson(dynamic json, {bool growable = false,}) {
|
||||
final result = <SyncAssetMetadataV1>[];
|
||||
if (json is List && json.isNotEmpty) {
|
||||
for (final row in json) {
|
||||
final value = SyncAssetMetadataV1.fromJson(row);
|
||||
if (value != null) {
|
||||
result.add(value);
|
||||
}
|
||||
}
|
||||
}
|
||||
return result.toList(growable: growable);
|
||||
}
|
||||
|
||||
static Map<String, SyncAssetMetadataV1> mapFromJson(dynamic json) {
|
||||
final map = <String, SyncAssetMetadataV1>{};
|
||||
if (json is Map && json.isNotEmpty) {
|
||||
json = json.cast<String, dynamic>(); // ignore: parameter_assignments
|
||||
for (final entry in json.entries) {
|
||||
final value = SyncAssetMetadataV1.fromJson(entry.value);
|
||||
if (value != null) {
|
||||
map[entry.key] = value;
|
||||
}
|
||||
}
|
||||
}
|
||||
return map;
|
||||
}
|
||||
|
||||
// maps a json object with a list of SyncAssetMetadataV1-objects as value to a dart map
|
||||
static Map<String, List<SyncAssetMetadataV1>> mapListFromJson(dynamic json, {bool growable = false,}) {
|
||||
final map = <String, List<SyncAssetMetadataV1>>{};
|
||||
if (json is Map && json.isNotEmpty) {
|
||||
// ignore: parameter_assignments
|
||||
json = json.cast<String, dynamic>();
|
||||
for (final entry in json.entries) {
|
||||
map[entry.key] = SyncAssetMetadataV1.listFromJson(entry.value, growable: growable,);
|
||||
}
|
||||
}
|
||||
return map;
|
||||
}
|
||||
|
||||
/// The list of required keys that must be present in a JSON.
|
||||
static const requiredKeys = <String>{
|
||||
'assetId',
|
||||
'key',
|
||||
'value',
|
||||
};
|
||||
}
|
||||
|
||||
+13
-1
@@ -20,6 +20,7 @@ class SyncAssetV1 {
|
||||
required this.fileModifiedAt,
|
||||
required this.id,
|
||||
required this.isFavorite,
|
||||
required this.libraryId,
|
||||
required this.livePhotoVideoId,
|
||||
required this.localDateTime,
|
||||
required this.originalFileName,
|
||||
@@ -44,6 +45,8 @@ class SyncAssetV1 {
|
||||
|
||||
bool isFavorite;
|
||||
|
||||
String? libraryId;
|
||||
|
||||
String? livePhotoVideoId;
|
||||
|
||||
DateTime? localDateTime;
|
||||
@@ -69,6 +72,7 @@ class SyncAssetV1 {
|
||||
other.fileModifiedAt == fileModifiedAt &&
|
||||
other.id == id &&
|
||||
other.isFavorite == isFavorite &&
|
||||
other.libraryId == libraryId &&
|
||||
other.livePhotoVideoId == livePhotoVideoId &&
|
||||
other.localDateTime == localDateTime &&
|
||||
other.originalFileName == originalFileName &&
|
||||
@@ -88,6 +92,7 @@ class SyncAssetV1 {
|
||||
(fileModifiedAt == null ? 0 : fileModifiedAt!.hashCode) +
|
||||
(id.hashCode) +
|
||||
(isFavorite.hashCode) +
|
||||
(libraryId == null ? 0 : libraryId!.hashCode) +
|
||||
(livePhotoVideoId == null ? 0 : livePhotoVideoId!.hashCode) +
|
||||
(localDateTime == null ? 0 : localDateTime!.hashCode) +
|
||||
(originalFileName.hashCode) +
|
||||
@@ -98,7 +103,7 @@ class SyncAssetV1 {
|
||||
(visibility.hashCode);
|
||||
|
||||
@override
|
||||
String toString() => 'SyncAssetV1[checksum=$checksum, deletedAt=$deletedAt, duration=$duration, fileCreatedAt=$fileCreatedAt, fileModifiedAt=$fileModifiedAt, id=$id, isFavorite=$isFavorite, livePhotoVideoId=$livePhotoVideoId, localDateTime=$localDateTime, originalFileName=$originalFileName, ownerId=$ownerId, stackId=$stackId, thumbhash=$thumbhash, type=$type, visibility=$visibility]';
|
||||
String toString() => 'SyncAssetV1[checksum=$checksum, deletedAt=$deletedAt, duration=$duration, fileCreatedAt=$fileCreatedAt, fileModifiedAt=$fileModifiedAt, id=$id, isFavorite=$isFavorite, libraryId=$libraryId, livePhotoVideoId=$livePhotoVideoId, localDateTime=$localDateTime, originalFileName=$originalFileName, ownerId=$ownerId, stackId=$stackId, thumbhash=$thumbhash, type=$type, visibility=$visibility]';
|
||||
|
||||
Map<String, dynamic> toJson() {
|
||||
final json = <String, dynamic>{};
|
||||
@@ -125,6 +130,11 @@ class SyncAssetV1 {
|
||||
}
|
||||
json[r'id'] = this.id;
|
||||
json[r'isFavorite'] = this.isFavorite;
|
||||
if (this.libraryId != null) {
|
||||
json[r'libraryId'] = this.libraryId;
|
||||
} else {
|
||||
// json[r'libraryId'] = null;
|
||||
}
|
||||
if (this.livePhotoVideoId != null) {
|
||||
json[r'livePhotoVideoId'] = this.livePhotoVideoId;
|
||||
} else {
|
||||
@@ -168,6 +178,7 @@ class SyncAssetV1 {
|
||||
fileModifiedAt: mapDateTime(json, r'fileModifiedAt', r''),
|
||||
id: mapValueOfType<String>(json, r'id')!,
|
||||
isFavorite: mapValueOfType<bool>(json, r'isFavorite')!,
|
||||
libraryId: mapValueOfType<String>(json, r'libraryId'),
|
||||
livePhotoVideoId: mapValueOfType<String>(json, r'livePhotoVideoId'),
|
||||
localDateTime: mapDateTime(json, r'localDateTime', r''),
|
||||
originalFileName: mapValueOfType<String>(json, r'originalFileName')!,
|
||||
@@ -230,6 +241,7 @@ class SyncAssetV1 {
|
||||
'fileModifiedAt',
|
||||
'id',
|
||||
'isFavorite',
|
||||
'libraryId',
|
||||
'livePhotoVideoId',
|
||||
'localDateTime',
|
||||
'originalFileName',
|
||||
|
||||
+215
@@ -0,0 +1,215 @@
|
||||
//
|
||||
// AUTO-GENERATED FILE, DO NOT MODIFY!
|
||||
//
|
||||
// @dart=2.18
|
||||
|
||||
// ignore_for_file: unused_element, unused_import
|
||||
// ignore_for_file: always_put_required_named_parameters_first
|
||||
// ignore_for_file: constant_identifier_names
|
||||
// ignore_for_file: lines_longer_than_80_chars
|
||||
|
||||
part of openapi.api;
|
||||
|
||||
class SyncAuthUserV1 {
|
||||
/// Returns a new [SyncAuthUserV1] instance.
|
||||
SyncAuthUserV1({
|
||||
required this.avatarColor,
|
||||
required this.deletedAt,
|
||||
required this.email,
|
||||
required this.hasProfileImage,
|
||||
required this.id,
|
||||
required this.isAdmin,
|
||||
required this.name,
|
||||
required this.oauthId,
|
||||
required this.pinCode,
|
||||
required this.profileChangedAt,
|
||||
required this.quotaSizeInBytes,
|
||||
required this.quotaUsageInBytes,
|
||||
required this.storageLabel,
|
||||
});
|
||||
|
||||
UserAvatarColor? avatarColor;
|
||||
|
||||
DateTime? deletedAt;
|
||||
|
||||
String email;
|
||||
|
||||
bool hasProfileImage;
|
||||
|
||||
String id;
|
||||
|
||||
bool isAdmin;
|
||||
|
||||
String name;
|
||||
|
||||
String oauthId;
|
||||
|
||||
String? pinCode;
|
||||
|
||||
DateTime profileChangedAt;
|
||||
|
||||
int? quotaSizeInBytes;
|
||||
|
||||
int quotaUsageInBytes;
|
||||
|
||||
String? storageLabel;
|
||||
|
||||
@override
|
||||
bool operator ==(Object other) => identical(this, other) || other is SyncAuthUserV1 &&
|
||||
other.avatarColor == avatarColor &&
|
||||
other.deletedAt == deletedAt &&
|
||||
other.email == email &&
|
||||
other.hasProfileImage == hasProfileImage &&
|
||||
other.id == id &&
|
||||
other.isAdmin == isAdmin &&
|
||||
other.name == name &&
|
||||
other.oauthId == oauthId &&
|
||||
other.pinCode == pinCode &&
|
||||
other.profileChangedAt == profileChangedAt &&
|
||||
other.quotaSizeInBytes == quotaSizeInBytes &&
|
||||
other.quotaUsageInBytes == quotaUsageInBytes &&
|
||||
other.storageLabel == storageLabel;
|
||||
|
||||
@override
|
||||
int get hashCode =>
|
||||
// ignore: unnecessary_parenthesis
|
||||
(avatarColor == null ? 0 : avatarColor!.hashCode) +
|
||||
(deletedAt == null ? 0 : deletedAt!.hashCode) +
|
||||
(email.hashCode) +
|
||||
(hasProfileImage.hashCode) +
|
||||
(id.hashCode) +
|
||||
(isAdmin.hashCode) +
|
||||
(name.hashCode) +
|
||||
(oauthId.hashCode) +
|
||||
(pinCode == null ? 0 : pinCode!.hashCode) +
|
||||
(profileChangedAt.hashCode) +
|
||||
(quotaSizeInBytes == null ? 0 : quotaSizeInBytes!.hashCode) +
|
||||
(quotaUsageInBytes.hashCode) +
|
||||
(storageLabel == null ? 0 : storageLabel!.hashCode);
|
||||
|
||||
@override
|
||||
String toString() => 'SyncAuthUserV1[avatarColor=$avatarColor, deletedAt=$deletedAt, email=$email, hasProfileImage=$hasProfileImage, id=$id, isAdmin=$isAdmin, name=$name, oauthId=$oauthId, pinCode=$pinCode, profileChangedAt=$profileChangedAt, quotaSizeInBytes=$quotaSizeInBytes, quotaUsageInBytes=$quotaUsageInBytes, storageLabel=$storageLabel]';
|
||||
|
||||
Map<String, dynamic> toJson() {
|
||||
final json = <String, dynamic>{};
|
||||
if (this.avatarColor != null) {
|
||||
json[r'avatarColor'] = this.avatarColor;
|
||||
} else {
|
||||
// json[r'avatarColor'] = null;
|
||||
}
|
||||
if (this.deletedAt != null) {
|
||||
json[r'deletedAt'] = this.deletedAt!.toUtc().toIso8601String();
|
||||
} else {
|
||||
// json[r'deletedAt'] = null;
|
||||
}
|
||||
json[r'email'] = this.email;
|
||||
json[r'hasProfileImage'] = this.hasProfileImage;
|
||||
json[r'id'] = this.id;
|
||||
json[r'isAdmin'] = this.isAdmin;
|
||||
json[r'name'] = this.name;
|
||||
json[r'oauthId'] = this.oauthId;
|
||||
if (this.pinCode != null) {
|
||||
json[r'pinCode'] = this.pinCode;
|
||||
} else {
|
||||
// json[r'pinCode'] = null;
|
||||
}
|
||||
json[r'profileChangedAt'] = this.profileChangedAt.toUtc().toIso8601String();
|
||||
if (this.quotaSizeInBytes != null) {
|
||||
json[r'quotaSizeInBytes'] = this.quotaSizeInBytes;
|
||||
} else {
|
||||
// json[r'quotaSizeInBytes'] = null;
|
||||
}
|
||||
json[r'quotaUsageInBytes'] = this.quotaUsageInBytes;
|
||||
if (this.storageLabel != null) {
|
||||
json[r'storageLabel'] = this.storageLabel;
|
||||
} else {
|
||||
// json[r'storageLabel'] = null;
|
||||
}
|
||||
return json;
|
||||
}
|
||||
|
||||
/// Returns a new [SyncAuthUserV1] instance and imports its values from
|
||||
/// [value] if it's a [Map], null otherwise.
|
||||
// ignore: prefer_constructors_over_static_methods
|
||||
static SyncAuthUserV1? fromJson(dynamic value) {
|
||||
upgradeDto(value, "SyncAuthUserV1");
|
||||
if (value is Map) {
|
||||
final json = value.cast<String, dynamic>();
|
||||
|
||||
return SyncAuthUserV1(
|
||||
avatarColor: UserAvatarColor.fromJson(json[r'avatarColor']),
|
||||
deletedAt: mapDateTime(json, r'deletedAt', r''),
|
||||
email: mapValueOfType<String>(json, r'email')!,
|
||||
hasProfileImage: mapValueOfType<bool>(json, r'hasProfileImage')!,
|
||||
id: mapValueOfType<String>(json, r'id')!,
|
||||
isAdmin: mapValueOfType<bool>(json, r'isAdmin')!,
|
||||
name: mapValueOfType<String>(json, r'name')!,
|
||||
oauthId: mapValueOfType<String>(json, r'oauthId')!,
|
||||
pinCode: mapValueOfType<String>(json, r'pinCode'),
|
||||
profileChangedAt: mapDateTime(json, r'profileChangedAt', r'')!,
|
||||
quotaSizeInBytes: mapValueOfType<int>(json, r'quotaSizeInBytes'),
|
||||
quotaUsageInBytes: mapValueOfType<int>(json, r'quotaUsageInBytes')!,
|
||||
storageLabel: mapValueOfType<String>(json, r'storageLabel'),
|
||||
);
|
||||
}
|
||||
return null;
|
||||
}
|
||||
|
||||
static List<SyncAuthUserV1> listFromJson(dynamic json, {bool growable = false,}) {
|
||||
final result = <SyncAuthUserV1>[];
|
||||
if (json is List && json.isNotEmpty) {
|
||||
for (final row in json) {
|
||||
final value = SyncAuthUserV1.fromJson(row);
|
||||
if (value != null) {
|
||||
result.add(value);
|
||||
}
|
||||
}
|
||||
}
|
||||
return result.toList(growable: growable);
|
||||
}
|
||||
|
||||
static Map<String, SyncAuthUserV1> mapFromJson(dynamic json) {
|
||||
final map = <String, SyncAuthUserV1>{};
|
||||
if (json is Map && json.isNotEmpty) {
|
||||
json = json.cast<String, dynamic>(); // ignore: parameter_assignments
|
||||
for (final entry in json.entries) {
|
||||
final value = SyncAuthUserV1.fromJson(entry.value);
|
||||
if (value != null) {
|
||||
map[entry.key] = value;
|
||||
}
|
||||
}
|
||||
}
|
||||
return map;
|
||||
}
|
||||
|
||||
// maps a json object with a list of SyncAuthUserV1-objects as value to a dart map
|
||||
static Map<String, List<SyncAuthUserV1>> mapListFromJson(dynamic json, {bool growable = false,}) {
|
||||
final map = <String, List<SyncAuthUserV1>>{};
|
||||
if (json is Map && json.isNotEmpty) {
|
||||
// ignore: parameter_assignments
|
||||
json = json.cast<String, dynamic>();
|
||||
for (final entry in json.entries) {
|
||||
map[entry.key] = SyncAuthUserV1.listFromJson(entry.value, growable: growable,);
|
||||
}
|
||||
}
|
||||
return map;
|
||||
}
|
||||
|
||||
/// The list of required keys that must be present in a JSON.
|
||||
static const requiredKeys = <String>{
|
||||
'avatarColor',
|
||||
'deletedAt',
|
||||
'email',
|
||||
'hasProfileImage',
|
||||
'id',
|
||||
'isAdmin',
|
||||
'name',
|
||||
'oauthId',
|
||||
'pinCode',
|
||||
'profileChangedAt',
|
||||
'quotaSizeInBytes',
|
||||
'quotaUsageInBytes',
|
||||
'storageLabel',
|
||||
};
|
||||
}
|
||||
|
||||
+24
-6
@@ -23,11 +23,14 @@ class SyncEntityType {
|
||||
|
||||
String toJson() => value;
|
||||
|
||||
static const authUserV1 = SyncEntityType._(r'AuthUserV1');
|
||||
static const userV1 = SyncEntityType._(r'UserV1');
|
||||
static const userDeleteV1 = SyncEntityType._(r'UserDeleteV1');
|
||||
static const assetV1 = SyncEntityType._(r'AssetV1');
|
||||
static const assetDeleteV1 = SyncEntityType._(r'AssetDeleteV1');
|
||||
static const assetExifV1 = SyncEntityType._(r'AssetExifV1');
|
||||
static const assetMetadataV1 = SyncEntityType._(r'AssetMetadataV1');
|
||||
static const assetMetadataDeleteV1 = SyncEntityType._(r'AssetMetadataDeleteV1');
|
||||
static const partnerV1 = SyncEntityType._(r'PartnerV1');
|
||||
static const partnerDeleteV1 = SyncEntityType._(r'PartnerDeleteV1');
|
||||
static const partnerAssetV1 = SyncEntityType._(r'PartnerAssetV1');
|
||||
@@ -43,9 +46,11 @@ class SyncEntityType {
|
||||
static const albumUserV1 = SyncEntityType._(r'AlbumUserV1');
|
||||
static const albumUserBackfillV1 = SyncEntityType._(r'AlbumUserBackfillV1');
|
||||
static const albumUserDeleteV1 = SyncEntityType._(r'AlbumUserDeleteV1');
|
||||
static const albumAssetV1 = SyncEntityType._(r'AlbumAssetV1');
|
||||
static const albumAssetCreateV1 = SyncEntityType._(r'AlbumAssetCreateV1');
|
||||
static const albumAssetUpdateV1 = SyncEntityType._(r'AlbumAssetUpdateV1');
|
||||
static const albumAssetBackfillV1 = SyncEntityType._(r'AlbumAssetBackfillV1');
|
||||
static const albumAssetExifV1 = SyncEntityType._(r'AlbumAssetExifV1');
|
||||
static const albumAssetExifCreateV1 = SyncEntityType._(r'AlbumAssetExifCreateV1');
|
||||
static const albumAssetExifUpdateV1 = SyncEntityType._(r'AlbumAssetExifUpdateV1');
|
||||
static const albumAssetExifBackfillV1 = SyncEntityType._(r'AlbumAssetExifBackfillV1');
|
||||
static const albumToAssetV1 = SyncEntityType._(r'AlbumToAssetV1');
|
||||
static const albumToAssetDeleteV1 = SyncEntityType._(r'AlbumToAssetDeleteV1');
|
||||
@@ -64,14 +69,18 @@ class SyncEntityType {
|
||||
static const userMetadataDeleteV1 = SyncEntityType._(r'UserMetadataDeleteV1');
|
||||
static const syncAckV1 = SyncEntityType._(r'SyncAckV1');
|
||||
static const syncResetV1 = SyncEntityType._(r'SyncResetV1');
|
||||
static const syncCompleteV1 = SyncEntityType._(r'SyncCompleteV1');
|
||||
|
||||
/// List of all possible values in this [enum][SyncEntityType].
|
||||
static const values = <SyncEntityType>[
|
||||
authUserV1,
|
||||
userV1,
|
||||
userDeleteV1,
|
||||
assetV1,
|
||||
assetDeleteV1,
|
||||
assetExifV1,
|
||||
assetMetadataV1,
|
||||
assetMetadataDeleteV1,
|
||||
partnerV1,
|
||||
partnerDeleteV1,
|
||||
partnerAssetV1,
|
||||
@@ -87,9 +96,11 @@ class SyncEntityType {
|
||||
albumUserV1,
|
||||
albumUserBackfillV1,
|
||||
albumUserDeleteV1,
|
||||
albumAssetV1,
|
||||
albumAssetCreateV1,
|
||||
albumAssetUpdateV1,
|
||||
albumAssetBackfillV1,
|
||||
albumAssetExifV1,
|
||||
albumAssetExifCreateV1,
|
||||
albumAssetExifUpdateV1,
|
||||
albumAssetExifBackfillV1,
|
||||
albumToAssetV1,
|
||||
albumToAssetDeleteV1,
|
||||
@@ -108,6 +119,7 @@ class SyncEntityType {
|
||||
userMetadataDeleteV1,
|
||||
syncAckV1,
|
||||
syncResetV1,
|
||||
syncCompleteV1,
|
||||
];
|
||||
|
||||
static SyncEntityType? fromJson(dynamic value) => SyncEntityTypeTypeTransformer().decode(value);
|
||||
@@ -146,11 +158,14 @@ class SyncEntityTypeTypeTransformer {
|
||||
SyncEntityType? decode(dynamic data, {bool allowNull = true}) {
|
||||
if (data != null) {
|
||||
switch (data) {
|
||||
case r'AuthUserV1': return SyncEntityType.authUserV1;
|
||||
case r'UserV1': return SyncEntityType.userV1;
|
||||
case r'UserDeleteV1': return SyncEntityType.userDeleteV1;
|
||||
case r'AssetV1': return SyncEntityType.assetV1;
|
||||
case r'AssetDeleteV1': return SyncEntityType.assetDeleteV1;
|
||||
case r'AssetExifV1': return SyncEntityType.assetExifV1;
|
||||
case r'AssetMetadataV1': return SyncEntityType.assetMetadataV1;
|
||||
case r'AssetMetadataDeleteV1': return SyncEntityType.assetMetadataDeleteV1;
|
||||
case r'PartnerV1': return SyncEntityType.partnerV1;
|
||||
case r'PartnerDeleteV1': return SyncEntityType.partnerDeleteV1;
|
||||
case r'PartnerAssetV1': return SyncEntityType.partnerAssetV1;
|
||||
@@ -166,9 +181,11 @@ class SyncEntityTypeTypeTransformer {
|
||||
case r'AlbumUserV1': return SyncEntityType.albumUserV1;
|
||||
case r'AlbumUserBackfillV1': return SyncEntityType.albumUserBackfillV1;
|
||||
case r'AlbumUserDeleteV1': return SyncEntityType.albumUserDeleteV1;
|
||||
case r'AlbumAssetV1': return SyncEntityType.albumAssetV1;
|
||||
case r'AlbumAssetCreateV1': return SyncEntityType.albumAssetCreateV1;
|
||||
case r'AlbumAssetUpdateV1': return SyncEntityType.albumAssetUpdateV1;
|
||||
case r'AlbumAssetBackfillV1': return SyncEntityType.albumAssetBackfillV1;
|
||||
case r'AlbumAssetExifV1': return SyncEntityType.albumAssetExifV1;
|
||||
case r'AlbumAssetExifCreateV1': return SyncEntityType.albumAssetExifCreateV1;
|
||||
case r'AlbumAssetExifUpdateV1': return SyncEntityType.albumAssetExifUpdateV1;
|
||||
case r'AlbumAssetExifBackfillV1': return SyncEntityType.albumAssetExifBackfillV1;
|
||||
case r'AlbumToAssetV1': return SyncEntityType.albumToAssetV1;
|
||||
case r'AlbumToAssetDeleteV1': return SyncEntityType.albumToAssetDeleteV1;
|
||||
@@ -187,6 +204,7 @@ class SyncEntityTypeTypeTransformer {
|
||||
case r'UserMetadataDeleteV1': return SyncEntityType.userMetadataDeleteV1;
|
||||
case r'SyncAckV1': return SyncEntityType.syncAckV1;
|
||||
case r'SyncResetV1': return SyncEntityType.syncResetV1;
|
||||
case r'SyncCompleteV1': return SyncEntityType.syncCompleteV1;
|
||||
default:
|
||||
if (!allowNull) {
|
||||
throw ArgumentError('Unknown enum value to decode: $data');
|
||||
|
||||
+6
@@ -30,6 +30,8 @@ class SyncRequestType {
|
||||
static const albumAssetExifsV1 = SyncRequestType._(r'AlbumAssetExifsV1');
|
||||
static const assetsV1 = SyncRequestType._(r'AssetsV1');
|
||||
static const assetExifsV1 = SyncRequestType._(r'AssetExifsV1');
|
||||
static const assetMetadataV1 = SyncRequestType._(r'AssetMetadataV1');
|
||||
static const authUsersV1 = SyncRequestType._(r'AuthUsersV1');
|
||||
static const memoriesV1 = SyncRequestType._(r'MemoriesV1');
|
||||
static const memoryToAssetsV1 = SyncRequestType._(r'MemoryToAssetsV1');
|
||||
static const partnersV1 = SyncRequestType._(r'PartnersV1');
|
||||
@@ -51,6 +53,8 @@ class SyncRequestType {
|
||||
albumAssetExifsV1,
|
||||
assetsV1,
|
||||
assetExifsV1,
|
||||
assetMetadataV1,
|
||||
authUsersV1,
|
||||
memoriesV1,
|
||||
memoryToAssetsV1,
|
||||
partnersV1,
|
||||
@@ -107,6 +111,8 @@ class SyncRequestTypeTypeTransformer {
|
||||
case r'AlbumAssetExifsV1': return SyncRequestType.albumAssetExifsV1;
|
||||
case r'AssetsV1': return SyncRequestType.assetsV1;
|
||||
case r'AssetExifsV1': return SyncRequestType.assetExifsV1;
|
||||
case r'AssetMetadataV1': return SyncRequestType.assetMetadataV1;
|
||||
case r'AuthUsersV1': return SyncRequestType.authUsersV1;
|
||||
case r'MemoriesV1': return SyncRequestType.memoriesV1;
|
||||
case r'MemoryToAssetsV1': return SyncRequestType.memoryToAssetsV1;
|
||||
case r'PartnersV1': return SyncRequestType.partnersV1;
|
||||
|
||||
+2
-2
@@ -17,7 +17,7 @@ class SyncUserMetadataDeleteV1 {
|
||||
required this.userId,
|
||||
});
|
||||
|
||||
String key;
|
||||
UserMetadataKey key;
|
||||
|
||||
String userId;
|
||||
|
||||
@@ -51,7 +51,7 @@ class SyncUserMetadataDeleteV1 {
|
||||
final json = value.cast<String, dynamic>();
|
||||
|
||||
return SyncUserMetadataDeleteV1(
|
||||
key: mapValueOfType<String>(json, r'key')!,
|
||||
key: UserMetadataKey.fromJson(json[r'key'])!,
|
||||
userId: mapValueOfType<String>(json, r'userId')!,
|
||||
);
|
||||
}
|
||||
|
||||
+2
-2
@@ -18,7 +18,7 @@ class SyncUserMetadataV1 {
|
||||
required this.value,
|
||||
});
|
||||
|
||||
String key;
|
||||
UserMetadataKey key;
|
||||
|
||||
String userId;
|
||||
|
||||
@@ -57,7 +57,7 @@ class SyncUserMetadataV1 {
|
||||
final json = value.cast<String, dynamic>();
|
||||
|
||||
return SyncUserMetadataV1(
|
||||
key: mapValueOfType<String>(json, r'key')!,
|
||||
key: UserMetadataKey.fromJson(json[r'key'])!,
|
||||
userId: mapValueOfType<String>(json, r'userId')!,
|
||||
value: mapValueOfType<Object>(json, r'value')!,
|
||||
);
|
||||
|
||||
+31
-3
@@ -13,48 +13,70 @@ part of openapi.api;
|
||||
class SyncUserV1 {
|
||||
/// Returns a new [SyncUserV1] instance.
|
||||
SyncUserV1({
|
||||
required this.avatarColor,
|
||||
required this.deletedAt,
|
||||
required this.email,
|
||||
required this.hasProfileImage,
|
||||
required this.id,
|
||||
required this.name,
|
||||
required this.profileChangedAt,
|
||||
});
|
||||
|
||||
UserAvatarColor? avatarColor;
|
||||
|
||||
DateTime? deletedAt;
|
||||
|
||||
String email;
|
||||
|
||||
bool hasProfileImage;
|
||||
|
||||
String id;
|
||||
|
||||
String name;
|
||||
|
||||
DateTime profileChangedAt;
|
||||
|
||||
@override
|
||||
bool operator ==(Object other) => identical(this, other) || other is SyncUserV1 &&
|
||||
other.avatarColor == avatarColor &&
|
||||
other.deletedAt == deletedAt &&
|
||||
other.email == email &&
|
||||
other.hasProfileImage == hasProfileImage &&
|
||||
other.id == id &&
|
||||
other.name == name;
|
||||
other.name == name &&
|
||||
other.profileChangedAt == profileChangedAt;
|
||||
|
||||
@override
|
||||
int get hashCode =>
|
||||
// ignore: unnecessary_parenthesis
|
||||
(avatarColor == null ? 0 : avatarColor!.hashCode) +
|
||||
(deletedAt == null ? 0 : deletedAt!.hashCode) +
|
||||
(email.hashCode) +
|
||||
(hasProfileImage.hashCode) +
|
||||
(id.hashCode) +
|
||||
(name.hashCode);
|
||||
(name.hashCode) +
|
||||
(profileChangedAt.hashCode);
|
||||
|
||||
@override
|
||||
String toString() => 'SyncUserV1[deletedAt=$deletedAt, email=$email, id=$id, name=$name]';
|
||||
String toString() => 'SyncUserV1[avatarColor=$avatarColor, deletedAt=$deletedAt, email=$email, hasProfileImage=$hasProfileImage, id=$id, name=$name, profileChangedAt=$profileChangedAt]';
|
||||
|
||||
Map<String, dynamic> toJson() {
|
||||
final json = <String, dynamic>{};
|
||||
if (this.avatarColor != null) {
|
||||
json[r'avatarColor'] = this.avatarColor;
|
||||
} else {
|
||||
// json[r'avatarColor'] = null;
|
||||
}
|
||||
if (this.deletedAt != null) {
|
||||
json[r'deletedAt'] = this.deletedAt!.toUtc().toIso8601String();
|
||||
} else {
|
||||
// json[r'deletedAt'] = null;
|
||||
}
|
||||
json[r'email'] = this.email;
|
||||
json[r'hasProfileImage'] = this.hasProfileImage;
|
||||
json[r'id'] = this.id;
|
||||
json[r'name'] = this.name;
|
||||
json[r'profileChangedAt'] = this.profileChangedAt.toUtc().toIso8601String();
|
||||
return json;
|
||||
}
|
||||
|
||||
@@ -67,10 +89,13 @@ class SyncUserV1 {
|
||||
final json = value.cast<String, dynamic>();
|
||||
|
||||
return SyncUserV1(
|
||||
avatarColor: UserAvatarColor.fromJson(json[r'avatarColor']),
|
||||
deletedAt: mapDateTime(json, r'deletedAt', r''),
|
||||
email: mapValueOfType<String>(json, r'email')!,
|
||||
hasProfileImage: mapValueOfType<bool>(json, r'hasProfileImage')!,
|
||||
id: mapValueOfType<String>(json, r'id')!,
|
||||
name: mapValueOfType<String>(json, r'name')!,
|
||||
profileChangedAt: mapDateTime(json, r'profileChangedAt', r'')!,
|
||||
);
|
||||
}
|
||||
return null;
|
||||
@@ -118,10 +143,13 @@ class SyncUserV1 {
|
||||
|
||||
/// The list of required keys that must be present in a JSON.
|
||||
static const requiredKeys = <String>{
|
||||
'avatarColor',
|
||||
'deletedAt',
|
||||
'email',
|
||||
'hasProfileImage',
|
||||
'id',
|
||||
'name',
|
||||
'profileChangedAt',
|
||||
};
|
||||
}
|
||||
|
||||
|
||||
@@ -13,14 +13,16 @@ part of openapi.api;
|
||||
class SystemConfigMachineLearningDto {
|
||||
/// Returns a new [SystemConfigMachineLearningDto] instance.
|
||||
SystemConfigMachineLearningDto({
|
||||
required this.availabilityChecks,
|
||||
required this.clip,
|
||||
required this.duplicateDetection,
|
||||
required this.enabled,
|
||||
required this.facialRecognition,
|
||||
this.url,
|
||||
this.urls = const [],
|
||||
});
|
||||
|
||||
MachineLearningAvailabilityChecksDto availabilityChecks;
|
||||
|
||||
CLIPConfig clip;
|
||||
|
||||
DuplicateDetectionConfig duplicateDetection;
|
||||
@@ -29,50 +31,37 @@ class SystemConfigMachineLearningDto {
|
||||
|
||||
FacialRecognitionConfig facialRecognition;
|
||||
|
||||
/// This property was deprecated in v1.122.0
|
||||
///
|
||||
/// Please note: This property should have been non-nullable! Since the specification file
|
||||
/// does not include a default value (using the "default:" property), however, the generated
|
||||
/// source code must fall back to having a nullable type.
|
||||
/// Consider adding a "default:" property in the specification file to hide this note.
|
||||
///
|
||||
String? url;
|
||||
|
||||
List<String> urls;
|
||||
|
||||
@override
|
||||
bool operator ==(Object other) => identical(this, other) || other is SystemConfigMachineLearningDto &&
|
||||
other.availabilityChecks == availabilityChecks &&
|
||||
other.clip == clip &&
|
||||
other.duplicateDetection == duplicateDetection &&
|
||||
other.enabled == enabled &&
|
||||
other.facialRecognition == facialRecognition &&
|
||||
other.url == url &&
|
||||
_deepEquality.equals(other.urls, urls);
|
||||
|
||||
@override
|
||||
int get hashCode =>
|
||||
// ignore: unnecessary_parenthesis
|
||||
(availabilityChecks.hashCode) +
|
||||
(clip.hashCode) +
|
||||
(duplicateDetection.hashCode) +
|
||||
(enabled.hashCode) +
|
||||
(facialRecognition.hashCode) +
|
||||
(url == null ? 0 : url!.hashCode) +
|
||||
(urls.hashCode);
|
||||
|
||||
@override
|
||||
String toString() => 'SystemConfigMachineLearningDto[clip=$clip, duplicateDetection=$duplicateDetection, enabled=$enabled, facialRecognition=$facialRecognition, url=$url, urls=$urls]';
|
||||
String toString() => 'SystemConfigMachineLearningDto[availabilityChecks=$availabilityChecks, clip=$clip, duplicateDetection=$duplicateDetection, enabled=$enabled, facialRecognition=$facialRecognition, urls=$urls]';
|
||||
|
||||
Map<String, dynamic> toJson() {
|
||||
final json = <String, dynamic>{};
|
||||
json[r'availabilityChecks'] = this.availabilityChecks;
|
||||
json[r'clip'] = this.clip;
|
||||
json[r'duplicateDetection'] = this.duplicateDetection;
|
||||
json[r'enabled'] = this.enabled;
|
||||
json[r'facialRecognition'] = this.facialRecognition;
|
||||
if (this.url != null) {
|
||||
json[r'url'] = this.url;
|
||||
} else {
|
||||
// json[r'url'] = null;
|
||||
}
|
||||
json[r'urls'] = this.urls;
|
||||
return json;
|
||||
}
|
||||
@@ -86,11 +75,11 @@ class SystemConfigMachineLearningDto {
|
||||
final json = value.cast<String, dynamic>();
|
||||
|
||||
return SystemConfigMachineLearningDto(
|
||||
availabilityChecks: MachineLearningAvailabilityChecksDto.fromJson(json[r'availabilityChecks'])!,
|
||||
clip: CLIPConfig.fromJson(json[r'clip'])!,
|
||||
duplicateDetection: DuplicateDetectionConfig.fromJson(json[r'duplicateDetection'])!,
|
||||
enabled: mapValueOfType<bool>(json, r'enabled')!,
|
||||
facialRecognition: FacialRecognitionConfig.fromJson(json[r'facialRecognition'])!,
|
||||
url: mapValueOfType<String>(json, r'url'),
|
||||
urls: json[r'urls'] is Iterable
|
||||
? (json[r'urls'] as Iterable).cast<String>().toList(growable: false)
|
||||
: const [],
|
||||
@@ -141,6 +130,7 @@ class SystemConfigMachineLearningDto {
|
||||
|
||||
/// The list of required keys that must be present in a JSON.
|
||||
static const requiredKeys = <String>{
|
||||
'availabilityChecks',
|
||||
'clip',
|
||||
'duplicateDetection',
|
||||
'enabled',
|
||||
|
||||
+21
-1
@@ -21,8 +21,10 @@ class TimeBucketAssetResponseDto {
|
||||
this.isFavorite = const [],
|
||||
this.isImage = const [],
|
||||
this.isTrashed = const [],
|
||||
this.latitude = const [],
|
||||
this.livePhotoVideoId = const [],
|
||||
this.localOffsetHours = const [],
|
||||
this.longitude = const [],
|
||||
this.ownerId = const [],
|
||||
this.projectionType = const [],
|
||||
this.ratio = const [],
|
||||
@@ -55,12 +57,18 @@ class TimeBucketAssetResponseDto {
|
||||
/// Array indicating whether each asset is in the trash
|
||||
List<bool> isTrashed;
|
||||
|
||||
/// Array of latitude coordinates extracted from EXIF GPS data
|
||||
List<num?> latitude;
|
||||
|
||||
/// Array of live photo video asset IDs (null for non-live photos)
|
||||
List<String?> livePhotoVideoId;
|
||||
|
||||
/// 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.
|
||||
List<num> localOffsetHours;
|
||||
|
||||
/// Array of longitude coordinates extracted from EXIF GPS data
|
||||
List<num?> longitude;
|
||||
|
||||
/// Array of owner IDs for each asset
|
||||
List<String> ownerId;
|
||||
|
||||
@@ -89,8 +97,10 @@ class TimeBucketAssetResponseDto {
|
||||
_deepEquality.equals(other.isFavorite, isFavorite) &&
|
||||
_deepEquality.equals(other.isImage, isImage) &&
|
||||
_deepEquality.equals(other.isTrashed, isTrashed) &&
|
||||
_deepEquality.equals(other.latitude, latitude) &&
|
||||
_deepEquality.equals(other.livePhotoVideoId, livePhotoVideoId) &&
|
||||
_deepEquality.equals(other.localOffsetHours, localOffsetHours) &&
|
||||
_deepEquality.equals(other.longitude, longitude) &&
|
||||
_deepEquality.equals(other.ownerId, ownerId) &&
|
||||
_deepEquality.equals(other.projectionType, projectionType) &&
|
||||
_deepEquality.equals(other.ratio, ratio) &&
|
||||
@@ -109,8 +119,10 @@ class TimeBucketAssetResponseDto {
|
||||
(isFavorite.hashCode) +
|
||||
(isImage.hashCode) +
|
||||
(isTrashed.hashCode) +
|
||||
(latitude.hashCode) +
|
||||
(livePhotoVideoId.hashCode) +
|
||||
(localOffsetHours.hashCode) +
|
||||
(longitude.hashCode) +
|
||||
(ownerId.hashCode) +
|
||||
(projectionType.hashCode) +
|
||||
(ratio.hashCode) +
|
||||
@@ -119,7 +131,7 @@ class TimeBucketAssetResponseDto {
|
||||
(visibility.hashCode);
|
||||
|
||||
@override
|
||||
String toString() => 'TimeBucketAssetResponseDto[city=$city, country=$country, duration=$duration, fileCreatedAt=$fileCreatedAt, id=$id, isFavorite=$isFavorite, isImage=$isImage, isTrashed=$isTrashed, livePhotoVideoId=$livePhotoVideoId, localOffsetHours=$localOffsetHours, ownerId=$ownerId, projectionType=$projectionType, ratio=$ratio, stack=$stack, thumbhash=$thumbhash, visibility=$visibility]';
|
||||
String toString() => 'TimeBucketAssetResponseDto[city=$city, country=$country, duration=$duration, fileCreatedAt=$fileCreatedAt, id=$id, isFavorite=$isFavorite, isImage=$isImage, isTrashed=$isTrashed, latitude=$latitude, livePhotoVideoId=$livePhotoVideoId, localOffsetHours=$localOffsetHours, longitude=$longitude, ownerId=$ownerId, projectionType=$projectionType, ratio=$ratio, stack=$stack, thumbhash=$thumbhash, visibility=$visibility]';
|
||||
|
||||
Map<String, dynamic> toJson() {
|
||||
final json = <String, dynamic>{};
|
||||
@@ -131,8 +143,10 @@ class TimeBucketAssetResponseDto {
|
||||
json[r'isFavorite'] = this.isFavorite;
|
||||
json[r'isImage'] = this.isImage;
|
||||
json[r'isTrashed'] = this.isTrashed;
|
||||
json[r'latitude'] = this.latitude;
|
||||
json[r'livePhotoVideoId'] = this.livePhotoVideoId;
|
||||
json[r'localOffsetHours'] = this.localOffsetHours;
|
||||
json[r'longitude'] = this.longitude;
|
||||
json[r'ownerId'] = this.ownerId;
|
||||
json[r'projectionType'] = this.projectionType;
|
||||
json[r'ratio'] = this.ratio;
|
||||
@@ -175,12 +189,18 @@ class TimeBucketAssetResponseDto {
|
||||
isTrashed: json[r'isTrashed'] is Iterable
|
||||
? (json[r'isTrashed'] as Iterable).cast<bool>().toList(growable: false)
|
||||
: const [],
|
||||
latitude: json[r'latitude'] is Iterable
|
||||
? (json[r'latitude'] as Iterable).cast<num>().toList(growable: false)
|
||||
: const [],
|
||||
livePhotoVideoId: json[r'livePhotoVideoId'] is Iterable
|
||||
? (json[r'livePhotoVideoId'] as Iterable).cast<String>().toList(growable: false)
|
||||
: const [],
|
||||
localOffsetHours: json[r'localOffsetHours'] is Iterable
|
||||
? (json[r'localOffsetHours'] as Iterable).cast<num>().toList(growable: false)
|
||||
: const [],
|
||||
longitude: json[r'longitude'] is Iterable
|
||||
? (json[r'longitude'] as Iterable).cast<num>().toList(growable: false)
|
||||
: const [],
|
||||
ownerId: json[r'ownerId'] is Iterable
|
||||
? (json[r'ownerId'] as Iterable).cast<String>().toList(growable: false)
|
||||
: const [],
|
||||
|
||||
+88
@@ -0,0 +1,88 @@
|
||||
//
|
||||
// AUTO-GENERATED FILE, DO NOT MODIFY!
|
||||
//
|
||||
// @dart=2.18
|
||||
|
||||
// ignore_for_file: unused_element, unused_import
|
||||
// ignore_for_file: always_put_required_named_parameters_first
|
||||
// ignore_for_file: constant_identifier_names
|
||||
// ignore_for_file: lines_longer_than_80_chars
|
||||
|
||||
part of openapi.api;
|
||||
|
||||
|
||||
class UserMetadataKey {
|
||||
/// Instantiate a new enum with the provided [value].
|
||||
const UserMetadataKey._(this.value);
|
||||
|
||||
/// The underlying value of this enum member.
|
||||
final String value;
|
||||
|
||||
@override
|
||||
String toString() => value;
|
||||
|
||||
String toJson() => value;
|
||||
|
||||
static const preferences = UserMetadataKey._(r'preferences');
|
||||
static const license = UserMetadataKey._(r'license');
|
||||
static const onboarding = UserMetadataKey._(r'onboarding');
|
||||
|
||||
/// List of all possible values in this [enum][UserMetadataKey].
|
||||
static const values = <UserMetadataKey>[
|
||||
preferences,
|
||||
license,
|
||||
onboarding,
|
||||
];
|
||||
|
||||
static UserMetadataKey? fromJson(dynamic value) => UserMetadataKeyTypeTransformer().decode(value);
|
||||
|
||||
static List<UserMetadataKey> listFromJson(dynamic json, {bool growable = false,}) {
|
||||
final result = <UserMetadataKey>[];
|
||||
if (json is List && json.isNotEmpty) {
|
||||
for (final row in json) {
|
||||
final value = UserMetadataKey.fromJson(row);
|
||||
if (value != null) {
|
||||
result.add(value);
|
||||
}
|
||||
}
|
||||
}
|
||||
return result.toList(growable: growable);
|
||||
}
|
||||
}
|
||||
|
||||
/// Transformation class that can [encode] an instance of [UserMetadataKey] to String,
|
||||
/// and [decode] dynamic data back to [UserMetadataKey].
|
||||
class UserMetadataKeyTypeTransformer {
|
||||
factory UserMetadataKeyTypeTransformer() => _instance ??= const UserMetadataKeyTypeTransformer._();
|
||||
|
||||
const UserMetadataKeyTypeTransformer._();
|
||||
|
||||
String encode(UserMetadataKey data) => data.value;
|
||||
|
||||
/// Decodes a [dynamic value][data] to a UserMetadataKey.
|
||||
///
|
||||
/// If [allowNull] is true and the [dynamic value][data] cannot be decoded successfully,
|
||||
/// then null is returned. However, if [allowNull] is false and the [dynamic value][data]
|
||||
/// cannot be decoded successfully, then an [UnimplementedError] is thrown.
|
||||
///
|
||||
/// The [allowNull] is very handy when an API changes and a new enum value is added or removed,
|
||||
/// and users are still using an old app with the old code.
|
||||
UserMetadataKey? decode(dynamic data, {bool allowNull = true}) {
|
||||
if (data != null) {
|
||||
switch (data) {
|
||||
case r'preferences': return UserMetadataKey.preferences;
|
||||
case r'license': return UserMetadataKey.license;
|
||||
case r'onboarding': return UserMetadataKey.onboarding;
|
||||
default:
|
||||
if (!allowNull) {
|
||||
throw ArgumentError('Unknown enum value to decode: $data');
|
||||
}
|
||||
}
|
||||
}
|
||||
return null;
|
||||
}
|
||||
|
||||
/// Singleton [UserMetadataKeyTypeTransformer] instance.
|
||||
static UserMetadataKeyTypeTransformer? _instance;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user