Update docimentation

This commit is contained in:
rui hildt 2020-02-09 20:47:45 +01:00
parent b659af9cb4
commit f9c5eeecf5

View File

@ -18,7 +18,7 @@ ___
**`GET /api/countries/:country_id`**
##### Response
A json object with a list of cities in the selected country `name` and `id` and `country_id`.
An array of json objects with a list of cities in the selected country with `name`, `id` and `country_id`.
```
[
@ -51,14 +51,16 @@ A json object with a list of cities in the selected country `name` and `id` and
**`GET /api/cities`**
##### Response
A json object with `id`, `name` and `country_id`.
An array of json objects with `id`, `name` and `country_id`.
```
{
"id": 1,
"name": 'bruges',
"country_id": 1
}
[
{
"id": 1,
"name": 'bruges',
"country_id": 1
}
]
```
### ROADS **`roads`**
@ -73,15 +75,17 @@ A json object with `id`, `name` and `country_id`.
**`GET /api/roads`**
##### Response
A json object with `id`, `start_city_id`, 'end_city_id` and `distance`.
A array of json objects with `id`, `start_city_id`, 'end_city_id` and `distance`.
```
{
"id": 1,
"start_city_id": 1,
"end_city_id": 3,
"distance": 50
}
[
{
"id": 1,
"start_city_id": 1,
"end_city_id": 3,
"distance": 50
}
]
```
### Shortest Path **`cities`**