Q:

Node JS push server send/receive

I am trying to set up a node js server to do push notifications to my browser app. I have a basic example working, but I am wondering how to send data up to the server from the client on handshake. 
I Need to send to the server something like a user id, so when a notification comes in for them, it can be routed back to the user. 
my server looks something like this
var app = require('http').createServer(handler)
  , io = require('socket.io').listen(app)
  , fs = require('fs');

app.listen(8000);

function handler ( req, res ) {
    res.writeHead( 200 );
    res.end('node working');
};

io.sockets.on( 'connection', function ( socket ) {

  socket.volatile.emit( 'notification' , "blah" );
});

and my client looks something like this
 var socket = io.connect('http://localhost:8000');

  socket.on('notification', function (data) {
    //prints data here
  });

A:

In socket.io, the emit is essentially like any other event handler (e.g. jQuery's .on('click'...)); you declare the event and send the data. On the server, you add the .on('event', ...) to catch the request and process it.
The socket.io front page shows this example for the server:
var io = require('socket.io').listen(80);

io.sockets.on('connection', function (socket) {
  socket.emit('news', { hello: 'world' });
  socket.on('my other event', function (data) {
    console.log(data);
  });
});

And this for the client:
<script src="/socket.io/socket.io.js"></script>
<script>
  var socket = io.connect('http://localhost');
  socket.on('news', function (data) {
    console.log(data);
    socket.emit('my other event', { my: 'data' });
  });
</script>

It sounds like the part you're looking for is the socket.emit portion.

