android - Retrofit2: @Path parameter in OkHttp Interceptor -


in our api have sign based on both @query , @path parameters. suggests use okhttp interceptor this. fine query params, don't think there way path parameter values , names. example:

/api/{version}/books/{id} /api/v1.1/books/10 

to make correct sign, need map:

{"id":"10", "version":"v1.1"} 

am missing something?

follow following code, problem solved.

/api/{version}/books/{id}

public type method(@path("version") string versionvalue,@path("id") string idvalue,.....)