getFileMetadata method
Retrieves metadata for the file or directory at the specified path
.
Implementation
@override
Future<CloudFile> getFileMetadata(String path) {
return _executeRequest(() async {
final normalizedPath = _normalizePath(path);
debugPrint('Getting metadata for Dropbox path: $normalizedPath');
final response = await _dio.post(
'https://api.dropboxapi.com/2/files/get_metadata',
data: jsonEncode({'path': normalizedPath}),
options: Options(contentType: 'application/json'),
);
return _mapToCloudFile(response.data);
});
}