function get many filters

This commit is contained in:
Corban-Lee Jones 2024-08-23 17:45:43 +01:00
parent 1a4f25ec97
commit 2a1aaa689e

View File

@ -157,7 +157,7 @@ class API:
log.debug("getting tracked content")
return await self._get_many(self.API_ENDPOINT + f"tracked-content/", filters)
return await self._get_many(self.API_ENDPOINT + "tracked-content/", filters)
async def get_filter(self, filter_id: int) -> dict:
"""
@ -167,3 +167,10 @@ class API:
log.debug("getting a filter")
return await self._get_one(f"{self.API_ENDPOINT}filter/{filter_id}")
async def get_filters(self, **filters) -> tuple[list[dict], int]:
"""
Get many instances of Filter.
"""
return await self._get_many(self.API_ENDPOINT + "filter/", filters)