add route and swagger doc
All checks were successful
All checks were successful
This commit is contained in:
parent
9ac4ba7252
commit
ae9e1eae47
@ -1,4 +1,4 @@
|
|||||||
import { getCity, getRadius } from "./openTripMaps"
|
import { getCity, getRadius, getPoiId } from "./openTripMaps"
|
||||||
import express from "express"
|
import express from "express"
|
||||||
/**
|
/**
|
||||||
* Initialize Express application instance.
|
* Initialize Express application instance.
|
||||||
@ -91,4 +91,28 @@ app.get("/otm/city", getCity)
|
|||||||
*/
|
*/
|
||||||
app.get("/otm/radius", getRadius)
|
app.get("/otm/radius", getRadius)
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @openapi
|
||||||
|
* /otm/poidetaill:
|
||||||
|
* get:
|
||||||
|
* summary: detail of a POI
|
||||||
|
* description: detail of a POI link name, kind, rate,...
|
||||||
|
* parameters:
|
||||||
|
* - name: id
|
||||||
|
* in: query
|
||||||
|
* required: true
|
||||||
|
* description: Unique identifier of the object in OpenTripMap
|
||||||
|
* schema:
|
||||||
|
* type: string
|
||||||
|
* responses:
|
||||||
|
* 200:
|
||||||
|
* description: Return a list of bars and coffee in city in geoJSON format
|
||||||
|
* 400:
|
||||||
|
* description: Missing Argument Error
|
||||||
|
* 401:
|
||||||
|
* description: Missing OTM tocken
|
||||||
|
*/
|
||||||
|
app.get("/otm/poidetaill", getPoiId)
|
||||||
|
|
||||||
export default app
|
export default app
|
Loading…
x
Reference in New Issue
Block a user