You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Spring Boot backend with RESTful APIs, session management via Supabase
⭐️ About
This project demonstrate how to integrate Supabase to a RESTful service built with Spring Boot. This backend plays as a middleware to handle requests from multiple clients via RESTful API then interact with Supabase. The common use case is using this service to public APIs to multiple clients so that each client does not have to interact with Supabase via specific SDK.
Tip
If you want to see the more about Supabase Kotlin Multiplatform samples, check out the supabase-kt repository.
⚙️ Setup
Get started with Spring Boot project with Spring Initializr, select Kotlin and Java 17 (JVM)
Add dependencies to build.gradle
val ktor_version ="2.3.10"
implementation("io.ktor:ktor-client-core:$ktor_version")
implementation("io.ktor:ktor-client-java:$ktor_version")
implementation("io.ktor:ktor-client-cio:$ktor_version")
val supabaseVersion ="2.4.0"
implementation(platform("io.github.jan-tennert.supabase:bom:$supabaseVersion"))
implementation("io.github.jan-tennert.supabase:gotrue-kt")
implementation("io.github.jan-tennert.supabase:postgrest-kt")
implementation("io.github.jan-tennert.supabase:storage-kt")
implementation("io.github.jan-tennert.supabase:serializer-jackson:$supabaseVersion")
Create SupabaseConfiguration class to provide Supabase client instance: