I don’t completely get what you are trying to do:
a. Override an http error code: I’ve tried this and found that it’s always returning the default validation errors.
b. Make responses depending on parameters (like working with “when” on mocking frameworks): This is more complex. Since the RAML spec is not intended to write mocks, it doesn’t provide a way to describe this. It could be a feature to add to the mocking service by using some kind of metadata taken from other place.
For both cases, I’ve already opened the discussion with the teams and will keep you updated.