mirror of https://github.com/pelias/api.git
Peter Johnson
10 years ago
commit
b9db328ab6
5 changed files with 59 additions and 0 deletions
@ -0,0 +1,13 @@
|
||||
|
||||
var pkg = require('../package'); |
||||
|
||||
function controller( req, res ){ |
||||
res.json({ |
||||
name: pkg.name, |
||||
version: { |
||||
number: pkg.version |
||||
} |
||||
}); |
||||
} |
||||
|
||||
module.exports = controller; |
@ -0,0 +1,5 @@
|
||||
|
||||
var express = require('express'); |
||||
var app = express(); |
||||
|
||||
module.exports = app; |
@ -0,0 +1,7 @@
|
||||
|
||||
var app = require('./express'); |
||||
|
||||
// api root
|
||||
app.get( '/', require('./controller/index' ) ); |
||||
|
||||
app.listen( process.env.PORT || 3100 ); |
@ -0,0 +1,33 @@
|
||||
{ |
||||
"name": "pelias-api", |
||||
"author": "mapzen", |
||||
"version": "0.0.0", |
||||
"description": "Pelias API", |
||||
"homepage": "https://github.com/pelias/api", |
||||
"license": "MIT", |
||||
"main": "index.js", |
||||
"scripts": { |
||||
"start": "node index.js", |
||||
"test": "echo \"Error: no test specified\" && exit 0" |
||||
}, |
||||
"repository": { |
||||
"type": "git", |
||||
"url": "git://github.com/pelias/api.git" |
||||
}, |
||||
"keywords": [ |
||||
"pelias", |
||||
"elasticsearch", |
||||
"webview" |
||||
], |
||||
"bugs": { |
||||
"url": "https://github.com/pelias/api/issues" |
||||
}, |
||||
"engines": { |
||||
"node": ">=0.10.26", |
||||
"npm": ">=1.4.3", |
||||
"elasticsearch": ">=1.2.1" |
||||
}, |
||||
"dependencies": { |
||||
"express": "^4.8.8" |
||||
} |
||||
} |
Loading…
Reference in new issue