diff options
Diffstat (limited to 'core/ResponseDefinitions.php')
-rw-r--r-- | core/ResponseDefinitions.php | 60 |
1 files changed, 49 insertions, 11 deletions
diff --git a/core/ResponseDefinitions.php b/core/ResponseDefinitions.php index 93662fbaac4..4bf1112a482 100644 --- a/core/ResponseDefinitions.php +++ b/core/ResponseDefinitions.php @@ -7,7 +7,7 @@ declare(strict_types=1); * SPDX-License-Identifier: AGPL-3.0-or-later */ -namespace OCA\Core; +namespace OC\Core; /** * @psalm-type CoreLoginFlowV2Credentials = array{ @@ -63,7 +63,7 @@ namespace OCA\Core; * @psalm-type CoreCollection = array{ * id: int, * name: string, - * resources: CoreResource[], + * resources: list<CoreResource>, * } * * @psalm-type CoreReference = array{ @@ -78,7 +78,7 @@ namespace OCA\Core; * title: string, * icon_url: string, * order: int, - * search_providers_ids: ?string[] + * search_providers_ids: ?list<string>, * } * * @psalm-type CoreUnifiedSearchProvider = array{ @@ -87,7 +87,8 @@ namespace OCA\Core; * name: string, * icon: string, * order: int, - * triggers: string[], + * isExternalProvider: bool, + * triggers: list<string>, * filters: array<string, string>, * inAppSearch: bool, * } @@ -99,13 +100,13 @@ namespace OCA\Core; * resourceUrl: string, * icon: string, * rounded: bool, - * attributes: string[], + * attributes: list<string>, * } * * @psalm-type CoreUnifiedSearchResult = array{ * name: string, * isPaginated: bool, - * entries: CoreUnifiedSearchResultEntry[], + * entries: list<CoreUnifiedSearchResultEntry>, * cursor: int|string|null, * } * @@ -165,15 +166,22 @@ namespace OCA\Core; * @psalm-type CoreTaskProcessingShape = array{ * name: string, * description: string, - * type: "Number"|"Text"|"Audio"|"Image"|"Video"|"File"|"ListOfNumbers"|"ListOfTexts"|"ListOfImages"|"ListOfAudios"|"ListOfVideos"|"ListOfFiles", - * mandatory: bool, + * type: "Number"|"Text"|"Audio"|"Image"|"Video"|"File"|"Enum"|"ListOfNumbers"|"ListOfTexts"|"ListOfImages"|"ListOfAudios"|"ListOfVideos"|"ListOfFiles", * } * * @psalm-type CoreTaskProcessingTaskType = array{ * name: string, * description: string, - * inputShape: CoreTaskProcessingShape[], - * outputShape: CoreTaskProcessingShape[], + * inputShape: array<string, CoreTaskProcessingShape>, + * inputShapeEnumValues: array<string, list<array{name: string, value: string}>>, + * inputShapeDefaults: array<string, numeric|string>, + * optionalInputShape: array<string, CoreTaskProcessingShape>, + * optionalInputShapeEnumValues: array<string, list<array{name: string, value: string}>>, + * optionalInputShapeDefaults: array<string, numeric|string>, + * outputShape: array<string, CoreTaskProcessingShape>, + * outputShapeEnumValues: array<string, list<array{name: string, value: string}>>, + * optionalOutputShape: array<string, CoreTaskProcessingShape>, + * optionalOutputShapeEnumValues: array<string, list<array{name: string, value: string}>>, * } * * @psalm-type CoreTaskProcessingIO = array<string, numeric|list<numeric>|string|list<string>> @@ -189,7 +197,37 @@ namespace OCA\Core; * output: null|CoreTaskProcessingIO, * customId: ?string, * completionExpectedAt: ?int, - * progress: ?float + * progress: ?float, + * scheduledAt: ?int, + * startedAt: ?int, + * endedAt: ?int, + * } + * + * @psalm-type CoreProfileAction = array{ + * id: string, + * icon: string, + * title: string, + * target: ?string, + * } + * + * @psalm-type CoreProfileFields = array{ + * userId: string, + * address?: string|null, + * biography?: string|null, + * displayname?: string|null, + * headline?: string|null, + * isUserAvatarVisible?: bool, + * organisation?: string|null, + * pronouns?: string|null, + * role?: string|null, + * actions: list<CoreProfileAction>, + * } + * + * @psalm-type CoreProfileData = CoreProfileFields&array{ + * // Timezone identifier like Europe/Berlin or America/North_Dakota/Beulah + * timezone: string, + * // Offset in seconds, negative when behind UTC, positive otherwise + * timezoneOffset: int, * } * */ |