Skip to content
A simple Play application with Frege
Branch: master
Clone or download
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
Type Name Latest commit message Commit time
Failed to load latest commit information.
app/views
conf
project
public
src/main/frege/helloplay
test
.gitignore
LICENSE
README.md
activator
activator.bat
build.sbt

README.md

#A simple Play application with Frege# This is a simple play application written in Frege to demonstrate how we can use Frege with Play.

Since Play supports Java, it is actually very easy to use the Java API from Frege even though we don't have native Play support for Frege yet. The application is basically JSON-in and JSON-out. A Frege program reads a parameter from a JSON POST request and responds with a JSON response that greets the user.

##How to run##

  1. Run activator run to compile and start the server.

  2. Then send a JSON post request. For example, with curl:

    $ curl --header "Content-type: application/json" --request POST --data '{"name": "Play Frege"}' http://localhost:9000/greet
    
    {"message" : "Hello, Play Frege"}
    
    
You can’t perform that action at this time.