Hey guys! Do you know a tool, framework or techniq...
# random
f
Hey guys! Do you know a tool, framework or technique for evaluate a kotlin code to Slack channel?
g
I don't know any ready to use solution, but it should be straightforward to implement using Kotlin Playground server and slack bot api https://github.com/JetBrains/kotlin-web-demo
❤️ 1
f
Thanks Andrey!
g
Also see sources of new playground, it has links on 2 version of server implementation and new UI https://github.com/JetBrains/kotlin-playground
But you also can just reuse existing server if you don’t need custom libraries in classpath, it allows external requests:
Copy code
curl '<https://api.kotlinlang.org/api/1.3.72/compiler/run>' \
    -H 'content-type: application/json' \
    --data-binary '{"files":[{"name":"File.kt", "text":"fun main() { println(\"Hello World!\") }"}]}'
f
Wow! That’s it Many thanks @gildor