https://github.com/wenta/script-engine
Script Engine with the REST API
https://github.com/wenta/script-engine
Last synced: 11 months ago
JSON representation
Script Engine with the REST API
- Host: GitHub
- URL: https://github.com/wenta/script-engine
- Owner: wenta
- License: apache-2.0
- Created: 2017-07-11T14:03:56.000Z (about 9 years ago)
- Default Branch: master
- Last Pushed: 2017-07-20T08:15:25.000Z (about 9 years ago)
- Last Synced: 2025-04-08T12:50:33.921Z (over 1 year ago)
- Language: Scala
- Homepage:
- Size: 18.6 KB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# ScriptEngine
Script Engine based on the [FlowScript](http://github.com/carldata/flow-script).
Provides REST API for executing scripts
## Running the server
```bash
sbt assembly
java -jar target/scala-2.12/script-engine-assembly-0.1.0.jar
docker build -t script-engine:0.1.0 .
docker run -p 8080:8080 script-engine:0.1.0
```
In separate terminal execute function:
```bash
curl -H "Content-Type: application/json" -X POST -d '{"function":"Test1.main","params":[23]}' http://localhost:8080/api/execute
```
This should return (Check script 'scripts/Test1.fs' for the details):
```bash
{result: 23}
```
## Installing flow-script dependencies
Since FlowScript is not yet published to the external repository, it is necessary to publish flow-script project
to the local repository with the command (do it inside the flow-script project)
```bash
sbt publish-local
```
# Join in!
We are happy to receive bug reports, fixes, documentation enhancements,
and other improvements.
Please report bugs via the
[github issue tracker](http://github.com/carldata/script-engine/issues).
# Redistributing
Script Engine source code is distributed under the Apache-2.0 license.
**Contributions**
Unless you explicitly state otherwise, any contribution intentionally submitted
for inclusion in the work by you, as defined in the Apache-2.0 license, shall be
licensed as above, without any additional terms or conditions.