Files
ENI-Kotlin/app/src/main/java/com/example/tpfilrouge/auth/AuthService.kt
2025-01-27 16:56:31 +01:00

19 lines
540 B
Kotlin

package com.example.tpfilrouge.auth
import com.example.tpfilrouge.api.RetrofitTools.Companion.retrofit
import com.example.tpfilrouge.api.ServiceResponseDTO
import com.example.tpfilrouge.article.Article
import retrofit2.http.Body
import retrofit2.http.GET
import retrofit2.http.POST
interface AuthService {
@POST("login")
suspend fun login(@Body loginRequestDTO: LoginRequestDTO) : ServiceResponseDTO<String>
object AuthApi {
val authService : AuthService by lazy { retrofit.create(AuthService::class.java) }
}
}