pid를 심어놓은 광고를 타고 들어온 경우 항상 AppLaunch 이벤트를 실행하는 코드 추가
This commit is contained in:
@@ -0,0 +1,11 @@
|
||||
package kr.co.vividnext.sodalive.tracking
|
||||
|
||||
import io.reactivex.rxjava3.core.Single
|
||||
import kr.co.vividnext.sodalive.common.ApiResponse
|
||||
import retrofit2.http.Body
|
||||
import retrofit2.http.POST
|
||||
|
||||
interface AdTrackingApi {
|
||||
@POST("/ad-tracking/app-launch")
|
||||
fun appLaunch(@Body request: AdTrackingAppLaunchRequest): Single<ApiResponse<Any>>
|
||||
}
|
||||
@@ -0,0 +1,9 @@
|
||||
package kr.co.vividnext.sodalive.tracking
|
||||
|
||||
import androidx.annotation.Keep
|
||||
import com.google.gson.annotations.SerializedName
|
||||
|
||||
@Keep
|
||||
data class AdTrackingAppLaunchRequest(
|
||||
@SerializedName("pid") val pid: String
|
||||
)
|
||||
@@ -0,0 +1,5 @@
|
||||
package kr.co.vividnext.sodalive.tracking
|
||||
|
||||
class AdTrackingRepository(private val api: AdTrackingApi) {
|
||||
fun appLaunch(pid: String) = api.appLaunch(request = AdTrackingAppLaunchRequest(pid = pid))
|
||||
}
|
||||
Reference in New Issue
Block a user