Skip to content

Glossary: Kotlin Beyond the Basics

status code

Also written: HttpStatusCode, 200 OK, 201 Created, 400 Bad Request, 404 Not Found, 415 Unsupported Media Type

A response's number saying how the request went: 200 OK (worked), 201 Created (new thing stored), 400 Bad Request (request is wrong), 404 Not Found (nothing at that path), 415 Unsupported Media Type (missing JSON Content-Type). Ktor names them in `HttpStatusCode`, such as `HttpStatusCode.NotFound`.

Where the book teaches it

Related terms

HTTPBadRequestException