using Newtonsoft.Json.Linq; using OF_DL.Enumerations; using ArchivedEntities = OF_DL.Models.Entities.Archived; using MessageEntities = OF_DL.Models.Entities.Messages; using PostEntities = OF_DL.Models.Entities.Posts; using PurchasedEntities = OF_DL.Models.Entities.Purchased; using StreamEntities = OF_DL.Models.Entities.Streams; using UserEntities = OF_DL.Models.Entities.Users; namespace OF_DL.Services; public interface IApiService { /// /// Retrieves a decryption key using the local CDM integration. /// Task GetDecryptionKeyCdm(Dictionary drmHeaders, string licenceUrl, string pssh); /// /// Retrieves the last modified timestamp for a DRM MPD manifest. /// Task GetDrmMpdLastModified(string mpdUrl, string policy, string signature, string kvp); /// /// Retrieves the Widevine PSSH from an MPD manifest. /// Task GetDrmMpdPssh(string mpdUrl, string policy, string signature, string kvp); /// /// Retrieves the user's lists. /// Task?> GetLists(string endpoint); /// /// Retrieves usernames for a specific list. /// Task?> GetListUsers(string endpoint); /// /// Retrieves media URLs for stories or highlights. /// Task?> GetMedia(MediaType mediaType, string endpoint, string? username, string folder, CancellationToken cancellationToken = default); /// /// Retrieves paid posts and their media. /// Task GetPaidPosts(string endpoint, string folder, string username, List paidPostIds, IStatusReporter statusReporter, CancellationToken cancellationToken = default); /// /// Retrieves posts and their media. /// Task GetPosts(string endpoint, string folder, List paidPostIds, IStatusReporter statusReporter, CancellationToken cancellationToken = default); /// /// Retrieves a single post and its media. /// Task GetPost(string endpoint, string folder, CancellationToken cancellationToken = default); /// /// Retrieves streams and their media. /// Task GetStreams(string endpoint, string folder, List paidPostIds, IStatusReporter statusReporter, CancellationToken cancellationToken = default); /// /// Retrieves archived posts and their media. /// Task GetArchived(string endpoint, string folder, IStatusReporter statusReporter, CancellationToken cancellationToken = default); /// /// Retrieves messages and their media. /// Task GetMessages(string endpoint, string folder, IStatusReporter statusReporter, CancellationToken cancellationToken = default); /// /// Retrieves paid messages and their media. /// Task GetPaidMessages(string endpoint, string folder, string username, IStatusReporter statusReporter, CancellationToken cancellationToken = default); /// /// Retrieves a single paid message and its media. /// Task GetPaidMessage(string endpoint, string folder, CancellationToken cancellationToken = default); /// /// Retrieves users that appear in the Purchased tab. /// Task> GetPurchasedTabUsers(string endpoint, Dictionary users, CancellationToken cancellationToken = default); /// /// Retrieves Purchased tab content grouped by user. /// Task> GetPurchasedTab(string endpoint, string folder, Dictionary users, CancellationToken cancellationToken = default); /// /// Retrieves user information. /// Task GetUserInfo(string endpoint, CancellationToken cancellationToken = default); /// /// Retrieves user information by ID. /// Task GetUserInfoById(string endpoint); /// /// Builds signed headers for API requests. /// Dictionary GetDynamicHeaders(string path, string queryParam); /// /// Retrieves active subscriptions. /// Task?> GetActiveSubscriptions(string endpoint, bool includeRestrictedSubscriptions); /// /// Retrieves expired subscriptions. /// Task?> GetExpiredSubscriptions(string endpoint, bool includeRestrictedSubscriptions); /// /// Retrieves a decryption key via the OF DL fallback service. /// Task GetDecryptionKeyOfdl(Dictionary drmHeaders, string licenceUrl, string pssh); }