LANCommander/LANCommander.SDK/Clients/IssueClient.cs
2025-12-13 00:26:43 -06:00

26 lines
738 B
C#

using LANCommander.SDK.Models;
using Microsoft.Extensions.Logging;
using System;
using System.Threading.Tasks;
using LANCommander.SDK.Factories;
namespace LANCommander.SDK.Services
{
public class IssueClient(ApiRequestFactory apiRequestFactory)
{
public async Task<bool> Open(string description, Guid gameId)
{
return await apiRequestFactory
.Create()
.UseAuthenticationToken()
.UseVersioning()
.UseRoute("/api/Issue/Open")
.AddBody(new Issue
{
Description = description,
GameId = gameId,
})
.PostAsync<bool>();
}
}
}