/* Options: Date: 2024-11-23 01:30:00 Version: 6.00 Tip: To override a DTO option, remove "//" prefix before updating BaseUrl: https://resourcelibrary.api.ashcompanies.com //Package: //AddServiceStackTypes: True //AddResponseStatus: False //AddImplicitVersion: //AddDescriptionAsComments: True IncludeTypes: HealthCheckRequest.* //ExcludeTypes: //InitializeCollections: True //TreatTypesAsStrings: //DefaultImports: java.math.*,java.util.*,net.servicestack.client.*,com.google.gson.annotations.*,com.google.gson.reflect.* */ import java.math.* import java.util.* import net.servicestack.client.* import com.google.gson.annotations.* import com.google.gson.reflect.* @Route("/health") open class HealthCheckRequest : IReturn { companion object { private val responseType = HealthReport::class.java } override fun getResponseType(): Any? = HealthCheckRequest.responseType } @DataContract open class HealthReport { @DataMember var entries:IReadOnlyDictionary? = null @DataMember var applicationStatus:HealthStatus? = null @DataMember var duration:TimeSpan? = null } @DataContract open class HealthReportEntry { @DataMember var status:HealthStatus? = null @DataMember var description:String? = null @DataMember var duration:TimeSpan? = null @DataMember var exception:Exception? = null @DataMember @SerializedName("data") var Data:IReadOnlyDictionary? = null } @Flags() @DataContract enum class HealthStatus(val value:Int) { @SerializedName("0") Healthy(0), @SerializedName("4") Degraded(4), @SerializedName("8") Unhealthy(8), }