ResponseDefinitions.php 4.5 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195
  1. <?php
  2. declare(strict_types=1);
  3. /**
  4. * SPDX-FileCopyrightText: 2023 Nextcloud GmbH and Nextcloud contributors
  5. * SPDX-License-Identifier: AGPL-3.0-or-later
  6. */
  7. namespace OCA\Core;
  8. /**
  9. * @psalm-type CoreLoginFlowV2Credentials = array{
  10. * server: string,
  11. * loginName: string,
  12. * appPassword: string,
  13. * }
  14. *
  15. * @psalm-type CoreLoginFlowV2 = array{
  16. * poll: array{
  17. * token: string,
  18. * endpoint: string,
  19. * },
  20. * login: string,
  21. * }
  22. *
  23. * @psalm-type CoreNavigationEntry = array{
  24. * id: string,
  25. * order: int|string,
  26. * href: string,
  27. * icon: string,
  28. * type: string,
  29. * name: string,
  30. * active: bool,
  31. * classes: string,
  32. * unread: int,
  33. * }
  34. *
  35. * @psalm-type CoreContactsAction = array{
  36. * title: string,
  37. * icon: string,
  38. * hyperlink: string,
  39. * appId: string,
  40. * }
  41. *
  42. * @psalm-type CoreOpenGraphObject = array{
  43. * id: string,
  44. * name: string,
  45. * description: ?string,
  46. * thumb: ?string,
  47. * link: string,
  48. * }
  49. *
  50. * @psalm-type CoreResource = array{
  51. * richObjectType: string,
  52. * richObject: array<string, mixed>,
  53. * openGraphObject: CoreOpenGraphObject,
  54. * accessible: bool,
  55. * }
  56. *
  57. * @psalm-type CoreCollection = array{
  58. * id: int,
  59. * name: string,
  60. * resources: CoreResource[],
  61. * }
  62. *
  63. * @psalm-type CoreReference = array{
  64. * richObjectType: string,
  65. * richObject: array<string, mixed>,
  66. * openGraphObject: CoreOpenGraphObject,
  67. * accessible: bool,
  68. * }
  69. *
  70. * @psalm-type CoreReferenceProvider = array{
  71. * id: string,
  72. * title: string,
  73. * icon_url: string,
  74. * order: int,
  75. * search_providers_ids: ?string[]
  76. * }
  77. *
  78. * @psalm-type CoreUnifiedSearchProvider = array{
  79. * id: string,
  80. * appId: string,
  81. * name: string,
  82. * icon: string,
  83. * order: int,
  84. * triggers: string[],
  85. * filters: array<string, string>,
  86. * inAppSearch: bool,
  87. * }
  88. *
  89. * @psalm-type CoreUnifiedSearchResultEntry = array{
  90. * thumbnailUrl: string,
  91. * title: string,
  92. * subline: string,
  93. * resourceUrl: string,
  94. * icon: string,
  95. * rounded: bool,
  96. * attributes: string[],
  97. * }
  98. *
  99. * @psalm-type CoreUnifiedSearchResult = array{
  100. * name: string,
  101. * isPaginated: bool,
  102. * entries: CoreUnifiedSearchResultEntry[],
  103. * cursor: int|string|null,
  104. * }
  105. *
  106. * @psalm-type CoreAutocompleteResult = array{
  107. * id: string,
  108. * label: string,
  109. * icon: string,
  110. * source: string,
  111. * status: array{
  112. * status: string,
  113. * message: ?string,
  114. * icon: ?string,
  115. * clearAt: ?int,
  116. * }|string,
  117. * subline: string,
  118. * shareWithDisplayNameUnique: string,
  119. * }
  120. *
  121. * @psalm-type CoreTextProcessingTask = array{
  122. * id: ?int,
  123. * type: string,
  124. * status: 0|1|2|3|4,
  125. * userId: ?string,
  126. * appId: string,
  127. * input: string,
  128. * output: ?string,
  129. * identifier: string,
  130. * completionExpectedAt: ?int
  131. * }
  132. *
  133. * @psalm-type CoreTextToImageTask = array{
  134. * id: ?int,
  135. * status: 0|1|2|3|4,
  136. * userId: ?string,
  137. * appId: string,
  138. * input: string,
  139. * identifier: ?string,
  140. * numberOfImages: int,
  141. * completionExpectedAt: ?int,
  142. * }
  143. *
  144. * @psalm-type CoreTeam = array{
  145. * id: string,
  146. * name: string,
  147. * icon: string,
  148. * }
  149. *
  150. * @psalm-type CoreTeamResource = array{
  151. * id: int,
  152. * label: string,
  153. * url: string,
  154. * iconSvg: ?string,
  155. * iconURL: ?string,
  156. * iconEmoji: ?string,
  157. * }
  158. *
  159. * @psalm-type CoreTaskProcessingShape = array{
  160. * name: string,
  161. * description: string,
  162. * type: "Number"|"Text"|"Audio"|"Image"|"Video"|"File"|"ListOfNumbers"|"ListOfTexts"|"ListOfImages"|"ListOfAudios"|"ListOfVideos"|"ListOfFiles",
  163. * mandatory: bool,
  164. * }
  165. *
  166. * @psalm-type CoreTaskProcessingTaskType = array{
  167. * name: string,
  168. * description: string,
  169. * inputShape: CoreTaskProcessingShape[],
  170. * outputShape: CoreTaskProcessingShape[],
  171. * }
  172. *
  173. * @psalm-type CoreTaskProcessingIO = array<string, numeric|list<numeric>|string|list<string>>
  174. *
  175. * @psalm-type CoreTaskProcessingTask = array{
  176. * id: int,
  177. * lastUpdated: int,
  178. * type: string,
  179. * status: 'STATUS_CANCELLED'|'STATUS_FAILED'|'STATUS_SUCCESSFUL'|'STATUS_RUNNING'|'STATUS_SCHEDULED'|'STATUS_UNKNOWN',
  180. * userId: ?string,
  181. * appId: string,
  182. * input: CoreTaskProcessingIO,
  183. * output: null|CoreTaskProcessingIO,
  184. * customId: ?string,
  185. * completionExpectedAt: ?int,
  186. * progress: ?float
  187. * }
  188. *
  189. */
  190. class ResponseDefinitions {
  191. }