Currently there is MethodStyle to set the case conventions for the REST interface. This is working fine for the methods. But I expected it to work for the parameters and the response as well. With the response I mean the field in a struct that is returned.

Example:

interface Api
{
    int fooBar(int fooBar);
}

When the method style is set to lowerUnderscored the above route is accessible as foo_bar. But the parameter needs to be fooBar. I would have expected the parameter to follow the same case conventions, i.e. foo_bar.

Same issue with the response:

struct Response
{
    int fooBar;
}

interface Api
{
    Response fooBar(int fooBar);
}

The JSON response for the above would look something like { "fooBar": 0 }. But I would expect it to follow the case conventions as in: { "foo_bar": 0 }.

I have not tried the behavior of the deserialization in a request, but I'm suspecting it has the same behavior.

Should the parameters and request/response follow the style set by MethodStyle or should those be separate settings?

/Jacob Carlborg