commonMain.io.github.jan.supabase.postgrest.request.RpcRequest.kt Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of postgrest-kt-jvm Show documentation
Show all versions of postgrest-kt-jvm Show documentation
Extends supabase-kt with a Postgrest Client
package io.github.jan.supabase.postgrest.request
import io.github.jan.supabase.postgrest.query.Count
import io.ktor.http.HttpMethod
import kotlinx.serialization.json.JsonElement
@PublishedApi
internal class RpcRequest(
override val method: HttpMethod,
val count: Count? = null,
override val urlParams: Map,
override val body: JsonElement? = null,
) : PostgrestRequest {
override val schema: String = ""
override val prefer = if (count != null) listOf("count=${count.identifier}") else listOf()
}