Skip to content


Subversion checkout URL

You can clone with
Download ZIP
Fetching latest commit...
Cannot retrieve the latest commit at this time.
Failed to load latest commit information.

To run this example:

First install all the depedencies

  npm install .

Next start the example:

  node app.js

Now visit http://localhost:3000/ in your browser

Next steps - Things to try doing with the example:

  1. Visit the documentation page and run all the examples

  2. Open the JavaScript console in your browser and use the API

   UserService.create({ name: "user", email:"", password:"foofoo"},function(err,result){ console.log(err,result}; });
  1. Generate the shell script stub
  # This will generate a shell script which uses 'curl' to call our API
  ../../bin/hopjs-gen --url http://localhost:3000/ shell --output
  chmod 755 ./

  # Now let's use the command line to create a user
  ./ UserService.create --APIURL http://localhost:3000/ --email --password foofoo --name user

  # Now we'll generate the unit test for this stub
  ../../bin/hopjs-gen --url http://localhost:3000/ shell --unitTest --output 
  chmod 755 ./

  ./ http://localhost:3000/ ./


Run app.js with node-dev instead of node, it will automatically restart the server when you make changes to the code

sudo npm install -g node-dev

node-dev app.js
Something went wrong with that request. Please try again.