import '../dto/common/qiu_token_dto.dart';
import '../dto/common/version_dto.dart';
import '../network/request.dart';

///获取七牛token
/// - [fileKey]: 文件key
Future<QiuTokenDto> getQiuTokenApi(String fileKey) async {
  var response = await Request().get("/files/get_qiniu_upload_token", {
    "file_key": fileKey,
  });
  return QiuTokenDto.fromJson(response);
}

///获取APP最新版本
Future<VersionDto> getAppVersionApi() async {
  var response = await Request().get("/get_latest_version");
  return VersionDto.fromJson(response);
}
