openapi.yaml 1.4 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465
  1. openapi: 3.0.4
  2. info:
  3. title: API Documentation | ChatRPG
  4. version: 1.0.0
  5. description: API fro ChatRPG
  6. servers:
  7. - url: http://localhost:8000
  8. description: Development/local server
  9. tags:
  10. - name: User
  11. - name: Game
  12. - name: Character
  13. components:
  14. schemas:
  15. User:
  16. $ref: "./components/schemas/user.yaml"
  17. Game:
  18. $ref: "./components/schemas/game.yaml"
  19. Character:
  20. $ref: "./components/schemas/character.yaml"
  21. Session:
  22. $ref: "./components/schemas/session.yaml"
  23. Turn:
  24. $ref: "./components/schemas/turn.yaml"
  25. responses:
  26. "400":
  27. $ref: "./components/responses/400.yaml"
  28. "401":
  29. $ref: "./components/responses/401.yaml"
  30. "403":
  31. $ref: "./components/responses/403.yaml"
  32. "404":
  33. $ref: "./components/responses/404.yaml"
  34. "500":
  35. $ref: "./components/responses/500.yaml"
  36. securitySchemes:
  37. $ref: "./components/security.yaml"
  38. paths:
  39. #Users
  40. /user:
  41. post:
  42. $ref: "./paths/user/create.yaml"
  43. get:
  44. $ref: "./paths/user/get_one.yaml"
  45. /user/login:
  46. post:
  47. $ref: "./paths/user/login.yaml"
  48. /user/logout:
  49. get:
  50. $ref: "./paths/user/logout.yaml"
  51. /user/payment-intent:
  52. post:
  53. $ref: "./paths/user/payment_intent.yaml"
  54. #Game
  55. /game:
  56. post:
  57. $ref: "./paths/game/create.yaml"
  58. /game/{game_id}/character:
  59. post:
  60. $ref: "./paths/game/character/create.yaml"