diff --git a/What_The_Fantasy/app/src/main/java/com/example/what_the_fantasy/data/retrofit/ApiService.kt b/What_The_Fantasy/app/src/main/java/com/example/what_the_fantasy/data/retrofit/ApiService.kt index 3b570eb..b3002de 100644 --- a/What_The_Fantasy/app/src/main/java/com/example/what_the_fantasy/data/retrofit/ApiService.kt +++ b/What_The_Fantasy/app/src/main/java/com/example/what_the_fantasy/data/retrofit/ApiService.kt @@ -1,5 +1,6 @@ package com.example.what_the_fantasy.data.retrofit +import com.example.what_the_fantasy.data.model.Quote import com.example.what_the_fantasy.data.model.SrcLanguage import com.example.what_the_fantasy.data.model.User import retrofit2.Response @@ -51,6 +52,13 @@ interface UserApiService { ): Response } +interface QuoteApiService { + @GET("quote/{id}") + suspend fun getQuoteById(@Path("id")id : Int):Quote + @GET("quote/all") + suspend fun getAllQuote( @Query("index") index: Int, @Query("count") count: Int):List + +} object RetrofitInstance { private const val BASE_URL = "https://codefirst.iut.uca.fr/containers/WhatTheFantasy-web-services/api/v1/"