listHistoricalDeletionsWithHttpInfo method
Historical deletions — paged list
Cost: 5 credits, flat. Paged/filterable window on the 24-month deletion backlog. Rows are frozen at the moment the model was last seen on the Hub — peak_downloads and total_months_alive never change after death. Sort by size (downloads, default), recency (recent, newest deaths first) or lifespan (lifespan, longest-lived first — surprising deaths).
Note: This method returns the HTTP Response.
Parameters:
-
String sinceMonth: ISO YYYY-MM. Rows with last_seen_month >= it only.
-
int minPeakDownloads: Only rows whose peak downloads >= this.
casualties over Nqueries. -
String sort:
downloads(default, biggest first),recent(newest last_seen_month first),lifespan(longest-lived first). -
int limit: Rows to return, 1 to 1000. Values outside the range are clamped, not rejected.
-
int offset: Rows to skip. Negative and non-numeric values are treated as 0.
Implementation
Future<Response> listHistoricalDeletionsWithHttpInfo({ String? sinceMonth, int? minPeakDownloads, String? sort, int? limit, int? offset, Future<void>? abortTrigger, }) async {
// ignore: prefer_const_declarations
final path = r'/api/v1/models/historical-deletions/list';
// ignore: prefer_final_locals
Object? postBody;
final queryParams = <QueryParam>[];
final headerParams = <String, String>{};
final formParams = <String, String>{};
if (sinceMonth != null) {
queryParams.addAll(_queryParams('', 'since_month', sinceMonth));
}
if (minPeakDownloads != null) {
queryParams.addAll(_queryParams('', 'min_peak_downloads', minPeakDownloads));
}
if (sort != null) {
queryParams.addAll(_queryParams('', 'sort', sort));
}
if (limit != null) {
queryParams.addAll(_queryParams('', 'limit', limit));
}
if (offset != null) {
queryParams.addAll(_queryParams('', 'offset', offset));
}
const contentTypes = <String>[];
return apiClient.invokeAPI(
path,
'GET',
queryParams,
postBody,
headerParams,
formParams,
contentTypes.isEmpty ? null : contentTypes.first,
abortTrigger: abortTrigger,
);
}