Skip to content

Commit

Permalink
Update README
Browse files Browse the repository at this point in the history
  • Loading branch information
sh0drun authored Oct 11, 2022
1 parent 191b702 commit fb1956a
Showing 1 changed file with 38 additions and 1 deletion.
39 changes: 38 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,40 @@
# BackendNoteBookChallenge

A simple notebook server that can execute pieces of python code in an interpreter using Spring Boot technology and Antler, it can interpret just expression statement, function and class definitions.
A simple notebook server that can execute pieces of python code in an interpreter using Spring Boot to expose API endpoints and Antler to parse code, it can interpret just expression statement, function and class definitions. All previous execuded python code gets saved with sessionId that was executed with, and if there is any error in the stored code, it will be shown in the output object.

this project doesn't contain any tests but it might has some in the future. Feel free to add test throught pull request

It can be tested with any rest client

Endpoints:
- Post /execute
- Request object (Example - first request):
```json
{
"code" : "print(\"Hello World\")",
"sessionId": "8upWRlfWL0WSJYoDqsjDIg=="
}
```
- Response object (Example):
```json
{
"result" : "Hello World",
"code": "",
"error": ""
}
```
- Request object (Example - second request):
```json
{
"code" : "2**3",
"sessionId": "8upWRlfWL0WSJYoDqsjDIg=="
}
```
- Response object (Example):
```json
{
"result" : "Hello World\n 8",
"code": "print(\"Hello World\")",
"error": ""
}
```

0 comments on commit fb1956a

Please sign in to comment.