Skip to content

Instantly share code, notes, and snippets.

@richy486
Created September 2, 2013 00:08
Show Gist options
  • Save richy486/6408152 to your computer and use it in GitHub Desktop.
Save richy486/6408152 to your computer and use it in GitHub Desktop.
var express = require('express');
var app = express();
app.get('/stuff', function(req, res) {
res.send(
{
"options": {
"something": "1234"
},
"batman":
[
{"value": "18934675"},
{"value": "gfo4"},
{"value": "vih3"}
]
}
);
});
app.get('/products/:id', function(req, res) {
res.send({id:req.params.id, name: "The Name", description: "description"});
});
app.listen(3000);
console.log('Listening on port 3000...');
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment