feat: add ApiService for login functionality

This commit is contained in:
Cutiful 2025-06-05 13:14:42 +07:00
parent cc3326fe8d
commit a797e0084c

View File

@ -0,0 +1,21 @@
package com.syaroful.agrilinkvocpro.data.network
import com.syaroful.agrilinkvocpro.data.model.LoginResponse
import retrofit2.Response
import retrofit2.http.Body
import retrofit2.http.Header
import retrofit2.http.POST
data class LoginRequest(
val username: String,
val password: String
)
interface ApiService {
@POST("auth/login")
suspend fun login(
@Header("Authorization") authHeader: String,
@Body body: LoginRequest
): Response<LoginResponse>
}