Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
9 changes: 6 additions & 3 deletions sdk-compliance.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -181,9 +181,7 @@ features:
auth.session.auto_refresh:
status: implemented
note: "Token refresh runs automatically as an internal background task controlled by the auto_refresh_token constructor option."
symbols:
- AsyncSessionManager.start_auto_refresh_token
- SyncSessionManager.start_auto_refresh_token
no_public_symbols: true
auth.session.sign_out_reason: not_implemented

auth.identities.link_identity:
Expand Down Expand Up @@ -752,6 +750,8 @@ features:
status: implemented
symbols:
- BaseRequestClient.retry
supporting_symbols:
- BaseRequestClient
database.configuration.request_timeout:
status: implemented
note: "No timeout parameter. Configure the timeout on the httpx client passed in through http_session, or wrap async calls in asyncio.wait_for (asyncio.timeout on Python 3.11+)."
Expand Down Expand Up @@ -1004,6 +1004,7 @@ features:
- StorageClient.create_bucket
supporting_symbols:
- CreateOrUpdateBucketBody
- BucketName
storage.file_buckets.get_bucket:
status: implemented
symbols:
Expand Down Expand Up @@ -1198,6 +1199,7 @@ features:
- StorageVectorsClient
- VectorBucketScope
- VectorIndexScope
- StorageVectorsClient.get_bucket
storage.vector_buckets.create_index:
status: implemented
symbols:
Expand Down Expand Up @@ -1423,3 +1425,4 @@ supporting_symbols:
- SystemMessage
- ChannelErrorMessage
- ChannelCloseMessage
- ChannelLeaveMessage
32 changes: 16 additions & 16 deletions src/auth/src/supabase_auth/admin_api.py
Original file line number Diff line number Diff line change
Expand Up @@ -20,12 +20,12 @@
from yarl import URL

from .helpers import (
handle_error_response,
_handle_error_response,
_redirect_to_as_query,
_validate_adapter,
_validate_model,
parse_link_response,
parse_user_response,
redirect_to_as_query,
validate_adapter,
validate_model,
validate_uuid,
)
from .types import (
Expand Down Expand Up @@ -74,7 +74,7 @@ def delete_factor(
method="DELETE",
path=["admin", "users", user_id, "factors", factor_id],
)
return validate_model(response, AuthMFAAdminDeleteFactorResponse)
return _validate_model(response, AuthMFAAdminDeleteFactorResponse)

@handle_http_io
def list_factors(self, user_id: str) -> HttpMethod[AuthMFAAdminListFactorsResponse]:
Expand All @@ -86,7 +86,7 @@ def list_factors(self, user_id: str) -> HttpMethod[AuthMFAAdminListFactorsRespon
method="GET",
path=["admin", "users", user_id, "factors"],
)
return validate_adapter(response, AuthMFAAdminListFactorsResponseParser)
return _validate_adapter(response, AuthMFAAdminListFactorsResponseParser)


@dataclass
Expand Down Expand Up @@ -125,7 +125,7 @@ def list_clients(
query=query,
)

result = validate_model(response, OAuthClientListResponse)
result = _validate_model(response, OAuthClientListResponse)

# Parse pagination headers
total = response.headers.get("x-total-count")
Expand Down Expand Up @@ -166,7 +166,7 @@ def create_client(
body=params,
)

return OAuthClientResponse(client=validate_model(response, OAuthClient))
return OAuthClientResponse(client=_validate_model(response, OAuthClient))

@handle_http_io
def get_client(
Expand All @@ -185,7 +185,7 @@ def get_client(
method="GET",
path=["admin", "oauth", "clients", client_id],
)
return OAuthClientResponse(client=validate_model(response, OAuthClient))
return OAuthClientResponse(client=_validate_model(response, OAuthClient))

@handle_http_io
def update_client(
Expand All @@ -206,7 +206,7 @@ def update_client(
path=["admin", "oauth", "clients", client_id],
body=params,
)
return OAuthClientResponse(client=validate_model(response, OAuthClient))
return OAuthClientResponse(client=_validate_model(response, OAuthClient))

@handle_http_io
def delete_client(
Expand All @@ -226,7 +226,7 @@ def delete_client(
path=["admin", "oauth", "clients", client_id],
)
if not response.is_success:
raise handle_error_response(response)
raise _handle_error_response(response)

@handle_http_io
def regenerate_client_secret(
Expand All @@ -245,7 +245,7 @@ def regenerate_client_secret(
method="POST",
path=["admin", "oauth", "clients", client_id, "regenerate_secret"],
)
return OAuthClientResponse(client=validate_model(response, OAuthClient))
return OAuthClientResponse(client=_validate_model(response, OAuthClient))


class SupabaseAuthAdmin(Generic[HttpIO]):
Expand Down Expand Up @@ -279,7 +279,7 @@ def invite_user_by_email(
method="POST",
path=["invite"],
body={"email": email, "data": data},
query=redirect_to_as_query(redirect_to),
query=_redirect_to_as_query(redirect_to),
)
return parse_user_response(response)

Expand All @@ -294,7 +294,7 @@ def generate_link(
method="POST",
path=["admin", "generate_link"],
body=params.body,
query=redirect_to_as_query(params.redirect_to),
query=_redirect_to_as_query(params.redirect_to),
)

return parse_link_response(response)
Expand Down Expand Up @@ -335,7 +335,7 @@ def list_users(
path=["admin", "users"],
query=query,
)
return validate_model(response, UserList).users
return _validate_model(response, UserList).users

@handle_http_io
def get_user_by_id(self, uid: str) -> HttpMethod[UserResponse]:
Expand Down Expand Up @@ -389,7 +389,7 @@ def delete_user(
method="DELETE", path=["admin", "users", id], body=body
)
if not response.is_success:
raise handle_error_response(response)
raise _handle_error_response(response)


class SyncSupabaseAuthAdmin(SupabaseAuthAdmin[SyncHttpIO]):
Expand Down
Loading
Loading