swagger3 project.yml 25 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851852853854855856857858859860861862863864865866867868869870871872873874875876877878879880881882883884885886887888889890891892893894895896897898899900901902903904905906907908909910911912913914915916917918919920921922923924925926927928929930931932933934935936937938939940941942943944945946947948949950951952953954955956
  1. openapi: 3.0.1
  2. info:
  3. title: Project API
  4. description: |
  5. Latihan Project API
  6. - CRUD Project
  7. - Platform Relationship
  8. - Auth
  9. - Membership & Ownership
  10. - Rights & Paging
  11. version: 5.0.0
  12. servers:
  13. - url: http://localhost:8080/api/v1
  14. tags:
  15. - name: projects
  16. description: everything project
  17. - name: platforms
  18. description: everything platform
  19. - name: users
  20. description: everything user
  21. paths:
  22. /projects:
  23. get:
  24. tags:
  25. - projects
  26. summary: find all project
  27. description: return all project
  28. operationId: getProject
  29. parameters:
  30. - $ref: '#/components/parameters/page'
  31. - $ref: '#/components/parameters/limit'
  32. - name: sort
  33. in: query
  34. description: sort direction (default 'project_id, desc')
  35. schema:
  36. type: string
  37. responses:
  38. 200:
  39. $ref: '#/components/responses/getArrayProject'
  40. 400:
  41. $ref: '#/components/responses/400'
  42. 401:
  43. $ref: '#/components/responses/UnauthorizedError'
  44. security:
  45. - testAuth: []
  46. post:
  47. tags:
  48. - projects
  49. summary: Add new Project
  50. description: Add new Project
  51. operationId: addProject
  52. requestBody:
  53. $ref: '#/components/requestBodies/Project'
  54. responses:
  55. 201:
  56. $ref: '#/components/responses/successAddProject'
  57. 400:
  58. $ref: '#/components/responses/400'
  59. 401:
  60. $ref: '#/components/responses/UnauthorizedError'
  61. 409:
  62. $ref: '#/components/responses/409'
  63. 413:
  64. $ref: '#/components/responses/413'
  65. security:
  66. - testAuth: []
  67. /projects/{projectId}:
  68. get:
  69. tags:
  70. - projects
  71. summary: find project by ID
  72. description: return project
  73. operationId: getProjectById
  74. parameters:
  75. - $ref: '#/components/parameters/projectPath'
  76. responses:
  77. 200:
  78. $ref: '#/components/responses/getSingleProject'
  79. 401:
  80. $ref: '#/components/responses/UnauthorizedError'
  81. 403:
  82. $ref: '#/components/responses/403'
  83. 404:
  84. $ref: '#/components/responses/404'
  85. security:
  86. - testAuth: []
  87. put:
  88. tags:
  89. - projects
  90. summary: update existing project by ID
  91. description: update project
  92. operationId: updateProjectById
  93. parameters:
  94. - $ref: '#/components/parameters/projectPath'
  95. requestBody:
  96. $ref: '#/components/requestBodies/Project'
  97. responses:
  98. 200:
  99. $ref: '#/components/responses/getSingleProject'
  100. 400:
  101. $ref: '#/components/responses/400'
  102. 401:
  103. $ref: '#/components/responses/UnauthorizedError'
  104. 403:
  105. $ref: '#/components/responses/403'
  106. 404:
  107. $ref: '#/components/responses/404'
  108. 409:
  109. $ref: '#/components/responses/409'
  110. 413:
  111. $ref: '#/components/responses/413'
  112. security:
  113. - testAuth: []
  114. delete:
  115. tags:
  116. - projects
  117. summary: Deletes a project
  118. description: delete a project
  119. operationId: deleteProject
  120. parameters:
  121. - $ref: '#/components/parameters/projectPath'
  122. responses:
  123. 200:
  124. description: successful operation
  125. 205:
  126. description: Unable to delete. Data is used.
  127. 401:
  128. $ref: '#/components/responses/UnauthorizedError'
  129. 403:
  130. $ref: '#/components/responses/403'
  131. security:
  132. - testAuth: []
  133. /projects/{projectId}/member:
  134. get:
  135. tags:
  136. - projects
  137. summary: find all member by project
  138. description: return all member by project
  139. operationId: getMemberByProject
  140. parameters:
  141. - $ref: '#/components/parameters/projectPath'
  142. - $ref: '#/components/parameters/roleQuery'
  143. - $ref: '#/components/parameters/page'
  144. - $ref: '#/components/parameters/limit'
  145. - name: sort
  146. in: query
  147. description: sort direction (default 'member_id, desc')
  148. schema:
  149. type: string
  150. responses:
  151. 200:
  152. $ref: '#/components/responses/getArrayMember'
  153. 400:
  154. $ref: '#/components/responses/400'
  155. 401:
  156. $ref: '#/components/responses/UnauthorizedError'
  157. security:
  158. - testAuth: []
  159. post:
  160. tags:
  161. - projects
  162. summary: add project member
  163. description: add project member
  164. operationId: addProjectMember
  165. parameters:
  166. - $ref: '#/components/parameters/projectPath'
  167. requestBody:
  168. $ref: '#/components/requestBodies/ProjectMember'
  169. responses:
  170. 201:
  171. $ref: '#/components/responses/successAddMember'
  172. 400:
  173. $ref: '#/components/responses/400'
  174. 401:
  175. $ref: '#/components/responses/UnauthorizedError'
  176. 403:
  177. $ref: '#/components/responses/403'
  178. 404:
  179. $ref: '#/components/responses/404'
  180. 409:
  181. $ref: '#/components/responses/409'
  182. security:
  183. - testAuth: []
  184. /projects/member/{memberId}:
  185. get:
  186. tags:
  187. - projects
  188. summary: find member by ID
  189. description: return member by ID
  190. operationId: getMemberProject
  191. parameters:
  192. - $ref: '#/components/parameters/memberPath'
  193. responses:
  194. 200:
  195. $ref: '#/components/responses/getSingleMember'
  196. 401:
  197. $ref: '#/components/responses/UnauthorizedError'
  198. security:
  199. - testAuth: []
  200. delete:
  201. tags:
  202. - projects
  203. summary: delete project member
  204. description: delete project member
  205. operationId: deleteProjectMember
  206. parameters:
  207. - $ref: '#/components/parameters/memberPath'
  208. responses:
  209. 200:
  210. description: successful operation
  211. 401:
  212. $ref: '#/components/responses/UnauthorizedError'
  213. 403:
  214. $ref: '#/components/responses/403'
  215. 404:
  216. $ref: '#/components/responses/404'
  217. security:
  218. - testAuth: []
  219. /platforms:
  220. get:
  221. tags:
  222. - platforms
  223. summary: find all platform of a project
  224. description: return all platform of a project
  225. operationId: getPlatformByProjectId
  226. parameters:
  227. - $ref: '#/components/parameters/projectQuery'
  228. - $ref: '#/components/parameters/page'
  229. - $ref: '#/components/parameters/limit'
  230. - name: sort
  231. in: query
  232. description: sort direction (default 'platform_id, desc')
  233. schema:
  234. type: string
  235. responses:
  236. 200:
  237. $ref: '#/components/responses/getArrayPlatform'
  238. 401:
  239. $ref: '#/components/responses/UnauthorizedError'
  240. security:
  241. - testAuth: []
  242. post:
  243. tags:
  244. - platforms
  245. summary: Add new platform for a project
  246. description: add new platform for a project
  247. operationId: addPlatformByProjectId
  248. requestBody:
  249. $ref: '#/components/requestBodies/Platform'
  250. responses:
  251. 201:
  252. $ref: '#/components/responses/successAddPlatform'
  253. 400:
  254. $ref: '#/components/responses/400'
  255. 401:
  256. $ref: '#/components/responses/UnauthorizedError'
  257. 403:
  258. $ref: '#/components/responses/403'
  259. 404:
  260. $ref: '#/components/responses/404'
  261. 409:
  262. $ref: '#/components/responses/409'
  263. 413:
  264. $ref: '#/components/responses/413'
  265. security:
  266. - testAuth: []
  267. /platforms/{platformId}:
  268. get:
  269. tags:
  270. - platforms
  271. summary: find platform by ID
  272. description: return platform by ID
  273. operationId: getPlatformById
  274. parameters:
  275. - $ref: '#/components/parameters/platformPath'
  276. responses:
  277. 200:
  278. $ref: '#/components/responses/getSinglePlatform'
  279. 401:
  280. $ref: '#/components/responses/UnauthorizedError'
  281. 404:
  282. $ref: '#/components/responses/404'
  283. security:
  284. - testAuth: []
  285. put:
  286. tags:
  287. - platforms
  288. summary: update existing platform by ID
  289. description: update platform
  290. operationId: updatePlatformById
  291. parameters:
  292. - $ref: '#/components/parameters/platformPath'
  293. requestBody:
  294. $ref: '#/components/requestBodies/Platform'
  295. responses:
  296. 200:
  297. $ref: '#/components/responses/getSinglePlatform'
  298. 400:
  299. $ref: '#/components/responses/400'
  300. 401:
  301. $ref: '#/components/responses/UnauthorizedError'
  302. 403:
  303. $ref: '#/components/responses/403'
  304. 404:
  305. $ref: '#/components/responses/404'
  306. 409:
  307. $ref: '#/components/responses/409'
  308. 413:
  309. $ref: '#/components/responses/413'
  310. security:
  311. - testAuth: []
  312. delete:
  313. tags:
  314. - platforms
  315. summary: deletes a platform by ID
  316. description: delete a platform by ID
  317. operationId: deletePlatformById
  318. parameters:
  319. - $ref: '#/components/parameters/platformPath'
  320. responses:
  321. 200:
  322. description: successful operation
  323. 401:
  324. $ref: '#/components/responses/UnauthorizedError'
  325. 403:
  326. $ref: '#/components/responses/403'
  327. 404:
  328. $ref: '#/components/responses/404'
  329. security:
  330. - testAuth: []
  331. /users:
  332. get:
  333. tags:
  334. - users
  335. summary: find all user
  336. description: return all user
  337. operationId: getUser
  338. parameters:
  339. - $ref: '#/components/parameters/page'
  340. - $ref: '#/components/parameters/limit'
  341. - $ref: '#/components/parameters/sortQuery'
  342. responses:
  343. 200:
  344. $ref: '#/components/responses/getArrayUser'
  345. 400:
  346. $ref: '#/components/responses/400'
  347. 401:
  348. $ref: '#/components/responses/UnauthorizedError'
  349. security:
  350. - testAuth: []
  351. post:
  352. tags:
  353. - users
  354. summary: add user
  355. description: add new user
  356. operationId: AddUser
  357. requestBody:
  358. $ref: '#/components/requestBodies/User'
  359. responses:
  360. 201:
  361. $ref: '#/components/responses/successAddUser'
  362. 400:
  363. $ref: '#/components/responses/400'
  364. 401:
  365. $ref: '#/components/responses/UnauthorizedError'
  366. 409:
  367. $ref: '#/components/responses/409'
  368. 413:
  369. $ref: '#/components/responses/413'
  370. security:
  371. - testAuth: []
  372. /users/{userId}:
  373. get:
  374. tags:
  375. - users
  376. summary: find user by userId
  377. description: return user by userId
  378. operationId: getUserById
  379. parameters:
  380. - $ref: '#/components/parameters/UserPath'
  381. responses:
  382. 200:
  383. $ref: '#/components/responses/getSingleUser'
  384. 401:
  385. $ref: '#/components/responses/UnauthorizedError'
  386. 404:
  387. $ref: '#/components/responses/404'
  388. security:
  389. - testAuth: []
  390. put:
  391. tags:
  392. - users
  393. summary: update existing user except password
  394. description: update user
  395. operationId: updateUserById
  396. parameters:
  397. - $ref: '#/components/parameters/UserPath'
  398. requestBody:
  399. description: User object
  400. required: true
  401. content:
  402. application/json:
  403. schema:
  404. type: object
  405. properties:
  406. username:
  407. type: string
  408. example: abi
  409. name:
  410. type: string
  411. example: abidzar
  412. responses:
  413. 200:
  414. $ref: '#/components/responses/getSingleUser'
  415. 400:
  416. $ref: '#/components/responses/400'
  417. 401:
  418. $ref: '#/components/responses/UnauthorizedError'
  419. 404:
  420. $ref: '#/components/responses/404'
  421. 409:
  422. $ref: '#/components/responses/409'
  423. 413:
  424. $ref: '#/components/responses/413'
  425. security:
  426. - testAuth: []
  427. delete:
  428. tags:
  429. - users
  430. summary: deletes a user by ID
  431. description: delete a user by ID
  432. operationId: deleteUserById
  433. parameters:
  434. - $ref: '#/components/parameters/UserPath'
  435. responses:
  436. 200:
  437. description: successful operation
  438. 205:
  439. description: Unable to delete. Data is used.
  440. 401:
  441. $ref: '#/components/responses/UnauthorizedError'
  442. 403:
  443. $ref: '#/components/responses/403'
  444. 404:
  445. $ref: '#/components/responses/404'
  446. security:
  447. - testAuth: []
  448. /users/{userId}/password:
  449. put:
  450. tags:
  451. - users
  452. summary: change password
  453. description: update user password
  454. operationId: updatePassword
  455. parameters:
  456. - $ref: '#/components/parameters/UserPath'
  457. requestBody:
  458. description: User object
  459. required: true
  460. content:
  461. application/json:
  462. schema:
  463. type: object
  464. properties:
  465. oldPassword:
  466. type: string
  467. example: abi123
  468. newPassword:
  469. type: string
  470. example: abi456
  471. responses:
  472. 200:
  473. $ref: '#/components/responses/getSingleUser'
  474. 400:
  475. $ref: '#/components/responses/400'
  476. 401:
  477. $ref: '#/components/responses/UnauthorizedError'
  478. 403:
  479. description: wrong old password
  480. 404:
  481. $ref: '#/components/responses/404'
  482. security:
  483. - testAuth: []
  484. components:
  485. schemas:
  486. Project:
  487. required:
  488. - id
  489. - name
  490. - owner
  491. type: object
  492. properties:
  493. id:
  494. type: integer
  495. uniqueItems: true
  496. example: 2
  497. name:
  498. type: string
  499. uniqueItems: true
  500. maximum: 100
  501. example: PI
  502. description:
  503. type: string
  504. maximum: 255
  505. example: PropInspector
  506. owner:
  507. $ref: '#/components/schemas/User'
  508. Platform:
  509. type: object
  510. required:
  511. - id
  512. - name
  513. properties:
  514. id:
  515. type: integer
  516. uniqueItems: true
  517. example: 3
  518. name:
  519. type: string
  520. uniqueItems: true
  521. maximum: 100
  522. example: mobile
  523. project_id:
  524. $ref: '#/components/schemas/Project'
  525. User:
  526. type: object
  527. required:
  528. - id
  529. - username
  530. - password
  531. - name
  532. properties:
  533. id:
  534. type: integer
  535. uniqueItems: true
  536. example: 4
  537. username:
  538. type: string
  539. uniqueItems: true
  540. maximum: 100
  541. example: abi
  542. password:
  543. type: string
  544. maximum: 100
  545. example: abi123
  546. name:
  547. type: string
  548. maximum: 255
  549. example: abidzar
  550. project_member:
  551. type: object
  552. properties:
  553. id:
  554. type: integer
  555. uniqueItems: true
  556. project:
  557. $ref: '#/components/schemas/Project'
  558. user:
  559. $ref: '#/components/schemas/User'
  560. role:
  561. type: number
  562. enum: [0,1,2]
  563. description: role = 0.QC, 1. Programmer, 2.Admin
  564. required:
  565. - id
  566. - project
  567. - user
  568. - role
  569. PaginatedResult:
  570. type: object
  571. properties:
  572. totalPage: { type: number, example: 2 }
  573. currentPage: { type: number, example: 0 }
  574. totalRecord: { type: number, example: 4 }
  575. results: { type: array, items: {} }
  576. parameters:
  577. projectPath:
  578. name: projectId
  579. in: path
  580. description: Project ID
  581. required: true
  582. schema:
  583. type: integer
  584. platformPath:
  585. name: platformId
  586. in: path
  587. description: Platform ID
  588. required: true
  589. schema:
  590. type: integer
  591. UserPath:
  592. name: userId
  593. in: path
  594. description: User ID
  595. required: true
  596. schema:
  597. type: integer
  598. projectQuery:
  599. name: project
  600. in: query
  601. description: Project ID
  602. schema:
  603. type: integer
  604. memberPath:
  605. name: memberId
  606. in: path
  607. description: Project Member ID
  608. required: true
  609. schema:
  610. type: integer
  611. limit:
  612. name: limit
  613. in: query
  614. description: Number of records to return (default 3)
  615. schema:
  616. type: number
  617. minimum: 1
  618. page:
  619. name: page
  620. in: query
  621. description: Number of page to return (default 0)
  622. schema:
  623. type: number
  624. minimum: 0
  625. roleQuery:
  626. name: role
  627. in: query
  628. description: filter role (role = QC, Programmer, Admin)
  629. schema:
  630. type: string
  631. sortQuery:
  632. name: sort
  633. in: query
  634. description: sort direction (default 'id, desc')
  635. schema:
  636. type: string
  637. responses:
  638. getArrayProject:
  639. description: successful operation
  640. content:
  641. application/json:
  642. schema:
  643. type: object
  644. allOf:
  645. - $ref: '#/components/schemas/PaginatedResult'
  646. - type: object
  647. properties:
  648. results:
  649. type: array
  650. items:
  651. properties:
  652. id:
  653. type: integer
  654. example: 1
  655. name:
  656. type: string
  657. example: TM
  658. description:
  659. type: string
  660. example: TelMesengger
  661. owner:
  662. properties:
  663. id:
  664. type: integer
  665. example: 1
  666. username:
  667. type: string
  668. example: abi
  669. name:
  670. type: string
  671. example: abidzar
  672. getSingleProject:
  673. description: successful operation
  674. content:
  675. application/json:
  676. schema:
  677. properties:
  678. id:
  679. type: integer
  680. example: 1
  681. name:
  682. type: string
  683. example: TM
  684. description:
  685. type: string
  686. example: TelMesengger
  687. owner:
  688. properties:
  689. id:
  690. type: integer
  691. example: 1
  692. username:
  693. type: string
  694. example: abi
  695. name:
  696. type: string
  697. example: abidzar
  698. successAddProject:
  699. description: record successfully added
  700. content:
  701. application/json:
  702. schema:
  703. properties:
  704. id:
  705. type: integer
  706. example: 1
  707. name:
  708. type: string
  709. example: TM
  710. description:
  711. type: string
  712. example: TelMesengger
  713. owner:
  714. properties:
  715. id:
  716. type: integer
  717. example: 1
  718. username:
  719. type: string
  720. example: abi
  721. name:
  722. type: string
  723. example: abidzar
  724. successAddMember:
  725. description: record successfully added
  726. content:
  727. application/json:
  728. schema:
  729. properties:
  730. id:
  731. type: integer
  732. example: 1
  733. project:
  734. example: TelMessenger
  735. user:
  736. example: abidzar
  737. role:
  738. type: string
  739. example: QC
  740. getArrayPlatform:
  741. description: successful operation
  742. content:
  743. application/json:
  744. schema:
  745. type: object
  746. allOf:
  747. - $ref: '#/components/schemas/PaginatedResult'
  748. - type: object
  749. properties:
  750. results:
  751. type: array
  752. items:
  753. properties:
  754. id:
  755. type: integer
  756. example: 1
  757. name:
  758. type: string
  759. example: mobile
  760. project:
  761. example: TelMessenger
  762. successAddPlatform:
  763. description: record successfully added
  764. content:
  765. application/json:
  766. schema:
  767. properties:
  768. id:
  769. type: integer
  770. example: 1
  771. name:
  772. type: string
  773. example: mobile
  774. project:
  775. example: TelMessenger
  776. getSinglePlatform:
  777. description: successful operation
  778. content:
  779. application/json:
  780. schema:
  781. properties:
  782. id:
  783. type: integer
  784. example: 1
  785. name:
  786. type: string
  787. example: mobile
  788. project:
  789. example: TelMessenger
  790. getArrayUser:
  791. description: successful operation
  792. content:
  793. application/json:
  794. schema:
  795. type: object
  796. allOf:
  797. - $ref: '#/components/schemas/PaginatedResult'
  798. - type: object
  799. properties:
  800. results:
  801. type: array
  802. items:
  803. properties:
  804. id:
  805. type: integer
  806. example: 1
  807. username:
  808. type: string
  809. example: abi
  810. name:
  811. type: string
  812. example: abidzar
  813. successAddUser:
  814. description: record successfully added
  815. content:
  816. application/json:
  817. schema:
  818. properties:
  819. id:
  820. type: integer
  821. example: 1
  822. username:
  823. type: string
  824. example: abi
  825. name:
  826. type: string
  827. example: abidzar
  828. getSingleUser:
  829. description: successful operation
  830. content:
  831. application/json:
  832. schema:
  833. properties:
  834. id:
  835. type: integer
  836. example: 1
  837. username:
  838. type: string
  839. example: abi
  840. name:
  841. type: string
  842. example: abidzar
  843. getSingleMember:
  844. description: successful operation
  845. content:
  846. application/json:
  847. schema:
  848. properties:
  849. id:
  850. example: 1
  851. project:
  852. example: TelMessenger
  853. user:
  854. example: abidzar
  855. role:
  856. example: QC
  857. getArrayMember:
  858. description: successful operation
  859. content:
  860. application/json:
  861. schema:
  862. type: object
  863. allOf:
  864. - $ref: '#/components/schemas/PaginatedResult'
  865. - type: object
  866. properties:
  867. results:
  868. type: array
  869. items:
  870. properties:
  871. id:
  872. example: 1
  873. project:
  874. example: TelMessenger
  875. user:
  876. example: abidzar
  877. role:
  878. example: QC
  879. 400:
  880. description: invalid data
  881. 403:
  882. description: do not have rights
  883. UnauthorizedError:
  884. description: Authentication information is missing or invalid
  885. 404:
  886. description: not found
  887. 409:
  888. description: duplicate data
  889. 413:
  890. description: content too large
  891. requestBodies:
  892. Project:
  893. description: Project object
  894. required: true
  895. content:
  896. application/json:
  897. schema:
  898. type: object
  899. properties:
  900. name:
  901. type: string
  902. example: TM
  903. description:
  904. type: string
  905. example: TelMesengger
  906. ProjectMember:
  907. description: project member object
  908. required: true
  909. content:
  910. application/json:
  911. schema:
  912. type: object
  913. properties:
  914. user_id:
  915. type: integer
  916. example: 1
  917. role:
  918. type: string
  919. example: qc
  920. Platform:
  921. description: Platform object
  922. required: true
  923. content:
  924. application/json:
  925. schema:
  926. type: object
  927. properties:
  928. name:
  929. type: string
  930. example: web
  931. project_name:
  932. type: string
  933. example: TM
  934. User:
  935. description: User object
  936. required: true
  937. content:
  938. application/json:
  939. schema:
  940. type: object
  941. properties:
  942. username:
  943. type: string
  944. example: abi
  945. password:
  946. type: string
  947. example: abi123
  948. name:
  949. type: string
  950. example: abidzar
  951. securitySchemes:
  952. testAuth:
  953. type: http
  954. scheme: basic
  955. description: use `user`/`password` to login