In the README, the following caveat is stated:
Only "200" and "201" responses are inspected for determining the expected return value for RPC endpoints.
Are there plans to support responses from other statuses?
I believe this can be achieved using the oneof construct. For example, instead of:
message FindPetsByIdsResponse {
message PetsMessage {
int64 id = 1;
string name = 2;
string tag = 3;
}
repeated PetsMessage pets = 1;
}
Assuming there's no $ref on the status code 404, this will become:
message FindPetsByIdsResponse {
message Message200 {
int64 id = 1;
string name = 2;
string tag = 3;
}
message Message404 {
}
oneof responses {
repeated Message200 pets = 1;
Message404 = 2;
}
}
Thoughts?
In the README, the following caveat is stated:
Are there plans to support responses from other statuses?
I believe this can be achieved using the oneof construct. For example, instead of:
Assuming there's no
$refon the status code404, this will become:Thoughts?