Spotify OAuth & Presence

This commit is contained in:
2025-11-02 15:32:20 +08:00
parent c74ab20236
commit 6817ab6b56
7 changed files with 502 additions and 1 deletions

View File

@@ -0,0 +1,21 @@
using Quartz;
namespace DysonNetwork.Pass.Account.Presences;
public class SpotifyPresenceUpdateJob(SpotifyPresenceService spotifyPresenceService, ILogger<SpotifyPresenceUpdateJob> logger) : IJob
{
public async Task Execute(IJobExecutionContext context)
{
logger.LogInformation("Starting Spotify presence updates...");
try
{
await spotifyPresenceService.UpdateAllSpotifyPresencesAsync();
logger.LogInformation("Spotify presence updates completed successfully.");
}
catch (Exception ex)
{
logger.LogError(ex, "Error occurred during Spotify presence updates.");
}
}
}