feat: open-trip-api-drink #11

Merged
Clement merged 34 commits from feat/open-trip-api into master 2024-05-19 09:38:39 +00:00
Showing only changes of commit 02dc74bb79 - Show all commits

View File

@ -1,4 +1,4 @@
import { getCity, getRadius, getPoiId } from "./openTripMaps"
import { getCity, getRadius, getPoiId, getBox } from "./openTripMaps"
import express from "express"
/**
* Initialize Express application instance.
@ -107,7 +107,7 @@ app.get("/otm/radius", getRadius)
* type: string
* responses:
* 200:
* description: Return a list of bars and coffee in city in geoJSON format
* description: Return the detaill of an POI in otm
* 400:
* description: Missing Argument Error
* 401:
@ -115,4 +115,53 @@ app.get("/otm/radius", getRadius)
*/
app.get("/otm/poidetaill", getPoiId)
/**
* @openapi
* /otm/box:
* get:
* summary: return the drinks in a box
* description: return the drinks in a defined box
* parameters:
* - name: lon1
* in: query
* required: true
* description: longitude 1 of the box
* schema:
* type: number
* minimum: -180
* maximum: 180
* - name: lat1
* in: query
* required: true
* description: latitude 1 of the box
* schema:
* type: number
* minimum: -90
* maximum: 90
* - name: lon2
* in: query
* required: true
* description: longitude 2 of the box
* schema:
* type: number
* minimum: -180
* maximum: 180
* - name: lat2
* in: query
* required: true
* description: latitude 2 of the box
* schema:
* type: number
* minimum: -90
* maximum: 90
* 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/box", getBox)
export default app