package lu.circl.mispbump.restful_client; import java.util.List; import retrofit2.Call; import retrofit2.http.Body; import retrofit2.http.GET; import retrofit2.http.POST; import retrofit2.http.Path; /** * RetroFit2 interface for communication with misp instances */ public interface MispRestService { // settings routes @GET("servers/getPyMISPVersion") Call pyMispVersion(); // user routes @GET("users/view/me") Call getMyUserInformation(); @GET("users/view/{value}") Call getUser(@Path("value") int userId); @POST("admin/users/add") Call addUser(@Body User user); // organisation routes @GET("organisations/view/{value}") Call getOrganisation(@Path("value") int orgId); @GET("organisations") Call> getAllOrganisations(); @POST("admin/organisations/add") Call addOrganisation(@Body Organisation organisation); // server routes @GET("servers/index") Call> getServers(); // @POST("servers/add") // Call addServer(@Body MispServer server); @POST("servers/add") Call addServer(@Body Server server); }