ResponseDefinitions.php 5.2 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207
  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 OC\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,
  26. * href: string,
  27. * icon: string,
  28. * type: string,
  29. * name: string,
  30. * app?: string,
  31. * default?: bool,
  32. * active: bool,
  33. * classes: string,
  34. * unread: int,
  35. * }
  36. *
  37. * @psalm-type CoreContactsAction = array{
  38. * title: string,
  39. * icon: string,
  40. * hyperlink: string,
  41. * appId: string,
  42. * }
  43. *
  44. * @psalm-type CoreOpenGraphObject = array{
  45. * id: string,
  46. * name: string,
  47. * description: ?string,
  48. * thumb: ?string,
  49. * link: string,
  50. * }
  51. *
  52. * @psalm-type CoreResource = array{
  53. * richObjectType: string,
  54. * richObject: array<string, ?mixed>,
  55. * openGraphObject: CoreOpenGraphObject,
  56. * accessible: bool,
  57. * }
  58. *
  59. * @psalm-type CoreCollection = array{
  60. * id: int,
  61. * name: string,
  62. * resources: list<CoreResource>,
  63. * }
  64. *
  65. * @psalm-type CoreReference = array{
  66. * richObjectType: string,
  67. * richObject: array<string, ?mixed>,
  68. * openGraphObject: CoreOpenGraphObject,
  69. * accessible: bool,
  70. * }
  71. *
  72. * @psalm-type CoreReferenceProvider = array{
  73. * id: string,
  74. * title: string,
  75. * icon_url: string,
  76. * order: int,
  77. * search_providers_ids: ?list<string>,
  78. * }
  79. *
  80. * @psalm-type CoreUnifiedSearchProvider = array{
  81. * id: string,
  82. * appId: string,
  83. * name: string,
  84. * icon: string,
  85. * order: int,
  86. * triggers: list<string>,
  87. * filters: array<string, string>,
  88. * inAppSearch: bool,
  89. * }
  90. *
  91. * @psalm-type CoreUnifiedSearchResultEntry = array{
  92. * thumbnailUrl: string,
  93. * title: string,
  94. * subline: string,
  95. * resourceUrl: string,
  96. * icon: string,
  97. * rounded: bool,
  98. * attributes: list<string>,
  99. * }
  100. *
  101. * @psalm-type CoreUnifiedSearchResult = array{
  102. * name: string,
  103. * isPaginated: bool,
  104. * entries: list<CoreUnifiedSearchResultEntry>,
  105. * cursor: int|string|null,
  106. * }
  107. *
  108. * @psalm-type CoreAutocompleteResult = array{
  109. * id: string,
  110. * label: string,
  111. * icon: string,
  112. * source: string,
  113. * status: array{
  114. * status: string,
  115. * message: ?string,
  116. * icon: ?string,
  117. * clearAt: ?int,
  118. * }|string,
  119. * subline: string,
  120. * shareWithDisplayNameUnique: string,
  121. * }
  122. *
  123. * @psalm-type CoreTextProcessingTask = array{
  124. * id: ?int,
  125. * type: string,
  126. * status: 0|1|2|3|4,
  127. * userId: ?string,
  128. * appId: string,
  129. * input: string,
  130. * output: ?string,
  131. * identifier: string,
  132. * completionExpectedAt: ?int
  133. * }
  134. *
  135. * @psalm-type CoreTextToImageTask = array{
  136. * id: ?int,
  137. * status: 0|1|2|3|4,
  138. * userId: ?string,
  139. * appId: string,
  140. * input: string,
  141. * identifier: ?string,
  142. * numberOfImages: int,
  143. * completionExpectedAt: ?int,
  144. * }
  145. *
  146. * @psalm-type CoreTeam = array{
  147. * id: string,
  148. * name: string,
  149. * icon: string,
  150. * }
  151. *
  152. * @psalm-type CoreTeamResource = array{
  153. * id: int,
  154. * label: string,
  155. * url: string,
  156. * iconSvg: ?string,
  157. * iconURL: ?string,
  158. * iconEmoji: ?string,
  159. * }
  160. *
  161. * @psalm-type CoreTaskProcessingShape = array{
  162. * name: string,
  163. * description: string,
  164. * type: "Number"|"Text"|"Audio"|"Image"|"Video"|"File"|"Enum"|"ListOfNumbers"|"ListOfTexts"|"ListOfImages"|"ListOfAudios"|"ListOfVideos"|"ListOfFiles",
  165. * }
  166. *
  167. * @psalm-type CoreTaskProcessingTaskType = array{
  168. * name: string,
  169. * description: string,
  170. * inputShape: list<CoreTaskProcessingShape>,
  171. * inputShapeEnumValues: list<list<array{name: string, value: string}>>,
  172. * inputShapeDefaults: array<string, numeric|string>,
  173. * optionalInputShape: list<CoreTaskProcessingShape>,
  174. * optionalInputShapeEnumValues: list<list<array{name: string, value: string}>>,
  175. * optionalInputShapeDefaults: array<string, numeric|string>,
  176. * outputShape: list<CoreTaskProcessingShape>,
  177. * outputShapeEnumValues: list<list<array{name: string, value: string}>>,
  178. * optionalOutputShape: list<CoreTaskProcessingShape>,
  179. * optionalOutputShapeEnumValues: list<list<array{name: string, value: string}>>,
  180. * }
  181. *
  182. * @psalm-type CoreTaskProcessingIO = array<string, numeric|list<numeric>|string|list<string>>
  183. *
  184. * @psalm-type CoreTaskProcessingTask = array{
  185. * id: int,
  186. * lastUpdated: int,
  187. * type: string,
  188. * status: 'STATUS_CANCELLED'|'STATUS_FAILED'|'STATUS_SUCCESSFUL'|'STATUS_RUNNING'|'STATUS_SCHEDULED'|'STATUS_UNKNOWN',
  189. * userId: ?string,
  190. * appId: string,
  191. * input: CoreTaskProcessingIO,
  192. * output: null|CoreTaskProcessingIO,
  193. * customId: ?string,
  194. * completionExpectedAt: ?int,
  195. * progress: ?float,
  196. * scheduledAt: ?int,
  197. * startedAt: ?int,
  198. * endedAt: ?int,
  199. * }
  200. *
  201. */
  202. class ResponseDefinitions {
  203. }