data.js 1.7 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566
  1. window.data = [
  2. {
  3. type: "object",
  4. title: "User",
  5. id: "user",
  6. auth: false,
  7. description: "User object",
  8. properties: [
  9. {
  10. name: "id",
  11. type: "String",
  12. desc: "Unique user ID"
  13. },
  14. {
  15. name: "name",
  16. type: "String",
  17. desc: "User name"
  18. },
  19. {
  20. name: "workouts",
  21. type: [Object],
  22. desc: "List of workouts. Includes name of the workout and list of exercises"
  23. },
  24. {
  25. name: "workouts.name",
  26. type: "String",
  27. desc: "Name of the workout"
  28. },
  29. {
  30. name: "workouts.exercises",
  31. type: "[String]",
  32. desc: "List of strings, each one being the name of an exercise"
  33. }
  34. ]
  35. },
  36. {
  37. type: "route",
  38. id: "createUser",
  39. title: "Create",
  40. url: "POST /user",
  41. auth: false,
  42. description: "Create a new user",
  43. requestBody: [
  44. {
  45. name: "name",
  46. type: "String",
  47. desc: "User name"
  48. },
  49. {
  50. name: "email",
  51. type: "String",
  52. desc: "User email address"
  53. },
  54. {
  55. name: "pass",
  56. type: "String",
  57. desc: "User password"
  58. },
  59. {
  60. name: "confirmPass",
  61. type: "String",
  62. desc: "Confirmation password"
  63. }
  64. ]
  65. }
  66. ]