From 35c43fa85980f4197aa6c462c8a836fcb3db04bc Mon Sep 17 00:00:00 2001 From: csgulati09 Date: Sat, 14 Dec 2024 13:18:53 +0530 Subject: [PATCH] feat: user invite resend --- portkey_ai/api_resources/apis/admin.py | 22 ++++++++++++++++++++++ 1 file changed, 22 insertions(+) diff --git a/portkey_ai/api_resources/apis/admin.py b/portkey_ai/api_resources/apis/admin.py index 6d0b3a6..8cf97b5 100644 --- a/portkey_ai/api_resources/apis/admin.py +++ b/portkey_ai/api_resources/apis/admin.py @@ -170,6 +170,17 @@ def delete(self, *, invite_id: str) -> Any: headers={}, ) + def resend(self, *, invite_id: str) -> Any: + return self._post( + f"{PortkeyApiPaths.INVITE_API}/{invite_id}/resend", + body=None, + params=None, + cast_to=GenericResponse, + stream=False, + stream_cls=None, + headers={}, + ) + class Workspaces(APIResource): def __init__(self, client: APIClient) -> None: @@ -454,6 +465,17 @@ async def delete(self, *, user_id: str) -> Any: headers={}, ) + async def resend(self, *, invite_id: str) -> Any: + return await self._post( + f"{PortkeyApiPaths.INVITE_API}/{invite_id}/resend", + body=None, + params=None, + cast_to=GenericResponse, + stream=False, + stream_cls=None, + headers={}, + ) + class AsyncInvites(AsyncAPIResource): def __init__(self, client: AsyncAPIClient) -> None: