apigateway
``` { "uri": "/applepen/:id", "method": "get", "req": { "pen": { "url": "https://chaus.herokuapp.com/apis/apigateway/pens/:params.id", "req": { "name": "query.name", "token": "cookies.token" } }, "apple"
Last updated 3 years ago by sideroad .
ISC · Original npm · Tarball · package.json
$ cnpm install apigateway 
SYNC missed versions from official npm registry.

Prepare configure files under some directory

{
  "uri": "/applepen/:id",
  "method": "get",
  "req": {
    "pen": {
      "url": "https://chaus.herokuapp.com/apis/apigateway/pens/:params.id",
      "req": {
        "name": "query.name",
        "token": "cookies.token"
      }
    },
    "apple": {
      "url": "https://chaus.herokuapp.com/apis/apigateway/apples/:params.id"
    }
  },
  "res": {
    "id": "pen.id",
    "pen": "pen.name",
    "apple": "apple.name",
    "taste": "apple.taste"
  }
}

Setup server

specify directory and port

apigateway config 3000

Current Tags

  • 1.0.1                                ...           latest (3 years ago)

2 Versions

  • 1.0.1                                ...           3 years ago
  • 1.0.0                                ...           3 years ago
Maintainers (1)
Downloads
Today 0
This Week 0
This Month 0
Last Day 0
Last Week 2
Last Month 3
Dependencies (7)
Dev Dependencies (0)
None
Dependents (0)
None

Copyright 2014 - 2016 © taobao.org |