Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Prototype server and static client
tree: 1d9eb5b614

Fetching latest commit…

Cannot retrieve the latest commit at this time

Failed to load latest commit information.
assets
lib
public
.gitignore
README.md
package.json
server.js
spec.sample.json
spec.sampleBy2.json

README.md

Mirawatt Server

Initial deployment to nodejitsu

When it's up, you can find it here

jitsu deploy

To use custom domains with nodejitsu see http://dns.jit.su/

Initial deployment to cloudfoundry

When it's up, you can find it here

  • or - here (mw-spec)

    if not yet created... (add mongo later)

    vmc push mirawatt

    to push an update

    vmc update mirawatt

Boilerplate

Start from HTML5 mobile boilerplate index.html. Do not use it's build system, will try to minimise with express/connect.

  • index.html
  • add jQuery mobile, downgrade to jQ 1.6.4
  • icons and startup
  • js
  • mobile-boookmark-bubble
  • crossdomain
  • appcache

Timezones

Found this binding to time.h node-time.

Todo

Transport and RPC

curl command to straight POST

curl -X POST -H "Content-Type: application/json" -d @../mirawatt-client/example.json http://localhost:3000/incoming/daniel

curl command to invoke jsonrpc service

curl -H "Content-Type: application/json" -d '{ "jsonrpc": "2.0", "method": "zing", "params": [42], "id":2 }' http://localhost:3000/jsonrpc curl -H "Content-Type: application/json" -d '{ "jsonrpc": "2.0", "method": "get", "params": ["001DC9103902"], "id":3 }' http://mirawatt.cloudfoundry.com/jsonrpc

node client to invoke jsonrpc-service

node client.js

node client to invoke dnode-service (local-only)

Something went wrong with that request. Please try again.