Supabase.Auth.Admin.CustomProviders.Behaviour behaviour (supabase_auth v1.0.1)

View Source

Behaviour for admin-level custom OIDC/OAuth provider management.

Defines the contract for managing custom identity providers programmatically via the GoTrue admin API. Requires a service_role key.

Summary

Callbacks

create_provider(t, map)

@callback create_provider(Supabase.Client.t(), map()) ::
  {:ok, Supabase.Auth.Schemas.CustomProvider.t()} | {:error, term()}

delete_provider(t, t)

@callback delete_provider(Supabase.Client.t(), String.t()) :: :ok | {:error, term()}

get_provider(t, t)

@callback get_provider(Supabase.Client.t(), String.t()) ::
  {:ok, Supabase.Auth.Schemas.CustomProvider.t()} | {:error, term()}

list_providers(t, map)

@callback list_providers(Supabase.Client.t(), map()) ::
  {:ok, [Supabase.Auth.Schemas.CustomProvider.t()]} | {:error, term()}

update_provider(t, t, map)

@callback update_provider(Supabase.Client.t(), String.t(), map()) ::
  {:ok, Supabase.Auth.Schemas.CustomProvider.t()} | {:error, term()}