🚸 Routing in the box

Co-authored-by: Amalie Erdal Mansåker <amalie.erdal.mansaker@nav.no>
Co-authored-by: Øydis Kind Refsum <oydis.kind.refsum@nav.no>
This commit is contained in:
Sindre Kjelsrud 2023-07-19 17:10:21 +02:00
parent eabfd2b291
commit 73215513a3
4 changed files with 25 additions and 6 deletions

View file

@ -48,7 +48,7 @@ fun configureRouting(): ApplicationEngine = embeddedServer(CIO, applicationEngin
val test = call.receive<Test>()
call.respond(status = HttpStatusCode.Created, message = test)
}
post("/nyFeil") {
post("/nyfeil") {
val feilmelding = call.receive<Feilmelding>()
feilmeldingRepository.lagre(feilmelding)
call.respond(status = HttpStatusCode.Created, message = "Feilmelding motatt og sendt til database")