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

brabo-hi

04/08/2022, 2:13 PM
Could not find io.ktor:ktor-serialization-kotlinx-json:2.0.0-RC.1
a

Aleksei Tirman [JB]

04/08/2022, 2:14 PM
Please try version
2.0.0
.
b

brabo-hi

04/08/2022, 2:42 PM
thanks looks compiling, however
Copy code
install(ContentNegotiation) {
    json(Json {
}}
has been removed?
a

Aleksei Tirman [JB]

04/08/2022, 2:43 PM
No. It should work.
Please share your Gradle build script.
b

brabo-hi

04/08/2022, 2:46 PM
Copy code
Unresolved reference. None of the following candidates is applicable because of receiver type mismatch: 
public fun Configuration.json(json: Json = ..., contentType: ContentType = ...): Unit defined in io.ktor.serialization.kotlinx.json
a

Aleksei Tirman [JB]

04/08/2022, 2:48 PM
Please check what packages
json
and
Json
reside at.
The first one should from Ktor and the second from kotlinx.serialization.
b

brabo-hi

04/08/2022, 3:33 PM
working now, i had to import
import io.ktor.client.plugins.contentnegotiation
33 Views