HttpErrorResponseException
open class HttpErrorResponseException(val status: HttpStatusCode, val headers: Headers, val responseBody: String, val oauth2Error: OAuth2Error?, val problemDetails: ProblemDetails?) : IllegalStateException(source)
A non-success HTTP response with its OAuth or RFC 9457 error details, when available.
Extends IllegalStateException, as its ktor-based predecessor did by extending ktor's ResponseException.
Constructors
Link copied to clipboard
constructor(status: HttpStatusCode, headers: Headers, responseBody: String, oauth2Error: OAuth2Error?, problemDetails: ProblemDetails?)
Parses oauth2Error from responseBody, and problemDetails if the response has the media type application/problem+json.