Closed anandology closed 3 years ago
The most common use case of LiveCode is to execute some code and get the result back. Dealing with websockets is quite an overkill for that.
Provide an endpoint that accepts as POST request with the code and returns the output as response.
POST /livecode { "runtime": "python", "code": "for i in range(5): print(i)" } --- 200 OK { "exit_status": 0, "output": "0\n1\n2\n3\n4\n" }
Implemented this in a slightly different way:
POST /livecode { "runtime": "python", "code": "for i in range(5): print(i)" } --- 200 OK 0 1 2 3 4
The most common use case of LiveCode is to execute some code and get the result back. Dealing with websockets is quite an overkill for that.
Provide an endpoint that accepts as POST request with the code and returns the output as response.