https://kotlinlang.org logo
#ktor
Title
# ktor
j

JPilson Sumbo

02/08/2023, 7:27 PM
Guys I’m trying to implement a post test but can’t get body request work The documentation says we need to install content type
Copy code
val client = createClient {
        install(ContentNegotiation) {
            json()
        }
    }
but this causes a problem
Unit' can't be called in this context by implicit receiver
Does anyone knows how to solve this?
a

Aleksei Tirman [JB]

02/08/2023, 7:33 PM
Can you check that you’ve imported the ContentNegotiation client plugin?
1
j

JPilson Sumbo

02/08/2023, 7:36 PM
Oh yes , the had to use the Client Plugin thanks
4 Views