This application provides a REST API allowing users to get port similarities on different time windows.
This API allows multiple features:
Each day, four new datasets are added to this API.
Thus each one need a specific designation in order to be uniquely addressable.
The selected designation for a dataset from 15 March 2018 to 21 March 2018 is : sim-20180315-20180321
Returns existing time windows
Request |
GET /api/timewindows
|
---|---|
Example Request |
GET /api/timewindows
|
Example Response |
|
Returns time window distance dataset as a CSV file
Request format |
GET /api/timewindow/:designation
|
---|---|
Parameters |
|
Example Request |
GET /api/timewindow/sim-20180315-20180321
|
Example Response |
If the dataset exists, you are redirected to the appropriate file
compressed in GZ format.
Otherwise, an HTTP 404 is returned
The given CSV file contains the 50.000.000 lowest semantic distances for the selected time
window
CSV columns are :
|
Returns a list of integer representing port numbers
Request format |
GET /api/timewindow/:designation/ports
|
---|---|
Parameters |
|
Example Request |
GET /api/timewindow/sim-20180315-20180321/ports
|
Example Response |
The following response is returned if the dataset exists :
Otherwise, an HTTP 404 is returned
|
Returns JSON object containing information about distance between the two ports
Request format |
GET /api/timewindow/:designation/distance/:from/:to
|
---|---|
Parameters |
|
Example Request |
GET
/api/timewindow/sim-20180315-20180321/distance/80/443
|
Example Response |
The following response is returned if the two ports exists and the dataset exists :
Otherwise, an HTTP 404 is returned
|