using Flurl.Http; using Recyclarr.TrashLib.Http; using Recyclarr.TrashLib.Services.Sonarr.Api.Objects; namespace Recyclarr.TrashLib.Services.Sonarr.Api; public class SonarrTagApiService : ISonarrTagApiService { private readonly IServiceRequestBuilder _service; public SonarrTagApiService(IServiceRequestBuilder service) { _service = service; } public async Task> GetTags() { return await _service.Request("tag") .GetJsonAsync>(); } public async Task CreateTag(string tag) { return await _service.Request("tag") .PostJsonAsync(new {label = tag}) .ReceiveJson(); } }