Response Definition
open class ResponseDefinition<T>(contentType: ContentType = ContentType.Application.Json, val body: T? = null, httpStatus: HttpStatusCode = HttpStatusCode.OK, headers: ResponseHeaders.() -> Unit? = null, delay: Duration, formatter: HttpFormatter) : AbstractResponseDefinition<T> (source)
Represents a concrete implementation of an HTTP response definition with a specific response body. This class builds on the AbstractResponseDefinition to provide additional configuration and behavior.
Author
Konstantin Pavlov
Type Parameters
T
The type of the response body.
Constructors
Link copied to clipboard
constructor(contentType: ContentType = ContentType.Application.Json, body: T? = null, httpStatus: HttpStatusCode = HttpStatusCode.OK, headers: ResponseHeaders.() -> Unit? = null, delay: Duration, formatter: HttpFormatter)