`POST <http://localhost:1296/search> 415 (Unsuppor...
# ktor
h
POST <http://localhost:1296/search> 415 (Unsupported Media Type)
m
Copy code
install(JsonFeature) {
            serializer = KotlinxSerializer(Json.nonstrict).apply {
                setMapper(YourClass::class, ClaimInput.serializer())
            }
        }
?
Ah, you might also need
contentType(ContentType.Application.Json)
Copy code
<http://client.post|client.post>("<http://localhost:1296/search>") {
        body = postData
        contentType(ContentType.Application.Json)
    }
h
@mbonnin i mean my server post accept json
m
Ah, server side sorry I haven't used that part yet
h
all good.
h
@cy i thought about looking more into CN right as you sent it hahaha. I just learnt that it can also be used to parse requests. Thank you for responding! Much appreciated