Skip to content

Commit 2510230

Browse files
authored
fix: update invite user by email option type (#588)
1 parent 536ad2c commit 2510230

File tree

3 files changed

+9
-4
lines changed

3 files changed

+9
-4
lines changed

supabase_auth/_async/gotrue_admin_api.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@
1313
AuthMFAAdminListFactorsResponse,
1414
GenerateLinkParams,
1515
GenerateLinkResponse,
16-
Options,
16+
InviteUserByEmailOptions,
1717
SignOutScope,
1818
User,
1919
UserResponse,
@@ -57,7 +57,7 @@ async def sign_out(self, jwt: str, scope: SignOutScope = "global") -> None:
5757
async def invite_user_by_email(
5858
self,
5959
email: str,
60-
options: Options = {},
60+
options: InviteUserByEmailOptions = {},
6161
) -> UserResponse:
6262
"""
6363
Sends an invite link to an email address.

supabase_auth/_sync/gotrue_admin_api.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@
1313
AuthMFAAdminListFactorsResponse,
1414
GenerateLinkParams,
1515
GenerateLinkResponse,
16-
Options,
16+
InviteUserByEmailOptions,
1717
SignOutScope,
1818
User,
1919
UserResponse,
@@ -57,7 +57,7 @@ def sign_out(self, jwt: str, scope: SignOutScope = "global") -> None:
5757
def invite_user_by_email(
5858
self,
5959
email: str,
60-
options: Options = {},
60+
options: InviteUserByEmailOptions = {},
6161
) -> UserResponse:
6262
"""
6363
Sends an invite link to an email address.

supabase_auth/types.py

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -87,6 +87,11 @@ class Options(TypedDict):
8787
captcha_token: NotRequired[str]
8888

8989

90+
class InviteUserByEmailOptions(TypedDict):
91+
redirect_to: NotRequired[str]
92+
data: NotRequired[Any]
93+
94+
9095
class AuthResponse(BaseModel):
9196
user: Union[User, None] = None
9297
session: Union[Session, None] = None

0 commit comments

Comments
 (0)