using System.Collections.Generic;
using System.Threading;
using System.Threading.Tasks;

namespace Jellyfin.Plugin.SRFPlay.Services.Interfaces;

/// <summary>
/// Interface for refreshing content from SRF API.
/// </summary>
public interface IContentRefreshService
{
    /// <summary>
    /// Refreshes latest content from SRF API using Play v3.
    /// </summary>
    /// <param name="cancellationToken">The cancellation token.</param>
    /// <returns>List of URNs for new content.</returns>
    Task<List<string>> RefreshLatestContentAsync(CancellationToken cancellationToken);

    /// <summary>
    /// Refreshes trending content from SRF API using Play v3.
    /// </summary>
    /// <param name="cancellationToken">The cancellation token.</param>
    /// <returns>List of URNs for trending content.</returns>
    Task<List<string>> RefreshTrendingContentAsync(CancellationToken cancellationToken);

    /// <summary>
    /// Refreshes all content (latest and trending).
    /// </summary>
    /// <param name="cancellationToken">The cancellation token.</param>
    /// <returns>Tuple with counts of latest and trending items.</returns>
    Task<(int LatestCount, int TrendingCount)> RefreshAllContentAsync(CancellationToken cancellationToken);

    /// <summary>
    /// Gets content recommendations (combines latest and trending).
    /// </summary>
    /// <param name="cancellationToken">The cancellation token.</param>
    /// <returns>List of recommended URNs.</returns>
    Task<List<string>> GetRecommendedContentAsync(CancellationToken cancellationToken);
}
