more refactors
This commit is contained in:
@@ -0,0 +1,10 @@
|
||||
abstract interface class IAuthenticationApiRepository {
|
||||
/// Returns the access token on successful login
|
||||
Future<String?> login(String email, String password);
|
||||
|
||||
/// Returns the OAuth URL
|
||||
Future<String?> startOAuth({required String redirectUri});
|
||||
|
||||
/// Returns the access token on successful oauth login
|
||||
Future<String?> finishOAuth(String url);
|
||||
}
|
||||
@@ -0,0 +1,13 @@
|
||||
import 'package:immich_mobile/domain/models/server-info/server_config.model.dart';
|
||||
import 'package:immich_mobile/domain/models/server-info/server_features.model.dart';
|
||||
|
||||
abstract interface class IServerApiRepository {
|
||||
/// Pings and check if server is reachable
|
||||
Future<void> pingServer();
|
||||
|
||||
/// Fetches the list of enabled features in the server
|
||||
Future<ServerFeatures?> getServerFeatures();
|
||||
|
||||
/// Fetches the server configuration and settings
|
||||
Future<ServerConfig?> getServerConfig();
|
||||
}
|
||||
@@ -0,0 +1,11 @@
|
||||
import 'package:immich_mobile/domain/models/asset.model.dart';
|
||||
|
||||
abstract interface class ISyncApiRepository {
|
||||
/// Fetches the full assets for the user in batches
|
||||
Future<List<Asset>?> getFullSyncForUser({
|
||||
String? lastId,
|
||||
required int limit,
|
||||
required DateTime updatedUntil,
|
||||
String? userId,
|
||||
});
|
||||
}
|
||||
@@ -0,0 +1,6 @@
|
||||
import 'package:immich_mobile/domain/models/user.model.dart';
|
||||
|
||||
abstract interface class IUserApiRepository {
|
||||
/// Fetches the current users meta data
|
||||
Future<User?> getMyUser();
|
||||
}
|
||||
Reference in New Issue
Block a user