Problem
When the compiler infers a Standard Schema success response, it resolves the status but leaves the OpenAPI response description empty unless the consumer adds an explicit Swagger decorator. Consumers then repeat standard reason phrases such as OK and Created on every handler.
Expected behavior
When no description is explicitly supplied, inferred Swagger response metadata should derive the standard reason phrase from the resolved status.
Acceptance criteria
- An inferred 200 response has
description: "OK".
- An inferred 201 response has
description: "Created".
- A statically resolved custom
@HttpCode(...) uses the corresponding standard reason phrase.
- An explicitly supplied description always wins.
- Runtime serialization behavior is unchanged.
- Compiler and runnable-example tests cover the behavior.
Problem
When the compiler infers a Standard Schema success response, it resolves the status but leaves the OpenAPI response description empty unless the consumer adds an explicit Swagger decorator. Consumers then repeat standard reason phrases such as
OKandCreatedon every handler.Expected behavior
When no description is explicitly supplied, inferred Swagger response metadata should derive the standard reason phrase from the resolved status.
Acceptance criteria
description: "OK".description: "Created".@HttpCode(...)uses the corresponding standard reason phrase.