diff --git a/android/backend/src/main/java/net/buzzert/kordophone/backend/server/APIInterface.kt b/android/backend/src/main/java/net/buzzert/kordophone/backend/server/APIInterface.kt index 821f0f8..71a0142 100644 --- a/android/backend/src/main/java/net/buzzert/kordophone/backend/server/APIInterface.kt +++ b/android/backend/src/main/java/net/buzzert/kordophone/backend/server/APIInterface.kt @@ -55,13 +55,13 @@ data class UploadAttachmentResponse( ) interface APIInterface { - @GET("/version") + @GET("version") suspend fun getVersion(): ResponseBody - @GET("/conversations") + @GET("conversations") suspend fun getConversations(): Response> - @GET("/messages") + @GET("messages") suspend fun getMessages( @Query("guid") conversationGUID: String, @Query("limit") limit: Int? = null, @@ -69,19 +69,19 @@ interface APIInterface { @Query("afterMessageGUID") afterMessageGUID: GUID? = null, ): Response> - @POST("/sendMessage") + @POST("sendMessage") suspend fun sendMessage(@Body request: SendMessageRequest): Response - @POST("/markConversation") + @POST("markConversation") suspend fun markConversation(@Query("guid") conversationGUID: String): Response - @GET("/attachment") + @GET("attachment") suspend fun fetchAttachment(@Query("guid") guid: String, @Query("preview") preview: Boolean = false): ResponseBody - @POST("/uploadAttachment") + @POST("uploadAttachment") suspend fun uploadAttachment(@Query("filename") filename: String, @Body body: RequestBody): Response - @POST("/authenticate") + @POST("authenticate") suspend fun authenticate(@Body request: AuthenticationRequest): Response } @@ -93,4 +93,4 @@ fun Response.bodyOnSuccessOrThrow(): T { } throw ResponseDecodeError(errorBody()!!) -} \ No newline at end of file +}