function spec building

register now builds a function spec
for the served object. this spec, available at /functions
lists what functions can be called through the websocket

The plan is to use something (maybe bluebird promises) to
make calling these functions easier

Example: served object obj has function get_message

socket.get_message().then(...)