openapi.json 47 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851852853854855856857858859860861862863864865866867868869870871872873874875876877878879880881882883884885886887888889890891892893894895896897898899900901902903904905906907908909910911912913914915916917918919920921922923924925926927928929930931932933934935936937938939940941942943944945946947948949950951952953954955956957958959960961962963964965966967968969970971972973974975976977978979980981982983984985986987988989990991992993994995996997998999100010011002100310041005100610071008100910101011101210131014101510161017101810191020102110221023102410251026102710281029103010311032103310341035103610371038103910401041104210431044104510461047104810491050105110521053105410551056105710581059106010611062106310641065106610671068106910701071107210731074107510761077107810791080108110821083108410851086108710881089109010911092109310941095109610971098109911001101110211031104110511061107110811091110111111121113111411151116111711181119112011211122112311241125112611271128112911301131113211331134113511361137113811391140114111421143114411451146114711481149115011511152115311541155115611571158115911601161
  1. {
  2. "openapi": "3.0.3",
  3. "info": {
  4. "title": "user_status",
  5. "version": "0.0.1",
  6. "description": "User status",
  7. "license": {
  8. "name": "agpl"
  9. }
  10. },
  11. "components": {
  12. "securitySchemes": {
  13. "basic_auth": {
  14. "type": "http",
  15. "scheme": "basic"
  16. },
  17. "bearer_auth": {
  18. "type": "http",
  19. "scheme": "bearer"
  20. }
  21. },
  22. "schemas": {
  23. "Capabilities": {
  24. "type": "object",
  25. "required": [
  26. "user_status"
  27. ],
  28. "properties": {
  29. "user_status": {
  30. "type": "object",
  31. "required": [
  32. "enabled",
  33. "restore",
  34. "supports_emoji"
  35. ],
  36. "properties": {
  37. "enabled": {
  38. "type": "boolean"
  39. },
  40. "restore": {
  41. "type": "boolean"
  42. },
  43. "supports_emoji": {
  44. "type": "boolean"
  45. }
  46. }
  47. }
  48. }
  49. },
  50. "ClearAt": {
  51. "type": "object",
  52. "required": [
  53. "type",
  54. "time"
  55. ],
  56. "properties": {
  57. "type": {
  58. "type": "string",
  59. "enum": [
  60. "period",
  61. "end-of"
  62. ]
  63. },
  64. "time": {
  65. "anyOf": [
  66. {
  67. "type": "integer",
  68. "format": "int64"
  69. },
  70. {
  71. "$ref": "#/components/schemas/ClearAtTimeType"
  72. }
  73. ]
  74. }
  75. }
  76. },
  77. "ClearAtTimeType": {
  78. "type": "string",
  79. "enum": [
  80. "day",
  81. "week"
  82. ]
  83. },
  84. "OCSMeta": {
  85. "type": "object",
  86. "required": [
  87. "status",
  88. "statuscode"
  89. ],
  90. "properties": {
  91. "status": {
  92. "type": "string"
  93. },
  94. "statuscode": {
  95. "type": "integer"
  96. },
  97. "message": {
  98. "type": "string"
  99. },
  100. "totalitems": {
  101. "type": "string"
  102. },
  103. "itemsperpage": {
  104. "type": "string"
  105. }
  106. }
  107. },
  108. "Predefined": {
  109. "type": "object",
  110. "required": [
  111. "id",
  112. "icon",
  113. "message",
  114. "clearAt",
  115. "visible"
  116. ],
  117. "properties": {
  118. "id": {
  119. "type": "string"
  120. },
  121. "icon": {
  122. "type": "string"
  123. },
  124. "message": {
  125. "type": "string"
  126. },
  127. "clearAt": {
  128. "$ref": "#/components/schemas/ClearAt",
  129. "nullable": true
  130. },
  131. "visible": {
  132. "type": "boolean",
  133. "nullable": true
  134. }
  135. }
  136. },
  137. "Private": {
  138. "allOf": [
  139. {
  140. "$ref": "#/components/schemas/Public"
  141. },
  142. {
  143. "type": "object",
  144. "required": [
  145. "messageId",
  146. "messageIsPredefined",
  147. "statusIsUserDefined"
  148. ],
  149. "properties": {
  150. "messageId": {
  151. "type": "string",
  152. "nullable": true
  153. },
  154. "messageIsPredefined": {
  155. "type": "boolean"
  156. },
  157. "statusIsUserDefined": {
  158. "type": "boolean"
  159. }
  160. }
  161. }
  162. ]
  163. },
  164. "Public": {
  165. "type": "object",
  166. "required": [
  167. "userId",
  168. "message",
  169. "icon",
  170. "clearAt",
  171. "status"
  172. ],
  173. "properties": {
  174. "userId": {
  175. "type": "string"
  176. },
  177. "message": {
  178. "type": "string",
  179. "nullable": true
  180. },
  181. "icon": {
  182. "type": "string",
  183. "nullable": true
  184. },
  185. "clearAt": {
  186. "type": "integer",
  187. "format": "int64",
  188. "nullable": true
  189. },
  190. "status": {
  191. "$ref": "#/components/schemas/Type"
  192. }
  193. }
  194. },
  195. "Type": {
  196. "type": "string",
  197. "enum": [
  198. "online",
  199. "away",
  200. "dnd",
  201. "busy",
  202. "offline",
  203. "invisible"
  204. ]
  205. }
  206. }
  207. },
  208. "paths": {
  209. "/ocs/v2.php/apps/user_status/api/v1/heartbeat": {
  210. "put": {
  211. "operationId": "heartbeat-heartbeat",
  212. "summary": "Keep the status alive",
  213. "tags": [
  214. "heartbeat"
  215. ],
  216. "security": [
  217. {
  218. "bearer_auth": []
  219. },
  220. {
  221. "basic_auth": []
  222. }
  223. ],
  224. "requestBody": {
  225. "required": true,
  226. "content": {
  227. "application/json": {
  228. "schema": {
  229. "type": "object",
  230. "required": [
  231. "status"
  232. ],
  233. "properties": {
  234. "status": {
  235. "type": "string",
  236. "description": "Only online, away"
  237. }
  238. }
  239. }
  240. }
  241. }
  242. },
  243. "parameters": [
  244. {
  245. "name": "OCS-APIRequest",
  246. "in": "header",
  247. "description": "Required to be true for the API request to pass",
  248. "required": true,
  249. "schema": {
  250. "type": "boolean",
  251. "default": true
  252. }
  253. }
  254. ],
  255. "responses": {
  256. "200": {
  257. "description": "Status successfully updated",
  258. "content": {
  259. "application/json": {
  260. "schema": {
  261. "type": "object",
  262. "required": [
  263. "ocs"
  264. ],
  265. "properties": {
  266. "ocs": {
  267. "type": "object",
  268. "required": [
  269. "meta",
  270. "data"
  271. ],
  272. "properties": {
  273. "meta": {
  274. "$ref": "#/components/schemas/OCSMeta"
  275. },
  276. "data": {
  277. "$ref": "#/components/schemas/Private"
  278. }
  279. }
  280. }
  281. }
  282. }
  283. }
  284. }
  285. },
  286. "400": {
  287. "description": "Invalid status to update",
  288. "content": {
  289. "application/json": {
  290. "schema": {
  291. "type": "object",
  292. "required": [
  293. "ocs"
  294. ],
  295. "properties": {
  296. "ocs": {
  297. "type": "object",
  298. "required": [
  299. "meta",
  300. "data"
  301. ],
  302. "properties": {
  303. "meta": {
  304. "$ref": "#/components/schemas/OCSMeta"
  305. },
  306. "data": {}
  307. }
  308. }
  309. }
  310. }
  311. }
  312. }
  313. },
  314. "500": {
  315. "description": "",
  316. "content": {
  317. "application/json": {
  318. "schema": {
  319. "type": "object",
  320. "required": [
  321. "ocs"
  322. ],
  323. "properties": {
  324. "ocs": {
  325. "type": "object",
  326. "required": [
  327. "meta",
  328. "data"
  329. ],
  330. "properties": {
  331. "meta": {
  332. "$ref": "#/components/schemas/OCSMeta"
  333. },
  334. "data": {}
  335. }
  336. }
  337. }
  338. }
  339. }
  340. }
  341. },
  342. "204": {
  343. "description": "User has no status to keep alive"
  344. }
  345. }
  346. }
  347. },
  348. "/ocs/v2.php/apps/user_status/api/v1/predefined_statuses": {
  349. "get": {
  350. "operationId": "predefined_status-find-all",
  351. "summary": "Get all predefined messages",
  352. "tags": [
  353. "predefined_status"
  354. ],
  355. "security": [
  356. {
  357. "bearer_auth": []
  358. },
  359. {
  360. "basic_auth": []
  361. }
  362. ],
  363. "parameters": [
  364. {
  365. "name": "OCS-APIRequest",
  366. "in": "header",
  367. "description": "Required to be true for the API request to pass",
  368. "required": true,
  369. "schema": {
  370. "type": "boolean",
  371. "default": true
  372. }
  373. }
  374. ],
  375. "responses": {
  376. "200": {
  377. "description": "Predefined statuses returned",
  378. "content": {
  379. "application/json": {
  380. "schema": {
  381. "type": "object",
  382. "required": [
  383. "ocs"
  384. ],
  385. "properties": {
  386. "ocs": {
  387. "type": "object",
  388. "required": [
  389. "meta",
  390. "data"
  391. ],
  392. "properties": {
  393. "meta": {
  394. "$ref": "#/components/schemas/OCSMeta"
  395. },
  396. "data": {
  397. "type": "array",
  398. "items": {
  399. "$ref": "#/components/schemas/Predefined"
  400. }
  401. }
  402. }
  403. }
  404. }
  405. }
  406. }
  407. }
  408. }
  409. }
  410. }
  411. },
  412. "/ocs/v2.php/apps/user_status/api/v1/statuses": {
  413. "get": {
  414. "operationId": "statuses-find-all",
  415. "summary": "Find statuses of users",
  416. "tags": [
  417. "statuses"
  418. ],
  419. "security": [
  420. {
  421. "bearer_auth": []
  422. },
  423. {
  424. "basic_auth": []
  425. }
  426. ],
  427. "parameters": [
  428. {
  429. "name": "limit",
  430. "in": "query",
  431. "description": "Maximum number of statuses to find",
  432. "schema": {
  433. "type": "integer",
  434. "format": "int64",
  435. "nullable": true
  436. }
  437. },
  438. {
  439. "name": "offset",
  440. "in": "query",
  441. "description": "Offset for finding statuses",
  442. "schema": {
  443. "type": "integer",
  444. "format": "int64",
  445. "nullable": true
  446. }
  447. },
  448. {
  449. "name": "OCS-APIRequest",
  450. "in": "header",
  451. "description": "Required to be true for the API request to pass",
  452. "required": true,
  453. "schema": {
  454. "type": "boolean",
  455. "default": true
  456. }
  457. }
  458. ],
  459. "responses": {
  460. "200": {
  461. "description": "Statuses returned",
  462. "content": {
  463. "application/json": {
  464. "schema": {
  465. "type": "object",
  466. "required": [
  467. "ocs"
  468. ],
  469. "properties": {
  470. "ocs": {
  471. "type": "object",
  472. "required": [
  473. "meta",
  474. "data"
  475. ],
  476. "properties": {
  477. "meta": {
  478. "$ref": "#/components/schemas/OCSMeta"
  479. },
  480. "data": {
  481. "type": "array",
  482. "items": {
  483. "$ref": "#/components/schemas/Public"
  484. }
  485. }
  486. }
  487. }
  488. }
  489. }
  490. }
  491. }
  492. }
  493. }
  494. }
  495. },
  496. "/ocs/v2.php/apps/user_status/api/v1/statuses/{userId}": {
  497. "get": {
  498. "operationId": "statuses-find",
  499. "summary": "Find the status of a user",
  500. "tags": [
  501. "statuses"
  502. ],
  503. "security": [
  504. {
  505. "bearer_auth": []
  506. },
  507. {
  508. "basic_auth": []
  509. }
  510. ],
  511. "parameters": [
  512. {
  513. "name": "userId",
  514. "in": "path",
  515. "description": "ID of the user",
  516. "required": true,
  517. "schema": {
  518. "type": "string"
  519. }
  520. },
  521. {
  522. "name": "OCS-APIRequest",
  523. "in": "header",
  524. "description": "Required to be true for the API request to pass",
  525. "required": true,
  526. "schema": {
  527. "type": "boolean",
  528. "default": true
  529. }
  530. }
  531. ],
  532. "responses": {
  533. "200": {
  534. "description": "Status returned",
  535. "content": {
  536. "application/json": {
  537. "schema": {
  538. "type": "object",
  539. "required": [
  540. "ocs"
  541. ],
  542. "properties": {
  543. "ocs": {
  544. "type": "object",
  545. "required": [
  546. "meta",
  547. "data"
  548. ],
  549. "properties": {
  550. "meta": {
  551. "$ref": "#/components/schemas/OCSMeta"
  552. },
  553. "data": {
  554. "$ref": "#/components/schemas/Public"
  555. }
  556. }
  557. }
  558. }
  559. }
  560. }
  561. }
  562. },
  563. "404": {
  564. "description": "The user was not found",
  565. "content": {
  566. "application/json": {
  567. "schema": {
  568. "type": "object",
  569. "required": [
  570. "ocs"
  571. ],
  572. "properties": {
  573. "ocs": {
  574. "type": "object",
  575. "required": [
  576. "meta",
  577. "data"
  578. ],
  579. "properties": {
  580. "meta": {
  581. "$ref": "#/components/schemas/OCSMeta"
  582. },
  583. "data": {}
  584. }
  585. }
  586. }
  587. }
  588. }
  589. }
  590. }
  591. }
  592. }
  593. },
  594. "/ocs/v2.php/apps/user_status/api/v1/user_status": {
  595. "get": {
  596. "operationId": "user_status-get-status",
  597. "summary": "Get the status of the current user",
  598. "tags": [
  599. "user_status"
  600. ],
  601. "security": [
  602. {
  603. "bearer_auth": []
  604. },
  605. {
  606. "basic_auth": []
  607. }
  608. ],
  609. "parameters": [
  610. {
  611. "name": "OCS-APIRequest",
  612. "in": "header",
  613. "description": "Required to be true for the API request to pass",
  614. "required": true,
  615. "schema": {
  616. "type": "boolean",
  617. "default": true
  618. }
  619. }
  620. ],
  621. "responses": {
  622. "200": {
  623. "description": "The status was found successfully",
  624. "content": {
  625. "application/json": {
  626. "schema": {
  627. "type": "object",
  628. "required": [
  629. "ocs"
  630. ],
  631. "properties": {
  632. "ocs": {
  633. "type": "object",
  634. "required": [
  635. "meta",
  636. "data"
  637. ],
  638. "properties": {
  639. "meta": {
  640. "$ref": "#/components/schemas/OCSMeta"
  641. },
  642. "data": {
  643. "$ref": "#/components/schemas/Private"
  644. }
  645. }
  646. }
  647. }
  648. }
  649. }
  650. }
  651. },
  652. "404": {
  653. "description": "The user was not found",
  654. "content": {
  655. "application/json": {
  656. "schema": {
  657. "type": "object",
  658. "required": [
  659. "ocs"
  660. ],
  661. "properties": {
  662. "ocs": {
  663. "type": "object",
  664. "required": [
  665. "meta",
  666. "data"
  667. ],
  668. "properties": {
  669. "meta": {
  670. "$ref": "#/components/schemas/OCSMeta"
  671. },
  672. "data": {}
  673. }
  674. }
  675. }
  676. }
  677. }
  678. }
  679. }
  680. }
  681. }
  682. },
  683. "/ocs/v2.php/apps/user_status/api/v1/user_status/status": {
  684. "put": {
  685. "operationId": "user_status-set-status",
  686. "summary": "Update the status type of the current user",
  687. "tags": [
  688. "user_status"
  689. ],
  690. "security": [
  691. {
  692. "bearer_auth": []
  693. },
  694. {
  695. "basic_auth": []
  696. }
  697. ],
  698. "requestBody": {
  699. "required": true,
  700. "content": {
  701. "application/json": {
  702. "schema": {
  703. "type": "object",
  704. "required": [
  705. "statusType"
  706. ],
  707. "properties": {
  708. "statusType": {
  709. "type": "string",
  710. "description": "The new status type"
  711. }
  712. }
  713. }
  714. }
  715. }
  716. },
  717. "parameters": [
  718. {
  719. "name": "OCS-APIRequest",
  720. "in": "header",
  721. "description": "Required to be true for the API request to pass",
  722. "required": true,
  723. "schema": {
  724. "type": "boolean",
  725. "default": true
  726. }
  727. }
  728. ],
  729. "responses": {
  730. "200": {
  731. "description": "The status was updated successfully",
  732. "content": {
  733. "application/json": {
  734. "schema": {
  735. "type": "object",
  736. "required": [
  737. "ocs"
  738. ],
  739. "properties": {
  740. "ocs": {
  741. "type": "object",
  742. "required": [
  743. "meta",
  744. "data"
  745. ],
  746. "properties": {
  747. "meta": {
  748. "$ref": "#/components/schemas/OCSMeta"
  749. },
  750. "data": {
  751. "$ref": "#/components/schemas/Private"
  752. }
  753. }
  754. }
  755. }
  756. }
  757. }
  758. }
  759. },
  760. "400": {
  761. "description": "The status type is invalid",
  762. "content": {
  763. "application/json": {
  764. "schema": {
  765. "type": "object",
  766. "required": [
  767. "ocs"
  768. ],
  769. "properties": {
  770. "ocs": {
  771. "type": "object",
  772. "required": [
  773. "meta",
  774. "data"
  775. ],
  776. "properties": {
  777. "meta": {
  778. "$ref": "#/components/schemas/OCSMeta"
  779. },
  780. "data": {}
  781. }
  782. }
  783. }
  784. }
  785. }
  786. }
  787. }
  788. }
  789. }
  790. },
  791. "/ocs/v2.php/apps/user_status/api/v1/user_status/message/predefined": {
  792. "put": {
  793. "operationId": "user_status-set-predefined-message",
  794. "summary": "Set the message to a predefined message for the current user",
  795. "tags": [
  796. "user_status"
  797. ],
  798. "security": [
  799. {
  800. "bearer_auth": []
  801. },
  802. {
  803. "basic_auth": []
  804. }
  805. ],
  806. "requestBody": {
  807. "required": true,
  808. "content": {
  809. "application/json": {
  810. "schema": {
  811. "type": "object",
  812. "required": [
  813. "messageId"
  814. ],
  815. "properties": {
  816. "messageId": {
  817. "type": "string",
  818. "description": "ID of the predefined message"
  819. },
  820. "clearAt": {
  821. "type": "integer",
  822. "format": "int64",
  823. "nullable": true,
  824. "description": "When the message should be cleared"
  825. }
  826. }
  827. }
  828. }
  829. }
  830. },
  831. "parameters": [
  832. {
  833. "name": "OCS-APIRequest",
  834. "in": "header",
  835. "description": "Required to be true for the API request to pass",
  836. "required": true,
  837. "schema": {
  838. "type": "boolean",
  839. "default": true
  840. }
  841. }
  842. ],
  843. "responses": {
  844. "200": {
  845. "description": "The message was updated successfully",
  846. "content": {
  847. "application/json": {
  848. "schema": {
  849. "type": "object",
  850. "required": [
  851. "ocs"
  852. ],
  853. "properties": {
  854. "ocs": {
  855. "type": "object",
  856. "required": [
  857. "meta",
  858. "data"
  859. ],
  860. "properties": {
  861. "meta": {
  862. "$ref": "#/components/schemas/OCSMeta"
  863. },
  864. "data": {
  865. "$ref": "#/components/schemas/Private"
  866. }
  867. }
  868. }
  869. }
  870. }
  871. }
  872. }
  873. },
  874. "400": {
  875. "description": "The clearAt or message-id is invalid",
  876. "content": {
  877. "application/json": {
  878. "schema": {
  879. "type": "object",
  880. "required": [
  881. "ocs"
  882. ],
  883. "properties": {
  884. "ocs": {
  885. "type": "object",
  886. "required": [
  887. "meta",
  888. "data"
  889. ],
  890. "properties": {
  891. "meta": {
  892. "$ref": "#/components/schemas/OCSMeta"
  893. },
  894. "data": {}
  895. }
  896. }
  897. }
  898. }
  899. }
  900. }
  901. }
  902. }
  903. }
  904. },
  905. "/ocs/v2.php/apps/user_status/api/v1/user_status/message/custom": {
  906. "put": {
  907. "operationId": "user_status-set-custom-message",
  908. "summary": "Set the message to a custom message for the current user",
  909. "tags": [
  910. "user_status"
  911. ],
  912. "security": [
  913. {
  914. "bearer_auth": []
  915. },
  916. {
  917. "basic_auth": []
  918. }
  919. ],
  920. "requestBody": {
  921. "required": false,
  922. "content": {
  923. "application/json": {
  924. "schema": {
  925. "type": "object",
  926. "properties": {
  927. "statusIcon": {
  928. "type": "string",
  929. "nullable": true,
  930. "description": "Icon of the status"
  931. },
  932. "message": {
  933. "type": "string",
  934. "nullable": true,
  935. "description": "Message of the status"
  936. },
  937. "clearAt": {
  938. "type": "integer",
  939. "format": "int64",
  940. "nullable": true,
  941. "description": "When the message should be cleared"
  942. }
  943. }
  944. }
  945. }
  946. }
  947. },
  948. "parameters": [
  949. {
  950. "name": "OCS-APIRequest",
  951. "in": "header",
  952. "description": "Required to be true for the API request to pass",
  953. "required": true,
  954. "schema": {
  955. "type": "boolean",
  956. "default": true
  957. }
  958. }
  959. ],
  960. "responses": {
  961. "200": {
  962. "description": "The message was updated successfully",
  963. "content": {
  964. "application/json": {
  965. "schema": {
  966. "type": "object",
  967. "required": [
  968. "ocs"
  969. ],
  970. "properties": {
  971. "ocs": {
  972. "type": "object",
  973. "required": [
  974. "meta",
  975. "data"
  976. ],
  977. "properties": {
  978. "meta": {
  979. "$ref": "#/components/schemas/OCSMeta"
  980. },
  981. "data": {
  982. "$ref": "#/components/schemas/Private"
  983. }
  984. }
  985. }
  986. }
  987. }
  988. }
  989. }
  990. },
  991. "400": {
  992. "description": "The clearAt or icon is invalid or the message is too long",
  993. "content": {
  994. "application/json": {
  995. "schema": {
  996. "type": "object",
  997. "required": [
  998. "ocs"
  999. ],
  1000. "properties": {
  1001. "ocs": {
  1002. "type": "object",
  1003. "required": [
  1004. "meta",
  1005. "data"
  1006. ],
  1007. "properties": {
  1008. "meta": {
  1009. "$ref": "#/components/schemas/OCSMeta"
  1010. },
  1011. "data": {}
  1012. }
  1013. }
  1014. }
  1015. }
  1016. }
  1017. }
  1018. }
  1019. }
  1020. }
  1021. },
  1022. "/ocs/v2.php/apps/user_status/api/v1/user_status/message": {
  1023. "delete": {
  1024. "operationId": "user_status-clear-message",
  1025. "summary": "Clear the message of the current user",
  1026. "tags": [
  1027. "user_status"
  1028. ],
  1029. "security": [
  1030. {
  1031. "bearer_auth": []
  1032. },
  1033. {
  1034. "basic_auth": []
  1035. }
  1036. ],
  1037. "parameters": [
  1038. {
  1039. "name": "OCS-APIRequest",
  1040. "in": "header",
  1041. "description": "Required to be true for the API request to pass",
  1042. "required": true,
  1043. "schema": {
  1044. "type": "boolean",
  1045. "default": true
  1046. }
  1047. }
  1048. ],
  1049. "responses": {
  1050. "200": {
  1051. "description": "Message cleared successfully",
  1052. "content": {
  1053. "application/json": {
  1054. "schema": {
  1055. "type": "object",
  1056. "required": [
  1057. "ocs"
  1058. ],
  1059. "properties": {
  1060. "ocs": {
  1061. "type": "object",
  1062. "required": [
  1063. "meta",
  1064. "data"
  1065. ],
  1066. "properties": {
  1067. "meta": {
  1068. "$ref": "#/components/schemas/OCSMeta"
  1069. },
  1070. "data": {}
  1071. }
  1072. }
  1073. }
  1074. }
  1075. }
  1076. }
  1077. }
  1078. }
  1079. }
  1080. },
  1081. "/ocs/v2.php/apps/user_status/api/v1/user_status/revert/{messageId}": {
  1082. "delete": {
  1083. "operationId": "user_status-revert-status",
  1084. "summary": "Revert the status to the previous status",
  1085. "tags": [
  1086. "user_status"
  1087. ],
  1088. "security": [
  1089. {
  1090. "bearer_auth": []
  1091. },
  1092. {
  1093. "basic_auth": []
  1094. }
  1095. ],
  1096. "parameters": [
  1097. {
  1098. "name": "messageId",
  1099. "in": "path",
  1100. "description": "ID of the message to delete",
  1101. "required": true,
  1102. "schema": {
  1103. "type": "string"
  1104. }
  1105. },
  1106. {
  1107. "name": "OCS-APIRequest",
  1108. "in": "header",
  1109. "description": "Required to be true for the API request to pass",
  1110. "required": true,
  1111. "schema": {
  1112. "type": "boolean",
  1113. "default": true
  1114. }
  1115. }
  1116. ],
  1117. "responses": {
  1118. "200": {
  1119. "description": "Status reverted",
  1120. "content": {
  1121. "application/json": {
  1122. "schema": {
  1123. "type": "object",
  1124. "required": [
  1125. "ocs"
  1126. ],
  1127. "properties": {
  1128. "ocs": {
  1129. "type": "object",
  1130. "required": [
  1131. "meta",
  1132. "data"
  1133. ],
  1134. "properties": {
  1135. "meta": {
  1136. "$ref": "#/components/schemas/OCSMeta"
  1137. },
  1138. "data": {
  1139. "anyOf": [
  1140. {
  1141. "$ref": "#/components/schemas/Private"
  1142. },
  1143. {
  1144. "type": "array",
  1145. "maxItems": 0
  1146. }
  1147. ]
  1148. }
  1149. }
  1150. }
  1151. }
  1152. }
  1153. }
  1154. }
  1155. }
  1156. }
  1157. }
  1158. }
  1159. },
  1160. "tags": []
  1161. }