package com.kryptnostic.storage.v1.client;

import retrofit.http.Body;
import retrofit.http.GET;
import retrofit.http.POST;

import com.kryptnostic.kodex.v1.exceptions.types.ResourceNotFoundException;
import com.kryptnostic.kodex.v1.models.response.BasicResponse;
import com.kryptnostic.multivariate.gf2.SimplePolynomialFunction;

public interface SearchFunctionApi {
    String SEARCH_FUNCTION = "/searchFunction";
    
    @POST(SEARCH_FUNCTION)
    BasicResponse<Boolean> setFunction(@Body SimplePolynomialFunction function);
    
    @GET(SEARCH_FUNCTION)
    BasicResponse<SimplePolynomialFunction> getFunction() throws ResourceNotFoundException;
}

@@ -322,16 +322,93 @@
 unction;
+%0Aimport com.kryptnostic.search.v1.models.request.SearchFunctionUploadRequest;
 %0A%0Apublic
@@ -568,40 +568,42 @@
 dy S
-implePolynomialFunction function
+earchFunctionUploadRequest request
 );%0A 

update API to take request instead of raw SPF search function