feat(bp): /battle_pass/buy — crystal-cost + retroactive premium grants
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
@@ -19,4 +19,12 @@ public interface IBattlePassService
|
||||
/// array if the viewer already owns premium for the active season. Null when no active season.
|
||||
/// </summary>
|
||||
Task<BattlePassItemListResponse?> GetItemListAsync(long viewerId, CancellationToken ct);
|
||||
|
||||
/// <summary>
|
||||
/// Purchase premium for the active season. Validates season_id matches active season,
|
||||
/// product id derives from season, viewer has crystals, viewer isn't already premium.
|
||||
/// On success: deducts crystals, flips IsPremium, retroactively grants premium rewards for
|
||||
/// every level <= current_level not yet claimed. All-or-nothing transaction.
|
||||
/// </summary>
|
||||
Task<BattlePassBuyOutcome> BuyPremiumAsync(long viewerId, int seasonId, int productId, CancellationToken ct);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user