Skip to content

Commit

Permalink
docs(readme): Update readme
Browse files Browse the repository at this point in the history
  • Loading branch information
dajk committed Dec 31, 2017
1 parent a2bd79d commit de7d3e2
Showing 1 changed file with 23 additions and 11 deletions.
34 changes: 23 additions & 11 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -66,13 +66,17 @@ import {
```
##### News
- request
```js
app.get('/', (req, res) => {
getNews(news => res.json(news));
});
```
- request
```
http://localhost:3000/
```
- response
```json
[{
Expand All @@ -84,13 +88,17 @@ app.get('/', (req, res) => {
```
##### Results
- request
```js
app.get('/results', (req, res) => {
getResults(results => res.json(results));
});
```
- request
```
http://localhost:3000/results
```
- response
```json
[{
Expand All @@ -111,24 +119,28 @@ app.get('/results', (req, res) => {
```
##### Matches
- request
```js
app.get('/:matchId(*)', (req, res) => {
const { matchId } = req.params;
getMatches(matchId, (stats) => res.json(stats));
});
```
- request
```
http://localhost:3000/matches/2316387/fnatic-vs-faze-ecs-season-4-europe
```
- response
```json
[{
"playerName": "Robin ropz Kool",
"playerId": "/player/11816/ropz",
"kills": 38,
"deaths": 21,
"plusMinus": 17,
"adr": 97,
"kast": 77.8,
"rating": 1.46
"playerName": "Robin flusha Rönnquist",
"playerId": "/player/3055/flusha",
"kills": 19,
"deaths": 19,
"plusMinus": 0,
"adr": 73.7,
"kast": 62.1,
"rating": 0.97
}, ]
```

0 comments on commit de7d3e2

Please sign in to comment.