From 7d5a77438069309a2234cb56ba0ff6f4eb645c10 Mon Sep 17 00:00:00 2001 From: Tom Hacohen Date: Thu, 1 Aug 2024 09:27:48 -0400 Subject: [PATCH] Python (async): add missing 'get_stats' function. (#1378) It already existed in the sync library, but not the async. --- python/svix/api.py | 14 ++++++++++++++ 1 file changed, 14 insertions(+) diff --git a/python/svix/api.py b/python/svix/api.py index cca45c8fd..f4e898185 100644 --- a/python/svix/api.py +++ b/python/svix/api.py @@ -539,6 +539,20 @@ async def patch_headers( json_body=endpoint_headers_in, ) + async def get_stats( + self, + app_id: str, + endpoint_id: str, + options: EndpointStatsOptions = EndpointStatsOptions(), + ) -> EndpointStats: + return await v1_endpoint_get_stats.request_asyncio( + client=self._client, + app_id=app_id, + endpoint_id=endpoint_id, + since=options.since, + until=options.until, + ) + async def replay_missing( self, app_id: str,