Supabase Auth is a Scala library for interacting with the Supabase Auth API.
This Scala client follows the ideas of the official client supabase/auth-py
To get started, you'll need to create a Supabase account and obtain an API key. You can sign up for a free Supabase account here.
Once you have your API key, you can use the Supabase Auth library to interact with the Supabase Auth API. Here's an example of how to create a user:
import cats.effect._
import com.eff3ct.supabase.auth.api._
import org.http4s.client._
import org.http4s.ember.client._
import org.http4s.implicits._
implicit val client: Resource[IO, Client[IO]] =
EmberClientBuilder.default[IO].build
for {
api <- SupabaseAuthAPI.create[IO](uri"https://your-supabase-url.supabase.co/auth/v1", "your-supabase-api-key")
user <- api.signUpWithEmail("user@example.com", "password")
} yield user
import cats.effect._
import cats.effect.unsafe.implicits.global
import com.eff3ct.supabase.auth.api._
import org.http4s.ember.client._
import org.http4s.implicits._
implicit val client: ClientR[IO] = EmberClientBuilder.default[IO].build
implicit val api: SupabaseAuthAPI[IO] =
SupabaseAuthAPI.create[IO](uri"https://your-supabase-url.supabase.co/auth/v1", "your-supabase-api-key")
.unsafeRunSync()
SupabaseAuthAPI[IO].signUpWithEmail("user@example.com", "password").unsafeRunSync()
Contributions are welcome! Please see the contributing guidelines for more information.
This project is licensed under the MIT License. See the LICENSE file for more information.