mirror of
https://github.com/Ombi-app/Ombi.git
synced 2025-08-14 02:26:55 -07:00
Loads more work *phew* !wip
This commit is contained in:
parent
f72e48659c
commit
70db3c7bca
33 changed files with 841 additions and 487 deletions
|
@ -11,7 +11,8 @@ namespace Ombi.Api.Lidarr
|
|||
Task<List<LidarrProfile>> GetProfiles(string apiKey, string baseUrl);
|
||||
Task<List<LidarrRootFolder>> GetRootFolders(string apiKey, string baseUrl);
|
||||
Task<ArtistResult> GetArtist(int artistId, string apiKey, string baseUrl);
|
||||
Task<ArtistResult> GetArtistByForignId(string foreignArtistId, string apiKey, string baseUrl);
|
||||
Task<ArtistResult> GetArtistByForeignId(string foreignArtistId, string apiKey, string baseUrl);
|
||||
Task<AlbumByArtistResponse> GetAlbumsByArtist(int artistId, string apiKey, string baseUrl);
|
||||
Task<AlbumLookup> GetAlbumByForeignId(string foreignArtistId, string apiKey, string baseUrl);
|
||||
}
|
||||
}
|
|
@ -62,7 +62,7 @@ namespace Ombi.Api.Lidarr
|
|||
return Api.Request<ArtistResult>(request);
|
||||
}
|
||||
|
||||
public Task<ArtistResult> GetArtistByForignId(string foreignArtistId, string apiKey, string baseUrl)
|
||||
public Task<ArtistResult> GetArtistByForeignId(string foreignArtistId, string apiKey, string baseUrl)
|
||||
{
|
||||
var request = new Request($"{ApiVersion}/artist/lookup", baseUrl, HttpMethod.Get);
|
||||
|
||||
|
@ -71,6 +71,16 @@ namespace Ombi.Api.Lidarr
|
|||
return Api.Request<ArtistResult>(request);
|
||||
}
|
||||
|
||||
|
||||
public Task<AlbumLookup> GetAlbumByForeignId(string foreignArtistId, string apiKey, string baseUrl)
|
||||
{
|
||||
var request = new Request($"{ApiVersion}/album/lookup", baseUrl, HttpMethod.Get);
|
||||
|
||||
request.AddQueryString("term", $"lidarr:{foreignArtistId}");
|
||||
AddHeaders(request, apiKey);
|
||||
return Api.Request<AlbumLookup>(request);
|
||||
}
|
||||
|
||||
public Task<AlbumByArtistResponse> GetAlbumsByArtist(int artistId, string apiKey, string baseUrl)
|
||||
{
|
||||
var request = new Request($"{ApiVersion}/album", baseUrl, HttpMethod.Get);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue