Advertisement
Guest User

Beep Beep statististics

a guest
Nov 18th, 2018
178
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
HTML 4.02 KB | None | 0 0
  1. swagger: "2.0"
  2. info:
  3.   description: "This is a statistics web server for the Beep Beep application for retrieving statistics about your runs in a visual graphical format. For more information, visit the Github repository: https://github.com/MFranceschi6/BeepBeep-statistics"
  4.   version: "1.0.0"
  5.   title: "Beep Beep-Statistics"
  6.   termsOfService: "https://github.com/MFranceschi6/BeepBeep-statistics"
  7.   contact:
  8.     email: "daniele.gadler@yahoo.it"
  9.   license:
  10.     name: "Apache 2.0"
  11.     url: "http://www.apache.org/licenses/LICENSE-2.0.html"
  12. host: "localhost:5000"
  13. basePath: "/"
  14. tags:
  15. - name: "statistics"
  16.   description: "View graphical statistics of all your Strava runs"
  17.   externalDocs:
  18.     description: "Find out more"
  19.     url: "http://www.strava.com"
  20. schemes:
  21. - "http"
  22. paths:
  23.   /statistics/{userID}:
  24.     get:
  25.       tags:
  26.       - "statistics"
  27.       summary: "Find statistics for a certain user ID"
  28.       description: "By accessing this page and providing an existing user ID, you retrieve a set of 5 arrays, respectively the temporal statistics of your runs for the following attributes, respectively: 'distance', 'average speed', 'average heartrate'. 'total elevation gain', 'elapsed time'."
  29.       operationId: "getStatisticsbyUserID"
  30.       produces:
  31.       - "application/xml"
  32.       - "application/json"
  33.       parameters:
  34.       - name: "userID"
  35.         in: "path"
  36.         description: "User ID of the user whose statistics you want to return."
  37.         required: true
  38.         type: "integer"
  39.         format: "int64"
  40.       responses:
  41.         200:
  42.           description: "successful operation"
  43.           schema:
  44.             $ref: "#/definitions/User"
  45.         400:
  46.           description: "Invalid user ID supplied"
  47.         404:
  48.           description: "User not found for the user ID suppied. "
  49.       security:
  50.       - api_key: []
  51.   /statistics/{userID}/{statisticsID}:
  52.     get:
  53.       tags:
  54.       - "statistics"
  55.       summary: "Find statistics for a certain user ID"
  56.       description: "By accessing this page and providing an existing user ID, you retrieve a set of 5 arrays, respectively the temporal statistics of your runs for the following attributes, respectively: 'distance', 'average speed', 'average heartrate'. 'total elevation gain', 'elapsed time'."
  57.       operationId: "getCertainStatisticsbyUserID"
  58.       produces:
  59.       - "application/xml"
  60.       - "application/json"
  61.       parameters:
  62.       - name: "userID"
  63.         in: "path"
  64.         description: "User ID of the user whose statistics you want to return."
  65.         required: true
  66.         type: "integer"
  67.         format: "int64"
  68.       - name: "statisticsID"
  69.         in: "path"
  70.         description: "Statistics ID of the statistics type you want to return. 1 = distance; 2 = average speed; 3 = average heartrate; 4 = total elevation gain; 5 = elapsed time."
  71.         required: true
  72.         type: "integer"
  73.         format: "int64"
  74.       responses:
  75.         200:
  76.           description: "successful operation"
  77.           schema:
  78.             $ref: "#/definitions/User"
  79.         400:
  80.           description: "Invalid user ID or statistics ID supplied"
  81.         404:
  82.           description: "User not found for the user ID supplied. "
  83.       security:
  84.       - api_key: []
  85. securityDefinitions:
  86.   api_key:
  87.     type: "apiKey"
  88.     name: "api_key"
  89.     in: "header"
  90. definitions:
  91.   User:
  92.     type: "object"
  93.     properties:
  94.       id:
  95.         type: "integer"
  96.         format: "int64"
  97.       firstName:
  98.         type: "string"
  99.       lastName:
  100.         type: "string"
  101.       email:
  102.         type: "string"
  103.       password:
  104.         type: "string"
  105.       age:
  106.         type: "integer"
  107.         format: "int64"
  108.       weight:
  109.         type: "number"
  110.         format: "float64"
  111.       max_hr:
  112.         type: "integer"
  113.         format: "int64"
  114.       rest_hr:
  115.         type: "integer"
  116.         format: "int64"
  117.       vo2max:
  118.         type: "number"
  119.         format: "float64"
  120.     xml:
  121.       name: "User"
  122. externalDocs:
  123.   description: "Find out more about Swagger"
  124.   url: "http://swagger.io"
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement